Class: Sketchup::Model

Inherits:
Object show all
Defined in:
lib/model.rb

Overview

This is the access point for many common Sketchup objects

Constant Summary collapse

VERSION_3 =

Sketchup::Model.constants.each { |n| puts "#n = #const_get(n)" }

3
VERSION_4 =
4
VERSION_5 =
5
VERSION_6 =
6
VERSION_7 =
7
VERSION_8 =
8
VERSION_2013 =
9
VERSION_2014 =
10
VERSION_2015 =
11

Instance Method Summary collapse

Instance Method Details

#abort_operationObject

end


37
38
# File 'lib/model.rb', line 37

def abort_operation
end

#active_entitiesSketchup::Entities

Returns:


41
42
# File 'lib/model.rb', line 41

def active_entities
end

#active_layerSketchup::Layer

Returns:


45
46
# File 'lib/model.rb', line 45

def active_layer
end

#active_layer=(layer) ⇒ Object

Parameters:


49
50
# File 'lib/model.rb', line 49

def active_layer=(layer)
end

#active_pathObject


52
53
# File 'lib/model.rb', line 52

def active_path
end

#active_viewView

Returns:


56
57
# File 'lib/model.rb', line 56

def active_view
end

#add_noteObject


58
59
# File 'lib/model.rb', line 58

def add_note
end

#add_observerObject


60
61
# File 'lib/model.rb', line 60

def add_observer
end

#attribute_dictionariesObject


62
63
# File 'lib/model.rb', line 62

def attribute_dictionaries
end

#attribute_dictionaryObject


64
65
# File 'lib/model.rb', line 64

def attribute_dictionary
end

#behaviorObject


66
67
# File 'lib/model.rb', line 66

def behavior
end

#boundsBoundingBox

Returns:

  • (BoundingBox)

70
71
# File 'lib/model.rb', line 70

def bounds
end

#classificationsObject


73
74
# File 'lib/model.rb', line 73

def classifications
end

#close(ignore_changes = false) ⇒ Object

Since:

  • 2015


77
78
79
# File 'lib/model.rb', line 77

def close(ignore_changes = false)
  nil
end

#close_activeObject


81
82
# File 'lib/model.rb', line 81

def close_active
end

#commit_operationObject


83
84
# File 'lib/model.rb', line 83

def commit_operation
end

#definitionsDefinitionList

Returns:


87
88
# File 'lib/model.rb', line 87

def definitions
end

#descriptionObject


89
90
# File 'lib/model.rb', line 89

def description
end

#description=Object


91
92
# File 'lib/model.rb', line 91

def description=
end

#edit_transformObject


93
94
# File 'lib/model.rb', line 93

def edit_transform
end

#entitiesEntities

Returns a reference to the active_model's top-level entities collection.

Returns:

See Also:


99
100
101
# File 'lib/model.rb', line 99

def entities
    @entities
end

#exportObject

Note:

Exporting a model actually saves a copy of the model, and subsequently triggers the onSaveModel method of any [ModelObserver]

Note:

PDF export ability added in SketchUp 2016


111
112
# File 'lib/model.rb', line 111

def export
end

#find_entity_by_id(id_list_or_array) ⇒ Object

Finds and returns entities by their entityID or GUID.


115
116
# File 'lib/model.rb', line 115

def find_entity_by_id(id_list_or_array)
end

#get_attributeObject

See Also:


119
120
# File 'lib/model.rb', line 119

def get_attribute
end

#get_datumObject


122
123
# File 'lib/model.rb', line 122

def get_datum
end

#get_product_familyObject


124
125
# File 'lib/model.rb', line 124

def get_product_family
end

#guidObject


126
127
# File 'lib/model.rb', line 126

def guid
end

#importObject


128
129
# File 'lib/model.rb', line 128

def import
end

#latlong_to_pointObject


130
131
# File 'lib/model.rb', line 130

def latlong_to_point
end

#layersLayers

Returns:


134
135
136
# File 'lib/model.rb', line 134

def layers
    @layers
end

#list_datumsObject


138
139
# File 'lib/model.rb', line 138

def list_datums
end

#materialsMaterials

Returns:


