fix Scribble output of multi-line error messages, especially when they contain a blank line; minor doc repairs

svn: r13325
This commit is contained in:
Matthew Flatt 2009-01-30 16:41:42 +00:00
parent cebd9282b1
commit 6c77acf6f1
4 changed files with 17 additions and 17 deletions

View File

@ -93,11 +93,7 @@
;; Error result case:
(map
(lambda (s)
(list (make-flow (list (make-paragraph
(list
(hspace 2)
(span-class "schemeerror"
(italic s))))))))
(car (format-output s "schemeerror")))
(let sloop ([s (caar val-list+outputs)])
(if ((string-length s) . > . maxlen)
;; break the error message into multiple lines:

View File

@ -607,7 +607,7 @@ on exit.}
A @tech{custom function type} that is similar to @scheme[_ptr], except
that it is used for converting lists to/from C vectors. The optional
@scheme[len] argument is needed for output values where it is used in
@scheme[maybe-len] argument is needed for output values where it is used in
the post code, and in the pre code of an output mode to allocate the
block. In either case, it can refer to a previous binding for the
length of the list which the C function will most likely require.}

View File

@ -222,7 +222,7 @@ returns a bitmap of the same size as this one, a grayscale version is
included in the PNG file as the alpha channel.
A monochrome bitmap saved as @scheme['png] without a mask bitmap
produces a 1-bit grayscale PNG file (which , when read with
produces a 1-bit grayscale PNG file (which, when read with
@method[bitmap% load-file], creates a monochrome @scheme[bitmap%]
object.)

View File

@ -2565,16 +2565,20 @@
(when fn
(let ([safer-fn (normalize-path (build-path (find-system-path 'desk-dir)
(regexp-replace* #rx"[/\"|:<>\\]" fn "-")))])
(insert " " set-standard-style)
(insert "[save to ~/Desktop/ & open]"
(lambda (t s e)
(send t set-clickback s e
(lambda (a b c)
(to-file safer-fn)
(parameterize ([current-input-port (open-input-string "")])
(system* "/usr/bin/open" (path->string safer-fn))))
#f #f)
(send t change-style url-delta s e)))))))
(let ([and-open
(lambda (dir)
(insert " " set-standard-style)
(insert (format "[~a & open]" dir)
(lambda (t s e)
(send t set-clickback s e
(lambda (a b c)
(to-file safer-fn)
(parameterize ([current-input-port (open-input-string "")])
(system* "/usr/bin/open" (path->string safer-fn))))
#f #f)
(send t change-style url-delta s e))))])
(and-open "~/Desktop")
(and-open "~/Temp"))))))
(insert "\n" set-standard-style)
(lambda ()
(unless content