Rogue Wave Views
Foundation Package API Reference Guide
Product Documentation:

Rogue Wave Views
Documentation Home
List of all members | Public Member Functions
IlvRectangularScale Class Reference

Graphic class. More...

#include <ilviews/graphics/scale.h>

Inheritance diagram for IlvRectangularScale:
IlvScale IlvSimpleGraphic IlvGraphic IlvValueInterface

Public Member Functions

 IlvRectangularScale (IlvDisplay *display, const IlvPoint &orig, IlvDim size, const char *format, IlFloat min, IlFloat max, IlvDirection direction=IlvVertical, IlvPosition position=IlvLeft, IlUShort steps=0, IlUShort substeps=0, IlUShort stepsize=10, IlUShort substepsize=5, IlvPalette *palette=0)
 Constructor. More...
 
 IlvRectangularScale (IlvDisplay *display, const IlvPoint &orig, IlvDim size, char *labels[], IlvDirection direction=IlvVertical, IlvPosition position=IlvLeft, IlUShort steps=2, IlUShort substeps=0, IlUShort stepsize=10, IlUShort substepsize=5, IlvPalette *palette=0)
 Constructor. More...
 
virtual void applyTransform (const IlvTransformer *t)
 Applies a transformation function to the graphic object. More...
 
IlBoolean areLabelsCentered () const
 Gets the 'centered labels' flag. More...
 
virtual void boundingBox (IlvRect &, const IlvTransformer *t=0) const
 Retrieves the bounding box of the graphic object. More...
 
void centerLabels (IlBoolean flag)
 Sets the 'centered labels' flag. More...
 
IlBoolean doesDrawOverlappingLabels () const
 Gets the 'draw overlapping labels' flag. More...
 
virtual void draw (IlvPort *, const IlvTransformer *t=0, const IlvRegion *clip=0) const
 Draws the graphic object. More...
 
virtual void drawBaseLine (IlvPort *dst, const IlvTransformer *t=0, const IlvRegion *clip=0) const
 Draws the base line. More...
 
virtual void drawLabel (IlvPort *dst, IlUShort idx, const IlvPoint &orig, const IlvFloatPoint &offset, const IlvPoint &tickoffset, const IlvTransformer *t=0, const IlvRegion *clip=0) const
 Draws a label. More...
 
virtual void drawLabels (IlvPort *dst, const IlvTransformer *t=0, const IlvRegion *clip=0) const
 Draws all labels. More...
 
void drawOverlappingLabels (IlBoolean val)
 Sets the 'draw overlapping labels' flag. More...
 
virtual void drawTick (IlvPort *dst, IlUShort idx, const IlvPoint &orig, const IlvFloatPoint &offset, const IlvFloatPoint &suboffset, const IlvPoint &tickoffset, const IlvPoint &subtickoffset, const IlvTransformer *t=0, const IlvRegion *clip=0) const
 Draws a tick mark. More...
 
virtual void drawTicks (IlvPort *dst, const IlvTransformer *t=0, const IlvRegion *clip=0) const
 Draws all tick marks. More...
 
IlvDirection getDirection () const
 Gets the direction of this scale. More...
 
virtual IlUShort getNumberOfSkippedSteps (const IlvPoint &orig, IlvDim size, IlUShort steps, const IlvFloatPoint &offset, const IlvPoint &tickoffset, const IlvTransformer *t=0) const
 Gets the number of skipped steps. More...
 
void getOrigin (IlvPoint &p) const
 Gets the origin of this scale. More...
 
IlvPosition getPosition () const
 Gets the position of the ticks of this scale. More...
 
IlvDim getSize () const
 Gets the size of this scale. More...
 
IlBoolean hasVerticalLabels () const
 Gets the 'vertical labels' flag. More...
 
IlBoolean isStepSizeFixed () const
 Gets the 'fixed step size' flag. More...
 
virtual void labelBBox (IlvRect &rect, IlUShort idx, const IlvPoint &orig, const IlvFloatPoint &offset, const IlvPoint &tickoffset, const IlvTransformer *t=0) const
 Gets a label bounding box. More...
 
virtual void labelsBBox (IlvRect &rect, const IlvFloatPoint &offset, const IlvPoint &tickoffset, const IlvTransformer *t=0) const
 Gets the bounding box of all labels. More...
 
void setDirection (IlvDirection direction)
 Sets the direction of this scale. More...
 
void setOrigin (const IlvPoint &origin)
 Sets the origin of this scale. More...
 
void setPosition (IlvPosition position)
 Sets the position of the ticks of this scale. More...
 
void setSize (IlvDim size)
 Sets the size of this scale. More...
 
void setStepSizeFixed (IlBoolean flag)
 Sets the 'fixed step size' flag. More...
 
virtual void ticksBBox (IlvRect &rect, const IlvFloatPoint &offset, const IlvPoint &tickoffset, const IlvTransformer *t=0) const
 Gets the bounding box of all ticks. More...
 
void useVerticalLabels (IlBoolean flag)
 Sets the 'vertical labels' flag. More...
 
