Creating a frame
Left-click on the frame icon on the object palette, and left-click
again on the object editor canvas, or choose New frame from
the Edit menu. The frame properties editor will be shown,
with the following controls.
- Name
- The name of this frame instance.
- Description
- A textual description of the frame.
- Class name
- The name of the C++ class that will be created for
this frame. At present, each frame must have a unique class.
- Icon name
- The name of the icon file to be used for this frame.
- Title
- The default title for the frame.
- No. status line fields
- The number of divisions for the status line.
Zero indicates no status line.
- Vertical subwindow tiling
- If checked on, the subwindow tiling
is vertical. Otherwise it is horizontal.
- Thick frame
- If checked on, the frame has a thick border for resizing
(Windows only).
- Caption
- If checked on, the frame has a caption (Windows only).
- System menu
- If checked on, the frame has a system menu (Windows only).
- Minimize button
- If checked on, the frame has a minimize button (Windows only).
- Maximize button
- If checked on, the frame has a maximize button (Windows only).
- Shuffle subwindows
- If pressed, the subwindow positioning order is rearranged.
Subwindow tiling
Subwindow tiling
The way in which subwindows are positioned and sized in wxWindows is very different
from the method for panel items, dialog boxes and frames. This is because
subwindows are often sized relative to their parent frame.
If there is only one subwindow, the default wxWindows method is used, which is
simply to resize the subwindow to the frame client area when the frame is created
or resized.
If there is more than one subwindow, wxBuilder uses an algorithm to
layout the windows. It is hoped that this algorithm will cater for most
subwindow layout needs. These are the options and constraints:
- Zero or more subwindows may be children of a frame.
- All subwindows must be tiled either vertically or horizontally.
Mixture of the two tiling modes is not allowed (horizontal tool bars work
independently and may be discounted from this constraint).
- Each subwindow has a resize strategy, one of
Fixed, Proportional and Grow.
- The mix of resize strategies must be such as to allow
wxBuilder to determine all subwindow sizes.
If the resize strategy is Fixed, the specified width (if in horizontal
tiling mode) or height (if in vertical mode) is used. The other
dimension is determined by the size of the frame (and possibly the
presence of a tool bar).
If the resize strategy is Proportional, the free dimension of the
subwindow is determined from that dimension of the frame, together
with the percentage specified in the subwindow property editor.
If the resize strategy is Grow, the free dimension of the
subwindow is determined by adjacent subwindows. In practice
only one subwindow may use this strategy.