scriptup 2024.0.4 → 2024.0.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/ext/attribute_dictionaries.c +1 -1
- data/ext/color.c +3 -3
- data/ext/component_definition.c +2 -2
- data/ext/definition_list.c +1 -1
- data/ext/entity.c +4 -3
- data/ext/material.c +4 -7
- data/ext/utils.h +4 -4
- data/sketchup-sdk-win/binaries/layout/x64/LayOutAPI.dll +0 -0
- data/sketchup-sdk-win/binaries/layout/x64/LayOutAPI.lib +0 -0
- data/sketchup-sdk-win/binaries/layout/x64/LayOutControllers.dll +0 -0
- data/sketchup-sdk-win/binaries/layout/x64/LayOutModel.dll +0 -0
- data/sketchup-sdk-win/binaries/layout/x64/LayOutRTF.dll +0 -0
- data/sketchup-sdk-win/binaries/layout/x64/LayOutUtils.dll +0 -0
- data/sketchup-sdk-win/binaries/layout/x64/SketchUpCommonPreferences.dll +0 -0
- data/sketchup-sdk-win/binaries/layout/x64/SketchUpViewerAPI.dll +0 -0
- data/sketchup-sdk-win/binaries/layout/x64/SketchUpViewerAPI.lib +0 -0
- data/sketchup-sdk-win/binaries/layout/x64/pdflib.dll +0 -0
- data/sketchup-sdk-win/headers/LayOutAPI/application/application.h +117 -0
- data/sketchup-sdk-win/headers/LayOutAPI/common.h +22 -0
- data/sketchup-sdk-win/headers/LayOutAPI/geometry/geometry.h +78 -0
- data/sketchup-sdk-win/headers/LayOutAPI/initialize.h +36 -0
- data/sketchup-sdk-win/headers/LayOutAPI/layout.h +49 -0
- data/sketchup-sdk-win/headers/LayOutAPI/model/angulardimension.h +468 -0
- data/sketchup-sdk-win/headers/LayOutAPI/model/autotextdefinition.h +569 -0
- data/sketchup-sdk-win/headers/LayOutAPI/model/autotextdefinitionlist.h +79 -0
- data/sketchup-sdk-win/headers/LayOutAPI/model/connectionpoint.h +107 -0
- data/sketchup-sdk-win/headers/LayOutAPI/model/defs.h +42 -0
- data/sketchup-sdk-win/headers/LayOutAPI/model/dictionary.h +120 -0
- data/sketchup-sdk-win/headers/LayOutAPI/model/document.h +864 -0
- data/sketchup-sdk-win/headers/LayOutAPI/model/documentexportoptions.h +59 -0
- data/sketchup-sdk-win/headers/LayOutAPI/model/ellipse.h +78 -0
- data/sketchup-sdk-win/headers/LayOutAPI/model/entity.h +330 -0
- data/sketchup-sdk-win/headers/LayOutAPI/model/entityiterator.h +49 -0
- data/sketchup-sdk-win/headers/LayOutAPI/model/entitylist.h +114 -0
- data/sketchup-sdk-win/headers/LayOutAPI/model/formattedtext.h +397 -0
- data/sketchup-sdk-win/headers/LayOutAPI/model/grid.h +251 -0
- data/sketchup-sdk-win/headers/LayOutAPI/model/group.h +243 -0
- data/sketchup-sdk-win/headers/LayOutAPI/model/image.h +146 -0
- data/sketchup-sdk-win/headers/LayOutAPI/model/imagerep.h +109 -0
- data/sketchup-sdk-win/headers/LayOutAPI/model/label.h +332 -0
- data/sketchup-sdk-win/headers/LayOutAPI/model/layer.h +207 -0
- data/sketchup-sdk-win/headers/LayOutAPI/model/layerinstance.h +117 -0
- data/sketchup-sdk-win/headers/LayOutAPI/model/layerlist.h +69 -0
- data/sketchup-sdk-win/headers/LayOutAPI/model/lineardimension.h +456 -0
- data/sketchup-sdk-win/headers/LayOutAPI/model/page.h +261 -0
- data/sketchup-sdk-win/headers/LayOutAPI/model/pageinfo.h +372 -0
- data/sketchup-sdk-win/headers/LayOutAPI/model/pagelist.h +81 -0
- data/sketchup-sdk-win/headers/LayOutAPI/model/path.h +464 -0
- data/sketchup-sdk-win/headers/LayOutAPI/model/rectangle.h +240 -0
- data/sketchup-sdk-win/headers/LayOutAPI/model/referenceentity.h +120 -0
- data/sketchup-sdk-win/headers/LayOutAPI/model/sketchupmodel.h +624 -0
- data/sketchup-sdk-win/headers/LayOutAPI/model/skpfilereference.h +94 -0
- data/sketchup-sdk-win/headers/LayOutAPI/model/style.h +1080 -0
- data/sketchup-sdk-win/headers/LayOutAPI/model/table.h +470 -0
- data/sketchup-sdk-win/headers/LayOutAPI/model/typed_value.h +156 -0
- metadata +50 -2
@@ -0,0 +1,69 @@
|
|
1
|
+
// Copyright 2015 Trimble Navigation Ltd. All rights reserved.
|
2
|
+
// This file is intended for public distribution.
|
3
|
+
|
4
|
+
#ifndef LAYOUT_MODEL_LAYER_LIST_H_
|
5
|
+
#define LAYOUT_MODEL_LAYER_LIST_H_
|
6
|
+
|
7
|
+
#include <LayOutAPI/common.h>
|
8
|
+
#include <LayOutAPI/model/defs.h>
|
9
|
+
|
10
|
+
/**
|
11
|
+
@struct LOLayerListRef
|
12
|
+
@brief References an ordered, indexable list of \ref LOLayerRef objects.
|
13
|
+
*/
|
14
|
+
|
15
|
+
#ifdef __cplusplus
|
16
|
+
extern "C" {
|
17
|
+
#endif // __cplusplus
|
18
|
+
|
19
|
+
/**
|
20
|
+
@brief Creates a new empty layer list object.
|
21
|
+
@param[out] layer_list The layer definition list object.
|
22
|
+
@return
|
23
|
+
- \ref SU_ERROR_NONE on success
|
24
|
+
- \ref SU_ERROR_NULL_POINTER_OUTPUT if layer_list is NULL
|
25
|
+
- \ref SU_ERROR_OVERWRITE_VALID if *layer_list already refers to a valid object
|
26
|
+
*/
|
27
|
+
LO_RESULT LOLayerListCreate(LOLayerListRef* layer_list);
|
28
|
+
|
29
|
+
/**
|
30
|
+
@brief Releases a layer list object. *layer_list will be set to invalid by this
|
31
|
+
function.
|
32
|
+
@param[in] layer_list The layer definition list object.
|
33
|
+
@return
|
34
|
+
- \ref SU_ERROR_NONE on success
|
35
|
+
- \ref SU_ERROR_NULL_POINTER_INPUT if layer_list is NULL
|
36
|
+
- \ref SU_ERROR_INVALID_INPUT if *layer_list does not refer to a valid object
|
37
|
+
*/
|
38
|
+
LO_RESULT LOLayerListRelease(LOLayerListRef* layer_list);
|
39
|
+
|
40
|
+
/**
|
41
|
+
@brief Gets the number of layer definitions in the list.
|
42
|
+
@param[in] layer_list The layer definition list object.
|
43
|
+
@param[out] num_layers The number of layer definitions in the list.
|
44
|
+
@return
|
45
|
+
- \ref SU_ERROR_NONE on success
|
46
|
+
- \ref SU_ERROR_INVALID_INPUT if layer_list does not refer to a valid object
|
47
|
+
- \ref SU_ERROR_NULL_POINTER_OUTPUT if num_layers is NULL
|
48
|
+
*/
|
49
|
+
LO_RESULT LOLayerListGetNumberOfLayers(LOLayerListRef layer_list, size_t* num_layers);
|
50
|
+
|
51
|
+
/**
|
52
|
+
@brief Gets the layer definition at the specified index.
|
53
|
+
@param[in] layer_list The layer definition list object.
|
54
|
+
@param[in] index The index of the layer definition object to get.
|
55
|
+
@param[out] layer The layer definition object.
|
56
|
+
@return
|
57
|
+
- \ref SU_ERROR_NONE on success
|
58
|
+
- \ref SU_ERROR_INVALID_INPUT if layer_list does not refer to a valid object
|
59
|
+
- \ref SU_ERROR_OUT_OF_RANGE if index is out of range for this list
|
60
|
+
- \ref SU_ERROR_NULL_POINTER_OUTPUT if layer is NULL
|
61
|
+
- \ref SU_ERROR_OVERWRITE_VALID if *layer already refers to a valid object
|
62
|
+
*/
|
63
|
+
LO_RESULT LOLayerListGetLayerAtIndex(LOLayerListRef layer_list, size_t index, LOLayerRef* layer);
|
64
|
+
|
65
|
+
#ifdef __cplusplus
|
66
|
+
} // end extern "C"
|
67
|
+
#endif // __cplusplus
|
68
|
+
|
69
|
+
#endif // LAYOUT_MODEL_LAYER_LIST_H_
|
@@ -0,0 +1,456 @@
|
|
1
|
+
// Copyright 2015 Trimble Navigation Ltd. All rights reserved.
|
2
|
+
// This file is intended for public distribution.
|
3
|
+
|
4
|
+
#ifndef LAYOUT_MODEL_LINEARDIMENSION_H_
|
5
|
+
#define LAYOUT_MODEL_LINEARDIMENSION_H_
|
6
|
+
|
7
|
+
#include <LayOutAPI/common.h>
|
8
|
+
#include <LayOutAPI/geometry/geometry.h>
|
9
|
+
#include <LayOutAPI/model/defs.h>
|
10
|
+
|
11
|
+
/**
|
12
|
+
@struct LOLinearDimensionRef
|
13
|
+
@brief References a linear dimension entity. A linear dimension is composed of
|
14
|
+
the following sub-entities:
|
15
|
+
- two 'extension lines' that connect to the entity being dimensioned.
|
16
|
+
- a 'dimension line' connecting the ends of the leaders.
|
17
|
+
(this may be represented by one or two paths depending on appearance.)
|
18
|
+
- an optional 'leader line' that is used for small dimensions.
|
19
|
+
- a 'dimension text' that displays the dimension's text.
|
20
|
+
|
21
|
+
There are six points that may be modified for a linear dimension:
|
22
|
+
- two 'connection points' that define the start and end of the
|
23
|
+
dimension.
|
24
|
+
- two 'extent points' that define the start and end of the dimension
|
25
|
+
line and are the ends of the two extension lines.
|
26
|
+
- two 'offset points' that define the starting points of the extension
|
27
|
+
lines.
|
28
|
+
*/
|
29
|
+
|
30
|
+
#ifdef __cplusplus
|
31
|
+
extern "C" {
|
32
|
+
#endif // __cplusplus
|
33
|
+
|
34
|
+
/**
|
35
|
+
@enum LOLinearDimensionLeaderLineType
|
36
|
+
@brief Defines the different types of leader lines for a linear dimension entity.
|
37
|
+
*/
|
38
|
+
typedef enum {
|
39
|
+
LOLinearDimensionLeaderLineType_SingleSegment = 0, ///< Single segment leader line.
|
40
|
+
LOLinearDimensionLeaderLineType_TwoSegment, ///< Two segment leader line.
|
41
|
+
LOLinearDimensionLeaderLineType_Bezier, ///< Curved Bezier leader line.
|
42
|
+
LOLinearDimensionLeaderLineType_Hidden, ///< No visible leader line.
|
43
|
+
LONumLinearDimensionLeaderLineTypes
|
44
|
+
} LOLinearDimensionLeaderLineType;
|
45
|
+
|
46
|
+
/**
|
47
|
+
@brief Creates a new disconnected linear dimension object.
|
48
|
+
@param[out] dimension The linear dimension object
|
49
|
+
@param[in] start_point Where the dimension should start
|
50
|
+
@param[in] end_point Where the dimension should end
|
51
|
+
@param[in] height Distance from the start and end points to the dimension
|
52
|
+
line
|
53
|
+
@return
|
54
|
+
- \ref SU_ERROR_NONE on success
|
55
|
+
- \ref SU_ERROR_NULL_POINTER_OUTPUT if dimension is NULL
|
56
|
+
- \ref SU_ERROR_OVERWRITE_VALID if *dimension already refers to a valid object
|
57
|
+
- \ref SU_ERROR_NULL_POINTER_INPUT if start_point is NULL
|
58
|
+
- \ref SU_ERROR_NULL_POINTER_INPUT if end_point is NULL
|
59
|
+
*/
|
60
|
+
LO_RESULT LOLinearDimensionCreate(
|
61
|
+
LOLinearDimensionRef* dimension, const LOPoint2D* start_point, const LOPoint2D* end_point,
|
62
|
+
double height);
|
63
|
+
|
64
|
+
/**
|
65
|
+
@brief Adds a reference to a linear dimension object.
|
66
|
+
@param[in] dimension The linear dimension object.
|
67
|
+
@return
|
68
|
+
- \ref SU_ERROR_NONE on success
|
69
|
+
- \ref SU_ERROR_INVALID_INPUT if dimension does not refer to a valid object
|
70
|
+
*/
|
71
|
+
LO_RESULT LOLinearDimensionAddReference(LOLinearDimensionRef dimension);
|
72
|
+
|
73
|
+
/**
|
74
|
+
@brief Releases a linear dimension object. The object will be invalidated if
|
75
|
+
releasing the last reference.
|
76
|
+
@param[in] dimension The linear dimension object.
|
77
|
+
@return
|
78
|
+
- \ref SU_ERROR_NONE on success
|
79
|
+
- \ref SU_ERROR_NULL_POINTER_INPUT if dimension is NULL
|
80
|
+
- \ref SU_ERROR_INVALID_INPUT if *dimension does not refer to a valid object
|
81
|
+
*/
|
82
|
+
LO_RESULT LOLinearDimensionRelease(LOLinearDimensionRef* dimension);
|
83
|
+
|
84
|
+
/**
|
85
|
+
@brief Converts from a \ref LOEntityRef to a \ref LOLinearDimensionRef.
|
86
|
+
This is essentially a downcast operation so the given \ref LOEntityRef
|
87
|
+
must be convertible to a \ref LOLinearDimensionRef.
|
88
|
+
@param[in] entity The entity object.
|
89
|
+
@return
|
90
|
+
- The converted \ref LOLinearDimensionRef if the downcast operation succeeds
|
91
|
+
- If not, the returned reference will be invalid
|
92
|
+
*/
|
93
|
+
LO_EXPORT LOLinearDimensionRef LOLinearDimensionFromEntity(LOEntityRef entity);
|
94
|
+
|
95
|
+
/**
|
96
|
+
@brief Converts from a \ref LOLinearDimensionRef to a \ref LOEntityRef.
|
97
|
+
This is essentially an upcast operation.
|
98
|
+
@param[in] dimension The linear dimension object.
|
99
|
+
@return
|
100
|
+
- The converted \ref LOEntityRef if dimension is a valid object
|
101
|
+
- If not, the returned reference will be invalid
|
102
|
+
*/
|
103
|
+
LO_EXPORT LOEntityRef LOLinearDimensionToEntity(LOLinearDimensionRef dimension);
|
104
|
+
|
105
|
+
/**
|
106
|
+
@brief Creates the entities that represent the dimension in its exploded form
|
107
|
+
and adds them to a \ref LOEntityListRef. It is NOT necessary to
|
108
|
+
explicitly release these entities, since \ref LOEntityListRef itself
|
109
|
+
adds a reference to the entities and will release them when they are
|
110
|
+
removed from the list or when the list is released. Depending on the
|
111
|
+
appearance of the dimension being exploded, this may return anywhere from
|
112
|
+
four to six entities. Start extension line, end extension line,
|
113
|
+
one or two dimension lines, dimension text, optional leader line.
|
114
|
+
@param[in] dimension The linear dimension object.
|
115
|
+
@param[in] entity_list The entity list object to add the new entities to.
|
116
|
+
@return
|
117
|
+
- \ref SU_ERROR_NONE on success
|
118
|
+
- \ref SU_ERROR_INVALID_INPUT if dimension does not refer to a valid object
|
119
|
+
- \ref SU_ERROR_INVALID_INPUT if entity_list does not refer to a valid object
|
120
|
+
*/
|
121
|
+
LO_RESULT LOLinearDimensionGetExplodedEntities(
|
122
|
+
LOLinearDimensionRef dimension, LOEntityListRef entity_list);
|
123
|
+
|
124
|
+
/**
|
125
|
+
@brief Gets whether or not the dimension text uses custom text. When
|
126
|
+
true, the dimension text will display a custom string that doesn't
|
127
|
+
change. When false, the dimension text will display the length
|
128
|
+
measurement and will update automatically.
|
129
|
+
@param[in] dimension The linear dimension object.
|
130
|
+
@param[out] use_custom_text Whether the dimension uses custom text.
|
131
|
+
@return
|
132
|
+
- \ref SU_ERROR_NONE on success
|
133
|
+
- \ref SU_ERROR_INVALID_INPUT if dimension does not refer to a valid object
|
134
|
+
- \ref SU_ERROR_NULL_POINTER_OUTPUT if use_auto_text is NULL
|
135
|
+
*/
|
136
|
+
LO_RESULT LOLinearDimensionGetUsesCustomText(LOLinearDimensionRef dimension, bool* use_custom_text);
|
137
|
+
|
138
|
+
/**
|
139
|
+
@brief Sets whether or not the dimension text uses custom text. When true, the
|
140
|
+
dimension text will display a custom string that doesn't change. When
|
141
|
+
false, the dimension text will display the length measurement and will
|
142
|
+
update automatically.
|
143
|
+
@param[in] dimension The linear dimension object.
|
144
|
+
@param[in] use_custom_text Whether or not the dimension should use custom text.
|
145
|
+
@return
|
146
|
+
- \ref SU_ERROR_NONE on success
|
147
|
+
- \ref SU_ERROR_INVALID_INPUT if dimension does not refer to a valid object
|
148
|
+
- \ref SU_ERROR_LAYER_LOCKED if dimension is on a locked layer
|
149
|
+
- \ref SU_ERROR_ENTITY_LOCKED if dimension is locked
|
150
|
+
*/
|
151
|
+
LO_RESULT LOLinearDimensionSetUsesCustomText(LOLinearDimensionRef dimension, bool use_custom_text);
|
152
|
+
|
153
|
+
/**
|
154
|
+
@brief Creates a copy of the dimension text's \ref LOFormattedTextRef object.
|
155
|
+
@note With the addition of auto-text in dimensions for LayOut 2019.2, the
|
156
|
+
copy of the dimension text incorrectly provided the plain text when
|
157
|
+
requesting the display text. This has been fixed in LayOut 2020.1, API 5.1.
|
158
|
+
@param[in] dimension The linear dimension object.
|
159
|
+
@param[out] text The formatted text object.
|
160
|
+
@return
|
161
|
+
- \ref SU_ERROR_NONE on success
|
162
|
+
- \ref SU_ERROR_INVALID_INPUT if dimension does not refer to a valid object
|
163
|
+
- \ref SU_ERROR_NULL_POINTER_OUTPUT if text is NULL
|
164
|
+
- \ref SU_ERROR_OVERWRITE_VALID if *text already refers to a valid object
|
165
|
+
*/
|
166
|
+
LO_RESULT LOLinearDimensionCreateDimensionTextCopy(
|
167
|
+
LOLinearDimensionRef dimension, LOFormattedTextRef* text);
|
168
|
+
|
169
|
+
/**
|
170
|
+
@brief Sets the text of the dimension from a \ref LOFormattedTextRef object.
|
171
|
+
The dimension lines may be adjusted if the text has been re-positioned.
|
172
|
+
@param[in] dimension The linear dimension object.
|
173
|
+
@param[in] text The formatted text object.
|
174
|
+
@return
|
175
|
+
- \ref SU_ERROR_NONE on success
|
176
|
+
- \ref SU_ERROR_INVALID_INPUT if dimension does not refer to a valid object
|
177
|
+
- \ref SU_ERROR_INVALID_INPUT if text does not refer to a valid object
|
178
|
+
- \ref SU_ERROR_LAYER_LOCKED if dimension is on a locked layer
|
179
|
+
- \ref SU_ERROR_ENTITY_LOCKED if dimension is locked
|
180
|
+
*/
|
181
|
+
LO_RESULT LOLinearDimensionSetDimensionText(
|
182
|
+
LOLinearDimensionRef dimension, LOFormattedTextRef text);
|
183
|
+
|
184
|
+
/**
|
185
|
+
@brief Gets the type of leader line the linear dimension is using.
|
186
|
+
@param[in] dimension The linear dimension object.
|
187
|
+
@param[out] leader_line_type The leader line type.
|
188
|
+
@return
|
189
|
+
- \ref SU_ERROR_NONE on success
|
190
|
+
- \ref SU_ERROR_INVALID_INPUT if dimension does not refer to a valid object
|
191
|
+
- \ref SU_ERROR_NULL_POINTER_OUTPUT if leader_line_type is NULL
|
192
|
+
*/
|
193
|
+
LO_RESULT LOLinearDimensionGetLeaderLineType(
|
194
|
+
LOLinearDimensionRef dimension, LOLinearDimensionLeaderLineType* leader_line_type);
|
195
|
+
|
196
|
+
/**
|
197
|
+
@brief Sets the type of leader line the linear dimension is using. New control
|
198
|
+
points will be generated if changing to a two segment or bezier leader
|
199
|
+
line type. Setting the leader line type to \ref
|
200
|
+
LOLinearDimensionLeaderLineType_Hidden will not move the dimension text.
|
201
|
+
@param[in] dimension The linear dimension object.
|
202
|
+
@param[in] leader_line_type The leader line type.
|
203
|
+
@return
|
204
|
+
- \ref SU_ERROR_NONE on success
|
205
|
+
- \ref SU_ERROR_INVALID_INPUT if dimension does not refer to a valid object
|
206
|
+
- \ref SU_ERROR_OUT_OF_RANGE if leader_line_type is not a valid value
|
207
|
+
- \ref SU_ERROR_LAYER_LOCKED if dimension is on a locked layer
|
208
|
+
- \ref SU_ERROR_ENTITY_LOCKED if dimension is locked
|
209
|
+
*/
|
210
|
+
LO_RESULT LOLinearDimensionSetLeaderLineType(
|
211
|
+
LOLinearDimensionRef dimension, LOLinearDimensionLeaderLineType leader_line_type);
|
212
|
+
|
213
|
+
/**
|
214
|
+
@brief Gets whether or not the scale for the dimension length text is set
|
215
|
+
automatically.
|
216
|
+
@param[in] dimension The linear dimension object.
|
217
|
+
@param[out] use_auto_scale Whether the dimension is using auto scale or not.
|
218
|
+
@return
|
219
|
+
- \ref SU_ERROR_NONE on success
|
220
|
+
- \ref SU_ERROR_INVALID_INPUT if dimension does not refer to a valid object
|
221
|
+
- \ref SU_ERROR_NULL_POINTER_OUTPUT if use_auto_scale is NULL
|
222
|
+
*/
|
223
|
+
LO_RESULT LOLinearDimensionGetUsesAutoScale(LOLinearDimensionRef dimension, bool* use_auto_scale);
|
224
|
+
|
225
|
+
/**
|
226
|
+
@brief Sets whether or not the scale for the dimension length text is set
|
227
|
+
automatically.
|
228
|
+
@param[in] dimension The linear dimension object.
|
229
|
+
@param[in] use_auto_scale Whether the dimension should use auto scale or not.
|
230
|
+
@return
|
231
|
+
- \ref SU_ERROR_NONE on success
|
232
|
+
- \ref SU_ERROR_INVALID_INPUT if dimension does not refer to a valid object
|
233
|
+
- \ref SU_ERROR_LAYER_LOCKED if dimension is on a locked layer
|
234
|
+
*/
|
235
|
+
LO_RESULT LOLinearDimensionSetUsesAutoScale(LOLinearDimensionRef dimension, bool use_auto_scale);
|
236
|
+
|
237
|
+
/**
|
238
|
+
@brief Gets the scale being used for the dimension length text.
|
239
|
+
@param[in] dimension The linear dimension object.
|
240
|
+
@param[out] scale The dimension text scale.
|
241
|
+
@return
|
242
|
+
- \ref SU_ERROR_NONE on success
|
243
|
+
- \ref SU_ERROR_INVALID_INPUT if dimension does not refer to a valid object
|
244
|
+
- \ref SU_ERROR_NULL_POINTER_OUTPUT if scale is NULL
|
245
|
+
*/
|
246
|
+
LO_RESULT LOLinearDimensionGetScale(LOLinearDimensionRef dimension, double* scale);
|
247
|
+
|
248
|
+
/**
|
249
|
+
@brief Sets the scale being used for the dimension length text. This will also
|
250
|
+
make the scale not use auto-scale.
|
251
|
+
@param[in] dimension The linear dimension object.
|
252
|
+
@param[in] scale The new scale to use.
|
253
|
+
@return
|
254
|
+
- \ref SU_ERROR_NONE on success
|
255
|
+
- \ref SU_ERROR_INVALID_INPUT if dimension does not refer to a valid object
|
256
|
+
- \ref SU_ERROR_OUT_OF_RANGE if scale is not positive or scale is greater than 1
|
257
|
+
- \ref SU_ERROR_LAYER_LOCKED if dimension is on a locked layer
|
258
|
+
- \ref SU_ERROR_ENTITY_LOCKED if dimension is locked
|
259
|
+
*/
|
260
|
+
LO_RESULT LOLinearDimensionSetScale(LOLinearDimensionRef dimension, double scale);
|
261
|
+
|
262
|
+
/**
|
263
|
+
@brief Gets the page location for the first connection.
|
264
|
+
@param[in] dimension The linear dimension object.
|
265
|
+
@param[out] point The position of the first connection point.
|
266
|
+
@return
|
267
|
+
- \ref SU_ERROR_NONE on success
|
268
|
+
- \ref SU_ERROR_INVALID_INPUT if dimension does not refer to a valid object
|
269
|
+
- \ref SU_ERROR_NULL_POINTER_OUTPUT if point is NULL
|
270
|
+
*/
|
271
|
+
LO_RESULT LOLinearDimensionGetStartConnectionPoint(
|
272
|
+
LOLinearDimensionRef dimension, LOPoint2D* point);
|
273
|
+
|
274
|
+
/**
|
275
|
+
@brief Sets the page location for the first connection. This will cause the
|
276
|
+
dimension to become disconnected. To make a connected dimension, call
|
277
|
+
LOLinearDimensionConnectTo.
|
278
|
+
@param[in] dimension The linear dimension object.
|
279
|
+
@param[in] point The position for the first connection point.
|
280
|
+
@return
|
281
|
+
- \ref SU_ERROR_NONE on success
|
282
|
+
- \ref SU_ERROR_INVALID_INPUT if dimension does not refer to a valid object
|
283
|
+
- \ref SU_ERROR_LAYER_LOCKED if dimension is on a locked layer
|
284
|
+
- \ref SU_ERROR_ENTITY_LOCKED if dimension is locked
|
285
|
+
*/
|
286
|
+
LO_RESULT LOLinearDimensionSetStartConnectionPoint(
|
287
|
+
LOLinearDimensionRef dimension, LOPoint2D* point);
|
288
|
+
|
289
|
+
/**
|
290
|
+
@brief Gets the page location for the second connection. This will cause the
|
291
|
+
dimension to become disconnected. To make a connected dimension, call
|
292
|
+
LOLinearDimensionConnectTo.
|
293
|
+
@param[in] dimension The linear dimension object.
|
294
|
+
@param[out] point The position of the second control point.
|
295
|
+
@return
|
296
|
+
- \ref SU_ERROR_NONE on success
|
297
|
+
- \ref SU_ERROR_INVALID_INPUT if dimension does not refer to a valid object
|
298
|
+
- \ref SU_ERROR_NULL_POINTER_OUTPUT if point is NULL
|
299
|
+
*/
|
300
|
+
LO_RESULT LOLinearDimensionGetEndConnectionPoint(LOLinearDimensionRef dimension, LOPoint2D* point);
|
301
|
+
|
302
|
+
/**
|
303
|
+
@brief Sets the page location for the second connection.
|
304
|
+
@param[in] dimension The linear dimension object.
|
305
|
+
@param[in] point The position for the second control point.
|
306
|
+
@return
|
307
|
+
- \ref SU_ERROR_NONE on success
|
308
|
+
- \ref SU_ERROR_INVALID_INPUT if dimension does not refer to a valid object
|
309
|
+
- \ref SU_ERROR_LAYER_LOCKED if dimension is on a locked layer
|
310
|
+
- \ref SU_ERROR_ENTITY_LOCKED if dimension is locked
|
311
|
+
*/
|
312
|
+
LO_RESULT LOLinearDimensionSetEndConnectionPoint(LOLinearDimensionRef dimension, LOPoint2D* point);
|
313
|
+
|
314
|
+
/**
|
315
|
+
@brief Gets the page location for the start of the dimension line.
|
316
|
+
@param[in] dimension The linear dimension object.
|
317
|
+
@param[out] point The position of the start of the dimension line.
|
318
|
+
@return
|
319
|
+
- \ref SU_ERROR_NONE on success
|
320
|
+
- \ref SU_ERROR_INVALID_INPUT if dimension does not refer to a valid object
|
321
|
+
- \ref SU_ERROR_NULL_POINTER_OUTPUT if point is NULL
|
322
|
+
*/
|
323
|
+
LO_RESULT LOLinearDimensionGetStartExtentPoint(LOLinearDimensionRef dimension, LOPoint2D* point);
|
324
|
+
|
325
|
+
/**
|
326
|
+
@brief Sets the page location for the start of the dimension line. This will
|
327
|
+
also adjust the end of the dimension line to maintain the correct
|
328
|
+
dimension line length.
|
329
|
+
@param[in] dimension The linear dimension object.
|
330
|
+
@param[in] point The position of the start of the dimension line.
|
331
|
+
@return
|
332
|
+
- \ref SU_ERROR_NONE on success
|
333
|
+
- \ref SU_ERROR_INVALID_INPUT if dimension does not refer to a valid object
|
334
|
+
- \ref SU_ERROR_LAYER_LOCKED if dimension is on a locked layer
|
335
|
+
- \ref SU_ERROR_ENTITY_LOCKED if dimension is locked
|
336
|
+
*/
|
337
|
+
LO_RESULT LOLinearDimensionSetStartExtentPoint(LOLinearDimensionRef dimension, LOPoint2D* point);
|
338
|
+
|
339
|
+
/**
|
340
|
+
@brief Gets the page location for the end of the dimension line.
|
341
|
+
@param[in] dimension The linear dimension object.
|
342
|
+
@param[out] point The position of the end of the dimension line.
|
343
|
+
@return
|
344
|
+
- \ref SU_ERROR_NONE on success
|
345
|
+
- \ref SU_ERROR_INVALID_INPUT if dimension does not refer to a valid object
|
346
|
+
- \ref SU_ERROR_NULL_POINTER_OUTPUT if point is NULL
|
347
|
+
*/
|
348
|
+
LO_RESULT LOLinearDimensionGetEndExtentPoint(LOLinearDimensionRef dimension, LOPoint2D* point);
|
349
|
+
|
350
|
+
/**
|
351
|
+
@brief Sets the page location for the end of the dimension line. This will
|
352
|
+
also adjust the start of the dimension line to maintain the correct
|
353
|
+
dimension line length.
|
354
|
+
@param[in] dimension The linear dimension object.
|
355
|
+
@param[in] point The position of the end of the dimension line.
|
356
|
+
@return
|
357
|
+
- \ref SU_ERROR_NONE on success
|
358
|
+
- \ref SU_ERROR_INVALID_INPUT if dimension does not refer to a valid object
|
359
|
+
- \ref SU_ERROR_LAYER_LOCKED if dimension is on a locked layer
|
360
|
+
- \ref SU_ERROR_ENTITY_LOCKED if dimension is locked
|
361
|
+
*/
|
362
|
+
LO_RESULT LOLinearDimensionSetEndExtentPoint(LOLinearDimensionRef dimension, LOPoint2D* point);
|
363
|
+
|
364
|
+
/**
|
365
|
+
@brief Gets the page location for the start of the first extension line. The
|
366
|
+
first extension line runs from this offset point to the start extent
|
367
|
+
point.
|
368
|
+
@param[in] dimension The linear dimension object.
|
369
|
+
@param[out] point The position of the start of the extension line.
|
370
|
+
@return
|
371
|
+
- \ref SU_ERROR_NONE on success
|
372
|
+
- \ref SU_ERROR_INVALID_INPUT if dimension does not refer to a valid object
|
373
|
+
- \ref SU_ERROR_NULL_POINTER_OUTPUT if point is NULL
|
374
|
+
*/
|
375
|
+
LO_RESULT LOLinearDimensionGetStartOffsetPoint(LOLinearDimensionRef dimension, LOPoint2D* point);
|
376
|
+
|
377
|
+
/**
|
378
|
+
@brief Gets the page location for the start of the second extension line. The
|
379
|
+
second extension line runs from this offset point to the end extent
|
380
|
+
point.
|
381
|
+
@param[in] dimension The linear dimension object.
|
382
|
+
@param[out] point The position of the end of the dimension line.
|
383
|
+
@return
|
384
|
+
- \ref SU_ERROR_NONE on success
|
385
|
+
- \ref SU_ERROR_INVALID_INPUT if dimension does not refer to a valid object
|
386
|
+
- \ref SU_ERROR_NULL_POINTER_OUTPUT if point is NULL
|
387
|
+
*/
|
388
|
+
LO_RESULT LOLinearDimensionGetEndOffsetPoint(LOLinearDimensionRef dimension, LOPoint2D* point);
|
389
|
+
|
390
|
+
/**
|
391
|
+
@brief Sets the length of the offset from the first connection point to the
|
392
|
+
start of the first extension line. The connection and extent points will
|
393
|
+
not move.
|
394
|
+
@param[in] dimension The linear dimension object.
|
395
|
+
@param[in] length The length the offset to the extension line should be.
|
396
|
+
@return
|
397
|
+
- \ref SU_ERROR_NONE on success
|
398
|
+
- \ref SU_ERROR_INVALID_INPUT if dimension does not refer to a valid object
|
399
|
+
- \ref SU_ERROR_LAYER_LOCKED if dimension is on a locked layer
|
400
|
+
- \ref SU_ERROR_ENTITY_LOCKED if dimension is locked
|
401
|
+
*/
|
402
|
+
LO_RESULT LOLinearDimensionSetStartOffsetLength(LOLinearDimensionRef dimension, double length);
|
403
|
+
|
404
|
+
/**
|
405
|
+
@brief Sets the length of the offset from the second connection point to the
|
406
|
+
start of the second extension line. The connection and extent points
|
407
|
+
will not move.
|
408
|
+
@param[in] dimension The linear dimension object.
|
409
|
+
@param[in] length The length the offset to the extension line should be.
|
410
|
+
@return
|
411
|
+
- \ref SU_ERROR_NONE on success
|
412
|
+
- \ref SU_ERROR_INVALID_INPUT if dimension does not refer to a valid object
|
413
|
+
- \ref SU_ERROR_LAYER_LOCKED if dimension is on a locked layer
|
414
|
+
- \ref SU_ERROR_ENTITY_LOCKED if dimension is locked
|
415
|
+
*/
|
416
|
+
LO_RESULT LOLinearDimensionSetEndOffsetLength(LOLinearDimensionRef dimension, double length);
|
417
|
+
|
418
|
+
/**
|
419
|
+
@brief Connects the linear dimension to the given connection points. If both
|
420
|
+
the linear dimension and the connection point's entities are on
|
421
|
+
non-shared layers, they must be on the same page.
|
422
|
+
@param[in] dimension The linear dimension object.
|
423
|
+
@param[in] start_point The first connection point object.
|
424
|
+
@param[in] end_point The second connection point object.
|
425
|
+
@return
|
426
|
+
- \ref SU_ERROR_NONE on success
|
427
|
+
- \ref SU_ERROR_INVALID_INPUT if dimension does not refer to a valid object
|
428
|
+
- \ref SU_ERROR_INVALID_INPUT if start_point does not refer to a valid object
|
429
|
+
- \ref SU_ERROR_INVALID_INPUT if end_point does not refer to a valid object
|
430
|
+
- \ref SU_ERROR_LAYER_LOCKED if dimension is on a locked layer
|
431
|
+
- \ref SU_ERROR_ENTITY_LOCKED if dimension is locked
|
432
|
+
- \ref SU_ERROR_GENERIC if the linear dimension was unable to connect to the
|
433
|
+
connection points
|
434
|
+
*/
|
435
|
+
LO_RESULT LOLinearDimensionConnectTo(
|
436
|
+
LOLinearDimensionRef dimension, LOConnectionPointRef start_point,
|
437
|
+
LOConnectionPointRef end_point);
|
438
|
+
|
439
|
+
/**
|
440
|
+
@brief Disconnects the linear dimension from its connection points. The
|
441
|
+
dimension will not be adjusted by disconnecting from its connection
|
442
|
+
points.
|
443
|
+
@param[in] dimension The linear dimension object.
|
444
|
+
@return
|
445
|
+
- \ref SU_ERROR_NONE on success
|
446
|
+
- \ref SU_ERROR_INVALID_INPUT if dimension does not refer to a valid object
|
447
|
+
- \ref SU_ERROR_LAYER_LOCKED if dimension is on a locked layer
|
448
|
+
- \ref SU_ERROR_ENTITY_LOCKED if dimension is locked
|
449
|
+
*/
|
450
|
+
LO_RESULT LOLinearDimensionDisconnect(LOLinearDimensionRef dimension);
|
451
|
+
|
452
|
+
#ifdef __cplusplus
|
453
|
+
} // end extern "C"
|
454
|
+
#endif // __cplusplus
|
455
|
+
|
456
|
+
#endif // LAYOUT_MODEL_LINEARDIMENSION_H_
|