- Public Member Functions inherited from IlvScale
 IlvScale (IlvDisplay *display, const IlvRect &drawrect, const char *format=0, IlFloat min=0, IlFloat max=100, IlUShort steps=0, IlUShort substeps=0, IlUShort stepsize=10, IlUShort substepsize=5, IlvPalette *palette=0)
 Constructor. More...
 
 IlvScale (IlvDisplay *display, const IlvRect &drawrect, char *labels[], IlUShort steps=2, IlUShort substeps=0, IlUShort stepsize=10, IlUShort substepsize=5, IlvPalette *palette=0)
 Constructor. More...
 
const char * getFormat () const
 Gets the format of the step labels. More...
 
const char * getLabel (IlUShort idx) const
 Gets a label. More...
 
char *const * getLabels () const
 Gets the labels. More...
 
void getLabelSizes (IlUShort idx, IlvDim &w, IlvDim &h, IlvDim &d) const
 Gets a label's sizes. More...
 
IlFloat getMax () const
 Gets the maximum value of the scale. More...
 
IlFloat getMin () const
 Gets the minimum value of the scale. More...
 
IlUShort getSteps () const
 Gets the number of steps. More...
 
IlUShort getStepSize () const
 Gets the step size. More...
 
IlUShort getSubSteps () const
 Gets the number of substeps. More...
 
IlUShort getSubStepSize () const
 Gets the substep size. More...
 
virtual void setFont (IlvFont *)
 Sets the font of the object. More...
 
void setFormat (const char *format)
 Sets the format of the step labels. More...
 
void setLabel (IlUShort idx, const char *label)
 Sets a label. More...
 
void setLabels (IlUShort count, const char *const *labels=0)
 Sets the labels. More...
 
void setLabels (IlUShort count, IlFloat min, IlFloat max, const char *format)
 Sets the labels. More...
 
void setMax (IlFloat max)
 Sets the maximum value of the scale. More...
 
void setMin (IlFloat min)
 Sets the minimum value of the scale. More...
 
virtual void setPalette (IlvPalette *)
 Sets the internal palette. More...
 
void setSteps (IlUShort steps)
 Sets the number of steps. More...
 
void setStepSize (IlUShort stepsize)
 Sets the step size. More...
 
void setSubSteps (IlUShort substeps)
 Sets the number of substeps. More...
 
void setSubStepSize (IlUShort substepsize)
 Sets the substep size. More...
 
- Public Member Functions inherited from IlvSimpleGraphic
 IlvSimpleGraphic (IlvDisplay *display, IlvPalette *palette=0)
 Initializes a new IlvSimpleGraphic. More...
 
virtual ~IlvSimpleGraphic ()
 Destructor. More...
 
virtual void applyResources (const char *, const char *, const char *, const char *, IlvDisplay *=0)
 Applies resources on a graphic object. More...
 
IlvIntensity getAlpha () const
 Retrieves the alpha value. More...
 
IlvAntialiasingMode getAntialiasingMode () const
 Retrieves the anti-aliasing mode. More...
 
IlvArcMode getArcMode () const
 Retrieves the arc mode. More...
 
IlvColorgetBackground () const
 Retrieves the background color. More...
 
IlvColorPatterngetColorPattern () const
 Retrieves the color pattern. More...
 
virtual IlvDisplaygetDisplay () const
 Retrieves the IlvDisplay instance. More...
 
IlvFillRule getFillRule () const
 Retrieves the fill rule. More...
 
IlvFillStyle getFillStyle () const
 Retrieves the fill style. More...
 
IlvFontgetFont () const
 Retrieves the font. More...
 
IlvColorgetForeground () const
 Retrieves the foreground color. More...
 
IlvGradientPatterngetGradientPattern () const
 Retrieves the gradient pattern. More...
 
IlvLineStylegetLineStyle () const
 Retrieves the line style. More...
 
IlUShort getLineWidth () const
 Retrieves the line width. More...
 
virtual IlvLookFeelHandlergetLookFeelHandler () const
 Returns the look & feel handler used by this object. More...
 
virtual int getLookupStringInputMethod (IlvEvent &event, char *bufferReturn, int bytesBuffer, int *statusReturn)
 Gets the preedit string from an input method. More...
 
IlvDrawMode getMode () const
 Retrieves the draw mode. More...
 
IlBoolean getOverwrite () const
 Retrieves the overwrite mode. More...
 
IlvPalettegetPalette () const
 Retrieves the internal palette value. More...
 
IlvPatterngetPattern () const
 Retrieves the pattern. More...
 
virtual void invert (IlBoolean=IlFalse)
 Highlights the object. More...
 
virtual void registerInputMethod () const
 Controls the connection of a graphic object to an input method. More...
 
virtual void setAlpha (IlvIntensity)
 Sets the alpha value of the object. More...
 
virtual void setAntialiasingMode (IlvAntialiasingMode)
 Sets the anti-aliasing mode of the object. More...
 
virtual void setArcMode (IlvArcMode)
 Sets the arc mode of the object. More...
 
virtual void setBackground (IlvColor *)
 Sets the background color of the object. More...
 
virtual void setColorPattern (IlvColorPattern *)
 Sets the color pattern of the object. More...
 
virtual void setFillRule (IlvFillRule)
 Sets the fill rule of the object. More...
 
virtual void setFillStyle (IlvFillStyle)
 Sets the fill style of the object. More...
 
