csDialog Class Reference
[Dialog]
The Dialog class is a single-colored canvas which contains a number of child controls.
More...
#include <csdialog.h>
Inheritance diagram for csDialog:

Public Methods | |
csDialog (csComponent *iParent, csDialogFrameStyle iFrameStyle=csdfsNone) | |
Create dialog object. | |
virtual | ~csDialog () |
Destroy a dialog object. | |
virtual bool | HandleEvent (iEvent &Event) |
Handle input events. | |
void | SetAutoGrid (int iDeltaX, int iDeltaY, bool iSnapSize) |
Enable/disable(dx<0||dy<0) automatic control placement in a grid fashion. | |
virtual bool | SetRect (int xmin, int ymin, int xmax, int ymax) |
Do auto-placement work if enabled. | |
virtual void | SuggestSize (int &w, int &h) |
Return the recommended minimal size of dialog. | |
void | GetBorderSize (int &w, int &h) |
Return border width and height. | |
void | SetBorderSize (int w, int h) |
Set border width and height. | |
virtual void | FixSize (int &newW, int &newH) |
Fix dialog size when resizing. | |
csDialogFrameStyle | GetFrameStyle () |
Query dialog border style. | |
void | SetFrameStyle (csDialogFrameStyle iFrameStyle) |
Change dialog border style. | |
virtual char * | GetSkinName () |
Get the name of the skip slice for this component. | |
void | SetAlpha (uint8 iAlpha) |
Set dialog transparency level (0 - opaque, 255 - fully transparent). | |
void | SetOverlayAlpha (uint8 iAlpha) |
Set dialog overlay transparency level (0 - opaque, 255 - fully transparent). | |
uint8 | GetAlpha () |
Query dialog transparency level. | |
uint8 | GetOverlayAlpha () |
Query dialog overlay transparency level. | |
void | SetFrameBitmap (csPixmap *iFrameBitmap, bool iDelFrameBitmap) |
Set the bitmap for the frame (only useful if the framestyle is csdfsBitmap). | |
void | SetOverlayBitmap (csPixmap *iOverlayBitmap, bool iDelOverlayBitmap) |
Set the bitmap for the overlay (only useful if the framestyle is csdfsBitmap). | |
csPixmap * | GetFrameBitmap () |
Get the frame bitmap. | |
csPixmap * | GetOverlayBitmap () |
Get the overlay bitmap. | |
Protected Methods | |
void | AdjustFocused (bool forward) |
Adjust focused control by switching back or forth if it is disabled. | |
bool | PlaceItems () |
Place all dialog items in correspondence to GridX, GridY and SnapSizeToGrid. | |
Static Protected Methods | |
bool | do_topleft (csComponent *comp, void *param) |
Used by SuggestSize. | |
Protected Attributes | |
csDialogFrameStyle | FrameStyle |
Dialog frame style. | |
int | GridX |
Automatical grid placement parameters. | |
int | GridY |
Automatical grid placement parameters. | |
bool | SnapSizeToGrid |
Automatically snap dialog size to grid? | |
csComponent * | first |
First component. | |
int | BorderWidth |
Border width and height. | |
int | BorderHeight |
Border width and height. | |
uint8 | Alpha |
Dialog transparency (if CSS_TRANSPARENT is set). | |
uint8 | OverlayAlpha |
Dialog transparency (if CSS_TRANSPARENT is set). | |
csPixmap * | FrameBitmap |
Frame bitmap, if there is one. | |
csPixmap * | OverlayBitmap |
Frame bitmap, if there is one. | |
bool | delFrameBitmap |
Set if this component should delete the frame bitmap when it is done. | |
bool | delOverlayBitmap |
Set if this component should delete the frame bitmap when it is done. |
Detailed Description
The Dialog class is a single-colored canvas which contains a number of child controls.The dialog can perform a number of operations on its childs such as switching between them using Tab/ShiftTab key, activating the default button when Enter is pressed etc.
Other uses for csDialog class are for floating toolbars. They can be even resizeable; to create a floating toolbar you should create a stand-alone dialog object, setting his DragStyle to CS_DRAG_MOVEABLE and, possibly, CS_DRAG_SIZEABLE. In this case dialog will act as a standalone window; it would be good if you specify its frame style to csdfsAround: in this case it will look like a usual window but without titlebar.
Definition at line 67 of file csdialog.h.
Constructor & Destructor Documentation
|
Create dialog object.
|
|
Destroy a dialog object.
|
Member Function Documentation
|
Adjust focused control by switching back or forth if it is disabled.
|
|
Used by SuggestSize.
|
|
Fix dialog size when resizing.
Reimplemented from csComponent. Reimplemented in csLayout. |
|
Query dialog transparency level.
Definition at line 138 of file csdialog.h. References Alpha, CSS_TRANSPARENT, and csComponent::GetState(). |
|
Return border width and height.
Definition at line 113 of file csdialog.h. References BorderHeight, and BorderWidth. |
|
Get the frame bitmap.
Definition at line 153 of file csdialog.h. |
|
Query dialog border style.
Definition at line 122 of file csdialog.h. References csDialogFrameStyle, and FrameStyle. |
|
Query dialog overlay transparency level.
Definition at line 142 of file csdialog.h. References CSS_TRANSPARENT, csComponent::GetState(), and OverlayAlpha. |
|
Get the overlay bitmap.
Definition at line 157 of file csdialog.h. |
|
Get the name of the skip slice for this component.
Reimplemented from csComponent. Definition at line 128 of file csdialog.h. |
|
Handle input events.
Reimplemented from csComponent. Reimplemented in csLayout. |
|
Place all dialog items in correspondence to GridX, GridY and SnapSizeToGrid.
|
|
Set dialog transparency level (0 - opaque, 255 - fully transparent).
|
|
Enable/disable(dx<0||dy<0) automatic control placement in a grid fashion. DeltaX and DeltaY is the horizontal and vertical distance between controls; SnapSize tells dialog object whenever dialog size should snap when it is resized to the maximal x/y coordinates of all controls. Definition at line 103 of file csdialog.h. References GridX, GridY, and SnapSizeToGrid. |
|
Set border width and height.
|
|
Set the bitmap for the frame (only useful if the framestyle is csdfsBitmap).
|
|
Change dialog border style.
|
|
Set dialog overlay transparency level (0 - opaque, 255 - fully transparent).
|
|
Set the bitmap for the overlay (only useful if the framestyle is csdfsBitmap).
|
|
Do auto-placement work if enabled.
Reimplemented from csComponent. Reimplemented in csLayout. |
|
Return the recommended minimal size of dialog.
Reimplemented from csComponent. Reimplemented in csAbsoluteLayout, csGridBagLayout, csBorderLayout, csBoxLayout, csFlowLayout, csGridLayout, and csLayout. |
Member Data Documentation
|
Dialog transparency (if CSS_TRANSPARENT is set).
Definition at line 81 of file csdialog.h. Referenced by GetAlpha(). |
|
Border width and height.
Definition at line 79 of file csdialog.h. Referenced by GetBorderSize(). |
|
Border width and height.
Definition at line 79 of file csdialog.h. Referenced by GetBorderSize(). |
|
Set if this component should delete the frame bitmap when it is done.
Definition at line 85 of file csdialog.h. |
|
Set if this component should delete the frame bitmap when it is done.
Definition at line 85 of file csdialog.h. |
|
First component.
Definition at line 77 of file csdialog.h. |
|
Frame bitmap, if there is one.
Definition at line 83 of file csdialog.h. |
|
Dialog frame style.
Definition at line 71 of file csdialog.h. Referenced by GetFrameStyle(). |
|
Automatical grid placement parameters.
Definition at line 73 of file csdialog.h. Referenced by SetAutoGrid(). |
|
Automatical grid placement parameters.
Definition at line 73 of file csdialog.h. Referenced by SetAutoGrid(). |
|
Dialog transparency (if CSS_TRANSPARENT is set).
Definition at line 81 of file csdialog.h. Referenced by GetOverlayAlpha(). |
|
Frame bitmap, if there is one.
Definition at line 83 of file csdialog.h. |
|
Automatically snap dialog size to grid?
Definition at line 75 of file csdialog.h. Referenced by SetAutoGrid(). |
The documentation for this class was generated from the following file:
- csws/csdialog.h
Generated for Crystal Space by doxygen 1.2.18