sketchup-api-stubs 0.1.2 → 0.2.0

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.
Files changed (92) hide show
  1. checksums.yaml +4 -4
  2. data/SketchUp/Geom/BoundingBox.rb +17 -20
  3. data/SketchUp/Geom/Bounds2d.rb +172 -0
  4. data/SketchUp/Geom/LatLong.rb +31 -16
  5. data/SketchUp/Geom/OrientedBounds2d.rb +102 -0
  6. data/SketchUp/Geom/Point2d.rb +365 -0
  7. data/SketchUp/Geom/Point3d.rb +121 -110
  8. data/SketchUp/Geom/PolygonMesh.rb +30 -21
  9. data/SketchUp/Geom/Transformation.rb +8 -4
  10. data/SketchUp/Geom/Transformation2d.rb +125 -0
  11. data/SketchUp/Geom/UTM.rb +43 -37
  12. data/SketchUp/Geom/Vector2d.rb +497 -0
  13. data/SketchUp/Geom/Vector3d.rb +143 -131
  14. data/SketchUp/Layout.rb +25 -0
  15. data/SketchUp/Layout/AngularDimension.rb +569 -0
  16. data/SketchUp/Layout/AutoTextDefinition.rb +417 -0
  17. data/SketchUp/Layout/AutoTextDefinitions.rb +186 -0
  18. data/SketchUp/Layout/ConnectionPoint.rb +70 -0
  19. data/SketchUp/Layout/Document.rb +458 -0
  20. data/SketchUp/Layout/Ellipse.rb +29 -0
  21. data/SketchUp/Layout/Entities.rb +155 -0
  22. data/SketchUp/Layout/Entity.rb +363 -0
  23. data/SketchUp/Layout/FormattedText.rb +349 -0
  24. data/SketchUp/Layout/Grid.rb +131 -0
  25. data/SketchUp/Layout/Group.rb +261 -0
  26. data/SketchUp/Layout/Image.rb +86 -0
  27. data/SketchUp/Layout/Label.rb +371 -0
  28. data/SketchUp/Layout/Layer.rb +222 -0
  29. data/SketchUp/Layout/LayerInstance.rb +128 -0
  30. data/SketchUp/Layout/Layers.rb +232 -0
  31. data/SketchUp/Layout/LinearDimension.rb +563 -0
  32. data/SketchUp/Layout/LockedEntityError.rb +10 -0
  33. data/SketchUp/Layout/LockedLayerError.rb +11 -0
  34. data/SketchUp/Layout/Page.rb +187 -0
  35. data/SketchUp/Layout/PageInfo.rb +393 -0
  36. data/SketchUp/Layout/Pages.rb +216 -0
  37. data/SketchUp/Layout/Path.rb +326 -0
  38. data/SketchUp/Layout/Rectangle.rb +174 -0
  39. data/SketchUp/Layout/SketchUpModel.rb +522 -0
  40. data/SketchUp/Layout/Style.rb +1520 -0
  41. data/SketchUp/Layout/Table.rb +290 -0
  42. data/SketchUp/Layout/TableCell.rb +149 -0
  43. data/SketchUp/Layout/TableColumn.rb +139 -0
  44. data/SketchUp/Layout/TableRow.rb +135 -0
  45. data/SketchUp/Sketchup/Animation.rb +7 -4
  46. data/SketchUp/Sketchup/ArcCurve.rb +10 -10
  47. data/SketchUp/Sketchup/AttributeDictionaries.rb +13 -4
  48. data/SketchUp/Sketchup/AttributeDictionary.rb +12 -12
  49. data/SketchUp/Sketchup/Color.rb +68 -78
  50. data/SketchUp/Sketchup/ComponentDefinition.rb +60 -60
  51. data/SketchUp/Sketchup/ComponentInstance.rb +57 -55
  52. data/SketchUp/Sketchup/DefinitionList.rb +34 -17
  53. data/SketchUp/Sketchup/Drawingelement.rb +19 -21
  54. data/SketchUp/Sketchup/Edge.rb +22 -24
  55. data/SketchUp/Sketchup/Entities.rb +173 -162
  56. data/SketchUp/Sketchup/Entity.rb +71 -55
  57. data/SketchUp/Sketchup/Face.rb +45 -44
  58. data/SketchUp/Sketchup/Group.rb +47 -49
  59. data/SketchUp/Sketchup/Image.rb +16 -0
  60. data/SketchUp/Sketchup/ImageRep.rb +226 -0
  61. data/SketchUp/Sketchup/InstancePath.rb +13 -13
  62. data/SketchUp/Sketchup/Layer.rb +15 -17
  63. data/SketchUp/Sketchup/Material.rb +40 -30
  64. data/SketchUp/Sketchup/Materials.rb +40 -22
  65. data/SketchUp/Sketchup/Menu.rb +5 -5
  66. data/SketchUp/Sketchup/Model.rb +230 -228
  67. data/SketchUp/Sketchup/Page.rb +32 -0
  68. data/SketchUp/Sketchup/Pages.rb +3 -4
  69. data/SketchUp/Sketchup/RenderingOptions.rb +21 -16
  70. data/SketchUp/Sketchup/SectionPlane.rb +64 -0
  71. data/SketchUp/Sketchup/Selection.rb +20 -28
  72. data/SketchUp/Sketchup/ShadowInfo.rb +14 -14
  73. data/SketchUp/Sketchup/Text.rb +24 -26
  74. data/SketchUp/Sketchup/Texture.rb +28 -12
  75. data/SketchUp/Sketchup/Vertex.rb +14 -11
  76. data/SketchUp/Sketchup/View.rb +126 -116
  77. data/SketchUp/UI/Command.rb +17 -17
  78. data/SketchUp/UI/HtmlDialog.rb +8 -5
  79. data/SketchUp/UI/Notification.rb +1 -1
  80. data/SketchUp/UI/Toolbar.rb +13 -14
  81. data/SketchUp/UI/WebDialog.rb +55 -59
  82. data/SketchUp/_top_level.rb +139 -27
  83. data/SketchUp/{Array.rb → array.rb} +167 -30
  84. data/SketchUp/{Geom.rb → geom.rb} +9 -7
  85. data/SketchUp/{LanguageHandler.rb → languagehandler.rb} +15 -15
  86. data/SketchUp/{Length.rb → length.rb} +15 -15
  87. data/SketchUp/{Numeric.rb → numeric.rb} +19 -19
  88. data/SketchUp/sketchup.rb +167 -156
  89. data/SketchUp/{SketchupExtension.rb → sketchupextension.rb} +27 -27
  90. data/SketchUp/{String.rb → string.rb} +1 -1
  91. data/SketchUp/ui.rb +113 -87
  92. metadata +46 -9
