Fixing a few doc issues, updating DRC doc.

This commit is contained in:
Matthias Koefferlein 2025-08-02 16:19:12 +02:00
parent ffafebcaae
commit 8e95f6a8e1
2 changed files with 35 additions and 5 deletions

View File

@ -1745,18 +1745,18 @@ Class<db::Region> decl_Region (decl_dbShapeCollection, "db", "Region",
"See \\merged_semantics= for a description of this attribute.\n"
) +
method ("join_properties_on_merge=", &db::Region::set_join_properties_on_merge, gsi::arg ("f"),
"@brief Sets a flag indication whether to join properties on merge\n"
"@brief Sets a flag indicating whether to join properties on merge\n"
"\n"
"When this flag is set to true, properties are joined on 'merge'.\n"
"That is: shapes merging into bigger shapes will have their properties joined.\n"
"With the flag set to false (the default), 'merge' will not join properties and return merged\n"
"shapes only if the sub-shapes have the same properties - i.e. properties form\n"
"different classes on merge.\n"
"separate shape classes on merge.\n"
"\n"
"This attribute has been introduced in version 0.30.3."
) +
method ("join_properties_on_merge?", &db::Region::join_properties_on_merge,
"@brief Gets a flag indication whether to join properties on merge\n"
"@brief Gets a flag indicating whether to join properties on merge\n"
"See \\join_properties_on_merge= for a description of this attribute.\n"
"\n"
"This attribute has been introduced in version 0.30.3."
@ -2428,7 +2428,7 @@ Class<db::Region> decl_Region (decl_dbShapeCollection, "db", "Region",
"means that output is only produced if two or more polygons overlap.\n"
"\n"
"The 'join_properties_on_merge' argument indicates how properties should be handled: if true, "
"the properties of the constituents are joined and attached to the merged shape. If false, "
"the properties of the parts are joined and attached to the merged shape. If false, "
"only shapes with the same properties are merged - i.e. different properties form shape classes "
"that are merged individually.\n"
"\n"
@ -2474,7 +2474,7 @@ Class<db::Region> decl_Region (decl_dbShapeCollection, "db", "Region",
"\n"
"\n"
"The 'join_properties_on_merge' argument indicates how properties should be handled: if true, "
"the properties of the constituents are joined and attached to the merged shape. If false, "
"the properties of the parts are joined and attached to the merged shape. If false, "
"only shapes with the same properties are merged - i.e. different properties form shape classes "
"that are merged individually.\n"
"\n"

View File

@ -1774,6 +1774,16 @@ See also <a href="#select_props">select_props</a> and <a href="#remove_props">re
Like <a href="#merged">merged</a>, but modifies the input and returns a reference to the
new layer.
</p>
<a name="merge_props"/><h2>"merge_props" - Merges the layer and joins the properties (modifies the layer)</h2>
<keyword name="merge_props"/>
<p>Usage:</p>
<ul>
<li><tt>layer.merge_props([overlap_count])</tt></li>
</ul>
<p>
Like <a href="#merged_props">merged_props</a>, but modifies the input and returns a reference to the
new layer.
</p>
<a name="merged"/><h2>"merged" - Returns the merged layer</h2>
<keyword name="merged"/>
<p>Usage:</p>
@ -1805,6 +1815,26 @@ The following images show the effect of various forms of the "merged" method:
</tr>
</table>
</p>
<a name="merged_props"/><h2>"merged_props" - Merges and joins properties of the shapes</h2>
<keyword name="merged_props"/>
<p>Usage:</p>
<ul>
<li><tt>layer.merged_props([overlap_count])</tt></li>
</ul>
<p>
Returns the merged input. Unlike the plain <a href="#merged">merged</a> method, this version
will join properties on merged shapes. Properties with the same name
will be merged by computing the maximum value of the parts.
</p><p>
For example:
Properties <tt>{ "A" =&gt; 17, "C" =&gt; 2.5 } </tt>merged with <tt>{ "A" =&gt; 1, "B" =&gt; "a text" } </tt>will give
<tt>{ "A" =&gt; 17, "B" =&gt; "a text", "C" =&gt; 2.5 } </tt>.
</p><p>
The plain <a href="#merged">merged</a> method will treat shapes with different properties as
separate entities and will not merge them.
</p><p>
Currently, this method is available for polygon layers only.
</p>
<a name="middle"/><h2>"middle" - Returns the center points of the bounding boxes of the polygons</h2>
<keyword name="middle"/>
<p>Usage:</p>