virtual void setFocusValuesInputMethod (IlUShort count, const IlvImValue *values) const
 Controls the interaction between a simple graphic object and an input method. More...
 
virtual void setForeground (IlvColor *)
 Sets the foreground color of the object. More...
 
virtual void setGradientPattern (IlvGradientPattern *)
 Sets the gradient pattern of the object. More...
 
virtual void setHolder (IlvGraphicHolder *)
 Sets the object's holder. More...
 
virtual void setLineStyle (IlvLineStyle *)
 Sets the line style of the object. More...
 
virtual void setLineWidth (IlUShort)
 Sets the line width of the object. More...
 
virtual void setMode (IlvDrawMode)
 Sets the drawing mode of the object temporarily. More...
 
virtual void setOverwrite (IlBoolean)
 Sets an overwrite mode that modifies how the drawing member functions operate. More...
 
virtual void setPattern (IlvPattern *)
 Sets the pattern of the object. More...
 
virtual void setValuesInputMethod (IlUShort count, const IlvImValue *values) const
 Controls the interaction between a graphic object and an input method. More...
 
virtual void unRegisterInputMethod () const
 Controls the disconnection of a graphic object from an input method. More...
 
virtual void unsetFocusInputMethod () const
 Controls the interaction between a graphic object and an input method. More...
 
- Public Member Functions inherited from IlvGraphic
void addCallback (const IlSymbol *callbackType, IlvGraphicCallback callback)
 Adds a callback function to a callback list. More...
 
void addCallback (const IlSymbol *callbackType, const IlSymbol *callbackName, const IlSymbol *script=0)
 Adds a callback function to a callback list. More...
 
void addCallback (const IlSymbol *callbackType, IlvGraphicCallback callbackName, IlAny data)
 Adds a callback function to a callback list. More...
 
void addClassProperty (const IlSymbol *key, IlAny value)
 Adds a property to this object's class. More...
 
void addProperty (const IlSymbol *key, IlAny value)
 Adds a specific property to the object. More...
 
void addTag (const IlSymbol *tag)
 Adds a tag. More...
 
virtual void apply (IlvApplyObject function, IlAny arg)
 Applies a function to objects that compose another object. More...
 
IlBoolean applyAttribute (const char *attributeClassName, IlInt value, IlAny checkData=0) const
 Applies attributes. More...
 
IlBoolean applyAttribute (const char *attributeClassName, IlFloat value, IlAny checkData=0) const
 Applies attributes. More...
 
IlBoolean applyAttribute (const char *attributeClassName, const char *value, IlAny checkData=0) const
 Applies attributes. More...
 
virtual void applyReferences (IlvApplyObject function, IlAny arg)
 Applies a function to objects that are referenced by another object. More...
 
virtual void callCallbacks (const IlSymbol *callbackType)
 Calls every callback of a given type. More...
 
const char * className () const
 Returns the class name of an object. More...
 
virtual void computeFocusRegion (IlvRegion &r, const IlvTransformer *t=0) const
 Computes the region needed for the drawing of the focus. More...
 
virtual IlBoolean contains (const IlvPoint &p, const IlvPoint &tp, const IlvTransformer *t=0) const
 Checks whether a point is in the object. More...
 
IlBoolean contains (const IlvPoint &p) const
 Checks whether a point is in the object. More...
 
virtual IlvGraphiccopy () const =0
 Copies this object. More...
 
void draw (IlvPort *dst, const IlvTransformer *t, const IlvRect *clip) const
 Draws a graphic object. More...
 
virtual void drawFocus (IlvPort *dst, const IlvPalette *palette, const IlvTransformer *t=0, const IlvRegion *clip=0) const
 Draws additional drawings for an object that has the keyboard focus. More...
 
virtual void getAccessors (const IlSymbol *const **, const IlvValueTypeClass *const **, IlUInt &) const
 Retrieves the list of available accessors of an object. More...
 
IlvGraphicCallback getCallback (const IlSymbol *callbackType) const
 Gets a callback. More...
 
IlvGraphicCallback getCallback () const
 Gets the main callback function. More...
 
IlAny getCallbackData (const IlSymbol *callbackType, IlvGraphicCallback callback) const
 Gets a callback user data. More...
 
IlAny getCallbackData (const IlSymbol *callbackType, const IlSymbol *callbackName) const
 Gets a callback user data. More...
 
IlSymbolgetCallbackName (const IlSymbol *callbackType) const
 Gets the name of a callback. More...
 
IlSymbolgetCallbackName () const
 Gets the symbol that identifies the main callback. More...
 
virtual IlUInt getCallbackTypes (const char *const **names, const IlSymbol *const **types) const
 Gets the number of register callback types for the object. More...
 
virtual IlvGraphicgetChildAt (IlUInt index) const
 Returns the sub-object of the graphic object specified by index. More...
 
virtual IlvGraphicgetChildByName (const char *name) const
 Returns the sub-object of the graphic object specified by a name. More...
 
virtual IlUInt getChildCount () const
 Returns the number of children of this graphic object. More...
 
virtual IlInt getChildIndex (const IlvGraphic *object) const
 Returns the index of the specified sub-object in this graphic object. More...
 
virtual IlvGraphic *const * getChildren (IlUInt &count) const
 Returns an array containing the sub-objects of this graphic object. More...
 
