Skip to content

Commit fdea1aa

Browse files
committed
Some edits to TEMPLATE-STYLE.md.
1 parent c946190 commit fdea1aa

File tree

1 file changed

+25
-1
lines changed

1 file changed

+25
-1
lines changed

docs/TEMPLATE-STYLE.md

Lines changed: 25 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,30 @@ is the naming convention for these files:
1717
Where *brand* is the lowercase brand name, and *class* is the media size class (currently
1818
`iso`, `us`, and `other`).
1919

20+
Templates should be sorted in [natural order](https://en.wikipedia.org/wiki/Natural_sort_order)
21+
by part number within each file. An exception to this rule is to group equivalent templates
22+
directly below their referenced template. For example:
23+
24+
```xml
25+
<Template brand="Avery" part="5126" size="US-Letter" _description="Shipping labels">
26+
<Meta category="label"/>
27+
<Meta category="rectangle-label"/>
28+
<Meta category="mail"/>
29+
<Label-rectangle id="0" width="8.5in" height="5.5in" round="0in" x_waste="0in" y_waste="0in">
30+
<Markup-margin size="9pt"/>
31+
<Layout nx="1" ny="2" x0="0in" y0="0in" dx="0in" dy="5.5in"/>
32+
</Label-rectangle>
33+
</Template>
34+
35+
<Template brand="Avery" part="5526" equiv="5126"/>
36+
<Template brand="Avery" part="8126" equiv="5126"/>
37+
<Template brand="Avery" part="15516" equiv="5126"/>
38+
<Template brand="Avery" part="18126" equiv="5126"/>
39+
40+
41+
<Template brand="Avery" part="5159" size="US-Letter" _description="Address labels">...
42+
```
43+
2044
When creating a new template file, it must be added to the variable template_files in
2145
the [CMakeLists.txt](../templates/CMakeLists.txt) file in this same directory.
2246

@@ -67,7 +91,7 @@ is acceptable. For example:
6791
The following are good bad descriptions:
6892

6993
| description | Good/Bad | Notes |
70-
|:-------------------------|:---------|:----------------------------------------------|
94+
|:-------------------------|:--------:|:----------------------------------------------|
7195
| `Address labels` || |
7296
| `Address Labels` || Capitalized second word of description. |
7397
| `Business cards` || |

0 commit comments

Comments
 (0)