rackety slideshow doc

original commit: ce21cf9fd88736fae321b865269cb379bb674baa
This commit is contained in:
Matthew Flatt 2010-05-02 12:19:25 -06:00
parent 15e7763f70
commit 637b443ddc
4 changed files with 21 additions and 21 deletions

View File

@ -42,7 +42,7 @@ To document a collection or @|PLaneT| package:
@racket[racket] for writing Racket documentation.} @racket[racket] for writing Racket documentation.}
@item{Add the following entry to your collect or package's @item{Add the following entry to your collect or package's
@filepath{info.ss}: @filepath{info.rkt}:
@racketblock[ @racketblock[
(define scribblings '(("manual.scrbl" ()))) (define scribblings '(("manual.scrbl" ())))
@ -54,7 +54,7 @@ To document a collection or @|PLaneT| package:
the whole right-hand side of the definition is already the whole right-hand side of the definition is already
quoted). quoted).
If you do not already have an @filepath{info.ss} module, If you do not already have an @filepath{info.rkt} module,
here's a suitable complete module: here's a suitable complete module:
@racketmod[ @racketmod[
@ -172,7 +172,7 @@ The following example illustrates section hyperlinks:
}| }|
Since the page is so short, the hyperlinks in the above example are Since the page is so short, the hyperlinks in the above example are
more effective if you change the @filepath{info.ss} file to add the more effective if you change the @filepath{info.rkt} file to add the
@racket['multi-file] flag: @racket['multi-file] flag:
@racketblock[ @racketblock[
@ -213,22 +213,22 @@ and they declare hyperlink targets for @racket[racket]-based
hyperlinks. hyperlinks.
To document a @racket[my-helper] procedure that is exported by To document a @racket[my-helper] procedure that is exported by
@filepath{helper.ss} in the @filepath{my-lib} collection that contains @filepath{helper.rkt} in the @filepath{my-lib} collection that contains
@filepath{manual.scrbl}: @filepath{manual.scrbl}:
@itemize[ @itemize[
@item{Use @racket[(require (for-label "helper.ss"))] to import the @item{Use @racket[(require (for-label "helper.rkt"))] to import the
binding information about the bindings of @filepath{helper.ss} binding information about the bindings of @filepath{helper.rkt}
for use when typesetting identifiers. A relative reference for use when typesetting identifiers. A relative reference
@racket["helper.ss"] works since it is relative to the @racket["helper.rkt"] works since it is relative to the
documentation source.} documentation source.}
@item{Add a @tt|{@defmodule[my-lib/helper]}| declaration, which @item{Add a @tt|{@defmodule[my-lib/helper]}| declaration, which
specifies the library that is being documented within the specifies the library that is being documented within the
section. The @racket[defmodule] form needs an absolute module section. The @racket[defmodule] form needs an absolute module
name @racket[mylib/helper], instead of a relative reference name @racket[mylib/helper], instead of a relative reference
@racket["helper.ss"], since the module path given to @racket["helper.rkt"], since the module path given to
@racket[defmodule] appears verbatim in the generated @racket[defmodule] appears verbatim in the generated
documentation.} documentation.}
@ -244,7 +244,7 @@ following:
@verbatim[#:indent 2]|{ @verbatim[#:indent 2]|{
#lang scribble/manual #lang scribble/manual
@(require (for-label racket @(require (for-label racket
"helper.ss")) "helper.rkt"))
@title{My Library} @title{My Library}
@ -290,7 +290,7 @@ generates:
@item{If you use @racket[my-helper] in any documentation now, as long @item{If you use @racket[my-helper] in any documentation now, as long
as that documentation source also has a @racket[(require as that documentation source also has a @racket[(require
(for-label ....))] of @filepath{helper.ss}, then the (for-label ....))] of @filepath{helper.rkt}, then the
reference is hyperlinked to the definition above.} reference is hyperlinked to the definition above.}
] ]
@ -309,15 +309,15 @@ To use @racket[examples], the procedures to document must be suitable
for use at documentation time; in fact, @racket[examples] uses for use at documentation time; in fact, @racket[examples] uses
bindings introduced into the document source by bindings introduced into the document source by
@racket[require]. Thus, to generate examples using @racket[my-helper] @racket[require]. Thus, to generate examples using @racket[my-helper]
from the previous section, @filepath{helper.ss} must be imported both from the previous section, @filepath{helper.rkt} must be imported both
via @racket[require-for-label] and @racket[require]: via @racket[require-for-label] and @racket[require]:
@verbatim[#:indent 2]|{ @verbatim[#:indent 2]|{
#lang scribble/manual #lang scribble/manual
@(require scribble/eval ; <--- added @(require scribble/eval ; <--- added
"helper.ss" ; <--- added "helper.rkt" ; <--- added
(for-label racket (for-label racket
"helper.ss")) "helper.rkt"))
@title{My Library} @title{My Library}
@ -365,7 +365,7 @@ Revising @filepath{cows.scrbl} from the previous section:
See @secref["singing"]. See @secref["singing"].
}| }|
To run this example, remember to change @filepath{info.ss} to add the To run this example, remember to change @filepath{info.rkt} to add the
@racket['multi-page] style. You may also want to add a call to @racket['multi-page] style. You may also want to add a call to
@racket[table-of-contents] in @filepath{manual.scrbl}. @racket[table-of-contents] in @filepath{manual.scrbl}.

View File

@ -35,7 +35,7 @@ changes that make it suitable as a preprocessor language:
@; TODO: @; TODO:
@; * make all example sections be subsections, @; * make all example sections be subsections,
@; * add a reference section, @; * add a reference section,
@; * a section on "scribble/text.ss" @; * a section on "scribble/text.rkt"
@; * maybe a section on additional utilities: begin/text @; * maybe a section on additional utilities: begin/text
@;-------------------------------------------------------------------- @;--------------------------------------------------------------------
@ -926,13 +926,13 @@ trivial: the preprocessor source is still source code in a module, so
you can @racket[require] additional files with utility functions. you can @racket[require] additional files with utility functions.
@example|-{#lang scribble/text @example|-{#lang scribble/text
@(require "itemize.ss") @(require "itemize.rkt")
Todo: Todo:
@itemize[@list{Hack some} @itemize[@list{Hack some}
@list{Sleep some} @list{Sleep some}
@list{Hack some @list{Hack some
more}] more}]
---***--- itemize.ss ---***--- itemize.rkt
#lang racket #lang racket
(provide itemize) (provide itemize)
(define (itemize . items) (define (itemize . items)
@ -953,14 +953,14 @@ often be useful here, since such files need to deal with texts. Using
it, it is easy to include a lot of textual content. it, it is easy to include a lot of textual content.
@example|-{#lang scribble/text @example|-{#lang scribble/text
@(require "stuff.ss") @(require "stuff.rkt")
Todo: Todo:
@itemize[@list{Hack some} @itemize[@list{Hack some}
@list{Sleep some} @list{Sleep some}
@list{Hack some @list{Hack some
more}] more}]
@summary @summary
---***--- stuff.ss ---***--- stuff.rkt
#lang at-exp racket/base #lang at-exp racket/base
(require racket/list) (require racket/list)
(provide (all-defined-out)) (provide (all-defined-out))

View File

@ -36,7 +36,7 @@ to the renderers. For example, the @exec{scribble} command-line tool
might, in the future, extract rendering mixins from a document module might, in the future, extract rendering mixins from a document module
(in addition to the document proper). (in addition to the document proper).
See the @filepath{base-render.ss} source for more information about See the @filepath{base-render.rkt} source for more information about
the methods of the renderer. Documents built with higher layers, such the methods of the renderer. Documents built with higher layers, such
as @racketmodname[scribble/manual], generally do not call the render as @racketmodname[scribble/manual], generally do not call the render
object's methods directly. object's methods directly.

View File

@ -29,7 +29,7 @@ same way that the module system keeps expansion-time code separate
from run-time code. from run-time code.
For an example use, see the @filepath{file} collection's For an example use, see the @filepath{file} collection's
@filepath{gif.ss} source file and the corresponding extraction in @filepath{gif.rkt} source file and the corresponding extraction in
@filepath{scribblings/gif.scrbl}. As that example illustrates, @filepath{scribblings/gif.scrbl}. As that example illustrates,
prefixing the module declaration with prefixing the module declaration with