Next: Utility Functions
Up: Classes and Methods
Previous: XList
(subclass of 9.1.3.2 Button)
An XList_Button is a very special kind of Button, when it is created
(using "new-instance") an XList contained in a Layer is created
as well. In its action, i.e. when it is clicked, the Button
will show the Layer to allow using the XList; of course XList stands
for any subclass of XList.
When the button is freed it will delete the Layer and the XList as well.
- (XLIST_BUTTON * ) GRAPE(XList_Button, "new-for-xlist")(meth, inst, name, get_data)
- CLASS *XList_Button
char *meth
INSTANCE *inst
char *name, *get_data
This method creates a Button, which will pop-up an XList, if you press
the button. The XList will then send the method defined in the
parameter "get-data" to itself. This method has to fill the
XList with data.
If the user ends the selection of a list element using the XList's OK- or
Cancel-button, the method meth will be send to the instance
inst. This method must also hide the XList by sending the method
"hide" to the XList's Layer.
- (XLIST_BUTTON * ) GRAPE(XList_Button, "new-for-filelist")(meth, inst, name, get_data,
wildcard, open_mode)
- CLASS *XList_Button
char *meth
INSTANCE *inst
char *name, *get_data, *wildcard
OPEN_MODE open_mode
This method will create a button, which will pop-up a file-list, with
the same principal as "new-for-xlist".
Additional to "new-for-xlist" you must define a wildcard, to
select the files you want to see in the file-list. With the parameter
open_mode you can define if the file should be opened for
reading or for writing.
Normally the get_data parameter should be "get-files".
- (XLIST_BUTTON * ) GRAPE(XList_Button, "new-for-methlist")(meth, inst, name, get_data, end_of_meth, nr_of_additionals,
additionals)
- CLASS *XList_Button
char *meth
INSTANCE *inst
char *name, *get_data, *end_of_meth
int
nr_of_additionals
char **additionals
This method creates a button, which will pop-up a method list with
the same principal as "new-for-xlist". If the value of
end_of_meth is != NULL, only method, whose names have the correct
ending will be added to the list, for example this "-disp" to
get only display-methods. With the additional parameters a number of
methods can be added to the list, which don't need to have the correct
ending, for example "display" to add the default-display method
to the list of display methods.
Normally the get_data parameter should be "get-methods".
- GRAPE(butt, "set-label")(label)
- XLIST_BUTTON * butt
char * label
Like "set-label" on the superclass Interactive, but the
label is used for the assiciated XList as well.
- GRAPE(butt, "share-path")(other)
- XLIST_BUTTON * butt, * other
If butt and other have been created by "new-for-filelist",
the associated FileLists share their working directory hereafter.
Next: Utility Functions
Up: Classes and Methods
Previous: XList
SFB 256 Universität Bonn and IAM Universität Freiburg Copyright © by the Sonderforschungsbereich 256 at the Institut für Angewandte Mathematik,
Universität Bonn.