OWLNext 7.0
Borland's Object Windows Library for the modern age
|
A gadget that is used on the far right of a status bar to provide re-sizing grip for the host window. More...
#include <owl/gadget.h>
Public Member Functions | |
TFlatHandleGadget (int id=IDG_FLATHANDLE) | |
virtual void | Paint (TDC &dc) |
virtual void | GetDesiredSize (TSize &size) |
Public Member Functions inherited from owl::TSeparatorGadget | |
TSeparatorGadget (int size=0, int id=0, bool showseparator=true) | |
Used for both the width and the height of the separator, the default size is TUIMetric::CxSizeFrame times two. | |
void | Inserted () |
This is an overridden virtual, called after a gadget is inserted into a window. | |
void | Paint (TDC &dc) |
void | SetShowSep (bool show=true) |
bool | GetShowSep () |
Public Member Functions inherited from owl::TGadget | |
TGadget (int id=0, TBorderStyle borderStyle=None) | |
Construct a gadget with a given id and border style. | |
virtual | ~TGadget () |
Destroys a TGadget interface object and removes it from its associated window. | |
int | GetId () const |
Gets the ID for the gadget. | |
TRect & | GetBounds () |
Returns the boundary rectangle for the gadget. | |
const TRect & | GetBounds () const |
Returns the boundary rectangle for the gadget. | |
virtual void | SetEnabled (bool enabled) |
Enables or disables keyboard and mouse input for the gadget. | |
bool | GetEnabled () const |
Determines whether keyboard and mouse input have been enabled for the specified gadget. | |
virtual void | SetVisible (bool visible) |
Changes the visibility of the gadget. | |
bool | IsVisible () const |
Returns true if the gadget is visible. | |
bool | IsWindowVisible () const |
check to see if the button's created | |
void | SetEndOfRow (bool eor) |
Sets the end of row property for the gadget. | |
bool | IsEndOfRow () const |
Returns true if this gadget is at the end of a row. | |
bool | IsWideAsPossible () const |
Indicates whether the gadget width will be adjusted by the gadget window to be as wide as possible in the remaining space. | |
void | SetWideAsPossible (bool wide=true) |
Sets the flag that indicates whether the gadget width will be adjusted by the gadget window to be as wide as possible in the remaining space. | |
void | SetShrinkWrap (bool shrinkWrapWidth, bool shrinkWrapHeight) |
Simple set accessor to set whether shrinkwrapping is performed horizontally and/or vertically. | |
void | SetSize (const TSize &size) |
Alters the size of the gadget and then calls TGadgetWindow::GadgetChangedSize() for the size change to take effect. | |
void | GetOuterSizes (int &left, int &right, int &top, int &bottom) |
Get the four total outer sizes in pixels which consists of the margins plus the borders. | |
void | GetInnerRect (TRect &rect) |
Computes the area of the gadget's rectangle excluding the borders and margins. | |
virtual void | SetBounds (const TRect &rect) |
Called by the gadget window to inform the gadget of a change in its bounding rectangle. | |
virtual bool | IdleAction (long idleCount) |
Called during idle time to allow the gadget to perform any idle actions. | |
virtual void | CommandEnable () |
Provided so that the gadget can perform command enabling (so it can handle an incoming message if it's appropriate to do so). | |
virtual void | SysColorChange () |
Called when the system colors have been changed so that gadgets can rebuild and repaint, if necessary. | |
TGadget * | NextGadget () |
Returns the next gadget in the list of gadgets. | |
void | SetBorders (const TBorders &borders) |
Sets the borders for the gadget. | |
TBorders & | GetBorders () |
Gets the gadget's borders measured in border units that are based on SM_CXBORDER and SM_CYBORDER. | |
void | SetMargins (const TMargins &margins) |
Sets the margins of the gadget. | |
TMargins & | GetMargins () |
Gets the margin dimensions. | |
void | SetBorderStyle (TBorderStyle bs) |
Set the border style used by this gadget. | |
TBorderStyle | GetBorderStyle () const |
Gets the style for the gadget's borders. | |
Additional Inherited Members | |
Public Types inherited from owl::TGadget | |
enum | TBorderStyle { None , Plain , Raised , Recessed , Embossed , Grooved , ButtonUp , ButtonDn , WndRaised , WndRecessed , WellSet } |
Gadget border styles. More... | |
Protected Member Functions inherited from owl::TGadget | |
TGadgetWindow * | GetGadgetWindow () |
Return a pointer to the owning or parent window for the gadget. | |
const TGadgetWindow * | GetGadgetWindow () const |
Return a pointer to the owning or parent window for the gadget. | |
virtual void | Created () |
This is the virtual called after the window holding a gadget has been created. | |
virtual void | Moved () |
This is the virtual called when a gadget is relocated. | |
virtual void | Removed () |
Virtual called after a gadget is removed from a window. | |
bool | IsHaveMouse () const |
Return true if mouse inside gadget. | |
void | SetInMouse (bool state) |
Sets if mouse inside gadget or not. | |
bool | GetTrackMouse () const |
void | SetTrackMouse (bool track) |
void | Invalidate (bool erase=true) |
Used to invalidate the active (usually nonborder) portion of the gadget, Invalidate calls InvalidateRect and passes the boundary width and height of the area to erase. | |
void | InvalidateRect (const TRect &rect, bool erase=true) |
Invalidate a rectangle in our containing window. | |
void | Update () |
Paint now if possible. | |
virtual bool | PtIn (const TPoint &point) |
Default behavior returns true if the point is within the receiver's bounding rect. | |
virtual void | PaintBorder (TDC &dc) |
Self sent by method Paint(). | |
virtual void | MouseEnter (uint modKeys, const TPoint &point) |
Mouse is entering this gadget. | |
virtual void | MouseMove (uint modKeys, const TPoint &point) |
Mouse is moving over this gadget. | |
virtual void | MouseLeave (uint modKeys, const TPoint &point) |
Mouse is leaving this gadget. | |
virtual void | LButtonDown (uint modKeys, const TPoint &point) |
Captures the mouse if TrackMouse is set. | |
virtual void | RButtonDown (uint modKeys, const TPoint &point) |
virtual void | LButtonUp (uint modKeys, const TPoint &point) |
Releases the mouse capture if TrackMouse is set. | |
virtual void | RButtonUp (uint modKeys, const TPoint &point) |
void | ChangeBorderStyle (TBorderStyle bs) |
Simply changes the border style without recalculating the gadget size. | |
Protected Attributes inherited from owl::TSeparatorGadget | |
bool | ShowSeparator |
A gadget that is used on the far right of a status bar to provide re-sizing grip for the host window.
owl::TFlatHandleGadget::TFlatHandleGadget | ( | int | id = IDG_FLATHANDLE | ) |
Definition at line 743 of file gadget.cpp.
References owl::TGadget::SetEnabled().
Reimplemented from owl::TGadget.
Definition at line 758 of file gadget.cpp.
References owl::DefaultGripSize, owl::TGadget::GetDesiredSize(), owl::TGadget::GetGadgetWindow(), owl::TGadgetWindow::Horizontal, IDG_FLATHANDLE, owl::TGadgetList::NextGadget(), owl::TGadgetWindow::Rectangular, and owl::TGadgetWindow::Vertical.
Reimplemented from owl::TGadget.
Definition at line 790 of file gadget.cpp.
References owl::TDC::DPtoLP(), owl::TUIBorder::DrawEdge(), owl::TGadgetWindow::FlatSingleDiv, owl::TGadgetWindow::Horizontal, owl::TUIBorder::RaisedInner, owl::TUIBorder::Rect, and owl::TGadgetWindow::Vertical.