The LPdoc Internals Manual

INTERNALS MANUAL The Ciao Documentation Series

https://ciao-lang.org/

Generated/Printed on: 22 July 2023 Technical Report CLIP 5/97.1-<version>

Edited by:

Manuel Hermenegildo Jose F. Morales

Copyright \begin{matrix}c \\ ◯ \end{matrix} 1996-2018 Manuel Hermenegildo and José Francisco Morales. This document may be freely read, stored, reproduced, disseminated, translated or quoted by any means and on any medium provided the following conditions are met:

1. Every reader or user of this document acknowledges that is aware that no guarantee is given regarding its contents, on any account, and specifically concerning veracity, accuracy and fitness for any purpose.

2. No modification is made other than cosmetic, change of representation format, translation, correction of obvious syntactic errors, or as permitted by the clauses below.

3. Comments and other additions may be inserted, provided they clearly appear as such; translations or fragments must clearly refer to an original complete version, preferably one that is easily accessed whenever possible.

4. Translations, comments and other additions or modifications must be dated and their author(s) must be identifiable (possibly via an alias).

5. This licence is preserved and applies to the whole document with modifications and additions (except for brief quotes), independently of the representation format.

6. Any reference to the "official version", "original version" or "how to obtain original versions" of the document is preserved verbatim. Any copyright notice in the document is preserved verbatim. Also, the title and author(s) of the original document should be clearly mentioned as such.

7. In the case of translations, verbatim sentences mentioned in (6.) are preserved in the language of the original document accompanied by verbatim translations to the language of the traslated document. All translations state clearly that the author is not responsible for the translated work. This license is included, at least in the language in which it is referenced in the original version.

8. Whatever the mode of storage, reproduction or dissemination, anyone able to access a digitized version of this document must be able to make a digitized copy in a format directly usable, and if possible editable, according to accepted, and publicly documented, public standards.

9. Redistributing this document to a third party requires simultaneous redistribution of this licence, without modification, and in particular without any further condition or restriction, expressed or implied, related or not to this redistribution. In particular, in case of inclusion in a database or collection, the owner or the manager of the database or the collection renounces any right related to this inclusion and concerning the possible uses of the document after extraction from the database or the collection, whether alone or in relation with other documents.

Any incompatibility of the above clauses with legal, contractual or judiciary decisions or constraints implies a corresponding limitation of reading, usage, or redistribution rights for this document, verbatim or modified.

Table of Contents

1 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1

2 Introduction. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3

3 Driver for documentation generation . . . . . . . . . . . 5

3.1 Usage and interface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5 3.2 Documentation on exports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5

doc cmd/3 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5

3.3 Documentation on multifiles. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5 fsmemo.key/2 (pred). . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5 fsmemo.deps/2 (pred). . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5 fsmemo.run/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5

3.4 Documentation on imports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6

4 Documentation generation library . . . . . . . . . . . . . 7

4.1 Usage and interface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7 4.2 Documentation on exports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7

reset output dir db/0 (pred) . . . . . . . . . . . . . . . . . . . . . . . . 7 ensure output dir prepared/2 (pred) . . . . . . . . . . . . . . . . . 7 get autodoc opts/3 (pred). . . . . . . . . . . . . . . . . . . . . . . . . . . 7 autodoc gen doctree/5 (pred) . . . . . . . . . . . . . . . . . . . . . . . 8 fmt infodir entry/3 (pred). . . . . . . . . . . . . . . . . . . . . . . . . . . 8 autodoc compute grefs/3 (pred) . . . . . . . . . . . . . . . . . . . . . 8 autodoc translate doctree/3 (pred) . . . . . . . . . . . . . . . . . . 8 autodoc is operational/2 (pred) . . . . . . . . . . . . . . . . . . . . . 8 autodoc finish/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8 autodoc gen alternative/2 (pred) . . . . . . . . . . . . . . . . . . . . 8

4.3 Documentation on multifiles. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9 autodoc is operational hook/2 (pred) . . . . . . . . . . . . . . . . 9 autodoc finish hook/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . . 9 autodoc gen alternative hook/2 (pred) . . . . . . . . . . . . . . . 9

4.4 Documentation on imports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9

5 Internal state for documentation generation … 11

5.1 Usage and interface. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11 5.2 Documentation on exports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11

backend id/1 (regtype) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11 backend ignores components/1 (pred) . . . . . . . . . . . . . . . 11 backend alt format/2 (pred). . . . . . . . . . . . . . . . . . . . . . . . 11 parent format/2 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11 docstate/1 (regtype) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 docst backend/2 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 docst currmod/2 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 docst set currmod/3 (pred) . . . . . . . . . . . . . . . . . . . . . . . . 12 docst opts/2 (pred). . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 docst set opts/3 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 docst inputfile/2 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 docst pragma/2 (pred). . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 docst new no src/4 (pred). . . . . . . . . . . . . . . . . . . . . . . . . . 12 docst new with src/5 (pred). . . . . . . . . . . . . . . . . . . . . . . . 12 docst new sub/3 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13 docst opt/2 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13 docst currmod is main/1 (pred) . . . . . . . . . . . . . . . . . . . . 13 docst no components/1 (pred). . . . . . . . . . . . . . . . . . . . . . 13 docst modname/2 (pred). . . . . . . . . . . . . . . . . . . . . . . . . . . 13 labgen init/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13 labgen clean/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13 labgen get/2 (pred). . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13 docst mvar lookup/3 (pred) . . . . . . . . . . . . . . . . . . . . . . . . 13 docst mvar replace/4 (pred) . . . . . . . . . . . . . . . . . . . . . . . . 13 docst mvar get/3 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . 13 docst mdata clean/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . . 14 docst mdata assertz/2 (pred). . . . . . . . . . . . . . . . . . . . . . . 14 docst mdata save/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . 14 docst gdata/3 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14 docst gdata query/2 (pred) . . . . . . . . . . . . . . . . . . . . . . . . 14 docst gdata query/3 (pred) . . . . . . . . . . . . . . . . . . . . . . . . 14 docst gdata restore/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . 14 docst gdata clean/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . 14 docst gvar save/2 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . 14 docst gvar restore/2 (pred). . . . . . . . . . . . . . . . . . . . . . . . . 14 docst has index/2 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . 14 all indices/2 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15 get doc/4 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15 get doc changes/3 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . 15 get doc pred varnames/2 (pred) . . . . . . . . . . . . . . . . . . . . 15 custom doc/2 (pred). . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15 doc assertion read/9 (pred) . . . . . . . . . . . . . . . . . . . . . . . . 15 get docdecl/4 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15 bind dict varnames/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . 15 get mod doc/3 (pred). . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15 pred has docprop/2 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . 15 docst filetype/2 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15 get first loc for pred/3 (pred) . . . . . . . . . . . . . . . . . . . . . . 15

5.3 Documentation on imports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16

6 Documentation abstract syntax tree . . . . . . . . . . 17

6.1 Usage and interface. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17 6.2 Documentation on exports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17

cmd type/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17 doctree/1 (regtype). . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17 doctree is empty/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . 17 is nonempty doctree/1 (pred) . . . . . . . . . . . . . . . . . . . . . . 17 empty doctree/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18 doctree insert end/3 (pred) . . . . . . . . . . . . . . . . . . . . . . . . 18 doctree insert before subfile section/3 (pred) . . . . . . . . 18 doctree concat/3 (pred). . . . . . . . . . . . . . . . . . . . . . . . . . . . 18 doclink/1 (regtype) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18 doclabel/1 (regtype) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18 doclink at/2 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19 doclink is local/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . 19 doctokens/1 (regtype) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19 section prop/2 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19 section select prop/3 (pred) . . . . . . . . . . . . . . . . . . . . . . . . 19 doctree save/2 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19 doctree restore/2 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . 19 doctree simplify/2 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . 19 doctree putvars/5 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . 19 doctree scan and save refs/2 (pred) . . . . . . . . . . . . . . . . . 20 doctree prepare docst translate and write/3 (pred)… 20 doctree to rawtext/3 (pred) . . . . . . . . . . . . . . . . . . . . . . . . 20 doctree translate and write/3 (pred) . . . . . . . . . . . . . . . . 20 escape string/4 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20 is version/1 (pred). . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21 version patch/2 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21 version date/2 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21 version numstr/2 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . 21 version string/2 (pred). . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21 insert show toc/3 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . 21

6.3 Documentation on multifiles. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21 doc cmd type/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21 doc cmd rw/2 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21 autodoc rw command hook/4 (pred) . . . . . . . . . . . . . . . . 21 autodoc escape string hook/5 (pred) . . . . . . . . . . . . . . . . 21

6.4 Documentation on imports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22

7 Handling the Document Structure . . . . . . . . . . . . 23

7.1 Usage and interface. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 7.2 Documentation on exports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23

docstr node/4 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 clean docstr/0 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 parse structure/0 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 standalone docstr/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . 23 get mainmod/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 get mainmod spec/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . . 23 all component specs/1 (pred). . . . . . . . . . . . . . . . . . . . . . . 23

7.3 Documentation on imports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24

8 Current documentation settings . . . . . . . . . . . . . . 25

8.1 Usage and interface. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25 8.2 Documentation on exports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25

autodoc option/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . 25 settings file/1 (pred). . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25 clean autodoc settings/0 (pred) . . . . . . . . . . . . . . . . . . . . 25 load settings/3 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25 verify settings/0 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25 setting value or default/2 (pred). . . . . . . . . . . . . . . . . . . . 25 setting value/2 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26 all setting values/2 (pred). . . . . . . . . . . . . . . . . . . . . . . . . . 26 load vpaths/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26 custom html layout/0 (pred) . . . . . . . . . . . . . . . . . . . . . . . 26 bibtex/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26 tex/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26 texindex/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26 awk/1 (pred). . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26 dvips/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26 ps2pdf/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26 makeinfo/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26 convertc/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26 8.3 Documentation on multifiles. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27

file search path/2 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . 27

8.4 Documentation on imports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27

9 LPdoc backends . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29

10 Texinfo backend . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31

10.1 Usage and interface. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31 10.2 Documentation on exports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31

infodir base/2 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31

10.3 Documentation on multifiles. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31 autodoc escape string hook/5 (pred) . . . . . . . . . . . . . . . . 31 autodoc rw command hook/4 (pred) . . . . . . . . . . . . . . . . 31 autodoc is operational hook/2 (pred) . . . . . . . . . . . . . . . 31 autodoc finish hook/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . 32 autodoc gen alternative hook/2 (pred) . . . . . . . . . . . . . . 32

10.4 Documentation on imports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32

11 HTML backend . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33

11.1 Usage and interface. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33 11.2 Documentation on multifiles. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33

autodoc escape string hook/5 (pred) . . . . . . . . . . . . . . . . 33 autodoc rw command hook/4 (pred) . . . . . . . . . . . . . . . . 33 autodoc is operational hook/2 (pred) . . . . . . . . . . . . . . . 33 autodoc finish hook/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . 33 autodoc gen alternative hook/2 (pred) . . . . . . . . . . . . . . 33

11.3 Documentation on imports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 34

12 Assets for the HTML backend. . . . . . . . . . . . . . . 35

12.1 Usage and interface. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35 12.2 Documentation on exports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35

prepare html assets/2 (pred) . . . . . . . . . . . . . . . . . . . . . . . 35 asset file/2 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35 using mathjax/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35

12.3 Documentation on imports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35

13 Template support for the HTML backend …. 37

13.1 Usage and interface. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37 13.2 Documentation on exports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37

prefix htmlurl/2 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37 img url/2 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37 fmt html template/3 (pred) . . . . . . . . . . . . . . . . . . . . . . . . 37

13.3 Documentation on imports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37

14 Man Pages (man) backend . . . . . . . . . . . . . . . . . . 39

14.1 Usage and interface. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39 14.2 Documentation on multifiles. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39

autodoc rw command hook/4 (pred) . . . . . . . . . . . . . . . . 39 autodoc is operational hook/2 (pred) . . . . . . . . . . . . . . . 39 autodoc finish hook/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . 39 autodoc gen alternative hook/2 (pred) . . . . . . . . . . . . . . 39

14.3 Documentation on imports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39

