Prev | Current Page 97 | Next

David Berube

"Practical Reporting with Ruby and Rails"

The first line creates the control with the text ???Example Button Control,??? and the
following lines specify an action to take when the user clicks the button.
Next, you create a few more interface widgets:
FXTextField.new(mainWindow, 30).text = 'Example Text Control'
FXRadioButton.new(mainWindow, "Example Radio Control")
FXCheckButton.new(mainWindow, "Example Check Control")
The FXTextField object lets the user enter text. The text can be retrieved or preset
using the text property, as in this example. You then create an FXRadioButton object,
which lets the user select just one button from a group (of course, typically you would
have more than one radio button). The last line creates an FXCheckButton control, which
lets the user make an on/off choice.
Finally, having specified the elements for your interface, you then need to perform
some actions. First, you call the create method on your application object. This calls the
create method on all of your FXRuby objects, which uses the FOX GUI toolkit to actually
create the objects and prepare them for display:
myApp.


Pages:
85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109
gry platformowe hotele spa antyki białystok odzyskiwanie zdjęć utylizacja