[Classes] [Prev] [Next] [Methods]

CGlue

Methods Index

Heritage
Description
Usage
Protected Data Members
Public Methods
Glue Event Handling
Overrides

CGlue


Heritage

Superclass: CNotifier

Subclasses: None


Description

CGlue allows objects to have stickiness properties. When a view is resized a sticky object will, depending on its stickiness, stretch with the view or stay fixed by a constant distance from the view's borders.


Usage

Although CGlue is not a private class, it is used internally. Glue objects are created and destroyed internally. CGlue has been made public so that you can derive from it and set your own derived glue objects for any view.

The gluing options, passed in the GLUETYPE variable, are chosen by OR'ing one or more of the following:

TOPSTICKY BOTTOMRIGHTSTICKY
BOTTOMSTICKY TOPLEFTSTICKY
LEFTSTICKY TOPRIGHTSTICKY
RIGHTSTICKY BOTTOMLEFTSTICKY
ALLSTICKY

For instance, an object whose glue is set remains glued to the top-right corner of its enclosing border as the window is stretched. For example: SetGlue(TOPSTICKY|RIGHTSTICKY)

However, an object whose stickiness is defined stretches or shrinks as the window changes size. For example: SetGlue(ALLSTICKY)


Protected Data Members

GLUETYPE itsGlue; Its conjoined sticky properties
UNITS itsTopScaling; Distance to itsBorder's top
UNITS itsLeftScaling; Distance to itsBorder's left
UNITS itsBottomScaling; Distance to itsBorder's bottom
UNITS itsRightScaling; Distance to itsBorder's right
CView* itsOwner; The view owning this glue


Public Methods

CGlue(CView* theOwner);
CGlue(const CGlue& theGlue);
CGlue& operator=(const CGlue& theGlue);
virtual ~CGlue(void);
virtual void SetGlue(GLUETYPE theGlue);
virtual GLUETYPE GetGlue(void) const;

Glue Event Handling

virtual void SizeOwner(void);

Overrides

GetFrame and SetFrame.



[Classes] [Prev] [Next] [Methods]

support@xvt.com


Visit our online help desk for tech support

Copyright © 2009, Providence Software Solutions Inc. All rights reserved.