virtual IlvClassInfogetClassInfo () const
 Gets class information. More...
 
IlAny getClassProperty (const IlSymbol *key, IlBoolean checkParent=IlFalse) const
 Retrieves the indicated property value in the class of this object. More...
 
IlAny getClientData () const
 Gets client data. More...
 
virtual const char * getDefaultInteractor () const
 Gets the name of the default interactor for this object. More...
 
virtual IlvGraphicHoldergetHolder () const
 Gets a pointer to an object's holder. More...
 
IlvInteractorgetInteractor () const
 Returns the interactor associated with the current object. More...
 
const char * getName () const
 Gets the name of the object. More...
 
IlvNamedPropertygetNamedProperty (const IlSymbol *name) const
 Gets a named property. More...
 
IlSymbolgetNextFocusGraphic () const
 Gets the next object in the focus chain. More...
 
IlSymbolgetPreviousFocusGraphic () const
 Gets the previous object in the focus chain. More...
 
IlAny getProperty (const IlSymbol *key) const
 Gets a property. More...
 
IlvSmartSetgetSmartSet () const
 Gets the smart set object containing this graphic object. More...
 
const IlSymbol *const * getTags (IlUInt &count) const
 Returns all the tags applied to this object. More...
 
IlvDim h () const
 Gets the height value of the object. More...
 
void h (IlvDim h)
 Sets the height value of the object. More...
 
IlBoolean hasCallback (const IlSymbol *callbackType, IlvGraphicCallback callback) const
 Checks whether a callback function is in a callback list. More...
 
IlBoolean hasCallback (const IlSymbol *callbackType, const IlSymbol *callbackName) const
 Checks whether a callback function is in a callback list. More...
 
IlBoolean hasCallbackData (const IlSymbol *callbackType, IlvGraphicCallback callback) const
 Checks whether a callback function has user data. More...
 
IlBoolean hasCallbackData (const IlSymbol *callbackType, const IlSymbol *callbackName) const
 Checks whether a callback function has user data. More...
 
const IlvClassInfohasClassProperty (const IlSymbol *key, IlBoolean s=IlFalse) const
 Checks for a class where the keyed property exists. More...
 
IlBoolean hasProperty (const IlSymbol *key) const
 Checks whether the object has a particular property. More...
 
IlBoolean hasTag (const IlSymbol *tag) const
 Checks whether the object has a specific tag. More...
 
virtual IlBoolean inside (const IlvRegion &r, const IlvTransformer *t=0) const
 Determines whether an object with transformation applied is inside the bounding box. More...
 
IlBoolean inside (const IlvRect &r, const IlvRect &tr, const IlvTransformer *t=0) const
 Determines whether an object with transformation applied is inside the bounding box. More...
 
IlBoolean inside (const IlvRect &r) const
 Determines whether a rectangle is inside the bounding box. More...
 
virtual IlBoolean intersects (const IlvRegion &r, const IlvTransformer *t=0) const
 Checks whether a region intersects the bounding box with transformation applied. More...
 
IlBoolean intersects (const IlvRect &r, const IlvRect &tr, const IlvTransformer *t=0) const
 Checks whether a rectangle intersects the bounding box with transformation applied. More...
 
IlBoolean intersects (const IlvRect &r) const
 Checks whether a rectangle intersects the bounding box. More...
 
IlBoolean isFirstFocusGraphic () const
 Checks whether the object is first in the focus chain. More...
 
IlBoolean isFocusable () const
 Checks whether the object can receive the keyboard focus. More...
 
IlBoolean isInSmartSet () const
 Checks whether a graphic object belongs to a smart set. More...
 
IlBoolean isLastFocusGraphic () const
 Checks whether the object is last in the focus chain. More...
 
IlBoolean isSensitive () const
 Checks whether the object is sensitive. More...
 
IlBoolean isSubtypeOf (const char *parentClass) const
 Checks whether this object's class is a subclass of a given parent class. More...
 
IlBoolean isSubtypeOf (const IlvClassInfo *classInfo) const
 Checks whether this object's class is a subclass. More...
 
virtual void move (IlvPos x, IlvPos y)
 Moves the graphic object. More...
 
void move (const IlvPoint &p)
 Moves the graphic object. More...
 
void moveResize (const IlvRect &size)
 Moves and resizes a graphic object. More...
 
virtual IlBoolean needsInputContext () const
 Indicates whether the graphic instance can connect to an input method for locale dependent input. More...
 
virtual void print (std::ostream &out, int level=0) const
 Prints for debugging purposes. More...
 
void removeCallback (const IlSymbol *callbackType, IlvGraphicCallback callback)
 Removes a callback function from a callback list. More...
 
void removeCallback (const IlSymbol *callbackType, const IlSymbol *callbackName)
 Removes a callback function from a callback list. More...
 
IlBoolean removeClassProperty (const IlSymbol *key)
 Removes a property from this object's class. More...
 
void removeInteractor ()
 Removes the interactor from the current object. More...
 
IlvNamedPropertyremoveNamedProperty (IlSymbol *name)
 Removes a named property from the object. More...
 
IlBoolean removeProperty (const IlSymbol *key)
 Removes a property from the object. More...
 
void removeTag (const IlSymbol *tag)
 Removes a tag. More...
 
IlBoolean replaceClassProperty (const IlSymbol *key, IlAny value)
 Replaces a property in this object's class. More...
 
IlBoolean replaceProperty (const IlSymbol *key, IlAny value)
 Replaces a property. More...
 
virtual void resize (IlvDim newW, IlvDim newH)
 Resizes a graphic object. More...
 
virtual void rotate (const IlvPoint &center, IlFloat angle)
 Rotates a graphic object. More...
 
virtual void scale (IlFloat zoomX, IlFloat zoomY)
 Scales the graphic object. More...
 
void setCallback (const IlSymbol *callbackType, IlvGraphicCallback callback)
 Sets a new callback. More...
 
void setCallback (const IlSymbol *callbackType, const IlSymbol *callbackName, const IlSymbol *script=0)
 Removes all previously set callbacks. More...
 
void setCallback (const IlSymbol *callbackType, IlvGraphicCallback callbackName, IlAny data)
 Removes all previously set callbacks. More...
 
void setCallback (IlvGraphicCallback callback, IlAny data)
 Sets the main callback function. More...
 
void setCallbackData (const IlSymbol *callbackType, IlvGraphicCallback callback, IlAny data)
 Sets the callback user data for a callback function. More...
 
void setCallbackData (const IlSymbol *callbackType, const IlSymbol *callbackName, IlAny data)
 Sets the callback user data for a callback function. More...
 
void setCallbackName (const IlSymbol *callbackName)
 Sets the symbol that identifies the main callback. More...
 
void setClientData (IlAny clientData)
 Sets client data. More...
 
void setFirstFocusGraphic ()
 Sets the object to be first in the focus chain.
 
void setFocusable (IlBoolean value)
 Set the focusable state of the object. More...
 
IlBoolean setInteractor (IlvInteractor *inter)
 Attaches an interactor to the current object. More...
 
IlBoolean setInteractor (const char *name)
 Attaches an interactor to this graphic object. More...
 
void setLastFocusGraphic ()
 Sets the object to be last in the focus chain.
 
virtual void setName (const char *name)
 Sets the name of the object. More...
 
IlvNamedPropertysetNamedProperty (IlvNamedProperty *property)
 Sets a named property on the object. More...
 
virtual void setNeedsInputContext (IlBoolean val)
 Specifies whether the graphic object should have locale dependent input. More...
 
void setNextFocusGraphic (IlSymbol *name)
 Sets the object to be next in the focus chain. More...
 
void setPreviousFocusGraphic (IlSymbol *name)
 Sets an object as previous in the focus chain. More...
 
void setProperty (const IlSymbol *key, IlAny value)
 Sets a property of the object to a value. More...
 
virtual void setSensitive (IlBoolean value)
 Sets the sensitivity of the object. More...
 
virtual void symmetry (IlvDirection axis)
 Flips a graphic object. More...
 
virtual void translate (IlvPos dx, IlvPos dy)
 Applies a transformation function on a graphic object. More...
 
IlvDim w () const
 Gets the width value of the object. More...
 
void w (IlvDim w)
 Sets the width value of the object. More...
 
virtual void write (IlvOutputFile &output) const =0
 Writes an object description to a file. More...
 
IlvPos x () const
 Gets the x coordinate value of the object. More...
 
void x (IlvPos x)
 Sets the x coordinate value of the object. More...
 
IlvPos y () const
 Gets the y coordinate value of the object. More...
 
void y (IlvPos y)
 Sets the y coordinate value of the object. More...
 
virtual IlBoolean zoomable () const
 Checks whether this object is zoomable. More...
 
- Public Member Functions inherited from IlvValueInterface
virtual IlBoolean applyValue (const IlvValue &value)
 Apply an accessor. More...
 
virtual IlBoolean changeValue (const IlvValue &val)
 Changes the value of an accessor. More...
 
virtual IlBoolean changeValues (const IlvValue *values, IlUShort count=0)
 Changes several accessor values simultaneously. More...
 
virtual IlvValuequeryValue (IlvValue &val) const
 Retrieves an accessor value. More...
 
virtual void queryValues (IlvValue *values, IlUShort count) const
 Retrieves multiple accessor values simultaneously. More...
 

Additional Inherited Members

- Static Public Member Functions inherited from IlvGraphic
static void AddProperty (const IlSymbol *key, IlAny value)
 Adds a property to this object's class. More...
 
static void AddToCallbackTypeList (IlUInt &count, const char *const **names, const IlSymbol *const **types, const char *newName, const IlSymbol *newType)
 Adds a callback to a list. More...
 
static void AllowZoom (IlBoolean az)
 Sets or inhibits zooming. More...
 
static IlvClassInfoClassInfo () const
 Gets class information. More...
 
static IlAny GetProperty (const IlSymbol *key, IlBoolean checkSuperClass=IlFalse)
 Retrieves the property value associated with the key in this object's class. More...
 
static const IlvClassInfoHasProperty (const IlSymbol *key, IlBoolean checkSuperClass=IlFalse)
 Checks for the existence of a property for this object's class hierarchy. More...
 
static IlBoolean IsZoomAllowed ()
 Checks whether zoomable objects can display themselves when zooming out. More...
 
static IlvGraphicread (IlvInputFile &file, IlvPalette *palette)
 Reads an object description from a file. More...
 
static IlBoolean RemoveProperty (const IlSymbol *key)
 Removes a property from this object's class. More...
 
static IlBoolean ReplaceProperty (const IlSymbol *key, IlAny value)
 Replaces a property in this object's class. More...
 

Detailed Description

Graphic class.

Library: views

Use this class to create horizontal and vertical scales like those shown in the following figure:


- IlvRectangularScale -

See also
IlvCircularScale, IlvGauge.

Accessors

Accessors provide a scriptable and uniform way to inspect and modify an object by using its base class methods IlvValueInterface::queryValue(), IlvValueInterface::queryValues(), IlvValueInterface::changeValue(), IlvValueInterface::changeValues(). This class inherits the accessors of its superclass IlvScale and adds the following ones:

Name Type Equivalent methods
originX Int getOrigin(), setOrigin()
originY Int getOrigin(), setOrigin()
size UInt getSize(), setSize()
direction Direction getDirection(), setDirection()
position Direction getPosition(), setPosition()
stepSizeFixed Boolean isStepSizeFixed(), setStepSizeFixed()
verticalLabels Boolean hasVerticalLabels(), useVerticalLabels()
centerLabels Boolean areLabelsCentered(), centerLabels()
drawOverlappingLabels Boolean doesDrawOverlappingLabels(), drawOverlappingLabels()

Constructor & Destructor Documentation

IlvRectangularScale::IlvRectangularScale ( IlvDisplay display,
const IlvPoint orig,
IlvDim  size,
const char *  format,
IlFloat  min,
IlFloat  max,
IlvDirection  direction = IlvVertical,
IlvPosition  position = IlvLeft,
IlUShort  steps = 0,
IlUShort  substeps = 0,
IlUShort  stepsize = 10,
IlUShort  substepsize = 5,
IlvPalette palette = 0 
)

Constructor.

The bounding box of the new scale depends on its origin and size, but also on the direction and position parameters. The origin of the scale must not be confused with the origin of the rectangle that contains it, which is located at the upper-left corner of its bounding box.

Parameters
displayThe display where this object is created.
origThe origin of the scale.
sizeThe dimension of the scale's main axis: the width of the scale if it is horizontal, and its height if it is vertical.
formatThe printf() format of the step labels.
minThe minimum value of the scale.
maxThe maximum value of the scale.
directionThe direction of the scale. Valid values are IlvVertical (bottom to top) and IlvHorizontal (left to right).
positionThe position of the scale. Valid values depend on direction: IlvLeft and IlvRight for a vertical scale, IlvTop and IlvBottom for a horizontal scale.
stepsThe number of major ticks to be drawn, which can be 0 for no scales.
substepsThe number of minor ticks displayed between major ones.
stepsizeThe major tick mark size.
substepsizeThe minor tick mark size.
paletteThe palette associated with this object.
IlvRectangularScale::IlvRectangularScale ( IlvDisplay display,
const IlvPoint orig,
IlvDim  size,
char *  labels[],
IlvDirection  direction = IlvVertical,
IlvPosition  position = IlvLeft,
IlUShort  steps = 2,
IlUShort  substeps = 0,
IlUShort  stepsize = 10,
IlUShort  substepsize = 5,
IlvPalette palette = 0 
)

Constructor.

The point orig specifies the origin of the scale. Its position varies depending on the direction and position parameters. The origin of the scale should not be confused with the origin of the rectangle that contains it, which is located at the upper-left corner. The parameter size specifies the dimension of the scale in its main axis (width for horizontal scale and height for a vertical scale). The direction of the scale is indicated by direction: valid values are IlvVertical (bottom to top) and IlvHorizontal (left to right). The position of the scale is specified by position. Valid values depend on direction: IlvLeft and IlvRight for a vertical scale, IlvTop and IlvBottom for a horizontal scale.

Parameters
displayThe display where this object is created.
origThe origin of the scale.
sizeThe dimension of the scale's main axis.
labels[]The array of text strings.
directionThe direction of the scale.
positionThe position of the scale.
stepsThe number of major ticks to be drawn, which can be 0 for no scales.
substepsThe number of minor ticks displayed between major ones.
stepsizeThe major tick mark size.
substepsizeThe minor tick mark size.
paletteThe palette associated with this object.

Member Function Documentation

virtual void IlvRectangularScale::applyTransform ( const IlvTransformer t)
virtual

Applies a transformation function to the graphic object.

Applies the transformer t to the shape of the object. Unless the transformation is a scaling operation, the result of applying it to certain objects can be insignificant. For example, applying a non-scaling transformer to an IlvRectangle object is meaningless, since the rectangle remains a rectangle. On the other hand, meaningful transformations can be applied to objects that are instances of types such as IlvLine or IlvPolyPoints.

Note
applyTransform() is one of the most important method to be rewritten for classes derived from IlvGraphic, since it is called by the resize(), move(), moveResize(), scale(), etc., methods.
Parameters
tThe transformer value. If 0, no transformation is performed.

Reimplemented from IlvScale.

IlBoolean IlvRectangularScale::areLabelsCentered ( ) const

Gets the 'centered labels' flag.

Returns
IlTrue if the scale draws its labels between the markers, or IlFalse if it draws each label with its corresponding marker.
See also
centerLabels().
virtual void IlvRectangularScale::boundingBox ( IlvRect bbox,
const IlvTransformer t = 0 
) const
virtual

Retrieves the bounding box of the graphic object.

Sets bbox, the rectangle reference parameter, to be the bounding box of the object. Since the object can appear within a transformed environment (for example, in a multiview editor), an IlvTransformer object occurs as an optional parameter in order to compute the bounding box in the coordinate system of the transformed environment.

Parameters
bboxThe bounding box to be set.
tA transformer value or 0 if there is no transformation.

Implements IlvScale.

void IlvRectangularScale::centerLabels ( IlBoolean  flag)

Sets the 'centered labels' flag.

Parameters
flagThe new value of the the 'centered labels' flag of this scale object.
See also
areLabelsCentered().
IlBoolean IlvRectangularScale::doesDrawOverlappingLabels ( ) const

Gets the 'draw overlapping labels' flag.

Returns
IlTrue if the scale allows labels to overlap, and IlFalse otherwise.
See also
drawOverlappingLabels().
virtual void IlvRectangularScale::draw ( IlvPort dst,
const IlvTransformer t = 0,
const IlvRegion clip = 0 
) const
virtual

Draws the graphic object.

Draws the object in the given IlvPort using the transformer t.

Parameters
dstThe destination port this object is drawn onto.
tThe transformer value. If 0, no transformation is performed.
clipThe clipping region, relative to the transformed object, or 0 if none.

Implements IlvScale.

virtual void IlvRectangularScale::drawBaseLine ( IlvPort dst,
const IlvTransformer t = 0,
const IlvRegion clip = 0 
) const
virtual

Draws the base line.

Draws a line from the origin to the last scale marker.

Parameters
dstThe drawing port.
tThe transformer to apply.
clipThe clipping region to respect.
virtual void IlvRectangularScale::drawLabel ( IlvPort dst,
IlUShort  idx,
const IlvPoint orig,
const IlvFloatPoint offset,
const IlvPoint tickoffset,
const IlvTransformer t = 0,
const IlvRegion clip = 0 
) const
virtual

Draws a label.

Draws a scale label at the position indicated by index, in the dst port. origin indicates the location of the minimum value representation on the scale.
The offset values allow the dimensions to be handled, without considering whether the values are positive or negative (this is handled elsewhere). offset is the offset of the origin of two major ticks. tickoffset is the absolute offset of the extremity of a tick to its origin.

Parameters
dstThe drawing port.
idxThe label position to draw.
origThe location of the minimum value representation on the scale.
offsetThe offset of the origin of two major ticks.
tickoffsetThe absolute tick offset to the origin.
tA transformation.
clipThe clipping region to respect.
virtual void IlvRectangularScale::drawLabels ( IlvPort dst,
const IlvTransformer t = 0,
const IlvRegion clip = 0 
) const
virtual

Draws all labels.

Draws the scale labels, computing the two different offsets and calls the drawLabel() member function for each label in the scale. See drawLabel().

Parameters
dstThe drawing port.
tA transformation.
clipThe clipping region to respect.
void IlvRectangularScale::drawOverlappingLabels ( IlBoolean  val)

Sets the 'draw overlapping labels' flag.

Allows or disallows labels from overlapping.

Parameters
valThe new value of the the 'draw overlapping labels' flag of this scale object.
See also
doesDrawOverlappingLabels().
virtual void IlvRectangularScale::drawTick ( IlvPort dst,
IlUShort  idx,
const IlvPoint orig,
const IlvFloatPoint offset,
const IlvFloatPoint suboffset,
const IlvPoint tickoffset,
const IlvPoint subtickoffset,
const IlvTransformer t = 0,
const IlvRegion clip = 0 
) const
virtual

Draws a tick mark.

Draws a scale marker at the position indicated by index, in the dst port. origin indicates the location of the minimum value representation on the scale.
The offset values allow the dimensions to be handled, without considering whether the values are positive or negative (this is handled elsewhere). offset is the offset between the origins of two major ticks, suboffset is the offset between the origins of two minor ticks, tickoffset is the offset from the major tick line origin to its extremity, and subtickoffset is the offset from the origin of the minor tick line to its extremity.

Parameters
dstThe drawing port.
idxThe label position to draw.
origThe location of the minimum value representation on the scale.
offsetThe offset of the origin of two major ticks.
suboffsetThe offset of the origin of two minor ticks.
tickoffsetThe absolute major tick offset to the origin.
subtickoffsetThe absolute minor tick offset to the origin.
tA transformation.
clipThe clipping region to respect.
virtual void IlvRectangularScale::drawTicks ( IlvPort dst,
const IlvTransformer t = 0,
const IlvRegion clip = 0 
) const
virtual

Draws all tick marks.

Draws the scale markers, computing the four different offsets and calls the drawTick member function for each tick in the scale. See drawTick().

Parameters
dstThe drawing port.
tThe transformer that applies.
clipThe clipping region to respect.
IlvDirection IlvRectangularScale::getDirection ( ) const

Gets the direction of this scale.

