Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update theme wiki #594

Merged
merged 27 commits into from
Feb 16, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
27 commits
Select commit Hold shift + click to select a range
6702203
Pull changes from wiki subrepo to resources/theme
infotexture Jan 10, 2025
8e4c771
Remove redundant page size example
infotexture Jan 10, 2025
e7f8538
Move header and footer examples from How-to
infotexture Jan 10, 2025
21d22b3
Move background image syntax example to Styles
infotexture Jan 10, 2025
105155e
Push changes from resources/theme to wiki subrepo
infotexture Jan 12, 2025
599e251
Pull changes from wiki subrepo to resources/theme
infotexture Jan 12, 2025
d69f34f
Pull changes from wiki subrepo to resources/theme
infotexture Jan 14, 2025
e192366
Pull changes from wiki subrepo to resources/theme
infotexture Jan 25, 2025
499ba0e
Pull changes from wiki subrepo to resources/theme
infotexture Jan 26, 2025
ae4cae8
Split block & inline styles to separate pages
infotexture Jan 26, 2025
2c8e5d0
Add block & inline topics as Styles subtopics
infotexture Jan 26, 2025
8b7701d
Set subrepo parent SHA to last subrepo pull
infotexture Jan 26, 2025
b3057fa
Push changes from resources/theme to wiki subrepo
infotexture Jan 26, 2025
bc782a0
Preserve tabs in git-subrepo config
infotexture Feb 1, 2025
1676572
Pull changes from wiki subrepo to resources/theme
infotexture Feb 1, 2025
b042887
Use YAML syntax for property listings
infotexture Feb 1, 2025
82c0c3a
Align Boolean value descriptions
infotexture Feb 1, 2025
8716d5e
Use <n> convention for number placeholders
infotexture Feb 1, 2025
b938f81
Edit menucascade separator description
infotexture Feb 1, 2025
c477080
Add curly braces to variable listings
infotexture Feb 1, 2025
e4e940b
Push changes from resources/theme to wiki subrepo
infotexture Feb 1, 2025
2f1db2c
Pull wiki subrepo to `resources/theme`
infotexture Feb 14, 2025
08c792f
Sort block styles alphabetically
infotexture Feb 14, 2025
b148ba1
Remove unused block reference from inline styles
infotexture Feb 14, 2025
95a789c
Sort inline styles alphabetically
infotexture Feb 14, 2025
14f5e88
Move shared XSL-FO extension properties → Styles
infotexture Feb 14, 2025
5e0c35f
Push `resources/theme` to wiki subrepo
infotexture Feb 14, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,6 @@ trim_trailing_whitespace = true
[*.md, *.mdown, *.markdown]
trim_trailing_whitespace = false

[.git/config]
# Prevent mixed indentation in Git config (Git commands insert tabs)
[.git/config, **/.gitrepo]
# Prevent mixed indentation (Git commands & git-subrepo insert tabs)
indent_style = tab
2 changes: 2 additions & 0 deletions resources/source-files.ditamap
Original file line number Diff line number Diff line change
Expand Up @@ -232,8 +232,10 @@
<keydef keys="parameters-xhtml" href="../parameters/parameters-xhtml.dita"/>

<!-- PDF Plug-in Generator wiki (cloned as subrepo to `resources/theme`) -->
<keydef format="wikidocs" keys="block-styles" href="../resources/theme/Block-styles.md"/>
<keydef format="wikidocs" keys="extending-themes" href="../resources/theme/Extending-themes.md"/>
<keydef format="wikidocs" keys="header-and-footer" href="../resources/theme/Header-and-footer.md"/>
<keydef format="wikidocs" keys="inline-styles" href="../resources/theme/Inline-styles.md"/>
<keydef format="wikidocs" keys="page-settings" href="../resources/theme/Page-settings.md"/>
<keydef format="wikidocs" keys="styles" href="../resources/theme/Styles.md"/>
<keydef format="wikidocs" keys="syntactic-sugar" href="../resources/theme/Syntactic-sugar.md"/>
Expand Down
6 changes: 3 additions & 3 deletions resources/theme/.gitrepo
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
[subrepo]
remote = https://github.com/jelovirt/pdf-generator.wiki.git
branch = master
commit = 21ed9c285776ee1711a6b83e5a241f35b0590e7a
parent = 3a35331db3f1f2b47ef9479d6c2463cca8c98a67
commit = 19c02c94998210c2ab06ebcc7519a45befffbe17
parent = 14f5e88d7753493033681948b2de04d76097ced3
method = merge
cmdver = 0.4.6
cmdver = 0.4.9
273 changes: 273 additions & 0 deletions resources/theme/Block-styles.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,273 @@
The presentation of block elements can be adjusted by setting `style` keys. Block keys support styling properties from [XSL fo:block] and [XSL extensions].

## Block keys

### `appendix`

Appendix title.

<!--
- `title-numbering: 'true' | 'false'`
-->

### `appendix-toc`

Appendix table of contents.

- `maximum-level: <n>` — Number of TOC levels to show

