Small typos, some reformatting.
Fixes PR10920
This commit is contained in:
parent
682430b2c4
commit
c4f67b3e74
|
@ -38,7 +38,7 @@ bindings such as @scheme[foo-bar] for foreign names like
|
|||
]}
|
||||
|
||||
|
||||
@defproc[(list->cblock [lst list?][type ctype?]) any]{
|
||||
@defproc[(list->cblock [lst list?] [type ctype?]) any]{
|
||||
|
||||
Allocates a memory block of an appropriate size, and initializes it
|
||||
using values from @scheme[lst] and the given @scheme[type]. The
|
||||
|
@ -46,7 +46,7 @@ using values from @scheme[lst] and the given @scheme[type]. The
|
|||
according to the given @scheme[type].}
|
||||
|
||||
|
||||
@defproc[(vector->cblock [vec vector?][type type?]) any]{
|
||||
@defproc[(vector->cblock [vec vector?] [type type?]) any]{
|
||||
|
||||
Like @scheme[list->cblock], but for Racket vectors.}
|
||||
|
||||
|
@ -75,7 +75,7 @@ symbol. The set of supported symbols is likely to expand in the
|
|||
future.}
|
||||
|
||||
|
||||
@defproc[(cast [v any/c][from-type ctype?][to-type ctype?]) any/c]{
|
||||
@defproc[(cast [v any/c] [from-type ctype?] [to-type ctype?]) any/c]{
|
||||
|
||||
Converts @scheme[v] from a value matching @scheme[from-type] to a
|
||||
value matching @scheme[to-type], where @scheme[(ctype-sizeof from-type)]
|
||||
|
@ -89,7 +89,7 @@ The conversion is equivalent to
|
|||
(ptr-ref p to-type))
|
||||
]}
|
||||
|
||||
@defproc[(cblock->list [cblock any/c][type ctype?][length exact-nonnegative-integer?])
|
||||
@defproc[(cblock->list [cblock any/c] [type ctype?] [length exact-nonnegative-integer?])
|
||||
list?]{
|
||||
|
||||
Converts C @scheme[cblock], which is a vector of @scheme[type]s, to a
|
||||
|
@ -98,7 +98,7 @@ Racket list. The arguments are the same as in the
|
|||
there is no way to know where the block ends.}
|
||||
|
||||
|
||||
@defproc[(cblock->vector [cblock any/c][type ctype?][length exact-nonnegative-integer?])
|
||||
@defproc[(cblock->vector [cblock any/c] [type ctype?] [length exact-nonnegative-integer?])
|
||||
vector?]{
|
||||
|
||||
Like @scheme[cblock->vector], but for Racket vectors.}
|
||||
|
|
|
@ -42,9 +42,8 @@ Returns the size or alignment of a given @scheme[type] for the current
|
|||
platform.}
|
||||
|
||||
|
||||
@defproc[(ctype->layout [type ctype?]) (flat-rec-contract rep
|
||||
symbol?
|
||||
(listof rep))]{
|
||||
@defproc[(ctype->layout [type ctype?])
|
||||
(flat-rec-contract rep symbol? (listof rep))]{
|
||||
|
||||
Returns a value to describe the eventual C representation of the
|
||||
type. It can be any of the following symbols:
|
||||
|
|
|
@ -14,8 +14,7 @@
|
|||
|
||||
@title{Miscellaneous}
|
||||
|
||||
@defproc[(begin-busy-cursor)
|
||||
void?]{
|
||||
@defproc[(begin-busy-cursor) void?]{
|
||||
|
||||
Changes the cursor to a watch cursor for all windows in the current eventspace.
|
||||
Use
|
||||
|
@ -27,30 +26,15 @@ The cursor installed by
|
|||
@scheme[begin-busy-cursor] overrides any window-specific cursors installed with
|
||||
@method[window<%> set-cursor].
|
||||
|
||||
See also
|
||||
@scheme[is-busy?].
|
||||
|
||||
|
||||
|
||||
See also @scheme[is-busy?].
|
||||
}
|
||||
|
||||
@defproc[(bell)
|
||||
void?]{
|
||||
|
||||
@defproc[(bell) void?]{
|
||||
Rings the system bell.
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
@defproc[(end-busy-cursor)
|
||||
void?]{
|
||||
|
||||
See
|
||||
@scheme[begin-busy-cursor].
|
||||
|
||||
|
||||
|
||||
@defproc[(end-busy-cursor) void?]{
|
||||
See @scheme[begin-busy-cursor].
|
||||
}
|
||||
|
||||
@defproc*[([(file-creator-and-type [filename path]
|
||||
|
@ -234,12 +218,9 @@ The keymap for the read-eval-print loop's editor is initialized by
|
|||
calling the current keymap initializer procedure, which is determined
|
||||
by the
|
||||
@scheme[current-text-keymap-initializer] parameter.
|
||||
|
||||
|
||||
}
|
||||
|
||||
@defproc[(textual-read-eval-print-loop)
|
||||
void?]{
|
||||
@defproc[(textual-read-eval-print-loop) void?]{
|
||||
|
||||
Similar to @scheme[read-eval-print-loop], except that evaluation uses
|
||||
a newly created eventspace.
|
||||
|
@ -259,30 +240,21 @@ break is sent (via @scheme[break-thread]) to the created eventspace's
|
|||
@tech{handler thread}.}
|
||||
|
||||
|
||||
@defproc[(hide-cursor-until-moved)
|
||||
void?]{
|
||||
@defproc[(hide-cursor-until-moved) void?]{
|
||||
|
||||
Hides the cursor until the user moves the mouse or clicks the mouse
|
||||
button. (For some platforms, the cursor is not hidden if it is over
|
||||
a window in a different eventspace or application.)
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
@defproc[(is-busy?)
|
||||
boolean?]{
|
||||
@defproc[(is-busy?) boolean?]{
|
||||
|
||||
Returns @scheme[#t] if a busy cursor has been installed with
|
||||
@scheme[begin-busy-cursor] and not removed with
|
||||
@scheme[end-busy-cursor].
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
@defproc[(label->plain-label [label string])
|
||||
string]{
|
||||
@defproc[(label->plain-label [label string]) string?]{
|
||||
|
||||
Strips shortcut ampersands from @scheme[label], removes parenthesized
|
||||
ampersand--character combinations along with any surrounding space,
|
||||
|
@ -292,15 +264,13 @@ Strips shortcut ampersands from @scheme[label], removes parenthesized
|
|||
}
|
||||
|
||||
|
||||
@defproc[(make-gui-empty-namespace)
|
||||
namespace?]{
|
||||
@defproc[(make-gui-empty-namespace) namespace?]{
|
||||
|
||||
Like @scheme[make-base-empty-namespace], but with
|
||||
@scheme[scheme/class] and @schememodname[scheme/gui/base] also
|
||||
attached to the result namespace.}
|
||||
|
||||
@defproc[(make-gui-namespace)
|
||||
namespace?]{
|
||||
@defproc[(make-gui-namespace) namespace?]{
|
||||
|
||||
Like @scheme[make-base-namespace], but with @scheme[scheme/class] and
|
||||
@schememodname[scheme/gui/base] also required into the top-level
|
||||
|
|
|
@ -1091,7 +1091,6 @@ converted to a path using @racket[bytes->path].}
|
|||
(or/c (listof bytes?) bytes?)))])
|
||||
path?]{
|
||||
|
||||
|
||||
The inverse of @racket[path->main-collects-relative]: if @racket[rel]
|
||||
is a pair that starts with @racket['collects], then it is converted
|
||||
back to a path relative to @racket[(find-collects-dir)].
|
||||
|
|
|
@ -48,8 +48,7 @@ positions are initialized with the given @scheme[b]s.
|
|||
|
||||
|
||||
@defproc[(bytes->immutable-bytes [bstr bytes?])
|
||||
(and/c bytes?
|
||||
immutable?)]{
|
||||
(and/c bytes? immutable?)]{
|
||||
Returns an immutable byte string with the same content
|
||||
as @scheme[bstr], returning @scheme[bstr] itself if @scheme[bstr] is
|
||||
immutable.
|
||||
|
|
|
@ -144,8 +144,7 @@ Returns @racket[#t] if @racket[v] is a mark set created by
|
|||
@racket[continuation-marks] or @racket[current-continuation-marks],
|
||||
@racket[#f] otherwise.}
|
||||
|
||||
@defproc[(continuation-mark-set->context
|
||||
[mark-set continuation-mark-set?])
|
||||
@defproc[(continuation-mark-set->context [mark-set continuation-mark-set?])
|
||||
list?]{
|
||||
|
||||
Returns a list representing an approximate ``@index["stack
|
||||
|
|
|
@ -79,7 +79,7 @@ used as an ephemeron key (see @secref["ephemerons"]).
|
|||
(symbol-unreadable? (gensym))
|
||||
(symbol-unreadable? (string->unreadable-symbol "Apple"))]}
|
||||
|
||||
@defproc[(symbol->string [sym symbol?]) symbol?]{Returns a freshly
|
||||
@defproc[(symbol->string [sym symbol?]) string?]{Returns a freshly
|
||||
allocated mutable string whose characters are the same as in
|
||||
@scheme[sym].
|
||||
|
||||
|
@ -150,7 +150,7 @@ Returns @scheme[#t] if @scheme[v] is a keyword, @scheme[#f] otherwise.}
|
|||
Returns a string for the @scheme[display]ed form of @scheme[keyword],
|
||||
not including the leading @litchar{#:}.}
|
||||
|
||||
@defproc[(string->keyword [str string?]) keyword]{
|
||||
@defproc[(string->keyword [str string?]) keyword?]{
|
||||
|
||||
Returns a keyword whose @scheme[display]ed form is the same as that of
|
||||
@scheme[str], but with a leading @litchar{#:}.}
|
||||
|
|
|
@ -146,7 +146,6 @@ by @racket[kind], which must be one of the following:
|
|||
[default-path-list (listof path?)])
|
||||
(listof path?)]{
|
||||
|
||||
|
||||
Parses a string or byte string containing a list of paths, and returns
|
||||
a list of path strings. Under @|AllUnix|, paths in a path list are
|
||||
separated by a @litchar{:}; under Windows, paths are separated by a
|
||||
|
@ -598,16 +597,16 @@ for @racket[open-input-file].}
|
|||
|
||||
@defproc[(file->value [path path-string?]
|
||||
[#:mode mode-flag (or/c 'binary 'text) 'binary])
|
||||
bytes?]{
|
||||
any]{
|
||||
|
||||
Reads a single S-expression from @racket[path] using @racket[read].
|
||||
The @racket[mode-flag] argument is the same as for
|
||||
@racket[open-input-file].}
|
||||
|
||||
@defproc[(file->list [path path-string?]
|
||||
[proc (input-port? . -> . any/c) read]
|
||||
[#:mode mode-flag (or/c 'binary 'text) 'binary])
|
||||
(listof any/c)]{
|
||||
[proc (input-port? . -> . any/c) read]
|
||||
[#:mode mode-flag (or/c 'binary 'text) 'binary])
|
||||
(listof any/c)]{
|
||||
Repeatedly calls @racket[proc] to consume the contents of
|
||||
@racket[path], until @racket[eof] is produced. The @racket[mode-flag]
|
||||
argument is the same as for @racket[open-input-file]. }
|
||||
|
@ -624,8 +623,8 @@ Read all characters from @racket[path], breaking them into lines. The
|
|||
@racket[open-input-file].}
|
||||
|
||||
@defproc[(file->bytes-lines [path path-string?]
|
||||
[#:mode mode-flag (or/c 'binary 'text) 'binary]
|
||||
[#:line-mode line-mode (or/c 'linefeed 'return 'return-linefeed 'any 'any-one) 'any])
|
||||
[#:mode mode-flag (or/c 'binary 'text) 'binary]
|
||||
[#:line-mode line-mode (or/c 'linefeed 'return 'return-linefeed 'any 'any-one) 'any])
|
||||
(listof bytes?)]{
|
||||
|
||||
Like @racket[file->lines], but reading bytes and collecting them into
|
||||
|
|
|
@ -734,8 +734,8 @@ generator.}
|
|||
@section-index["numbers" "little-endian"]
|
||||
@section-index["numbers" "converting"]
|
||||
|
||||
@defproc[(number->string [z number?]
|
||||
[radix (or/c 2 8 10 16) 10]) string?]{
|
||||
@defproc[(number->string [z number?] [radix (or/c 2 8 10 16) 10])
|
||||
string?]{
|
||||
Returns a string that is the printed form of @racket[z]
|
||||
in the base specific by @racket[radix]. If @racket[z] is inexact,
|
||||
@racket[radix] must be @racket[10], otherwise the
|
||||
|
@ -801,8 +801,7 @@ least-significant eight bits, and so on.}
|
|||
[size-n (or/c 2 4 8)]
|
||||
[signed? any/c]
|
||||
[big-endian? any/c (system-big-endian?)]
|
||||
[dest-bstr (and/c bytes?
|
||||
(not/c immutable?))
|
||||
[dest-bstr (and/c bytes? (not/c immutable?))
|
||||
(make-bytes size-n)]
|
||||
[start exact-nonnegative-integer? 0])
|
||||
bytes?]{
|
||||
|
@ -844,9 +843,8 @@ provides the least-significant eight bits, and so on.}
|
|||
@defproc[(real->floating-point-bytes [x real?]
|
||||
[size-n (or/c 4 8)]
|
||||
[big-endian? any/c (system-big-endian?)]
|
||||
[dest-bstr (and/c bytes?
|
||||
(not/c immutable?))
|
||||
(make-bytes size-n)]
|
||||
[dest-bstr (and/c bytes? (not/c immutable?))
|
||||
(make-bytes size-n)]
|
||||
[start exact-nonnegative-integer? 0])
|
||||
bytes?]{
|
||||
|
||||
|
|
|
@ -66,8 +66,7 @@ typically, however, @scheme[name] is not used for reporting errors,
|
|||
since the procedure name is typically hard-wired into an internal
|
||||
check.}
|
||||
|
||||
@defproc[(procedure->method [proc procedure?])
|
||||
procedure?]{
|
||||
@defproc[(procedure->method [proc procedure?]) procedure?]{
|
||||
|
||||
Returns a procedure that is like @scheme[proc] except that, when applied
|
||||
to the wrong number of arguments, the resulting error hides the first
|
||||
|
|
|
@ -462,11 +462,13 @@ of the generator.
|
|||
(introspective-generator)
|
||||
]}
|
||||
|
||||
@defproc[(sequence->generator [s sequence?]) (-> any?)]{ Returns a generator
|
||||
that returns elements from the sequence, @scheme[s], each time the generator
|
||||
is invoked.}
|
||||
@defproc[(sequence->generator [s sequence?]) (-> any?)]{
|
||||
|
||||
@defproc[(sequence->repeated-generator [s sequence?]) (-> any?)]{ Returns a generator
|
||||
that returns elements from the sequence, @scheme[s], similar to
|
||||
@scheme[sequence->generator] but looping over the values in the sequence
|
||||
when no more values are left.}
|
||||
Returns a generator that returns elements from the sequence, @scheme[s],
|
||||
each time the generator is invoked.}
|
||||
|
||||
@defproc[(sequence->repeated-generator [s sequence?]) (-> any?)]{
|
||||
|
||||
Returns a generator that returns elements from the sequence, @scheme[s],
|
||||
similar to @scheme[sequence->generator] but looping over the values in
|
||||
the sequence when no more values are left.}
|
||||
|
|
|
@ -121,8 +121,7 @@ pair-valued @tech{syntax object} @italic{only} for parentheses in the
|
|||
source. See @secref["parse-pair"] for more information.}
|
||||
|
||||
|
||||
@defproc[(syntax->list [stx syntax?])
|
||||
(or/c list? #f)]{
|
||||
@defproc[(syntax->list [stx syntax?]) (or/c list? #f)]{
|
||||
|
||||
Returns a list of @tech{syntax object}s or @scheme[#f]. The result is a list
|
||||
of @tech{syntax object}s when @scheme[(syntax->datum stx)] would produce a
|
||||
|
|
|
@ -125,7 +125,7 @@ result is the result of @racket[expr].}
|
|||
|
||||
@note-lib-only[racket/date]
|
||||
|
||||
@defproc[(date->string [date date?][time? any/c #f]) string?]{
|
||||
@defproc[(date->string [date date?] [time? any/c #f]) string?]{
|
||||
|
||||
Converts a date to a string. The returned string contains the time of
|
||||
day only if @racket[time?]. See also @racket[date-display-format].}
|
||||
|
@ -171,4 +171,3 @@ calculations.}
|
|||
|
||||
Converts a Julian number (Scalinger's off-by-one version) into a
|
||||
string.}
|
||||
|
||||
|
|
|
@ -55,7 +55,7 @@ order.}
|
|||
Returns the length of @racket[vec] (i.e., the number of slots in the
|
||||
vector).}
|
||||
|
||||
@defproc[(vector-ref [vec vector?][pos exact-nonnegative-integer?]) any/c]{
|
||||
@defproc[(vector-ref [vec vector?] [pos exact-nonnegative-integer?]) any/c]{
|
||||
|
||||
Returns the element in slot @racket[pos] of @racket[vec]. The first
|
||||
slot is position @racket[0], and the last slot is one less than
|
||||
|
@ -69,14 +69,12 @@ slot is position @racket[0], and the last slot is one less than
|
|||
Updates the slot @racket[pos] of @racket[vec] to contain @racket[v].}
|
||||
|
||||
|
||||
@defproc[(vector->list [vec vector?])
|
||||
list?]{
|
||||
@defproc[(vector->list [vec vector?]) list?]{
|
||||
|
||||
Returns a list with the same length and elements as @racket[vec].}
|
||||
|
||||
|
||||
@defproc[(list->vector [lst list?])
|
||||
vector?]{
|
||||
@defproc[(list->vector [lst list?]) vector?]{
|
||||
|
||||
Returns a mutable vector with the same length and elements as
|
||||
@racket[lst].}
|
||||
|
|
|
@ -415,8 +415,7 @@ The tag @racket[t] refers to the content form of
|
|||
The @tech{decode}d @racket[pre-content] is hyperlinked to @racket[t],
|
||||
which is normally defined using @racket[elemtag].}
|
||||
|
||||
@defproc[(module-path-prefix->string [mod-path module-path?])
|
||||
string?]{
|
||||
@defproc[(module-path-prefix->string [mod-path module-path?]) string?]{
|
||||
|
||||
Converts a module path to a string by resolving it to a path, and
|
||||
using @racket[path->main-collects-relative].}
|
||||
|
|
|
@ -115,8 +115,7 @@ The optional @racket[using-render%] argument is as for
|
|||
@racket[load-xref].}
|
||||
|
||||
|
||||
@defproc[(xref-tag->index-entry [xref xref?]
|
||||
[tag tag?])
|
||||
@defproc[(xref-tag->index-entry [xref xref?] [tag tag?])
|
||||
(or/c false/c entry?)]{
|
||||
|
||||
Extract an @racket[entry] structure that provides addition information
|
||||
|
|
|
@ -290,4 +290,3 @@ The same as @racket[pict-last], provided for backward compatibility.}
|
|||
|
||||
Mainly for backward compatibility: returns @racket[(if bl-pict
|
||||
(use-last pict (or (pict-last bl-pict) bl-pict)))].}
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user