142
143
144
# File 'lib/model.rb', line 142

def materials
    @materials
end

#mipmapping=Object


146
147
# File 'lib/model.rb', line 146

def mipmapping=
end

#mipmapping?Boolean

Returns:

  • (Boolean)

148
149
# File 'lib/model.rb', line 148

def mipmapping?
end

#modified?Boolean

Returns:

  • (Boolean)

150
151
# File 'lib/model.rb', line 150

def modified?
end

#nameString

The model name, or "" if model as not been saved.

Returns:


155
156
# File 'lib/model.rb', line 155

def name
end

#name=Object


158
159
# File 'lib/model.rb', line 158

def name=
end

#optionsObject


160
161
162
# File 'lib/model.rb', line 160

def options
    @options
end

#pagesObject

Returns a reference to the model's Pages (Scenes) collection.

Returns:

  • a reference to the model's Pages (Scenes) collection.


165
166
167
# File 'lib/model.rb', line 165

def pages
    @pages
end

#pathObject


169
170
# File 'lib/model.rb', line 169

def path
end

#place_componentObject


171
172
# File 'lib/model.rb', line 171

def place_component
end

#point_to_latlongObject


173
174
# File 'lib/model.rb', line 173

def point_to_latlong
end

#point_to_utmObject


175
176
# File 'lib/model.rb', line 175

def point_to_utm
end

#raytestObject


177
178
# File 'lib/model.rb', line 177

def raytest
end

#remove_observerObject


179
180
# File 'lib/model.rb', line 179

def remove_observer
end

#rendering_optionsRenderingOptions

Returns:


183
184
# File 'lib/model.rb', line 183

def rendering_options
end

#saveObject


185
186
# File 'lib/model.rb', line 185

def save
end

#save_copyObject

Since:

  • SketchUp 2014


189
190
# File 'lib/model.rb', line 189

def save_copy
end

#save_thumbnailObject


192
193
# File 'lib/model.rb', line 192

def save_thumbnail
end

#select_toolObject


194
195
# File 'lib/model.rb', line 194

def select_tool
end

#selectionObject

Returns a collection of selected Entity objects

Returns:

  • a collection of selected Entity objects


198
199
200
# File 'lib/model.rb', line 198

def selection
    @selection
end

#set_attributeObject

See Also:


203
204
# File 'lib/model.rb', line 203

def set_attribute
end

#set_datumObject


206
207
# File 'lib/model.rb', line 206

def set_datum
end

#shadow_infoShadowInfo

Returns object

Returns:


210
211
# File 'lib/model.rb', line 210

def shadow_info
end

#start_operation(op_name) ⇒ bool #start_operation(op_name[,disable_ui, transparent, prev_trans]) ⇒ bool

The start_operation method is used to notify Edit > Undo that a new operation (which can be undone) is starting.

Overloads:

  • #start_operation(op_name) ⇒ bool

    Parameters:

    • op_name (String)

      the name which appears

    Since:

    • SketchUp 6.0

  • #start_operation(op_name[,disable_ui, transparent, prev_trans]) ⇒ bool

    Parameters:

    • op_name (String)

      optional the name which appears

    • disable_ui (optional, true/false)

      user interface changes are suppressed.

    • transparent (Boolean)
    • prev_trans (Boolean)

    Since:

    • SketchUp 7.0

Returns:

  • (bool)

    true if successful, false if not.


227
228
# File 'lib/model.rb', line 227

def start_operation(op_name, disable_ui = false, next_transparent = false, previous_transparent = false)
end

#stylesObject


230
231
# File 'lib/model.rb', line 230

def styles
end

#tagsObject


232
233
# File 'lib/model.rb', line 232

def tags
end

#tags=Object


234
235
# File 'lib/model.rb', line 234

def tags=
end

#titleString

The name of the model

Returns:


239
240
# File 'lib/model.rb', line 239

def title
end

#toolsObject


242
243
# File 'lib/model.rb', line 242

def tools
end

#utm_to_pointObject


244
245
# File 'lib/model.rb', line 244

def utm_to_point
end

#valid?Boolean

Returns:

  • (Boolean)

246
247
# File 'lib/model.rb', line 246

def valid?
end