@@ -41,10 +41,10 @@ class Sketchup::Entity
41
41
  # status = entity.add_observer observer
42
42
  # end
43
43
  #
44
- # @param observer
44
+ # @param [Object] observer
45
45
  # An observer.
46
46
  #
47
- # @return true if successful, false if unsuccessful.
47
+ # @return [Boolean] true if successful, false if unsuccessful.
48
48
  #
49
49
  # @version SketchUp 6.0
50
50
  def add_observer(observer)
@@ -73,7 +73,7 @@ class Sketchup::Entity
73
73
  # status = entity1.set_attribute "testdictionary", "test", 115
74
74
  # attrdicts = entity1.attribute_dictionaries
75
75
  #
76
- # @return attributedictionaries - the AttributeDictionaries
76
+ # @return [Sketchup::AttributeDictionaries, nil] the AttributeDictionaries
77
77
  # object associated with the entity, or nil if there are
78
78
  # no attribute_dictionary objects associated with the
79
79
  # model. Care must be taken if nil is returned, for
@@ -107,15 +107,15 @@ class Sketchup::Entity
107
107
  # status = entity1.set_attribute "testdictionary", "test", 115
108
108
  # attrdict = entity1.attribute_dictionary "testdictionary"
109
109
  #
110
- # @param name
110
+ # @param [String] name
111
111
  # The name of the attribute dictionary.
112
112
  #
113
- # @param [optional] create
113
+ # @param [Boolean] create
114
114
  # boolean, if set to true then the attribute
115
115
  # dictionary will be created if it does not exist.
116
116
  #
117
- # @return attributedictionary - an AttributeDictionary object if
118
- # successful, or nil if there is no attribute dictionary
117
+ # @return [Sketchup::AttributeDictionary, nil] - an AttributeDictionary object
118
+ # if successful, or nil if there is no attribute dictionary
119
119
  #
120
120
  # @version SketchUp 6.0
121
121
  def attribute_dictionary(name, create)
@@ -127,6 +127,11 @@ class Sketchup::Entity
127
127
  # AttributeDictionary. Otherwise, delete_attribute deletes the attribute with
128
128
  # the given key from the given dictionary.
129
129
  #
130
+ # In SketchUp 2018, special attribute dictionaries have been added. The name
131
+ # of these dictionaries are "SU_InstanceSet" and "SU_DefinitionSet". The
132
+ # dictionaries cannot be deleted via ruby and an ArgumentError will be raised.
133
+ # The key/value pairs in the dictionary can be deleted safely.
134
+ #
130
135
  # @example
131
136
  # depth = 100
132
137
  # width = 100
@@ -148,14 +153,14 @@ class Sketchup::Entity
148
153
  #
149
154
  # @overload delete_attribute(dictionary_name)
150
155
  #
151
- # @param dictionary_name The name of an attribute dictionary.
152
- # @return nil
156
+ # @param dictionary_name [String] The name of an attribute dictionary.
157
+ # @return [nil]
153
158
  #
154
159
  # @overload delete_attribute(dictionary_name, key)
155
160
  #
156
- # @param dictionary_name The name of an attribute dictionary.
157
- # @param key An attribute key.
158
- # @return nil
161
+ # @param dictionary_name [String] The name of an attribute dictionary.
162
+ # @param key [String] An attribute key.
163
+ # @return [nil]
159
164
  #
160
165
  # @version SketchUp 6.0
161
166
  def delete_attribute(*args)
@@ -180,7 +185,7 @@ class Sketchup::Entity
180
185
  # entity1 = entities[1]
181
186
  # status = entity1.deleted?
182
187
  #
183
- # @return status - true if deleted, false if not deleted
188
+ # @return [Boolean]
184
189
  #
185
190
  # @return [Boolean]
186
191
  #
@@ -208,52 +213,41 @@ class Sketchup::Entity
208
213
  # entity1 = entities[1]
209
214
  # id = entity1.entityID
210
215
  #
211
- # @return id - the id for the Entity object
216
+ # @return [Integer] the id for the Entity object
212
217
  #
213
218
  # @version SketchUp 6.0
214
219
  def entityID
215
220
  end
216
221
 
217
- # The get_attribute method is used to retrieve the value of an attribute in
222
+ # The {#get_attribute} method is used to retrieve the value of an attribute in
218
223
  # the entity's attribute dictionary.
219
224
  #
220
- # If the third parameter, default_value, is not passed and there is no
221
- # attribute that matches the given name, it returns nil.
225
+ # If the third parameter, +default_value+, is not passed and there is no
226
+ # attribute that matches the given name, it returns +nil+.
222
227
  #
223
- # If default_value is provided and there is no matching attribute it returns
228
+ # If +default_value+ is provided and there is no matching attribute it returns
224
229
  # the given value. It does not create an attribute with that name though.
225
230
  #
226
231
  # @example
227
- # depth = 100
228
- # width = 100
232
+ # # Add an entity to the model:
229
233
  # model = Sketchup.active_model
230
234
  # entities = model.active_entities
231
- # pts = []
232
- # pts[0] = [0, 0, 0]
233
- # pts[1] = [width, 0, 0]
234
- # pts[2] = [width, depth, 0]
235
- # pts[3] = [0, depth, 0]
236
- #
237
- # # Add the face to the entities in the model
238
- # face = entities.add_face pts
235
+ # edge = entities.add_line([0, 0, 0], [9, 9, 9])
239
236
  #
240
- # # I just happen to know that the second and third entities in the
241
- # # entities objects are edges.
242
- # entity1 = entities[1]
243
- # status = entity1.set_attribute "testdictionary", "test", 115
244
- # value = entity1.get_attribute "testdictoinary", "test"
237
+ # # Read an attribute value from the edge. In this case this will return the
238
+ # # default value provided; 42.
239
+ # value = edge.get_attribute("MyExtension", "MyProperty", 42)
245
240
  #
246
- # @param dict_name
241
+ # @param [String] dict_name
247
242
  # The name of an attribute dictionary.
248
243
  #
249
- # @param key
250
- # An attribute key.
244
+ # @param [Object] default_value
245
+ # A default value to return if no attribute is found.
251
246
  #