### `appendix-toc-<n>`

TOC entry in appendix TOC. `<n>` is a number ranging from 1 to 6, representing each of the six TOC entry levels.

### `body`

Default body text, for example `<p>` elements.

### `chapter`

Chapter title.

- `title-numbering: 'true' | 'false'`

### `chapter-toc`

Chapter table of contents.

- `maximum-level: <n>` — Number of TOC levels to show

### `chapter-toc-<n>`

TOC entry in chapter TOC. `<n>` is a number ranging from 1 to 6, representing each of the six TOC entry levels.

### `codeblock`

Code block element.

- `line-numbering: 'true' | 'false'` — Line numbering.
- `show-whitespace: 'true' | 'false'` — Show whitespace characters.

### `cover`

Cover page.

### `cover-title`

Cover page title.

- `content: content-template`

### `cover-titlealt`

Cover page subtitle or alternative title.

### `dl`

Definition list element.

- `dl-type: 'table' | 'list' | 'html'` — Style definition list as bulleted list or indented list.

### `example`

Example element.

### `example-title`

Example element title.

### `fig`

Figure element.

- `caption-number: 'chapter' | 'document'` — Number figures with chapter prefix or use whole document numbering.
- `caption-position: 'before' | 'after'` — Place figure caption before or after figure.

### `fig-caption`

Figure caption.

- `content`: Contents of figure caption. Supported fields are:
- `number`: caption number
- `title`: caption contents

### `glossary`

Glossary title.

### `h<n>`

Topic titles. `<n>` is a number ranging from 1 to 6, representing each of the six heading levels.

- `title-numbering: 'true' | 'false'`

### `hazardstatement`

Hazard statement element.

### `hazardstatement-label`

Hazard statement label element.

### `hazardstatement-<type>-label`

Label for hazard statement elements with `@type`.

### `index`

Index title.

### `note`

Note element with `@type` `note` or without `@type`.

### `note-label`

Label for note elements.

- `content` — Content template.

### `note-<type>`

Note element with `@type`. Type values are:

- `note`
- `tip`
- `fastpath`
- `restriction`
- `important`
- `remember`
- `attention`
- `caution`
- `notice`
- `danger`
- `warning`
- `trouble`
- `other`

To add an image to a note, use the `background-image` property.

```yaml
style:
note-other:
background-image: legal.svg
background-repeat: no-repeat
# image width plus padding
padding-start: 60pt + 1em
# image width plus parent indentation
start-indent: 60pt + from-parent(start-indent)
```

### `note-<type>-label`

Label for note elements with `@type`.

- `content` — Content template.

### `ol`

Ordered list.

### `parml`

Parameter list element.

### `part`

Part title.

- `title-numbering: 'true' | 'false'`

### `part-toc`

Part table of contents.

- `maximum-level: <n>` — Number of TOC levels to show

### `part-toc-chapter`

Bookmap chapter TOC entry in part TOC.

### `part-toc-<n>`

TOC entry in part TOC. `<n>` is a number ranging from 1 to 6, representing each of the six TOC entry levels.

### `pd`

Parameter definition element within a parameter list entry.

### `plentry`

Parameter list entry element.

### `pre`

Preformatted element.

### `pt`

Parameter term element within a parameter list entry.

### `section`

Section element.

### `section-title`

Section element title.

### `shortdesc`

Short description and abstract styles.

### `table`

Table element.

- `caption-number: 'chapter' | 'document'` — Number figures with chapter prefix or use whole document numbering.
- `caption-position: 'before' | 'after'` — Place figure caption before or after figure.
- `table-continued: 'true' | 'false'` — Output "table continued" when table breaks across pages.

### `table-caption`

Table caption.

- `content: content-template` — Contents of table caption. Supported fields are:
- `number`: caption number
- `title`: caption contents

### `table-header`

Table header row

### `task-labels`

Boolean key to generate default section labels for tasks.

### `toc`

Table of contents.

- `maximum-level: <n>` — Number of TOC levels to show

### `toc-appendix`

Bookmap appendix TOC entry.

### `toc-chapter`

Bookmap chapter TOC entry.

### `toc-part`

Bookmap part TOC entry.

### `toc-<n>`

TOC entry in main TOC. `<n>` is a number ranging from 1 to 6, representing each of the six TOC entry levels.

### `ul`

Unordered list.

[XSL fo:block]: https://www.w3.org/TR/xsl11/#fo_block
[XSL extensions]: ./Styles.md#xsl-fo-extension-properties
4 changes: 3 additions & 1 deletion resources/theme/Extending-themes.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
A theme can extend another theme using the `extends` key. The value of `extends` is a relative path from the current theme file to the theme being extended.
A theme can extend another theme using the `extends` key.

If the value is `default`, it resolves to the built-in default theme. Otherwise the value of `extends` is a relative path from the current theme file to the theme being extended. If a theme doesn't have an `extends` key, default PDF2 plug-in styles are used.

`base.yaml`

Expand Down
Loading
Loading