15 Filesystem abstraction . . . . . . . . . . . . . . . . . . . . . . 41

15.1 Usage and interface. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41 15.2 Documentation on exports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41

filename/1 (regtype) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41 filename noext/1 (regtype) . . . . . . . . . . . . . . . . . . . . . . . . . 41 cleanup vpath/0 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41 add vpath/1 (pred). . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41 vpath indir/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41 find file/2 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42 find file/3 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42 find doc source/2 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . 42 subtarget/1 (regtype) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42 file format name/2 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . 42 supported file format/1 (pred). . . . . . . . . . . . . . . . . . . . . . 42 format get subtarget/3 (pred) . . . . . . . . . . . . . . . . . . . . . . 42 format get file/3 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42 clean fs db/0 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43 get output dir/2 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43 get cache dir/2 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43 get cache dir0/2 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43 ensure output dir/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . 43 ensure cache dir/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . 43 absfile for aux/3 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43 absfile for subtarget/4 (pred). . . . . . . . . . . . . . . . . . . . . . . 43 main output name/2 (pred) . . . . . . . . . . . . . . . . . . . . . . . . 43 main output name novers/1 (pred) . . . . . . . . . . . . . . . . . 43 get parent bundle/1 (pred). . . . . . . . . . . . . . . . . . . . . . . . . 43 get modspec/2 (pred). . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 44 modname nodoc/2 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . 44 modspec nodoc/2 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . 44 get subbase/3 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 44 absfile to relfile/3 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . 44 clean all/0 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 44 clean docs no texi/0 (pred) . . . . . . . . . . . . . . . . . . . . . . . . 44 clean all temporary/0 (pred) . . . . . . . . . . . . . . . . . . . . . . . 44 clean intermediate/0 (pred) . . . . . . . . . . . . . . . . . . . . . . . . 44 pred to glob pattern/2 (pred) . . . . . . . . . . . . . . . . . . . . . . 44

15.3 Documentation on imports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 45

16 Indexing commands (definition and formatting) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47

16.1 Usage and interface. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47 16.2 Documentation on exports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47

typeindex/5 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47 idx get indices/3 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47 is index cmd/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47 codetype/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47 normalize index cmd/3 (pred) . . . . . . . . . . . . . . . . . . . . . . 47 fmt idx env/7 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 48 get use outlink/4 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . 48 fmt index/3 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 48

16.3 Documentation on imports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 48

17 Database of documentation references . . . . . . . 49

17.1 Usage and interface. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 49 17.2 Documentation on exports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 49

compute refs and biblio/1 (pred) . . . . . . . . . . . . . . . . . . . 49 prepare current refs/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . 49 clean current refs/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . 49 pretty cite/3 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 49 secttree/1 (regtype) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 49 get nav/4 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 50 secttree resolve/3 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . 50

17.3 Documentation on imports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 50

18 Error messages (parsing) . . . . . . . . . . . . . . . . . . . . 51

18.1 Usage and interface. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51 18.2 Documentation on exports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51

error text/3 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51

18.3 Documentation on imports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51

19 Resolution of bibliographical references . . . . . . 53

19.1 Usage and interface. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 53 19.2 Documentation on exports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 53

resolve bibliography/1 (pred). . . . . . . . . . . . . . . . . . . . . . . 53 parse commands/3 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . 53

19.3 Documentation on imports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 53

20 Auxiliary definitions . . . . . . . . . . . . . . . . . . . . . . . . 55

20.1 Usage and interface. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55 20.2 Documentation on exports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55

all vars/1 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55 read file/2 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55 ascii blank lines/2 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . 55 autodoc process call/3 (pred) . . . . . . . . . . . . . . . . . . . . . . 55 cmd logbase/3 (pred) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55

20.3 Documentation on imports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55

21 Image handling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 57

21.1 Usage and interface. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 57 21.2 Documentation on exports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 57

locate and convert image/4 (pred) . . . . . . . . . . . . . . . . . . 57 clean image cache/0 (pred). . . . . . . . . . . . . . . . . . . . . . . . . 57

21.3 Documentation on imports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 57

References . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 59

Library/Module Index . . . . . . . . . . . . . . . . . . . . . . . . . . 61

Predicate Index. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 63

Property Index . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 65

Regular Type Index. . . . . . . . . . . . . . . . . . . . . . . . . . . . . 67 Declaration Index. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 69 Concept Index . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 71 Author Index . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 73 Global Index . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 75

1 Summary

This is the LPdoc internals manual, providing information on the different internal parts of lpdoc are their connections, which can be useful if new capabilities need to be added to the system or its libraries are used for other purposes.

2 The LPdoc Internals Manual

2 Introduction

This is the LPdoc internals manual, providing information on the different internal parts of lpdoc are their connections, which can be useful if new capabilities need to be added to the system or its libraries are used for other purposes.

4 The LPdoc Internals Manual

3 Driver for documentation generation

Author(s): Manuel Hermenegildo, Jose F. Morales. This module implements the main driver for documentation generation.

3.1 Usage and interface

• Library usage:

:- use_module(lpdoc(docmaker)).

• Exports:

− Predicates:

   doc_cmd/3.

− Multifiles:

   fsmemo.key/2, fsmemo.deps/2, fsmemo.run/1.

3.2 Documentation on exports

PREDICATE doc cmd/3:

Usage: doc_cmd(InFile,Opts,Cmd)

Treat according to Cmd InFile (which can be a doccfg-file or standalone file). Opts is the list of options (see autodoc_option/1).

3.3 Documentation on multifiles

PREDICATE fsmemo.key/2:

The predicate is multifile.

Module entry condition: fsmemo.key(Action,Arg2)

− The following properties hold at call time: Action is currently ground (it contains no variables). ( ground/1)

PREDICATE fsmemo.deps/2:

The predicate is multifile.

Module entry condition: fsmemo.deps(Action,Arg2)

− The following properties hold at call time: Action is currently ground (it contains no variables). ( ground/1)

PREDICATE fsmemo.run/1:

The predicate is multifile. Module entry condition: fsmemo.run(Action) − The following properties hold at call time:

Action is currently ground (it contains no variables). ( ground/1)

3.4 Documentation on imports

This module has the following direct dependencies: − Application modules:

autodoc, autodoc_state, autodoc_images, autodoc_structure, autodoc_settings,
autodoc_filesystem, autodoc_texinfo, autodoc_messages, docmod_holder.

− System library modules:

format, aggregates, compiler, lists, stream_utils, pathnames, fsmemo_rt, port_
reify, system, opendoc, read.

− Internal (engine) modules:

term_basic, arithmetic, atomic_basic, basiccontrol, exceptions, term_compare,
term_typing, debugger_support, basic_props, hiord_rt, internals, stream_basic.

− Packages:

prelude, initial, condcomp, assertions, assertions/assertions_basic, regtypes,
dcg, basicmodes, fsyntax, fsmemo.

4 Documentation generation library

Author(s): Manuel Hermenegildo, Jose F. Morales. This library provides some predicates which generate documentation automatically for a

given documenation component (module, package, application, etc.), using the declarations and assertions used in the source itself as input (see the assertions library).

The output format in which the documentation is generated is defined by the backend modules

( autodoc_texinfo, autodoc_html, autodoc_man, etc.).

4.1 Usage and interface

• Library usage:

:- use_module(lpdoc(autodoc)).

• Exports:

− Predicates:

reset_output_dir_db/0, ensure_output_dir_prepared/2, get_autodoc_opts/3,
autodoc_gen_doctree/5, fmt_infodir_entry/3, autodoc_compute_grefs/3,
autodoc_translate_doctree/3, autodoc_is_operational/2, autodoc_finish/1,
autodoc_gen_alternative/2.

− Multifiles:

autodoc_is_operational_hook/2,  autodoc_finish_hook/1,
autodoc_gen_alternative_hook/2.

4.2 Documentation on exports

PREDICATE reset output dir db/0:

No further documentation available for this predicate.

PREDICATE ensure output dir prepared/2:

Usage: ensure_output_dir_prepared(Backend,Opts)

Ensure that the output directories for backend Backend are prepared.

PREDICATE get autodoc opts/3:

Usage: get_autodoc_opts(Backend,Mod,Opts)

Get the list of documentation options Opts for the FileBase file. − The following properties should hold at call time:

 Backend is an atom.  ( atm/1)

Mod is an atom. ( atm/1) Opts is any term. ( term/1)

− The following properties should hold upon exit:

 Backend is an atom.  ( atm/1)

Mod is an atom. ( atm/1)

 Opts is a list of supported_options.  ( list/2)

PREDICATE autodoc gen doctree/5:

Usage: autodoc_gen_doctree(Backend,FileBase,FileExt,Opts,Mod)

FileBase is the module specifier of the source file being documented (without extension, FileExt is the source extension). The output is a file whose contents document the main file, based on any assertions present in that file. The documentation is produced in the format given by Backend (the name of the output file also depends on Backend). The formats supported are given by backend_id/1. − Call and exit should be compatible with:

Backend is a supported backend. ( backend_id/1) FileBase is the base name of a file (without extension). ( filename_noext/1)

    FileExt is an atom.  ( atm/1)
    Opts is a list of supported_options.  ( list/2)

Mod is an atom. ( atm/1)

PREDICATE fmt infodir entry/3:

Usage: fmt_infodir_entry(DocSt,Version,Mod)

Generates a one line description (ASCII) of the application or library in a file for the directory of emacs info manuals. − The following properties should hold at call time:

    docstate(DocSt)  ( docstate/1)
    Version is any term.  ( term/1)

Mod is the base name of a file (without extension). ( filename_noext/1)

PREDICATE autodoc compute grefs/3:

Usage: Compute the globally resolved references (including bibliography)

PREDICATE autodoc translate doctree/3:

Usage: Translate the doctree using the specific backend

PREDICATE autodoc is operational/2:

No further documentation available for this predicate.

PREDICATE autodoc finish/1:

No further documentation available for this predicate.

PREDICATE autodoc gen alternative/2:

No further documentation available for this predicate.

4.3 Documentation on multifiles

PREDICATE autodoc is operational hook/2:

No further documentation available for this predicate. The predicate is multifile.

PREDICATE autodoc finish hook/1:

No further documentation available for this predicate. The predicate is multifile.

PREDICATE autodoc gen alternative hook/2:

No further documentation available for this predicate. The predicate is multifile.

4.4 Documentation on imports

This module has the following direct dependencies: − Application modules:

doccfg_props, autodoc_state, autodoc_settings, autodoc_filesystem, autodoc_
structure, autodoc_doctree, autodoc_refsdb, autodoc_parse, autodoc_index,
comments, autodoc_messages, autodoc_html_assets, autodoc_texinfo, autodoc_aux.

− System library modules:

datafacts_rt, format, read, aggregates, compiler, assrt_lib, c_itf, pathnames,
lists, terms, assertions_props, system, bundle_paths.

− Internal (engine) modules:

term_basic, arithmetic, atomic_basic, basiccontrol, exceptions, term_compare,
term_typing, debugger_support, basic_props, hiord_rt, stream_basic.

− Packages:

prelude, initial, condcomp, assertions, assertions/assertions_basic, regtypes,
dcg, basicmodes, fsyntax, datafacts.

10 The LPdoc Internals Manual

5 Internal state for documentation generation

Author(s): Manuel Hermenegildo, Jose F. Morales. This module defines the internal state of the documentation generation (for a single module).

5.1 Usage and interface

• Library usage:

:- use_module(lpdoc(autodoc_state)).

• Exports:

− Predicates:

backend_ignores_
components/1, backend_alt_format/2, parent_format/2, docst_backend/2,
docst_currmod/2, docst_set_currmod/3, docst_opts/2, docst_set_opts/3,
docst_inputfile/2, docst_pragma/2, docst_new_no_src/4, docst_new_with_
src/5, docst_new_sub/3, docst_opt/2, docst_currmod_is_main/1, docst_no_
components/1, docst_modname/2, labgen_init/1, labgen_clean/1, labgen_get/2,
docst_mvar_lookup/3, docst_mvar_replace/4, docst_mvar_get/3, docst_mdata_
clean/1, docst_mdata_assertz/2, docst_mdata_save/1, docst_gdata/3, docst_
gdata_query/2, docst_gdata_query/3, docst_gdata_restore/1, docst_gdata_
clean/1, docst_gvar_save/2, docst_gvar_restore/2, docst_has_index/2, all_
indices/2, get_doc/4, get_doc_changes/3, get_doc_pred_varnames/2, custom_
doc/2, doc_assertion_read/9, get_docdecl/4, bind_dict_varnames/1, get_mod_
doc/3, pred_has_docprop/2, docst_filetype/2, get_first_loc_for_pred/3.