252
- # @param [optional] default_value
253
- # A default value to return if no attribute
254
- # is found.
247
+ # @param [String] key
248
+ # An attribute key.
255
249
  #
256
- # @return value - the retrieved value
250
+ # @return [Object] the retrieved value
257
251
  #
258
252
  # @version SketchUp 6.0
259
253
  def get_attribute(dict_name, key, default_value = nil)
@@ -280,7 +274,7 @@ class Sketchup::Entity
280
274
  # entity1 = entities[1]
281
275
  # st = entity1.to_s
282
276
  #
283
- # @return string - the string representation of the entity if
277
+ # @return [String] the string representation of the entity if
284
278
  # successful
285
279
  #
286
280
  # @version SketchUp 6.0
@@ -308,7 +302,7 @@ class Sketchup::Entity
308
302
  # entity1 = entities[1]
309
303
  # m = entity1.model
310
304
  #
311
- # @return model - the model that contains the Entity object
305
+ # @return [Sketchup::Model] the model that contains the Entity object
312
306
  #
313
307
  # @version SketchUp 6.0
314
308
  def model
@@ -338,8 +332,8 @@ class Sketchup::Entity
338
332
  # entity1 = entities[1]
339
333
  # parent = entity1.parent
340
334
  #
341
- # @return entity - a Entity object representing the parent of
342
- # this entity
335
+ # @return [Sketchup::ComponentDefinition, Sketchup::Model] a Entity object
336
+ # representing the parent of this entity
343
337
  #
344
338
  # @version SketchUp 6.0
345
339
  def parent
@@ -350,6 +344,28 @@ class Sketchup::Entity
350
344
  #
351
345
  # The persistent id persistent between sessions.
352
346
  #
347
+ # Note that only a subset of entity types support PIDs. Refer to the table
348
+ # below for which and when support was added.
349
+ #
350
+ # [SketchUp 2018]
351
+ # - {Sketchup::Page}
352
+ # [SketchUp 2017]
353
+ # - {Sketchup::Axes}
354
+ # - {Sketchup::ComponentDefinition}
355
+ # - {Sketchup::ComponentInstance}
356
+ # - {Sketchup::ConstructionLine}
357
+ # - {Sketchup::ConstructionPoint}
358
+ # - {Sketchup::Curve}
359
+ # - {Sketchup::Dimension}
360
+ # - {Sketchup::Edge}
361
+ # - {Sketchup::Face}
362
+ # - {Sketchup::SectionPlane}
363
+ # - {Sketchup::Text}
364
+ # - {Sketchup::Vertex}
365
+ # - Polyline3d entities exposed only as {Sketchup::Drawingelement} Use
366
+ # {#typename} to determine if a {Sketchup::Drawingelement} is
367
+ # a <tt>"Polyline3d"</tt>.
368
+ #
353
369
  # @example
354
370
  # model = Sketchup.active_model
355
371
  # entities = model.active_entities
@@ -382,10 +398,10 @@ class Sketchup::Entity
382
398
  # status = entity.remove_observer observer
383
399
  # end
384
400
  #
385
- # @param observer
401
+ # @param [Object] observer
386
402
  # An observer.
387
403
  #
388
- # @return true if successful, false if unsuccessful.
404
+ # @return [Boolean] true if successful, false if unsuccessful.
389
405
  #
390
406
  # @version SketchUp 6.0
391
407
  def remove_observer(observer)
@@ -419,16 +435,16 @@ class Sketchup::Entity
419
435
  # entity1 = entities[1]
420
436
  # status = entity1.set_attribute "testdictionary", "test", 115
421
437
  #
422
- # @param dict_name
438
+ # @param [String] dict_name
423
439
  # The name of an attribute dictionary.
424
440
  #
425
- # @param key
426
- # An attribute key.
427
- #
428
- # @param value
441
+ # @param [Object] value
429
442
  # The value for the attribute.
430
443
  #
431
- # @return value - the newly set value if successful
444
+ # @param [String] key
445
+ # An attribute key.
446
+ #
447
+ # @return [Object] the newly set value if successful
432
448
  #
433
449
  # @version SketchUp 6.0
434
450
  def set_attribute(dict_name, key, value)
@@ -455,7 +471,7 @@ class Sketchup::Entity
455
471
  # entity1 = entities[1]
