aboutsummaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* devbook.xsl: Use self-closing tags when possibleUlrich Müller2024-07-301-22/+22
| | | | | | | This makes no difference for the HMTL output, i.e. xsltproc will expand <foo/> to <foo></foo>. Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl: Rename parameter of repeat-string templateUlrich Müller2024-06-101-6/+6
| | | | Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl: Use abbreviated CC-BY-SA-4.0 in footerUlrich Müller2024-05-071-1/+1
| | | | | | This agrees with the footer in other gentoo.org sites. Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl: Add Gentoo e.V. to page footerUlrich Müller2024-03-231-1/+1
| | | | | Bug: https://bugs.gentoo.org/927555 Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl: Add sub and sup elementsUlrich Müller2024-02-081-0/+8
| | | | | | | These were present in GuideXML: https://gitweb.gentoo.org/proj/devmanual.git/tree/appendices/contributing/devbook-guide/text.xml?id=8be0d382fb82dc4cfe73b1b85bb7fc3c923a21c7#n397 Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* Update copyright yearsUlrich Müller2024-01-191-1/+1
| | | | Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl: Use same test for eclass pages everywhereUlrich Müller2023-11-231-4/+4
| | | | | | Drop relative_path_depth variable which is no longer used. Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl: Manipulate paths in getLastNode consistentlyUlrich Müller2023-11-051-5/+5
| | | | | | | Directory paths are used everywhere else, so append text.xml only when actually accessing the file. Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl: Fix links created by contentsTree extractionUlrich Müller2023-11-021-3/+15
| | | | | | | | | | | | | If the element that is extracted from the external document contains internal references, these links would be relative to the wrong start location, namely the one defined in that document. Therefore, define our own copy of /guide/@self (pointing to the location of the target document), and rebase the tree onto it. This fixes the intra-document links in appendices/todo-list/. Closes: https://bugs.gentoo.org/916523 Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl: Use hexadecimal for character entitiesUlrich Müller2023-11-021-3/+3
| | | | Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl: Replace str:repeatString by a non-recursive versionUlrich Müller2023-10-311-22/+10
| | | | | | | Also rename the template to repeat-string, i.e. move it out of the str namespace. Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl: Update the findNext template for relative linksUlrich Müller2023-10-311-23/+9
| | | | | | Create relative links with correct depth. Some other simplifications. Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl: Warn about missing terminating slash in internal linksUlrich Müller2023-10-301-1/+4
| | | | Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl: Drop unused class parameter from uri templateUlrich Müller2023-10-301-7/+6
| | | | Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl: Rewrite the uri templateUlrich Müller2023-10-301-61/+71
| | | | | | | Create relative links with correct depth. Assign some variables, instead of computing things multiple times. Simplify. Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl: Work around a bug in tidyUlrich Müller2023-10-221-1/+11
| | | | | | | | | | | tidy reports spurious warnings due to a bug in version tidy-html5-5.8.0: https://github.com/htacg/tidy-html5/issues/1012 line 128 column 1 - Warning: <ol> attribute "type" not allowed for HTML5 Work around it by using "ol style" instead of "ol type". Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl: Support type and start attributes for ordered listsUlrich Müller2023-10-221-1/+6
| | | | | | Simply copy them to the HTML output. Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl: Force end tag for empty li elementsUlrich Müller2023-10-221-2/+2
| | | | | | | | | In order to make "tidy" happy. For some reason, xsltproc omits the end tag if the element is empty. Apparently, an empty comment is enough to make it think differently. Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl: WhitespaceUlrich Müller2023-10-051-3/+3
| | | | | Fixes: 19153057c1dbbc3537dfc9d1ca20a12d69a46c81 Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl, bin/gen-eclass-html.sh: Link to privacy policyUlrich Müller2023-10-051-0/+3
| | | | | Bug: https://bugs.gentoo.org/613938 Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* Update copyright yearsUlrich Müller2023-01-211-1/+1
| | | | Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl: Fix whitespace in <note> and friendsUlrich Müller2022-06-221-4/+4
| | | | Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl: Eclass documentation needs GPL-2 in the footerUlrich Müller2022-06-101-1/+9
| | | | | | | Eclasses are licensed GPL-2, therefore we need a different footer. Hardcode this for all sub-pages of eclass-reference/. Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* Update copyright yearsUlrich Müller2022-03-261-1/+1
| | | | Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl: Support alignment of table cellsUlrich Müller2022-01-191-9/+17
| | | | | | | The "align" attribute is documented in the DevBook XML Guide, but was not implemented in the XSL stylesheet. Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl: td doesn't have a nowrap attribute in HTML 5Ulrich Müller2021-10-101-1/+1
| | | | | | Problem seen with tidy from app-text/htmltidy-5.8.0-r1. Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* Automatically generate the author list on the homepageUlrich Müller2021-09-081-1/+11
| | | | | | | Contributors are listed in appendices/contributors/, so we can take the information from there without maintaining duplicate lists. Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl: Drop unused variable in findNext and findPreviousUlrich Müller2021-03-101-6/+0
| | | | Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl: Properly declare HTML 5 outputUlrich Müller2021-03-101-3/+1
| | | | | | | | | | Instead of hand-crafting a DOCTYPE line. libxslt-1.1.30 and later support version="5" for the html output method. Drop indent="yes" and omit-xml-declaration="yes" because they are the defaults anyway. Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl: Drop unnecessary xsl:text elementsUlrich Müller2021-03-101-1/+1
| | | | Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl: concat can take more than two argumentsUlrich Müller2021-03-101-1/+1
| | | | Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl: Indent consistently and other whitespace fixesUlrich Müller2021-03-101-538/+590
| | | | Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl: Simplify section templateUlrich Müller2021-03-101-4/+2
| | | | Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl: Specify line length for EmacsUlrich Müller2021-03-071-0/+1
| | | | | | | The Emacs default of 70 is definitely to small for this file, but 200 won't fit on my laptop screen. :) So, make it moderately larger. Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl: Split some very long lines for better readabilityUlrich Müller2021-03-031-8/+35
| | | | Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl, devmanual.css: Add permalinks to section headersUlrich Müller2021-02-251-1/+5
| | | | | | | | | | | While we use empty fragments ("#") elsewhere for navigation within the document (because they don't cause reloading of the page), we use an empty href ("") for the chapter because it is meant to be copied as an external link. Closes: https://bugs.gentoo.org/772005 Suggested-by: Sam James <sam@gentoo.org> Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl: Remove code duplication in section templatesUlrich Müller2021-02-251-38/+16
| | | | | | HTML output is identical. Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl: Drop unused findParent templateUlrich Müller2021-02-241-11/+0
| | | | | | This has been superseded by printParentDocs some time ago. Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* Update copyright yearsUlrich Müller2021-01-031-1/+1
| | | | Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl: Bring admonitions in line with the wiki.Ulrich Müller2020-03-061-11/+11
| | | | | | | | | | | | | Use alert-info, alert-warning, and alert-danger for note, important, and warning, respectively. This is also the scheme used in the wiki: https://wiki.gentoo.org/wiki/Gentoo_Wiki:Guidelines#Block-level_layout_elements Yellow background for important and red for warning also agrees with the colours formerly used with GuideXML: https://web.archive.org/web/20150314192204/http://www.gentoo.org/doc/en/xml-guide.xml#doc_chap2_sect3 Closes: https://bugs.gentoo.org/711164 Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* Fix list-groups in text browsersMax Magorsch2020-03-031-6/+7
| | | | | | | Closes: https://bugs.gentoo.org/711286 Signed-off-by: Max Magorsch <arzano@gentoo.org> [Removed extra newline before </li>.] Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl: Assign a default "depth" value for printParentDocs.Ulrich Müller2020-03-011-5/+2
| | | | | | | | | The depth of the current document from the document root looks like a reasonable default. There is no "path" parameter, so remove it from the caller. Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl: Remove collapse from search bar.Ulrich Müller2020-02-281-14/+4
| | | | | | | In order not to hide it on small devices. Patch from Brian Evans <grknight@gentoo.org> in bug 615938. Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* Revise the navbar itemsMax Magorsch2020-02-281-5/+5
| | | | | | | | | The navbar links have been shortened using css resulting in a fixed navbar size. In addition the searchbar in the lower navbar has been centered vertically. Signed-off-by: Max Magorsch <arzano@gentoo.org> Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl: Suppress // in URIs with literal ## fragments.Ulrich Müller2020-02-281-1/+4
| | | | | | Handle the slash in the same way as for other types of URIs. Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl: Don't use @link to construct the home path.Ulrich Müller2020-02-281-1/+1
| | | | | | | The root template doesn't even have attributes, so why was this originally added? Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl: Use a fixed label for the dropdown.Ulrich Müller2020-02-281-3/+1
| | | | | | | | This will help to prevent the navbar from becoming too wide. The chapter title didn't add much information, because it also appears just below. Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* devbook.xsl: List sections in navigation dropdown.Ulrich Müller2020-02-281-7/+30
| | | | | | | | | This aims at improving navigation by also listing the sections of the current chapter in the dropdown list. As before, list any first-level sub-documents (below a divider line). Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* bin/gen-eclass-html.sh: Use en-dash in page title.Ulrich Müller2020-02-281-1/+1
| | | | | | | | For consistency with devbook.xsl. The literal character is visually indistinguishable from other dashes when using a fixed-width font, therefore replace it by an &#x2013; escape. Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* Replace ">" by "&gt;" throughout.Ulrich Müller2020-02-181-1/+1
| | | | | | | Most instances are already being escaped, so convert the few remaining ones for consistency throughout the document. Signed-off-by: Ulrich Müller <ulm@gentoo.org>