scriptup 0.0.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 (241) hide show
  1. checksums.yaml +7 -0
  2. data/LICENSE.txt +11 -0
  3. data/README.md +5 -0
  4. data/ext/attribute_dictionaries.c +45 -0
  5. data/ext/attribute_dictionaries.h +3 -0
  6. data/ext/attribute_dictionary.c +156 -0
  7. data/ext/attribute_dictionary.h +3 -0
  8. data/ext/behavior.c +10 -0
  9. data/ext/behavior.h +3 -0
  10. data/ext/color.c +211 -0
  11. data/ext/color.h +3 -0
  12. data/ext/component_definition.c +188 -0
  13. data/ext/component_definition.h +3 -0
  14. data/ext/component_instance.c +10 -0
  15. data/ext/component_instance.h +3 -0
  16. data/ext/definition_list.c +145 -0
  17. data/ext/definition_list.h +3 -0
  18. data/ext/drawing_element.c +10 -0
  19. data/ext/drawing_element.h +3 -0
  20. data/ext/entities.c +11 -0
  21. data/ext/entities.h +3 -0
  22. data/ext/entity.c +253 -0
  23. data/ext/entity.h +3 -0
  24. data/ext/extconf.rb +38 -0
  25. data/ext/material.c +242 -0
  26. data/ext/material.h +3 -0
  27. data/ext/materials.c +80 -0
  28. data/ext/materials.h +3 -0
  29. data/ext/model.c +42 -0
  30. data/ext/model.h +3 -0
  31. data/ext/sketchup.c +89 -0
  32. data/ext/sketchup.h +4 -0
  33. data/ext/texture.c +9 -0
  34. data/ext/texture.h +3 -0
  35. data/ext/typed_value.c +84 -0
  36. data/ext/typed_value.h +5 -0
  37. data/ext/utils.h +80 -0
  38. data/lib/sketchup.rb +12 -0
  39. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/application/application.h +36 -0
  40. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/application/model.h +59 -0
  41. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/application/overlay.h +248 -0
  42. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/application/ruby_api.h +118 -0
  43. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/color.h +107 -0
  44. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/common.h +178 -0
  45. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/defs.h +19 -0
  46. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/extension_license.h +62 -0
  47. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/geometry/bounding_box.h +34 -0
  48. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/geometry/plane3d.h +153 -0
  49. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/geometry/point2d.h +96 -0
  50. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/geometry/point3d.h +98 -0
  51. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/geometry/ray3d.h +64 -0
  52. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/geometry/transformation.h +321 -0
  53. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/geometry/transformation2d.h +163 -0
  54. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/geometry/vector2d.h +235 -0
  55. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/geometry/vector3d.h +285 -0
  56. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/geometry.h +152 -0
  57. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/import_export/modelexporterplugin.h +165 -0
  58. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/import_export/modelimporterplugin.h +183 -0
  59. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/import_export/pluginprogresscallback.h +84 -0
  60. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/initialize.h +43 -0
  61. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/length_formatter.h +424 -0
  62. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/arccurve.h +244 -0
  63. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/arrow_type.h +17 -0
  64. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/attribute_dictionary.h +161 -0
  65. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/axes.h +242 -0
  66. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/camera.h +398 -0
  67. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/classification_attribute.h +89 -0
  68. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/classification_info.h +125 -0
  69. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/classifications.h +86 -0
  70. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/component_definition.h +588 -0
  71. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/component_instance.h +344 -0
  72. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/curve.h +143 -0
  73. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/defs.h +142 -0
  74. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/dimension.h +222 -0
  75. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/dimension_linear.h +421 -0
  76. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/dimension_radial.h +194 -0
  77. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/dimension_style.h +253 -0
  78. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/drawing_element.h +198 -0
  79. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/dynamic_component_attribute.h +92 -0
  80. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/dynamic_component_info.h +70 -0
  81. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/edge.h +271 -0
  82. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/edge_use.h +214 -0
  83. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/entities.h +834 -0
  84. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/entity.h +186 -0
  85. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/entity_list.h +80 -0
  86. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/entity_list_iterator.h +90 -0
  87. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/face.h +686 -0
  88. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/font.h +138 -0
  89. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/geometry.h +20 -0
  90. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/geometry_input.h +685 -0
  91. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/group.h +244 -0
  92. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/guide_line.h +155 -0
  93. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/guide_point.h +153 -0
  94. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/image.h +288 -0
  95. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/image_rep.h +275 -0
  96. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/instancepath.h +266 -0
  97. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/layer.h +265 -0
  98. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/layer_folder.h +301 -0
  99. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/line_style.h +211 -0
  100. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/line_styles.h +81 -0
  101. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/location.h +65 -0
  102. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/loop.h +182 -0
  103. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/material.h +390 -0
  104. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/mesh_helper.h +187 -0
  105. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/model.h +1663 -0
  106. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/model_version.h +49 -0
  107. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/opening.h +72 -0
  108. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/options_manager.h +79 -0
  109. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/options_provider.h +166 -0
  110. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/polyline3d.h +140 -0
  111. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/rendering_options.h +179 -0
  112. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/scene.h +836 -0
  113. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/schema.h +56 -0
  114. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/schema_type.h +26 -0
  115. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/section_plane.h +212 -0
  116. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/selection.h +156 -0
  117. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/shadow_info.h +147 -0
  118. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/skp.h +45 -0
  119. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/style.h +303 -0
  120. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/styles.h +190 -0
  121. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/text.h +384 -0
  122. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/texture.h +358 -0
  123. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/texture_writer.h +280 -0
  124. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/typed_value.h +390 -0
  125. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/uv_helper.h +79 -0
  126. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/model/vertex.h +154 -0
  127. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/sketchup.h +122 -0
  128. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/sketchup_info.h +65 -0
  129. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/slapi.h +16 -0
  130. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/transformation.h +16 -0
  131. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/unicodestring.h +239 -0
  132. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Headers/utils/math_helpers.h +124 -0
  133. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Libraries/libCommonGeometry.dylib +0 -0
  134. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Libraries/libCommonGeoutils.dylib +0 -0
  135. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Libraries/libCommonImage.dylib +0 -0
  136. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Libraries/libCommonPreferences.dylib +0 -0
  137. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Libraries/libCommonUnits.dylib +0 -0
  138. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Libraries/libCommonUtils.dylib +0 -0
  139. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Libraries/libCommonZip.dylib +0 -0
  140. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/Resources/Info.plist +50 -0
  141. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/SketchUpAPI +0 -0
  142. data/sketchup-sdk-mac/SketchUpAPI.framework/Versions/A/_CodeSignature/CodeResources +835 -0
  143. data/sketchup-sdk-win/binaries/sketchup/x64/SketchUpAPI.dll +0 -0
  144. data/sketchup-sdk-win/binaries/sketchup/x64/SketchUpAPI.lib +0 -0
  145. data/sketchup-sdk-win/binaries/sketchup/x64/SketchUpCommonPreferences.dll +0 -0
  146. data/sketchup-sdk-win/binaries/sketchup/x64/sketchup.lib +0 -0
  147. data/sketchup-sdk-win/headers/SketchUpAPI/application/application.h +36 -0
  148. data/sketchup-sdk-win/headers/SketchUpAPI/application/model.h +59 -0
  149. data/sketchup-sdk-win/headers/SketchUpAPI/application/overlay.h +248 -0
  150. data/sketchup-sdk-win/headers/SketchUpAPI/application/ruby_api.h +118 -0
  151. data/sketchup-sdk-win/headers/SketchUpAPI/color.h +107 -0
  152. data/sketchup-sdk-win/headers/SketchUpAPI/common.h +178 -0
  153. data/sketchup-sdk-win/headers/SketchUpAPI/defs.h +19 -0
  154. data/sketchup-sdk-win/headers/SketchUpAPI/extension_license.h +62 -0
  155. data/sketchup-sdk-win/headers/SketchUpAPI/geometry/bounding_box.h +34 -0
  156. data/sketchup-sdk-win/headers/SketchUpAPI/geometry/plane3d.h +153 -0
  157. data/sketchup-sdk-win/headers/SketchUpAPI/geometry/point2d.h +96 -0
  158. data/sketchup-sdk-win/headers/SketchUpAPI/geometry/point3d.h +98 -0
  159. data/sketchup-sdk-win/headers/SketchUpAPI/geometry/ray3d.h +64 -0
  160. data/sketchup-sdk-win/headers/SketchUpAPI/geometry/transformation.h +321 -0
  161. data/sketchup-sdk-win/headers/SketchUpAPI/geometry/transformation2d.h +163 -0
  162. data/sketchup-sdk-win/headers/SketchUpAPI/geometry/vector2d.h +235 -0
  163. data/sketchup-sdk-win/headers/SketchUpAPI/geometry/vector3d.h +285 -0
  164. data/sketchup-sdk-win/headers/SketchUpAPI/geometry.h +152 -0
  165. data/sketchup-sdk-win/headers/SketchUpAPI/import_export/modelexporterplugin.h +165 -0
  166. data/sketchup-sdk-win/headers/SketchUpAPI/import_export/modelimporterplugin.h +183 -0
  167. data/sketchup-sdk-win/headers/SketchUpAPI/import_export/pluginprogresscallback.h +84 -0
  168. data/sketchup-sdk-win/headers/SketchUpAPI/initialize.h +43 -0
  169. data/sketchup-sdk-win/headers/SketchUpAPI/length_formatter.h +424 -0
  170. data/sketchup-sdk-win/headers/SketchUpAPI/model/arccurve.h +244 -0
  171. data/sketchup-sdk-win/headers/SketchUpAPI/model/arrow_type.h +17 -0
  172. data/sketchup-sdk-win/headers/SketchUpAPI/model/attribute_dictionary.h +161 -0
  173. data/sketchup-sdk-win/headers/SketchUpAPI/model/axes.h +242 -0
  174. data/sketchup-sdk-win/headers/SketchUpAPI/model/camera.h +398 -0
  175. data/sketchup-sdk-win/headers/SketchUpAPI/model/classification_attribute.h +89 -0
  176. data/sketchup-sdk-win/headers/SketchUpAPI/model/classification_info.h +125 -0
  177. data/sketchup-sdk-win/headers/SketchUpAPI/model/classifications.h +86 -0
  178. data/sketchup-sdk-win/headers/SketchUpAPI/model/component_definition.h +588 -0
  179. data/sketchup-sdk-win/headers/SketchUpAPI/model/component_instance.h +344 -0
  180. data/sketchup-sdk-win/headers/SketchUpAPI/model/curve.h +143 -0
  181. data/sketchup-sdk-win/headers/SketchUpAPI/model/defs.h +142 -0
  182. data/sketchup-sdk-win/headers/SketchUpAPI/model/dimension.h +222 -0
  183. data/sketchup-sdk-win/headers/SketchUpAPI/model/dimension_linear.h +421 -0
  184. data/sketchup-sdk-win/headers/SketchUpAPI/model/dimension_radial.h +194 -0
  185. data/sketchup-sdk-win/headers/SketchUpAPI/model/dimension_style.h +253 -0
  186. data/sketchup-sdk-win/headers/SketchUpAPI/model/drawing_element.h +198 -0
  187. data/sketchup-sdk-win/headers/SketchUpAPI/model/dynamic_component_attribute.h +92 -0
  188. data/sketchup-sdk-win/headers/SketchUpAPI/model/dynamic_component_info.h +70 -0
  189. data/sketchup-sdk-win/headers/SketchUpAPI/model/edge.h +271 -0
  190. data/sketchup-sdk-win/headers/SketchUpAPI/model/edge_use.h +214 -0
  191. data/sketchup-sdk-win/headers/SketchUpAPI/model/entities.h +834 -0
  192. data/sketchup-sdk-win/headers/SketchUpAPI/model/entity.h +186 -0
  193. data/sketchup-sdk-win/headers/SketchUpAPI/model/entity_list.h +80 -0
  194. data/sketchup-sdk-win/headers/SketchUpAPI/model/entity_list_iterator.h +90 -0
  195. data/sketchup-sdk-win/headers/SketchUpAPI/model/face.h +686 -0
  196. data/sketchup-sdk-win/headers/SketchUpAPI/model/font.h +138 -0
  197. data/sketchup-sdk-win/headers/SketchUpAPI/model/geometry.h +20 -0
  198. data/sketchup-sdk-win/headers/SketchUpAPI/model/geometry_input.h +685 -0
  199. data/sketchup-sdk-win/headers/SketchUpAPI/model/group.h +244 -0
  200. data/sketchup-sdk-win/headers/SketchUpAPI/model/guide_line.h +155 -0
  201. data/sketchup-sdk-win/headers/SketchUpAPI/model/guide_point.h +153 -0
  202. data/sketchup-sdk-win/headers/SketchUpAPI/model/image.h +288 -0
  203. data/sketchup-sdk-win/headers/SketchUpAPI/model/image_rep.h +275 -0
  204. data/sketchup-sdk-win/headers/SketchUpAPI/model/instancepath.h +266 -0
  205. data/sketchup-sdk-win/headers/SketchUpAPI/model/layer.h +265 -0
  206. data/sketchup-sdk-win/headers/SketchUpAPI/model/layer_folder.h +301 -0
  207. data/sketchup-sdk-win/headers/SketchUpAPI/model/line_style.h +211 -0
  208. data/sketchup-sdk-win/headers/SketchUpAPI/model/line_styles.h +81 -0
  209. data/sketchup-sdk-win/headers/SketchUpAPI/model/location.h +65 -0
  210. data/sketchup-sdk-win/headers/SketchUpAPI/model/loop.h +182 -0
  211. data/sketchup-sdk-win/headers/SketchUpAPI/model/material.h +390 -0
  212. data/sketchup-sdk-win/headers/SketchUpAPI/model/mesh_helper.h +187 -0
  213. data/sketchup-sdk-win/headers/SketchUpAPI/model/model.h +1663 -0
  214. data/sketchup-sdk-win/headers/SketchUpAPI/model/model_version.h +49 -0
  215. data/sketchup-sdk-win/headers/SketchUpAPI/model/opening.h +72 -0
  216. data/sketchup-sdk-win/headers/SketchUpAPI/model/options_manager.h +79 -0
  217. data/sketchup-sdk-win/headers/SketchUpAPI/model/options_provider.h +166 -0
  218. data/sketchup-sdk-win/headers/SketchUpAPI/model/polyline3d.h +140 -0
  219. data/sketchup-sdk-win/headers/SketchUpAPI/model/rendering_options.h +179 -0
  220. data/sketchup-sdk-win/headers/SketchUpAPI/model/scene.h +836 -0
  221. data/sketchup-sdk-win/headers/SketchUpAPI/model/schema.h +56 -0
  222. data/sketchup-sdk-win/headers/SketchUpAPI/model/schema_type.h +26 -0
  223. data/sketchup-sdk-win/headers/SketchUpAPI/model/section_plane.h +212 -0
  224. data/sketchup-sdk-win/headers/SketchUpAPI/model/selection.h +156 -0
  225. data/sketchup-sdk-win/headers/SketchUpAPI/model/shadow_info.h +147 -0
  226. data/sketchup-sdk-win/headers/SketchUpAPI/model/skp.h +45 -0
  227. data/sketchup-sdk-win/headers/SketchUpAPI/model/style.h +303 -0
  228. data/sketchup-sdk-win/headers/SketchUpAPI/model/styles.h +190 -0
  229. data/sketchup-sdk-win/headers/SketchUpAPI/model/text.h +384 -0
  230. data/sketchup-sdk-win/headers/SketchUpAPI/model/texture.h +358 -0
  231. data/sketchup-sdk-win/headers/SketchUpAPI/model/texture_writer.h +280 -0
  232. data/sketchup-sdk-win/headers/SketchUpAPI/model/typed_value.h +390 -0
  233. data/sketchup-sdk-win/headers/SketchUpAPI/model/uv_helper.h +79 -0
  234. data/sketchup-sdk-win/headers/SketchUpAPI/model/vertex.h +154 -0
  235. data/sketchup-sdk-win/headers/SketchUpAPI/sketchup.h +122 -0
  236. data/sketchup-sdk-win/headers/SketchUpAPI/sketchup_info.h +65 -0
  237. data/sketchup-sdk-win/headers/SketchUpAPI/slapi.h +16 -0
  238. data/sketchup-sdk-win/headers/SketchUpAPI/transformation.h +16 -0
  239. data/sketchup-sdk-win/headers/SketchUpAPI/unicodestring.h +239 -0
  240. data/sketchup-sdk-win/headers/SketchUpAPI/utils/math_helpers.h +124 -0
  241. metadata +313 -0