456
472
  # st = entity1.to_s
457
473
  #
458
- # @return string - the string representation of the entity if
474
+ # @return [String] the string representation of the entity if
459
475
  # successful
460
476
  #
461
477
  # @version SketchUp 6.0
@@ -484,7 +500,7 @@ class Sketchup::Entity
484
500
  # entity1 = entities[1]
485
501
  # type = entity1.typename
486
502
  #
487
- # @return type - the type of the entity
503
+ # @return [String] the type of the entity
488
504
  #
489
505
  # @version SketchUp 6.0
490
506
  def typename
@@ -511,7 +527,7 @@ class Sketchup::Entity
511
527
  # entity1 = entities[1]
512
528
  # status = entity1.valid?
513
529
  #
514
- # @return status - true if deleted, false if not deleted
530
+ # @return [Boolean]
515
531
  #
516
532
  # @return [Boolean]
517
533
  #
@@ -35,7 +35,7 @@ class Sketchup::Face < Sketchup::Drawingelement
35
35
  # face = entities.add_face(pts)
36
36
  # connected = face.all_connected
37
37
  #
38
- # @return entities - the entities connected to the face
38
+ # @return [Array<Sketchup::Entity>] the entities connected to the face
39
39
  #
40
40
  # @version SketchUp 6.0
41
41
  def all_connected
@@ -66,15 +66,13 @@ class Sketchup::Face < Sketchup::Drawingelement
66
66
  #
67
67
  # @overload area
68
68
  #
69
- # @return area - the area of the face in current units (if
70
- # successful)
69
+ # @return [Float] the area of the face in current units (if successful)
71
70
  #
72
71
  # @overload area(transform)
73
72
  #
74
- # @param transform A Transformation object or array that can
75
- # be interpreted as a Transformation object.
76
- # @return area - the area of the face in current units (if
77
- # successful)
73
+ # @param transform [Geom::Transformation] A Transformation object or array
74
+ # that can be interpreted as a Transformation object.
75
+ # @return [Float] the area of the face in current units (if successful)
78
76
  #
79
77
  # @version SketchUp 6.0
80
78
  def area(*args)
@@ -101,7 +99,7 @@ class Sketchup::Face < Sketchup::Drawingelement
101
99
  # face.back_material = "red"
102
100
  # material = face.back_material
103
101
  #
104
- # @return material - a Material object representing the material
102
+ # @return [Sketchup::Material, nil] a Material object representing the material
105
103
  # on the back of the face (if successful)
106
104
  #
107
105
  # @version SketchUp 6.0
@@ -125,10 +123,10 @@ class Sketchup::Face < Sketchup::Drawingelement
125
123
  # face = entities.add_face(pts)
126
124
  # status = face.back_material = "red"
127
125
  #
128
- # @param material
126
+ # @param [Sketchup::Material] material
129
127
  # A Material object or the name of a valid material.
130
128
  #
131
- # @return material - the name of the valid material or the new
129
+ # @return [Sketchup::Material] the name of the valid material or the new
132
130
  # Material object (if successful)
133
131
  #
134
132
  # @version SketchUp 6.0
@@ -191,10 +189,10 @@ class Sketchup::Face < Sketchup::Drawingelement
191
189
  # puts "#{pt.to_s} is not on the same plane as the face"
192
190
  # end
193
191
  #
194
- # @param point
192
+ # @param [Geom::Point3d] point
195
193
  # A Point3d.
196
194
  #
197
- # @return result - an integer describing where a Point3d is in
195
+ # @return [Integer] an integer describing where a Point3d is in
198
196
  # relation to the referenced Face.
199
197
  #
200
198
  # @version SketchUp 6.0
@@ -217,7 +215,7 @@ class Sketchup::Face < Sketchup::Drawingelement
217
215
  # face = entities.add_face(pts)
218
216
  # edges = face.edges
219
217
  #
220
- # @return edges - an array of Edge objects (if successful)
218
+ # @return [Array<Sketchup::Edge>] an array of Edge objects (if successful)
221
219
  #
222
220
  # @version SketchUp 6.0
223
221
  def edges
@@ -279,18 +277,18 @@ class Sketchup::Face < Sketchup::Drawingelement
279
277
  # tw = Sketchup.create_texture_writer
