sketchup-api-stubs 0.3.1 → 0.4.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.
- checksums.yaml +5 -5
- data/.yardopts +7 -7
- data/SketchUp/Geom/BoundingBox.rb +7 -15
- data/SketchUp/Geom/Bounds2d.rb +18 -18
- data/SketchUp/Geom/LatLong.rb +6 -6
- data/SketchUp/Geom/OrientedBounds2d.rb +1 -1
- data/SketchUp/Geom/Point2d.rb +42 -6
- data/SketchUp/Geom/Point3d.rb +32 -21
- data/SketchUp/Geom/PolygonMesh.rb +22 -17
- data/SketchUp/Geom/Transformation.rb +35 -35
- data/SketchUp/Geom/Transformation2d.rb +153 -13
- data/SketchUp/Geom/UTM.rb +1 -1
- data/SketchUp/Geom/Vector2d.rb +45 -9
- data/SketchUp/Geom/Vector3d.rb +11 -11
- data/SketchUp/Layout.rb +1 -1
- data/SketchUp/Layout/AngularDimension.rb +25 -25
- data/SketchUp/Layout/AutoTextDefinition.rb +5 -5
- data/SketchUp/Layout/AutoTextDefinitions.rb +1 -1
- data/SketchUp/Layout/ConnectionPoint.rb +1 -1
- data/SketchUp/Layout/Document.rb +6 -5
- data/SketchUp/Layout/Ellipse.rb +1 -1
- data/SketchUp/Layout/Entities.rb +1 -1
- data/SketchUp/Layout/Entity.rb +16 -16
- data/SketchUp/Layout/FormattedText.rb +21 -21
- data/SketchUp/Layout/Grid.rb +1 -1
- data/SketchUp/Layout/Group.rb +18 -18
- data/SketchUp/Layout/Image.rb +6 -6
- data/SketchUp/Layout/Label.rb +15 -15
- data/SketchUp/Layout/Layer.rb +5 -5
- data/SketchUp/Layout/LayerInstance.rb +3 -3
- data/SketchUp/Layout/Layers.rb +1 -1
- data/SketchUp/Layout/LinearDimension.rb +25 -25
- data/SketchUp/Layout/LockedEntityError.rb +1 -1
- data/SketchUp/Layout/LockedLayerError.rb +1 -1
- data/SketchUp/Layout/Page.rb +3 -3
- data/SketchUp/Layout/PageInfo.rb +1 -1
- data/SketchUp/Layout/Pages.rb +1 -1
- data/SketchUp/Layout/Path.rb +47 -27
- data/SketchUp/Layout/Rectangle.rb +8 -8
- data/SketchUp/Layout/SketchUpModel.rb +61 -26
- data/SketchUp/Layout/Style.rb +18 -17
- data/SketchUp/Layout/Table.rb +14 -14
- data/SketchUp/Layout/TableCell.rb +5 -5
- data/SketchUp/Layout/TableColumn.rb +7 -7
- data/SketchUp/Layout/TableRow.rb +7 -7
- data/SketchUp/Sketchup/Animation.rb +1 -1
- data/SketchUp/Sketchup/AppObserver.rb +1 -1
- data/SketchUp/Sketchup/ArcCurve.rb +1 -1
- data/SketchUp/Sketchup/AttributeDictionaries.rb +1 -1
- data/SketchUp/Sketchup/AttributeDictionary.rb +7 -7
- data/SketchUp/Sketchup/Axes.rb +4 -4
- data/SketchUp/Sketchup/Behavior.rb +1 -1
- data/SketchUp/Sketchup/Camera.rb +30 -41
- data/SketchUp/Sketchup/ClassificationSchema.rb +1 -1
- data/SketchUp/Sketchup/Classifications.rb +1 -1
- data/SketchUp/Sketchup/Color.rb +1 -1
- data/SketchUp/Sketchup/ComponentDefinition.rb +3 -3
- data/SketchUp/Sketchup/ComponentInstance.rb +10 -10
- data/SketchUp/Sketchup/Console.rb +5 -5
- data/SketchUp/Sketchup/ConstructionLine.rb +11 -11
- data/SketchUp/Sketchup/ConstructionPoint.rb +1 -1
- data/SketchUp/Sketchup/Curve.rb +1 -1
- data/SketchUp/Sketchup/DefinitionList.rb +12 -9
- data/SketchUp/Sketchup/DefinitionObserver.rb +6 -7
- data/SketchUp/Sketchup/DefinitionsObserver.rb +3 -3
- data/SketchUp/Sketchup/Dimension.rb +1 -1
- data/SketchUp/Sketchup/DimensionLinear.rb +81 -1
- data/SketchUp/Sketchup/DimensionObserver.rb +1 -1
- data/SketchUp/Sketchup/DimensionRadial.rb +1 -1
- data/SketchUp/Sketchup/Drawingelement.rb +1 -1
- data/SketchUp/Sketchup/Edge.rb +13 -16
- data/SketchUp/Sketchup/EdgeUse.rb +1 -1
- data/SketchUp/Sketchup/Entities.rb +181 -100
- data/SketchUp/Sketchup/EntitiesObserver.rb +1 -1
- data/SketchUp/Sketchup/Entity.rb +29 -26
- data/SketchUp/Sketchup/EntityObserver.rb +1 -1
- data/SketchUp/Sketchup/ExtensionsManager.rb +1 -1
- data/SketchUp/Sketchup/Face.rb +7 -7
- data/SketchUp/Sketchup/FrameChangeObserver.rb +4 -4
- data/SketchUp/Sketchup/Group.rb +1 -1
- data/SketchUp/Sketchup/Http.rb +1 -1
- data/SketchUp/Sketchup/Http/Request.rb +3 -3
- data/SketchUp/Sketchup/Http/Response.rb +1 -1
- data/SketchUp/Sketchup/Image.rb +1 -1
- data/SketchUp/Sketchup/ImageRep.rb +16 -16
- data/SketchUp/Sketchup/Importer.rb +1 -1
- data/SketchUp/Sketchup/InputPoint.rb +8 -4
- data/SketchUp/Sketchup/InstanceObserver.rb +1 -1
- data/SketchUp/Sketchup/InstancePath.rb +15 -12
- data/SketchUp/Sketchup/Layer.rb +27 -1
- data/SketchUp/Sketchup/Layers.rb +1 -1
- data/SketchUp/Sketchup/LayersObserver.rb +1 -1
- data/SketchUp/Sketchup/Licensing.rb +1 -1
- data/SketchUp/Sketchup/Licensing/ExtensionLicense.rb +1 -1
- data/SketchUp/Sketchup/LineStyle.rb +24 -0
- data/SketchUp/Sketchup/LineStyles.rb +123 -0
- data/SketchUp/Sketchup/Loop.rb +1 -1
- data/SketchUp/Sketchup/Material.rb +16 -10
- data/SketchUp/Sketchup/Materials.rb +9 -1
- data/SketchUp/Sketchup/MaterialsObserver.rb +3 -3
- data/SketchUp/Sketchup/Menu.rb +1 -1
- data/SketchUp/Sketchup/Model.rb +47 -21
- data/SketchUp/Sketchup/ModelObserver.rb +3 -3
- data/SketchUp/Sketchup/OptionsManager.rb +1 -1
- data/SketchUp/Sketchup/OptionsProvider.rb +5 -5
- data/SketchUp/Sketchup/OptionsProviderObserver.rb +1 -1
- data/SketchUp/Sketchup/Page.rb +1 -1
- data/SketchUp/Sketchup/Pages.rb +13 -8
- data/SketchUp/Sketchup/PagesObserver.rb +1 -1
- data/SketchUp/Sketchup/PickHelper.rb +49 -50
- data/SketchUp/Sketchup/RegionalSettings.rb +1 -1
- data/SketchUp/Sketchup/RenderingOptions.rb +4 -4
- data/SketchUp/Sketchup/RenderingOptionsObserver.rb +3 -3
- data/SketchUp/Sketchup/SectionPlane.rb +1 -1
- data/SketchUp/Sketchup/Selection.rb +3 -3
- data/SketchUp/Sketchup/SelectionObserver.rb +3 -3
- data/SketchUp/Sketchup/Set.rb +1 -1
- data/SketchUp/Sketchup/ShadowInfo.rb +3 -3
- data/SketchUp/Sketchup/ShadowInfoObserver.rb +1 -1
- data/SketchUp/Sketchup/Style.rb +1 -1
- data/SketchUp/Sketchup/Styles.rb +1 -1
- data/SketchUp/Sketchup/Text.rb +28 -1
- data/SketchUp/Sketchup/Texture.rb +1 -1
- data/SketchUp/Sketchup/TextureWriter.rb +13 -13
- data/SketchUp/Sketchup/Tool.rb +68 -64
- data/SketchUp/Sketchup/Tools.rb +13 -1
- data/SketchUp/Sketchup/ToolsObserver.rb +13 -13
- data/SketchUp/Sketchup/UVHelper.rb +1 -1
- data/SketchUp/Sketchup/Vertex.rb +1 -1
- data/SketchUp/Sketchup/View.rb +57 -56
- data/SketchUp/Sketchup/ViewObserver.rb +2 -2
- data/SketchUp/UI/Command.rb +4 -1
- data/SketchUp/UI/HtmlDialog.rb +23 -14
- data/SketchUp/UI/Notification.rb +10 -10
- data/SketchUp/UI/Toolbar.rb +1 -1
- data/SketchUp/UI/WebDialog.rb +38 -20
- data/SketchUp/_top_level.rb +32 -34
- data/SketchUp/array.rb +125 -112
- data/SketchUp/geom.rb +2 -2
- data/SketchUp/languagehandler.rb +1 -1
- data/SketchUp/length.rb +1 -1
- data/SketchUp/numeric.rb +3 -3
- data/SketchUp/sketchup.rb +11 -11
- data/SketchUp/sketchupextension.rb +6 -2
- data/SketchUp/string.rb +1 -1
- data/SketchUp/ui.rb +14 -14
- data/autoload/sketchup.rb +2 -0
- metadata +5 -3
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# Copyright:: Copyright
|
|
1
|
+
# Copyright:: Copyright 2019 Trimble Inc.
|
|
2
2
|
# License:: The MIT License (MIT)
|
|
3
3
|
|
|
4
4
|
# This observer interface is implemented to react to model events. To
|
|
@@ -57,9 +57,9 @@ class Sketchup::ModelObserver
|
|
|
57
57
|
#
|
|
58
58
|
# @return [nil]
|
|
59
59
|
#
|
|
60
|
-
# @see Sketchup::Model#edit_transform
|
|
61
|
-
#
|
|
62
60
|
# @see Sketchup::Model#active_path
|
|
61
|
+
#
|
|
62
|
+
# @see Sketchup::Model#edit_transform
|
|
63
63
|
def onActivePathChanged(model)
|
|
64
64
|
end
|
|
65
65
|
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# Copyright:: Copyright
|
|
1
|
+
# Copyright:: Copyright 2019 Trimble Inc.
|
|
2
2
|
# License:: The MIT License (MIT)
|
|
3
3
|
|
|
4
4
|
# An OptionsProvider class provides various kinds of options on a Model. You
|
|
@@ -103,9 +103,9 @@ class Sketchup::OptionsProvider
|
|
|
103
103
|
#
|
|
104
104
|
# @yield [key, value]
|
|
105
105
|
#
|
|
106
|
-
# @yieldparam [Object] value
|
|
107
|
-
#
|
|
108
106
|
# @yieldparam [String] key
|
|
107
|
+
#
|
|
108
|
+
# @yieldparam [Object] value
|
|
109
109
|
def each
|
|
110
110
|
end
|
|
111
111
|
|
|
@@ -139,9 +139,9 @@ class Sketchup::OptionsProvider
|
|
|
139
139
|
#
|
|
140
140
|
# @yield [key, value]
|
|
141
141
|
#
|
|
142
|
-
# @yieldparam [Object] value
|
|
143
|
-
#
|
|
144
142
|
# @yieldparam [String] key
|
|
143
|
+
#
|
|
144
|
+
# @yieldparam [Object] value
|
|
145
145
|
def each_pair
|
|
146
146
|
end
|
|
147
147
|
|
data/SketchUp/Sketchup/Page.rb
CHANGED
data/SketchUp/Sketchup/Pages.rb
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# Copyright:: Copyright
|
|
1
|
+
# Copyright:: Copyright 2019 Trimble Inc.
|
|
2
2
|
# License:: The MIT License (MIT)
|
|
3
3
|
|
|
4
4
|
# The Pages class contains methods for manipulating a collection of Pages
|
|
@@ -296,20 +296,25 @@ class Sketchup::Pages < Sketchup::Entity
|
|
|
296
296
|
def selected_page=(page)
|
|
297
297
|
end
|
|
298
298
|
|
|
299
|
-
# The show_frame_at method is used to show a frame in animation (of the
|
|
300
|
-
# show) at a given time in seconds.
|
|
299
|
+
# The {#show_frame_at} method is used to show a frame in animation (of the
|
|
300
|
+
# slide show) at a given time in seconds.
|
|
301
301
|
#
|
|
302
302
|
# @example
|
|
303
303
|
# model = Sketchup.active_model
|
|
304
304
|
# pages = model.pages
|
|
305
|
-
#
|
|
306
|
-
#
|
|
307
|
-
#
|
|
305
|
+
# pages.add("Page 1")
|
|
306
|
+
# pages.add("Page 2")
|
|
307
|
+
# page, ratio = pages.show_frame_at(1.8)
|
|
308
308
|
#
|
|
309
|
-
# @
|
|
309
|
+
# @note In versions prior to SketchUp 2019 this method will crash if called
|
|
310
|
+
# when there are no pages in the model.
|
|
311
|
+
#
|
|
312
|
+
# @param [Float] seconds
|
|
310
313
|
# The time in seconds.
|
|
311
314
|
#
|
|
312
|
-
# @return nil
|
|
315
|
+
# @return [Array(Sketchup::Page, Float), nil] Upon success it returns the
|
|
316
|
+
# page that is displayed and a parameter between +0.0+ and +1.0+ that is
|
|
317
|
+
# tells how far along the transition to next page you are at.
|
|
313
318
|
#
|
|
314
319
|
# @version SketchUp 6.0
|
|
315
320
|
def show_frame_at(seconds)
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# Copyright:: Copyright
|
|
1
|
+
# Copyright:: Copyright 2019 Trimble Inc.
|
|
2
2
|
# License:: The MIT License (MIT)
|
|
3
3
|
|
|
4
4
|
# The PickHelper class is used to pick entities that reside under the current
|
|
@@ -174,10 +174,10 @@ class Sketchup::PickHelper
|
|
|
174
174
|
def element_at(index)
|
|
175
175
|
end
|
|
176
176
|
|
|
177
|
-
# The init method is used to initialize the PickHelper for testing points.
|
|
177
|
+
# The {#init} method is used to initialize the PickHelper for testing points.
|
|
178
178
|
#
|
|
179
179
|
# You do not normally need to call this method, but you can use this if you
|
|
180
|
-
# want to call test_point or pick_segment on a lot of points.
|
|
180
|
+
# want to call {#test_point} or {#pick_segment} on a lot of points.
|
|
181
181
|
#
|
|
182
182
|
# If the optional aperture is given, it is given in pixels.
|
|
183
183
|
#
|
|
@@ -189,16 +189,16 @@ class Sketchup::PickHelper
|
|
|
189
189
|
# ph.test_point(point)
|
|
190
190
|
# }
|
|
191
191
|
#
|
|
192
|
-
# @param x
|
|
192
|
+
# @param [Integer] x
|
|
193
193
|
# X screen coordinate for the pick.
|
|
194
194
|
#
|
|
195
|
-
# @param y
|
|
195
|
+
# @param [Integer] y
|
|
196
196
|
# Y screen coordinate for the pick.
|
|
197
197
|
#
|
|
198
|
-
# @param [
|
|
198
|
+
# @param [Integer] aperture
|
|
199
199
|
# aperture in pixels.
|
|
200
200
|
#
|
|
201
|
-
# @return
|
|
201
|
+
# @return [PickHelper] self
|
|
202
202
|
#
|
|
203
203
|
# @version SketchUp 6.0
|
|
204
204
|
def init(x, y, aperture = 0)
|
|
@@ -255,17 +255,18 @@ class Sketchup::PickHelper
|
|
|
255
255
|
def path_at(index)
|
|
256
256
|
end
|
|
257
257
|
|
|
258
|
-
# The pick_segment method is used to pick a segment of a polyline curve that
|
|
258
|
+
# The {#pick_segment} method is used to pick a segment of a polyline curve that
|
|
259
259
|
# is defined by an array of points.
|
|
260
260
|
#
|
|
261
261
|
# If you click on a point in a polyline curve, the index of
|
|
262
|
-
# the point in the curve is returned (starting at 0).
|
|
263
|
-
# segment in the polyline curve, the index of the segment is returned.
|
|
264
|
-
# Segments start at index -1 (for the segment connecting the first two points)
|
|
265
|
-
# and increase by a factor of -1 (for example, the segment connecting second
|
|
266
|
-
# and third point is -2).
|
|
262
|
+
# the point in the curve is returned (starting at 0).
|
|
267
263
|
#
|
|
268
|
-
#
|
|
264
|
+
# If you click on a segment in the polyline curve, the index of the segment is
|
|
265
|
+
# returned. Segments are returned by negative indicies and start at index -1
|
|
266
|
+
# (for the segment connecting the first two points) and increase by a factor
|
|
267
|
+
# of -1 (for example, the segment connecting second and third point is -2).
|
|
268
|
+
#
|
|
269
|
+
# There is no need to invoke {#do_pick} for this and the results are unrelated.
|
|
269
270
|
#
|
|
270
271
|
# @example
|
|
271
272
|
# point1 = Geom::Point3d.new(0 ,0, 0)
|
|
@@ -275,29 +276,33 @@ class Sketchup::PickHelper
|
|
|
275
276
|
# # If testing many points this is the fastest way to test.
|
|
276
277
|
# ph.init(x, y)
|
|
277
278
|
# picked = ph.pick_segment(segment)
|
|
278
|
-
# # This do not require init
|
|
279
|
+
# # This do not require .init
|
|
279
280
|
# picked = ph.pick_segment(segment, x, y)
|
|
280
281
|
#
|
|
281
|
-
# @
|
|
282
|
-
# A series of Point3d objects in the polyline as a list
|
|
283
|
-
# of parameters or an array containing Point3d objects.
|
|
282
|
+
# @note The return value will be a negative index when a segment is picked.
|
|
284
283
|
#
|
|
285
|
-
# @
|
|
286
|
-
# screen mouse position in pixels.
|
|
284
|
+
# @overload pick_segment(points)
|
|
287
285
|
#
|
|
288
|
-
#
|
|
289
|
-
#
|
|
286
|
+
# This is more efficient if you need to test a number of segments for the
|
|
287
|
+
# same set of screen coordinates. But then you must use {#init} first.
|
|
288
|
+
# @param [Array<Geom::Point3d>] points A series of points in the polyline as
|
|
289
|
+
# a list of parameters or an array containing Point3d
|
|
290
|
+
# objects.
|
|
291
|
+
# @return [Integer, false] an index on success, +false+ on failure
|
|
290
292
|
#
|
|
291
|
-
# @
|
|
292
|
-
# screen mouse position
|
|
293
|
-
# in pixels.
|
|
293
|
+
# @overload pick_segment(points, x, y, aperture = 0)
|
|
294
294
|
#
|
|
295
|
-
#
|
|
296
|
-
#
|
|
297
|
-
#
|
|
295
|
+
# @param [Array<Geom::Point3d>] points A series of points in the polyline as
|
|
296
|
+
# a list of parameters or an array containing Point3d
|
|
297
|
+
# objects.
|
|
298
|
+
# @param [Integer] x screen mouse position in pixels.
|
|
299
|
+
# @param [Integer] y (required if x given) screen mouse position
|
|
300
|
+
# in pixels.
|
|
301
|
+
# @param aperture aperture in pixels.
|
|
302
|
+
# @return [Integer, false] an index on success, +false+ on failure
|
|
298
303
|
#
|
|
299
304
|
# @version SketchUp 6.0
|
|
300
|
-
def pick_segment(
|
|
305
|
+
def pick_segment(*args)
|
|
301
306
|
end
|
|
302
307
|
|
|
303
308
|
# The picked_edge method is used to retrieve the "best" Edge picked.
|
|
@@ -352,18 +357,10 @@ class Sketchup::PickHelper
|
|
|
352
357
|
def picked_face
|
|
353
358
|
end
|
|
354
359
|
|
|
355
|
-
# The test_point method is used to test a point to see if it would be
|
|
356
|
-
# using the default or given pick aperture.
|
|
360
|
+
# The {#test_point} method is used to test a point to see if it would be
|
|
361
|
+
# selected using the default or given pick aperture.
|
|
357
362
|
#
|
|
358
|
-
#
|
|
359
|
-
# method. This is more efficient if you want to test a lot of points using the
|
|
360
|
-
# same screen point.
|
|
361
|
-
#
|
|
362
|
-
# In the second and third forms, it initializes the
|
|
363
|
-
# PickHelper using a screen point and an optional pick aperture that you pass
|
|
364
|
-
# in as the 2nd-4th arguments.
|
|
365
|
-
#
|
|
366
|
-
# There is no need to invoke do_pick for this and the results are unrelated.
|
|
363
|
+
# There is no need to invoke {#do_pick} for this and the results are unrelated.
|
|
367
364
|
#
|
|
368
365
|
# @example
|
|
369
366
|
# ph = view.pick_helper
|
|
@@ -374,22 +371,24 @@ class Sketchup::PickHelper
|
|
|
374
371
|
# picked = ph.test_point(point, x, y)
|
|
375
372
|
# picked = ph.test_point(point, x, y, aperture)
|
|
376
373
|
#
|
|
377
|
-
# @
|
|
378
|
-
# Screen point.
|
|
374
|
+
# @overload test_point(point)
|
|
379
375
|
#
|
|
380
|
-
#
|
|
381
|
-
#
|
|
376
|
+
# This is more efficient if you want to test a lot of points using the same
|
|
377
|
+
# screen point. But you *must* have called the {#init} method first for this
|
|
378
|
+
# to work.
|
|
379
|
+
# @param [Geom::Point3d] point
|
|
382
380
|
#
|
|
383
|
-
# @
|
|
384
|
-
# aperture in pixels.
|
|
381
|
+
# @overload test_point(point, x, y, aperture = 0)
|
|
385
382
|
#
|
|
386
|
-
#
|
|
387
|
-
#
|
|
383
|
+
# @param [Geom::Point3d] point
|
|
384
|
+
# @param [Integer] x
|
|
385
|
+
# @param [Integer] y
|
|
386
|
+
# @param [Integer] aperture
|
|
388
387
|
#
|
|
389
|
-
# @return
|
|
388
|
+
# @return [Boolean]
|
|
390
389
|
#
|
|
391
390
|
# @version SketchUp 6.0
|
|
392
|
-
def test_point(
|
|
391
|
+
def test_point(*args)
|
|
393
392
|
end
|
|
394
393
|
|
|
395
394
|
# The transformation_at method is used to get a transformation at a specific
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# Copyright:: Copyright
|
|
1
|
+
# Copyright:: Copyright 2019 Trimble Inc.
|
|
2
2
|
# License:: The MIT License (MIT)
|
|
3
3
|
|
|
4
4
|
# The RenderingOptions class contains method to extract the rendering
|
|
@@ -255,11 +255,11 @@ class Sketchup::RenderingOptions < Sketchup::Entity
|
|
|
255
255
|
#
|
|
256
256
|
# @yield [key, value]
|
|
257
257
|
#
|
|
258
|
-
# @yieldparam [Object] value
|
|
259
|
-
# The value of each pair found.
|
|
260
|
-
#
|
|
261
258
|
# @yieldparam [String] key
|
|
262
259
|
# The key of each pair found.
|
|
260
|
+
#
|
|
261
|
+
# @yieldparam [Object] value
|
|
262
|
+
# The value of each pair found.
|
|
263
263
|
def each
|
|
264
264
|
end
|
|
265
265
|
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# Copyright:: Copyright
|
|
1
|
+
# Copyright:: Copyright 2019 Trimble Inc.
|
|
2
2
|
# License:: The MIT License (MIT)
|
|
3
3
|
|
|
4
4
|
# This observer interface is implemented to react to rendering options events.
|
|
@@ -30,13 +30,13 @@ class Sketchup::RenderingOptionsObserver
|
|
|
30
30
|
# puts "onRenderingOptionsChanged(#{rendering_options}, #{type})"
|
|
31
31
|
# end
|
|
32
32
|
#
|
|
33
|
+
# @param [Sketchup::RenderingOptions] rendering_options
|
|
34
|
+
#
|
|
33
35
|
# @param [Integer] type
|
|
34
36
|
# A number indicating which option was changed
|
|
35
37
|
# represented by one of the constants defined in
|
|
36
38
|
# {Sketchup::RenderingOptions}.
|
|
37
39
|
#
|
|
38
|
-
# @param [Sketchup::RenderingOptions] rendering_options
|
|
39
|
-
#
|
|
40
40
|
# @version SketchUp 6.0
|
|
41
41
|
def onRenderingOptionsChanged(rendering_options, type)
|
|
42
42
|
end
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# Copyright:: Copyright
|
|
1
|
+
# Copyright:: Copyright 2019 Trimble Inc.
|
|
2
2
|
# License:: The MIT License (MIT)
|
|
3
3
|
|
|
4
4
|
# A set of the currently selected entities. Use the Model.selection method
|
|
@@ -271,10 +271,10 @@ class Sketchup::Selection
|
|
|
271
271
|
#
|
|
272
272
|
# @return [Integer]
|
|
273
273
|
#
|
|
274
|
-
# @see #nitems
|
|
275
|
-
#
|
|
276
274
|
# @see #size
|
|
277
275
|
#
|
|
276
|
+
# @see #nitems
|
|
277
|
+
#
|
|
278
278
|
# @version SketchUp 6.0
|
|
279
279
|
def length
|
|
280
280
|
end
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# Copyright:: Copyright
|
|
1
|
+
# Copyright:: Copyright 2019 Trimble Inc.
|
|
2
2
|
# License:: The MIT License (MIT)
|
|
3
3
|
|
|
4
4
|
# This observer interface is implemented to react to selection events. To
|
|
@@ -102,10 +102,10 @@ class Sketchup::SelectionObserver
|
|
|
102
102
|
# @note Due to a bug in SketchUp this event doesn't trigger. Instead
|
|
103
103
|
# +onSelectedRemoved+ is called.
|
|
104
104
|
#
|
|
105
|
-
# @param [Sketchup::Entity] entity
|
|
106
|
-
#
|
|
107
105
|
# @param [Sketchup::Selection] selection
|
|
108
106
|
#
|
|
107
|
+
# @param [Sketchup::Entity] entity
|
|
108
|
+
#
|
|
109
109
|
# @return [nil]
|
|
110
110
|
#
|
|
111
111
|
# @version SketchUp 6.0
|
data/SketchUp/Sketchup/Set.rb
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# Copyright:: Copyright
|
|
1
|
+
# Copyright:: Copyright 2019 Trimble Inc.
|
|
2
2
|
# License:: The MIT License (MIT)
|
|
3
3
|
|
|
4
4
|
# The ShadowInfo class contains method to extract the shadow information for a
|
|
@@ -156,9 +156,9 @@ class Sketchup::ShadowInfo < Sketchup::Entity
|
|
|
156
156
|
#
|
|
157
157
|
# @yield [key, value]
|
|
158
158
|
#
|
|
159
|
-
# @yieldparam [Object] value
|
|
160
|
-
#
|
|
161
159
|
# @yieldparam [String] key
|
|
160
|
+
#
|
|
161
|
+
# @yieldparam [Object] value
|
|
162
162
|
def each
|
|
163
163
|
end
|
|
164
164
|
|
data/SketchUp/Sketchup/Style.rb
CHANGED
data/SketchUp/Sketchup/Styles.rb
CHANGED
data/SketchUp/Sketchup/Text.rb
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# Copyright:: Copyright
|
|
1
|
+
# Copyright:: Copyright 2019 Trimble Inc.
|
|
2
2
|
# License:: The MIT License (MIT)
|
|
3
3
|
|
|
4
4
|
# The Text class contains method to manipulate a Text entity object.
|
|
@@ -43,6 +43,33 @@ class Sketchup::Text < Sketchup::Drawingelement
|
|
|
43
43
|
def arrow_type=(type)
|
|
44
44
|
end
|
|
45
45
|
|
|
46
|
+
# The {#attached_to} method returns an array of the attached
|
|
47
|
+
# {Sketchup::InstancePath} object and the {Geom::Point3d}.
|
|
48
|
+
#
|
|
49
|
+
# @example
|
|
50
|
+
# # Have a text annotation attached to a drawing element and selected
|
|
51
|
+
# Sketchup.active_model.selection[0].attached_to
|
|
52
|
+
#
|
|
53
|
+
# @return [Array(Sketchup::InstancePath, Geom::Point3d), nil]
|
|
54
|
+
#
|
|
55
|
+
# @version SketchUp 2019
|
|
56
|
+
def attached_to
|
|
57
|
+
end
|
|
58
|
+
|
|
59
|
+
# The {#attached_to=} method will attach the {Sketchup::Text} to another
|
|
60
|
+
# {Sketchup::DrawingElement}.
|
|
61
|
+
#
|
|
62
|
+
# @example
|
|
63
|
+
# # Have a text annotation attached to a drawing element and selected
|
|
64
|
+
# array = Sketchup.active_model.selection[0].attached_to
|
|
65
|
+
# Sketchup.active_model.selection[0].attached_to = [array[0], Geom::Point3d.new(0, 0, 0)]
|
|
66
|
+
#
|
|
67
|
+
# @param [Array(Sketchup::InstancePath, Geom::Point3d)] path
|
|
68
|
+
#
|
|
69
|
+
# @version SketchUp 2019
|
|
70
|
+
def attached_to=(path)
|
|
71
|
+
end
|
|
72
|
+
|
|
46
73
|
# The display_leader= method accepts true or false for whether to display the
|
|
47
74
|
# leader.
|
|
48
75
|
#
|