Returns
The direction of this scale.
See also
setDirection().
virtual IlUShort IlvRectangularScale::getNumberOfSkippedSteps ( const IlvPoint orig,
IlvDim  size,
IlUShort  steps,
const IlvFloatPoint offset,
const IlvPoint tickoffset,
const IlvTransformer t = 0 
) const
virtual

Gets the number of skipped steps.

Returns
The number of steps to skip when drawing the scale labels and tick marks. The return value is 1 if the draw overlapping labels flag is set to IlTrue. Overload this function if you want to control the display of scale labels on the screen (Show only odd or even numbers.)
void IlvRectangularScale::getOrigin ( IlvPoint p) const

Gets the origin of this scale.

Returns
The location of origin of this scale.
See also
setOrigin().
IlvPosition IlvRectangularScale::getPosition ( ) const

Gets the position of the ticks of this scale.

Returns
The position of the ticks of this scale.
See also
setPosition().
IlvDim IlvRectangularScale::getSize ( ) const

Gets the size of this scale.

Returns
The size (the width or the height) of this scale. The size is the distance from the minimum to maximum tick marks on the scale.
See also
setSize().
IlBoolean IlvRectangularScale::hasVerticalLabels ( ) const

Gets the 'vertical labels' flag.

Returns
IlTrue if the scale draws its labels in a vertical direction, or IlFalse if it draws them in a horizontal direction.
See also
useVerticalLabels().
IlBoolean IlvRectangularScale::isStepSizeFixed ( ) const

Gets the 'fixed step size' flag.

Returns
IlTrue if the scale has a fixed step size (i.e., distance between two markers), or IlFalse if this distance varies to make the scale fit its size.
See also
setStepSizeFixed().
virtual void IlvRectangularScale::labelBBox ( IlvRect rect,
IlUShort  idx,
const IlvPoint orig,
const IlvFloatPoint offset,
const IlvPoint tickoffset,
const IlvTransformer t = 0 
) const
virtual

Gets a label bounding box.

Uses the rect parameter to return the bounding box of the label of the scale at the position indicated by idx.

Parameters
rectReturn value holding the bounding box coordinates.
idxThe index position of the label.
origIs set to the location of the scale origin.
offsetThe offset of the major ticks, from the origin.
tickoffsetThe offset of the major ticks, from the origin.
tThe transformer that applies.
virtual void IlvRectangularScale::labelsBBox ( IlvRect rect,
const IlvFloatPoint offset,
const IlvPoint tickoffset,
const IlvTransformer t = 0 
) const
virtual

Gets the bounding box of all labels.

Parameters
rectReturn value holding the bounding box containing all the labels of this scale.
offsetThe offset of the first major tick origin, relative to this scale's origin.
tickoffsetThe location of the first major tick end, relative to this scale's origin.
tThe transformer to apply.
void IlvRectangularScale::setDirection ( IlvDirection  direction)

Sets the direction of this scale.

Parameters
directionThe new direction of this scale. This can be IlvBottom, IlvTop, IlvLeft or IlvRight, indicating where the minimum value of the scale is positioned. This can also be IlvHorizontal, indicating that the scale goes from left to right (equivalent to IlvLeft), or IlvVertical, indicating that the scale goes from bottom to top (equivalent to IlvBottom).
See also
getDirection().
void IlvRectangularScale::setOrigin ( const IlvPoint origin)

Sets the origin of this scale.

Sets the origin of the scale (the location of the minimum value representation) to the value of the origin parameter.

Parameters
originThe new origin of this scale.
See also
getOrigin().
void IlvRectangularScale::setPosition ( IlvPosition  position)

Sets the position of the ticks of this scale.

The position indicate where the scale is drawn in relation to its bounding rectangle.

Parameters
positionThe position of the scale. If the scale is horizontal, valid values for are IlvTop and IlvBottom. If the scale is vertical, then the possible values are IlvLeft and IlvRight.
See also
getPosition().
void IlvRectangularScale::setSize ( IlvDim  size)

Sets the size of this scale.

Sets the size of the scale (the width or the height) of the scale to the value of the size parameter. The size is the distance from the minimum to maximum tick marks on the scale.

Parameters
sizeThe new dimension of this scale's main axis.
See also
getSize().
void IlvRectangularScale::setStepSizeFixed ( IlBoolean  flag)

Sets the 'fixed step size' flag.

Parameters
flagThe new value of the the 'fixed step size' flag of this scale object.
See also
isStepSizeFixed().
virtual void IlvRectangularScale::ticksBBox ( IlvRect rect,
const IlvFloatPoint offset,
const IlvPoint tickoffset,
const IlvTransformer t = 0 
) const
virtual

Gets the bounding box of all ticks.

Uses the rect parameter to return the bounding box containing all the scale markers.

Returns
In rect the bounding box containing all ticks.
void IlvRectangularScale::useVerticalLabels ( IlBoolean  flag)

Sets the 'vertical labels' flag.

Parameters
flagThe new value of the the 'vertical labels' flag of this scale object.
See also
hasVerticalLabels().

© Copyright 2016, Rogue Wave Software, Inc. All Rights Reserved.
Rogue Wave is a registered trademark of Rogue Wave Software, Inc. in the United States and other countries. All other trademarks are the property of their respective owners.