remove the mode where reader errors discovered via online check syntax

are shown in the corner of the window

This was an attempt to avoid opening up a whole status line in the
bottom of the window much of the time. But it doesn't really work
since as soon as you have a syntax error (which are relatively common)
you get that whole line opened up. That it, this attempted GUI interaction
depended on the bogus premise that read errors are somehow happening
in a transient way between error-free states.

closes PR 13267
This commit is contained in:
Robby Findler 2012-11-17 13:16:10 -06:00
parent fda9d211b7
commit 4befb20bd0
5 changed files with 7 additions and 20 deletions

View File

@ -506,8 +506,8 @@
(preferences:set-default 'drracket:online-compilation-default-on #t boolean?)
(preferences:set-default 'drracket:online-expansion:read-in-defs-errors
'corner
(or/c 'margin 'gold 'corner))
'margin
(or/c 'margin 'gold))
(preferences:set-default 'drracket:online-expansion:variable-errors
'margin
(or/c 'margin 'gold))

View File

@ -1471,8 +1471,7 @@
[(reader-in-defs-error)
(case (preferences:get 'drracket:online-expansion:read-in-defs-errors)
[(margin) (show-error-in-margin res)]
[(gold) (show-error-as-highlighted-regions res)]
[(corner) (show-error-as-parens-in-corner res)])]
[(gold) (show-error-as-highlighted-regions res)])]
[(access-violation)
(send (get-tab) show-bkg-running 'failed (gui-utils:format-literal-label "~a" (vector-ref res 1)))
(clear-old-error)
@ -1500,13 +1499,7 @@
(send (get-tab) show-bkg-running 'completed-successfully sc-finished-successfully)]
[else
(error 'module-language.rkt "unknown response from the expanding place: ~s\n" res)]))
(define/private (show-error-as-parens-in-corner res)
(send (get-tab) show-bkg-running 'reader-in-defs-error
(gui-utils:format-literal-label "~a" (vector-ref res 1)))
(clear-old-error)
(reset-frame-expand-error #f))
(define/private (show-error-in-margin res)
(begin-edit-sequence #f #f)
(define tlw (send (get-tab) get-frame))
@ -1937,8 +1930,7 @@
[label (string-constant online-expansion-show-read-errors-as)]
[callback (make-callback 'drracket:online-expansion:read-in-defs-errors)]
[choices (list (string-constant online-expansion-error-margin)
(string-constant online-expansion-error-gold-highlight)
(string-constant online-expansion-error-in-corner))]))
(string-constant online-expansion-error-gold-highlight))]))
(define var-choice
(new choice%
[parent vp]
@ -1961,13 +1953,11 @@
(define (index->pref n)
(case n
[(0) 'margin]
[(1) 'gold]
[(2) 'corner]))
[(1) 'gold]))
(define (pref->index p)
(case p
[(margin) 0]
[(gold) 1]
[(corner) 2]))
[(gold) 1]))
(connect-to-prefs read-choice 'drracket:online-expansion:read-in-defs-errors)
(connect-to-prefs var-choice 'drracket:online-expansion:variable-errors)
(connect-to-prefs other-choice 'drracket:online-expansion:other-errors)

View File

@ -251,7 +251,6 @@ please adhere to these guidelines:
(online-expansion-show-variable-errors-as "Show unbound identifier errors")
(online-expansion-show-other-errors-as "Show other errors")
; locations the errors can be shown
(online-expansion-error-in-corner "in the corner of the window")
(online-expansion-error-gold-highlight "with gold highlighting")
(online-expansion-error-margin "in the margin")
;;; info bar at botttom of drscheme frame

View File

@ -237,7 +237,6 @@
(online-expansion-show-variable-errors-as "Montrer les identificateurs libres")
(online-expansion-show-other-errors-as "Montrer les autres erreurs")
; locations the errors can be shown
(online-expansion-error-in-corner "dans le coin de la fenêtre")
(online-expansion-error-gold-highlight "par surlignage doré")
(online-expansion-error-margin "dans la marge")
;;; info bar at botttom of drscheme frame

View File

@ -156,7 +156,6 @@
(online-expansion-show-variable-errors-as "Ungebundene Bezeichner anzeigen")
(online-expansion-show-other-errors-as "Andere Fehler anzeigen")
; locations the errors can be shown
(online-expansion-error-in-corner "in der Ecke des Fensters")
(online-expansion-error-gold-highlight "mit goldener Markierung")
(online-expansion-error-margin "am Rand")
;;; info bar at botttom of drscheme frame