280
278
  # uvHelp = face.get_UVHelper(true, true, tw)
281
279
  #
282
- # @param front
280
+ # @param [Boolean] front
283
281
  # True if you want the texture coordinates for the front
284
282
  # face, false if not. Defaults to true.
285
283
  #
286
- # @param back
284
+ # @param [Sketchup::TextureWriter] texturewriter
285
+ # An optional TextureWriter object.
286
+ #
287
+ # @param [Boolean] back
287
288
  # True if you want the texture coordinates for the back
288
289
  # face, false if not. Defaults to true.
289
290
  #
290
- # @param texturewriter
291
- # A TextureWriter object.
292
- #
293
- # @return uvhelper - a UVHelper object
291
+ # @return [Sketchup::UVHelper] a UVHelper object
294
292
  #
295
293
  # @version SketchUp 6.0
296
294
  def get_UVHelper(front, back, texturewriter)
@@ -313,7 +311,7 @@ class Sketchup::Face < Sketchup::Drawingelement
313
311
  # face = entities.add_face(pts)
314
312
  # glued_array = face.get_glued_instances
315
313
  #
316
- # @return instances - An array of ComponentInstance objects that
314
+ # @return [Array<Sketchup::ComponentInstance, Sketchup::Group, Sketchup::Image>] An array of ComponentInstance objects that
317
315
  # are currently glued to the face.
318
316
  #
319
317
  # @version SketchUp 7.0 M1
@@ -353,10 +351,10 @@ class Sketchup::Face < Sketchup::Drawingelement
353
351
  # # Get the projection of the applied material
354
352
  # vector = face.get_texture_projection(true)
355
353
  #
356
- # @param frontside
354
+ # @param [Boolean] frontside
357
355
  # true for front side, false for back side.
358
356
  #
359
- # @return vector - a vector on success, nil on failure.
357
+ # @return [Geom::Vector3d] a vector on success, nil on failure.
360
358
  #
361
359
  # @version SketchUp 2014
362
360
  def get_texture_projection(frontside)
@@ -380,7 +378,7 @@ class Sketchup::Face < Sketchup::Drawingelement
380
378
  # face = entities.add_face(pts)
381
379
  # loops = face.loops
382
380
  #
383
- # @return loops - an array of Loop objects if successful
381
+ # @return [Array<Sketchup::Loop>] an array of Loop objects if successful
384
382
  #
385
383
  # @version SketchUp 6.0
386
384
  def loops
@@ -408,7 +406,7 @@ class Sketchup::Face < Sketchup::Drawingelement
408
406
  # face.material = "red"
409
407
  # material = face.material
410
408
  #
411
- # @return material - a Material object representing the material
409
+ # @return [Sketchup::Material, nil] a Material object representing the material
412
410
  # on the front of the face (if successful)
413
411
  #
414
412
  # @version SketchUp 6.0
@@ -433,10 +431,10 @@ class Sketchup::Face < Sketchup::Drawingelement
433
431
  # face = entities.add_face(pts)
434
432
  # status = face.material = "red"
435
433
  #
436
- # @param material
434
+ # @param [Sketchup::Material] material
437
435
  # A Material object or the name of a valid material.
438
436
  #
439
- # @return material - the name of the valid material or the new
437
+ # @return [Sketchup::Material] the name of the valid material or the new
440
438
  # Material object (if successful)
441
439
  #
442
440
  # @version SketchUp 6.0
@@ -504,7 +502,7 @@ class Sketchup::Face < Sketchup::Drawingelement
504
502
  # face = entities.add_face(pts)
505
503
  # normal = face.normal
506
504
  #
507
- # @return vector - a Vector3d object if successful
505
+ # @return [Geom::Vector3d] a Vector3d object if successful
508
506
  #
509
507
  # @version SketchUp 6.0
510
508
  def normal
@@ -526,7 +524,7 @@ class Sketchup::Face < Sketchup::Drawingelement
526
524
  # face = entities.add_face(pts)
527
525
  # loop = face.outer_loop
528
526
  #
529
- # @return loop - a Loop object representing the outer loop (if
527
+ # @return [Sketchup::Loop] a Loop object representing the outer loop (if
530
528
  # successful)
531
529
  #
532
530
  # @version SketchUp 6.0
@@ -551,7 +549,7 @@ class Sketchup::Face < Sketchup::Drawingelement
551
549
  # face = entities.add_face(pts)
