Convert all uses of (integer-in 0 255) to `byte?'.

This commit is contained in:
Eli Barzilay 2012-07-22 12:59:52 -04:00
parent a6b20f01da
commit 18883681a2
14 changed files with 168 additions and 293 deletions

View File

@ -812,7 +812,7 @@ TODO
(user-break-parameterization #f) (user-break-parameterization #f)
(user-logger (make-logger)) (user-logger (make-logger))
;; user-exit-code (union #f (integer-in 0 255)) ;; user-exit-code (union #f byte?)
;; #f indicates that exit wasn't called. Integer indicates exit code ;; #f indicates that exit wasn't called. Integer indicates exit code
(user-exit-code #f)) (user-exit-code #f))

View File

@ -106,7 +106,6 @@
;; The maximum level height of an octree. ;; The maximum level height of an octree.
(define MAX-LEVEL 7) (define MAX-LEVEL 7)
(define byte/c (integer-in 0 255))
(define octet/c (integer-in 0 7)) (define octet/c (integer-in 0 7))
@ -129,7 +128,7 @@
bluesum ; number bluesum ; number
children ; (vectorof (or/c #f node)) children ; (vectorof (or/c #f node))
next ; (or/c #f node) next ; (or/c #f node)
palette-index) ; (or/c #f (integer-in 0 255)) palette-index) ; (or/c #f byte?)
#:mutable) #:mutable)
;; node-next is used to accelerate the search for a reduction candidate. ;; node-next is used to accelerate the search for a reduction candidate.
@ -355,7 +354,7 @@
([root node?] ([root node?]
[leaf-count natural-number/c] [leaf-count natural-number/c]
[reduction-heads (vectorof (or/c node? false/c))] [reduction-heads (vectorof (or/c node? false/c))]
[palette (vectorof (vector/c byte/c byte/c byte/c))])] [palette (vectorof (vector/c byte? byte? byte?))])]
[struct node [struct node
([leaf? boolean?] ([leaf? boolean?]
[npixels natural-number/c] [npixels natural-number/c]
@ -364,11 +363,11 @@
[bluesum natural-number/c] [bluesum natural-number/c]
[children (vectorof (or/c false/c node?))] [children (vectorof (or/c false/c node?))]
[next (or/c node? false/c)] [next (or/c node? false/c)]
[palette-index byte/c])] [palette-index byte?])]
[new-octree (-> octree?)] [new-octree (-> octree?)]
[octree-insert-color! (octree? byte/c byte/c byte/c . -> . any)] [octree-insert-color! (octree? byte? byte? byte? . -> . any)]
[octree-lookup [octree-lookup
(octree? byte/c byte/c byte/c . -> . (values byte/c byte/c byte/c))] (octree? byte? byte? byte? . -> . (values byte? byte? byte?))]
[octree-reduce! (octree? . -> . any)] [octree-reduce! (octree? . -> . any)]
[octree-finalize! (octree? . -> . any)] [octree-finalize! (octree? . -> . any)]
[rgb->index (natural-number/c byte/c byte/c byte/c . -> . octet/c)]) [rgb->index (natural-number/c byte? byte? byte? . -> . octet/c)])

View File

@ -843,7 +843,7 @@ for b3, we have:
[argb->bitmap (argb? . -> . (or/c #f (is-a?/c bitmap%)))] [argb->bitmap (argb? . -> . (or/c #f (is-a?/c bitmap%)))]
[argb? (any/c . -> . boolean?)] [argb? (any/c . -> . boolean?)]
[make-argb ((vectorof (integer-in 0 255)) exact-nonnegative-integer? exact-nonnegative-integer? . -> . argb?)] [make-argb ((vectorof byte?) exact-nonnegative-integer? exact-nonnegative-integer? . -> . argb?)]
[argb-vector (argb? . -> . (vectorof (integer-in 0 255)))] [argb-vector (argb? . -> . (vectorof byte?))]
[argb-width (argb? . -> . exact-nonnegative-integer?)] [argb-width (argb? . -> . exact-nonnegative-integer?)]
[argb-height (argb? . -> . exact-nonnegative-integer?)]) [argb-height (argb? . -> . exact-nonnegative-integer?)])

View File

@ -107,7 +107,7 @@ exactly match alpha channels.}}
This snipclass is used for saved cache image snips.} This snipclass is used for saved cache image snips.}
@defproc[(make-argb [vectorof (integer-in 0 255)] @defproc[(make-argb [vectorof byte?]
[width exact-nonnegative-integer?] [width exact-nonnegative-integer?]
[height exact-nonnegative-integer?]) [height exact-nonnegative-integer?])
argb?]{ argb?]{
@ -119,7 +119,7 @@ This snipclass is used for saved cache image snips.}
pixel at location (x,y) comes from vector entry (4*(x+(width*y))). pixel at location (x,y) comes from vector entry (4*(x+(width*y))).
} }
@defproc[(argb-vector [argb argb?]) (vectorof (integer-in 0 255))]{ @defproc[(argb-vector [argb argb?]) (vectorof byte?)]{
Extracts the vector from @racket[argb]. The resulting vector Extracts the vector from @racket[argb]. The resulting vector
has entries in row-major order, so that the data for the pixel has entries in row-major order, so that the data for the pixel

View File

@ -57,9 +57,7 @@
real? real? real? real? real?)) real? real? real? real? real?))
(define make-color/c (define make-color/c
(->* ((integer-in 0 255) (->* (byte? byte? byte?)
(integer-in 0 255)
(integer-in 0 255))
((real-in 0 1)) ((real-in 0 1))
(is-a?/c color%))) (is-a?/c color%)))
@ -89,9 +87,9 @@
(define color%/c (define color%/c
(class/c (class/c
(alpha (->m (real-in 0 1))) (alpha (->m (real-in 0 1)))
(red (->m (integer-in 0 255))) (red (->m byte?))
(blue (->m (integer-in 0 255))) (blue (->m byte?))
(green (->m (integer-in 0 255))) (green (->m byte?))
(copy-from (->m (is-a?/c color%) (is-a?/c color%))) (copy-from (->m (is-a?/c color%) (is-a?/c color%)))
(ok? (->m boolean?)) (ok? (->m boolean?))
(set (->*m (byte? byte? byte?) (set (->*m (byte? byte? byte?)
@ -132,10 +130,7 @@
(set-cap (->m pen-cap-style/c void?)) (set-cap (->m pen-cap-style/c void?))
(set-color (case->m (set-color (case->m
(-> (or/c (is-a?/c color%) string?) void?) (-> (or/c (is-a?/c color%) string?) void?)
(-> (integer-in 0 255) (-> byte? byte? byte? void?)))
(integer-in 0 255)
(integer-in 0 255)
void?)))
(set-join (->m pen-join-style/c void?)) (set-join (->m pen-join-style/c void?))
(set-stipple (->m (or/c (is-a?/c bitmap%) #f) void?)) (set-stipple (->m (or/c (is-a?/c bitmap%) #f) void?))
(set-style (->m pen-style/c void?)) (set-style (->m pen-style/c void?))
@ -158,10 +153,7 @@
(get-style (->m brush-style/c)) (get-style (->m brush-style/c))
(set-color (case->m (set-color (case->m
(-> (or/c (is-a?/c color%) string?) void?) (-> (or/c (is-a?/c color%) string?) void?)
(-> (integer-in 0 255) (-> byte? byte? byte? void?)))
(integer-in 0 255)
(integer-in 0 255)
void?)))
(set-stipple (->*m ((or/c (is-a?/c bitmap%) #f)) (set-stipple (->*m ((or/c (is-a?/c bitmap%) #f))
((or/c transformation-vector/c #f)) ((or/c transformation-vector/c #f))
void?)) void?))

View File

@ -70,7 +70,7 @@
(get-family (->m font-family/c)) (get-family (->m font-family/c))
(get-foreground-add (->m (is-a?/c add-color<%>))) (get-foreground-add (->m (is-a?/c add-color<%>)))
(get-foreground-mult (->m (is-a?/c mult-color<%>))) (get-foreground-mult (->m (is-a?/c mult-color<%>)))
(get-size-add (->m (integer-in 0 255))) (get-size-add (->m byte?))
(get-size-in-pixels-off (->m boolean?)) (get-size-in-pixels-off (->m boolean?))
(get-size-in-pixels-on (->m boolean?)) (get-size-in-pixels-on (->m boolean?))
(get-size-mult (->m real?)) (get-size-mult (->m real?))
@ -117,7 +117,7 @@
(is-a?/c style-delta%))) (is-a?/c style-delta%)))
(set-face (->m (or/c string? false/c) void?)) (set-face (->m (or/c string? false/c) void?))
(set-family (->m font-family/c void?)) (set-family (->m font-family/c void?))
(set-size-add (->m (integer-in 0 255) void?)) (set-size-add (->m byte? void?))
(set-size-in-pixels-off (->m any/c void?)) (set-size-in-pixels-off (->m any/c void?))
(set-size-in-pixels-on (->m any/c void?)) (set-size-in-pixels-on (->m any/c void?))
(set-size-mult (->m real? void?)) (set-size-mult (->m real? void?))

View File

@ -177,9 +177,7 @@ Returns @racket[#t] if the brush object is immutable.
void?] void?]
[(set-color [color-name string?]) [(set-color [color-name string?])
void?] void?]
[(set-color [red (integer-in 0 255)] [(set-color [red byte?] [green byte?] [blue byte?])
[green (integer-in 0 255)]
[blue (integer-in 0 255)])
void?])]{ void?])]{
Sets the brush's color. A brush cannot be modified if it was obtained Sets the brush's color. A brush cannot be modified if it was obtained

View File

@ -16,9 +16,7 @@ object using a color name, and see also @racket[make-color].
@defconstructor*/make[(() @defconstructor*/make[(()
([red (integer-in 0 255)] ([red byte?] [green byte?] [blue byte?]
[green (integer-in 0 255)]
[blue (integer-in 0 255)]
[alpha (real-in 0 1) 1.0]) [alpha (real-in 0 1) 1.0])
([color-name string?]))]{ ([color-name string?]))]{
@ -29,62 +27,31 @@ Creates a new color with the given RGB values and alpha, or matching
} }
@defmethod[(alpha) @defmethod[(copy-from [src (is-a?/c color%)]) (is-a?/c color%)]{
(real-in 0 1)]{ Copies the RGB values of another color object to this one, returning
this object as the result.}
Returns the alpha component (i.e., opacity) of the color. @defmethod[(is-immutable?) boolean?]{
Returns @racket[#t] if the color object is immutable.}
} @defmethod[(ok?) boolean?]{
Returns @racket[#t] if the color object is valid.}
@defmethod[(blue) @defmethod[(red) byte?]{
(integer-in 0 255)]{ Returns the red component of the color.}
Returns the blue component of the color. @defmethod[(green) byte?]{
Returns the green component of the color.}
} @defmethod[(blue) byte?]{
Returns the blue component of the color.}
@defmethod[(copy-from [src (is-a?/c color%)]) @defmethod[(alpha) (real-in 0 1)]{
(is-a?/c color%)]{ Returns the alpha component (i.e., opacity) of the color.}
Copies the RGB values of another color object to this one, returning @defmethod[(set [red byte?] [green byte?] [blue byte?]
this object as the result.
}
@defmethod[(green)
(integer-in 0 255)]{
Returns the green component of the color.
}
@defmethod[(is-immutable?)
boolean?]{
Returns @racket[#t] if the color object is immutable.
}
@defmethod[(ok?)
boolean?]{
Returns @racket[#t] if the color object is valid.
}
@defmethod[(red)
(integer-in 0 255)]{
Returns the red component of the color.
}
@defmethod[(set [red (integer-in 0 255)]
[green (integer-in 0 255)]
[blue (integer-in 0 255)]
[alpha (real-in 0 1) 1.0]) [alpha (real-in 0 1) 1.0])
void?]{ void?]{
Sets the four (red, green, blue, and alpha) component values of the color.}
Sets the four (red, green, blue, and alpha) component values of the color. }
}}

View File

@ -84,10 +84,7 @@ result brush is created via @method[brush-list% find-or-create-brush] of
@racket[the-brush-list].} @racket[the-brush-list].}
@defproc[(make-color @defproc[(make-color [red byte?] [green byte?] [blue byte?]
[red (integer-in 0 255)]
[green (integer-in 0 255)]
[blue (integer-in 0 255)]
[alpha (real-in 0 1) 1.0]) [alpha (real-in 0 1) 1.0])
(is-a?/c color%)]{ (is-a?/c color%)]{

View File

@ -244,9 +244,7 @@ A pen cannot be modified if it was obtained from a @racket[pen-list%]
void?] void?]
[(set-color [color-name string?]) [(set-color [color-name string?])
void?] void?]
[(set-color [red (integer-in 0 255)] [(set-color [red byte?] [green byte?] [blue byte?])
[green (integer-in 0 255)]
[blue (integer-in 0 255)])
void?])]{ void?])]{
Sets the pen color. Sets the pen color.

View File

@ -3,8 +3,8 @@
@defclass/title[style-delta% object% ()]{ @defclass/title[style-delta% object% ()]{
A @racket[style-delta%] object encapsulates a style change. The changes expressible A @racket[style-delta%] object encapsulates a style change. The changes
by a delta include: expressible by a delta include:
@itemize[ @itemize[
@item{changing the font family} @item{changing the font family}
@item{changing the font face} @item{changing the font face}
@ -86,7 +86,8 @@ The possible values for @racket[underlined-on] and @racket[underlined-off] are:
@item{@racket[#t]} @item{@racket[#t]}
] ]
The possible values for @racket[size-in-pixels-on] and @racket[size-in-pixels-off] are: The possible values for @racket[size-in-pixels-on] and
@racket[size-in-pixels-off] are:
@itemize[ @itemize[
@item{@racket[#f] (acts like @racket['base])} @item{@racket[#f] (acts like @racket['base])}
@item{@racket[#t]} @item{@racket[#t]}
@ -127,8 +128,6 @@ The family and face settings in a style delta are interdependent:
] ]
@defconstructor*/make[(([change-command (or/c 'change-nothing @defconstructor*/make[(([change-command (or/c 'change-nothing
'change-normal 'change-normal
'change-toggle-underline 'change-toggle-underline
@ -148,14 +147,13 @@ The family and face settings in a style delta are interdependent:
([change-command (or/c 'change-size ([change-command (or/c 'change-size
'change-bigger 'change-bigger
'change-smaller)] 'change-smaller)]
[v (integer-in 0 255)]) [v byte?])
([change-command (or/c 'change-underline ([change-command (or/c 'change-underline
'change-size-in-pixels)] 'change-size-in-pixels)]
[v any/c]))]{ [v any/c]))]{
The initialization arguments are passed on to The initialization arguments are passed on to
@method[style-delta% set-delta]. @method[style-delta% set-delta].
} }
@ -170,37 +168,20 @@ Tries to collapse into a single delta the changes that would be made
} }
@defmethod[(copy [delta (is-a?/c style-delta%)]) @defmethod[(copy [delta (is-a?/c style-delta%)]) void?]{
void?]{ Copies the given style delta's settings into this one.}
Copies the given style delta's settings into this one. @defmethod[(equal? [delta (is-a?/c style-delta%)]) boolean?]{
Returns @racket[#t] if the given delta is equivalent to this one in
all contexts or @racket[#f] otherwise.}
} @defmethod[(get-alignment-off) (or/c 'base 'top 'center 'bottom)]{
See @racket[style-delta%].}
@defmethod[(equal? [delta (is-a?/c style-delta%)]) @defmethod[(get-alignment-on) (or/c 'base 'top 'center 'bottom)]{
boolean?]{ See @racket[style-delta%].}
Returns @racket[#t] if the given delta is equivalent to this one in @defmethod[(get-background-add) (is-a?/c add-color<%>)]{
all contexts or @racket[#f] otherwise.
}
@defmethod[(get-alignment-off)
(or/c 'base 'top 'center 'bottom)]{
See @racket[style-delta%].
}
@defmethod[(get-alignment-on)
(or/c 'base 'top 'center 'bottom)]{
See @racket[style-delta%].
}
@defmethod[(get-background-add)
(is-a?/c add-color<%>)]{
Gets the object additive color shift for the background (applied after Gets the object additive color shift for the background (applied after
the multiplicative factor). Call this @racket[add-color<%>] object's the multiplicative factor). Call this @racket[add-color<%>] object's
@ -248,13 +229,11 @@ Returns the delta's font family. The possible values are
@item{@indexed-racket['system] (used to draw control labels)} @item{@indexed-racket['system] (used to draw control labels)}
] ]
See also See also @method[style-delta% get-face].
@method[style-delta% get-face].
} }
@defmethod[(get-foreground-add) @defmethod[(get-foreground-add) (is-a?/c add-color<%>)]{
(is-a?/c add-color<%>)]{
Gets the additive color shift for the foreground (applied after the Gets the additive color shift for the foreground (applied after the
multiplicative factor). Call this @racket[add-color<%>] object's multiplicative factor). Call this @racket[add-color<%>] object's
@ -272,95 +251,61 @@ Gets the multiplicative color shift for the foreground (applied before
} }
@defmethod[(get-size-add) @defmethod[(get-size-add) byte?]{
(integer-in 0 255)]{ Gets the additive font size shift (applied after the multiplicative factor).}
Gets the additive font size shift (applied after the multiplicative factor). @defmethod[(get-size-in-pixels-off) boolean?]{
See @racket[style-delta%].}
} @defmethod[(get-size-in-pixels-on) boolean?]{
See @racket[style-delta%].}
@defmethod[(get-size-in-pixels-off) @defmethod[(get-size-mult) real?]{
boolean?]{ Gets the multiplicative font size shift (applied before the additive factor).}
See @racket[style-delta%].
}
@defmethod[(get-size-in-pixels-on)
boolean?]{
See @racket[style-delta%].
}
@defmethod[(get-size-mult)
real?]{
Gets the multiplicative font size shift (applied before the additive factor).
}
@defmethod[(get-smoothing-off) @defmethod[(get-smoothing-off)
(or/c 'base 'default 'partly-smoothed 'smoothed 'unsmoothed)]{ (or/c 'base 'default 'partly-smoothed 'smoothed 'unsmoothed)]{
See @racket[style-delta%].
See @racket[style-delta%].
} }
@defmethod[(get-smoothing-on) @defmethod[(get-smoothing-on)
(or/c 'base 'default 'partly-smoothed 'smoothed 'unsmoothed)]{See (or/c 'base 'default 'partly-smoothed 'smoothed 'unsmoothed)]{See
@racket[style-delta%]. @racket[style-delta%].
} }
@defmethod[(get-style-off) @defmethod[(get-style-off)
(or/c 'base 'normal 'italic 'slant)]{See (or/c 'base 'normal 'italic 'slant)]{See
@racket[style-delta%]. @racket[style-delta%].
} }
@defmethod[(get-style-on) @defmethod[(get-style-on) (or/c 'base 'normal 'italic 'slant)]{
(or/c 'base 'normal 'italic 'slant)]{See See @racket[style-delta%].}
@racket[style-delta%].
}
@defmethod[(get-transparent-text-backing-off) @defmethod[(get-transparent-text-backing-off) boolean?]{
boolean?]{See See @racket[style-delta%].}
@racket[style-delta%].
}
@defmethod[(get-transparent-text-backing-on) @defmethod[(get-transparent-text-backing-on) boolean?]{
boolean?]{See See @racket[style-delta%].}
@racket[style-delta%].
}
@defmethod[(get-underlined-off) @defmethod[(get-underlined-off)
boolean?]{See boolean?]{
@racket[style-delta%]. See @racket[style-delta%].}
}
@defmethod[(get-underlined-on) @defmethod[(get-underlined-on)
boolean?]{See boolean?]{
@racket[style-delta%]. See @racket[style-delta%].}
}
@defmethod[(get-weight-off) @defmethod[(get-weight-off) (or/c 'base 'normal 'bold 'light)]{
(or/c 'base 'normal 'bold 'light)]{See See @racket[style-delta%].}
@racket[style-delta%].
}
@defmethod[(get-weight-on) @defmethod[(get-weight-on) (or/c 'base 'normal 'bold 'light)]{
(or/c 'base 'normal 'bold 'light)]{See See @racket[style-delta%].}
@racket[style-delta%].
}
@defmethod[(set-alignment-off [v (or/c 'base 'top 'center 'bottom)]) @defmethod[(set-alignment-off [v (or/c 'base 'top 'center 'bottom)]) void?]{
void?]{See See @racket[style-delta%].}
@racket[style-delta%].
}
@defmethod[(set-alignment-on [v (or/c 'base 'top 'center 'bottom)]) @defmethod[(set-alignment-on [v (or/c 'base 'top 'center 'bottom)]) void?]{
void?]{See See @racket[style-delta%].}
@racket[style-delta%].
}
@defmethod*[([(set-delta [change-command (or/c 'change-nothing @defmethod*[([(set-delta [change-command (or/c 'change-nothing
'change-normal 'change-normal
@ -383,7 +328,7 @@ See @racket[style-delta%].
[(set-delta [change-command (or/c 'change-size [(set-delta [change-command (or/c 'change-size
'change-bigger 'change-bigger
'change-smaller)] 'change-smaller)]
[param (integer-in 0 255)]) [param byte?])
(is-a?/c style-delta%)] (is-a?/c style-delta%)]
[(set-delta [change-command (or/c 'change-underline [(set-delta [change-command (or/c 'change-underline
'change-size-in-pixels)] 'change-size-in-pixels)]
@ -501,72 +446,57 @@ Sets the delta's font family. See
} }
@defmethod[(set-size-add [v (integer-in 0 255)]) @defmethod[(set-size-add [v byte?]) void?]{
void?]{Sets the additive font size shift (applied Sets the additive font size shift (applied
after the multiplicative factor). after the multiplicative factor).}
}
@defmethod[(set-size-in-pixels-off [v any/c]) @defmethod[(set-size-in-pixels-off [v any/c]) void?]{
void?]{See See @racket[style-delta%].}
@racket[style-delta%].
}
@defmethod[(set-size-in-pixels-on [v any/c]) @defmethod[(set-size-in-pixels-on [v any/c]) void?]{
void?]{See See @racket[style-delta%].}
@racket[style-delta%].
}
@defmethod[(set-size-mult [v real?]) @defmethod[(set-size-mult [v real?]) void?]{
void?]{Sets the multiplicative font size shift (applied Sets the multiplicative font size shift (applied before the additive factor).}
before the additive factor).
}
@defmethod[(set-smoothing-off [v (or/c 'base 'default 'partly-smoothed 'smoothed 'unsmoothed)]) @defmethod[(set-smoothing-off [v (or/c 'base 'default 'partly-smoothed
void?]{See 'smoothed 'unsmoothed)])
@racket[style-delta%]. void?]{
} See @racket[style-delta%].}
@defmethod[(set-smoothing-on [v (or/c 'base 'default 'partly-smoothed 'smoothed 'unsmoothed)]) @defmethod[(set-smoothing-on [v (or/c 'base 'default 'partly-smoothed
void?]{See 'smoothed 'unsmoothed)])
@racket[style-delta%]. void?]{
} See @racket[style-delta%].}
@defmethod[(set-style-off [v (or/c 'base 'normal 'italic 'slant)]) @defmethod[(set-style-off [v (or/c 'base 'normal 'italic 'slant)])
void?]{See void?]{
@racket[style-delta%]. See @racket[style-delta%].}
}
@defmethod[(set-style-on [v (or/c 'base 'normal 'italic 'slant)]) @defmethod[(set-style-on [v (or/c 'base 'normal 'italic 'slant)])
void?]{See void?]{
@racket[style-delta%]. See @racket[style-delta%].}
}
@defmethod[(set-transparent-text-backing-off [v any/c]) @defmethod[(set-transparent-text-backing-off [v any/c])
void?]{See void?]{
@racket[style-delta%]. See @racket[style-delta%].}
}
@defmethod[(set-transparent-text-backing-on [v any/c]) @defmethod[(set-transparent-text-backing-on [v any/c]) void?]{
void?]{See See @racket[style-delta%].}
@racket[style-delta%].
}
@defmethod[(set-underlined-off [v any/c]) @defmethod[(set-underlined-off [v any/c]) void?]{
void?]{See See @racket[style-delta%].}
@racket[style-delta%].
}
@defmethod[(set-underlined-on [v any/c]) @defmethod[(set-underlined-on [v any/c])
void?]{See void?]{
@racket[style-delta%]. See @racket[style-delta%].}
}
@defmethod[(set-weight-off [v (or/c 'base 'normal 'bold 'light)]) @defmethod[(set-weight-off [v (or/c 'base 'normal 'bold 'light)])
void?]{See void?]{
@racket[style-delta%]. See @racket[style-delta%].}
}
@defmethod[(set-weight-on [v (or/c 'base 'normal 'bold 'light)]) @defmethod[(set-weight-on [v (or/c 'base 'normal 'bold 'light)])
void?]{See void?]{
@racket[style-delta%]. See @racket[style-delta%].}
}}
}

View File

@ -91,12 +91,8 @@ Returns the style's shift style if it is a join style. Otherwise, the
} }
@defmethod[(get-size) @defmethod[(get-size) byte?]{
(integer-in 0 255)]{ Returns the style's font size.}
Returns the style's font size.
}
@defmethod[(get-size-in-pixels) @defmethod[(get-size-in-pixels)
boolean?]{ boolean?]{

View File

@ -23,11 +23,11 @@ between @racket[1] and @racket[255] (which normally means
means ``success'').} means ``success'').}
@defparam[executable-yield-handler proc ((integer-in 0 255) . -> . any)]{ @defparam[executable-yield-handler proc (byte? . -> . any)]{
A parameter that determines a procedure to be called as the Racket A parameter that determines a procedure to be called as the Racket
process is about to exit normally. The procedure associated with this process is about to exit normally. The procedure associated with this
parameter is not call when @racket[exit] (or, more precisely, the parameter is not called when @racket[exit] (or, more precisely, the
default @tech{exit handler}) is used to exit early. The argument to default @tech{exit handler}) is used to exit early. The argument to
the handler is the status code that is returned to the system on exit. the handler is the status code that is returned to the system on exit.
The default executable-yield handler simply returns @|void-const|. The default executable-yield handler simply returns @|void-const|.

View File

@ -581,11 +581,9 @@ Selects a specific pen style for drawing, which applies to pen drawing
for @racket[pict] that does not already use a specific pen style.} for @racket[pict] that does not already use a specific pen style.}
@defproc[(colorize [pict pict?] [color (or/c string? @defproc[(colorize [pict pict?]
(is-a?/c color%) [color (or/c string? (is-a?/c color%)
(list (integer-in 0 255) (list byte? byte? byte?))])
(integer-in 0 255)
(integer-in 0 255)))])
pict?]{ pict?]{
Selects a specific color drawing, which applies to drawing in Selects a specific color drawing, which applies to drawing in