LayOut C API

- Main Page
- Related Pages
- Data Structures
- Files

- File List
- Globals

All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
label.h
Go to the documentation of this file.
1 // Copyright 2015 Trimble Navigation Ltd. All rights reserved.
2 // This file is intended for public distribution.
3
4 #ifndef LAYOUT_MODEL_LABEL_H_
5 #define LAYOUT_MODEL_LABEL_H_
6
7 #include <LayOutAPI/common.h>
8 #include <LayOutAPI/geometry/geometry.h>
9 #include <LayOutAPI/model/defs.h>
10 #include <LayOutAPI/model/formattedtext.h>
11
19 #ifdef __cplusplus
20 extern "C" {
21 #endif // __cplusplus
22
27 typedef enum {
28 LOLabelLeaderLineType_SingleSegment = 0,
29 LOLabelLeaderLineType_TwoSegment,
30 LOLabelLeaderLineType_Bezier,
31 LOLabelLeaderLineType_Unknown,
32 LONumLabelLeaderLineTypes
33 } LOLabelLeaderLineType;
34
39 typedef enum {
40 LOLabelTextConnectionType_NoConnection = 0,
41 LOLabelTextConnectionType_Automatic,
42
43 LOLabelTextConnectionType_ReverseAutomatic,
44
45
46 LOLabelTextConnectionType_TopLeft,
47 LOLabelTextConnectionType_CenterLeft,
48 LOLabelTextConnectionType_BottomLeft,
49 LOLabelTextConnectionType_TopRight,
50 LOLabelTextConnectionType_CenterRight,
51 LOLabelTextConnectionType_BottomRight,
52 LONumLabelTextConnectionTypes
53 } LOLabelTextConnectionType;
54
75 LO_RESULT LOLabelCreateAtPoint(
76 LOLabelRef* label, const LOPoint2D* anchor_point, LOFormattedTextAnchorType anchor_type,
77 const char* plain_text, LOLabelLeaderLineType leader_line_type, const LOPoint2D* target_point);
78
97 LO_RESULT LOLabelCreateWithBounds(
98 LOLabelRef* label, const LOAxisAlignedRect2D* bounds, const char* plain_text,
99 LOLabelLeaderLineType leader_line_type, const LOPoint2D* target_point);
100
108 LO_RESULT LOLabelAddReference(LOLabelRef label);
109
119 LO_RESULT LOLabelRelease(LOLabelRef* label);
120
130 LO_EXPORT LOLabelRef LOLabelFromEntity(LOEntityRef entity);
131
140 LO_EXPORT LOEntityRef LOLabelToEntity(LOLabelRef label);
141
162 LO_RESULT LOLabelGetExplodedEntities(
163 LOLabelRef label, LOEntityListRef entity_list, LOPageRef page_for_autotext);
164
183 LO_RESULT LOLabelConnectTo(LOLabelRef label, LOConnectionPointRef connection_point);
184
195 LO_RESULT LOLabelDisconnect(LOLabelRef label);
196
208 LO_RESULT LOLabelCreateLabelTextCopy(LOLabelRef label, LOFormattedTextRef* text);
209
226 LO_RESULT LOLabelCreateLabelDisplayTextCopy(
227 LOLabelRef label, LOPageRef page, LOFormattedTextRef* text);
228
242 LO_RESULT LOLabelSetLabelText(LOLabelRef label, LOFormattedTextRef text);
243
254 LO_RESULT LOLabelCreateLeaderLineCopy(LOLabelRef label, LOPathRef* path);
255
271 LO_RESULT LOLabelSetLeaderLine(LOLabelRef label, LOPathRef path);
272
283 LO_RESULT LOLabelGetLeaderLineType(LOLabelRef label, LOLabelLeaderLineType* leader_line_type);
284
298 LO_RESULT LOLabelSetLeaderLineType(LOLabelRef label, LOLabelLeaderLineType leader_line_type);
299
309 LO_RESULT LOLabelGetTextConnectionType(
310 LOLabelRef label, LOLabelTextConnectionType* text_connection_type);
311
325 LO_RESULT LOLabelSetTextConnectionType(
326 LOLabelRef label, LOLabelTextConnectionType text_connection_type);
327
328 #ifdef __cplusplus
329 }
330 #endif // __cplusplus
331
332 #endif // LAYOUT_MODEL_LABEL_H_