Attributes: Difference between revisions
m (") |
mNo edit summary |
||
(One intermediate revision by the same user not shown) | |||
Line 7: | Line 7: | ||
Scribus provides a document's attributes manager : goto '''File > Preferences... > Document Item Attributes'''. | Scribus provides a document's attributes manager : goto '''File > Preferences... > Document Item Attributes'''. | ||
Attributes are a build'in way to [[Creating_a_Table_of_Contents|create an automatic Table of Content]], and it's possible to use attributes for user-scripted purposes. | |||
== Scripting with attributes == | == Scripting with attributes == |
Latest revision as of 19:50, 25 September 2021
Some items like text-frames or image-frames have a tool for "Attributes" with Name, Type, Value, Parameter, Relationship and Relationship to as possible columns.
"Attributes" of objects is one of the most powerful features of Scribus and will enable the development of automated newsroom systems.
Attributes is a list of dictionary entries. Each entry must have those keys: Name, Type, Value, Parameter, Relationship, RelationshipTo, AutoAddTo. All values must be strings.
Scribus provides a document's attributes manager : goto File > Preferences... > Document Item Attributes.
Attributes are a build'in way to create an automatic Table of Content, and it's possible to use attributes for user-scripted purposes.
Scripting with attributes
You can manipulate attributes with Scribus Scripter's Python commands:
- `setObjectAttributes(attributes, ["name"])` : Sets attributes of the object "name". If "name" is not given the currently selected item is used.
- `getObjectAttributes(["name"])` : Returns a list containing all attributes of object "name". If "name" is not given the currently selected Item is used.
Any further contribution to this page is wellcome