− Regular Types:

backend_id/1, docstate/1.

5.2 Documentation on exports

REGTYPE backend id/1:

Usage: backend_id(Id)

Id is a supported backend.

PREDICATE backend ignores components/1:

Usage: backend_ignores_components(Id)

Id does not take into account components (only documents the mainfile)

PREDICATE backend alt format/2:

Usage: backend_alt_format(Id,Ext)

Ext is an alternative file format that can be generated by the backend Id

PREDICATE parent format/2:

Usage: parent_format(Format,Parent)

Parent is the parent format that will generate the file with Format format.

REGTYPE docstate/1:

A regular type, defined as follows:

     docstate(docstate(Backend,Name,Opts,MVarDic,I)) :-
         backend_id(Backend),
         atom(Name),
         list(Opts,supported_option),
         dictionary(MVarDic),
         filename(I).

PREDICATE docst backend/2:

No further documentation available for this predicate.

PREDICATE docst currmod/2:

No further documentation available for this predicate.

PREDICATE docst set currmod/3:

No further documentation available for this predicate.

PREDICATE docst opts/2:

No further documentation available for this predicate.

PREDICATE docst set opts/3:

No further documentation available for this predicate.

PREDICATE docst inputfile/2:

No further documentation available for this predicate.

PREDICATE docst pragma/2:

No further documentation available for this predicate.

PREDICATE docst new no src/4:

No further documentation available for this predicate.

PREDICATE docst new with src/5:

No further documentation available for this predicate.

PREDICATE docst new sub/3:

No further documentation available for this predicate.

PREDICATE docst opt/2:

No further documentation available for this predicate.

PREDICATE docst currmod is main/1:

No further documentation available for this predicate.

PREDICATE docst no components/1:

Usage: docst_no_components(DocSt)

DocSt specify an empty list of components

PREDICATE docst modname/2:

Usage: docst_modname(DocSt,ModName)

ModName is the name of the module that we are documenting.

PREDICATE labgen init/1:

No further documentation available for this predicate.

PREDICATE labgen clean/1:

No further documentation available for this predicate.

PREDICATE labgen get/2:

No further documentation available for this predicate.

PREDICATE docst mvar lookup/3:

No further documentation available for this predicate.

PREDICATE docst mvar replace/4:

No further documentation available for this predicate.

PREDICATE docst mvar get/3:

No further documentation available for this predicate.

PREDICATE docst mdata clean/1:

No further documentation available for this predicate.

PREDICATE docst mdata assertz/2:

No further documentation available for this predicate.

PREDICATE docst mdata save/1:

No further documentation available for this predicate.

PREDICATE docst gdata/3:

No further documentation available for this predicate. The predicate is of type data.

PREDICATE docst gdata query/2:

No further documentation available for this predicate.

PREDICATE docst gdata query/3:

No further documentation available for this predicate.

PREDICATE docst gdata restore/1:

No further documentation available for this predicate.

PREDICATE docst gdata clean/1:

No further documentation available for this predicate.

PREDICATE docst gvar save/2:

No further documentation available for this predicate.

PREDICATE docst gvar restore/2:

No further documentation available for this predicate.

PREDICATE docst has index/2:

No further documentation available for this predicate.

PREDICATE all indices/2:

No further documentation available for this predicate.

PREDICATE get doc/4:

No further documentation available for this predicate.

PREDICATE get doc changes/3:

No further documentation available for this predicate.

PREDICATE get doc pred varnames/2:

No further documentation available for this predicate.

PREDICATE custom doc/2:

No further documentation available for this predicate. The predicate is of type data.

PREDICATE doc assertion read/9:

No further documentation available for this predicate.

PREDICATE get docdecl/4:

No further documentation available for this predicate.

PREDICATE bind dict varnames/1:

Usage: bind_dict_varnames(Dict)

Binds the variables in Dict to the corresponding names (i.e., the names that appeared in the source during read.

PREDICATE get mod doc/3:

No further documentation available for this predicate.

PREDICATE pred has docprop/2:

No further documentation available for this predicate.

PREDICATE docst filetype/2:

No further documentation available for this predicate.

PREDICATE get first loc for pred/3:

No further documentation available for this predicate.

5.3 Documentation on imports

This module has the following direct dependencies: − Application modules:

doccfg_props, autodoc_settings, autodoc_filesystem, autodoc_structure, autodoc_
doctree, autodoc_refsdb, autodoc_parse, autodoc_index, comments, autodoc_
messages, autodoc_aux.

− System library modules:

datafacts_rt, aggregates, compiler, assrt_lib, c_itf, assertions_props,
pathnames, lists, terms, dict, write, read, system.

− Internal (engine) modules:

term_basic, arithmetic, atomic_basic, basiccontrol, exceptions, term_compare,
term_typing, debugger_support, basic_props, hiord_rt, runtime_control, stream_
basic.

− Packages:

prelude, initial, condcomp, dcg, assertions, assertions/assertions_basic,
regtypes, basicmodes, fsyntax, datafacts.

6 Documentation abstract syntax tree

Author(s): Manuel Hermenegildo (original version), Jose F. Morales. This module defines the intermediate tree representation doctree/1 for documentation and

its related operations.

6.1 Usage and interface

• Library usage:

:- use_module(lpdoc(autodoc_doctree)).

• Exports:

− Predicates:

cmd_type/1, doctree_is_empty/1, is_nonempty_doctree/1, empty_doctree/1,
doctree_insert_end/3, doctree_insert_before_subfile_section/3, doctree_
concat/3, doclink_at/2, doclink_is_local/1, section_prop/2, section_select_
prop/3, doctree_save/2, doctree_restore/2, doctree_simplify/2, doctree_
putvars/5, doctree_scan_and_save_refs/2, doctree_prepare_docst_translate_
and_write/3, doctree_to_rawtext/3, doctree_translate_and_write/3, escape_
string/4, is_version/1, version_patch/2, version_date/2, version_numstr/2,
version_string/2, insert_show_toc/3.

− Regular Types:

doctree/1, doclink/1, doclabel/1, doctokens/1.

− Multifiles:

doc_cmd_type/1, doc_cmd_rw/2, autodoc_rw_command_hook/4, autodoc_escape_
string_hook/5.

6.2 Documentation on exports

PREDICATE cmd type/1:

No further documentation available for this predicate.

REGTYPE doctree/1:

Usage: Intermediate tree representation for documentation

PREDICATE doctree is empty/1:

Usage: doctree_is_empty(R)

Emptiness test − The following properties should hold at call time:

R is currently a term which is not a free variable. ( nonvar/1) Intermediate tree representation for documentation ( doctree/1)

PREDICATE is nonempty doctree/1:

Usage: is_nonempty_doctree(R)

Not empty test − The following properties should hold at call time:

R is currently a term which is not a free variable. ( nonvar/1) Intermediate tree representation for documentation ( doctree/1)

PREDICATE empty doctree/1:

Usage: empty_doctree(R)

Empty − The following properties should hold at call time:

R is a free variable. ( var/1) Intermediate tree representation for documentation ( doctree/1)

PREDICATE doctree insert end/3:

Usage: doctree_insert_end(A0,Elem,A)

Insert Elem in A0 at the end, obtaining A − Call and exit should be compatible with:

Intermediate tree representation for documentation ( doctree/1) Intermediate tree representation for documentation ( doctree/1) Intermediate tree representation for documentation ( doctree/1)

PREDICATE doctree insert before subfile section/3:

Usage: doctree_insert_before_subfile_section(A0,Elem,A)

Insert Elem in A0 before the first section, obtaining A. Keep A0 if Elem is already present. − Call and exit should be compatible with:

Intermediate tree representation for documentation ( doctree/1) Intermediate tree representation for documentation ( doctree/1) Intermediate tree representation for documentation ( doctree/1)

PREDICATE doctree concat/3:

No further documentation available for this predicate.

REGTYPE doclink/1:

Usage: A link to a document label

REGTYPE doclabel/1:

Usage: An internal label

PREDICATE doclink at/2:

No further documentation available for this predicate.

PREDICATE doclink is local/1:

No further documentation available for this predicate.

REGTYPE doctokens/1:

Usage: Primitive doctree subset (ready for output, not further reducible)

PREDICATE section prop/2:

No further documentation available for this predicate.

PREDICATE section select prop/3:

No further documentation available for this predicate.

PREDICATE doctree save/2:

Usage: − Call and exit should be compatible with:

Arg1 is an atom. ( atm/1) Intermediate tree representation for documentation ( doctree/1)

− The following properties should hold at call time: Arg1 is currently a term which is not a free variable. ( nonvar/1) Arg2 is currently a term which is not a free variable. ( nonvar/1)

PREDICATE doctree restore/2:

Usage: − Call and exit should be compatible with:

Arg1 is an atom. ( atm/1) Intermediate tree representation for documentation ( doctree/1)

− The following properties should hold at call time: Arg1 is currently a term which is not a free variable. ( nonvar/1)

PREDICATE doctree simplify/2:

No further documentation available for this predicate.

PREDICATE doctree putvars/5:

Usage: doctree_putvars(R0,DocSt,PDict,VarDict,R)

Traverse R0 and replace each var(Name) doctree item with a fresh variable B. For each replacement, the term B=Var is introduced in VarDict, where Var is the associated value to Name in the dictionary PDict. − The following properties should hold at call time:

Intermediate tree representation for documentation ( doctree/1)

    docstate(DocSt)  ( docstate/1)

− The following properties should hold upon exit: Intermediate tree representation for documentation ( doctree/1)

PREDICATE doctree scan and save refs/2:

Usage: doctree_scan_and_save_refs(R,DocSt)

Scan and save the references of the doctree − The following properties should hold at call time:

Intermediate tree representation for documentation ( doctree/1)

    docstate(DocSt)  ( docstate/1)

PREDICATE doctree prepare docst translate and write/3:

No further documentation available for this predicate.

PREDICATE doctree to rawtext/3:

Usage: doctree_to_rawtext(X,DocSt,Y)

Y is a simplified raw text representation of the X − Call and exit should be compatible with:

Intermediate tree representation for documentation ( doctree/1)

    docstate(DocSt)  ( docstate/1)

Y is a string (a list of character codes). ( string/1)

PREDICATE doctree translate and write/3:

No further documentation available for this predicate.

PREDICATE escape string/4:

Usage: Escapes needed characters in input string as needed for the target format. − The following properties should hold upon exit:

Arg1 is currently instantiated to an atom. ( atom/1) Arg2 is a string (a list of character codes). ( string/1)

    docstate(Arg3)  ( docstate/1)

Arg4 is a string (a list of character codes). ( string/1)

PREDICATE is version/1:

No further documentation available for this predicate.

PREDICATE version patch/2:

No further documentation available for this predicate.

PREDICATE version date/2:

No further documentation available for this predicate.

PREDICATE version numstr/2:

Usage: version_numstr(Version,Str)

Obtain the string Str representation of version Version (except date)

PREDICATE version string/2:

Usage: version_string(Version,Str)

Obtain the string Str representation of version Version (including date)

PREDICATE insert show toc/3:

Usage: insert_show_toc(R0,DocSt,R)

Insert the command to show the table of contents in a given doctree/1. The right place may be different depending on the chosen backend.

6.3 Documentation on multifiles

PREDICATE doc cmd type/1:

No further documentation available for this predicate. The predicate is multifile.

PREDICATE doc cmd rw/2:

No further documentation available for this predicate. The predicate is multifile.

PREDICATE autodoc rw command hook/4:

No further documentation available for this predicate. The predicate is multifile.

PREDICATE autodoc escape string hook/5:

No further documentation available for this predicate. The predicate is multifile.

6.4 Documentation on imports

This module has the following direct dependencies: − Application modules:

autodoc_state, autodoc_refsdb, autodoc_index, autodoc_structure, autodoc_
filesystem, autodoc_settings, comments, autodoc_messages, autodoc_texinfo,
autodoc_man, autodoc_html, autodoc_nil.

− System library modules:

write, operators, format, pathnames, lists, read, terms.

− Internal (engine) modules:

term_basic, arithmetic, atomic_basic, basiccontrol, exceptions, term_compare,
term_typing, debugger_support, basic_props, hiord_rt, stream_basic, runtime_
control.

− Packages:

prelude, initial, condcomp, dcg, assertions, assertions/assertions_basic,
regtypes, basicmodes, fsyntax.

7 Handling the Document Structure

Author(s): Jose F. Morales.

7.1 Usage and interface

• Library usage:

:- use_module(lpdoc(autodoc_structure)).

• Exports:

− Predicates:

   docstr_node/4, clean_docstr/0, parse_structure/0, standalone_docstr/1, get_
   mainmod/1, get_mainmod_spec/1, all_component_specs/1.

7.2 Documentation on exports

PREDICATE docstr node/4:

No further documentation available for this predicate. The predicate is of type data.

PREDICATE clean docstr/0:

No further documentation available for this predicate.

PREDICATE parse structure/0:

No further documentation available for this predicate.

PREDICATE standalone docstr/1:

No further documentation available for this predicate.

PREDICATE get mainmod/1:

No further documentation available for this predicate.

PREDICATE get mainmod spec/1:

No further documentation available for this predicate.

PREDICATE all component specs/1:

No further documentation available for this predicate.

7.3 Documentation on imports

This module has the following direct dependencies: − Application modules:

autodoc_settings.

− System library modules:

datafacts_rt, pathnames, aggregates, terms.

− Internal (engine) modules:

term_basic, arithmetic, atomic_basic, basiccontrol, exceptions, term_compare,
term_typing, debugger_support, basic_props, hiord_rt.

− Packages:

prelude, initial, condcomp, dcg, assertions, assertions/assertions_basic,
regtypes, basicmodes, fsyntax, datafacts.

8 Current documentation settings

Author(s): Jose F. Morales. This module defines the predicates to load and access documentation configurations (modules

implementing doccfg).

8.1 Usage and interface

• Library usage:

:- use_module(lpdoc(autodoc_settings)).

• Exports:

− Predicates:

   autodoc_option/1, settings_file/1, clean_autodoc_settings/0, load_
   settings/3, verify_settings/0, setting_value_or_default/2, setting_value/2,
   all_setting_values/2, load_vpaths/1, custom_html_layout/0, bibtex/1, tex/1,
   texindex/1, awk/1, dvips/1, ps2pdf/1, makeinfo/1, convertc/1.

− Multifiles:

   file_search_path/2.

8.2 Documentation on exports

PREDICATE autodoc option/1:

No further documentation available for this predicate. The predicate is of type data.

PREDICATE settings file/1:

No further documentation available for this predicate. The predicate is of type data.

PREDICATE clean autodoc settings/0:

No further documentation available for this predicate.

PREDICATE load settings/3:

Usage: load_settings(InFile,InKind,Opts)

Set configuration from InFile of kind InKind and Opts

PREDICATE verify settings/0:

No further documentation available for this predicate.

PREDICATE setting value or default/2:

Usage: setting_value_or_default(Var,Value)

Returns in Value the value of the variable Var. In case this variable does not exist, it returns a default value. If there is no default value for the variable Var it fails.

PREDICATE setting value/2:

No further documentation available for this predicate.

PREDICATE all setting values/2:

No further documentation available for this predicate.

PREDICATE load vpaths/1:

No further documentation available for this predicate.

PREDICATE custom html layout/0:

No further documentation available for this predicate.

PREDICATE bibtex/1:

No further documentation available for this predicate.

PREDICATE tex/1:

No further documentation available for this predicate.

PREDICATE texindex/1:

No further documentation available for this predicate.

PREDICATE awk/1:

No further documentation available for this predicate.

PREDICATE dvips/1:

No further documentation available for this predicate.

PREDICATE ps2pdf/1:

No further documentation available for this predicate.

PREDICATE makeinfo/1:

No further documentation available for this predicate.

PREDICATE convertc/1:

No further documentation available for this predicate.

8.3 Documentation on multifiles

PREDICATE file search path/2:

No further documentation available for this predicate. The predicate is multifile. The predicate is of type dynamic.

8.4 Documentation on imports

This module has the following direct dependencies: − Application modules:

autodoc_messages, doccfg_holder, autodoc_filesystem.

− System library modules:

datafacts_rt, pathnames, aggregates, lists, system, bundle_paths.

− Internal (engine) modules:

term_basic, arithmetic, atomic_basic, basiccontrol, exceptions, term_compare,
term_typing, debugger_support, basic_props, stream_basic.

− Packages:

prelude, initial, condcomp, dcg, assertions, assertions/assertions_basic,
regtypes, fsyntax, datafacts.

28 The LPdoc Internals Manual

9 LPdoc backends

[figure] [figure]

30 The LPdoc Internals Manual

10 Texinfo backend

Author(s): Manuel Hermenegildo, Jose F. Morales.

This module implements the output format backend for texinfo (see The GNU Texinfo Documentation System manual for more info). This backend is is used to generate both ps/pdf and info manuals.

In this backend the documentation for a module is a texinfo chapter, suitable for inclusion in a wrapper “main” document file.

10.1 Usage and interface

• Library usage:

    :- use_module(lpdoc(autodoc_texinfo)).

• Exports:

− Predicates:

        infodir_base/2.

− Multifiles:

        autodoc_escape_string_hook/5,  autodoc_
        rw_command_hook/4, autodoc_is_operational_hook/2, autodoc_finish_hook/1,
        autodoc_gen_alternative_hook/2.

10.2 Documentation on exports

PREDICATE infodir base/2:

No further documentation available for this predicate.

10.3 Documentation on multifiles

PREDICATE autodoc escape string hook/5:

No further documentation available for this predicate. The predicate is multifile.

PREDICATE autodoc rw command hook/4:

     Usage: autodoc_rw_command_hook(Backend,DocSt,Command,NewCommand)

− The following properties should hold at call time: Backend is a supported backend. ( backend_id/1)

         docstate(DocSt)  ( docstate/1)

Intermediate tree representation for documentation ( doctree/1) Intermediate tree representation for documentation ( doctree/1)

The predicate is multifile.

PREDICATE autodoc is operational hook/2:

No further documentation available for this predicate. The predicate is multifile.

PREDICATE autodoc finish hook/1:

No further documentation available for this predicate. The predicate is multifile.

PREDICATE autodoc gen alternative hook/2:

No further documentation available for this predicate. The predicate is multifile.

10.4 Documentation on imports

This module has the following direct dependencies: − Application modules:

autodoc_state, autodoc_filesystem, autodoc_structure, autodoc_index, autodoc_
doctree, autodoc_images, autodoc_settings, autodoc_aux, comments, autodoc_
messages.

− System library modules:

lists, terms, format, format_to_string, system, pathnames, glob, system_extra,
stream_utils.

− Internal (engine) modules:

term_basic, arithmetic, atomic_basic, basiccontrol, exceptions, term_compare,
term_typing, debugger_support, basic_props.

− Packages:

prelude, initial, condcomp, assertions, assertions/assertions_basic, regtypes,
fsyntax.

11 HTML backend

Author(s): Jose F. Morales.

11.1 Usage and interface

• Library usage:

:- use_module(lpdoc(autodoc_html)).

11.2 Documentation on multifiles

PREDICATE autodoc escape string hook/5:

No further documentation available for this predicate. The predicate is multifile.

PREDICATE autodoc rw command hook/4:

Usage: autodoc_rw_command_hook(Backend,DocSt,Command,NewCommand)

− The following properties should hold at call time: Backend is a supported backend. ( backend_id/1)

    docstate(DocSt)  ( docstate/1)

Intermediate tree representation for documentation ( doctree/1) Intermediate tree representation for documentation ( doctree/1)

The predicate is multifile.

PREDICATE autodoc is operational hook/2:

No further documentation available for this predicate. The predicate is multifile.

PREDICATE autodoc finish hook/1:

No further documentation available for this predicate. The predicate is multifile.

PREDICATE autodoc gen alternative hook/2:

No further documentation available for this predicate. The predicate is multifile.

11.3 Documentation on imports

This module has the following direct dependencies: − Application modules:

autodoc_state, autodoc_structure, autodoc_filesystem, autodoc_doctree, autodoc_
index, autodoc_refsdb, autodoc_images, autodoc_settings, autodoc_messages,
comments, autodoc_html_template, autodoc_html_assets.

− System library modules:

lists, aggregates, dict, pathnames, format_to_string, syntax_highlight, system,
system_extra, stream_utils.

− Internal (engine) modules:

term_basic, arithmetic, atomic_basic, basiccontrol, exceptions, term_compare,
term_typing, debugger_support, basic_props.

− Packages:

prelude, initial, condcomp, assertions, assertions/assertions_basic, regtypes,
fsyntax.

12 Assets for the HTML backend

Author(s): Jose F. Morales. Predicates to manage asset data (file hierarchies for images, CSS files, JavaScript code, etc.)

to be used in the output of the HTML backend.

12.1 Usage and interface

• Library usage:

 :- use_module(lpdoc(autodoc_html_assets)).

• Exports:

− Predicates:

    prepare_html_assets/2, asset_file/2, using_mathjax/1.

12.2 Documentation on exports

PREDICATE prepare html assets/2:

No further documentation available for this predicate.

PREDICATE asset file/2:

No further documentation available for this predicate.

PREDICATE using mathjax/1:

No further documentation available for this predicate.

12.3 Documentation on imports

This module has the following direct dependencies: − Application modules:

autodoc_messages, autodoc_settings, autodoc_filesystem.

− System library modules:

datafacts_rt, lists, pathnames, system, bundle_paths, source_tree.

− Internal (engine) modules:

term_basic, arithmetic, atomic_basic, basiccontrol, exceptions, term_compare,
term_typing, debugger_support, basic_props, hiord_rt.

− Packages:

prelude, initial, condcomp, assertions, assertions/assertions_basic, isomodes,
fsyntax, datafacts.

36 The LPdoc Internals Manual

13 Template support for the HTML backend

Author(s): Jose F. Morales.

13.1 Usage and interface

• Library usage:

:- use_module(lpdoc(autodoc_html_template)).

• Exports:

− Predicates:

   prefix_htmlurl/2, img_url/2, fmt_html_template/3.

13.2 Documentation on exports

PREDICATE prefix htmlurl/2:

Usage: prefix_htmlurl(Path,Path2)

Prefix Path with value of htmlurl (if needed) − Call and exit should be compatible with:

Path is an atom. ( atm/1) Path2 is an atom. ( atm/1)

PREDICATE img url/2:

Usage: img_url(Name,Url)

Obtain the URL where image Name is or will be found. − Call and exit should be compatible with:

Name is an atom. ( atm/1) Url is a string (a list of character codes). ( string/1)

PREDICATE fmt html template/3:

No further documentation available for this predicate.

13.3 Documentation on imports

This module has the following direct dependencies: − Application modules:

autodoc_settings.

− System library modules:

system, stream_utils, pathnames, lists, html.

− Internal (engine) modules:

term_basic, arithmetic, atomic_basic, basiccontrol, exceptions, term_compare,
term_typing, debugger_support, basic_props, stream_basic.

− Packages:

prelude, initial, condcomp, assertions, assertions/assertions_basic, fsyntax.

38 The LPdoc Internals Manual

14 Man Pages (man) backend

Author(s): Jose F. Morales, Manuel Hermenegildo. This module implements some limited support for direct output in unix man format.

14.1 Usage and interface

• Library usage:

 :- use_module(lpdoc(autodoc_man)).

14.2 Documentation on multifiles

PREDICATE autodoc rw command hook/4:

 Usage: autodoc_rw_command_hook(Backend,DocSt,Command,NewCommand)

− The following properties should hold at call time: Backend is a supported backend. ( backend_id/1)

     docstate(DocSt)  ( docstate/1)

Intermediate tree representation for documentation ( doctree/1) Intermediate tree representation for documentation ( doctree/1)

The predicate is multifile.

PREDICATE autodoc is operational hook/2:

No further documentation available for this predicate. The predicate is multifile.

PREDICATE autodoc finish hook/1:

No further documentation available for this predicate. The predicate is multifile.

PREDICATE autodoc gen alternative hook/2:

No further documentation available for this predicate. The predicate is multifile.

14.3 Documentation on imports

This module has the following direct dependencies: − Application modules:

autodoc_state, autodoc_doctree, autodoc_images, autodoc_aux, comments.

− System library modules:

lists, format_to_string.

− Internal (engine) modules:

term_basic, arithmetic, atomic_basic, basiccontrol, exceptions, term_compare,
term_typing, debugger_support, basic_props.

− Packages:

prelude, initial, condcomp, assertions, assertions/assertions_basic, regtypes,
fsyntax.

40 The LPdoc Internals Manual

15 Filesystem abstraction

Author(s): Jose F. Morales. This module provides definitions to assign unique file-system paths and names for each of

the intermediate and final results of documentation generation.

15.1 Usage and interface

• Library usage:

:- use_module(lpdoc(autodoc_filesystem)).

• Exports:

− Predicates:

cleanup_vpath/0, add_vpath/1, vpath_indir/1, find_file/2, find_file/3,
find_doc_source/2, file_format_name/2, supported_file_format/1, format_
get_subtarget/3, format_get_file/3, clean_fs_db/0, get_output_dir/2, get_
cache_dir/2, get_cache_dir0/2, ensure_output_dir/1, ensure_cache_dir/1,
absfile_for_aux/3, absfile_for_subtarget/4, main_output_name/2, main_
output_name_novers/1, get_parent_bundle/1, get_modspec/2, modname_nodoc/2,
modspec_nodoc/2, get_subbase/3, absfile_to_relfile/3, clean_all/0, clean_
docs_no_texi/0, clean_all_temporary/0, clean_intermediate/0, pred_to_glob_
pattern/2.

− Regular Types:

filename/1, filename_noext/1, subtarget/1.

15.2 Documentation on exports

REGTYPE filename/1:

Usage: filename(X)

X is the name of a file.

REGTYPE filename noext/1:

Usage: filename_noext(X)

X is the base name of a file (without extension).

PREDICATE cleanup vpath/0:

No further documentation available for this predicate.

PREDICATE add vpath/1:

No further documentation available for this predicate.

PREDICATE vpath indir/1:

No further documentation available for this predicate.

PREDICATE find file/2:

No further documentation available for this predicate.

PREDICATE find file/3:

No further documentation available for this predicate. Meta-predicate with arguments:

find_file(?,pred(1),?).

PREDICATE find doc source/2:

No further documentation available for this predicate.

REGTYPE subtarget/1:

Usage: The kind of intermediate/final results for a single documentation processing unit (module).

PREDICATE file format name/2:

No further documentation available for this predicate.

PREDICATE supported file format/1:

No further documentation available for this predicate.

PREDICATE format get subtarget/3:

Usage: format_get_subtarget(Format,Backend,Subtarget)

Backend and Subtarget are the backend and subtarget that generates files with format

Format

− Call and exit should be compatible with:

    Format is an atom.  ( atm/1)

Backend is a supported backend. ( backend_id/1)

    Subtarget is an atom.  ( atm/1)

PREDICATE format get file/3:

Usage: format_get_file(Format,Mod,File)

File is the principal file for Mod in format Format − Call and exit should be compatible with:

    Format is an atom.  ( atm/1)

Mod is an atom. ( atm/1) File is an atom. ( atm/1)

PREDICATE clean fs db/0:

Usage: Clean the cached information for the filesystem mapping of the documentaton generation.

PREDICATE get output dir/2:

Usage: get_output_dir(Backend,Dir)

Dir is the directory where the documentation files are generated. Note that this is not the installation directory.

PREDICATE get cache dir/2:

Usage: get_cache_dir(Backend,Dir)

Dir is the directory where temporary documentation files will be stored (for the active backend)

PREDICATE get cache dir0/2:

Usage: get_cache_dir0(Backend,Dir)

Dir is the directory where temporary documentation files will be stored (for all backends)

PREDICATE ensure output dir/1:

No further documentation available for this predicate.

PREDICATE ensure cache dir/1:

No further documentation available for this predicate.

PREDICATE absfile for aux/3:

Usage: absfile_for_aux(AuxName,Backend,AbsFile)

Absolute file for an auxiliary output file (e.g. CSS, images, etc.)

PREDICATE absfile for subtarget/4:

No further documentation available for this predicate.

PREDICATE main output name/2:

No further documentation available for this predicate.

PREDICATE main output name novers/1:

No further documentation available for this predicate.

PREDICATE get parent bundle/1:

No further documentation available for this predicate.

PREDICATE get modspec/2:

No further documentation available for this predicate.

PREDICATE modname nodoc/2:

No further documentation available for this predicate.

PREDICATE modspec nodoc/2:

No further documentation available for this predicate.

PREDICATE get subbase/3:

Usage: get_subbase(Base,Sub,SubBase)

SubBase is the name for the sub-file (Sub) associated with Base − The following properties should hold upon exit:

Base is the base name of a file (without extension). ( filename_noext/1) Sub is an atom. ( atm/1) SubBase is the base name of a file (without extension). ( filename_noext/1)

PREDICATE absfile to relfile/3:

Usage: absfile_to_relfile(A,Backend,B)

Obtain the relative path, w.r.t. the output directory, of an absolute file. This is useful, e.g., for URLs.

PREDICATE clean all/0:

No further documentation available for this predicate.

PREDICATE clean docs no texi/0:

No further documentation available for this predicate.

PREDICATE clean all temporary/0:

No further documentation available for this predicate.

PREDICATE clean intermediate/0:

No further documentation available for this predicate.

PREDICATE pred to glob pattern/2:

No further documentation available for this predicate. Meta-predicate with arguments:

pred_to_glob_pattern(pred(1),?).

15.3 Documentation on imports

This module has the following direct dependencies: − Application modules:

autodoc_settings, autodoc_structure, autodoc_state.

− System library modules:

datafacts_rt, aggregates, pathnames, system, terms, lists, system_extra, bundle_
info, bundle_paths, source_tree.

− Internal (engine) modules:

term_basic, arithmetic, atomic_basic, basiccontrol, exceptions, term_compare,
term_typing, debugger_support, basic_props, hiord_rt.

− Packages:

prelude, initial, condcomp, dcg, assertions, assertions/assertions_basic,
regtypes, basicmodes, fsyntax, hiord, datafacts.

46 The LPdoc Internals Manual

16 Indexing commands (definition and formatting)

Author(s): Jose F. Morales. This module defines index commands and formatting.

16.1 Usage and interface

• Library usage:

:- use_module(lpdoc(autodoc_index)).

• Exports:

− Predicates:

   typeindex/5, idx_get_indices/3, is_index_cmd/1, codetype/1, normalize_
   index_cmd/3, fmt_idx_env/7, get_use_outlink/4, fmt_index/3.

16.2 Documentation on exports

PREDICATE typeindex/5:

Usage: typeindex(IdxName,IndexId,IType,Name,Comment)

Define properties of the index IdxName. IndexId is the index ID for texinfo. IType is the type of index; an empty string means normal. Name is the title of the index in the documentation. Comment is a comment to include before the index. − The following properties should hold upon exit:

IdxName is currently instantiated to an atom. ( atom/1)

    IndexId is an atom.  ( atm/1)

IType is a string (a list of character codes). ( string/1) Name is a string (a list of character codes). ( string/1) Intermediate tree representation for documentation ( doctree/1)

PREDICATE idx get indices/3:

No further documentation available for this predicate.

PREDICATE is index cmd/1:

No further documentation available for this predicate.

PREDICATE codetype/1:

No further documentation available for this predicate.

PREDICATE normalize index cmd/3:

No further documentation available for this predicate.

PREDICATE fmt idx env/7:

No further documentation available for this predicate.

PREDICATE get use outlink/4:

No further documentation available for this predicate.

PREDICATE fmt index/3:

No further documentation available for this predicate.

16.3 Documentation on imports

This module has the following direct dependencies: − Application modules:

autodoc_state, autodoc_filesystem, autodoc_doctree, autodoc_structure, autodoc_
refsdb.

− System library modules:

dict, lists, aggregates.

− Internal (engine) modules:

term_basic, arithmetic, atomic_basic, basiccontrol, exceptions, term_compare,
term_typing, debugger_support, basic_props.

− Packages:

prelude, initial, condcomp, dcg, assertions, assertions/assertions_basic,
regtypes, fsyntax.

17 Database of documentation references

Author(s): Jose F. Morales. This module stores and manages all the documentation references (indices, sections, bibliog-

raphy, etc.). It includes the generation of the table of contents.

17.1 Usage and interface

• Library usage:

:- use_module(lpdoc(autodoc_refsdb)).

• Exports:

− Predicates:

   compute_refs_and_biblio/1, prepare_current_refs/1, clean_current_refs/1,
   pretty_cite/3, get_nav/4, secttree_resolve/3.

− Regular Types:

   secttree/1.

17.2 Documentation on exports

PREDICATE compute refs and biblio/1:

No further documentation available for this predicate.

PREDICATE prepare current refs/1:

Usage: Prepare references for the translation of the current file. − Call and exit should be compatible with:

    docstate(Arg1)  ( docstate/1)

PREDICATE clean current refs/1:

Usage:

Clean the data stored by prepare_current_refs/1.

− Call and exit should be compatible with:

    docstate(Arg1)  ( docstate/1)

PREDICATE pretty cite/3:

Usage: pretty_cite(Ref,DocSt,Text)

Obtain citation text Text for Ref using the default bibliography style

REGTYPE secttree/1:

Usage: A tree of sections

PREDICATE get nav/4:

Usage: Obtain some navigation links and the tree for the current section from a global tree − Call and exit should be compatible with:

A tree of sections ( secttree/1) Arg2 is an atom. ( atm/1) Arg3 is any term. ( term/1) A tree of sections ( secttree/1)

PREDICATE secttree resolve/3:

Usage: secttree_resolve(LabelName,Tree,Link)

Locate in the section tree Tree the section with label name LabelName and return the Link to the section. − Call and exit should be compatible with:

LabelName is a string (a list of character codes). ( string/1) Intermediate tree representation for documentation ( doctree/1) A link to a document label ( doclink/1)

17.3 Documentation on imports

This module has the following direct dependencies: − Application modules:

autodoc_state, autodoc_doctree, autodoc_structure, autodoc_filesystem, autodoc_
messages, autodoc_bibrefs.

− System library modules:

aggregates, lists.

− Internal (engine) modules:

term_basic, arithmetic, atomic_basic, basiccontrol, exceptions, term_compare,
term_typing, debugger_support, basic_props.

− Packages:

prelude, initial, condcomp, dcg, assertions, assertions/assertions_basic,
regtypes, fsyntax.

18 Error messages (parsing)

Author(s): Manuel Hermenegildo. These texts are the basically the errors generated during parsing ( autodoc_parse.pl).

Other error messages are interspersed in the code.

18.1 Usage and interface

• Library usage:

 :- use_module(lpdoc(autodoc_errors)).

• Exports:

− Predicates:

    error_text/3.

18.2 Documentation on exports

PREDICATE error text/3:

No further documentation available for this predicate.

18.3 Documentation on imports

This module has the following direct dependencies: − Internal (engine) modules:

term_basic, arithmetic, atomic_basic, basiccontrol, exceptions, term_compare,
term_typing, debugger_support, basic_props, hiord_rt.

− Packages:

prelude, initial, condcomp, assertions, assertions/assertions_basic, regtypes,
basicmodes.

52 The LPdoc Internals Manual

19 Resolution of bibliographical references

Author(s): Manuel Hermenegildo (original version), Jose F. Morales. This module provides a predicate to resolve the bibliographical references found during the

generation of documentation.

19.1 Usage and interface

• Library usage:

:- use_module(lpdoc(autodoc_bibrefs)).

• Exports:

− Predicates:

   resolve_bibliography/1, parse_commands/3.

19.2 Documentation on exports

PREDICATE resolve bibliography/1:

Usage: resolve_bibliography(DocSt)

This predicate resolves bibliographical references. The algorithm is as follows: • Write all the bibliographical references to a .aux file.

• Invoke BibTeX with a customized .bst file that generates a pseudo-docstring.

• Load the docstring and fix its syntax.

• Parse the docstring as a doctree.

• Extract (Label,Ref) pairs from bibitem commands. Both the docstring and label/reference pairs are kept in the DocSt, and used later to map symbolic references to textual labels. − The following properties should hold at call time:

    docstate(DocSt)  ( docstate/1)

PREDICATE parse commands/3:

No further documentation available for this predicate.

19.3 Documentation on imports

This module has the following direct dependencies: − Application modules:

autodoc_state, autodoc_doctree, autodoc_refsdb, autodoc_settings, autodoc_
filesystem, autodoc_aux, autodoc_messages, autodoc_parse.

− System library modules:

dict, aggregates, terms, stream_utils, lists, format, pathnames, system.

− Internal (engine) modules:

term_basic, arithmetic, atomic_basic, basiccontrol, exceptions, term_compare,
term_typing, debugger_support, basic_props, stream_basic.

54 The LPdoc Internals Manual − Packages:

prelude, initial, condcomp, dcg, assertions, assertions/assertions_basic,
regtypes, fsyntax.

20 Auxiliary definitions

Author(s): Manuel Hermenegildo, Jose F. Morales.

20.1 Usage and interface

• Library usage:

 :- use_module(lpdoc(autodoc_aux)).

• Exports:

− Predicates:

    all_vars/1, read_file/2, ascii_blank_lines/2, autodoc_process_call/3, cmd_
    logbase/3.

20.2 Documentation on exports

PREDICATE all vars/1:

No further documentation available for this predicate.

PREDICATE read file/2:

No further documentation available for this predicate.

PREDICATE ascii blank lines/2:

No further documentation available for this predicate.

PREDICATE autodoc process call/3:

No further documentation available for this predicate.

PREDICATE cmd logbase/3:

No further documentation available for this predicate.

20.3 Documentation on imports

This module has the following direct dependencies: − Application modules:

autodoc_messages, autodoc_settings, autodoc_filesystem.

− System library modules:

system, logged_process, pathnames.

− Internal (engine) modules:

term_basic, arithmetic, atomic_basic, basiccontrol, exceptions, term_compare,
term_typing, debugger_support, basic_props, hiord_rt, stream_basic, io_basic.

− Packages:

prelude, initial, condcomp, assertions, assertions/assertions_basic, regtypes,
basicmodes, fsyntax.

56 The LPdoc Internals Manual

21 Image handling

Author(s): Jose F. Morales. This module defines the handling of image commands. It defines predicates to locate and

convert images in the different formats required for documentation.

21.1 Usage and interface

• Library usage:

 :- use_module(lpdoc(autodoc_images)).

• Exports:

− Predicates:

    locate_and_convert_image/4, clean_image_cache/0.

21.2 Documentation on exports

PREDICATE locate and convert image/4:

 Usage: locate_and_convert_image(SrcSpecS,AcceptedExts,DocSt,TargetFileS)

The image at SrcSpecS is located (as one of the known image extensions imgext/1) and converted to one of the AcceptedExts. The target file is called TargetFileS − Call and exit should be compatible with:

SrcSpecS is a string (a list of character codes). ( string/1)

     AcceptedExts is a list of atms.  ( list/2)
     docstate(DocSt)  ( docstate/1)

TargetFileS is a string (a list of character codes). ( string/1)

PREDICATE clean image cache/0:

Usage: Clean the cache for image copy/conversions.

21.3 Documentation on imports

This module has the following direct dependencies: − Application modules:

autodoc_state, autodoc_filesystem, autodoc_settings, autodoc_messages.

− System library modules:

datafacts_rt, lists, system, system_extra, process, pathnames, format.

− Internal (engine) modules:

term_basic, arithmetic, atomic_basic, basiccontrol, exceptions, term_compare,
term_typing, debugger_support, basic_props, stream_basic.

− Packages:

prelude, initial, condcomp, dcg, assertions, assertions/assertions_basic,
regtypes, fsyntax, datafacts.

58 The LPdoc Internals Manual References 59

References

(this section is empty)

60 The LPdoc Internals Manual Library/Module Index 61

Library/Module Index

A

autodoc . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7 autodoc_aux. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55 autodoc_bibrefs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 53 autodoc_doctree . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17 autodoc_errors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51 autodoc_filesystem . . . . . . . . . . . . . . . . . . . . . . . . . . . 41 autodoc_html. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33 autodoc_html_assets . . . . . . . . . . . . . . . . . . . . . . . . . . 35 autodoc_html_template . . . . . . . . . . . . . . . . . . . . . . . . 37 autodoc_images . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 57 autodoc_index. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47 autodoc_man. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39 autodoc_refsdb . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 49 autodoc_settings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25 autodoc_state. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11 autodoc_structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 autodoc_texinfo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31

D

docmaker . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5

62 The LPdoc Internals Manual Predicate Index 63

Predicate Index

A

absfile_for_aux/3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43 absfile_for_subtarget/4 . . . . . . . . . . . . . . . . . . . . . . 43 absfile_to_relfile/3 . . . . . . . . . . . . . . . . . . . . . . . . . 44 add_vpath/1. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41 all_component_specs/1 . . . . . . . . . . . . . . . . . . . . . . . . 23 all_indices/2. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15 all_setting_values/2 . . . . . . . . . . . . . . . . . . . . . . . . . 26 all_vars/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55 ascii_blank_lines/2 . . . . . . . . . . . . . . . . . . . . . . . . . . 55 asset_file/2. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35 autodoc_compute_grefs/3 . . . . . . . . . . . . . . . . . . . . . . . 8

autodoc_escape_string_hook/5 . . . . . . . . . 21, 31, 33

autodoc_finish/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8 autodoc_finish_hook/1 . . . . . . . . . . . . . . . 9, 32, 33, 39

autodoc_gen_alternative/2. . . . . . . . . . . . . . . . . . . . . 8
autodoc_gen_alternative_hook/2 . . . . . 9, 32, 33, 39

autodoc_gen_doctree/5 . . . . . . . . . . . . . . . . . . . . . . . . . 8

autodoc_is_operational/2 . . . . . . . . . . . . . . . . . . . . . . 8
autodoc_is_operational_hook/2 . . . . . . 9, 31, 33, 39

autodoc_option/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25 autodoc_process_call/3 . . . . . . . . . . . . . . . . . . . . . . . 55

autodoc_rw_command_hook/4 . . . . . . . . . 21, 31, 33, 39
autodoc_translate_doctree/3 . . . . . . . . . . . . . . . . . . 8

awk/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26

B

backend_alt_format/2 . . . . . . . . . . . . . . . . . . . . . . . . . 11

backend_ignores_components/1 . . . . . . . . . . . . . . . . 11

bibtex/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26 bind_dict_varnames/1 . . . . . . . . . . . . . . . . . . . . . . . . . 15

C

clean_all/0. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 44 clean_all_temporary/0 . . . . . . . . . . . . . . . . . . . . . . . . 44

clean_autodoc_settings/0. . . . . . . . . . . . . . . . . . . . . 25

clean_current_refs/1 . . . . . . . . . . . . . . . . . . . . . . . . . 49 clean_docs_no_texi/0 . . . . . . . . . . . . . . . . . . . . . . . . . 44 clean_docstr/0 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 clean_fs_db/0. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43 clean_image_cache/0 . . . . . . . . . . . . . . . . . . . . . . . . . . 57 clean_intermediate/0 . . . . . . . . . . . . . . . . . . . . . . . . . 44 cleanup_vpath/0 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41 cmd_logbase/3. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55 cmd_type/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17 codetype/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47

compute_refs_and_biblio/1. . . . . . . . . . . . . . . . . . . . 49

convertc/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26 custom_doc/2. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15 custom_html_layout/0 . . . . . . . . . . . . . . . . . . . . . . . . . 26

D

doc_assertion_read/9 . . . . . . . . . . . . . . . . . . . . . . . . . 15 doc_cmd/3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5 doc_cmd_rw/2. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21 doc_cmd_type/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21 doclink_at/2. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19 doclink_is_local/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . 19 docst_backend/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 docst_currmod/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 docst_currmod_is_main/1 . . . . . . . . . . . . . . . . . . . . . . 13 docst_filetype/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15 docst_gdata/3. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14 docst_gdata_clean/1 . . . . . . . . . . . . . . . . . . . . . . . . . . 14 docst_gdata_query/2 . . . . . . . . . . . . . . . . . . . . . . . . . . 14 docst_gdata_query/3 . . . . . . . . . . . . . . . . . . . . . . . . . . 14 docst_gdata_restore/1 . . . . . . . . . . . . . . . . . . . . . . . . 14 docst_gvar_restore/2 . . . . . . . . . . . . . . . . . . . . . . . . . 14 docst_gvar_save/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14 docst_has_index/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14 docst_inputfile/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 docst_mdata_assertz/2 . . . . . . . . . . . . . . . . . . . . . . . . 14 docst_mdata_clean/1 . . . . . . . . . . . . . . . . . . . . . . . . . . 14 docst_mdata_save/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . 14 docst_modname/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13 docst_mvar_get/3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13 docst_mvar_lookup/3 . . . . . . . . . . . . . . . . . . . . . . . . . . 13 docst_mvar_replace/4 . . . . . . . . . . . . . . . . . . . . . . . . . 13 docst_new_no_src/4 . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 docst_new_sub/3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13 docst_new_with_src/5 . . . . . . . . . . . . . . . . . . . . . . . . . 12 docst_no_components/1 . . . . . . . . . . . . . . . . . . . . . . . . 13 docst_opt/2. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13 docst_opts/2. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 docst_pragma/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 docst_set_currmod/3 . . . . . . . . . . . . . . . . . . . . . . . . . . 12 docst_set_opts/3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 docstr_node/4. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 doctree_concat/3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18

doctree_insert_before_subfile_section/3 . . . . 18

doctree_insert_end/3 . . . . . . . . . . . . . . . . . . . . . . . . . 18 doctree_is_empty/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . 17

doctree_prepare_docst_translate_and_write/3

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20 doctree_putvars/5 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19 doctree_restore/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19 doctree_save/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19

64 The LPdoc Internals Manual

doctree_scan_and_save_refs/2 . . . . . . . . . . . . . . . . 20

doctree_simplify/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . 19 doctree_to_rawtext/3 . . . . . . . . . . . . . . . . . . . . . . . . . 20

doctree_translate_and_write/3 . . . . . . . . . . . . . . . 20

dvips/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26

E

empty_doctree/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18 ensure_cache_dir/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . 43 ensure_output_dir/1 . . . . . . . . . . . . . . . . . . . . . . . . . . 43

ensure_output_dir_prepared/2 . . . . . . . . . . . . . . . . . 7

error_text/3. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51 escape_string/4 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20

F

file_format_name/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . 42 file_search_path/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . 27 find_doc_source/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42 find_file/2. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42 find_file/3. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42 fmt_html_template/3 . . . . . . . . . . . . . . . . . . . . . . . . . . 37 fmt_idx_env/7. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 48 fmt_index/3. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 48 fmt_infodir_entry/3 . . . . . . . . . . . . . . . . . . . . . . . . . . . 8 format_get_file/3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42 format_get_subtarget/3 . . . . . . . . . . . . . . . . . . . . . . . 42 fsmemo.deps/2. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5 fsmemo.key/2. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5 fsmemo.run/1. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5

G

get_autodoc_opts/3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7 get_cache_dir/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43 get_cache_dir0/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43 get_doc/4 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15 get_doc_changes/3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15 get_doc_pred_varnames/2 . . . . . . . . . . . . . . . . . . . . . . 15 get_docdecl/4. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15

get_first_loc_for_pred/3. . . . . . . . . . . . . . . . . . . . . 15

get_mainmod/1. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 get_mainmod_spec/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 get_mod_doc/3. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15 get_modspec/2. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 44 get_nav/4 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 50 get_output_dir/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43 get_parent_bundle/1 . . . . . . . . . . . . . . . . . . . . . . . . . . 43 get_subbase/3. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 44 get_use_outlink/4 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 48

I

idx_get_indices/3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47 img_url/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37 infodir_base/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31 insert_show_toc/3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21 is_index_cmd/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47 is_nonempty_doctree/1 . . . . . . . . . . . . . . . . . . . . . . . . 17 is_version/1. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21

L

labgen_clean/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13 labgen_get/2. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13 labgen_init/1. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13 load_settings/3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25 load_vpaths/1. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26

                                                  locate_and_convert_image/4 . . . . . . . . . . . . . . . . . . 57

M

main_output_name/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . 43

                                                  main_output_name_novers/1. . . . . . . . . . . . . . . . . . . . 43

makeinfo/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26 modname_nodoc/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 44 modspec_nodoc/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 44

N

normalize_index_cmd/3 . . . . . . . . . . . . . . . . . . . . . . . . 47

P

parent_format/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11 parse_commands/3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 53 parse_structure/0 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 pred_has_docprop/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . 15 pred_to_glob_pattern/2 . . . . . . . . . . . . . . . . . . . . . . . 44 prefix_htmlurl/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37 prepare_current_refs/1 . . . . . . . . . . . . . . . . . . . . . . . 49 prepare_html_assets/2 . . . . . . . . . . . . . . . . . . . . . . . . 35 pretty_cite/3. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 49 ps2pdf/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26

Predicate Index 65

R

read_file/2. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55 reset_output_dir_db/0 . . . . . . . . . . . . . . . . . . . . . . . . . 7 resolve_bibliography/1 . . . . . . . . . . . . . . . . . . . . . . . 53

S

section_prop/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19 section_select_prop/3 . . . . . . . . . . . . . . . . . . . . . . . . 19 secttree_resolve/3 . . . . . . . . . . . . . . . . . . . . . . . . . . . 50 setting_value/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26

setting_value_or_default/2 . . . . . . . . . . . . . . . . . . 25

settings_file/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25 standalone_docstr/1 . . . . . . . . . . . . . . . . . . . . . . . . . . 23 supported_file_format/1 . . . . . . . . . . . . . . . . . . . . . . 42

T

tex/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26 texindex/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26 typeindex/5. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47

U

using_mathjax/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35

V

verify_settings/0 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25 version_date/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21 version_numstr/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21 version_patch/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21 version_string/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21 vpath_indir/1. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41

66 The LPdoc Internals Manual Property Index 67

Property Index

(Index is nonexistent)

68 The LPdoc Internals Manual Regular Type Index 69

Regular Type Index

B

backend_id/1. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11

D

doclabel/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18 doclink/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18 docstate/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 doctokens/1. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19 doctree/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17

F

filename/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41 filename_noext/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41

S

secttree/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 49 subtarget/1. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42

70 The LPdoc Internals Manual Declaration Index 71

Declaration Index

(Index is nonexistent)

72 The LPdoc Internals Manual Concept Index 73

Concept Index

A

automatic documentation library . . . . . . . . . . . . . . . . . 7 documentation format . . . . . . . . . . . . . . . . . . . . . . . . . . . 7

S

supported documentation formats . . . . . . . . . . . . . . . . 8

74 The LPdoc Internals Manual Author Index 75

Author Index

J

Jose F. Morales … 5, 7, 11, 17, 23, 25, 31, 33, 35, 37, 39, 41, 47, 49, 53, 55, 57

M

Manuel Hermenegildo. . 5, 7, 11, 17, 31, 39, 51, 53, 55

76 The LPdoc Internals Manual Global Index 77

Global Index

This is a global index containing pointers to places where concepts, predicates, modes, properties, types, applications, authors, etc., are referred to in the text of the document.

A

absfile_for_aux/3 . . . . . . . . . . . . . . . . . . . . . . . . . 41, 43

absfile_for_subtarget/4 . . . . . . . . . . . . . . . . . . 41, 43

absfile_to_relfile/3. . . . . . . . . . . . . . . . . . . . . . 41, 44 add_vpath/1. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41 aggregates . . . . . . . 6, 9, 16, 24, 27, 34, 45, 48, 50, 53 all_component_specs/1 . . . . . . . . . . . . . . . . . . . . . . . . 23 all_indices/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11, 15 all_setting_values/2. . . . . . . . . . . . . . . . . . . . . . 25, 26 all_vars/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55 arithmetic … 6, 9, 16, 22, 24, 27, 32, 34, 35, 37, 39,

45, 48, 50, 51, 53, 55, 57 ascii_blank_lines/2 . . . . . . . . . . . . . . . . . . . . . . . . . . 55 assertions …. 6, 7, 9, 16, 22, 24, 27, 32, 34, 35, 37,

39, 45, 48, 50, 51, 54, 55, 57

assertions/assertions_basic . . 6, 9, 16, 22, 24, 27,

32, 34, 35, 37, 39, 45, 48, 50, 51, 54, 55, 57 assertions_props . . . . . . . . . . . . . . . . . . . . . . . . . . . 9, 16 asset_file/2. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35 assrt_lib . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9, 16 atm/1 . . . . . . . . . . . . . . . . . . . 7, 8, 19, 37, 42, 44, 47, 50 atom/1. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20, 47 atomic_basic …. 6, 9, 16, 22, 24, 27, 32, 34, 35, 37,

39, 45, 48, 50, 51, 53, 55, 57 autodoc . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6, 7 autodoc_aux . . . . . . . . . . . . . . . . . . . 9, 16, 32, 39, 53, 55 autodoc_bibrefs . . . . . . . . . . . . . . . . . . . . . . . . . . . 50, 53

autodoc_compute_grefs/3 . . . . . . . . . . . . . . . . . . . . 7, 8

autodoc_doctree …. 9, 16, 17, 32, 34, 39, 48, 50, 53 autodoc_errors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51

autodoc_escape_string_hook/5 . . . . . . 17, 21, 31, 33

autodoc_filesystem. . 6, 9, 16, 22, 27, 32, 34, 35, 41,

48, 50, 53, 55, 57 autodoc_finish/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7, 8 autodoc_finish_hook/1 . . . . . . . . . 7, 9, 31, 32, 33, 39

autodoc_gen_alternative/2 . . . . . . . . . . . . . . . . . . 7, 8
autodoc_gen_alternative_hook/2 . . 7, 9, 31, 32, 33,

39 autodoc_gen_doctree/5. . . . . . . . . . . . . . . . . . . . . . . 7, 8 autodoc_html . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7, 22, 33 autodoc_html_assets . . . . . . . . . . . . . . . . . . . . 9, 34, 35 autodoc_html_template . . . . . . . . . . . . . . . . . . . . 34, 37 autodoc_images . . . . . . . . . . . . . . . . . . . 6, 32, 34, 39, 57 autodoc_index. . . . . . . . . . . . . . . . . 9, 16, 22, 32, 34, 47

autodoc_is_operational/2 . . . . . . . . . . . . . . . . . . . 7, 8
autodoc_is_operational_hook/2 . . . . 7, 9, 31, 33, 39

autodoc_man . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7, 22, 39 autodoc_messages. … 6, 9, 16, 22, 27, 32, 34, 35, 50,

53, 55, 57 autodoc_nil. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22 autodoc_option/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . 5, 25 autodoc_parse . . . . . . . . . . . . . . . . . . . . . . . . . . . 9, 16, 53 autodoc_parse.pl . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51 autodoc_process_call/3 . . . . . . . . . . . . . . . . . . . . . . . 55 autodoc_refsdb . . . . . . . . . . . . 9, 16, 22, 34, 48, 49, 53

                                                  autodoc_rw_command_hook/4 . . . . . . 17, 21, 31, 33, 39

autodoc_settings. … 6, 9, 16, 22, 24, 25, 32, 34, 35,

37, 45, 53, 55, 57 autodoc_state … 6, 9, 11, 22, 32, 34, 39, 45, 48, 50,

53, 57 autodoc_structure . . 6, 9, 16, 22, 23, 32, 34, 45, 48,

50 autodoc_texinfo . . . . . . . . . . . . . . . . . . . . 6, 7, 9, 22, 31

                                                  autodoc_translate_doctree/3 . . . . . . . . . . . . . . . . 7, 8
                                                  automatic documentation library . . . . . . . . . . . . . . . 7

awk/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25, 26

B

backend_alt_format/2 . . . . . . . . . . . . . . . . . . . . . . . . . 11 backend_id/1. . . . . . . . . . . . . . . . . . 8, 11, 31, 33, 39, 42

                                                  backend_ignores_components/1 . . . . . . . . . . . . . . . . 11

basic_props . . 6, 9, 16, 22, 24, 27, 32, 34, 35, 37, 39,

45, 48, 50, 51, 53, 55, 57 basiccontrol …. 6, 9, 16, 22, 24, 27, 32, 34, 35, 37,

39, 45, 48, 50, 51, 53, 55, 57 basicmodes . . . . . . . . . . . . . . 6, 9, 16, 22, 24, 45, 51, 55 bibtex/1. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25, 26 bind_dict_varnames/1. . . . . . . . . . . . . . . . . . . . . . 11, 15 bundle_info. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 45 bundle_paths . . . . . . . . . . . . . . . . . . . . . . . . 9, 27, 35, 45

C

c_itf . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9, 16 clean_all/0 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41, 44 clean_all_temporary/0 . . . . . . . . . . . . . . . . . . . . 41, 44

                                                  clean_autodoc_settings/0. . . . . . . . . . . . . . . . . . . . . 25

clean_current_refs/1 . . . . . . . . . . . . . . . . . . . . . . . . . 49 clean_docs_no_texi/0. . . . . . . . . . . . . . . . . . . . . . 41, 44 clean_docstr/0 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 clean_fs_db/0 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41, 43 clean_image_cache/0 . . . . . . . . . . . . . . . . . . . . . . . . . . 57 clean_intermediate/0. . . . . . . . . . . . . . . . . . . . . . 41, 44 cleanup_vpath/0 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41 cmd_logbase/3. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55 cmd_type/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17 codetype/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47 comments . . . . . . . . . . . . . . . . . . . . . . 9, 16, 22, 32, 34, 39 compiler . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6, 9, 16

compute_refs_and_biblio/1. . . . . . . . . . . . . . . . . . . . 49

condcomp . . 6, 9, 16, 22, 24, 27, 32, 34, 35, 37, 39, 45,

48, 50, 51, 54, 55, 57 convertc/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25, 26 custom_doc/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11, 15 custom_html_layout/0. . . . . . . . . . . . . . . . . . . . . . 25, 26

D

datafacts . . . . . . . . . . . . . . . . . 9, 16, 24, 27, 35, 45, 57 datafacts_rt . . . . . . . . . . . . . . 9, 16, 24, 27, 35, 45, 57 dcg . . . . . . . . . . . 6, 9, 16, 22, 24, 27, 45, 48, 50, 54, 57 debugger_support. … 6, 9, 16, 22, 24, 27, 32, 34, 35,

37, 39, 45, 48, 50, 51, 53, 55, 57 dict . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16, 34, 48, 53 doc_assertion_read/9. . . . . . . . . . . . . . . . . . . . . . 11, 15 doc_cmd/3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5 doc_cmd_rw/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17, 21 doc_cmd_type/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17, 21 doccfg . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5, 25 doccfg_holder. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27 doccfg_props . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9, 16 doclabel/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17, 18 doclink/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17, 18, 50 doclink_at/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17, 19 doclink_is_local/1 . . . . . . . . . . . . . . . . . . . . . . . . 17, 19 docmaker . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5 docmod_holder. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6 docst_backend/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . 11, 12 docst_currmod/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . 11, 12

docst_currmod_is_main/1 . . . . . . . . . . . . . . . . . . 11, 13

docst_filetype/2 . . . . . . . . . . . . . . . . . . . . . . . . . . 11, 15 docst_gdata/3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11, 14 docst_gdata_clean/1. . . . . . . . . . . . . . . . . . . . . . . 11, 14 docst_gdata_query/2. . . . . . . . . . . . . . . . . . . . . . . 11, 14 docst_gdata_query/3. . . . . . . . . . . . . . . . . . . . . . . 11, 14 docst_gdata_restore/1 . . . . . . . . . . . . . . . . . . . . 11, 14 docst_gvar_restore/2. . . . . . . . . . . . . . . . . . . . . . 11, 14 docst_gvar_save/2 . . . . . . . . . . . . . . . . . . . . . . . . . 11, 14 docst_has_index/2 . . . . . . . . . . . . . . . . . . . . . . . . . 11, 14 docst_inputfile/2 . . . . . . . . . . . . . . . . . . . . . . . . . 11, 12 docst_mdata_assertz/2 . . . . . . . . . . . . . . . . . . . . 11, 14 docst_mdata_clean/1. . . . . . . . . . . . . . . . . . . . . . . 11, 14 docst_mdata_save/1 . . . . . . . . . . . . . . . . . . . . . . . . 11, 14 docst_modname/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . 11, 13 docst_mvar_get/3 . . . . . . . . . . . . . . . . . . . . . . . . . . 11, 13 docst_mvar_lookup/3. . . . . . . . . . . . . . . . . . . . . . . 11, 13 docst_mvar_replace/4. . . . . . . . . . . . . . . . . . . . . . 11, 13 docst_new_no_src/4 . . . . . . . . . . . . . . . . . . . . . . . . 11, 12 docst_new_sub/3 . . . . . . . . . . . . . . . . . . . . . . . . . . . 11, 13 docst_new_with_src/5. . . . . . . . . . . . . . . . . . . . . . 11, 12 docst_no_components/1 . . . . . . . . . . . . . . . . . . . . 11, 13 docst_opt/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11, 13 docst_opts/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11, 12 docst_pragma/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11, 12 docst_set_currmod/3. . . . . . . . . . . . . . . . . . . . . . . 11, 12 docst_set_opts/3 . . . . . . . . . . . . . . . . . . . . . . . . . . 11, 12 docstate(Arg1) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 49 docstate(Arg3) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20 docstate(DocSt) . . . . . . . . . . . 8, 20, 31, 33, 39, 53, 57 docstate/1 . . . . . . 8, 11, 12, 20, 31, 33, 39, 49, 53, 57 docstr_node/4. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 doctokens/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17, 19 doctree/1 . . . . . . 17, 18, 19, 20, 21, 31, 33, 39, 47, 50 doctree_concat/3 . . . . . . . . . . . . . . . . . . . . . . . . . . 17, 18

                                                  doctree_insert_before_subfile_section/3 . . . . 17,

18 doctree_insert_end/3. . . . . . . . . . . . . . . . . . . . . . 17, 18 doctree_is_empty/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . 17

                                                  doctree_prepare_docst_translate_and_write/3

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17, 20 doctree_putvars/5 . . . . . . . . . . . . . . . . . . . . . . . . . 17, 19 doctree_restore/2 . . . . . . . . . . . . . . . . . . . . . . . . . 17, 19 doctree_save/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17, 19

                                                  doctree_scan_and_save_refs/2 . . . . . . . . . . . . . 17, 20

doctree_simplify/2 . . . . . . . . . . . . . . . . . . . . . . . . 17, 19 doctree_to_rawtext/3. . . . . . . . . . . . . . . . . . . . . . 17, 20

                                                  doctree_translate_and_write/3 . . . . . . . . . . . . 17, 20

documentation format . . . . . . . . . . . . . . . . . . . . . . . . . . 7 dvips/1. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25, 26

E

empty_doctree/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . 17, 18 ensure_cache_dir/1 . . . . . . . . . . . . . . . . . . . . . . . . 41, 43 ensure_output_dir/1. . . . . . . . . . . . . . . . . . . . . . . 41, 43

                                                  ensure_output_dir_prepared/2 . . . . . . . . . . . . . . . . . 7

error_text/3. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51 escape_string/4 . . . . . . . . . . . . . . . . . . . . . . . . . . . 17, 20 exceptions … 6, 9, 16, 22, 24, 27, 32, 34, 35, 37, 39,

45, 48, 50, 51, 53, 55, 57

Global Index 79

F

file_format_name/2 . . . . . . . . . . . . . . . . . . . . . . . . 41, 42 file_search_path/2 . . . . . . . . . . . . . . . . . . . . . . . . 25, 27 filename/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41 filename_noext/1. . . . . . . . . . . . . . . . . . . . . . . . 8, 41, 44 find_doc_source/2 . . . . . . . . . . . . . . . . . . . . . . . . . 41, 42 find_file/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41, 42 find_file/3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41, 42 fmt_html_template/3 . . . . . . . . . . . . . . . . . . . . . . . . . . 37 fmt_idx_env/7 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47, 48 fmt_index/3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47, 48 fmt_infodir_entry/3 . . . . . . . . . . . . . . . . . . . . . . . . . 7, 8 format . . . . . . . . . . . . . . . . . . . . . . . . . 6, 9, 22, 32, 53, 57 format_get_file/3 . . . . . . . . . . . . . . . . . . . . . . . . . 41, 42 format_get_subtarget/3 . . . . . . . . . . . . . . . . . . . 41, 42 format_to_string . . . . . . . . . . . . . . . . . . . . . . 32, 34, 39 fsmemo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6 fsmemo.deps/2. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5 fsmemo.key/2. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5 fsmemo.run/1. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5 fsmemo_rt . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6 fsyntax … 6, 9, 16, 22, 24, 27, 32, 34, 35, 37, 39, 45,

48, 50, 54, 55, 57

G

get_autodoc_opts/3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7 get_cache_dir/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . 41, 43 get_cache_dir0/2 . . . . . . . . . . . . . . . . . . . . . . . . . . 41, 43 get_doc/4 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11, 15 get_doc_changes/3 . . . . . . . . . . . . . . . . . . . . . . . . . 11, 15

get_doc_pred_varnames/2 . . . . . . . . . . . . . . . . . . 11, 15

get_docdecl/4 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11, 15

get_first_loc_for_pred/3 . . . . . . . . . . . . . . . . . 11, 15

get_mainmod/1. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 get_mainmod_spec/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 get_mod_doc/3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11, 15 get_modspec/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41, 44 get_nav/4 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 49, 50 get_output_dir/2 . . . . . . . . . . . . . . . . . . . . . . . . . . 41, 43 get_parent_bundle/1. . . . . . . . . . . . . . . . . . . . . . . 41, 43 get_subbase/3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41, 44 get_use_outlink/4 . . . . . . . . . . . . . . . . . . . . . . . . . 47, 48 glob . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32 ground/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5

H

hiord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 45 hiord_rt . . . . . . . . . . . . . 6, 9, 16, 22, 24, 35, 45, 51, 55 html . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37

I

idx_get_indices/3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47 img_url/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37 imgext/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 57 infodir_base/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31 initial … 6, 9, 16, 22, 24, 27, 32, 34, 35, 37, 39, 45,

48, 50, 51, 54, 55, 57 insert_show_toc/3 . . . . . . . . . . . . . . . . . . . . . . . . . 17, 21 internals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6 internals manual . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1, 3 io_basic . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55 is_index_cmd/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47 is_nonempty_doctree/1 . . . . . . . . . . . . . . . . . . . . . . . . 17 is_version/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17, 21 isomodes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35

J

Jose F. Morales . . 5, 7, 11, 17, 23, 25, 31, 33, 35, 37, 39, 41, 47, 49, 53, 55, 57

L

labgen_clean/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11, 13 labgen_get/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11, 13 labgen_init/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11, 13 list/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7, 8, 57 lists . . 6, 9, 16, 22, 27, 32, 34, 35, 37, 39, 45, 48, 50,

53, 57 load_settings/3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25 load_vpaths/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25, 26

                                                  locate_and_convert_image/4 . . . . . . . . . . . . . . . . . . 57

logged_process . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55 lpdoc . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1, 3

M

main_output_name/2 . . . . . . . . . . . . . . . . . . . . . . . . 41, 43

                                                  main_output_name_novers/1 . . . . . . . . . . . . . . . . 41, 43

makeinfo/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25, 26 Manuel Hermenegildo. . 5, 7, 11, 17, 31, 39, 51, 53, 55 modname_nodoc/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . 41, 44 modspec_nodoc/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . 41, 44

N

nonvar/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17, 18, 19 normalize_index_cmd/3 . . . . . . . . . . . . . . . . . . . . . . . . 47

O

opendoc . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6 operators . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22

P

parent_format/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11 parse_commands/3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 53 parse_structure/0 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 pathnames …. 6, 9, 16, 22, 24, 27, 32, 34, 35, 37, 45,

53, 55, 57 port_reify . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6 pred_has_docprop/2 . . . . . . . . . . . . . . . . . . . . . . . . 11, 15 pred_to_glob_pattern/2 . . . . . . . . . . . . . . . . . . . 41, 44 prefix_htmlurl/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37 prelude … 6, 9, 16, 22, 24, 27, 32, 34, 35, 37, 39, 45,

48, 50, 51, 54, 55, 57 prepare_current_refs/1 . . . . . . . . . . . . . . . . . . . . . . . 49 prepare_html_assets/2 . . . . . . . . . . . . . . . . . . . . . . . . 35 pretty_cite/3. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 49 process . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 57 ps2pdf/1. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25, 26

R

read . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6, 9, 16, 22 read_file/2. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55 regtypes . . 6, 9, 16, 22, 24, 27, 32, 34, 39, 45, 48, 50,

51, 54, 55, 57 reset_output_dir_db/0 . . . . . . . . . . . . . . . . . . . . . . . . . 7 resolve_bibliography/1 . . . . . . . . . . . . . . . . . . . . . . . 53 runtime_control . . . . . . . . . . . . . . . . . . . . . . . . . . . 16, 22

S

section_prop/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17, 19 section_select_prop/3 . . . . . . . . . . . . . . . . . . . . 17, 19 secttree/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 49, 50 secttree_resolve/3 . . . . . . . . . . . . . . . . . . . . . . . . 49, 50 setting_value/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . 25, 26

setting_value_or_default/2 . . . . . . . . . . . . . . . . . . 25

settings_file/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25 source_tree . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35, 45 standalone_docstr/1 . . . . . . . . . . . . . . . . . . . . . . . . . . 23 stream_basic . . . . . . . . 6, 9, 16, 22, 27, 37, 53, 55, 57 stream_utils . . . . . . . . . . . . . . . . . . . . . 6, 32, 34, 37, 53 string/1 . . . . . . . . . . . . . . . . . . . . . . . . 20, 37, 47, 50, 57 subtarget/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41, 42

supported documentation formats . . . . . . . . . . . . . . . 8
supported_file_format/1 . . . . . . . . . . . . . . . . . . 41, 42

syntax_highlight . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 34 system . . . . . 6, 9, 16, 27, 32, 34, 35, 37, 45, 53, 55, 57 system_extra . . . . . . . . . . . . . . . . . . . . . . . 32, 34, 45, 57

T

term/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7, 8, 50 term_basic … 6, 9, 16, 22, 24, 27, 32, 34, 35, 37, 39,

45, 48, 50, 51, 53, 55, 57 term_compare …. 6, 9, 16, 22, 24, 27, 32, 34, 35, 37,

39, 45, 48, 50, 51, 53, 55, 57 term_typing . . 6, 9, 16, 22, 24, 27, 32, 34, 35, 37, 39,

45, 48, 50, 51, 53, 55, 57 terms . . . . . . . . . . . . . . . . . . . . . . 9, 16, 22, 24, 32, 45, 53 tex/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25, 26 texindex/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25, 26 typeindex/5. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47

U

using_mathjax/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35

V

var/1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18 verify_settings/0 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25 version_date/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17, 21 version_numstr/2 . . . . . . . . . . . . . . . . . . . . . . . . . . 17, 21 version_patch/2 . . . . . . . . . . . . . . . . . . . . . . . . . . . 17, 21 version_string/2 . . . . . . . . . . . . . . . . . . . . . . . . . . 17, 21 vpath_indir/1. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41

W

write . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16, 22