Skip to content

Commit fe781a0

Browse files
committed
Document --css-based-on-bootstrap, merge "example css" into CssOption
1 parent 8ac79ac commit fe781a0

7 files changed

Lines changed: 37 additions & 462 deletions

src/CommandLine.asciidoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,7 @@ Obsolete name for --link-look=full option.
123123
link:AutoAbstractOption[--auto-abstract]::
124124
Automatically deduce @abstract description of item from 1st sentence of it's full description
125125

126-
link:CssOption[--css]::
126+
link:CssOption[--css, --css-based-on-bootstrap]::
127127
Use the code of your cascading style sheet in replacement of default one.
128128

129129
link:UseTipueSearchOption[--use-tipue-search]::

src/CssOption.asciidoc

Lines changed: 31 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,34 @@
1-
:doctitle: --css command-line option
1+
:doctitle: --css, --css-based-on-bootstrap command-line options
22

3-
By default, pasdoc generates a pasdoc.css file in the generated
4-
documentation in link:HtmlOutput[HTML] and link:HtmlHelp[HtmlHelp]
5-
formats.
3+
## Introduction
64

7-
If you want to use your own style sheet, you can use the
8-
link:CommandLine[CommandLine] option --css=CSS-FILE-NAME. Then pasdoc
9-
will simply copy the given file CSS-FILE-NAME to the output directory as
10-
pasdoc.css.
5+
You can control what your link:HtmlOutput[HTML] and link:HtmlHelp[HtmlHelp]
6+
documentation looks like by tweaking the CSS file.
117

12-
You can find some alternative stylesheets on
13-
link:PasDocCssExamples[PasDocCssExamples].
8+
To use your own style sheet, use the link:CommandLine[CommandLine] option:
9+
10+
- `--css=CSS-FILE` to provide a new CSS file (that does _not_ rely on standard Bootstrap CSS classes, so Bootstrap will not be used in the output).
11+
12+
- `--css-based-on-bootstrap=CSS-FILE` to provide a new CSS file that _does_ rely on standard Bootstrap CSS classes. So Bootstrap will be used in the output.
13+
14+
## Default CSS
15+
16+
The https://github.com/pasdoc/pasdoc/blob/master/source/component/pasdoc.css[default pasdoc.css is here]. Note that it relies on Bootstrap, so if you tweak it, provide the new version using link:Css[--css-based-on-bootstrap] command-line option.
17+
18+
The old `pasdoc.css` that does not rely on Bootstrap is here: https://github.com/pasdoc/pasdoc/blob/master/source/component/alternative_css/pasdoc-up-to-0.16.0.css[source/component/alternative_css/pasdoc-up-to-0.16.0.css]. You can tweak it, and provide the new version using link:Css[--css] command-line option.
19+
20+
## Alternative CSS
21+
22+
We provide some alternative CSS styles in the https://github.com/pasdoc/pasdoc/tree/master/source/component/alternative_css/[source/component/alternative_css/] directory of the PasDoc repository.
23+
24+
Use them directly as a starting point for your own CSS styles.
25+
26+
Examples:
27+
28+
```
29+
pasdoc *.pas -css=source/component/alternative_css/AscanioPressato.css
30+
31+
pasdoc *.pas -css=source/component/alternative_css/ThomasMueller.css
32+
33+
pasdoc *.pas -css=source/component/alternative_css/pasdoc-up-to-0.16.0.css
34+
```

src/HtmlHeadBodyBeginEndOptions.asciidoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ These three command-line options insert custom HTML code to every generated page
88
99
They offer you a lot of possibilities:
1010

11-
* In `--html-head` you can add links to additional CSS files. (Remember that you can also _replace_ the original CSS code using link:CssOption[--css] option.)
11+
* In `--html-head` you can add links to additional CSS files. (Remember that you can also _replace_ the original CSS code using link:CssOption[--css or --css-based-on-bootstrap] options.)
1212
* You can add links to external JavaScript files. Some of them should to `--html-head`, some to `--html-body-end`. Consult the documentation of the particular JavaScript code.
1313
* You can add navigation panel to the top and/or bottom of every page.
1414
* Using both `--html-body-begin` and `--html-body-end` you can wrap the whole PasDoc content in an additional container (like `<div class="pasdoc-container">...</div>`). This can be useful e.g. to style the content selectively, or add a custom sidebar to it.

src/HtmlOutput.asciidoc

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,12 +14,9 @@ Some details about HTML output:
1414

1515
## [[css]] CSS
1616

17-
The look of HTML output is controlled by CSS code in pasdoc.css file,
17+
The look of HTML output is controlled by CSS code in `pasdoc.css` file,
1818
generated by pasdoc while making HTML output. You can customize how your
19-
documentation looks by modifying this file. See
20-
http://www.w3.org/Style/CSS/[W3C resources about CSS]. See also
21-
link:PasDocCssExamples[example alternative CSS styles for pasdoc]
22-
that you can use.
19+
documentation looks by providing your own CSS file using link:CssOption[--css or --css-based-on-bootstrap] command-line options.
2320

2421
## [[html-standard-conformance]] HTML standard conformance
2522

0 commit comments

Comments
 (0)