sketchup-api-stubs 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (107) hide show
  1. checksums.yaml +7 -0
  2. data/SketchUp/Geom/BoundingBox.rb +335 -0
  3. data/SketchUp/Geom/LatLong.rb +123 -0
  4. data/SketchUp/Geom/Point3d.rb +643 -0
  5. data/SketchUp/Geom/PolygonMesh.rb +478 -0
  6. data/SketchUp/Geom/Transformation.rb +476 -0
  7. data/SketchUp/Geom/UTM.rb +135 -0
  8. data/SketchUp/Geom/Vector3d.rb +684 -0
  9. data/SketchUp/Sketchup/Animation.rb +137 -0
  10. data/SketchUp/Sketchup/AppObserver.rb +157 -0
  11. data/SketchUp/Sketchup/ArcCurve.rb +209 -0
  12. data/SketchUp/Sketchup/AttributeDictionaries.rb +146 -0
  13. data/SketchUp/Sketchup/AttributeDictionary.rb +280 -0
  14. data/SketchUp/Sketchup/Axes.rb +149 -0
  15. data/SketchUp/Sketchup/Behavior.rb +338 -0
  16. data/SketchUp/Sketchup/Camera.rb +594 -0
  17. data/SketchUp/Sketchup/ClassificationSchema.rb +63 -0
  18. data/SketchUp/Sketchup/Classifications.rb +118 -0
  19. data/SketchUp/Sketchup/Color.rb +291 -0
  20. data/SketchUp/Sketchup/ComponentDefinition.rb +562 -0
  21. data/SketchUp/Sketchup/ComponentInstance.rb +597 -0
  22. data/SketchUp/Sketchup/Console.rb +78 -0
  23. data/SketchUp/Sketchup/ConstructionLine.rb +257 -0
  24. data/SketchUp/Sketchup/ConstructionPoint.rb +32 -0
  25. data/SketchUp/Sketchup/Curve.rb +196 -0
  26. data/SketchUp/Sketchup/DefinitionList.rb +312 -0
  27. data/SketchUp/Sketchup/DefinitionObserver.rb +73 -0
  28. data/SketchUp/Sketchup/DefinitionsObserver.rb +102 -0
  29. data/SketchUp/Sketchup/Dimension.rb +167 -0
  30. data/SketchUp/Sketchup/DimensionLinear.rb +232 -0
  31. data/SketchUp/Sketchup/DimensionObserver.rb +38 -0
  32. data/SketchUp/Sketchup/DimensionRadial.rb +87 -0
  33. data/SketchUp/Sketchup/Drawingelement.rb +400 -0
  34. data/SketchUp/Sketchup/Edge.rb +517 -0
  35. data/SketchUp/Sketchup/EdgeUse.rb +213 -0
  36. data/SketchUp/Sketchup/Entities.rb +1011 -0
  37. data/SketchUp/Sketchup/EntitiesObserver.rb +125 -0
  38. data/SketchUp/Sketchup/Entity.rb +522 -0
  39. data/SketchUp/Sketchup/EntityObserver.rb +59 -0
  40. data/SketchUp/Sketchup/ExtensionsManager.rb +129 -0
  41. data/SketchUp/Sketchup/Face.rb +737 -0
  42. data/SketchUp/Sketchup/FrameChangeObserver.rb +104 -0
  43. data/SketchUp/Sketchup/Group.rb +705 -0
  44. data/SketchUp/Sketchup/Http.rb +27 -0
  45. data/SketchUp/Sketchup/Http/Request.rb +285 -0
  46. data/SketchUp/Sketchup/Http/Response.rb +62 -0
  47. data/SketchUp/Sketchup/Image.rb +393 -0
  48. data/SketchUp/Sketchup/Importer.rb +192 -0
  49. data/SketchUp/Sketchup/InputPoint.rb +393 -0
  50. data/SketchUp/Sketchup/InstanceObserver.rb +82 -0
  51. data/SketchUp/Sketchup/InstancePath.rb +297 -0
  52. data/SketchUp/Sketchup/Layer.rb +240 -0
  53. data/SketchUp/Sketchup/Layers.rb +235 -0
  54. data/SketchUp/Sketchup/LayersObserver.rb +136 -0
  55. data/SketchUp/Sketchup/Licensing.rb +47 -0
  56. data/SketchUp/Sketchup/Licensing/ExtensionLicense.rb +88 -0
  57. data/SketchUp/Sketchup/Loop.rb +141 -0
  58. data/SketchUp/Sketchup/Material.rb +384 -0
  59. data/SketchUp/Sketchup/Materials.rb +283 -0
  60. data/SketchUp/Sketchup/MaterialsObserver.rb +141 -0
  61. data/SketchUp/Sketchup/Menu.rb +97 -0
  62. data/SketchUp/Sketchup/Model.rb +1459 -0
  63. data/SketchUp/Sketchup/ModelObserver.rb +356 -0
  64. data/SketchUp/Sketchup/OptionsManager.rb +135 -0
  65. data/SketchUp/Sketchup/OptionsProvider.rb +277 -0
  66. data/SketchUp/Sketchup/OptionsProviderObserver.rb +58 -0
  67. data/SketchUp/Sketchup/Page.rb +636 -0
  68. data/SketchUp/Sketchup/Pages.rb +349 -0
  69. data/SketchUp/Sketchup/PagesObserver.rb +76 -0
  70. data/SketchUp/Sketchup/PickHelper.rb +457 -0
  71. data/SketchUp/Sketchup/RegionalSettings.rb +43 -0
  72. data/SketchUp/Sketchup/RenderingOptions.rb +337 -0
  73. data/SketchUp/Sketchup/RenderingOptionsObserver.rb +44 -0
  74. data/SketchUp/Sketchup/SectionPlane.rb +88 -0
  75. data/SketchUp/Sketchup/Selection.rb +470 -0
  76. data/SketchUp/Sketchup/SelectionObserver.rb +115 -0
  77. data/SketchUp/Sketchup/Set.rb +253 -0
  78. data/SketchUp/Sketchup/ShadowInfo.rb +257 -0
  79. data/SketchUp/Sketchup/ShadowInfoObserver.rb +57 -0
  80. data/SketchUp/Sketchup/Style.rb +77 -0
  81. data/SketchUp/Sketchup/Styles.rb +204 -0
  82. data/SketchUp/Sketchup/Text.rb +241 -0
  83. data/SketchUp/Sketchup/Texture.rb +211 -0
  84. data/SketchUp/Sketchup/TextureWriter.rb +237 -0
  85. data/SketchUp/Sketchup/Tool.rb +808 -0
  86. data/SketchUp/Sketchup/Tools.rb +120 -0
  87. data/SketchUp/Sketchup/ToolsObserver.rb +154 -0
  88. data/SketchUp/Sketchup/UVHelper.rb +61 -0
  89. data/SketchUp/Sketchup/Vertex.rb +143 -0
  90. data/SketchUp/Sketchup/View.rb +965 -0
  91. data/SketchUp/Sketchup/ViewObserver.rb +40 -0
  92. data/SketchUp/UI/Command.rb +307 -0
  93. data/SketchUp/UI/HtmlDialog.rb +346 -0
  94. data/SketchUp/UI/Notification.rb +229 -0
  95. data/SketchUp/UI/Toolbar.rb +243 -0
  96. data/SketchUp/UI/WebDialog.rb +623 -0
  97. data/SketchUp/_top_level.rb +193 -0
  98. data/SketchUp/array.rb +593 -0
  99. data/SketchUp/geom.rb +231 -0
  100. data/SketchUp/languagehandler.rb +92 -0
  101. data/SketchUp/length.rb +210 -0
  102. data/SketchUp/numeric.rb +249 -0
  103. data/SketchUp/sketchup.rb +1290 -0
  104. data/SketchUp/sketchupextension.rb +355 -0
  105. data/SketchUp/string.rb +24 -0
  106. data/SketchUp/ui.rb +637 -0
  107. metadata +176 -0
