Try to avoid the general Control statement to create a child window, these controls use the system font, rather than the DEFAULT_ GUI_FONT.
Instead use GFA-BASIC 32 control statements for the different kinds of standard and common controls. For instance, to create a simple left justified static text control:
LText text$, ID%, x%, y%, width%, height% [,style%]
All control statements use the same syntax:
CtrlName text$, ID%, x%, y%, width%, height% [,style%]
CtrlName | Name of the GFA-BASIC 32 control statement. |
text$ | Specifies text that is displayed with the control. The text is positioned within the control's specified dimensions or adjacent to the control. |
ID% | Specifies the control identifier. This value must be an integer in the range 0 through 65,535 or a simple arithmetic expression that evaluates to a value in that range. |
x%, y% | Specifies the x- and y-coordinate of the left top side of the control relative to the left top side of the dialog box. The coordinate is in dialog units and is relative to the origin of the dialog box, window, or control containing the specified control. |
width% | Specifies the width of the control. |
height% | Specifies the height of the control. |
style% | Specifies the control styles. Use the bitwise OR (|) operator to combine styles. |
Standard controls:
LText, RText, CText, Icon,
PushButton, DefPushButton, CheckBox, AutoCheckBox, RadioButton, AutoRadioButton,
ListBox, ComboBox,
EditText, Scrollbar.
Common Controls:
AnimateCtrl,
TabCtrl,
HeaderCtrl, ListViewCtrl, TreeViewCtrl,
ProgressCtrl, TrackBarCtrl,
StatusCtrl, ToolBarCtrl,
UpDownCtrl.
Other: RichEditCtrl.
Note - There is no Static control command, Static is used to declare static local variables. Use the general Control statement instead.
Note - GFA-BASIC 32 also provides keywords like ProgressBar, Toolbar, Header, etc. These keywords are not statements to create controls, but they are OCX types. As such these keywords are used to declare variables or to create OCX controls. For instance:
Dim pb As ProgressBar ' declare a variable pb
Ocx ProgressBar pb1 ' create OCX & declare global variable pb1
These OCX types are not allowed in a GLL.
{Created by Sjouke Hamstra; Last updated: 27/09/2014 by James Gaite}