Difference between revisions of "Component: Component Label (Simulation)"

From Flowcode Help
Jump to navigationJump to search
(XML import)
 
(XML import)
Line 15: Line 15:
  
  
==[[Media:Component Icon c5be1da0_4b4c_49b9_82e5_ea2426f52606.png|Image]] Component Label component==
+
==[[File:Component Icon c5be1da0_4b4c_49b9_82e5_ea2426f52606.png|Image]] Component Label component==
 
Generates a label for a component.  When placed insdie a component, it will produce a
 
Generates a label for a component.  When placed insdie a component, it will produce a
 
"face me" label just outside the component bounding box.  This can show the component's
 
"face me" label just outside the component bounding box.  This can show the component's

Revision as of 13:05, 16 January 2014


Author Matrix Ltd.
Version 1.0
Category Simulation


Image Component Label component

Generates a label for a component. When placed insdie a component, it will produce a "face me" label just outside the component bounding box. This can show the component's name, or any of its properties.

Examples

No additional examples


Downloadable macro reference

This component does not contain any downloadable macros

Simulation macro reference

SetTargets

Set the objects used to determine the label text and position.

Parameters

HANDLE TextObject
Object that will provide the label text.
HANDLE BoundsObject
Object that will set the label position and bounding box.


Return value

This call does not return a value


ShowProperty

Sets the label to show a named property of the target object.

Parameters

STRING Property
Name of the property to show.


Return value

This call does not return a value


SetPosition

Set where the label will appear relative to the object.

Parameters

BYTE Position
Set the position - choose a preset from the list of constants, or 'Position XYZ to enter values below.
FLOAT X
X axis offset (only if 'Position_XYZ' selected for 'Position')
FLOAT Y
Y axis offset (only if 'Position_XYZ' selected for 'Position')
FLOAT Z
Z axis offset (only if 'Position_XYZ' selected for 'Position')


Return value

This call does not return a value


Hide

Hides the label.

Parameters

This macro has no parameters


Return value

This call does not return a value


SetColor

Sets the color of the label.

Parameters

ULONG Color
Color to set the labels to.


Return value

This call does not return a value


SetColorRGB

Set the label color using separate red, green and blue color channels.

Parameters

BYTE Red
Color parameter
BYTE Green
Color parameter
BYTE Blue
Color parameter


Return value

This call does not return a value


Update

Refresh the label after a change.

Parameters

This macro has no parameters


Return value

This call does not return a value


ShowName

Sets the label to show the target object's name

Parameters

This macro has no parameters


Return value

This call does not return a value



Property reference

Show

This property is of type Fixed list of ints and can be referenced with the variable name show_label.

Decide what labels to show...

None - no labels are displayed

Name - shows each component's name

Property - shows a particular property of each component (see 'property' below.

Label target

This property is of type Panel object and can be referenced with the variable name label_target.

Set the object from which the label text will be taken.

If none is given, defaults to the parent of the label component.

Bounds target

This property is of type Panel object and can be referenced with the variable name bounds_target.

Set the object used to set the dimensions used for the positioning of the labels.

If none is given, defaults to the parent of the label component.

Auto Update

This property is of type True or false and can be referenced with the variable name label_auto_update.

Automatically update the labels whenever the target's name or labelled property changes.

Use this sparingly, as it requires the component to regularly poll the component for changes!!

Color

This property is of type Color picker and can be referenced with the variable name label_color.

Color of the labels text.

Background

This property is of type Color picker with transparency and can be referenced with the variable name label_bg_color.

Color for label backgroiunds - may be transparent.

Always On Top

This property is of type True or false and can be referenced with the variable name label_on_top.

Whether labels should always be draw on top of other objects.

Scale

This property is of type Floating point and can be referenced with the variable name label_scale.

Sets the basic size (text height) of the labels.

Follow Zoom

This property is of type True or false and can be referenced with the variable name label_auto_scale.

Whether labels get bigger and smaller when the panel is zoomed in and out.

Auto

This property is of type Fixed list of ints and can be referenced with the variable name label_position.

Attempt to automatically move the label to the side of the object. Choose a positive or negative offset in

any of the three axes.