Académique Documents
Professionnel Documents
Culture Documents
Style Library Overview for Autodesk Inventor Transitioning to Style Libraries in Autodesk Inventor
The overview provides a general picture of what Style Libraries are and how they are used. The transition guide overviews the steps and tools used to prepare an existing project to use a Style Library.
Style Libraries a group of predefined XML files that Autodesk Inventor projects
actively reference
Exported styles one or more files with the extension .styxml, used to share
stylesbetween documents outside of a Style Library Note: Autodesk does not support the editing or use of these XML files outside of the tools provided inside Autodesk Inventor and the stand-alone tools: the Style Library Manager and Styles Management Wizard. Any manual edits to these files may result in corruption of data and render the files unusable by Autodesk Inventor.
XML Schema
The schema of the Autodesk Inventor Style Library XML files is subject to change from release to release.
Style Name/Value
Autodesk Inventor uses the style name as the unique style identifier. No two styles of the same type can have the same name in the same container. For example, inside a single drawing, there can only be one dimension style named Default (ANSI). However, there can be a dimension style named Default (ANSI), and a text style name Default (ANSI) in the same drawing, because they are two different style types. When Autodesk Inventor compares two styles of the same name, it checks all of the properties in each style to see if they are equal. This comparison is a value comparison. If a style in a document has a name match to a style in a library, and the values of these two styles are equal (every attribute is the same value), this is considered an exact Name/Value match. The concept of a Name/Value match is used by Autodesk Inventor to perform automated tasks
Substyles
Styles are a means of encapsulating and reusing sets of properties inside of Autodesk Inventor. Autodesk Inventor takes advantage of this encapsulation to reuse one type of property set as a subset of another. This is evident where one style references another style that contains needed information. When a style is referenced by another style, it is regarded as a substyle. For example, dimension styles have three substyles:
Primary Text Style: used to format the primary units in a dimension. Tolerance Text Style (optional): used to format the tolerances units. Leader Style: used to format Hole Notes and Leader Notes.
A style only knows the name of its substyle. It knows nothing about the values of the properties contained in the substyle. When Autodesk Inventor checks if a style in one container (a document or a Style Library) is an exact Name/Value match to a style in another container, it verifies that each style is referencing a substyle of the same name. A Name/Value match between the substyles is not necessary for the owning style to have an exact Name/Value match. When a style is copied from one container to another, Autodesk Inventor ensures that any substyle required by the parent style is present in the destination container. If the substyle does not exist in the destination container, it is copied along with the parent style. If the substyle does exist, the destinations version of the substyle is used.
The document version of a style always overrides. If a style is in both a document and a
library, and the two do not have the same values, the version in the document is used. Editing styles always takes place inside of a document. The Style Library cannot be edited directly.
In drawings, styles are filtered by the active standard. Each standard has a list of
Available Styles (found on the Available Styles tab of the Standard edit window). These styles appear at the top of the Styles drop-down list of drawing documents as well as style editors that reference a substyle. Note: These are not the only styles that can be used in the document. of a library to be used in a document
Any style cached in a document is available for use. This allows styles that are not part
The style was copied by Autodesk Inventor automatically into the document. The style is not used by any other object or is a substyle of any other style in the
document
Editing and Creating Styles The most common task involving the direct management of styles is either editing an existing style or creating a new style. Styles are always edited or created inside an Autodesk Inventor document (part, assembly, drawing, or presentation). Styles are edited in the style editor, even if the style has not yet been copied into the document. Styles are automatically copied from the library into a document for edit.Since the Style Library cannot be edited directly, an edited or newly created style must be saved to the library from a document. To save a style to a library:
Right-click the style in the Style Editor, and select Save to Style Library Select Save Styles to Style Library from the Format menu in Autodesk Inventor.
Saving a style to a library only saves its substyles if they do not exist in the library. If a substyle already exists, it must be saved explicitly to replace the library definition. Substyles are saved to a library with the referencing style using the Format > Save Styles to Style Library command. Renaming Styles Inside the Style Editor, a style is renamed by right-clicking on the style name, and selecting Rename Cached Style. Renaming a style in the editor only affects the documents copy of a style. The library copy of a style is never affected by this function. There are two effects of renaming a cached style:
All objects using the old style, and all locally cached styles using the old style as a
substyle, now use the renamed style.
Once a style is renamed, it looses any link to a Style Library (is considered to have no
match to a style in a library), unless its name is changed to a name that matches another style in the library itself.
A locally cached style cannot be renamed to the same name as a style that is already cached. For example, if two material styles, one named Aluminum and another named Aluminum 6061, exist in a document, Aluminum cannot be renamed to be Aluminum 6061. However, if Aluminum is in a document, and a material style named Aluminum 7075 existed in the current library, Aluminum can be renamed to Aluminum 7075, since Aluminum 7075 didnt already exist inside the document
No active link is made to an exported style file, meaning there is no update style
mechanism for exported styles.
On Import, any style of the same name is automatically overwritten by the imported
styles values. When updating from a Style Library, replacing styles and substyles must be confirmed or done explicitly by the user. The *.styxml file is a self contained file that includes all substyles required by exported styles. A Style Library keeps each type of style in a distinct, separate XML file. See the Style Library Contents section on page 7 for more details on the file structure of a Style Library
Updating Styles
When a style changes in a library, that change is consumed by all documents using that style by performing a style update. Updating a style from the library is always manual, and is done in one of two ways:
From Autodesk Inventor Menu, click Format > Update Styles From Style Editor, click the styles, right-click and select Update Style
Under certain conditions additional confirmations may be requested in order to update a style. This primarily happens when the style was edited locally in the document. Updating a style is always a manual process and must be initiated by the user. Updating a style does not update its substyles. Substyles must be updated separately. Substyles are updated simultaneously with the referencing style using the Format > Update Styles command
From the Autodesk Inventor menu, click Format > Purge Styles. This purge focuses on
or all styles in the current document. Unused styles and substyles are purged in a single operation. From the Style Editor: click a style, right-click and select: Purge Style to remove only the selected style.
Purge Style & Substyle to remove the selected style and all of its substyles.
Note about substyles and manual removal from a document: If a style cannot be purged from a document, check the following to verify if a style is referenced by:
An object (sketch geometry or sketch text in Drawing Resources) Any Standard cached in a drawing. The style may be referenced as an Available Style. Any Object Default style cached in a drawing. Object Defaults can be set to use styles
that are not Available Styles in a standard.
The default styles that are defined for each document type are:
Drawings: Standard. Parts/Weldments: Lighting, Material. (Material is set in the Weld Properties. Right-click
the Weld browser node, select Properties, and then the Physical tab.)
Assemblies/Presentations: Lighting. Sheet Metal: Lighting, Material. (The Default material is set by the active Sheet Metal
style in the template.) Note: Weldments also have a Standard setting on their Active Standard tab. This is not the same as the Standard style used by drawings. This is one of six international standards (ANSI, ISO, DIN, BSI, JIS, or DIN) that define how the weld features are characterized.
When a new document is created, the styles for that document are pulled from the Style Library. However, styles in a template that are not in the library are added to the new document as well
Since the names of the XML files must be the same for each Style Library, only one library can exist in a directory. To be considered a valid Style Library, all predefined XML files must be present in the directory. If any of the XML files are missing, an error message is displayed. See Incomplete Style Libraries below for more detail. Note: An exported style file (*.styxml) cannot be used as part of a Style Library.
Creation of new Style Libraries Simple style management inside of Style Libraries Management of styles between multiple Style Libraries
Create an empty Style Library: Select the Create Empty Style Library option in the dialog box, and specify the target directory for the Style Library. Once created, the new Style Library appears in the Style Library 2 pane of the Style Library Manager. With either creation method, the target directory for the new library cannot have a Style Library already present. After creation, styles are added or removed using the Style Library Manager. Styles are also added or edited using the Style Editor in Autodesk Inventor.
Set the project Use Style Library option to Read Only. Use a Microsoft Windows file property setting. In Microsoft Windows Explorer, select all
the XML files that make up the library or the library directory folder itself, right-click, select Properties, and set to Read Only.
In Autodesk Inventor, both methods are treated identically when accessing Style Libraries. If a single XML file is read-only, the entire library is treated as read-only. An administrator can have two versions of a project file. One is for users (Use Style Library = Read Only), which prevents changes, and one is for administrators (Use Style Library = Yes), to actively edit the library without dealing with the individual Windows file properties of each XML file. For many workgroup setups, this may be sufficient for management of Style Libraries. The project file option has the disadvantage that any interaction done outside Autodesk Inventor treats the Style Library as read/write. This includes the Style Library Manager, which works with library files outside the context of an Autodesk Inventor project. The Style Library Manager only references project files as a shortcut to the XML files.
Get, Check in, and Check Out must be done through the Vault Explorer. through the file properties, just as Vaulted Style Library XML files are set to read-only rd If editing the Style Library is required, all XML files must be checked out.
any standard Autodesk Inventor file or any other 3 party file that is vaulted manually.
Keep all working Style Libraries as read-only to prevent accidental changes. Use a parent/child Style Library scheme.
The parent is a library unused by any active project. All project Style Libraries are considered children. The administrator makes all changes in the parent version. Push changes to a child by copying the styles from the parent version using the Style Library Manager. Try to reuse styles if possible. Most users utilize the same Material, Color, and Lighting styles, even if they require a different set of drawing-related styles. For management of drawing related styles, give the primary Standard and its Object Defaults unique names for each project. Reuse Dimensions, Text, and Layers as much as possible.
Pack and Go
The Autodesk Inventor Pack and Go utility optionally includes a Style Library. By default, a projects Style Library is included in the target directory created by Pack and Go. This is true even if the default library is used, because the recipients default library may differ from the one used by your project(s). The packed Style Library is included in the Pack and Go project in a subdirectory called Design Data. The Pack and Go project file has the Use Style Library setting the same as the original project, but its Style Library folder option is set explicitly to the Pack and Go location of the packed up Style Library.
Autodesk and Autodesk Inventor are trademarks or registered trademarks of Autodesk, Inc., in the USA and/or other countries. All other brand names, product names, or trademarks belong to their respective holders. Autodesk reserves the right to alter product offerings and specifications at any time without notice, and is not responsible for typographical or graphical errors that may appear in this document. 2005 Autodesk, Inc. All rights reserved.
www.autodesk.com