Jump to content

Component: Component Labels (Misc): Difference between revisions

From Flowcode Help
No edit summary
No edit summary
Line 17: Line 17:
==Component Source Code==
==Component Source Code==


Please click here to download the component source project: [https://www.flowcode.co.uk/wiki/componentsource/FC_Comp_Source_auto_labels.fcfx FC_Comp_Source_auto_labels.fcfx]
Please click here to download the component source project: [https://www.flowcode.co.uk/wiki/componentsource/FC_Comp_Source_temp/auto_labels.fcfx FC_Comp_Source_temp/auto_labels.fcfx]


Please click here to view the component source code (Beta): [https://www.flowcode.co.uk/FlowchartView/?wfile=componentsource/FC_Comp_Source_auto_labels.fcfx FC_Comp_Source_auto_labels.fcfx]
Please click here to view the component source code (Beta): [https://www.flowcode.co.uk/FlowchartView/?wfile=componentsource/FC_Comp_Source_temp/auto_labels.fcfx FC_Comp_Source_temp/auto_labels.fcfx]


==Detailed description==
==Detailed description==
Line 73: Line 73:


''<span style="color:red;">No additional examples</span>''
''<span style="color:red;">No additional examples</span>''




Line 81: Line 83:
==Macro reference==
==Macro reference==


===ShowProperty===
===Hide===
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
|-
|-
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''ShowProperty'''
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''Hide'''
|-
|-
| colspan="2" | Sets the labels to show a named property of each object.&nbsp;
| colspan="2" | Hides all labels.&nbsp;
|-
|-
|-
| width="10%" align="center" | [[File:Fc9-string-icon.png]] - STRING
| width="90%" | Property
|-
| colspan="2" | Name of the property to show.&nbsp;
|-
|-
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID
Line 100: Line 97:




===ShowNames===
===SetColor===
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
|-
|-
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''ShowNames'''
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''SetColor'''
|-
| colspan="2" | Sets the color of the labels.  Note that this affects all nesting levels, so any nesting level specific colors set in the properties panel will be overridden.&nbsp;
|-
|-
|-
| colspan="2" | Sets the labels to show the names of objects.&nbsp;
| width="10%" align="center" | [[File:Fc9-u32-icon.png]] - ULONG
| width="90%" | Color
|-
|-
| colspan="2" | Color to set the labels to.&nbsp;
|-
|-
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID
Line 114: Line 116:




===Hide===
===SetTarget===
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
|-
|-
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''Hide'''
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''SetTarget'''
|-
| colspan="2" | Set the target object.  All items within the scope of this object will be given labels, not the taget object itself.  If the target is set to zero or 'this', all objects in the  current scope will be labelled.&nbsp;
|-
|-
|-
| colspan="2" | Hides all labels.&nbsp;
| width="10%" align="center" | [[File:Fc9-h32-icon.png]] - HANDLE
| width="90%" | target
|-
|-
| colspan="2" | &nbsp;
|-
|-
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID
Line 128: Line 135:




===SetTarget===
===ShowNames===
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
|-
|-
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''SetTarget'''
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''ShowNames'''
|-
|-
| colspan="2" | Set the target object.  All items within the scope of this object will be given labels, not the taget object itself.  If the target is set to zero or 'this', all objects in the  current scope will be labelled.&nbsp;
| colspan="2" | Sets the labels to show the names of objects.&nbsp;
|-
|-
|-
| width="10%" align="center" | [[File:Fc9-h32-icon.png]] - HANDLE
| width="90%" | target
|-
| colspan="2" | &nbsp;
|-
|-
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID
Line 147: Line 149:




===SetColor===
===ShowProperty===
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
|-
|-
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''SetColor'''
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''ShowProperty'''
|-
|-
| colspan="2" | Sets the color of the labels.  Note that this affects all nesting levels, so any nesting level specific colors set in the properties panel will be overridden.&nbsp;
| colspan="2" | Sets the labels to show a named property of each object.&nbsp;
|-
|-
|-
|-
| width="10%" align="center" | [[File:Fc9-u32-icon.png]] - ULONG
| width="10%" align="center" | [[File:Fc9-string-icon.png]] - STRING
| width="90%" | Color
| width="90%" | Property
|-
|-
| colspan="2" | Color to set the labels to.&nbsp;
| colspan="2" | Name of the property to show.&nbsp;
|-
|-
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID

Revision as of 12:03, 3 February 2023

Author Matrix Ltd.
Version 1.2
Category Misc


Component Labels component

Automatically generates labels for all panel objects and components in a given context. Labels will always face the camera, and can show the name of each object, or any chosen property. Nesting can be used so that components within components are labelled, and so on.

Component Source Code

Please click here to download the component source project: FC_Comp_Source_temp/auto_labels.fcfx

Please click here to view the component source code (Beta): FC_Comp_Source_temp/auto_labels.fcfx

Detailed description

No detailed description exists yet for this component

Examples

No additional examples





Macro reference

Hide

Hide
Hides all labels. 
- VOID Return


SetColor

SetColor
Sets the color of the labels. Note that this affects all nesting levels, so any nesting level specific colors set in the properties panel will be overridden. 
- ULONG Color
Color to set the labels to. 
- VOID Return


SetTarget

SetTarget
Set the target object. All items within the scope of this object will be given labels, not the taget object itself. If the target is set to zero or 'this', all objects in the current scope will be labelled. 
- HANDLE target
 
- VOID Return


ShowNames

ShowNames
Sets the labels to show the names of objects. 
- VOID Return


ShowProperty

ShowProperty
Sets the labels to show a named property of each object. 
- STRING Property
Name of the property to show. 
- VOID Return


Update

Update
Refresh the labels after a change. 
- VOID Return



Property reference

Properties
Show
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. 
Auto Update
Automatically update the labels whenever panel items are added, deleted or re-named. 
Auto Target
When auto target is on, the auto labeller will label every item in its own context. When off, the "SetTarget" macro must be used to set the scope of the labeller. 
Appearance
Color
Color of the labels text. 
Background
Color for label backgroiunds - may be transparent. 
Always On Top
Whether labels should always be draw on top of other objects. 
Size
Scale
Sets the basic size (text height) of the labels. 
Follow Zoom
Whether labels get bigger and smaller when the panel is zoomed in and out. 
Offset
Auto
Attempt to automatically move the label to the side of the object. Choose a positive or negative offset in any of the three axes. When 'off' is chosen, you will be able to enter manual offsets along each axis. 
Nesting
Nesting
Whether to label child items of groups, groups within groups etc. Off - only items at the same level as the labeller get labelled. Nest levels - how many 'generations' to iterate into groups. Show Leaves - does not label groups, but labels all individual items, no matter how far nested.