mirror of https://github.com/KLayout/klayout.git
Merge pull request #674 from KLayout/issue-670
Documentation clarification regarding properties in gds/oasis formats
This commit is contained in:
commit
ae42b03e3a
|
|
@ -1809,6 +1809,7 @@ Class<db::Cell> decl_Cell ("db", "Cell",
|
|||
"If no property with that key exists, it will create one. Using that method is more "
|
||||
"convenient than creating a new property set with a new ID and assigning that properties ID.\n"
|
||||
"This method may change the properties ID. "
|
||||
"Note: GDS only supports integer keys. OASIS supports numeric and string keys. "
|
||||
"\n"
|
||||
"This method has been introduced in version 0.23."
|
||||
) +
|
||||
|
|
@ -3821,6 +3822,7 @@ Class<db::Instance> decl_Instance ("db", "Instance",
|
|||
"If no property with that key exists, it will create one. Using that method is more "
|
||||
"convenient than creating a new property set with a new ID and assigning that properties ID.\n"
|
||||
"This method may change the properties ID. "
|
||||
"Note: GDS only supports integer keys. OASIS supports numeric and string keys. "
|
||||
"Calling this method may invalidate any iterators. It should not be called inside a "
|
||||
"loop iterating over instances.\n"
|
||||
"\n"
|
||||
|
|
|
|||
|
|
@ -1038,12 +1038,13 @@ Class<db::Layout> decl_Layout ("db", "Layout",
|
|||
"This method has been introduced in version 0.24."
|
||||
) +
|
||||
gsi::method_ext ("set_property", &set_layout_property,
|
||||
"@brief Set the user property with the given key to the given value\n"
|
||||
"@brief Sets the user property with the given key to the given value\n"
|
||||
"@args key, value\n"
|
||||
"This method is a convenience method that sets the property with the given key to the given value. "
|
||||
"If no property with that key exists, it will create one. Using that method is more "
|
||||
"convenient than creating a new property set with a new ID and assigning that properties ID.\n"
|
||||
"This method may change the properties ID. "
|
||||
"Note: GDS only supports integer keys. OASIS supports numeric and string keys. "
|
||||
"\n"
|
||||
"This method has been introduced in version 0.24."
|
||||
) +
|
||||
|
|
|
|||
|
|
@ -1292,6 +1292,7 @@ Class<db::Shape> decl_Shape ("db", "Shape",
|
|||
"If no property with that key exists, it will create one. Using that method is more "
|
||||
"convenient than creating a new property set with a new ID and assigning that properties ID.\n"
|
||||
"This method may change the properties ID. "
|
||||
"Note: GDS only supports integer keys. OASIS supports numeric and string keys. "
|
||||
"Calling this method will invalidate any iterators. It should not be called inside a "
|
||||
"loop iterating over shapes.\n"
|
||||
"\n"
|
||||
|
|
|
|||
|
|
@ -473,6 +473,13 @@ shape.set_property(1, "NewValue")</pre>
|
|||
and "delete_property" also are provided for cells and cell instances (<class_doc href="Cell"/> and <class_doc href="Instance"/>).
|
||||
</p>
|
||||
|
||||
<p>
|
||||
<b>Note:</b> The GDS format does not have string names for properties. As a result GDS only supports numeric property keys.
|
||||
OASIS, on the other hand, can handle string and numeric property "names". When saving layouts in GDS format, KLayout tries
|
||||
to convert the properties' names into numbers if possible (i.e. if it sees that the string is a number). If it can't, then
|
||||
the property is not saved. When the layout is read by KLayout upon opening, it gets converted to integer.
|
||||
</p>
|
||||
|
||||
<h2>The LayerInfo class</h2>
|
||||
|
||||
<keyword name="LayerInfo"/>
|
||||
|
|
|
|||
Loading…
Reference in New Issue