@DATABASE "OS_DevKit Extension" @INDEX "os_index.guide/main" @AUTHOR "Fromentin BRICE & Jens Vang Petersen" @node MAIN "OS_DevKit, workbench support" @toc "os_Documentation.guide/main" ___________ ___________ / /\ / /\ OS-DevKit Extension / ___ / // _______/ / Additional power for AMOS Pro V2.00+ / /\_/ / // /\_____ \/ / / // / // /\ Written by: / / // / //______ / / Fromentin BRICE / /_// / /_\_____/ / / / / // / / /__________/ //__________/ / \__________\/ \__________\/ @{b}@{u}Workbench support@{uu}@{ub} @{" Workbench controle " link "WORK"} @{" Icons & Tooltypes " link "ICON"} @{" AppItems " link "APPI"} @endnode @node APPI "OS_DevKit, workbench-AppItems support" @toc "MAIN" ___________ ___________ / /\ / /\ OS-DevKit Extension / ___ / // _______/ / Additional power for AMOS Pro V2.00+ / /\_/ / // /\_____ \/ / / // / // /\ Written by: / / // / //______ / / Fromentin BRICE / /_// / /_\_____/ / / / / // / / /__________/ //__________/ / \__________\/ \__________\/ @{b}@{u}Workbench support@{uu}@{ub} @{b}@{u}AppItems@{uu}@{ub} The AppItems are three types currently: - AppIcons - AppMenus - AppWindow The AppItems permits the drag&drop of icons, i.e, one could drag an icon on an AppWindow directly, this last will inform us of the arrival of such a event via its messages port. @{u}Commands:@{uu} @{" _app Add Icon " Link "_app add icon"} @{" _app Rem Icon " Link "_app rem icon"} @{" _app Add Menu " Link "_app add menu"} @{" _app Rem Menu " Link "_app rem menu"} @{" _app Add Wnd " Link "_app add wnd"} @{" _app Rem Wnd " Link "_app rem wnd"} You will receive an AppMessage if an AppItem receives an or several icons or if you double-click on the AppIcon, or selects the AppMenu. @{" Structure AppMessage " Link _app_msg} Here are two commands in order to extract the datas simply one 'ArgList.' @{" _arg What Str " Link "_arg What Str"} @{" _arg What Lock " Link "_arg What Lock"} @ENDNODE @NODE "_app Add Icon" @toc "APPI" _app Add Icon This function allocates and initializes an AppIcon, then sends back its pointer. APPICON=_app Add Icon(ID,USRDATA,PTXT,MSGPORT,LOCK,DSKO,TAGS) ID -> Identificateur for user. USRDATA -> User data. PTXT -> Pointer on a string whose will serves of title. MSGPORT -> Pointer of messages port receiver. LOCK -> Zero, no uses currently. DSKO -> Pointer on DiskObject (an icon). TAG -> Pointer of TAG list. @ENDNODE @NODE "_app Rem Icon" @toc "APPI" _app Rem Icon This function erases an AppIcon of the memory, and sends back TRUE if the operation succeeded. OK=_app Rem Icon(APPICON) APPICON -> Pointer of AppIcon. @ENDNODE @NODE "_app Add Menu" @toc "APPI" _app Add Menu This function allocates and initializes an AppMenu, then sends back its pointer. APPMENU=_app Add Menu(ID,USRDATA,PTXT,MSGPORT,TAGS) ID -> User Identifier. USRDATA -> User Data. PTXT -> Pointer of text for the menu. MSGPORT -> Pointer of messages port receiver. TAGS -> Pointer of TAG Lists @ENDNODE @NODE "_app Rem Menu" @toc "APPI" _app Rem Menu This function erases an AppMenu of the memory, and sends back TRUE if the operation succeeded. OK=_app Rem Menu(APPMENU) APPMENU -> Pointer of an AppMenu. @ENDNODE @NODE "_app Add Wnd" @toc "APPI" _app Add Wnd This function allocates and initializes an AppWnd, then sends back its pointer. APPWND=_app Add Menu(ID,USRDATA,WND,MSGPORT,TAGS) ID -> User Identifier. USRDATA -> User Data. WND -> Pointer of a Window. MSGPORT -> Pointer of messages port receiver. TAGS -> Pointer of TAG Lists. @ENDNODE @NODE "_app Rem Wnd" @toc "APPI" _app Rem Wnd This function erases an AppWnd of the memory, and sends back TRUE if the operation succeeded. OK=_app Rem Wnd(APPWND) APPWND -> Pointer of an AppMenu. @ENDNODE @NODE "_arg What Str" @toc "APPI" _arg What Str This function sends back the pointer on a string in one list of arguments. It sends back 0 if it strands. STR=_arg What Str(ARGLIST,NBMAX,NB) ARGLIST -> Pointer of ArgsList. NBMAX -> Number of areguments in the list. NB -> N° of arguments. From 1 to NBMAX @ENDNODE @NODE "_arg What Lock" @toc "APPI" _arg What Lock This function sends back the Lock handle in one list of arguments. It sends back 0 if it strands. LOCK=_arg What Lock(ARGLIST,NBMAX,NB) ARGLIST -> Pointer of ArgsList. NBMAX -> Number of areguments in the list. NB -> N° of arguments. From 1 to NBMAX @ENDNODE @NODE _app_msg "Structure AppMessage" @toc "APPI" Detail of the AppMessage structure. $0056 86 Taille de la structure $0000 0 20 am_Message $0014 20 2 am_Type $0016 22 4 am_UserData $001a 26 4 am_ID $001e 30 4 am_NumArgs $0022 34 4 am_ArgList $0026 38 2 am_Version $0028 40 2 am_Class $002a 42 2 am_MouseX $002c 44 2 am_MouseY $002e 46 4 am_Seconds $0032 50 4 am_Micros $0036 54 4 am_Reserved[0] @ENDNODE @node ICON "OS_DevKit, workbench-AppItems support" @toc "MAIN" ___________ ___________ / /\ / /\ OS-DevKit Extension / ___ / // _______/ / Additional power for AMOS Pro V2.00+ / /\_/ / // /\_____ \/ / / // / // /\ Written by: / / // / //______ / / Fromentin BRICE / /_// / /_\_____/ / / / / // / / /__________/ //__________/ / \__________\/ \__________\/ @{b}@{u}Workbench support@{uu}@{ub} @{b}@{u}Icons & Tooltypes@{uu}@{ub} Useless of presenting the icons for you see of it constantly. Never add of .info to the names of the icons for it is fact automatically in END OF TRANSMITTED NAME. @{" Structure DiskObject " Link _icon_struct} @{u}Easy2use Commands:@{uu} @{" _tool Get$ " link "_tool Get$"} @{" _tool Exist " link "_tool Exist"} @{" _icon Get " link "_icon Get"} @{" _icon Del " link "_icon Del"} @{" _icon Put " link "_icon Put"} @{" _tool Val Match$ " link "_tool Val Match$"} @{" _icon info " link "_icon info"} @{u}Advanced Commands:@{uu} @{" _icon Kill " Link "_icon kill"} @{" _icon Load " Link "_icon load"} @{" _icon Save " Link "_icon save"} @{" _icon Def " Link "_icon def"} @{" _icon Free " Link "_icon Free"} @{" _tool Find " Link "_tool find"} @{" _tool Match " Link "_tool match"} @ENDNODE @node "_tool Get$" @toc "ICON" _VAL$=@{b}_tool Get$@{ub} (DSKO,TOOLTYPE$) @endnode @node "_tool Exist" @toc "ICON" OK=@{b}_tool Exist@{ub} (DSKO,TOOLTYPE$) @endnode @node "_icon Get" @toc "ICON" DSKO=@{b}_icon Get@{ub} (NOM$) @endnode @node "_icon Del" @toc "ICON" OK=@{b}_icon Del@{ub} (NOM$) @endnode @node "_icon Put" @toc "ICON" OK=@{b}_icon Put@{ub} (NOM$,DSKO) @endnode @node "_tool Val Match$" @toc "ICON" IS=@{b}_tool Val Match$@{ub} (TYPE$,_VAL$) @endnode @node "_icon info" @toc "ICON" OK=@{b}_icon info@{ub} (SCR,NAME$) @endnode @NODE "_icon Kill" @toc "ICON" _icon Kill This function erases an icon of disk, and sends back TRUE if OK. OK=_icon Kill(NAME) NAME -> Pointer of name string to erase. @ENDNODE @NODE "_icon Free" @toc "ICON" _icon Free This function erases an icon (DiskObject Structure) of the memory. _icon Free DSKO DSKO -> Pointer of DiskObject structure. @ENDNODE @NODE "_icon Def" @toc "ICON" _icon Def This function allocates an icon by default of precise type, then it sends back its pointer. DSKO=_icon Def(TYPE) TYPE -> Type of icon. WBDISK = 1 WBDRAWER = 2 WBTOOL = 3 WBPROJECT = 4 WBGARBAGE = 5 WBDEVICE = 6 WBKICK = 7 WBAPPICON = 8 @ENDNODE @NODE "_icon Load" @toc "ICON" _icon Load This function loads an icon from disk and sends back its pointer. DSKO=_icon Load(NAME) NAME -> Pointer of name string. @ENDNODE @NODE "_icon Save" @toc "ICON" _icon Save This function saves an icon on the disk, and sends back TRUE if OK. OK=_icon Save(NAME,DSKO) NAME -> Pointer of name string. DSKO -> Pointer of DiskObject Structure. @ENDNODE @NODE "_tool Find" @toc "ICON" _tool Find This function seeks a ToolType among those one icon, it sends back a pointer on the string of ToolType. It sends back zero if it doesn't find anything. STR=_tool Find(DSKO,TOOL) DSKO -> Pointer of DiskObject Structure. TOOL -> Pointer of name string of ToolType. @ENDNODE @NODE "_tool Match" @toc "ICON" _tool Match This function verifies if the value of test of finds well in the string of ToolType. It manages the separators '|' automatically. If it finds the value, it will send back TRUE, otherwise FALSE. OK=_tool Match(TYPESTR,VALUE) TYPESTR -> Pointer of ToolType string. VALUE -> Pointer of string to test. @ENDNODE @NODE _icon_struct "Structure DiskObject @toc "ICON" Detail of the DiskObject structure. $004e 78 Taille de la structure $0000 0 2 do_Magic $0002 2 2 do_Version $0004 4 44 do_Gadget $0030 48 1 do_Type $0032 50 4 do_DefaultTool $0036 54 4 do_ToolTypes $003a 58 4 do_CurrentX $003e 62 4 do_CurrentY $0042 66 4 do_DrawerData $0046 70 4 do_ToolWindow $004a 74 4 do_StackSize @ENDNODE @node WORK "OS_DevKit, workbench-Workbench support" @toc "MAIN" ___________ ___________ / /\ / /\ OS-DevKit Extension / ___ / // _______/ / Additional power for AMOS Pro V2.00+ / /\_/ / // /\_____ \/ / / // / // /\ Written by: / / // / //______ / / Fromentin BRICE / /_// / /_\_____/ / / / / // / / /__________/ //__________/ / \__________\/ \__________\/ @{b}@{u}Workbench support@{uu}@{ub} @{u}Commands:@{uu} @{" _wb Open " Link "_wb Open"} @{" _wb Close " Link "_wb Close"} @{" _wb To Back " Link "_wb To Back"} @{" _wb To Front " Link "_wb To Front"} @{" _wb msg " link "_wb msg"} @endnode @NODE "_wb Open" @toc "WORK" _wb Open This function opens the WorkBench if it was previously closed. OK=_wb Open If failed, OK=False @ENDNODE @NODE "_wb Close" @toc "WORK" _wb Close This function tries to close the WorkBench. OK=_wb Close If failed, OK=False. @ENDNODE @NODE "_wb To Back" @toc "WORK" _wb To Back Without any comments. _wb To Back @ENDNODE @NODE "_wb To Front" @toc "WORK" _wb To Front Withou any comments. _wb To Front @ENDNODE @node "_wb msg" @toc "WORK" WBMSG=_@{b}_wb msg@{ub} @endnode