This feature is available only in SketchUp Pro.
Use these predefined attributes to create your dynamic components.
X, Y, Z
The X, Y, and Z attributes store the component's X (red), Y (green), or Z (blue) coordinate.
LenX, LenY, LenZ
The LenX, LenY, and LenZ attributes store the component's length in the X (red), Y (green), or Z (blue) direction.
RotX, RotY, RotZ
The RotX, RotY, and RotZ attributes store the rotation about the X, Y, or Z axis, in degrees.
Hidden
The Hidden attribute stores 1 (TRUE) to hide the component or 0 (FALSE) to show it.
Copies
The Copies attribute sets how many copies of the component SketchUp creates. Each copy starts at the original component's exact X, Y, and Z coordinates. You usually use Copies with the Copy attribute.
Copy
The Copy attribute stores the number of a specific copy. If Copies equals 3, Copy can contain 0 through 3, with 0 representing the original. You generally use Copy as a variable in formulas to refer to a specific copy, usually to position it at different X, Y, and Z coordinates. For example, to position fence pickets horizontally along the X axis, use this formula for X: =5+Copy*(Fence!spacing+LenX).
=5+Copy*(Fence!spacing+LenX)
If 'Fence!spacing' is 4" and the picket's width (LenX) is 2.5", the formula gives an X value of 5" for the original component (5+0*(4+2.5)). It gives 11.5 for the first copy (5+1*(4+2.5)), 18 for the second copy (5+2*(4+2.5)), and so on for each copy.
(5+0*(4+2.5))
11.5
(5+1*(4+2.5))
18
(5+2*(4+2.5))
You can see component copies only in Outliner (Window > Outliner). They do not appear in the Component Attributes dialog box, so you cannot view a copy's attribute/value pairs.
Name
The Name attribute sets the component name shown in the Component Options dialog box.
Summary
The Summary attribute stores a brief summary of the component in one sentence for the Component Options dialog box.
Description
The Description attribute stores a longer description of the component for the Component Options dialog box.
ItemCode
The ItemCode attribute stores the manufacturer's item code for the product your dynamic component represents.
ImageURL
The ImageURL attribute stores the address of an online GIF, JPG, or PNG file to show in the Component Options dialog box. For example, setting ImageURL to http://mysite.com/myimage.gif displays 'myimage.gif' in place of the SketchUp-generated thumbnail.
http://mysite.com/myimage.gif
DialogWidth
The DialogWidth attribute stores the width of the Component Options dialog box in pixels.
DialogHeight
The DialogHeight attribute stores the width of the Component Options dialog box in pixels.
onClick
The onClick attribute stores a simple script that controls what happens when you click the component with the Interact tool. For example, alert("Hello World"); displays an alert box when you click the component. See 'onClick functions' for more information.
alert("Hello World");
Material
The Material attribute sets the material to apply to the component. You can specify it in these formats:
- Use a named colour, such as 'Blue'. See the Ruby API docs for the complete list of colours.
- Use a hexadecimal string, such as '#FFFF00' or '3399A0'. The # is optional.
- Use a list of three RGB values between 0 and 255. For example, 255, 128, 0.
- Use a material name from the InModel material list. Your dynamic component must contain a tiny swatch of that material somewhere on the component. The material must also have a custom name. For example, '0002_HotPink' only works if you rename it to '0002_MyHotPink'.