diff --git a/collects/drscheme/private/module-language.ss b/collects/drscheme/private/module-language.ss index 169f2e84bf..da8dc8ebc9 100644 --- a/collects/drscheme/private/module-language.ss +++ b/collects/drscheme/private/module-language.ss @@ -368,7 +368,7 @@ [callback void])) (define auto-text-panel (new group-box-panel% [parent new-parent] - [label "Auto-text"])) ;!! need string-constant + [label (string-constant module-language-auto-text)])) (define auto-text-text-box (new text-field% [parent auto-text-panel] [label #f] @@ -490,7 +490,10 @@ (format "~s" vec)))) (define (get-auto-text) - (string-append (send auto-text-text-box get-value) "\n")) + (let ([str (send auto-text-text-box get-value)]) + (cond + [(equal? str "") ""] + [else (string-append str "\n")]))) (define (install-auto-text str) (send auto-text-text-box set-value (regexp-replace #rx"\n$" str ""))) @@ -500,6 +503,7 @@ (install-collection-paths '(default)) (update-buttons) + (install-auto-text default-auto-text) (case-lambda [() diff --git a/collects/string-constants/english-string-constants.ss b/collects/string-constants/english-string-constants.ss index 86f0485563..e173f76b85 100644 --- a/collects/string-constants/english-string-constants.ss +++ b/collects/string-constants/english-string-constants.ss @@ -1045,7 +1045,8 @@ please adhere to these guidelines: (no-language-chosen "No language chosen") (module-language-one-line-summary "Run creates a REPL in the context of the module, including the module's declared language") - + (module-language-auto-text "Automatic #lang line") ;; shows up in the details section of the module language + ;;; from the `not a language language' used initially in drscheme. (must-choose-language "DrScheme cannot process programs until you choose a programming language.")