BBjChildWindow
Description
The BBjChildWindow is a child window that must be created within a BBjWindow. The window that the child window is created in will be the child's parent window. BBjChildWindow extends from BBjWindow and implements methods within BBjWindow and BBjControl.
See Child Windows for an introduction to child windows.
Implemented Interfaces
TabTraversable (BBj 15.00 and higher)
Creation
BBjAPI > BBjSysGui > BBjWindow > BBjChildWindow
A BBjChildWindow object is created through the following BBjWindow methods:
|
Return Value |
Method |
|---|---|
|
BBjChildWindow |
addChildWindow(int ID, number x, number y, number w, number h, int context) addChildWindow(int ID, number x, number y, number w, number h, string title, int context) addChildWindow(int ID, number x, number y, number w, number h, string title, string flags, int context) addChildWindow(int ID, number x, number y, number w, number h, string title, string flags, int context, string eventMask) addChildWindow(int ID, int context) addChildWindow(int ID, string title, int context) addChildWindow(int ID, string title, String flags, int context) addChildWindow(int ID, string title, String flags, int context, string eventMask) addChildWindow(int context) addChildWindow(string title, int context) addChildWindow(string title, String flags, int context) addChildWindow(string title, String flags, int context, string eventMask) |
Creation Flags
| Flag | Description |
|---|---|
|
$00000004$ |
Horizontal Scrollbar: Causes a horizontal scroll bar to appear whenever the window is resized to be smaller than its initial size and setTrack(0) is specified. |
|
$00000008$ |
Vertical Scrollbar: Causes a vertical scroll bar to appear whenever the window is resized to be smaller than its initial size and setTrack(0) is specified. |
|
$00000010$ |
Invisible: Sets the child window to be initially invisible. |
|
$00000020$ |
Disabled: Sets the child window to be initially disabled. |
|
$00000800$ |
Borderless: Creates a child window without a border. |
|
$00001000$ |
Fieldset Element: In BBj 22.00 and higher, if creation flag $00008000$ is also specified, the simple child window is created as a fieldset element to emulate groupbox functionality. The default implementation uses a div element. This option is only meaningful in the DWC client. |
|
$00008000$ |
Simple: In BBj 22.00 and higher, creates a simple child window that doesn't support a status bar or internal docked child windows. This option is only meaningful in the DWC client. |
|
$00010000$ |
Keyboard Navigation: Activates keyboard navigation in the child window. If this flag is specified, key pressed ("t") events for arrow keys and the tab key will not be reported. |
|
$00100000$ |
Automatic Layout: Automatically arranges all controls to fit within the child window. In the DWC client, this flag causes the window to use dynamic flow layout, ignoring all absolute control sizes and positions. |
|
$00200000$ |
Docking: Attaches the child window to one side of the parent frame, by default to the top frame. It will always occupy the full extent of the parent window's edge (even if the parent is resized later), but the other dimension is determined by the width or height specified when the child was created. By default, docked child windows are attached to the top of their parent. This can be changed with the 'DOCK' mnemonic. |
|
$00800000$ |
Enter as Tab: Sets the Enter key to behave as a Tab key. |
|
$01000000$ |
Recessed Edge: Draws a recessed client edge around the child window. |
|
$02000000$ |
Raised Edge: Draws a raised edge around the child window. |
|
$08000000$ |
Unique Names: In BBj 8.00 and higher, causes the window to enforce unique control names. See BBjWindow::getControl. |
|
$10000000$ |
Mouse Events: In BBj 15.00 and higher, causes the window to report all mouse events for all controls. |
|
$20000000$ |
Keypress Events: In BBj 15.00 and higher, causes the window to report all keypress events for all controls. |
|
$80000000$ |
TRACK'(0)': In BBj 17.00 and higher, creates the window with 'TRACK'(0) instead of the default 'TRACK'(1). Use this option to enable scrolling behavior in the child window. |
Methods of BBjChildWindow
|
Return Value |
Method |
|---|---|
|
int |
|
|
void |
setBorderColor(BBjColor color!) |
|
void |
setDockLocation(int dock) |
Methods of BBjChildWindow implemented for MouseWheelEnabled
| Return Value | Method |
|---|---|
|
int |
|
|
void |
setScrollWheelBehavior(int mode) |
Methods of BBjChildWindow implemented for TabTraversable
| Return Value | Method |
|---|---|
|
boolean |
|
|
void |
setTabTraversable(boolean trav) |
Methods of BBjChildWindow inherited from BBjWindow
Methods of BBjChildWindow inherited from BBjControl
Events
|
Callback Code |
Object-oriented Event |
Read Record Event |
Code |
|---|---|---|---|
|
ON_DOUBLE_CLICK |
2 |
||
|
ON_KEYPRESS |
t |
||
|
ON_MOUSE_DOWN |
d |
||
|
ON_MOUSE_ENTER |
E |
||
|
ON_MOUSE_EXIT |
E |
||
|
ON_MOUSE_MOVE |
m |
||
|
ON_MOUSE_SCROLL |
w |
||
|
ON_MOUSE_UP |
u |
||
|
ON_RESIZE (BBj 22 and higher) |
BBjResizeEvent | Window Resize | S |
|
ON_RIGHT_MOUSE_DOWN |
R |
||
|
ON_POPUP_REQUEST |
r |
||
|
ON_WINDOW_GAINED_FOCUS |
F |
||
|
ON_WINDOW_LOST_FOCUS |
F |
||
|
ON_WINDOW_SCROLL |
p |
CSS
The visual appearance of BUI controls is defined using CSS (cascading style sheets) rules. Easily change the default colors, border, and other settings by customizing these rules, all without changing any application code. See CSS API for a high-level overview of BUI CSS.
The BBjChildWindow defines the following style names:
.BBjChildWindow
.BBjChildWindow-border
BBjChildWindows have a default 1px black border, which can be omitted when the control is created. That border color can be changed with the following CSS:
|
Constants
None.
Example
|
See Also
See the BBj Object Diagram for an illustration of the relationship between BBj Objects.
