Path: utzoo!attcan!utgpu!jarvis.csri.toronto.edu!mailrus!uwm.edu!gem.mps.ohio-state.edu!apple!bloom-beacon!eru!luth!sunic!ericom!erix.ericsson.se!joe From: joe@erix.ericsson.se (Joe Armstrong) Newsgroups: comp.lang.smalltalk Subject: help wanted with SmalltalkV Keywords: smalltalkV graphics Message-ID: <2211@erix.ericsson.se> Date: 20 Sep 89 08:48:36 GMT Organization: Ellemtel Utvecklings AB, Stockholm, Sweden Lines: 129 A problem and a question about SmalltalkV - 1) How do I get rid of old windows after I've done 'move' or 'reframe:' on them. I have an application consisting of a single graphics window - a subwindow of topPane, when I reframe the topPane I need to redraw the graphics contents of the window - that works fine. BUT the old window is not removed from the display - If I do redraw screen from the background menu then the old window is removed (so the window wasn't really there after all!) - I guess I need to do something in the method 'redisplay' but what ???? 2) When I do fileIn on certain files some of the class methods get displayed with a crotchet instead on the point at the end of every line - what does this mean? The offending Class is as follows: %------------------------- cut here ------------------------- Object subclass: #WaveEd instanceVariableNames: 'pen topPane graphPane waveData ' classVariableNames: '' poolDictionaries: '' ! !WaveEd class methods ! ! !WaveEd methods ! activatePane "The pane of the bit editor has been activated. Change the cursor to the crosshair." CursorManager hair change.! changeBits: aPoint Transcript cr;show:'changeBits'.! changeStatus: aPoint " this gets sent when you click the mouse left button in the window" " Transcript cr; show: 'changeStatus'; show: (topPane frame printString). "! checkCursor Transcript cr;show:'check cursor'! deactivatePane "The pane has been deactivated. change the cursor to the normal cursor shape." CursorManager normal change.! initStatus: aRectangle " This gets done once when we open the window " waveData := Array new:5. waveData at:1 put: 100 @ 200; at:2 put: 300 @ 600; at:3 put: 500 @ 100; at:4 put: 700 @ 620; at:5 put: 900 @ 10. Display white:(graphPane frame). self redisplay. " next line must be present -- crashes if not !!!!!! " ^Form new extent: aRectangle extent.! open "prompt the user for a rectangle then open self " self open: (PointDispatcher rectangleFromUserOfSize:300 @ 80).! open:aRectangle topPane := TopPane new label: 'WaveForm Editor'; menu: #windowMenu; model: self; minimumSize: 20@20; yourself. graphPane := (GraphPane new model: self; name: #initStatus:; framingRatio:(0 @ 0 extent: 1 @ 1); change: #changeStatus:). topPane addSubpane: graphPane . pen := Pen new. pen clipRect:aRectangle; combinationRule: Form reverse; mask:nil. topPane reframe:aRectangle. topPane dispatcher openWindow scheduleWindow.! redisplay | rect | rect := graphPane frame. pen clipRect:rect; up; goto:(rect origin); down; goto:(rect center). topPane dispatcher scheduleWindow.! reframe: aRect self redisplay.! windowMenu "Answer the window menu for the bit editor." ^Menu labels: 'collapse\cycle\frame\move\close' withCrs lines: #() selectors: #(collapse cycle frame move closeIt).! !