Wednesday, April 10, 2013

Livecode Cross Platform is now open source

An development tool I used for the past nine years released itself as open source April 9th 2013.
This includes the full source code to the engine for desktop, mobile and server along with the IDE.

Here an quick link to the Git engine source https://github.com/runrev/livecode

The IDE which needs an free account to unlock and use can be found here Runrev

Livecode is an cross-platform tool for Mac OSX , Windows, Linux, Server, Android and iOS.
Its not prefect and can not do everything. However what it can do it does well. For the last 9 years 80% of all the software I have sold was made with Livecode. Even if now I moved on to using Real Studio (Xojo), Xcode and Unity for most of my software and games. (it was not for any other reason than I needed tools that could make professional software that Livecode was no longer suited the best option to build.)

I do recommend checking it out, it will surprise you to find out Livecode can do much more than what you first think it can do.

There also an great amount of 3rd party add-ons and custom controls than any other tool I seen besides Unity. One of the best part of it being open source for me is actually opening up the engine source and tweaking things. However I only started peeking and saying there using that? In I use that already with tool X.

I recall helping out an Livecode user last winter, and when I recommend curl as an option I was told "that dumb I never use it." Well guess what, Livecode was using curl, one look at the source code and licensing shows it.

There are many other interesting discoveries on how they made there tool work. I for years tried to guess what cross compiler they used. When I seen stack-less just in time compiler. I almost fell out of my chair. I had that listed as one of my guesses years ago.

If your new to Livecode, it will depended on coding experience on how you take it. I personally learned programing from BASIC and Livecode is much like hyper-talk. It takes time getting use to if you have years of using other programming languages, because it seems like baby talk. If you can look beyond that you find it works fast and does a lot.

The mobile space is actually very well and 500 times better than Corona sdk. However if you want physics you need to program them your self, which is really not that hard. There is however some major down  sides. The native UI is outdated at best, but you can use custom controls and get them to work pretty fast depending on your skill at design.

For Mac there no cocoa yet, witch means no retina support. This was one of the main reasons I quit using Livecode last year. And moved back to tools like Xcode and real studio.

Personally Livecode still worth an look for Mobile and it also does windows really well. Also Cocoa for mac is now an future project of runrev so its coming. I just do not think it will come till 2014 I could be wrong.

Also the IDE is way dated. And mobile apps windows at 1 to 1 retina sizes do not fit most computer displays. There an few tricks to getting this to work, witch is not all that bad for the trade off in code time saved.

Why not download it and give it an try. Maybe it works for you. Also do not believe everyone on that forum that says you can not do that. I proved many of them wrong for years doing what they said can not be done with Livecode.

Monday, March 4, 2013

Mac Retina Supported Toolbars with Real Studio (Xojo)


Supporting retina base graphics in mac apps is easy. However how would one support retina graphics in an Mac Toolbar. With Retina we know we need to make all graphic files 2 times bigger than the standard resolution image. The standard resolution images files for toolbars are 32x32 pixels so high resolution needs 64x64 pixel images loaded.

Start by using toolbar icons that are 64x64 pixels and label them with an 2x suffix. Then make or use 32x32 pixel toolbar icon images for the standard resolution images. Once you have both an 2x and standard resolution icons for each toolbutton you want to add, import those into your project.

You will also need to build for Cocoa as Carbon based windows do not support high resolution displays at all.

To do this you will need to create the toolbar by code. As of the latest release 2012 r2.1 there no built in way to do this other than by code.


-

Also note that your application will also need to add the following plist setting or it will not work.

<key>NSHighResolutionCapable</key>
<true/>

If your not on an Retina based mac, you can still test your app for retina by downloading Xcode and installing the graphic add-on package. What you need is the Quartz Debugger developer tool application. Using it allows you to test for Retina based resolutions.

The code used in this video can also be used with all other image files within an retina supported app. Such as menu icons, list box icons, segmental icons and the such. Also I have examples of using pdf vector based files with segmental controls where those files alone support retina because they are using vector based images.

All the other system controls and text are fixed by simply adding the property list key:

<key>NSHighResolutionCapable</key>
<true/>

Only Images  bitmap images require the method shown in the video.

Cheers, and happy coding.

Tuesday, February 19, 2013

Retina Based Pattern Fills with Real Studio (Xojo)


Here is an look at how to do pattern fills with Real Studio that supports both standard and high resolution displays. It is really easy.


  -

Tuesday, January 22, 2013

Key Events with Class Cocoa Controls in Real Studio (Xojo)


The coolest part of using Real Studio is access to all the controls for each platform. Some of these controls are not built-in by default but are still available to use by using declares or Plugins (Like Monkey Bread Software, Complete Plugin or the Mac OSLib (free by the way.) to name an few.). Whatever you choose its up to you.

This however can present some interesting coding challenges to add support for certain events that are available to similar built in controls. Such as the text field keydown event can use an return key to preform an action. There is no keydown event however for an non built-in control, instead one needs to get creative and figure another way around this.

Lucky enough anything is possible by code. This is an simple look at getting an NSSearchField on OSX to search on clicking the Return or Enter key press. This without an event that supports keydown or keyup events.

The reason for this video is there no documentation, I could find to tell us how to do such. It was hours of trial and error to figuring it out. However I believe such information should be shared.

Here an simple video to show how this is done. I showing this off using OSX based controls, because I currently on mac. But should be similar on other platforms.


Wednesday, January 16, 2013

Mask Numbers only with text field in Cocoa

I been finding out many things that worked in Mac Carbon builds do not actually work the same in Cocoa builds. Lucky enough there are work arounds to fix many of these items.


In Carbon if we wanted to limit numbers in an text field we could simply do this in its open event. Using an mask like such:

me.text="9999"

That mask would limit numbers only and up to 4 numbers max. However masks do not work in Cocoa at all so we need to address this in an keydown event. This quick you tube video we made shows the simple and fast work around, witch does work on all platforms, Including Cocoa builds.




 I hope this helps out, moving from carbon to fully support Cocoa. As its little things like this that can make the task of converting Older Carbon apps to Cocoa not as simple as just an recompile.

Wednesday, November 14, 2012

Installing Livecode on Linux

I had to set up an new Linux box this week and came accross that time when to Install Livecode, again. Since we been asked this question before. How to install Livecode on Linux? I figure why not do an quick 1 minute video screen how to. Hopefully someone finds this useful. If not , oh well.


Sunday, September 30, 2012

Java To Objective-C Translation

I came across an interesting little open source project today. J2ObjC which is an Java to iOS Objective-C translation tool and runtime. The tool enables Java code to be part of an iOS app. J2ObjC is an Google made tool and worth checking out. Even if just for experimentation.

More Info

Adding Borders to Images with Livecode

If your looking for an clean rect boarder within an image within Livecode you need to do so using groups. I found an great tutorial demo this off by  Jan Sckenkel of Quartam Software. Jan's example is way beyond just borders and is worth checking out.

His StyledImageView custom control article come in two parts

Part 1 StyledImageView custom control
Part 2 StyledImageView custom control(Part 2)

I suggest checking these out. It an really cool project demo with code. Great job Jan.