disable _
prefix handling in racketmodname
and other places
In places where module names are typeset, such as `racketmodname`, there's no way to disable the special treatment of `_` as an identifier prefix as in `racket`. Even using `make-element-id-transformer` doesn't work, because the module-name datum is explcitly disconnected from binding withing `racketmodname`.
This commit is contained in:
parent
725f2bc9ed
commit
18e467ef9e
|
@ -494,18 +494,22 @@ generates
|
||||||
#:grammar ([maybe-indirect code:blank
|
#:grammar ([maybe-indirect code:blank
|
||||||
#:indirect])]{
|
#:indirect])]{
|
||||||
|
|
||||||
Like @racket[racket], but typeset as a module path. If @racket[datum]
|
Like @racket[racket], but typeset as a module path and without special
|
||||||
is an identifier or @racket[expr] produces a symbol, then it is
|
treatment of identifiers (such as @racketidfont{code:blank} or identifiers
|
||||||
hyperlinked to the module path's definition as created by
|
that start with @litchar{_}). If @racket[datum] is an identifier or
|
||||||
@racket[defmodule].
|
@racket[expr] produces a symbol, then it is hyperlinked to the module
|
||||||
|
path's definition as created by @racket[defmodule].
|
||||||
|
|
||||||
If @racket[#:indirect] is specified, then the hyperlink is given the
|
If @racket[#:indirect] is specified, then the hyperlink is given the
|
||||||
@racket['indirect-link] @tech{style property}, which makes the
|
@racket['indirect-link] @tech{style property}, which makes the
|
||||||
hyperlink's resolution in HTML potentially delayed; see
|
hyperlink's resolution in HTML potentially delayed; see
|
||||||
@racket['indirect-link] for @racket[link-element].}
|
@racket['indirect-link] for @racket[link-element].
|
||||||
|
|
||||||
|
@history[#:changed "1.21" @elem{Disabled @racket[racket]-style special
|
||||||
|
treatment of identifiers.}]}
|
||||||
|
|
||||||
@defform[(racketmodlink datum pre-content-expr ...)]{
|
@defform[(racketmodlink datum pre-content-expr ...)]{
|
||||||
Like @racket[racketmod], but separating the module path to link
|
Like @racket[racketmodname], but separating the module path to link
|
||||||
from the content to be linked. The @racket[datum] module path is always
|
from the content to be linked. The @racket[datum] module path is always
|
||||||
linked, even if it is not an identifier.}
|
linked, even if it is not an identifier.}
|
||||||
|
|
||||||
|
|
|
@ -23,4 +23,4 @@
|
||||||
|
|
||||||
(define pkg-authors '(mflatt eli))
|
(define pkg-authors '(mflatt eli))
|
||||||
|
|
||||||
(define version "1.20")
|
(define version "1.21")
|
||||||
|
|
|
@ -122,6 +122,8 @@
|
||||||
(make-element result-color (list (to-element/no-color s))))
|
(make-element result-color (list (to-element/no-color s))))
|
||||||
(define (to-element/id s)
|
(define (to-element/id s)
|
||||||
(make-element symbol-color (list (to-element/no-color s))))
|
(make-element symbol-color (list (to-element/no-color s))))
|
||||||
|
(define (to-element/no-escapes s)
|
||||||
|
(to-element s #:escapes? #f))
|
||||||
|
|
||||||
(define-syntax (keep-s-expr stx)
|
(define-syntax (keep-s-expr stx)
|
||||||
(syntax-case stx (quote)
|
(syntax-case stx (quote)
|
||||||
|
@ -160,7 +162,7 @@
|
||||||
(define-code RACKET to-element UNSYNTAX keep-s-expr add-sq-prop)
|
(define-code RACKET to-element UNSYNTAX keep-s-expr add-sq-prop)
|
||||||
(define-code racketresult to-element/result unsyntax keep-s-expr add-sq-prop)
|
(define-code racketresult to-element/result unsyntax keep-s-expr add-sq-prop)
|
||||||
(define-code racketid to-element/id unsyntax keep-s-expr add-sq-prop)
|
(define-code racketid to-element/id unsyntax keep-s-expr add-sq-prop)
|
||||||
(define-code *racketmodname to-element unsyntax keep-s-expr add-sq-prop)
|
(define-code *racketmodname to-element/no-escapes unsyntax keep-s-expr add-sq-prop)
|
||||||
|
|
||||||
(define-syntax (**racketmodname stx)
|
(define-syntax (**racketmodname stx)
|
||||||
(syntax-case stx ()
|
(syntax-case stx ()
|
||||||
|
|
Loading…
Reference in New Issue
Block a user