From d482aa50ee246fbe0793139e7fe77910dc4cc7b7 Mon Sep 17 00:00:00 2001 From: Matthew Flatt Date: Sat, 4 Jul 1998 02:58:37 +0000 Subject: [PATCH] . original commit: be254606e45e010375878362d170e021b4782887 --- collects/tests/mred/draw-info.txt | 8 +++++++- collects/tests/mred/draw.ss | 7 ++----- collects/tests/mred/frame-steps.txt | 5 ++++- collects/tests/mred/item.ss | 2 ++ 4 files changed, 15 insertions(+), 7 deletions(-) diff --git a/collects/tests/mred/draw-info.txt b/collects/tests/mred/draw-info.txt index 176b9995..0afd9508 100644 --- a/collects/tests/mred/draw-info.txt +++ b/collects/tests/mred/draw-info.txt @@ -1,6 +1,12 @@ The drawing area should have the following features: + At the top-left, when the window is opened for the first time, + you shoudl see a hollow box with a line sticking out to the + bottom left. Repainting the canvas should produce instead + a solid box and no line. Repainting with Pixmap or Bitmap + should always produce the hollow box and line. + At the top, "Pen 0 x 0" in a consistent font (i.e., re-painting should not change the font) "Pen 1 x 1" in a possibly different font @@ -10,7 +16,7 @@ The drawing area should have the following features: (if the line is missing, it was probably erased when the text was repainted, and that is bad) - the drawings under 0x0 and 1x1 should look the same: + The drawings under 0x0 and 1x1 should look the same: TopLeft: h-line should be left-aligned with box below it, but extend 1 extra pixel. v-line similarly should be top-aligned and 1 pixel longer. The lines should not diff --git a/collects/tests/mred/draw.ss b/collects/tests/mred/draw.ss index 565d1d5a..9a58daab 100644 --- a/collects/tests/mred/draw.ss +++ b/collects/tests/mred/draw.ss @@ -12,10 +12,9 @@ "Graphics Test" -1 -1 300 450)] [vp (make-object mred:vertical-panel% f)] - [hp-instr (make-object mred:horizontal-panel% vp)] [hp0 (make-object mred:horizontal-panel% vp)] [hp (make-object mred:horizontal-panel% vp)] - [hp2 (make-object mred:horizontal-panel% vp)] + [hp2 hp] [bb (make-object wx:bitmap% (sys-path "bb.gif") wx:const-bitmap-type-gif)] [return (make-object wx:bitmap% (sys-path "return.xbm") @@ -23,11 +22,9 @@ [tmp-mdc (make-object wx:memory-dc%)] [use-bitmap? #f] [depth-one? #f]) - (send hp-instr stretchable-in-y #f) (send hp0 stretchable-in-y #f) (send hp stretchable-in-y #f) - (send hp2 stretchable-in-y #f) - (make-object mred:button% hp-instr + (make-object mred:button% hp0 (lambda (b e) (send (send (mred:edit-file (local-path "draw-info.txt")) get-edit) lock #t)) "What Should I See?") diff --git a/collects/tests/mred/frame-steps.txt b/collects/tests/mred/frame-steps.txt index a7cc90bc..106ecb94 100644 --- a/collects/tests/mred/frame-steps.txt +++ b/collects/tests/mred/frame-steps.txt @@ -263,5 +263,8 @@ and make sure the resulting controls look right. Resize each frame and check stretchiness before closing it. Go back to the default configuration and try the 3 other combinations -of label and button fonts. +of label and button fonts. The big label font should apply to external +control labels, and to message items. The button font should apply to +the content of controls (names within a button, checkbox, listbox, +choice, or text control). diff --git a/collects/tests/mred/item.ss b/collects/tests/mred/item.ss index 850c3372..15e17784 100644 --- a/collects/tests/mred/item.ss +++ b/collects/tests/mred/item.ss @@ -1,5 +1,6 @@ (define my-txt #f) +(define my-lb #f) (define special-font (send wx:the-font-list find-or-create-font 20 wx:const-decorative @@ -258,6 +259,7 @@ -1 -1 -1 -1)) (set! my-txt txt) + (set! my-lb lb) (add-testers "Button" b) (add-change-label "Button" b lp #f OTHER-LABEL)