[racket] Scribble Warning / "on this page"

From: Matthew Flatt (mflatt at cs.utah.edu)
Date: Sun May 13 13:39:10 EDT 2012

Do you have a `defmodule' declaration? That is, your documentation
source should look something like this:

 #lang scribble/manual
 @(require (for-label racket
 @(defclass porte% object% {and% or% not% nand%}

Of course, you'd use something else for `mylib' --- whatever your
library is called --- but I'll assume `mylib' here.

The `@defmodue[mylib]' indicates that documentation in the enclosing
section is for bindings from the `mylib' library. It generates typeset
output of the form

 (require mylib)

in a beige box so that a reader of the documentation knows that it's
for the `mylib' library, but it also cooperates with `defclass',
`defproc', etc., so that they know they're documenting classes,
procedures, etc. for `mylib'.

I also added `mylib' to the `for-label' imports above, so that every
use of `porte%' will be hyperlinked to the definition (in the same
section) of `porte%'.

You shouldn't need to set up a tag to hyperlink to the definition of
`porte%' or a function documented with `defproc'. Instead,
`@racket[porte%]' in any context that imports `(for-label mylib)'
should cause the typeset `porte%' to be a hyperlink to the definition.

The "On this page" box on a page's left-hand side is similarly
generated automatically. I'm not sure why you're aren't seeing it
already, but maybe it has to to with the other problems, so let's sort
out those first.

At Sun, 13 May 2012 17:39:15 +0200, Quentin Rinaldi wrote:
> Hi
> I'm writing a Scheme project documentation with Scribble, and I have this
> error :
> WARNING: no declared exporting libraries for definition
> I've understood that I should write something like "declare-exporting ..."
> but I don't understand why... I don't need to export anything, all my
> documentation is written on the same page !
> My page is like that :
> #lang scribble/manual
> @(require (for-label racket))
> @title{Documentation}
> ...
> @(defclass porte% object% {and% or% not% nand%}
>    @(defconstructor ((x number?)
>                      (y number?)
>                      (val-out any/c #f)
>                      (co-out any/c #f)
>                      (name (or/c string? #f))))
>    @(defmethod (get-x) (x number?) "...")
>    @(defmethod (get-y) (y number?) "..."))
> then i have some @(defproc ...)
> And I have 2 questions : How do I make a tag in a defproc ? I mean, if I
> define a  procedure with defproc, how do I make a hyperlink somewhere else
> ? I know how to make it for a section (put a tag in the section, then
> seclink{tag} but i don't know how to do with a defproc...
> And then, how do we make an "on this page" as in the documentation racket ?
> i've read the documentation severals times, but unless a headache I didn't
> get anything...
> Thank you !
> ____________________
>   Racket Users list:
>   http://lists.racket-lang.org/users

Posted on the users mailing list.