Index | Parent | Application class |
The Application class is the main class in RxMUI.
Any window you create must be added to an Application object.
A window can't be opened if it is not added to an Application object.
Windows may be added to an Application object during the init process via the SubWindow attribute.
The first window may be specified as
.SubWindow="win"
or
.SubWindow.0="win"
Other windows may be added during the init process as
.SubWindow.i="win"
Wwindows may also be added to an Application object via the Add() function
Your goal is usually to create a tree of objects like this:
- An Application object which contains - A Window object, with contents - a Group, called main group, which contains - various objects
See Objects handling
Attributes | |||
---|---|---|---|
Name | Type | Class | Note |
Active | B | ISGN | |
Author | S | IG | |
Base | S | IG | Should be supplied if UseARexx=1 or OwnARexx=1 |
Copyright | S | IG | |
Description | S | IG | Should be supplied if UseCommodities=1 |
DiskInserted | B | N | If you set NotifyDisk to 1 at init time, you may set up a notifycation triggered by this attribute, using Everytime as triggering values: the notification will be triggered anytime a disk is inserted |
DiskObject | S | IS | Name of an icon WITHOUT .info |
DiskRemoved | B | N | If you set NotifyDisk to 1 at init time, you may set up a notifycation triggered by this attribute, using Everytime as triggering values: the notification will be triggered anytime a disk is removed |
DoubleStart | B | GN | |
DropObject | S | S | The name of an object. Note that the attribute is only settable and that a previous call to AppMessage() must be done (or nothing will happen). |
ForceQuit | B | GN | |
HelpFile | S | ISG | |
Iconified | B | SGN | |
MenuHelp | N | GN | Notified when the user presses the help key on a menu item |
MenuStrip | S | I | |
NotifyDisk | B | I | Set this to 1 to be notified with DiskInserted (DiskRemoved) anytime a disk is inserted (removed). Note that if the Application has a commodity (that happens if you do not set UseCommodities to 0 and MUI is not in light version, i.e. not registered) that is used, otherwise a private commodity is created |
Num1 | N | ISGN | An integral user attribute, use full in situation like multiple macros project, or just as container for values |
Num2 | N | ISGN | An integral user attribute, use full in situation like multiple macros project, or just as container for values |
Num3 | N | ISGN | An integral user attribute, use full in situation like multiple macros project, or just as container for values |
OwnARexx | B | I | It is so bad that we have an ARexx port opened and we can't get messages from it.If you specify OwnARexx you get the same port that would be opened (it means BASE if SingleTask=1 BASE.X if SingleTask=0) but internal in the macro. It means that you have to handle all the commands coming to the port, MUI ones too (e.g. QUIT) |
SingleTask | B | I | |
Sleep | B | I | |
String1 | S | ISGN | A string user attribute, use full in situation like multiple macros project, or just as container for values |
String2 | S | ISGN | A string user attribute, use full in situation like multiple macros project, or just as container for values |
String3 | S | ISGN | A string user attribute, use full in situation like multiple macros project, or just as container for values |
Title | S | I | Should be supplied if UseCommodities=1 |
UseARexx | B | I | |
UsedClasses | S | I | Only usefull for MUI 4 users, a list of the used MCCs separated by a |, that will help MUI to create the Settings window. Don't include #?.mui or #?.mcp in the list, just include the #?.mcc you are going to use |
UseCommodities | B | I | |
Version | S | IG | |
WantARexxCmd | B | I | This attribute instructs the object to pass any ARexx command it receives to its port to the macro via AREXXCMD event. |
Methods | ||
---|---|---|
Name | Parameters | Note |
About | [win],[string] | Shows a little about window. win is a window object name in front of which the About window will be opened; it may be _first which means the first application opened window string is the message to show; if it is not supplied the text to show is automatically constructed. |
ABoutMUI | [win] | Shows the About MUI requester. win is a window object name in front of which the About MUI window will be opened; it may be _first which means the first application opened window. |
AboutRxMUI | [win] | Shows the About RxMUI requester. win is a window object name in front of which the ABout RxMUI window will be opened; it may be _first which means the first application opened window. |
InLine | <fun>,[attribute | TriggerAttribute] | Note |
InputBuffered | ||
Load | [file | ENV | ENVARC] | default ENV |
OpenConfigWindow | ||
Return | <string> , [attr] | Note |
ReturnID | [QUIT] | Note |
Save | [file | ENV | ENVARC] | default ENV |
SetVar | <var> | Note |
ShowHelp | [win],[file],[node],[line/N] | Show an help file, via the amigaGuide datatype. Arguments:
|
call Notify("slider",trigger,value,"app","InLine","parse arg name,value;...",attr)
When trigger changes to value, fun, an inline ARexx function macro, is called; its arguments are:
The function is called in the same process of the running macro and so in it there can be used any RxMUI functions on any object, but it is called as a separate ARexx macro and HASN'T GOT the environment of the running macro (e.g. ala INTEPRET command). It means mainly that the existing variables are not valid in the function (they just don't exist).
call Notify("WIN","CLOSEREQUEST","APP","RETURN","HELLO") call Notify("CYCLE","ACTIVE","APP","RETURN","TRIGGERATTR")
call Notify("win","CloseRequest","EveryTime","app","ReturnID","quit")
or
call Notify("button","pressed",0."app","ReturnID")
The Application will return the name of the object that triggered the notification or the special value QUIT that means the Application should be closed. Any other value is a bad one.
call Notify("CYCLE","ACTIVE","EVERYTIME","SETVAR","ACT")
act will always contain the active entry of CYCLE.