@@ -0,0 +1,249 @@
1
+ # Copyright:: Copyright 2017 Trimble Inc.
2
+ # License:: The MIT License (MIT)
3
+
4
+ # A number of methods have been added to the Ruby Numeric class to do units
5
+ # conversions.
6
+ #
7
+ # @version SketchUp 6.0
8
+ class Numeric
9
+
10
+ # Instance Methods
11
+
12
+ # The cm method is used to convert from centimeters to inches.
13
+ #
14
+ # @example
15
+ # cm = 10
16
+ # inches = cm.cm
17
+ #
18
+ # @return inches - a value in inches if successful
19
+ #
20
+ # @version SketchUp 6.0
21
+ def cm
22
+ end
23
+
24
+ # The degrees method is used to convert from degrees to radians.
25
+ #
26
+ # For example 90.degrees would return 1.5707963267949
27
+ #
28
+ # @example
29
+ # degrees = 90
30
+ # radians = degrees.degrees
31
+ #
32
+ # @return radians - a value in radians if successful
33
+ #
34
+ # @version SketchUp 6.0
35
+ def degrees
36
+ end
37
+
38
+ # The feet method is used to convert from feet to inches.
39
+ #
40
+ # @example
41
+ # feet = 1
42
+ # inches = feet.feet
43
+ #
44
+ # @return inches - a value in inches if successful
45
+ #
46
+ # @version SketchUp 6.0
47
+ def feet
48
+ end
49
+
50
+ # The to_l is used to convert from a number to a length.
51
+ #
52
+ # @example
53
+ # number = 12
54
+ # length = number.to_l
55
+ #
56
+ # @return length - a Length object if successful
57
+ #
58
+ # @version SketchUp 6.0
59
+ def inch
60
+ end
61
+
62
+ # The km method is used to convert from kilometers to inches.
63
+ #
64
+ # @example
65
+ # value = 1
66
+ # inches = value.km
67
+ #
68
+ # @return inches - a value in inches if successful
69
+ #
70
+ # @version SketchUp 6.0
71
+ def km
72
+ end
73
+
74
+ # The m method is used to convert meters to inches.
75
+ #
76
+ # @example
77
+ # meters = 1
78
+ # inches = meters.m
79
+ #
80
+ # @return inches - a value in inches if successful
81
+ #
82
+ # @version SketchUp 6.0
83
+ def m
84
+ end
85
+
86
+ # The mile method is used to convert from miles to inches.
87
+ #
88
+ # @example
89
+ # miles = 1
90
+ # inches = miles.mile
91
+ #
92
+ # @return inches - a value in inches if successful
93
+ #
94
+ # @version SketchUp 6.0
95
+ def mile
96
+ end
97
+
98
+ # The mm method is used to convert a number to millimeters.
99
+ #
100
+ # It returns a Length value which is the same length as the given value. For
101
+ # example len = 25.4.mm returns 1 inch.
102
+ #
103
+ # @example
104
+ # value = 10
105
+ # mm = value.mm
106
+ #
107
+ # @return mm - a value in millimeters if successful
108
+ #
109
+ # @version SketchUp 6.0
110
+ def mm
111
+ end
112
+
113
+ # The radians method is used to convert from radians to degrees.
114
+ #
115
+ # For example, 1.5707963267949.radians would return 90.0
116
+ #
117
+ # @example
118
+ # radians = 1.5707963267949
119
+ # degrees = radians.radians
120
+ #
121
+ # @return degrees - a value in degrees if successful
122
+ #
123
+ # @version SketchUp 6.0
124
+ def radians
125
+ end
126
+
127
+ # The to_cm method is used to convert from inches to centimeters.
128
+ #
129
+ # @example
130
+ # inches = 1
131
+ # cm = inches.to_cm
132
+ #
133
+ # @return cm - a value in centimeters if successful
134
+ #
135
+ # @version SketchUp 6.0
136
+ def to_cm
137
+ end
138
+
139
+ # The to_feet method is used to convert from inches to feet.
140
+ #
141
+ # @example
142
+ # inches = 12
143
+ # feet = inches.to_feet
144
+ #
145
+ # @return feet - a value in feet if successful
146
+ #
147
+ # @version SketchUp 6.0
148
+ def to_feet
149
+ end
150
+
151
+ # The to_inch method converts from inches to inches.
152
+ #
153
+ # This does not change the value.
154
+ #
155
+ # @example
156
+ # inches = 12
157
+ # inches = inches.to_inch
158
+ #
159
+ # @return inches - a value in inches if successful
160
+ #
161
+ # @version SketchUp 6.0
162
+ def to_inch
163
+ end
164
+
165
+ # The to_km method is used to convert from inches to kilometers.
166
+ #
167
+ # @example
168
+ # inches = 1
169
+ # km = inches.to_km
170
+ #
171
+ # @return kilometers - a value in kilometers if successful
172
+ #
173
+ # @version SketchUp 6.0
174
+ def to_km
175
+ end
176
+
177
+ # The to_l is used to convert from a number to a length.
178
+ #
179
+ # @example
180
+ # number = 12
181
+ # length = number.to_l
182
+ #
183
+ # @return length - a Length object if successful
184
+ #
185
+ # @version SketchUp 6.0
186
+ def to_l
187
+ end
188
+
189
+ # The to_m method is used to convert from inches to meters.
190
+ #
191
+ # @example
192
+ # inches = 12
193
+ # meters = inches.to_m
194
+ #
195
+ # @return meters - a value in meters if successful
196
+ #
197
+ # @version SketchUp 6.0
198
+ def to_m
199
+ end
200
+
201
+ # The to_mile method is used to convert from inches to miles.
202
+ #
203
+ # @example
204
+ # inches = 10000
205
+ # miles = inches.to_mile
206
+ #
207
+ # @return miles - a value in miles if successful
208
+ #
209
+ # @version SketchUp 6.0
210
+ def to_mile
211
+ end
212
+
213
+ # The to_mm method is used to convert from inches to millimeters.
214
+ #
215
+ # @example
216
+ # inches = 1
217
+ # mm = inches.to_mm
218
+ #
219
+ # @return millimeters - a value in millimeters if successful
220
+ #
221
+ # @version SketchUp 6.0
222
+ def to_mm
223
+ end
224
+
225
+ # The to_yard method is used to convert from inches to yards.
226
+ #
227
+ # @example
228
+ # inches = 10000
229
+ # yards = inches.to_yard
230
+ #
231
+ # @return yards - a value in yards if successful
232
+ #
233
+ # @version SketchUp 6.0
234
+ def to_yard
235
+ end
236
+
237
+ # The yard method is used to convert from yards to inches.
238
+ #
239
+ # @example
240
+ # yards = 1.to_l
241
+ # inches = yards.yard
242
+ #
243
+ # @return inches - a value in inches if successful
244
+ #
245
+ # @version SketchUp 6.0
246
+ def yard
247
+ end
248
+
249
+ end
@@ -0,0 +1,1290 @@
1
+ # Copyright:: Copyright 2017 Trimble Inc.
2
+ # License:: The MIT License (MIT)
3
+
4
+ # The Sketchup module contains a number of important utility methods for use in
5
+ # your Ruby scripts. Many of the classes in the API are implemented beneath
6
+ # this module. You can think of the Sketchup module as the "root" of the
7
+ # application tree. Most ruby calls start from the currently active model, and
8
+ # this is accessed via the Sketchup.active_model method.
9
+ #
10
+ # @example
11
+ # # Grab a handle to the currently active model (aka the one the user is
12
+ # # looking at in SketchUp.)
13
+ # model = Sketchup.active_model
14
+ #
15
+ # # Grab other handles to commonly used collections inside the model.
16
+ # entities = model.entities
17
+ # layers = model.layers
18
+ # materials = model.materials
19
+ # component_definitions = model.definitions
20
+ # selection = model.selection
21
+ #
22
+ # # Now that we have our handles, we can start pulling objects and making
23
+ # # method calls that are useful.
24
+ # first_entity = entities[0]
25
+ # UI.messagebox("First thing in your model is a " + first_entity.typename)
26
+ #
27
+ # number_materials = materials.length
28
+ # UI.messagebox("Your model has " + number_materials.to_s + " materials.")
29
+ #
30
+ # new_edge = entities.add_line( [0,0,0], [500,500,0])
31
+ #
32
+ # @version SketchUp 6.0
33
+ module Sketchup
34
+
35
+ # Class Methods
36
+
37
+ # The active_model method returns the currently active SketchUp model. On the
38
+ # PC, this is the only model that one can have access to via the API, but
39
+ # Macintosh versions of SketchUp can have multiple models open at once, in
40
+ # which case the method will return the model that the user currently has
41
+ # focused.
42
+ #
43
+ # @example
44
+ # model = Sketchup.active_model
45
+ # if (! model)
46
+ # UI.messagebox "Failure"
47
+ # else
48
+ # # code acting on the model
49
+ # end
50
+ #
51
+ # @return model - active model object if successful, false if
52
+ # unsuccessful
53
+ #
54
+ # @version SketchUp 6.0
55
+ def self.active_model
56
+ end
57
+
58
+ # The add_observer method is used to add an observer to the current object.
59
+ #
60
+ # @example
61
+ # status = Sketchup.add_observer observer
62
+ #
63
+ # @param observer
64
+ # An observer.
65
+ #
66
+ # @return status - true if successful, false if unsuccessful.
67
+ #
68
+ # @version SketchUp 6.0
69
+ def self.add_observer(observer)
70
+ end
71
+
72
+ # The app_name method is used to retrieve the current application name.
73
+ #
74
+ # @example
75
+ # name = Sketchup.app_name
76
+ #
77
+ # @return name - the name of the application, either
78
+ # "SketchUp Pro" or "SketchUp".
79
+ # Note: For versions earlier than SketchUp8 M4
80
+ # (Mac 8.0.15157 and Windows 8.0.15158) this function will
81
+ # return "Google SketchUp Pro" or "Google SketchUp".
82
+ #
83
+ # @version SketchUp 6.0
84
+ def self.app_name
85
+ end
86
+
87
+ # The break_edges= method can be used to disable or enable the break edges
88
+ # feature. Break edges is the SketchUp 7 feature that automatically splits
89
+ # edges that the user draws which cross over one another.
90
+ #
91
+ # This feature is always on by default and cannot be disabled by the user
92
+ # via the user interface, but you can call this method to disable it. Be
93
+ # cautious in doing so, however, as the resulting model could then be altered
94
+ # when the user later draws lines into it with the break edges feature
95
+ # reactivated.
96
+ #
97
+ # @example
98
+ # is_on = Sketchup.break_edges?
99
+ #
100
+ # @param enabled
101
+ # If true, break edges will be turned on. If false, it
102
+ # will be deactivated.
103
+ #
104
+ # @return setting - true if break edges was turned on.
105
+ #
106
+ # @version SketchUp 7.0
107
+ def self.break_edges=(enabled)
108
+ end
109
+
110
+ # The break_edges? method indicates whether the break edges feature is
111
+ # currently turned on. Break edges is the SketchUp 7 feature that
112
+ # automatically splits edges that the user draws which cross over one another.
113
+ # This feature is always on by default and cannot be disabled by the user
114
+ # via the user interface.
115
+ #
116
+ # @example
117
+ # is_on = Sketchup.break_edges?
118
+ #
119
+ # @return break_edges - true if the feature is on.
120
+ #
121
+ # @return [Boolean]
122
+ #
123
+ # @version SketchUp 7.0
124
+ def self.break_edges?
125
+ end
126
+
127
+ # The create_texture_writer method is used to create a TextureWriter object.
128
+ #
129
+ # @example
130
+ # texturewriter = Sketchup.create_texture_writer
131
+ #
132
+ # @return texturewriter - a texturewriter object if successful.
133
+ #
134
+ # @version SketchUp 6.0
135
+ def self.create_texture_writer
136
+ end
137
+
138
+ # The debug_mode= method lets you controls whether SketchUp will output
139
+ # warnings to the console when it detects incorrect usage of the API.
140
+ # The setting takes effect right away, no need to restart SketchUp.
141
+ #
142
+ # @example
143
+ # Sketchup.debug_mode = true
144
+ #
145
+ # @param enabled
146
+ # If true, SketchUp will produce debug warnings.
147
+ #
148
+ # @return setting - true if debug mode is enabled.
149
+ #
150
+ # @version SketchUp 2016
151
+ def self.debug_mode=(enabled)
152
+ end
153
+
154
+ # The debug_mode? controls whether SketchUp will output warnings to the console
155
+ # when it detects incorrect usage of the API.
156
+ #
157
+ # @example
158
+ # debug_mode = Sketchup.debug_mode?
159
+ #
160
+ # @return debug_mode - true if debug mode is enabled
161
+ #
162
+ # @return [Boolean]
163
+ #
164
+ # @version SketchUp 2016
165
+ def self.debug_mode?
166
+ end
167
+
168
+ # The display_name_from_action method is used to gets a user-friendly name
169
+ # from an action string. See Sketchup.send_action for a list of valid
170
+ # action strings.
171
+ #
172
+ # @example
173
+ # Sketchup.display_name_from_action("viewRight:")
174
+ #
175
+ # @note This method has been non-functional on Mac since SketchUp 8.
176
+ #
177
+ # @param action_name
178
+ # An action string.
179
+ #
180
+ # @return friendly_name = a friendly name.
181
+ #
182
+ # @version SketchUp 6.0
183
+ def self.display_name_from_action(action_name)
184
+ end
185
+
186
+ # Returns the ExtensionsManager where you can find all registered
187
+ # SketchupExtension objects.
188
+ #
189
+ # @example
190
+ # extensions = Sketchup.extensions
191
+ # for extension in extensions
192
+ # UI.messagebox('The next extension is named: ' + extension.name +
193
+ # ' and its loaded? state is: ' + extension.loaded?)
194
+ # end
195
+ #
196
+ # @return extensionsmanager - an ExtensionsManager object.
197
+ #
198
+ # @version SketchUp 8.0 M2
199
+ def self.extensions
200
+ end
201
+
202
+ # The file_new method is used to create a new file.
203
+ #
204
+ # @example
205
+ # new_sketchup = Sketchup.file_new
206
+ #
207
+ # @return Sketchup - a Sketchup object if successful.
208
+ #
209
+ # @version SketchUp 6.0
210
+ def self.file_new
211
+ end
212
+
213
+ # The find_support_files method is used to retrieve the relative path and name
214
+ # of a file within the SketchUp installation directory.
215
+ #
216
+ # Forward slashes must be used to delimit between directory names.
217
+ #
218
+ # @example
219
+ # help_file = Sketchup.find_support_file "help.html", "Plugins/"
220
+ # if (help_file)
221
+ # # Print out the help_file full path
222
+ # UI.messagebox help_file
223
+ #
224
+ # # Open the help_file in a web browser
225
+ # UI.openURL "file://" + help_file
226
+ # else
227
+ # UI.messagebox "Failure"
228
+ # end
229
+ #
230
+ # @param filename
231
+ # Name of the filename you want to find.
232
+ #
233
+ # @param directory
234
+ # directory relative to the SketchUp
235
+ # installation directory.
236
+ #
237
+ # @return path - the entire path if successful. If unsuccessful,
238
+ # the method returns false.
239
+ #
240
+ # @version SketchUp 6.0
241
+ def self.find_support_file(filename, directory = '')
242
+ end
243
+
244
+ # The find_support_files method is used to retrieve the path and name of all
245
+ # matching files within the SketchUp installation directory.
246
+ #
247
+ # Forward slashes must be used to delimit between directory names.
248
+ #
249
+ # @example
250
+ # files = Sketchup.find_support_files('rb', 'Plugins')
251
+ #
252
+ # @param filename
253
+ # Extension of the files to be found.
254
+ #
255
+ # @param directory
256
+ # directory relative to the SketchUp installation
257
+ # directory. Without this the result will
258
+ # be empty.
259
+ #
260
+ # @return array - an array of files. If unsuccessful, the method
261
+ # returns false.
262
+ #
263
+ # @version SketchUp 6.0
264
+ def self.find_support_files(filename, directory)
265
+ end
266
+
267
+ # The fix_shadow_strings= method lets you control whether shadow rendering
268
+ # attempts to fix an artifact commonly referred to as "strings". The fix
269
+ # is actually very model dependent and not controllable from the UI, so this
270
+ # method can be used to control it.
271
+ #
272
+ # @example
273
+ # Sketchup.fix_shadow_strings=true
274
+ #
275
+ # @param enabled
276
+ # If true, shadow strings fix will be turned on. If
277
+ # false, it will be deactivated.
278
+ #
279
+ # @return setting - true if shadow strings fix was turned on.
280
+ #
281
+ # @version SketchUp 8.0 M1
282
+ def self.fix_shadow_strings=(enabled)
283
+ end
284
+
285
+ # The fix_shadow_strings? method indicates whether the a fix for a shadow
286
+ # rendering artifact commonly referred to as "strings" is enabled. The fix
287
+ # is actually very model dependent and not controllable from the UI, so this
288
+ # method can be used to test it.
289
+ #
290
+ # @example
291
+ # is_on = Sketchup.fix_shadow_strings?
292
+ #
293
+ # @return fix_shadow_strings - true if the feature is on.
294
+ #
295
+ # @return [Boolean]
296
+ #
297
+ # @version SketchUp 8.0 M1
298
+ def self.fix_shadow_strings?
299
+ end
300
+
301
+ # The format_angle method takes a number as an angle in radians and formats it
302
+ # into degrees. For example, format_angle(Math::PI) will return 180.0.
303
+ #
304
+ # @example
305
+ # degrees = Sketchup.format_angle Math::PI
306
+ #
307
+ # @param number
308
+ # A number to be formatted.
309
+ #
310
+ # @return degrees - an angle in degrees if successful, false if
311
+ # unsuccessful
312
+ #
313
+ # @version SketchUp 6.0
314
+ def self.format_angle(number)
315
+ end
316
+
317
+ # The format_area method formats a number as an area using the current units
318
+ # settings.
319
+ #
320
+ # The default unit setting is inches. For example, 10 becomes 10 inches
321
+ # squared.
322
+ #
323
+ # @example
324
+ # area = Sketchup.format_area number
325
+ #
326
+ # @param number
327
+ # A number to be formatted.
328
+ #
329
+ # @return area - an area if successful, false if unsuccessful.
330
+ #
331
+ # @version SketchUp 6.0
332
+ def self.format_area(number)
333
+ end
334
+
335
+ # The format_degrees method formats a number as an angle given in degrees. For
336
+ # example, 10 becomes 10.0. This is the equivalent to a to_f call.
337
+ #
338
+ # @example
339
+ # degrees = Sketchup.format_degrees number
340
+ #
341
+ # @param number
342
+ # A number to be formatted.
343
+ #
344
+ # @return degrees - degrees if successful, false if unsuccessful.
345
+ #
346
+ # @version SketchUp 6.0
347
+ def self.format_degrees(number)
348
+ end
349
+
350
+ # The format_length method formats a number as a length using the current
351
+ # units settings.
352
+ #
353
+ # The default unit setting is inches. For example, 10 becomes 10".
354
+ #
355
+ # @example
356
+ # length = Sketchup.format_length 10
357
+ # if (length)
358
+ # UI.messagebox length
359
+ # end
360
+ #
361
+ # @param number
362
+ # A number to be formatted.
363
+ #
364
+ # @return length - length if successful, false if unsuccessful
365
+ #
366
+ # @version SketchUp 6.0
367
+ def self.format_length(number)
368
+ end
369
+
370
+ # The get_datfile_info method is used to retrieve the value for the given key
371
+ # from Sketchup.dat.
372
+ #
373
+ # If the key is not found, default_value is returned.
374
+ #
375
+ # @example
376
+ # value = Sketchup.get_datfile_info(key, default_value)
377
+ #
378
+ # @param key
379
+ # The key whose value you want to retrieve.
380
+ #
381
+ # @param default_value
382
+ # The default value you want returned if key is not
383
+ # available.
384
+ #
385
+ # @return value - a string value if successful.
386
+ #
387
+ # @version SketchUp 6.0
388
+ def self.get_datfile_info(key, default_value)
389
+ end
390
+
391
+ # The get_i18ndatfile_info method is used to retrieve the value for the
392
+ # given key from the internationalization file that SketchUp uses to work
393
+ # in multiple languages.
394
+ #
395
+ # If the key is not found, default_value is returned.
396
+ #
397
+ # @example
398
+ # value = Sketchup.get_i18ndatfile_info(key, default_value)
399
+ #
400
+ # @param key
401
+ # The key whose value you want to retrieve.
402
+ #
403
+ # @param default_value
404
+ # The default value you want returned if key is not
405
+ # available.
406
+ #
407
+ # @return value - a string value if successful.
408
+ #
409
+ # @version SketchUp 6.0
410
+ def self.get_i18n_datfile_info(key, default_value)
411
+ end
412
+
413
+ # The os_language method returns the language code for the language SketchUp
414
+ # is running in. This is an alias for the get_locale method.
415
+ #
416
+ # Valid return values are: en-US, fr, it, de, es, ja, ko, zh-CN, zh-TW,
417
+ # pt-BR, nl, ru.
418
+ # If the OS language does not have corresponding folder and files in the
419
+ # SketchUp Resources folder, the returned language is, by default, en-US.
420
+ #
421
+ # @example
422
+ # language = Sketchup.os_language
423
+ #
424
+ # @return language - a code representing the language SketchUp
425
+ # is displaying.
426
+ #
427
+ # @version SketchUp 6.0
428
+ def self.get_locale
429
+ end
430
+
431
+ # The get_resource_path is used to retrieve the directory where "resource"
432
+ # files are stored by SketchUp. Resource files include things like language
433
+ # localization files.
434
+ #
435
+ # @example
436
+ # directory = Sketchup.get_resource_path "Styles.strings"
437
+ #
438
+ # @param filename
439
+ # The filename of a resource file in the resource
440
+ # directory hierarchy.
441
+ #
442
+ # @return path - the directory path to the resources folder.
443
+ #
444
+ # @version SketchUp 6.0
445
+ def self.get_resource_path(filename)
446
+ end
447
+
448
+ # The get_shortcuts method retrieves an array of all keyboard shortcuts
449
+ # currently registered with SketchUp. Each shortcut is returned as a
450
+ # string with the shortcut and the command separated by a tab, similar
451
+ # to "Ctrl+A\tEdit/Select All"
452
+ #
453
+ # @example
454
+ # shortcuts = Sketchup.get_shortcuts
455
+ #
456
+ # @return shortcuts - an array of shortcut strings.
457
+ #
458
+ # @version SketchUp 6.0
459
+ def self.get_shortcuts
460
+ end
461
+
462
+ # Installs the contents of a ZIP archive file into SketchUp's Plugins folder.
463
+ # If the ZIP contains subfolders, these will be preserved. This allows for a
464
+ # Ruby API plugin or Extension developer to distribute their plugin as a single
465
+ # file regardless of how many asset files must be included.
466
+ #
467
+ # The user will be shown a warning message that they must agree to before the
468
+ # install proceeds. If they do not agree, an Interrupt error will be raised.
469
+ # If the user does agree but there is a problem with the unzip process, an
470
+ # Exception will be raised. You can capture these states via a begin/rescue.
471
+ # See the example below.
472
+ #
473
+ # If the install is successful, any Ruby files that have been added to
474
+ # the Plugins folder will immediately be executed, saving the user a restart.
475
+ #
476
+ # To create an archive file, use your favorite tool (7zip, Winzip, etc.) to zip
477
+ # up any files and folders in your plugins directory. If the archive contains a
478
+ # SketchupExtension that you would like users to be able to install from the
479
+ # Preferences > Extensions panel, rename your file to have a .rbz file
480
+ # extension.
481
+ #
482
+ # @example
483
+ # path = 'c:/temp/SomePluginPackage.zip'
484
+ # begin
485
+ # Sketchup.install_from_archive(path)
486
+ # rescue Interrupt => error
487
+ # UI.messagebox "User said 'no': " + error
488
+ # rescue Exception => error
489
+ # UI.messagebox "Error during unzip: " + error
490
+ # end
491
+ #
492
+ # @param [String] filename
493
+ # The path to the RBZ or ZIP file to install.
494
+ #
495
+ # @raise [Exception] If the archive cannot be found.
496
+ #
497
+ # @raise [Interrupt] If the user cancel the installation.
498
+ #
499
+ # @raise [Exception] If the archive cannot be installed.
500
+ #
501
+ # @return [Boolean] .
502
+ #
503
+ # @version SketchUp 8.0 M2
504
+ def self.install_from_archive(filename)
505
+ end
506
+
507
+ # This methods indicates whether the host SketchUp application is 64bit.
508
+ # Useful for extensions that ship with binaries and need to determine
509
+ # which versions to load.
510
+ #
511
+ # @example
512
+ # # For backward compatibility, check for the existence of the method
513
+ # # and load 32bit binaries for SketchUp versions that do not have this
514
+ # # method.
515
+ # if Sketchup.respond_to?(:is_64bit?) && Sketchup.is_64bit?
516
+ # # Load 64bit binaries.
517
+ # else
518
+ # # Load 32bit binaries.
519
+ # end
520
+ #
521
+ # @return Boolean - True if SketchUp is 64bit.
522
+ #
523
+ # @return [Boolean]
524
+ #
525
+ # @version SketchUp 2015
526
+ def self.is_64bit?
527
+ end
528
+
529
+ # The is_online method is used to verify a connection to the Internet. This
530
+ # method can take some time to execute, so be careful not to call it more often
531
+ # than you need.
532
+ #
533
+ # @example
534
+ # status = Sketchup.is_online
535
+ #
536
+ # @return status - true if successful, false if unsuccessful.
537
+ #
538
+ # @version SketchUp 6.0
539
+ def self.is_online
540
+ end
541
+
542
+ # Returns a boolean flag indicating whether the application is SketchUp Pro.
543
+ # Note that after the free trial period, SketchUp Pro will revert to regular
544
+ # SketchUp and this method will return false until the user registers
545
+ # the product.
546
+ #
547
+ # @example
548
+ # if (Sketchup.is_pro?)
549
+ # UI.messagebox "You are running SU Pro."
550
+ # end
551
+ #
552
+ # @return is_pro - true if the user is using SketchUp Pro
553
+ #
554
+ # @return [Boolean]
555
+ #
556
+ # @version SketchUp 7.0
557
+ def self.is_pro?
558
+ end
559
+
560
+ # The is_valid_filename? method is used to determine whether a filename
561
+ # contains illegal characters.
562
+ #
563
+ # @example
564
+ # status = Sketchup.is_valid_filename? filename
565
+ #
566
+ # @param filename
567
+ # A filename string.
568
+ #
569
+ # @return status - true if filename is valid, false if filename
570
+ # is invalid (contains illegal characters).
571
+ #
572
+ # @return [Boolean]
573
+ #
574
+ # @version SketchUp 6.0
575
+ def self.is_valid_filename?(filename)
576
+ end
577
+
578
+ # The load method is used to include encrypted and nonencrypted ruby files.
579
+ #
580
+ # You do not need to include the file extension on the path. This method will
581
+ # look for .rb first (unencrypted) and then .rbe (encrypted) and finally .rbs
582
+ # (the deprecated scrambled format) files.
583
+ # See the "Distributing your Plugin" article for details.
584
+ #
585
+ # @example
586
+ # sfile = "application_loader" # file extension not required
587
+ # status = Sketchup.load(sfile)
588
+ #
589
+ # @param path
590
+ # The path, including the filename, to the file you want
591
+ # to require.
592
+ #
593
+ # @return status - True if the file is included. False if the
594
+ # file is not included.
595
+ #
596
+ # @version SketchUp 6.0
597
+ def self.load(path)
598
+ end
599
+
600
+ # The open_file method is used to open a file.
601
+ #
602
+ # @example
603
+ # result = Sketchup.open_file "C:\\model.skp"
604
+ #
605
+ # @param filename
606
+ # The path and filename to open.
607
+ #
608
+ # @return result - true if opening the file succeeded,
609
+ # false otherwise.
610
+ #
611
+ # @version SketchUp 6.0
612
+ def self.open_file(filename)
613
+ end
614
+
615
+ # The os_language method returns the language code for the language SketchUp
616
+ # is running in. This is an alias for the get_locale method.
617
+ #
618
+ # Valid return values are: en-US, fr, it, de, es, ja, ko, zh-CN, zh-TW,
619
+ # pt-BR, nl, ru.
620
+ # If the OS language does not have corresponding folder and files in the
621
+ # SketchUp Resources folder, the returned language is, by default, en-US.
622
+ #
623
+ # @example
624
+ # language = Sketchup.os_language
625
+ #
626
+ # @return language - a code representing the language SketchUp
627
+ # is displaying.
628
+ #
629
+ # @version SketchUp 6.0
630
+ def self.os_language
631
+ end
632
+
633
+ # The parse_length method parses a string as a length.
634
+ #
635
+ # For example, "200" becomes 200.0.
636
+ #
637
+ # @example
638
+ # float = Sketchup.parse_length("2'") # Returns 24 (representing inches)
639
+ # length = float.to_l # Convert to a Length type if needed.
640
+ #
641
+ # @param string
642
+ # The string to be parsed as a number.
643
+ #
644
+ # @return float - the numerical representation of the string if
645
+ # successful, or nil if unsuccessful.
646
+ #
647
+ # @version SketchUp 6.0
648
+ def self.parse_length(string)
649
+ end
650
+
651
+ # This methods returns a symbol indicating the current platform.
652
+ #
653
+ # It should be used over RUBY_PLATFORM as this returns a different value for
654
+ # Windows since SketchUp 2014.
655
+ #
656
+ # Older SketchUp versions still need to check
657
+ # <code>RUBY_PLATFORM.include?('mswin')</code> or
658
+ # <code>RUBY_PLATFORM.include?('darwin')</code>.
659
+ #
660
+ # Possible return values:
661
+ # - :platform_win
662
+ # - :platform_osx
663
+ #
664
+ # @example
665
+ # module MyExtension
666
+ # IS_WIN = Sketchup.platform == :platform_win
667
+ # IS_OSX = Sketchup.platform == :platform_osx
668
+ # end
669
+ #
670
+ # @return symbol - Current OS platform.
671
+ #
672
+ # @version SketchUp 2014
673
+ def self.platform
674
+ end
675
+
676
+ # The plugins_disabled= method lets you control whether SketchUp will load
677
+ # Ruby scripts from the plugins directory at startup time. This is primarily
678
+ # a trouble-shooting method. If you are having strange behavior in SketchUp
679
+ # that you suspect is from a bad script, you can type
680
+ # Sketchup.plugins_disabled=true into the Ruby console and restart SketchUp
681
+ # to see if the problem is fixed.
682
+ #
683
+ # @example
684
+ # # Type this in the Ruby console then restart SketchUp.
685
+ # Sketchup.plugins_disabled=true
686
+ #
687
+ # # To reactivate plugins, type this into the Ruby console and restart.
688
+ # Sketchup.plugins_disabled=false
689
+ #
690
+ # @param enabled
691
+ # If true, the plugins directory will not load.
692
+ #
693
+ # @return setting - true if plugins were disabled.
694
+ #
695
+ # @version SketchUp 8.0 M2
696
+ def self.plugins_disabled=(enabled)
697
+ end
698
+
699
+ # The plugins_disabled? method indicates whether Ruby scripts in the plugins
700
+ # directory will be loaded at startup time.
701
+ #
702
+ # @example
703
+ # is_disabled = Sketchup.plugins_disabled?
704
+ #
705
+ # @return plugins_disabled - true if the plugins are disabled.
706
+ #
707
+ # @return [Boolean]
708
+ #
709
+ # @version SketchUp 8.0 M2
710
+ def self.plugins_disabled?
711
+ end
712
+
713
+ # The quit method is used to terminate the application. This will pop-up the
714
+ # usual model save prompts if there are unsaved models open. User can cancel
715
+ # the model save, in which case the application will not terminate.
716
+ #
717
+ # @example
718
+ # Sketchup.quit
719
+ # # Do not expect code to execute reliably after this point.
720
+ #
721
+ # @return self
722
+ #
723
+ # @version SketchUp 2014
724
+ def self.quit
725
+ end
726
+
727
+ # The read_default method is used to retrieve the string associated with a
728
+ # value within the specified sub-section section of a .INI file or registry
729
+ # (within the Software > SketchUp > SketchUp [Version] section).
730
+ #
731
+ # @example
732
+ # result = Sketchup.read_default "section",
733
+ # "variable", "default"
734
+ #
735
+ # @param section
736
+ # A section in an .INI or registry.
737
+ #
738
+ # @param variable
739
+ # A variable within the section.
740
+ #
741
+ # @param default
742
+ # A default value if the value is not found.
743
+ #
744
+ # @return result - nil if unsuccessful, the value of the default
745
+ # if successful.
746
+ #
747
+ # @version SketchUp 6.0
748
+ def self.read_default(section, variable, default = nil)
749
+ end
750
+
751
+ # The register_extension method is used to register an extension with
752
+ # SketchUp's extension manager (in SketchUp preferences).
753
+ #
754
+ # @example
755
+ # utilitiesExtension = SketchupExtension.new "Utilities Tools",
756
+ # "Utilities/utilitiesTools.rb"
757
+ #
758
+ # utilitiesExtension.description = "Adds Tools->Utilities to the " +
759
+ # "SketchUp inteface. The Utilities submenu contains two tools: " +
760
+ # "Create Face and Query Tool."
761
+ #
762
+ # Sketchup.register_extension utilitiesExtension, false
763
+ #
764
+ # @note It is recommended to set +load_on_start+ to true unless you have a very
765
+ # good reason not to.
766
+ #
767
+ # @param [Boolean] load_on_start
768
+ # Passing true into this will load the
769
+ # extension immediately and set it so
770
+ # that it will load automatically
771
+ # whenever SketchUp restarts.
772
+ #
773
+ # @param [SketchupExtension] extension
774
+ # A SketchupExtension object.
775
+ #
776
+ # @return [Boolean] +true+ if extension registered properly
777
+ #
778
+ # @version SketchUp 6.0
779
+ def self.register_extension(extension, load_on_start = false)
780
+ end
781
+
782
+ # The register_importer method is used to register an importer with SketchUp.
783
+ #
784
+ # @example
785
+ # status = Sketchup.register_importer importer
786
+ #
787
+ # @param importer
788
+ # An Importer object representing the importer.
789
+ #
790
+ # @return status - true if successful, false if unsuccessful.
791
+ #
792
+ # @version SketchUp 6.0
793
+ def self.register_importer(importer)
794
+ end
795
+
796
+ # The remove_observer method is used to remove an observer from the current
797
+ # object.
798
+ #
799
+ # @example
800
+ # status = Sketchup.remove_observer observer
801
+ #
802
+ # @param observer
803
+ # An observer.
804
+ #
805
+ # @return true if successful, false if unsuccessful.
806
+ #
807
+ # @version SketchUp 6.0
808
+ def self.remove_observer(observer)
809
+ end
810
+
811
+ # The require method is used to include encrypted and nonencrypted ruby files.
812
+ # This is an alias of the Sketchup.load method.
813
+ #
814
+ # You do not need to include the file extension on the path. This method will
815
+ # look for .rbe first (encrypted) and then .rbs (the deprecated scrambled
816
+ # format) and finally .rb (unencrypted) files. The loading order was changed
817
+ # in SketchUp 2016 when the new .rbe encryption was introduced. Prior to
818
+ # SketchUp 2016 the loading order was first .rb then .rbs.
819
+ #
820
+ # @example
821
+ # sfile = "application_loader" # file extension not required
822
+ # status = Sketchup::require(sfile)
823
+ #
824
+ # @param path
825
+ # The path, including the filename, to the file you want
826
+ # to require.
827
+ #
828
+ # @return status - True if the file is included. False if the
829
+ # file is not included.
830
+ #
831
+ # @version SketchUp 6.0
832
+ def self.require(path)
833
+ end
834
+
835
+ # The save_thumbnail method is used to generate a thumbnail for any SKP file -
836
+ # not necessarily the loaded model.
837
+ #
838
+ # @example
839
+ # status = Sketchup.save_thumbnail "skp_filename", "image_filename"
840
+ #
841
+ # @param skp_filename
842
+ # The name of the SketchUp file whose model you want
843
+ # represented in the thumbnail.
844
+ #
845
+ # @param img_filename
846
+ # The name of the file where the thumbnail will be saved.
847
+ #
848
+ # @return status - true if successful, false if unsuccessful.
849
+ #
850
+ # @version SketchUp 6.0
851
+ def self.save_thumbnail(skp_filename, img_filename)
852
+ end
853
+
854
+ # The send_action method sends a message to the message queue to perform some
855
+ # action asynchronously.
856
+ #
857
+ # Valid actions are:
858
+ # - showRubyPanel:
859
+ # - viewBack:
860
+ # - viewBottom:
861
+ # - viewFront:
862
+ # - viewIso:
863
+ # - viewLeft:
864
+ # - viewRight:
865
+ # - viewTop:
866
+ # - viewPerspective:
867
+ # - viewShowAxes:
868
+ # - viewShowHidden:
869
+ # - viewZoomExtents:
870
+ # - viewZoomToSelection:
871
+ # - viewUndo:
872
+ # - selectOrbitTool:
873
+ # - selectPositionCameraTool:
874
+ # - selectDollyTool:
875
+ # - selectTurnTool:
876
+ # - selectWalkTool:
877
+ # - selectZoomTool:
878
+ # - selectFieldOfViewTool:
879
+ # - selectZoomWindowTool:
880
+ # - pageAdd:
881
+ # - pageDelete:
882
+ # - pageUpdate:
883
+ # - pageNext:
884
+ # - pagePrevious:
885
+ # - renderWireframe:
886
+ # - renderHiddenLine:
887
+ # - renderMonochrome:
888
+ # - renderShaded:
889
+ # - renderTextures:
890
+ # - selectArcTool:
891
+ # - selectArc3PointTool:
892
+ # - selectArc3PointPieTool:
893
+ # - selectAxisTool:
894
+ # - selectCircleTool:
895
+ # - selectEraseTool:
896
+ # - selectFreehandTool:
897
+ # - selectLineTool:
898
+ # - selectMeasureTool:
899
+ # - selectMoveTool:
900
+ # - selectOffsetTool:
901
+ # - selectPaintTool:
902
+ # - selectPolygonTool:
903
+ # - selectProtractorTool:
904
+ # - selectPushPullTool:
905
+ # - selectRectangleTool:
906
+ # - selectRectangle3PointTool:
907
+ # - selectRotateTool:
908
+ # - selectScaleTool:
909
+ # - selectSectionPlaneTool:
910
+ # - selectTextTool:
911
+ # - selectDimensionTool:
912
+ # - selectExtrudeTool:
913
+ # - selectSelectionTool:
914
+ # - editUndo:
915
+ # - editRedo:
916
+ # - editHide:
917
+ # - editUnhide:
918
+ # - fixNonPlanarFaces:
919
+ #
920
+ # Added in SketchUp 8.0+:
921
+ # - addBuilding:
922
+ # - getPhotoTexture:
923
+ # - selectImageIglooTool:
924
+ # - selectNorthTool:
925
+ #
926
+ # Added in SketchUp 2013+:
927
+ # - showExtensionStore:
928
+ #
929
+ # Removed in SketchUp 2013+:
930
+ # - addBuilding:
931
+ #
932
+ # On the PC only, you can also send these numeric values. (Note that these are
933
+ # officially "unsupported" and are not guaranteed to work in current or
934
+ # future versions of the API.)
935
+ #
936
+ # - 10501: set view to Top
937
+ # - 10502: set view to Front
938
+ # - 10503: set view to Rear
939
+ # - 10504: set view to Left
940
+ # - 10505: set view to Right
941
+ # - 10506: set view to Bottom
942
+ # - 10507: set view to Axonometric
943
+ # - 10510: set render mode to Wire
944
+ # - 10511: set render mode to Hidden lines removal
945
+ # - 10512: set render mode to Surfaces Shading
946
+ # - 10513: set render mode to Transparency
947
+ # - 10519: set camera to ortho (removes perspective)
948
+ # - 10520: walk tool
949
+ # - 10521: display the System Preferences dialog box (Files tab)
950
+ # - 10522: removes axes display
951
+ # - 10523: pan tool
952
+ # - 10525: set the interactive eye height feature
953
+ # - 10526: zoom window
954
+ # - 10527: zoom extents
955
+ # - 10529: zoom out 2
956
+ # - 10531: toggle the Standard toolbar
957
+ # - 10532: toggle the Camera toolbar
958
+ # - 10533: display the Shadows Settings dialog box
959
+ # - 10537: toggle the Views toolbar
960
+ # - 10538: display the System Preferences dialog box (Display tab)
961
+ # - 10545: toggle Color ByLayer
962
+ # - 10546: toggle Shadows toolbar
963
+ # - 10551: toogle Large icons
964
+ # - 10576: toggle Render Mode toolbar
965
+ # - 10596: set Render Mode to No Transparency (Preferences)
966
+ # - 10597: set Render Mode to Wire (Preferences)
967
+ # - 10598: set Render Mode to Transparency (Preferences)
968
+ # - 10599: set Render Mode to Surfaces Shading (Preferences)
969
+ # - 10600: set Render Mode to Texture (Preferences)
970
+ # - 10601: set Render Mode to No Texture (Preferences)
971
+ # - 10602: toggle Shadows
972
+ # - 10603: toggle Profiles
973
+ # - 10604: toggle Extension Lines
974
+ # - 10605: toggle Jitter edges
975
+ # - 21019: hide Status bar and VCB
976
+ # - 21020: show Status bar and VCB
977
+ # - 21022: hide Status bar and VCB
978
+ # - 21023: place 3d text box
979
+ # - 21024: select the Measure tool
980
+ # - 21031: select the Freehand Draw tool
981
+ # - 21041: select the PushPull tool
982
+ # - 21048: select the Move tool
983
+ # - 21052: hide selected objects
984
+ # - 21056: create face with selected edges closed loop
985
+ # - 21057: select the Protractor tool
986
+ # - 21060: display Components Window
987
+ # - 21061: toggle Draw toolbar
988
+ # - 21063: toggle Model Bounding Box display
989
+ # - 21065: select the Arc tool
990
+ # - 21067: creat a new Page
991
+ # - 21069: select the Arc 3 Point tool
992
+ # - 21070: select the Arc 3 Point Pie tool
993
+ # - 21074: show the Materials Browser Window
994
+ # - 21076: display the Preferences dialog box (Text activated)
995
+ # - 21077: display the Tip of the day Window
996
+ # - 21078: select the Paint Bucket tool
997
+ # - 21080: display the Page Manager Window
998
+ # - 21082: display the Macros Dialog Box
999
+ # - 21086: display the Components Browser Window
1000
+ # - 21094: select the Rectangle tool
1001
+ # - 21095: select the Polygon tool
1002
+ # - 21096: select the Circle tool
1003
+ # - 21098: open the Open Window
1004
+ # - 21100: select the Offset tool
1005
+ # - 21101: slect all objects
1006
+ # - 21112: open the Import Window
1007
+ # - 21124: launch the validity check tool
1008
+ # - 21126: select the Axes tool
1009
+ # - 21029: select the Rotate tool
1010
+ # - 21032: toggle Layer toolbar
1011
+ # - 21036: display the Save as Window
1012
+ # - 21046: spin the model a full 360&deg; and display report
1013
+ # - 21047: fast Pick Time report
1014
+ # - 21049: open the Export model Window
1015
+ # - 21169: select the Position Camera tool
1016
+ # - 21170: display the Preferences, Tour Guide activated
1017
+ # - 21180: create a new Page just right of selected page
1018
+ # - 21200: display the Insert Image Window
1019
+ # - 21233: display Area of selected face
1020
+ # - 21234: display Area of all faces with selected material
1021
+ # - 21236: select the Scale tool
1022
+ # - 21237: display the Export 2D Graphics Window
1023
+ # - 21245: display a Polygon Offset Factors dialog box
1024
+ # - 21276: reverse selected face(s)
1025
+ # - 21287: select the Divide feature
1026
+ # - 21337: select the Section Plane Placement tool
1027
+ # - 21354: open the Layer Window
1028
+ # - 21386: open the Export Animation Window
1029
+ # - 21405: select the Text tool
1030
+ # - 21406: display Fog dialog box
1031
+ # - 21410: select the Dim tool
1032
+ # - 21433: toggle Edit toolbar
1033
+ # - 21442: select the FollowMe tool
1034
+ # - 21448: select the Axes tool
1035
+ # - 21453: select all objects
1036
+ # - 21460: display Licence
1037
+ # - 21462: display Authorization dialog box
1038
+ # - 21463: display un-authorizing message
1039
+ # - 21464: display Open Licence files (Network) Window
1040
+ # - 21466: display Quick reference Card in Adobe Reader
1041
+ # - 21467: display Licences in use dialog box
1042
+ # - 21469: zoom extents to selected objects
1043
+ # - 21476: perform a non-planar check on selected objects
1044
+ # - 21477: list accelerators in window
1045
+ # - 21485: erase selected objects
1046
+ # - 21487: display Edit current material dialog box
1047
+ # - 21485: erase all new created pages
1048
+ # - 21488: display Entity Info Window
1049
+ # - 21490: display Soften Edges Window
1050
+ # - 21491: display Profiles
1051
+ # - 21492: display Extended Edges
1052
+ # - 21493: display Jitter Lines
1053
+ # - 21494: select Field of view tool
1054
+ # - 21513: display the outliner
1055
+ # - 21520: override Tile Rendering Size dialog box
1056
+ # - 21525: select the FollowMe tool
1057
+ # - 21542: display the Insert Image Window
1058
+ # - 21560 and up: causes a runtime Error
1059
+ #
1060
+ # @example
1061
+ # result = Sketchup.send_action "selectArcTool:"
1062
+ #
1063
+ # @param [String, Integer] action
1064
+ # The action to be performed.
1065
+ #
1066
+ # @return [boolean] +true+ if successful, +false+ if unsuccessful
1067
+ #
1068
+ # @version SketchUp 6.0
1069
+ def self.send_action(action)
1070
+ end
1071
+
1072
+ # The set_status_text method is used to
1073
+ # set the text appearing on the status bar within the drawing window.
1074
+ #
1075
+ # If no arguments are passed, the status bar content is cleared. Valid
1076
+ # positions are:
1077
+ #
1078
+ # - +SB_PROMPT+ - the text will appear at the left-side of the status bar
1079
+ # - +SB_VCB_LABEL+ - the text will appear in place of the VCB label
1080
+ # - +SB_VCB_VALUE+ - the text will appear in the VCB
1081
+ #
1082
+ # @example
1083
+ # result = Sketchup.set_status_text "This is a Test", SB_VCB_VALUE
1084
+ # if (result)
1085
+ # #code to do something if set_status_text is successful
1086
+ # end
1087
+ #
1088
+ # @overload set_status_text
1089
+ #
1090
+ # Clears all status panes.
1091
+ # @return [nil]
1092
+ #
1093
+ # @overload set_status_text(status_text = '', position = SB_PROMPT)
1094
+ #
1095
+ # @param status text the status text that will appear.
1096
+ # @param position the position where the text will appear.
1097
+ # @return [nil]
1098
+ #
1099
+ # @version SketchUp 6.0
1100
+ def self.set_status_text(*args)
1101
+ end
1102
+
1103
+ # The status_text= method is used to set the text appearing on the status
1104
+ # bar within the drawing window.
1105
+ #
1106
+ # This is the same as calling set_status_text with a 2nd parameter of
1107
+ # SB_PROMPT.
1108
+ #
1109
+ # @example
1110
+ # result = Sketchup.status_text = "This is a Test"
1111
+ #
1112
+ # @param status_text
1113
+ # The status text that will appear.
1114
+ #
1115
+ # @return result - true if successful, false if unsuccessful.
1116
+ #
1117
+ # @version SketchUp 6.0
1118
+ def self.status_text=(status_text)
1119
+ end
1120
+
1121
+ # The temp_dir method is used to retrieve the OS temporary directory for the
1122
+ # current user. You can use this directory to write temporary files that are
1123
+ # not required to persist between SketchUp sessions.
1124
+ #
1125
+ # @example
1126
+ # temp_dir = Sketchup.temp_dir
1127
+ #
1128
+ # @return String containing the full temporary directory path
1129
+ #
1130
+ # @version SketchUp 2014
1131
+ def self.temp_dir
1132
+ end
1133
+
1134
+ # The template method is used to get the file name of the current template.
1135
+ # Templates are the .skp files that are loaded when the user select File > New.
1136
+ #
1137
+ # @example
1138
+ # name = Sketchup.template
1139
+ #
1140
+ # @return name - the current template
1141
+ #
1142
+ # @version SketchUp 6.0
1143
+ def self.template
1144
+ end
1145
+
1146
+ # The template= method is used to set the file name of the current template.
1147
+ # Templates are the .skp files that are loaded when the user select File > New.
1148
+ #
1149
+ # @example
1150
+ # status = Sketchup.template= "filename"
1151
+ #
1152
+ # @param filename
1153
+ # The name of the template to set.
1154
+ #
1155
+ # @return status - true if successful, false if unsuccessful.
1156
+ #
1157
+ # @version SketchUp 6.0
1158
+ def self.template=(filename)
1159
+ end
1160
+
1161
+ # The template_dir is used to retrieve the directory where templates are
1162
+ # stored by the SketchUp install. Templates are the .skp files that are loaded
1163
+ # when the user select File > New.
1164
+ #
1165
+ # @example
1166
+ # directory = Sketchup.template_dir
1167
+ #
1168
+ # @return String containing the full template directory path
1169
+ #
1170
+ # @version SketchUp 6.0
1171
+ def self.template_dir
1172
+ end
1173
+
1174
+ # The undo method is used undo the last transaction on the undo stack.
1175
+ #
1176
+ # @example
1177
+ # Sketchup.undo
1178
+ #
1179
+ # @return nil
1180
+ #
1181
+ # @version SketchUp 6.0
1182
+ def self.undo
1183
+ end
1184
+
1185
+ # The vcb_label= method is used to set the label that appears on the vcb,
1186
+ # or the "value control box", which is another word for the "measurements"
1187
+ # text entry box that appears at the bottom on the SketchUp window.
1188
+ #
1189
+ # This is the same as calling set_status_text with a 2nd parameter of
1190
+ # SB_VCB_LABEL.
1191
+ #
1192
+ # @example
1193
+ # result = Sketchup.vcb_label = "This is a Test"
1194
+ #
1195
+ # @param label_text
1196
+ # The label text that will appear.
1197
+ #
1198
+ # @return result - true if successful, false if unsuccessful.
1199
+ #
1200
+ # @version SketchUp 6.0
1201
+ def self.vcb_label=(label_text)
1202
+ end
1203
+
1204
+ # The vcb_value= method is used to set the value that appears on the vcb,
1205
+ # or the "value control box", which is another word for the "measurements"
1206
+ # text entry box that appears at the bottom on the SketchUp window.
1207
+ #
1208
+ # This is the same as calling set_status_text with a 2nd parameter of
1209
+ # SB_VCB_VALUE.
1210
+ #
1211
+ # @example
1212
+ # result = Sketchup.vcb_value = "This is a Test"
1213
+ #
1214
+ # @param value
1215
+ # The text that will appear as the vcb's value.
1216
+ #
1217
+ # @return result - true if successful, false if unsuccessful.
1218
+ #
1219
+ # @version SketchUp 6.0
1220
+ def self.vcb_value=(value)
1221
+ end
1222
+
1223
+ # Gets the current version of sketchup in decimal form.
1224
+ #
1225
+ # @example
1226
+ # version = Sketchup.version
1227
+ # if (version)
1228
+ # UI.messagebox version
1229
+ # else
1230
+ # return
1231
+ # end
1232
+ #
1233
+ # @return version - the decimal form of the version
1234
+ #
1235
+ # @version SketchUp 6.0
1236
+ def self.version
1237
+ end
1238
+
1239
+ # Get the current version of sketchup as a whole number for comparisons. The
1240
+ # number returned has the major, minor, and build values packed into an integer
1241
+ # value as follows:
1242
+ # - Major version = X
1243
+ # - Minor version = Y
1244
+ # - Build number = Z
1245
+ #
1246
+ # SketchUp 6.0 - SketchUp 2015
1247
+ # - XXYYYZZZ
1248
+ #
1249
+ # SketchUp 2016+
1250
+ # - XXYZZZZZZZ
1251
+ #
1252
+ # @example
1253
+ # if (15003000...15004000) === Sketchup.version_number
1254
+ # puts "SketchUp 15.3"
1255
+ # end
1256
+ # if Sketchup.version_number >= 1600000000
1257
+ # puts "New format"
1258
+ # end
1259
+ #
1260
+ # @return version - the whole number form of the version
1261
+ #
1262
+ # @version SketchUp 6.0
1263
+ def self.version_number
1264
+ end
1265
+
1266
+ # The write_default method is used to set the string associated with a
1267
+ # variable within the specified sub-section of a .plist file on the Mac
1268
+ # or the registry on Windows
1269
+ # (within the Software > SketchUp > SketchUp [Version] section).
1270
+ #
1271
+ # @example
1272
+ # result = Sketchup.write_default("section", "key", "my_value")
1273
+ #
1274
+ # @param [String] section
1275
+ # A section in a .plist file (Mac) or the registry
1276
+ # (Windows).
1277
+ #
1278
+ # @param [String] key
1279
+ # A key within the section.
1280
+ #
1281
+ # @param [Object] value
1282
+ # The value to store.
1283
+ #
1284
+ # @return [Boolean] result - True if successful, false if unsuccessful.
1285
+ #
1286
+ # @version SketchUp 6.0
1287
+ def self.write_default(section, key, value)
1288
+ end
1289
+
1290
+ end