[ Top ] [ Modules ]
DESCRIPTION
RexxDW is an external function package that allows a Rexx programmer to write cross platform GUI applications, using a lightweight portable GUI API called Dynamic Windows (dwindows).
USAGE
The fundamental building blocks of a RexxDW program consist of two major components; widgets and event handlers or callbacks.
Various widgets are packed into the required layout and events are connected to the widgets to carry out the required behaviour.
The structure of a RexxDW program consists of various initialisation; creation of the widgets, packing them, connecting callbacks, and then calling the event loop handler to dispatch the event to the appropriate callbacks. The callbacks are normal Rexx subroutines.
There are two event loop handlers depending on whether your Rexx interpreter supports the RexxCallback() API. DW_main() is used for interpreters that have RexxCallback(); DW_main_iteration() is used for those interpretes that don't.
DERIVED FROM
All of the functions in RexxDW are based on the same function in dwindows. Some function arguments will differ due to the nature of the Rexx API interface.
The format of the function names is dw_(target)_(action)[_(options)]. eg. for tree widgets, functions act on both the tree itself and the tree items within the tree widget, so DW_tree_new() executes the "new" action on the tree widget, DW_tree_item_change() executes the "change" action on the tree item, not the tree.
Some dwindows functions are not available in RexxDW, mainly because they are not able to be implemented: dw_icon_load, etc...
A number of functions have been added to RexxDW that are not part of dwindows: dw_and, dw_or, dw_radiobutton_set, dw_radiobutton_get,...
TODO
BUGS
PORTABILITY
RexxDW runs on Windows 9x/Me/NT/2k/XP, OS/2 3.0+ and on any Un*x platform that has GTK+ 1.x installed (but works better with GTK+ 2.x).
SEE ALSO
RexxDW lives at http://rexxdw.sf.net Dynamic Windows lives at http://dwindows.netlabs.org
[ Top ] [ Modules ]
DESCRIPTION
The following "constants" are defined when RexxDW starts. By default, all constants are stored in an array with the stem preset to !REXXDW.! This can be changed by using the 'CONSTANTPREFIX' value of DW_variable(). If you use "Procedure" on your labels, you MUST "EXPOSE !REXXDW." or the stem you set with DW_variable() will not be visible. To reference the constants defined below, you must prefix them. So the "constant" DW_DESKTOP would be, by default, referenced in your code as !REXXDW.!DW_DESKTOP.
SEE ALSO
[ Top ] [ Constants ] [ Definitions ]
NAME
MiscellaneousFlags
DESCRIPTION
The following is a list of miscellaneous flags.
ATTRIBUTES
[ Top ] [ Constants ] [ Definitions ]
NAME
FileDialogFlags
DESCRIPTION
The following is a list of the pre-defined flags that are used in a call to DW_file_browse() to determine the dialog type displayted.
ATTRIBUTES
SEE ALSO
[ Top ] [ Constants ] [ Definitions ]
NAME
ContainerScrollFlags
DESCRIPTION
The following is a list of the pre-defined flags that are used in a call to DW_container_scroll() to indicate the direction of scrolling.
ATTRIBUTES
SEE ALSO
[ Top ] [ Constants ] [ Definitions ]
NAME
TextAttributeFlags
DESCRIPTION
The following is a list of the pre-defined flags that are used in a call to DW_window_set_style() to specify the formatting of text within a widget.
ATTRIBUTES
The following work on all platforms:
- DW_DT_LEFT - text is left-aligned
- DW_DT_RIGHT - text is right-aligned
- DW_DT_CENTER - text is centered
- DW_DT_VCENTER - text is centered vertically
The following attributes only have an effect on OS/2:
- DW_DT_QUERYEXTENT
- DW_DT_UNDERSCORE
- DW_DT_STRIKEOUT
- DW_DT_TEXTATTRS
- DW_DT_EXTERNALLEADING
- DW_DT_TOP
- DW_DT_BOTTOM
- DW_DT_HALFTONE
- DW_DT_MNEMONIC
- DW_DT_WORDBREAK
- DW_DT_ERASERECT
SEE ALSO
[ Top ] [ Constants ] [ Definitions ]
NAME
WindowStyleFlags
DESCRIPTION
The following is a list of the pre-defined flags that can be used when creating a new window. Any number of values from "Style Types" can be used plus optionally one value from "Initial State Types" are logically "or"ed together using DW_or().
ATTRIBUTES
Style Types:
- DW_FCF_TITLEBAR - display titlebar
- DW_FCF_SYSMENU
- DW_FCF_MENU
- DW_FCF_SIZEBORDER
- DW_FCF_MINBUTTON - display minimise button
- DW_FCF_MAXBUTTON - display maximise button
- DW_FCF_MINMAX
- DW_FCF_VERTSCROLL
- DW_FCF_HORZSCROLL
- DW_FCF_DLGBORDER
- DW_FCF_BORDER
- DW_FCF_SHELLPOSITION
- DW_FCF_TASKLIST
- DW_FCF_NOBYTEALIGN
- DW_FCF_NOMOVEWITHOWNER
- DW_FCF_SYSMODAL
- DW_FCF_HIDEBUTTON
- DW_FCF_HIDEMAX
- DW_FCF_AUTOICON
Initial State Types:
- DW_FCF_MAXIMIZE - start maximised
- DW_FCF_MINIMIZE - start minimised
SEE ALSO
[ Top ] [ Constants ] [ Definitions ]
NAME
ContainerColumnFlags
DESCRIPTION
The following is a list of the pre-defined flags that can be used when creating a container widget. When used in DW_container_setup() or DW_filesystem_setup(), one value from "Column Types", one value from "Alignment" and any value from "Separators" are logically "or"ed together using DW_or().
ATTRIBUTES
Column Types:
- DW_CFA_BITMAPORICON - the column contains an image
- DW_CFA_STRING - the column contains an unstructured string
- DW_CFA_ULONG - the column contains an integer
- DW_CFA_TIME - the column contains a time in the format Time('N')
- DW_CFA_DATE - the column contains a date in the format Date('S')
- DW_CFA_STRINGANDICON - the column contains a string and an image (not implemented)
Alignment:
- DW_CFA_CENTER - the column is centered
- DW_CFA_LEFT - the column is left aligned
- DW_CFA_RIGHT - the column is right aligned
Separators (not applicable on all platforms):
- DW_CFA_HORZSEPARATOR - the column has a cell border on the top and bottom
- DW_CFA_SEPARATOR - the column has a cell border on the left and right
SEE ALSO
DW_container_setup, DW_filesystem_setup
[ Top ] [ Constants ] [ Definitions ]
NAME
ContainerQueryFlags
DESCRIPTION
The following is a list of the pre-defined flags that can be used when querying a container widget.
ATTRIBUTES
SEE ALSO
DW_container_query_start, DW_container_query_next
[ Top ] [ Constants ] [ Definitions ]
NAME
MLESearchFlags
DESCRIPTION
The following is a list of the pre-defined flags that can be used in the SearchFlags argument in DW_mle_search().
ATTRIBUTES
SEE ALSO
[ Top ] [ Constants ] [ Definitions ]
NAME
MLEEditableFlags
DESCRIPTION
The following is a list of the pre-defined flags that can be used in the EditableFlags argument in DW_mle_set_editable().
ATTRIBUTES
SEE ALSO
[ Top ] [ Constants ] [ Definitions ]
NAME
MLEWordWrapFlags
DESCRIPTION
The following is a list of the pre-defined flags that can be used in the WordWrapFlags argument in DW_mle_set_word_wrap().
ATTRIBUTES
SEE ALSO
[ Top ] [ Constants ] [ Definitions ]
NAME
PointerTypes
DESCRIPTION
The following is a list of the pre-defined mouse pointer types used in the Pointer argument in DW_window-set_pointer().
ATTRIBUTES
SEE ALSO
[ Top ] [ Constants ] [ Definitions ]
NAME
Colours
DESCRIPTION
The following is a list of the pre-defined colours known to RexxDW. These colour constants are used in functions that require pre-defined colours.
ATTRIBUTES
SEE ALSO
DW_color_background_set, DW_color_foreground_set, DW_color_choose
[ Top ] [ Constants ] [ Definitions ]
NAME
WidgetOrientation
DESCRIPTION
The following constants are used in widgets that require an orientation to be specified.
ATTRIBUTES
SEE ALSO
DW_box_new, DW_groupbox_new, DW_splitbar_new, DW_scrollbar_new
[ Top ] [ Constants ] [ Definitions ]
NAME
NotebookTabLocation
DESCRIPTION
The following constants are used in the TabLocation argument in a call to DW_notebook_new() to specify whether notebook tabs are located at the top or bottom of the window.
ATTRIBUTES
SEE ALSO
[ Top ] [ Constants ] [ Definitions ]
NAME
NotebookPageLocation
DESCRIPTION
The following constants are used in the PageLocation argument in a call to DW_notebook_page_new() to specify if the page is created in front or behind other pages.
ATTRIBUTES
SEE ALSO
[ Top ] [ Constants ] [ Definitions ]
NAME
MenuConstants
DESCRIPTION
The following constants are used in a number of menu related function calls.
ATTRIBUTES
SEE ALSO
DW_menu_append_item, DW_menu_item_set_check
[ Top ] [ Constants ] [ Definitions ]
NAME
BoxExpansionFlags
DESCRIPTION
The following constants are used in the box packing functions to specify whether the box expand in a horizontal or vertical direction.
ATTRIBUTES
SEE ALSO
DW_box_pack_start, DW_box_pack_end
[ Top ] [ Constants ] [ Definitions ]
NAME
ListboxSelection
DESCRIPTION
The following constants are used in the Selection argument to a call to DW_listbox_new().
ATTRIBUTES
SEE ALSO
[ Top ] [ Constants ] [ Definitions ]
NAME
ListboxSelected
DESCRIPTION
The following is a list of the pre-defined flags that can be used when setting the State of a listbox or combobox.
ATTRIBUTES
SEE ALSO
[ Top ] [ Constants ] [ Definitions ]
NAME
ListboxReturn
DESCRIPTION
The following is the return value from DW_listbox_selected() or DW_listbox_selected_multi() if no item in the listbox has been selected.
ATTRIBUTES
SEE ALSO
DW_listbox_selected(), DW_listbox_selected_multi()
[ Top ] [ Constants ] [ Definitions ]
NAME
WidgetChecked
DESCRIPTION
The following constants are used to indicate the state of a widget that can have a boolean state.
ATTRIBUTES
SEE ALSO
DW_checkbox_set, DW_radiobutton_set
[ Top ] [ Constants ] [ Definitions ]
NAME
ContainerClearFlags
DESCRIPTION
The following constants are used in the Redraw argument to a call to DW_container_clear().
ATTRIBUTES
SEE ALSO
[ Top ] [ Constants ] [ Definitions ]
NAME
ContainerSelection
DESCRIPTION
The following constants are used in the Selection argument to a call to DW_container_new().
ATTRIBUTES
SEE ALSO
[ Top ] [ Constants ] [ Definitions ]
NAME
RectangleFill
DESCRIPTION
The following constants are used in the Fill argument to a call to DW_draw_rect().
ATTRIBUTES
SEE ALSO
[ Top ] [ Constants ] [ Definitions ]
NAME
MessageboxFlags
DESCRIPTION
The following constants are used in the Flags argument to a call to DW_messagebox(). Logically "or" one value from Buttons and one value from Icons
ATTRIBUTES
Buttons:
- DW_MB_OK
- DW_MB_OKCANCEL
- DW_MB_YESNO
- DW_MB_YESNOCANCEL
Icons:
- DW_MB_WARNING
- DW_MB_ERROR
- DW_MB_INFORMATION
- DW_MB_QUESTION
SEE ALSO
[ Top ] [ Constants ] [ Definitions ]
NAME
MessageboxResults
DESCRIPTION
The following constants are returned from a call to DW_messagebox().
ATTRIBUTES
SEE ALSO
[ Top ] [ Constants ] [ Definitions ]
NAME
VirtualKeys
DESCRIPTION
The following is a list of the mnemonic key values known to RexxDW. These keys are returned in a KeyPressEvent Callback, in the VirtualKey argument.
ATTRIBUTES
SEE ALSO
[ Top ] [ Constants ] [ Definitions ]
NAME
KeyStates
DESCRIPTION
The following is a list of the mnemonic key state values known to Rexx/DW. These keys are returned in a KeyPressEvent Callback, in the KeyState argument.
ATTRIBUTES
SEE ALSO
[ Top ] [ Constants ] [ Definitions ]
NAME
MouseButtons
DESCRIPTION
The following is a list of the mnemonic mouse button values known to RexxDW. These buttons are returned in a ButtonPressEvent Callback, in the Button argument.
ATTRIBUTES
SEE ALSO
ButtonPressEventCallback ButtonReleaseEventCallback
[ Top ] [ Modules ]
NAME
Fontnames
DESCRIPTION
Font names in Rexx/DW are platform dependent. This section explains how to specify fonts on each of the supported platforms.
NOTES
Windows:
Fonts are specifed in the format: 'size.family [Bold] [Italic]'
As an example, the following specify various font specifications for 8 point
Courier:
fixedfont = '8.Courier'
italicfont = '8.Courier Italic'
boldfont = '8.Courier Bold'
bolditalicfont = '8.Courier Bold Italic'
GTK+ 2.x:
Fonts are specified in the format: 'family [bold] [italic] size'
As an example, the following specify various font specifications for 14 point
monospace:
fixedfont = 'monospace 14'
italicfont = 'monospace italic 14'
boldfont = 'monospace bold italic 14'
bolditalicfont = 'monospace italic 14'
GTK+ 1.x:
Fonts are specified using full X11 specification.
As an example, the following specify various font specifications for 120
courier:
fixedfont = '-adobe-courier-medium-r-normal-*-*-120-*-*-m-*-iso8859-1'
italicfont = '-adobe-courier-medium-o-normal-*-*-120-*-*-m-*-iso8859-1'
boldfont = '-adobe-courier-bold-r-normal-*-*-120-*-*-m-*-iso8859-1'
bolditalicfont = '-adobe-courier-bold-o-normal-*-*-120-*-*-m-*-iso8859-1'
OS/2:
Fonts are specifed in the format: 'size.family [Bold] [Italic]'
As an example, the following specify various font specifications for 5
System VIO:
fixedfont = '5.System VIO'
italicfont = '5.System VIO Italic'
boldfont = '5.System VIO Bold'
bolditalicfont = '5.System VIO Bold Italic'
[ Top ] [ Modules ]
NAME
Packing
DESCRIPTION
One of the most important aspects of laying out widgets in a Rexx/DW program is how packing works. This section explains the Rexx/DW packing mechanism.
NOTES
The above ?????? TODO - horz/vert boxes, pack empty spaces, expand/dont_expand
[ Top ] [ Modules ]
NAME
Callbacks
DESCRIPTION
Rexx/DW is an event driven application. What this means is that internally various events occur, such as a key press, a window becoming exposed. Rexx/DW allows you to call an internal Rexx procedure when various events occur.
Each widget you create has certain valid events associated with it. As part of your code you associate a particular event with a widget. This is done by calling DW_signal_connect(). This associates an event on a particular widget with an internal Rexx procedure, so that when the particular event occurs on that widget your procedure is executed and certain parameters are passed to it. Details on what parameters are passed is detailed below depending on the type of event.
The internal Rexx procedure is called in the context of where DW_main() or DW_main_iteration() is called. This is important when considering what Rexx variables may or may not be in scope. It is probably better to always use PROCEDURE EXPOSE (myglobals) on procedures so you know that any variables you use within your procedure will not affect an others outside without you explicitly listing them.
Once you have handled an event in your code, you can return 1 to inform Dynamic Windows that all processing has been handled for the particular event. Dynamic Windows will not execute its default event handling code. If your event handler returns 0, then Dynamic Windows will execute its default event handling code.
ATTRIBUTES
The values of the supported events are:
NOTES
With Rexx interpreters that don't provide RexxCallBack() it is not possible to inform Dynamic Windows to execute the default callback functionality after your event handler has executed its code, because the return value is returned to the Rexx program; via DW_main_iteration(), not to Dynamic Windows.
[ Top ] [ Callbacks ] [ Generics ]
NAME
ConfigureEventCallback
USAGE
rcode = ConfigureEventCallback(Window, Width, Height [,UserData[,...]])
DESCRIPTION
Called when a DW_CONFIGURE_EVENT signal fires on a window. This event usually occurs when a window's size is changed.
ARGUMENTS
RETURN VALUE
Return 1 to ensure that the default callback is not called. Return 0 to enable the default callback to be called.
SOURCE
... Call dw_signal_connect window, !REXXDW.!DW_CONFIGURE_EVENT, 'configure_cb', , 'fred', 'mary' ... configure_cb: Procedure Expose !REXXDW. Parse Arg win, width, height, var1, var2 Say 'New width:' width 'height:' height 'for Window:' win 'UserVar1:' var1 , 'UserVar2:' var2 Return 1
[ Top ] [ Callbacks ] [ Generics ]
NAME
KeyPressEventCallback
USAGE
rcode = KeyPressEventCallback(Window, ASCIIKey, VirtualKey, KeyState [,UserData[,...]])
DESCRIPTION
Called when a DW_KEY_PRESS_EVENT signal fires on a window. Occurs when the user presses a key.
ARGUMENTS
RETURN VALUE
Return 1 to ensure that the default callback is not called. Return 0 to enable the default callback to be called.
SEE ALSO
SOURCE
... Call dw_signal_connect window, !REXXDW.!DW_KEY_PRESS_EVENT, 'keypress_cb', , 'fred', 'mary' ... keypress_cb: Procedure Expose !REXXDW. Parse Arg win, ascii, virtual, state, var1, var2 Say 'ASCII Key:' ascii 'Virtual Key:' virtual 'State:' state 'UserVar1:' , var1 'UserVar2:' var2 If virtual = !REXXDW.!DW_VK_F1 Then Return 1 Return 1
[ Top ] [ Callbacks ] [ Generics ]
NAME
ButtonPressEventCallback
USAGE
rcode = ButtonPressEventCallback(Window, X, Y, Button [,UserData[,...]])
DESCRIPTION
Called when a DW_BUTTON_PRESS_EVENT signal fires on a window. This occurs when the user clicks a button with the mouse.
ARGUMENTS
RETURN VALUE
Return 1 to ensure that the default callback is not called. Return 0 to enable the default callback to be called.
SEE ALSO
SOURCE
... Call dw_signal_connect window, !REXXDW.!DW_BUTTON_PRESS_EVENT, , 'buttonpress_cb', 'fred' ... buttonpress_cb: Parse Arg win, x, y, button, data Say 'Button:' button 'pressed at:' x'/'y 'in Window:' win Return 1
[ Top ] [ Callbacks ] [ Generics ]
NAME
ButtonReleaseEventCallback
USAGE
rcode = ButtonReleaseEventCallback(Window, X, Y, Button [,UserData[,...]])
DESCRIPTION
Called when a DW_BUTTON_RELEASE_EVENT signal fires on a window. This occurs when the user releases a button on the mouse.
ARGUMENTS
RETURN VALUE
Return 1 to ensure that the default callback is not called. Return 0 to enable the default callback to be called.
SEE ALSO
SOURCE
... Call dw_signal_connect window, !REXXDW.!DW_BUTTON_RELEASE_EVENT, , 'buttonrelease_cb', 'fred' ... buttonreleases_cb: Parse Arg win, x, y, button, data Say 'Button:' button 'released at:' x'/'y 'in Window:' win Return 1
[ Top ] [ Callbacks ] [ Generics ]
NAME
MotionNotifyEventCallback
USAGE
rcode = MotionNotifyEventCallback(Window, X, Y, Button [,UserData[,...]])
DESCRIPTION
Called when a DW_MOTION_NOTIFY_EVENT signal fires on a window. This occurs when the user moves the mouse.
ARGUMENTS
RETURN VALUE
Return 1 to ensure that the default callback is not called. Return 0 to enable the default callback to be called.
SEE ALSO
ButtonPressEventCallback ButtonReleaseEventCallback
SOURCE
... Call dw_signal_connect window, !REXXDW.!DW_MOTION_NOTIFY_EVENT, , 'motionnotify_cb', 'fred' ... motionnotify_cb: Parse Arg win, x, y, state, data Say 'Mouse movied to' x'/'y 'in Window:' win 'with state:' state Return 1
[ Top ] [ Callbacks ] [ Generics ]
NAME
DeleteEventCallback
USAGE
rcode = DeleteEventCallback(Window [,UserData[,...]])
DESCRIPTION
Called when a DW_DELETE_EVENT signal fires on a window. This occurs when the user closes the window by clicking the close icon on the window title bar, or when dw_window_destroy() ???? is called on the window.
ARGUMENTS
RETURN VALUE
Return 1 to ensure that the default callback is not called. Return 0 to enable the default callback to be called.
SEE ALSO
SOURCE
... Call dw_signal_connect window, !REXXDW.!DW_DELETE_EVENT, 'delete_cb', , 'fred' ... delete_cb: Parse Arg win, data Say 'Window:' win 'deleted' Return 1
[ Top ] [ Callbacks ] [ Generics ]
NAME
ExposeEventCallback
USAGE
rcode = ExposeEventCallback(Window, X, Y, Width, Height [,UserData[,...]])
DESCRIPTION
Called when a DW_EXPOSE_EVENT signal fires on a window. This occurs when the window is exposed.
ARGUMENTS
RETURN VALUE
Return 1 to ensure that the default callback is not called. Return 0 to enable the default callback to be called.
SOURCE
... Call dw_signal_connect window, !REXXDW.!DW_EXPOSE_EVENT, 'expose_cb', , 'fred' ... expose_cb: Parse Arg win, x, y, width, height, data Say 'Window:' win 'exposed at' x'/'y 'size:' width'/'height Return 1
[ Top ] [ Callbacks ] [ Generics ]
NAME
ClickedEventCallback
USAGE
rcode = ClickedEventCallback(Window [,UserData[,...]])
DESCRIPTION
Called when a DW_CLICKED_EVENT signal fires on a window. This occurs when the user clicks in the window; usually a button window.
ARGUMENTS
RETURN VALUE
Return 1 to ensure that the default callback is not called. Return 0 to enable the default callback to be called.
SOURCE
... Call dw_signal_connect window, !REXXDW.!DW_CLICKED_EVENT, 'clicked_cb', , 'fred' ... clicked_cb: Parse Arg win, data Say 'Window:' win 'clicked' Return 1
[ Top ] [ Callbacks ] [ Generics ]
NAME
ItemEnterEventCallback
USAGE
rcode = ItemEnterEventCallback(Window, Text [,UserData[,...]])
DESCRIPTION
Called when a DW_ITEM_ENTER_EVENT signal fires on a window. This occurs when the user double-clicks or presses ENTER key in a container window.
ARGUMENTS
RETURN VALUE
Return 1 to ensure that the default callback is not called. Return 0 to enable the default callback to be called.
SEE ALSO
SOURCE
... Call dw_signal_connect window, !REXXDW.!DW_ITEM_ENTER_EVENT, 'itementer_cb', , 'fred' ... itementer_cb: Parse Arg win, text, data Say 'Item text' text 'entered in Window:' win 'userdata:' data Return 1
[ Top ] [ Callbacks ] [ Generics ]
NAME
ItemContextEventCallback
USAGE
rcode = ItemContextEventCallback(Window, Text, X, Y, ItemData [,UserData[,...]])
DESCRIPTION
Called when a DW_ITEM_CONTEXT_EVENT signal fires on a window. This occurs when the user clicks the right mouse button in a container or tree window.
ARGUMENTS
RETURN VALUE
Return 1 to ensure that the default callback is not called. Return 0 to enable the default callback to be called.
SEE ALSO
DW_container_set_row_title, DW_tree_item_change
NOTES
When connecting this signal to a Tree widget, DW_signal_connect() MUST be called BEFORE the Tree is populated. When connecting this signal to a Container widget, DW_signal_connect() MUST be called AFTER the Container is populated.
SOURCE
... Call dw_signal_connect window, !REXXDW.!DW_ITEM_CONTEXT_EVENT, , 'itemcontext_cb', 'fred' ... itemcontext_cb: Parse Arg win, text, x, y, itemdata, userdata Say 'Item text' text 'entered in Window:' win 'at' x'/'y 'userdata:' userdata Return 1
[ Top ] [ Callbacks ] [ Generics ]
NAME
ListSelectEventCallback
USAGE
rcode = ListSelectEventCallback(Window, Item [,UserData[,...]])
DESCRIPTION
Called when a DW_LIST_SELECT_EVENT signal fires on a window. This occurs when the user clicks an entry in a listbox or combobox; ie an item in a list is selected.
ARGUMENTS
RETURN VALUE
Return 1 to ensure that the default callback is not called. Return 0 to enable the default callback to be called.
SOURCE
... Call dw_signal_connect window, !REXXDW.!DW_LIST_SELECT_EVENT, , 'listselect_cb', 'fred' ... listselect_cb: Parse Arg win, item, userdata Say 'Item number' item 'selected in Window:' win 'userdata:' userdata Return 1
[ Top ] [ Callbacks ] [ Generics ]
NAME
ItemSelectEventCallback
USAGE
rcode = ItemSelectEventCallback(Window, Item, Text, Itemdata [,UserData[,...]])
DESCRIPTION
Called when a DW_ITEM_SELECT_EVENT signal fires on a window. This occurs when the user clicks the left button on an item in a container or tree window. selected.
ARGUMENTS
RETURN VALUE
Return 1 to ensure that the default callback is not called. Return 0 to enable the default callback to be called.
NOTES
When connecting this signal to a Tree widget, DW_signal_connect() MUST be called BEFORE the Tree is populated otherwise the signal will never fire. When connecting this signal to a Container widget, DW_signal_connect() MUST be called AFTER the Container is populated.
SOURCE
... Call dw_signal_connect window, !REXXDW.!DW_ITEM_SELECT_EVENT, , 'itemselect_cb', 'fred' ... itemselect_cb: Parse Arg win, item, text, userdata Say 'Item number' item 'selected in Window:' win 'text is:' text , 'userdata:' userdata Return 1
[ Top ] [ Callbacks ] [ Generics ]
NAME
SetFocusEventCallback
USAGE
rcode = SetFocusEventCallback(Window [,UserData[,...]])
DESCRIPTION
Called when a DW_SET_FOCUS_EVENT signal fires on a window. This occurs when the user gives focus to a window, either by clicking the left button in the window or by tabbing to the window. selected.
ARGUMENTS
RETURN VALUE
Return 1 to ensure that the default callback is not called. Return 0 to enable the default callback to be called.
SOURCE
... Call dw_signal_connect window, !REXXDW.!DW_SET_FOCUS_EVENT, 'setfocus_cb', , 'fred' ... setfocus_cb: Parse Arg win, userdata Say 'Window:' win 'now has focus userdata:' userdata Return 1
[ Top ] [ Callbacks ] [ Generics ]
NAME
ValueChangedEventCallback
USAGE
rcode = ValueChangedEventCallback(Window, Value [,UserData[,...]])
DESCRIPTION
Called when a DW_VALUE_CHANGED_EVENT signal fires on a window. This occurs when the user adjusts a scrollbar, or a slider control.
ARGUMENTS
RETURN VALUE
Return 1 to ensure that the default callback is not called. Return 0 to enable the default callback to be called.
SEE ALSO
DW_scrollbar_set_range, DW_slider_set_pos
SOURCE
... Call dw_signal_connect window, !REXXDW.!DW_VALUE_CHANGED_EVENT, , 'valuechanged_cb', 'fred' ... valuechanged_cb: Parse Arg win, val, userdata Say 'The top of the scrollbar thumb is now' val 'in Window:' win , 'userdata:' userdata Return 1
[ Top ] [ Callbacks ] [ Generics ]
NAME
SwitchPageEventCallback
USAGE
rcode = SwitchPageEventCallback(Window, Page [,UserData[,...]])
DESCRIPTION
Called when a DW_SWITCH_PAGE_EVENT signal fires on a window. This occurs when the user clicks on a tab in a notebook.
ARGUMENTS
RETURN VALUE
Return 1 to ensure that the default callback is not called. Return 0 to enable the default callback to be called.
SOURCE
... Call dw_signal_connect window, !REXXDW.!DW_SWITCH_PAGE_EVENT, , 'switchpage_cb', 'fred' ... switchpage_cb: Parse Arg win, page, userdata Say 'Page' page 'of Window:' win 'selected. userdata:' userdata Return 1
[ Top ] [ Callbacks ] [ Generics ]
NAME
ColumnClickEventCallback
USAGE
rcode = ColumnClickEventCallback(Window, Column [,UserData[,...]])
DESCRIPTION
Called when a DW_COLUMN_CLICK_EVENT signal fires on a window. This occurs when the user clicks on a column heading of a container window. selected.
ARGUMENTS
RETURN VALUE
Return 1 to ensure that the default callback is not called. Return 0 to enable the default callback to be called.
SOURCE
... Call dw_signal_connect window, !REXXDW.!DW_COLUMN_CLICK_EVENT, , 'columnclick_cb', 'fred' ... columnclick_cb: Parse Arg win, column, userdata Say 'Column' column 'of Window:' win 'selected. userdata:' userdata Return 1
[ Top ] [ Callbacks ] [ Generics ]
NAME
TimerEventCallback
USAGE
rcode = TimerEventCallback([UserData[,...]])
DESCRIPTION
Called when a generic timer goes off. This occurs after the period specified by DW_timer_connect(). selected.
ARGUMENTS
RETURN VALUE
Return 1 to ensure that the timer is rearmed. Return 0 to ensure that the timer is not rearmed.
NOTES
The return code from the function called as a result of the timer firing determines whether the timer continues to fire after the specified period.
SEE ALSO
SOURCE
... Call dw_timer_connect window, 5000, 'timer_cb', 'fred' ... timer_cb: Parse Arg userdata Say 'Our timer went off after 5 seconds' 'userdata:' userdata Return 1
[ Top ] [ Modules ]
DESCRIPTION
The following external functions comprise Rexx/DW.
[ Top ] [ Functions ] [ Modules ]
DESCRIPTION
Widgets are the fundamental display items in RexxDW. RexxDW supports a range of widgets to enable a rich GUI interface for your Rexx programs.
NOTES
RexxDW supports all common widget types as follows:
box
button
checkbox/radiobutton
container/filesystem
dialog
rendering
entryfield
listbox/combobox
menu
multiline edit
notebook
percent
scrollbar
slider
spinbutton
splitbar
text
tree
window
[ Top ] [ Widgets ] [ Modules ]
DESCRIPTION
Boxes are used to layout the GUI display. Widgets are packed into a box to position that widget. A box can be horizontal or vertical, which determines the arrangement of the widgets packed into the box. So to arrange two widgets side-by-side, you would create a horizontal box, your two widgets, and pack those two widgets into the box and they appear beside each other.
NAME
DW_box_new
SYNOPSIS
win = dw_box_new( Orientation )
FUNCTION
Creates a new generic box window. A box is the basic widget for arranging the location and position of other widgets.
ARGUMENTS
RESULT
A window identifier.
SEE ALSO
DW_groupbox_new, WidgetOrientation
NOTES
The orientation of a box determines the orientation of the widgets that are packed into this box. Creating a horizontal box and packing two buttons into it will result in the two buttons being placed side by side.
SOURCE
... box = dw_box_new( !REXXDW.!DW_VERT ) Call dw_box_pack_start win, box, 0, 0, !REXXDW.!DW_EXPAND_HORZ, , !REXXDW.!DW_EXPAND_VERT, 0
NAME
DW_groupbox_new
SYNOPSIS
win = dw_groupbox_new( Orientation, Title )
FUNCTION
Creates a new generic groupbox window. A box is the basic widget for arranging the location and position of other widgets. The difference between a box and a groupbox is that a groupbox contains a border and a Title in the top left corner.
ARGUMENTS
RESULT
A window identifier.
SEE ALSO
NOTES
The orientation of a box determines the orientation of the widgets that are packed into this box. Creating a horizontal box and packing two buttons into it will result in the two buttons being placed side by side.
SOURCE
... box = dw_groupbox_new( !REXXDW.!DW_VERT, 'Editor' ) Call dw_box_pack_start win, box, 0, 0, !REXXDW.!DW_EXPAND_HORZ, , !REXXDW.!DW_EXPAND_VERT, 0
NAME
DW_box_pack_start
SYNOPSIS
dw_box_pack_start( ParentBox, BoxToPack, BoxWidth, BoxHeight, HorzExpand, VertExpand, Padding )
FUNCTION
Packs the BoxToPack at the start of the ParentBox; ie at the left of a horizontal ParentBox, or the top of a vertical ParentBox. The height and width of the box can be specified as is the ability to allow the box to expand horizontally or vertically.
ARGUMENTS
RESULT
No return result.
SEE ALSO
NOTES
The BoxToPack argument can be 0, which will result in empty space being packed.
SOURCE
... button = dw_bitmapbutton_new_from_file( 'Quit', 0, 'quit' ) Call dw_box_pack_start win, button, 0, 32, !REXXDW.!DW_EXPAND_HORZ, , !REXXDW.!DW_DONT_EXPAND_VERT, 0
NAME
DW_box_pack_end
SYNOPSIS
dw_box_pack_end( ParentBox, BoxToPack, BoxWidth, BoxHeight, HorzExpand, VertExpand, Padding )
FUNCTION
Packs the BoxToPack at the end of the ParentBox; ie at the right of a horizontal ParentBox, or the bottom of a vertical ParentBox. The height and width of the box can be specified as is the ability to allow the box to expand horizontally or vertically.
ARGUMENTS
RESULT
No return result.
SEE ALSO
NOTES
The BoxToPack argument can be 0, which will result in empty space being packed.
SOURCE
... button = dw_bitmapbutton_new_from_file( 'Quit', 0, 'quit' ) Call dw_box_pack_end win, button, 0, 32, !REXXDW.!DW_EXPAND_HORZ, , !REXXDW.!DW_DONT_EXPAND_VERT, 0
[ Top ] [ Widgets ] [ Modules ]
DESCRIPTION
Buttons enable an action to be carried out by the user clicking the left mouse button on the widget. RexxDW supports two types of button; plain text buttons and bitmap buttons.
[ Top ] [ Button ] [ Functions ]
NAME
DW_button_new
SYNOPSIS
win = dw_button_new( ButtonText, Id )
FUNCTION
Creates a new text button. A button is a widget which contains text and can be clicked to execute some action.
ARGUMENTS
RESULT
A window identifier.
SEE ALSO
SOURCE
... button = dw_button_new( "Quit", 10 )
[ Top ] [ Button ] [ Functions ]
NAME
DW_bitmapbutton_new_from_file
SYNOPSIS
win = dw_bitmapbutton_new_from_file( BubbleText, Id, Filename )
FUNCTION
Creates a new button window using a bitmap image.
ARGUMENTS
RESULT
A window identifier.
SEE ALSO
SOURCE
... button = dw_bitmapbutton_new_from_file( 'Quit', 0, 'quit' ) Call dw_box_pack_start win, button, 32, 32, !REXXDW.!DW_DONT_EXPAND_HORZ, , !REXXDW.!DW_DONT_EXPAND_VERT, 0
[ Top ] [ Widgets ] [ Modules ]
DESCRIPTION
The Calendar widget displays a month calendar from which the user can select a date.
[ Top ] [ Calendar ] [ Functions ]
NAME
DW_calendar_new
SYNOPSIS
win = dw_calendar_new( Id )
FUNCTION
Creates a new calendar. A calendar is a widget which allows the user to select a date.
ARGUMENTS
RESULT
A window identifier.
SEE ALSO
DW_calendar_get_date, DW_calendar_set_date
NOTES
On OS/2 this is a dummy text widget. On GTK, only 1 month is ever displayed. On Windows, more than 1 month is displayed depending on whether the widget is packed with expanding on.
SOURCE
... calendar = dw_calendar_new( 10 )
[ Top ] [ Calendar ] [ Functions ]
NAME
DW_calendar_get_date
SYNOPSIS
date = dw_calendar_get_date( Win )
FUNCTION
Gets the selected date of the widget.
ARGUMENTS
RESULT
The date selected in Rexx's DATE('S') format.
SEE ALSO
DW_calendar_new, DW_calendar_set_date
SOURCE
... calendar = dw_calendar_new( 10 ) ... date = dw_calendar_get_date( calendar )
[ Top ] [ Calendar ] [ Functions ]
NAME
DW_calendar_set_date
SYNOPSIS
dw_calendar_set_date( Win, Date )
FUNCTION
Sets the date for the widget.
ARGUMENTS
RESULT
None
SEE ALSO
DW_calendar_new, DW_calendar_get_date
SOURCE
... calendar = dw_calendar_new( 10 ) ... date = dw_calendar_set_date( calendar, Date( 'S' ) )
[ Top ] [ Widgets ] [ Modules ]
DESCRIPTION
Checkboxes provide a simple mechanism for a user to indicate a boolean value response. Radiobuttons provide the user with a means to choose from a list of options.
[ Top ] [ CheckboxAndRadiobutton ] [ Functions ]
NAME
DW_checkbox_new
SYNOPSIS
win = dw_checkbox_new( CheckboxText, Id )
FUNCTION
Creates a new checkbox. A checkbox is a widget that allows for a boolean value to be set. It contains text to describe the boolean value being set.
ARGUMENTS
RESULT
A window identifier.
SEE ALSO
DW_checkbox_get, DW_checkbox_set
SOURCE
... checkbox = dw_checkbox_new( "Allow user to delete", 0 )
[ Top ] [ CheckboxAndRadiobutton ] [ Functions ]
NAME
DW_radiobutton_new
SYNOPSIS
win = dw_radiobutton_new( ButtonText, Id )
FUNCTION
Creates a new radiobutton. A radiobutton is a widget that allows for one of a number of values to be set. It contains text to describe the value being set. A number of radiobuttons are created together with one of them set at any point in time.
ARGUMENTS
RESULT
A window identifier.
SEE ALSO
DW_checkbox_new, DW_groupbox_new
NOTES
For radiobuttons to work properly, all radiobuttons that are to be grouped together MUST be packed into the same groupbox and they MUST have a unique Id within the groupbox.
SOURCE
langs = 'Rexx Perl Tcl C COBOL'
groupbox = dw_groupbox_new( !REXXDW.!DW_VERT, 0, 'Favourite Language' )
Do i = 1 To Words( langs )
rb.i = dw_radiobutton_new( Word( langs, i ), i*10 )
Call dw_box_pack_start groupbox, rb.i, 150, 15, !REXXDW.!DW_EXPAND_HORZ, ,
!REXXDW.!DW_DONT_EXPAND_VERT, 0
End
Call dw_radiobutton_set rb.1, !REXXDW.!DW_CHECKED
[ Top ] [ CheckboxAndRadiobutton ] [ Functions ]
NAME
DW_checkbox_set
SYNOPSIS
dw_checkbox_set( Win, State )
FUNCTION
Sets the state of the specified checkbox.
ARGUMENTS
RESULT
No return result.
SEE ALSO
DW_checkbox_new, DW_checkbox_get, WidgetChecked
SOURCE
... checkbox = dw_checkbox_new( "Allow access", 0 ) Call dw_checkbox_set( checkbox, !REXXDW.!DW_CHECKED )
[ Top ] [ CheckboxAndRadiobutton ] [ Functions ]
NAME
DW_radiobutton_set
SYNOPSIS
dw_radiobutton_set( Win, State )
FUNCTION
Sets the state of the radiobutton to checked or not.
ARGUMENTS
RESULT
No return result.
SEE ALSO
SOURCE
langs = 'Rexx Perl Tcl C COBOL'
groupbox = dw_groupbox_new( !REXXDW.!DW_VERT, 0, 'Favourite Language' )
Do i = 1 To Words( langs )
rb.i = dw_radiobutton_new( Word( langs, i ), i*10 )
Call dw_box_pack_start groupbox, rb.i, 150, 15, !REXXDW.!DW_EXPAND_HORZ, ,
!REXXDW.!DW_DONT_EXPAND_VERT, 0
End
Call dw_radiobutton_set rb.1, !REXXDW.!DW_CHECKED
[ Top ] [ CheckboxAndRadiobutton ] [ Functions ]
NAME
DW_checkbox_get
SYNOPSIS
win = dw_checkbox_get( Win )
FUNCTION
Queries the state of the specified checkbox.
ARGUMENTS
RESULT
1 if the checkbox is checked, 0 if not checked.
SEE ALSO
DW_checkbox_new, DW_checkbox_set
SOURCE
... checkbox = dw_checkbox_new( "Allow access", 0 ) ... rc = dw_checkbox_get( checkbox ) cb_result = 'Unchecked Checked' Say 'Allow access checkbox' Word( cb_result, rc+1 )
[ Top ] [ CheckboxAndRadiobutton ] [ Functions ]
NAME
DW_radiobutton_get
SYNOPSIS
boolean = dw_radiobutton_get( Win )
FUNCTION
Determines if a radiobutton has been checked or not.
ARGUMENTS
RESULT
1 if the radiobutton is checked, 0 if unchecked
SEE ALSO
SOURCE
langs = 'Rexx Perl Tcl C COBOL'
groupbox = dw_groupbox_new( !REXXDW.!DW_VERT, 0, 'Favourite Language' )
Do i = 1 To Words( langs )
rb.i = dw_radiobutton_new( Word( langs, i ), i*10 )
Call dw_box_pack_start groupbox, rb.i, 150, 15, !REXXDW.!DW_EXPAND_HORZ, ,
!REXXDW.!DW_DONT_EXPAND_VERT, 0
End
Call dw_radiobutton_set rb.1, !REXXDW.!DW_CHECKED
...
Do i = 1 To Words( langs )
If dw_radiobutton_get( rb.i ) Then
Do
Say 'Your favourite language is' Word( langs, i )
Leave
End
End
[ Top ] [ Widgets ] [ Modules ]
DESCRIPTION
These widgets provide a two-dimensional display of read-only data. Data are displayed in rows and columns, with automatically created scrollbars to display the complete set of data. Columns can be resized by the user at runtime. A Filesystem is the same as a normal Container, except that the first column consists of a column of string and icon items, which usually displays a filename.
All DW_container*() functions (for which there is no specific "Filename" equivalent) also works with a "Filename" widget.
[ Top ] [ ContainerAndFilesystem ] [ Functions ]
NAME
DW_container_new
SYNOPSIS
win = dw_container_new( Id, Selection )
FUNCTION
Creates a new container. A container is a widget that provides a grid of cells with column headings.
ARGUMENTS
RESULT
A window identifier.
SEE ALSO
SOURCE
... container = dw_container_new( 1, !REXXDW.!DW_SINGLE_SELECTION )
[ Top ] [ ContainerAndFilesystem ] [ Functions ]
NAME
DW_container_alloc
SYNOPSIS
alloc = dw_container_alloc( Win, RowCount )
FUNCTION
Allocates working memory for a container window.
ARGUMENTS
RESULT
An identifier for the working memory.
SEE ALSO
DW_container_new, DW_container_clear
NOTES
After a container window is created, you need to allocate memory for the initial number of rows that the container will contain. This call does that and must be called after creating the container. The allocated memory will be freed when the container is destroyed and by a call to DW_container_clear().
SOURCE
... container = dw_container_new( 1, !REXXDW.!DW_SINGLE_SELECTION ) alloc = dw_container_alloc( container, 10 ) ...
[ Top ] [ ContainerAndFilesystem ] [ Functions ]
NAME
DW_container_setup
SYNOPSIS
dw_container_setup( Win, FlagsArray, TitlesArray[,Separator] )
FUNCTION
Defines properties for the columns in a container.
ARGUMENTS
RESULT
No return result.
SEE ALSO
DW_container_change_item, DW_filesystem_setup, ContainerColumnFlags
NOTES
The FlagsArray is a Rexx stem variable name, including a trailing period. The 0th compound variable (eg Flags.0) contains a count of the number of items in the array. Each item in the array can contain a combination of the values described in ContainerColumnFlags.
SOURCE
... flags.0 = 2 flags.1 = dw_or( !REXXDW.!DW_CFA_STRINGANDICON, !REXXDW.!DW_CFA_LEFT, , !REXXDW.!DW_CFA_SEPARATOR, !REXXDW.!DW_CFA_HORZSEPARATOR ) flags.2 = dw_or( !REXXDW.!DW_CFA_STRING, !REXXDW.!DW_CFA_LEFT, , !REXXDW.!DW_CFA_SEPARATOR, !REXXDW.!DW_CFA_HORZSEPARATOR ) titles.0 = 2 titles.1 = 'Title' titles.2 = 'Command' ... container = dw_container_new( 1, !REXXDW.!DW_MULTIPLE_SELECTION ) Call dw_container_setup container, 'flags.', 'titles.', 0 alloc = dw_container_alloc( container, numrows ) ... Do i = 1 To numrows Call dw_container_set_item container, alloc, 0, i-1, title.i, icon.i Call dw_container_set_item container, alloc, 1, i-1, command.i Call dw_container_set_row_title alloc, i-1, "Row"i End
[ Top ] [ ContainerAndFilesystem ] [ Functions ]
NAME
DW_filesystem_setup
SYNOPSIS
dw_filesystem_setup( Win, FlagsArray, TitlesArray, Separator )
FUNCTION
Defines properties for the columns in a filesystem container.
ARGUMENTS
RESULT
No return result.
SEE ALSO
DW_filesystem_change_item, DW_container_setup, ContainerColumnFlags
NOTES
The FlagsArray is a Rexx stem variable name, including a trailing period. The 0th compound variable (eg Flags.0) contains a count of the number of items in the array. Each item in the array can contain a combination of the values described in ContainerColumnFlags.
SOURCE
... flags.0 = 2 flags.1 = dw_or( !REXXDW.!DW_CFA_STRINGANDICON, !REXXDW.!DW_CFA_LEFT, , !REXXDW.!DW_CFA_SEPARATOR, !REXXDW.!DW_CFA_HORZSEPARATOR ) flags.2 = dw_or( !REXXDW.!DW_CFA_STRING, !REXXDW.!DW_CFA_LEFT, , !REXXDW.!DW_CFA_SEPARATOR, !REXXDW.!DW_CFA_HORZSEPARATOR ) titles.0 = 2 titles.1 = 'Title' titles.2 = 'Command' ... container = dw_container_new( 1, !REXXDW.!DW_MULTIPLE_SELECTION ) alloc = dw_container_alloc( container, numrows ) Call dw_filesystem_setup container, 'flags.', 'titles.' ... normalfileicon = dw_icon_load_from_file( '/home/mark/normalfile' ) Do i = 1 To numrows Call dw_filesystem_set_file container, alloc, '/home/mark/myfile', myicon Call dw_filesystem_set_item container, alloc, 0, i-1, title.i, icon.i Call dw_filesystem_set_item container, alloc, 1, i-1, command.i Call dw_container_set_row_title alloc, i-1, "Row"i End
[ Top ] [ ContainerAndFilesystem ] [ Functions ]
NAME
DW_container_set_item
SYNOPSIS
dw_container_set_item( Win, Memory, Column, Row, Data [,Data2] )
FUNCTION
Adds the initial data into a cell of a container.
ARGUMENTS
RESULT
No return result.
SEE ALSO
DW_container_change_item, DW_container_setup, ContainerColumnFlags DW_filesystem_change_item, DW_filesystem_set_item
NOTES
The Data (and Data2) arguments must match the data type of the column when defined in the call to DW_container_setup().
SOURCE
... flags.0 = 2 flags.1 = dw_or( !REXXDW.!DW_CFA_STRINGANDICON, !REXXDW.!DW_CFA_LEFT, , !REXXDW.!DW_CFA_SEPARATOR, !REXXDW.!DW_CFA_HORZSEPARATOR ) flags.2 = dw_or( !REXXDW.!DW_CFA_STRING, !REXXDW.!DW_CFA_LEFT, , !REXXDW.!DW_CFA_SEPARATOR, !REXXDW.!DW_CFA_HORZSEPARATOR ) titles.0 = 2 titles.1 = 'Title' titles.2 = 'Command' ... container = dw_container_new( 1, !REXXDW.!DW_MULTIPLE_SELECTION ) alloc = dw_container_alloc( container, numrows ) Call dw_container_setup container, 'flags.', 'titles.', 0 ... Do i = 1 To numrows Call dw_container_set_item container, alloc, 0, i-1, title.i, icon.i Call dw_container_set_item container, alloc, 1, i-1, command.i Call dw_container_set_row_title alloc, i-1, "Row"i End
[ Top ] [ ContainerAndFilesystem ] [ Functions ]
NAME
DW_filesystem_set_file
SYNOPSIS
dw_filesystem_set_file( Win, Memory, Row, Filename, Icon )
FUNCTION
Adds the data in the first cell of a filesystem container.
ARGUMENTS
RESULT
No return result.
SEE ALSO
DW_filesystem_change_file, DW_filesystem_set_item
SOURCE
... normalfileicon = dw_icon_load_from_file( '/home/mark/normalfile' ) container = dw_container_new( 1, !REXXDW.!DW_SINGLE_SELECTION ) alloc = dw_container_alloc( container, 10 ) ... Call dw_filesystem_set_file container, alloc, 10, '/home/mark/newfile.txt', , normalfileicon
[ Top ] [ ContainerAndFilesystem ] [ Functions ]
NAME
DW_filesystem_set_item
SYNOPSIS
dw_filesystem_set_item( Win, Memory, Column, Row, Data [,Data2] )
FUNCTION
Adds the initial data into a cell of a filesystem container.
ARGUMENTS
RESULT
No return result.
SEE ALSO
DW_container_change_item, DW_container_setup, ContainerColumnFlags DW_filesystem_change_item, DW_container_set_item
NOTES
The Data (and Data2) arguments must match the data type of the column when defined in the call to DW_container_setup().
SOURCE
... flags.0 = 2 flags.1 = dw_or( !REXXDW.!DW_CFA_STRINGANDICON, !REXXDW.!DW_CFA_LEFT, , !REXXDW.!DW_CFA_SEPARATOR, !REXXDW.!DW_CFA_HORZSEPARATOR ) flags.2 = dw_or( !REXXDW.!DW_CFA_STRING, !REXXDW.!DW_CFA_LEFT, , !REXXDW.!DW_CFA_SEPARATOR, !REXXDW.!DW_CFA_HORZSEPARATOR ) titles.0 = 2 titles.1 = 'Title' titles.2 = 'Command' ... container = dw_container_new( 1, !REXXDW.!DW_MULTIPLE_SELECTION ) alloc = dw_container_alloc( container, numrows ) Call dw_filesystem_setup container, 'flags.', 'titles.', 0 ... Do i = 1 To numrows Call dw_filesystem_set_file container, alloc, i-1, fname.i, icon.i Call dw_filesystem_set_item container, alloc, 0, i-1, title.i, icon.i Call dw_filesystem_set_item container, alloc, 1, i-1, command.i Call dw_container_set_row_title alloc, i-1, "Row"i End
[ Top ] [ ContainerAndFilesystem ] [ Functions ]
NAME
DW_container_change_item
SYNOPSIS
dw_container_change_item( Win, Column, Row, Data [,Data2] )
FUNCTION
Changes the data in a cell of a container.
ARGUMENTS
RESULT
No return result.
SEE ALSO
NOTES
The Data (and Data2) arguments must match the data type of the column when defined in the call to DW_container_setup().
SOURCE
... container = dw_container_new( 1, !REXXDW.!DW_SINGLE_SELECTION ) ... Call dw_container_change_item container, 0, 10, 'New string data'
[ Top ] [ ContainerAndFilesystem ] [ Functions ]
NAME
DW_filesystem_change_file
SYNOPSIS
dw_filesystem_change_file( Win, Row, Filename, Icon )
FUNCTION
Changes the data in the first cell of a filesystem container.
ARGUMENTS
RESULT
No return result.
SEE ALSO
DW_filesystem_change_item, DW_filesystem_set_file
SOURCE
... normalfileicon = dw_icon_load_from_file( '/home/mark/normalfile' ) ... container = dw_container_new( 1, !REXXDW.!DW_SINGLE_SELECTION ) ... Call dw_filesystem_change_file container, 10, '/home/mark/newfile.txt', , normalfileicon
[ Top ] [ ContainerAndFilesystem ] [ Functions ]
NAME
DW_filesystem_change_item
SYNOPSIS
dw_filesystem_change_item( Win, Column, Row, Data [,Data2] )
FUNCTION
Changes the data in a cell of a container.
ARGUMENTS
RESULT
No return result.
SEE ALSO