552
550
  # plane = face.plane
553
551
  #
554
- # @return plane - a plane that contains the face (if successful)
552
+ # @return [Array(Float, Float, Float, Float)] a plane that contains the face (if successful)
555
553
  #
556
554
  # @version SketchUp 6.0
557
555
  def plane
@@ -595,17 +593,17 @@ class Sketchup::Face < Sketchup::Drawingelement
595
593
  # on_front = true
596
594
  # face.position_material(material, pt_array, on_front)
597
595
  #
598
- # @param material
596
+ # @param [Sketchup::Material] material
599
597
  # a Material object.
600
598
  #
601
- # @param pt_array
602
- # An array of Point3d objects used to position the material.
603
- #
604
- # @param o_front
599
+ # @param [Boolean] o_front
605
600
  # true to position the texture on the front of the Face or
606
601
  # false to position it on the back of the Face.
607
602
  #
608
- # @return the face upon success, false upon failure.
603
+ # @param [Array<Geom::Point3d>] pt_array
604
+ # An array of Point3d objects used to position the material.
605
+ #
606
+ # @return [Sketchup::Face, false] the face upon success, false upon failure.
609
607
  #
610
608
  # @version SketchUp 6.0
611
609
  def position_material(material, pt_array, o_front)
@@ -629,18 +627,18 @@ class Sketchup::Face < Sketchup::Drawingelement
629
627
  # face = entities.add_face(pts)
630
628
  # status = face.pushpull(100, true)
631
629
  #
632
- # @param distance
630
+ # @param [Numeric] distance
633
631
  # The distance, in current units, to push/pull the face.
634
632
  #
635
- # @param copy
633
+ # @param [Boolean] copy
636
634
  # Create a new push/pull starting face if true (equivalent
637
635
  # of pressing CTRL while in SketchUp), do not create a
638
636
  # push/pull starting face if false.
639
637
  #
640
- # @return nil
638
+ # @return [nil]
641
639
  #
642
640
  # @version SketchUp 6.0
643
- def pushpull(distance, copy)
641
+ def pushpull(distance, copy = false)
644
642
  end
645
643
 
646
644
  # The reverse! method is used to reverse the face's orientation, meaning the
@@ -660,7 +658,7 @@ class Sketchup::Face < Sketchup::Drawingelement
660
658
  # face = entities.add_face(pts)
661
659
  # status = face.reverse!
662
660
  #
663
- # @return face - the reversed Face object if successful, false if
661
+ # @return [Sketchup::Face, false] the reversed Face object if successful, false if
664
662
  # unsuccessful
665
663
  #
666
664
  # @version SketchUp 6.0
@@ -670,6 +668,9 @@ class Sketchup::Face < Sketchup::Drawingelement
670
668
  # The set_texture_projection method is used to set the texture projection
671
669
  # direction.
672
670
  #
671
+ # @deprecated This function never worked right. It's not possible to control
672
+ # the position and orientation of the texture.
673
+ #
673
674
  # @example
674
675
  # model = Sketchup.active_model
675
676
  # entities = model.active_entities
@@ -697,14 +698,14 @@ class Sketchup::Face < Sketchup::Drawingelement
697
698
  # # Returns nil if not successful, path if successful
698
699
  # result = face.set_texture_projection(face.normal, true)
699
700
  #
700
- # @param vector
701
+ # @param [Geom::Vector3d] vector
701
702
  # representing the direction of the projection. Use nil
702
703
  # to remove the projection.
703
704
  #
704
- # @param frontside
705
+ # @param [Boolean] frontside
705
706
  # true for front side, false for back side.
706
707
  #
707
- # @return boolean - true on success
708
+ # @return [Boolean] true on success
708
709
  #
709
710
  # @version SketchUp 2014
710
711
  def set_texture_projection(vector, frontside)
@@ -728,7 +729,7 @@ class Sketchup::Face < Sketchup::Drawingelement
728
729
  # face = entities.add_face(pts)
729
730
  # vertices = face.vertices
730
731
  #
731
- # @return vertices - an array of Vertex objects if successful
732
+ # @return [Array<Sketchup::Vertex>] an array of Vertex objects if successful
732
733
  #
733
734
  # @version SketchUp 6.0
734
735
  def vertices