FME Transformers: 2025.0

Categories
Cartography and Reports
Related Transformers
LabelPointReplacer
TextAdder

Labeller

Places labels along a linear feature, angled to the orientation of each labeled segment.

Jump to Configuration

Typical Uses

  • Annotating linear features

How does it work?

The Labeller receives linear features and generates text labels at intervals along them. Labels are rotated to match the orientation of the segment being labeled, with various size and position parameters.

Collision avoidance and minimum feature length for labeling are both available.

Label Orientation

The orientation of the text varies according to the orientation of the line segment it is placed on. Text is placed parallel to the line segment.

If the line angle produces text that is upside-down (that is, between 90 and 270 degrees), the text is rotated 180 degrees.

Both the line and text angles may be added as an output attribute.

Label Placement Interval and Starting Position

Label intervals are determined by the Label Spacing and Labels at End Points parameters.

If Label Spacing is zero (0), only one label is placed.

This input feature will be labeled with a Label Height of 8. It is 100 meters long.

Action

Parameters

Result

Place one label at the start of the feature.

Label Spacing: 0

Labels at End Points: Yes

Place one label at the midpoint of the feature.

Label Spacing: 0

Labels at End Points: No

Place labels every 40 meters, and at the first and last points of the feature.

Label Spacing: 40

Labels at End Points: Yes

Place labels every 40 meters, but not at the end points.

 

Label Spacing: 40

Labels at End Points: No

Label Positioning

When an offset is applied to labels, the Label Position parameter determines where label insertion points are placed relative to the feature.

Note that left and right are relative to direction of travel along the feature - they are not the left- and right-hand side of the field of view.

This input feature will be labeled. Note its orientation, indicated by the arrow.

The labels are placed with a large Label Offset value to illustrate position.

Label Position

Placement

Result

Above or Left

Label insertion points are placed above the feature.

Where a line segment is vertical, labels are placed to the left, relative to the feature orientation.

Above or Right

Label insertion points are placed above the feature.

Where a line segment is vertical, labels are placed to the right, relative to the feature orientation.

Below or Left

Label insertion points are placed below the feature.

Where a line segment is vertical, labels are placed to the left, relative to the feature orientation.

Below or Right

Label insertion points are placed below the feature.

Where a line segment is vertical, labels are placed to the right, relative to the feature orientation.

Left

All label insertion points are placed on the left-hand side, relative to the feature orientation.

Right

All label insertion points are placed on the left-hand side, relative to the feature orientation.

Usage Notes

  • Although area geometry is accepted, the labels are placed along the perimeter of the feature which may be undesirable. Consider using a LabelPointReplacer instead.
  • Point geometry will be rejected. Consider using a LabelPointReplacer or TextAdder.
  • Awkwardly angled labels might be improved by adjusting spacing or using a Generalizer on the input feature before labeling.

Creating and Modifying Point and Text Features

These transformers work with points, text, and labels in a variety of ways.

Configuration

Input Ports

Output Ports

Parameters

Editing Transformer Parameters

Transformer parameters can be set by directly entering values, using expressions, or referencing other elements in the workspace such as attribute values or user parameters. Various editors and context menus are available to assist. To see what is available, click beside the applicable parameter.

For more information, see Transformer Parameter Menu Options.

Reference

Processing Behavior

Feature-Based

Feature Holding

No

Dependencies None
Aliases  
History  

FME Community

The FME Community has a wealth of FME knowledge with over 20,000 active members worldwide. Get help with FME, share knowledge, and connect with users globally.

Search for all results about the Labeller on the FME Community.

 

Examples may contain information licensed under the Open Government Licence – Vancouver, Open Government Licence - British Columbia, and/or Open Government Licence – Canada.