3.6 Hyperlinks
function | ||||||||
| ||||||||
| ||||||||
function | ||||||||
The url function is a shorthand to providing the same string to hyperlink as both url_str and pre_content.
function | |||||||
|
If a module path is provided via ~doc: module_path, the tag refers to a tag with a prefix determined by module_path. When raco setup renders documentation, it automatically adds a tag prefix to the document based on the source module. So, for example, to refer to a section of the Rhombus guide, module_path would be ModulePath'lib("rhombus/scribblings/rhombus.scrbl")'.
The ~tag_prefixes: prefixes argument similarly supports selecting a particular section as determined by a path of tag prefixes. When a ~doc argument is provided, then prefixes should trace a path of tag-prefixed subsections to reach the tag section. When ~doc is not provided, the prefixes path is relative to any enclosing section (i.e., the youngest ancestor that produces a match).
If ref_style is not #false, then it is attached as a style property and affects the rendering of the link. Alternatively, an enclosing part can have a LinkRenderStyle property that adjusts the rendering style for all links within the part. See LinkRenderStyle for more information about the rendering of section references.
If underline is #false, then a style is attached to the result so that the hyperlink is rendered in HTML without an underline.
In Racket and Rhombus documentation that is rendered to HTML, clicking
on a section title normally shows a Rhombus secref or Racket
secref call that is needed to link to the section—
function | |||||||
|
function | ||||||||
|
In addition to secref’s arguments, seclink supports a indirect argument. When indirect is true, then the section hyperlink’s resolution in HTML is potentially delayed until the HTML is viewed, and it may link to a documentation server instead of requiring installed documentation.
function | |||||
|
If indirect is content, then the link’s resolution in HTML can be delayed, like seclink with ~indirect: #true. The indirect content is prefixed with “the” and suffixed with ““documentation” to generate the rendered text of the link. For example,
@docref(ModulePath'lib("parsack/parsack/parsack.scrbl")',
~indirect: "Parsec implementation in Racket")
renders as a hyperlink with the text
the Parsec implementation in Racket documentation
function | |||||
| |||||
| |||||
function | |||||
|
The elemref function renders as pre_content, but hyperlinked to the target established by elemtag with t.