@@ -0,0 +1,303 @@
1
+ // Copyright 2015 Trimble Inc. All Rights Reserved.
2
+
3
+ /**
4
+ * @file
5
+ * @brief Interfaces for SUStyleRef.
6
+ */
7
+ #ifndef SKETCHUP_MODEL_STYLE_H_
8
+ #define SKETCHUP_MODEL_STYLE_H_
9
+
10
+ #include <SketchUpAPI/common.h>
11
+ #include <SketchUpAPI/unicodestring.h>
12
+ #include <SketchUpAPI/geometry.h>
13
+ #include <SketchUpAPI/model/defs.h>
14
+
15
+ #ifdef __cplusplus
16
+ extern "C" {
17
+ #endif
18
+
19
+ /**
20
+ @struct SUStyleRef
21
+ @extends SUEntityRef
22
+ @brief A style entity reference.
23
+ @since SketchUp 2017, API 5.0
24
+ */
25
+
26
+ /**
27
+ @brief Creates an empty style object.
28
+ @since SketchUp 2017, API 5.0
29
+ @param[out] style The style object.
30
+ @related SUStylesRef
31
+ @return
32
+ - \ref SU_ERROR_NONE on success
33
+ - \ref SU_ERROR_NULL_POINTER_OUTPUT if style is NULL
34
+ - \ref SU_ERROR_OVERWRITE_VALID if *style already refers to a valid object
35
+ */
36
+ SU_RESULT SUStyleCreate(SUStyleRef* style);
37
+
38
+ /**
39
+ @brief Creates a style object from a file at the given path.
40
+ @since SketchUp 2017, API 5.0
41
+ @param[out] style The style object.
42
+ @param[in] path The file path.
43
+ Assumed to be UTF-8 encoded.
44
+ @related SUStylesRef
45
+ @return
46
+ - \ref SU_ERROR_NONE on success
47
+ - \ref SU_ERROR_NULL_POINTER_OUTPUT if style is NULL
48
+ - \ref SU_ERROR_OVERWRITE_VALID if *style already refers to a valid object
49
+ - \ref SU_ERROR_NULL_POINTER_INPUT if path is NULL
50
+ - \ref SU_ERROR_SERIALIZATION if style couldn't be created from the file at path
51
+ */
52
+ SU_RESULT SUStyleCreateFromFile(SUStyleRef* style, const char* path);
53
+
54
+ /**
55
+ @brief Releases a style object.
56
+ @since SketchUp 2017, API 5.0
57
+ @param[in] style The style object.
58
+ @related SUStylesRef
59
+ @return
60
+ - \ref SU_ERROR_NONE on success
61
+ - \ref SU_ERROR_NULL_POINTER_INPUT if style is NULL
62
+ - \ref SU_ERROR_INVALID_INPUT if *style does not refer to a valid object
63
+ */
64
+ SU_RESULT SUStyleRelease(SUStyleRef* style);
65
+
66
+ /**
67
+ @brief Converts from an \ref SUStyleRef to an \ref SUEntityRef. This is
68
+ essentially an upcast operation.
69
+ @since SketchUp 2017, API 5.0
70
+ @param[in] style The style object.
71
+ @related SUStylesRef
72
+ @return
73
+ - The converted \ref SUEntityRef if style is a valid object
74
+ - If not, the returned reference will be invalid
75
+ */
76
+ SU_EXPORT SUEntityRef SUStyleToEntity(SUStyleRef style);
77
+
78
+ /**
79
+ @brief Converts from an \ref SUEntityRef to an \ref SUStyleRef.
80
+ This is essentially a downcast operation so the given \ref SUEntityRef
81
+ must be convertible to an \ref SUStyleRef.
82
+ @since SketchUp 2017, API 5.0
83
+ @param[in] entity The entity object.
84
+ @related SUStylesRef
85
+ @return
86
+ - The converted \ref SUStyleRef if the downcast operation succeeds
87
+ - If the downcast operation fails, the returned reference will be invalid
88
+ */
89
+ SU_EXPORT SUStyleRef SUStyleFromEntity(SUEntityRef entity);
90
+
91
+ /**
92
+ @brief Sets the name of a style object.
93
+ @since SketchUp 2017, API 5.0
94
+ @param[in] style The style object.
95
+ @param[in] name The name string to set the style object.
96
+ Assumed to be UTF-8 encoded.
97
+ @related SUStylesRef
98
+ @return
99
+ - \ref SU_ERROR_NONE on success
100
+ - \ref SU_ERROR_INVALID_INPUT if style is not a valid object
101
+ - \ref SU_ERROR_NULL_POINTER_INPUT if name is NULL
102
+ */
103
+ SU_RESULT SUStyleSetName(SUStyleRef style, const char* name);
104
+
105
+ /**
106
+ @brief Retrieves the name of a style object.
107
+ @since SketchUp 2017, API 5.0
108
+ @param[in] style The style object.
109
+ @param[out] name The name retrieved.
110
+ @related SUStylesRef
111
+ @return
112
+ - \ref SU_ERROR_NONE on success
113
+ - \ref SU_ERROR_INVALID_INPUT if style is not a valid object
114
+ - \ref SU_ERROR_NULL_POINTER_OUTPUT if name is NULL
115
+ - \ref SU_ERROR_INVALID_OUTPUT if name does not point to a valid \ref
116
+ SUStringRef object
117
+ */
118
+ SU_RESULT SUStyleGetName(SUStyleRef style, SUStringRef* name);
119
+
120
+ /**
121
+ @brief Retrieves the display name of a style object. If the name begins with a
122
+ wildcard character "*" the wildcard will be replaced be a default
123
+ string. The default string defaults to "*", so is no default string is
124
+ set this function will always return the same string as GetName.
125
+ @since SketchUp 2017, API 5.0
126
+ @param[in] style The style object.
127
+ @param[out] name The display name retrieved.
128
+ @related SUStylesRef
129
+ @return
130
+ - \ref SU_ERROR_NONE on success
131
+ - \ref SU_ERROR_INVALID_INPUT if style is not a valid object
132
+ - \ref SU_ERROR_NULL_POINTER_OUTPUT if name is NULL
133
+ - \ref SU_ERROR_INVALID_OUTPUT if name does not point to a valid \ref
134
+ SUStringRef object
135
+ */
136
+ SU_RESULT SUStyleGetDisplayName(SUStyleRef style, SUStringRef* name);
137
+
138
+ /**
139
+ @brief Sets the description of a style object.
140
+ @since SketchUp 2017, API 5.0
141
+ @param[in] style The style object.
142
+ @param[in] description The description string to set the style object.
143
+ Assumed to be UTF-8 encoded.
144
+ @related SUStylesRef
145
+ @return
146
+ - \ref SU_ERROR_NONE on success
147
+ - \ref SU_ERROR_INVALID_INPUT if style is not a valid object
148
+ - \ref SU_ERROR_NULL_POINTER_INPUT if description is NULL
149
+ */
150
+ SU_RESULT SUStyleSetDescription(SUStyleRef style, const char* description);
151
+
152
+ /**
153
+ @brief Retrieves the description of a style object.
154
+ @since SketchUp 2017, API 5.0
155
+ @param[in] style The style object.
156
+ @param[out] description The description retrieved.
157
+ @related SUStylesRef
158
+ @return
159
+ - \ref SU_ERROR_NONE on success
160
+ - \ref SU_ERROR_INVALID_INPUT if style is not a valid object
161
+ - \ref SU_ERROR_NULL_POINTER_OUTPUT if description is NULL
162
+ - \ref SU_ERROR_INVALID_OUTPUT if description does not point to a valid \ref
163
+ SUStringRef object
164
+ */
165
+ SU_RESULT SUStyleGetDescription(SUStyleRef style, SUStringRef* description);
166
+
167
+ /**
168
+ @brief Retrieves the filepath to the file which was used to import this style.
169
+ @since SketchUp 2017, API 5.0
170
+ @param[in] style The style object.
171
+ @param[out] path The path retrieved.
172
+ @related SUStylesRef
173
+ @return
174
+ - \ref SU_ERROR_NONE on success
175
+ - \ref SU_ERROR_INVALID_INPUT if style is not a valid object
176
+ - \ref SU_ERROR_NULL_POINTER_OUTPUT if path is NULL
177
+ - \ref SU_ERROR_INVALID_OUTPUT if path does not point to a valid \ref
178
+ SUStringRef object
179
+ */
180
+ SU_RESULT SUStyleGetPath(SUStyleRef style, SUStringRef* path);
181
+
182
+ /**
183
+ @brief Retrieves the GUID of a style object.
184
+ @since SketchUp 2017, API 5.0
185
+ @param[in] style The style object.
186
+ @param[out] guid The GUID retrieved.
187
+ @related SUStylesRef
188
+ @return
189
+ - \ref SU_ERROR_NONE on success
190
+ - \ref SU_ERROR_INVALID_INPUT if style is not a valid object
191
+ - \ref SU_ERROR_NULL_POINTER_OUTPUT if guid is NULL
192
+ - \ref SU_ERROR_INVALID_OUTPUT if guid does not point to a valid \ref
193
+ SUStringRef object
194
+ */
195
+ SU_RESULT SUStyleGetGuid(SUStyleRef style, SUStringRef* guid);
196
+
197
+ /**
198
+ @brief Retrieves a boolean indicating whether the style displays a watermark.
199
+ @since SketchUp 2017, API 5.0
200
+ @param[in] style The style object.
201
+ @param[out] shows_mark The boolean retrieved.
202
+ @related SUStylesRef
203
+ @return
204
+ - \ref SU_ERROR_NONE on success
205
+ - \ref SU_ERROR_INVALID_INPUT if style is not a valid object
206
+ - \ref SU_ERROR_NULL_POINTER_OUTPUT if shows_mark is NULL
207
+ */
208
+ SU_RESULT SUStyleGetDisplaysWatermark(SUStyleRef style, bool* shows_mark);
209
+
210
+ /**
211
+ @brief Saves the style data to the specified path.
212
+ @since SketchUp 2017, API 5.0
213
+ @param[in] style The style object.
214
+ @param[in] path The path to where the data should be saved. Assumed to be
215
+ UTF-8 encoded.
216
+ @related SUStylesRef
217
+ @return
218
+ - \ref SU_ERROR_NONE on success
219
+ - \ref SU_ERROR_INVALID_INPUT if style is not a valid object
220
+ - \ref SU_ERROR_NULL_POINTER_INPUT if path is NULL
221
+ - \ref SU_ERROR_SERIALIZATION if the save operation fails
222
+ */
223
+ SU_RESULT SUStyleSaveToFile(SUStyleRef style, const char* path);
224
+
225
+ /**
226
+ @enum SUStylePropertyType
227
+ @brief The set style properties that can be set/retrieved. Each property
228
+ supports a single data type indicated by comments in the list.
229
+ */
230
+ enum SUStylePropertyType {
231
+ // Edge Parameters (0 - 63)
232
+ SUStyleEdgesColor = 0, ///< data type: SUTypedValueType_Color.
233
+ SUStyleEdgesExtensionsEnabled = 1, ///< data type: SUTypedValueType_Bool.
234
+ SUStyleEdgesExtensionLength = 2, ///< data type: SUTypedValueType_Int32.
235
+ SUStyleEdgesProfilesEnabled = 3, ///< data type: SUTypedValueType_Bool.
236
+ SUStyleEdgesProfileWidth = 4, ///< data type: SUTypedValueType_Int32.
237
+ SUStyleEdgesDepthCueEnabled = 5, ///< data type: SUTypedValueType_Bool.
238
+ SUStyleEdgesDepthCueLevels = 6, ///< data type: SUTypedValueType_Int32.
239
+ // Background Parameters (64 - 127)
240
+ SUStyleBackgroundColor = 64 ///< data type: SUTypedValueType_Color.
241
+ };
242
+
243
+ /**
244
+ @brief Sets the value of the specified \ref SUStylePropertyType.
245
+ @since SketchUp 2017, API 5.0
246
+ @param[in] style The style object.
247
+ @param[in] type The style type to set.
248
+ @param[in] value The value to set for type.
249
+ @related SUStylesRef
250
+ @return
251
+ - \ref SU_ERROR_NONE on success
252
+ - \ref SU_ERROR_INVALID_INPUT if style or value are not valid objects or
253
+ value has the incorrect data type
254
+ - \ref SU_ERROR_OUT_OF_RANGE if attempting to set an unhandled property type
255
+ - \ref SU_ERROR_NO_DATA if attempting to set an unhandled data type
256
+ */
257
+ SU_RESULT SUStyleSetProperty(
258
+ SUStyleRef style, enum SUStylePropertyType type, SUTypedValueRef value);
259
+
260
+ /**
261
+ @brief Retrieves a \ref SUTypedValueRef containing the value of the specified
262
+ \ref SUStylePropertyType.
263
+ @since SketchUp 2017, API 5.0
264
+ @param[in] style The style object.
265
+ @param[in] type The style type to retrieve.
266
+ @param[out] value The \ref SUTypedValueRef retrieved.
267
+ @related SUStylesRef
268
+ @return
269
+ - \ref SU_ERROR_NONE on success
270
+ - \ref SU_ERROR_INVALID_INPUT if style is not a valid object
271
+ - \ref SU_ERROR_NULL_POINTER_OUTPUT if value is NULL
272
+ - \ref SU_ERROR_INVALID_OUTPUT if value is not a valid object
273
+ - \ref SU_ERROR_OUT_OF_RANGE if attempting to get an unhandled property type
274
+ - \ref SU_ERROR_NO_DATA if the style doesn't contain the specified property.
275
+ - \ref SU_ERROR_GENERIC if the retrieved data type is incorrect.
276
+ */
277
+ SU_RESULT SUStyleGetProperty(
278
+ SUStyleRef style, enum SUStylePropertyType type, SUTypedValueRef* value);
279
+
280
+
281
+ /**
282
+ @brief Retrieves an image containing the style's thumbnail. The given image
283
+ representation object must have been constructed using
284
+ SUImageRepCreate(). It must be released using SUImageRepRelease().
285
+ @since SketchUp 2017, API 5.0
286
+ @param[in] style The style object.
287
+ @param[out] image The image object retrieved.
288
+ @related SUStylesRef
289
+ @return
290
+ - \ref SU_ERROR_NONE on success
291
+ - \ref SU_ERROR_INVALID_INPUT if style is not a valid object
292
+ - \ref SU_ERROR_NULL_POINTER_OUTPUT if image is NULL
293
+ - \ref SU_ERROR_INVALID_OUTPUT if image does not point to a valid \ref
294
+ SUImageRepRef object
295
+ - \ref SU_ERROR_NO_DATA if there was no image data
296
+ */
297
+ SU_RESULT SUStyleGetThumbnail(SUStyleRef style, SUImageRepRef* image);
298
+
299
+ #ifdef __cplusplus
300
+ } // extern "C"
301
+ #endif
302
+
303
+ #endif // SKETCHUP_MODEL_STYLE_H_
@@ -0,0 +1,190 @@
1
+ // Copyright 2015 Trimble Inc. All Rights Reserved.
2
+
3
+ /**
4
+ * @file
5
+ * @brief Interfaces for SUStylesRef.
6
+ */
7
+ #ifndef SKETCHUP_MODEL_STYLES_H_
8
+ #define SKETCHUP_MODEL_STYLES_H_
9
+
10
+ #include <SketchUpAPI/common.h>
11
+ #include <SketchUpAPI/geometry.h>
12
+ #include <SketchUpAPI/model/defs.h>
13
+
14
+ #ifdef __cplusplus
15
+ extern "C" {
16
+ #endif
17
+
18
+ /**
19
+ @struct SUStylesRef
20
+ @brief A styles entity reference.
21
+ @since SketchUp 2017, API 5.0
22
+ */
23
+
24
+ /**
25
+ @brief Adds a new style to the styles object from a file at the given path.
26
+ Optionally will set the new style as the active style.
27
+
28
+ NOTE: Return value SU_ERROR_SERIALIZATION was added for SketchUp 2019, API 7.0
29
+ @since SketchUp 2017, API 5.0
30
+ @param[in] styles The styles object.
31
+ @param[in] path The string specifying the file path to the new style.
32
+ @param[in] activate If true activate the style.
33
+ @related SUStylesRef
34
+ @return
35
+ - \ref SU_ERROR_NONE on success
36
+ - \ref SU_ERROR_INVALID_INPUT if styles is not a valid object
37
+ - \ref SU_ERROR_NULL_POINTER_INPUT if name is NULL
38
+ - \ref SU_ERROR_SERIALIZATION if style couldn't be created from the file at path
39
+ - \ref SU_ERROR_DUPLICATE if the name corresponds to an existing style
40
+ */
41
+ SU_RESULT SUStylesAddStyle(SUStylesRef styles, const char* path, bool activate);
42
+
43
+ /**
44
+ @brief Retrieves the number of styles in a styles object.
45
+ @since SketchUp 2017, API 5.0
46
+ @param[in] styles The styles object.
47
+ @param[out] count The number of style objects available.
48
+ @related SUStylesRef
49
+ @return
50
+ - \ref SU_ERROR_NONE on success
51
+ - \ref SU_ERROR_INVALID_INPUT if styles is not a valid object
52
+ - \ref SU_ERROR_NULL_POINTER_OUTPUT if count is NULL
53
+ */
54
+ SU_RESULT SUStylesGetNumStyles(SUStylesRef styles, size_t* count);
55
+
56
+ /**
57
+ @brief Retrieves all the styles associated with a styles object.
58
+ @since SketchUp 2017, API 5.0
59
+ @param[in] styles The styles object.
60
+ @param[in] len The number of style objects to retrieve.
61
+ @param[out] style_array The style objects retrieved.
62
+ @param[out] count The number of style objects retrieved.
63
+ @related SUStylesRef
64
+ @return
65
+ - \ref SU_ERROR_NONE on success
66
+ - \ref SU_ERROR_INVALID_INPUT if styles is not a valid object
67
+ - \ref SU_ERROR_NULL_POINTER_OUTPUT if style_array or count is NULL
68
+ */
69
+ SU_RESULT SUStylesGetStyles(
70
+ SUStylesRef styles, size_t len, SUStyleRef style_array[], size_t* count);
71
+
72
+ /**
73
+ @brief Retrieves the active style.
74
+ @since SketchUp 2017, API 5.0
75
+ @param[in] styles The styles object.
76
+ @param[out] style Pointer to a \ref SUStyleRef for returning the style.
77
+ @related SUStylesRef
78
+ @return
79
+ - \ref SU_ERROR_NONE on success
80
+ - \ref SU_ERROR_INVALID_INPUT if styles is not a valid object
81
+ - \ref SU_ERROR_NULL_POINTER_OUTPUT if style is NULL
82
+ */
83
+ SU_RESULT SUStylesGetActiveStyle(SUStylesRef styles, SUStyleRef* style);
84
+
85
+ /**
86
+ @brief Retrieves the selected style.
87
+ @since SketchUp 2017, API 5.0
88
+ @param[in] styles The styles object.
89
+ @param[out] style Pointer to a \ref SUStyleRef for returning the style.
90
+ @related SUStylesRef
91
+ @return
92
+ - \ref SU_ERROR_NONE on success
93
+ - \ref SU_ERROR_INVALID_INPUT if styles is not a valid object
94
+ - \ref SU_ERROR_NULL_POINTER_OUTPUT if style is NULL
95
+ */
96
+ SU_RESULT SUStylesGetSelectedStyle(SUStylesRef styles, SUStyleRef* style);
97
+
98
+ /**
99
+ @brief Retrieves the style corresponding to the specified Guid.
100
+ @since SketchUp 2017, API 5.0
101
+ @param[in] styles The styles object.
102
+ @param[in] guid The string specifying a style by Guid.
103
+ @param[out] style Pointer to a \ref SUStyleRef for returning the style.
104
+ @related SUStylesRef
105
+ @return
106
+ - \ref SU_ERROR_NONE on success
107
+ - \ref SU_ERROR_INVALID_INPUT if styles is not a valid object
108
+ - \ref SU_ERROR_NULL_POINTER_INPUT if guid is NULL
109
+ - \ref SU_ERROR_NULL_POINTER_OUTPUT if style is NULL
110
+ */
111
+ SU_RESULT SUStylesGetStyleByGuid(SUStylesRef styles, const char* guid, SUStyleRef* style);
112
+
113
+ /**
114
+ @brief Retrieves the style corresponding to the specified path.
115
+ @since SketchUp 2017, API 5.0
116
+ @param[in] styles The styles object.
117
+ @param[in] path The string specifying a style by path.
118
+ @param[out] style Pointer to a \ref SUStyleRef for returning the style.
119
+ @related SUStylesRef
120
+ @return
121
+ - \ref SU_ERROR_NONE on success
122
+ - \ref SU_ERROR_INVALID_INPUT if styles is not a valid object
123
+ - \ref SU_ERROR_NULL_POINTER_INPUT if path is NULL
124
+ - \ref SU_ERROR_NULL_POINTER_OUTPUT if style is NULL
125
+ - \ref SU_ERROR_NO_DATA if no style in styles matches the style at path.
126
+ */
127
+ SU_RESULT SUStylesGetStyleByPath(SUStylesRef styles, const char* path, SUStyleRef* style);
128
+
129
+ /**
130
+ @brief Retrieves a bolean indicating if the active style has changed.
131
+ @since SketchUp 2017, API 5.0
132
+ @param[in] styles The styles object.
133
+ @param[out] changed Returns true if the active style was changed.
134
+ @related SUStylesRef
135
+ @return
136
+ - \ref SU_ERROR_NONE on success
137
+ - \ref SU_ERROR_INVALID_INPUT if styles is not a valid object
138
+ - \ref SU_ERROR_NULL_POINTER_OUTPUT if changed is NULL
139
+ */
140
+ SU_RESULT SUStylesGetActiveStyleChanged(SUStylesRef styles, bool* changed);
141
+
142
+ /**
143
+ @brief Applies the specified style to the specified scene.
144
+ @since SketchUp 2017, API 5.0
145
+ @param[in] styles The styles object.
146
+ @param[in] style The style to be applied to a scene.
147
+ @param[in] scene The scene to which the style will be applied.
148
+ @related SUStylesRef
149
+ @return
150
+ - \ref SU_ERROR_NONE on success
151
+ - \ref SU_ERROR_INVALID_INPUT if any of styles, style, or scene are not
152
+ valid objects
153
+ */
154
+ SU_RESULT SUStylesApplyStyleToScene(SUStylesRef styles, SUStyleRef style, SUSceneRef scene);
155
+
156
+ /**
157
+ @brief Sets the selected style.
158
+ @since SketchUp 2019.2, API 7.1
159
+ @param[in] styles The styles object.
160
+ @param[in] style The style object.
161
+ @related SUStylesRef
162
+ @return
163
+ - \ref SU_ERROR_NONE on success
164
+ - \ref SU_ERROR_INVALID_INPUT if styles or style are not valid objects
165
+ */
166
+ SU_RESULT SUStylesSetSelectedStyle(SUStylesRef styles, SUStyleRef style);
167
+
168
+ /**
169
+ @brief Delete the selected style. The style will be removed from all scenes
170
+ that use it and then released. The first different style in the style
171
+ manager will replace the style on model pages. The manager must have at
172
+ least one style remaining.
173
+ @since SketchUp 2019.2, API 7.1
174
+ @param[in] styles The styles object.
175
+ @param[in,out] style The style object.
176
+ @related SUStylesRef
177
+ @return
178
+ - \ref SU_ERROR_NONE on success
179
+ - \ref SU_ERROR_INVALID_INPUT if styles is not a valid object
180
+ - \ref SU_ERROR_NULL_POINTER_INPUT if style is NULL
181
+ - \ref SU_ERROR_INVALID_ARGUMENT if style is not within styles
182
+ - \ref SU_ERROR_OUT_OF_RANGE if the style is the last style in the manager
183
+ */
184
+ SU_RESULT SUStylesRemoveStyle(SUStylesRef styles, SUStyleRef* style);
185
+
186
+ #ifdef __cplusplus
187
+ } // extern "C"
188
+ #endif
189
+
190
+ #endif // SKETCHUP_MODEL_STYLES_H_