#lang scribble/doc @(require scribble/manual (for-label racket scribble/core scribble/base scribble/html-properties scriblib/render-cond "common.rkt" "slides.rkt")) @title{BystroTeX} This manual is not very useful, because most of the functions are auto-generated by macros. The beginner user should find the instructions in the form of a slide presentation @hyperlink["http://www.ift.unesp.br/users/yurevich/slides/bystroTeX/slides-manual/index.html"]{here}, and also study the sample file @tt{slides-manual.scrbl}, which is in the samples directory. This sample file can be used as a template for creating new presentations. @defmodule[(planet amkhlv/bystroTeX/common)] @;@defmodule[amkhlv/bystroTeX/common] @defproc[(amkhlv/js [x string?]) (traverse-element?) ]{Javascript injection} @defproc[(amkhlv/js-url [url string?]) (traverse-element?) ]{Insert Javascript from URL} @defproc[(amkhlv/path-to-link [x string?]) (string) ]{Returns the string representing a file URL for the UNIX path represented by @racket[x]} @defproc[(amkhlv/elemstyle [x string?]) (style?) ]{Style selector for element. Example of use: @racket[@element[@amkhlv/elemstyle{vertical-align:middle} @image{flowers-on-the-wall.png}]] } @defproc[(amkhlv/rectangular-table? [l any]) (boolean?)]{Verifies if @racket[l] is a list of lists representing a rectangular table} @defproc[(amkhlv/table [rows amkhlv/rectangular-table?] [#:orient dirn (or/c 'hor 'vert #f)])(table)]{To insert a table} @defproc[(amkhlv/verb [x string?] [#:indent i exact-nonnegative-integer?] [#:rest xs (listof string?)]) (block)]{ Like @racket[(verbatim x #:indent i xs)] but modified so that copy-past does not introduce extra linebreaks } @defproc[(amkhlv/clr [colorname string?] [#:rest xs (listof string?)]) (element)]{ Colored text.} @;@defmodule[amkhlv/bystroTeX/slides] @defmodule[(planet amkhlv/bystroTeX/slides)] @defproc[(amkhlv/titlepage-init) (element)]{ Installs the titlepage style} @defproc[ (amkhlv/slide [x content?] [#:tag tg (or/c symbol? string? #f) #f] [#:showtitle sttl boolean? #f] [#:rest xs (listof pre-flow?)] ) (part?)]{ A basic slide. The title of the slide is @racket[x], and the contents are @racket[xs]. I recommend providing a nice tag @racket[tg], which will serve as a filename for the html. Otherwize, @racket[x] will be used as a filename, which may lead to awkward effects. } @defproc[ (amkhlv/afterpause [#:tag tg (or/c symbol? string? #f) #f] [#:rest xs (listof pre-flow?)] ) (part?)]{ The continuation of the slide to be shown after pause. } @defproc[(amkhlv/remove)(void?)]{ Removes the most recently shown part of the slide } @defproc[ (amkhlv/initialize-formula-collection [x string?] [y string?] ) (db?)]{ This is to initialize the formula collection. The name of the @tt{sqlite} database is @racket[x], and the name of the folder for keeping @tt{png} files is @racket[y]. This function should not be called by the user, because it is called automatically. } @defproc[ (amkhlv/number-for-formula [x string?] ) (string?)]{ Like @literal|{\label{...}}| in @tt{LaTeX}, the label is @racket[x]. } @defproc[ (amkhlv/ref-formula [x string?] ) (string?)]{ Like @literal|{\ref{...}}| in @tt{LaTeX}, reference to the label @racket[x]. } @defproc[ (amkhlv/command-to-typeset-formula [comm path-string?] [tex string?] [n number?] [fn string?] ) (string?)]{ This should not be directly called by the user. Just for reference, @racket[comm] is the path to an executable, which has the following properties. That executable should take 3 arguments: a @tt{LaTeX} string @racket[tex] representing a formula, a number @racket[n] which is the intended fontsize of the formula, and a string @racket[fn] which is the filename, which should have extension @tt{.png}. The executable, upon success, should return a number representing the vertical offset. (Because e.g. letters x and y have different vertical offset.) } @defproc[ (amkhlv/formula [#:database x db?] [#:formulas-in-dir y string?] [#:shell-command z path? #f] [#:size n natural-number/c] [#:align m (or/c (integer-in (- 99) 99) #f) #f] [#:use-depth ud boolean? #f] [#:aa-adjust aa-adj (integer-in (- 99) 99) 0] [#:rest tex (listof string?)]) (element?)]{ The user probably will not want to call this procedure directly, because there are various auto-generated shortcuts. } @defproc[ (amkhlv/equation [tex (listof string?)] [#:hspace hs natural-number/c] [#:database x db?] [#:formulas-in-dir y string?] [#:shell-command z path?] [#:size n natural-number/c] [#:label l (or/c string? #f) #f] [#:aa-adjust aa-adj (integer-in (- 99) 99) 0] ) (nested-flow?)]{ Display-style formula. But it should not be called directly, because there is a shortcut defined in the headers of the slide file. }