;;; lib.skb -- Standard library. ;;; -*- coding: iso-8859-1 -*- ;;; ;;; Copyright 2007, 2008 Ludovic Courtès ;;; Copyright 2003 Erick Gallesio ;;; ;;; ;;; This file is part of Skribilo. ;;; ;;; Skribilo is free software: you can redistribute it and/or modify ;;; it under the terms of the GNU General Public License as published by ;;; the Free Software Foundation, either version 3 of the License, or ;;; (at your option) any later version. ;;; ;;; Skribilo is distributed in the hope that it will be useful, ;;; but WITHOUT ANY WARRANTY; without even the implied warranty of ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ;;; GNU General Public License for more details. ;;; ;;; You should have received a copy of the GNU General Public License ;;; along with Skribilo. If not, see . (chapter :title "Standard Library" (p [This section describes Skribilo's standard library.]) ;;; (section :title "File Functions" (p [The function ,(code "include") is particularily useful to spread a long document amongst several files.]) (doc-markup 'include '((file [The file containing the nodes to be included. These nodes are included in the document in place of the ,(code "include") call.])) :common-args '() :see-also '(*document-path*) :idx *function-index*) (p [The given file is searched in the current ,(ref :mark "*document-path*" :text "document path").]) (p [Skribilo provides functions to deal with paths. These functions are related to the path that can be specified on the command line, when the Skribilo compiler is invoked (see Chapter ,(ref :ident "compiler").)]) (doc-markup '*document-path* '() ;;:skribe-source? #f ;;:source "skribilo/parameters.scm" :source #f :def '(define (*document-path* #!optional opt) ...) :common-args '() :others '() :see-also '(include *image-path* *bib-path* *source-path*) :idx *function-index*) (index :index *function-index* "skribe-path") (index :index *function-index* "skribe-path-set!") (p [,(tt [*document-path*]) is a procedure as returned by ,(srfi-ref 39) ,(tt [make-parameter]). As such, ,(tt [(*document-path*)]) returns the current document path, while ,(tt [(*document-path* '("." "/some/path"))]) changes the value of the current path. This is equivalent to Skribe's ,(tt [skribe-path]) and ,(tt [skribe-path-set!]) functions. The value of ,(tt [*document-path*]) can also be changed using the ,(tt [-I]) command-line option of the compiler (see ,(numref :text [Chapter] :ident "compiler") for details).])) ;;; Misc (section :title "Configuration Functions" :ident "config-module" (p [Several functions describing the configuration of Skribilo are exported by the ,(code [(skribilo config)]) module. First, the ,(code "skribilo-version") function returns the version of Skribilo being used as a string.] (doc-markup 'skribilo-version '() :common-args '() :source "skribilo/config.scm" :idx *function-index*)) (p [For instance, the following piece of code:]) (prgm :language skribe "[This manual documents version ,(bold (skribilo-version)) of Skribilo.]") (p [produces the following output]) (disp [This manual documents version ,(bold (skribilo-version)) of Skribilo.]) (p [The ,(code "skribilo-url") function returns, not surprisingly, the URL of the project:] (doc-markup 'skribilo-url '() :common-args '() :source "skribilo/config.scm" :idx *function-index*)) (p [The ,(code [skribilo-module-directory]) returns the directory under which Skribilo modules were installed:] (doc-markup 'skribilo-module-directory '() :common-args '() :source "skribilo/config.scm" :idx *function-index*) [Similar information can be obtained using the ,(code [skribilo-config]) program, as described in ,(numref :text [Section] :ident "skribilo-config").]))) ;;; Local Variables: ;;; ispell-local-dictionary: "american" ;;; End: