Shu FAQ's
- What can I do with Shu?
- Shu enables you to convert an Adobe AIR file into a standalone application. Shu also provides you with some extra commands to add to your actionscript/javascript to extend the capabilities of your application.
- Does my output application require Adobe AIR at all?
- No your Shu application is completely standalone.
- Will my Shu application work on Mac and Windows?
- Yes. You will however need access to both a PC and a Mac to create the output for each platform.
- Does the Shu application require installation?
- No your Shu application is good to go straight away.
- Can my Shu application be run from CD-ROM or network share?
- Yes.
- I have been using an swf2exe (Zinc, SWF Studio etc) tool, should I switch to Shu?
-
If you want stability and speed, Yes.
If you want your application to be cross-platform (Mac and Windows), Yes.
If you want to make use of all of Adobe AIR's features yet still have a standalone application, Yes.
If you require a standalone applcation under 5mb, No.
-
- Why are Shu applications N MB?
- Because we have to embed the AIR runtime into the application to enable it to be standalone. We don’t feel application size is such an issue on the desktop and hence as yet have not attempted to reduce the application size.
- Why are there so few commands compared to the swf2exe tools?
-
Most desktop applications use commands already available in AIR. Shu only implements common commands that that we feel are missing.
Shu also allows developers to increase application functionality by adding their own commands via an Extensions API. As such, over time, there will probably be many third party extensions available.
swf2exe applications need to add all the common commands a desktop application would need as they make use of the Adobe Flash Player which has no native desktop based commands at all.
We have focused on making Shu a robust, stable and scaleable development tool, ensuring that commands are warranted, add value and are bug free.
-
Command List
In order for these functions to be available, you need to include the Shu.swc in your AIR project.
Instructions can be found here.
Executing other applications
shu.System.exec(filename:String):Number show
shu.System.execAsync(filename:String):Number show
shu.System.isRunning(pid:Number):Boolean show
shu.System.launchFile(filename:String):Boolean show
shu.System.lastOutput:String show
Database access
shu.MySQL.connect(host:String, port:Number, user:String, pass:String, dbName:String):Boolean show
port - The port number the MySQL database is running on.
user - The username to use when connecting.
pass - The password to use when connecting.
dbName - The database to use.
shu.MySQL.disconnect():void show
shu.MySQL.runQuery(query:String):Boolean show
shu.MySQL.fetchRow():Array show
shu.MySQL.seekRow(which:Number):Boolean show
shu.MySQL.rowCount:Number show
shu.MySQL.lastError:String; show
Prompts and message boxes
shu.Dialogs.messageBox(message:String, caption:String, style:Number):Number show
caption (optional) - The caption to display in the title bar of the messagebox.
style (optional) - The buttons and icons to show. This is constructed by OR'ing the style properties :
- shu.Dialogs.MB_OK
- shu.Dialogs.MB_CANCEL
- shu.Dialogs.MB_YES_NO
- shu.Dialogs.MB_ICON_ERROR
- shu.Dialogs.MB_ICON_INFORMATION
- shu.Dialogs.MB_ICON_QUESTION
- shu.Dialogs.MB_ICON_EXCLAMATION
- shu.Dialogs.MB_OK
- shu.Dialogs.MB_CANCEL
- shu.Dialogs.MB_YES
- shu.Dialogs.MB_NO
shu.Dialogs.inputBox(message:String, caption:String, defaultValue:String):String show
caption (optional) - The text to appear in the titlebar of the dialog.
defaultValue (optional) - An initial string of text to appear in the input textfield.
Paths
These properties give you some common file system paths. Note they are all read-only.shu.Paths.app:String show
shu.Paths.desktop:String show
shu.Paths.documents:String show
shu.Paths.temp:String show
Screen
shu.Screen.capture(filename:String,left:Number,top:Number,right:Number,botton:Number):Boolean show
Note that this function either takes just the first parameter or all parameters. If only the filename is supplied, the whole screen is captured. Otherwise the area specified by left, top, right and bottom is captured. The file to save to can be either a png, jpg, tiff or bmp and will be determined by the filenames extension.
left (optional) - The leftmost position to capture.
top (optional) - The topmost position to capture.
right (optional) - The rightmost position to capture.
bottom (optional) - The bottom-most position to capture.
Extend via custom DLL/dylib
N.B. The DLL/dylib must be an shu extension (eg it must implement the extapi)shu.Extension.call(handlerName, ...):* show
... - Any other parameters to pass to the handler function.
Quick Links
Latest News
Shu application update. - 15.04.08
We have been in ongoing discussions with Adobe regarding AIR redistribution in our product Shu and in turn, redistribution in Shu output applications.
Read more
SHU site launches - 01.04.08
The long awaited launch of the world's first AIR packager application for extending AIR features.
Read more


