*** empty log message ***
authorpenk
Tue, 09 Jan 2001 17:03:56 +0100
changeset 3397 55d7642b74f6
parent 3396 18f99e9fc5ec
child 3398 763d33dbd23a
*** empty log message ***
DeviceWorkstation.st
--- a/DeviceWorkstation.st	Mon Jan 08 18:33:01 2001 +0100
+++ b/DeviceWorkstation.st	Tue Jan 09 17:03:56 2001 +0100
@@ -1,6 +1,6 @@
 "
 COPYRIGHT (c) 1993 by Claus Gittinger
-	      All Rights Reserved
+              All Rights Reserved
 
  This software is furnished under a license and may be used
  only in accordance with the terms of that license and with the
@@ -13,27 +13,27 @@
 "{ Package: 'stx:libview' }"
 
 HostGraphicsDevice subclass:#DeviceWorkstation
-	instanceVariableNames:'visualType monitorType depth ncells bitsPerRGB bitsRed bitsGreen
-		bitsBlue redMask greenMask blueMask redShift greenShift blueShift
-		hasColors hasGreyscales width height widthMM heightMM
-		resolutionHor resolutionVer idToTableIndexMapping knownViews
-		knownIds knownBitmaps knownBitmapIds dispatching dispatchProcess
-		exitOnLastClose ctrlDown shiftDown metaDown altDown superDown
-		motionEventCompression lastId lastView keyboardMap rootView
-		isSlow activeKeyboardGrab activePointerGrab buttonTranslation
-		multiClickTimeDelta altModifiers metaModifiers ctrlModifiers
-		shiftModifiers superModifiers supportsDeepIcons preferredIconSize
-		ditherColors fixColors numFixRed numFixGreen numFixBlue
-		fixGrayColors copyBuffer lastCopyBuffer blackColor whiteColor
-		focusMode activeView clipBoardEncoding focusView
-		deviceErrorSignal deviceIOErrorSignal'
-	classVariableNames:'ButtonTranslation MultiClickTimeDelta DeviceErrorSignal
-		DeviceIOErrorSignal DeviceIOTimeoutErrorSignal ErrorPrinting
-		DefaultScreen AllScreens CurrentScreenQuerySignal
-		LastActiveScreen LastActiveProcess WindowsRightButtonBehavior
-		ExitOnLastClose DrawingOnClosedDeviceSignal'
-	poolDictionaries:''
-	category:'Interface-Graphics'
+        instanceVariableNames:'visualType monitorType depth ncells bitsPerRGB bitsRed bitsGreen
+                bitsBlue redMask greenMask blueMask redShift greenShift blueShift
+                hasColors hasGreyscales width height widthMM heightMM
+                resolutionHor resolutionVer idToTableIndexMapping knownViews
+                knownIds knownBitmaps knownBitmapIds dispatching dispatchProcess
+                exitOnLastClose ctrlDown shiftDown metaDown altDown superDown
+                motionEventCompression lastId lastView keyboardMap rootView
+                isSlow activeKeyboardGrab activePointerGrab buttonTranslation
+                multiClickTimeDelta altModifiers metaModifiers ctrlModifiers
+                shiftModifiers superModifiers supportsDeepIcons preferredIconSize
+                ditherColors fixColors numFixRed numFixGreen numFixBlue
+                fixGrayColors copyBuffer lastCopyBuffer blackColor whiteColor
+                focusMode activeView clipBoardEncoding focusView
+                deviceErrorSignal deviceIOErrorSignal'
+        classVariableNames:'ButtonTranslation MultiClickTimeDelta DeviceErrorSignal
+                DeviceIOErrorSignal DeviceIOTimeoutErrorSignal ErrorPrinting
+                DefaultScreen AllScreens CurrentScreenQuerySignal
+                LastActiveScreen LastActiveProcess WindowsRightButtonBehavior
+                ExitOnLastClose DrawingOnClosedDeviceSignal'
+        poolDictionaries:''
+        category:'Interface-Graphics'
 !
 
 !DeviceWorkstation class methodsFor:'documentation'!
@@ -41,7 +41,7 @@
 copyright
 "
 COPYRIGHT (c) 1993 by Claus Gittinger
-	      All Rights Reserved
+              All Rights Reserved
 
  This software is furnished under a license and may be used
  only in accordance with the terms of that license and with the
@@ -72,7 +72,7 @@
       depth           <SmallInteger>    bits per color
       ncells          <SmallInteger>    number of colors (i.e. colormap size; not always == 2^depth)
       bitsPerRGB      <SmallInteger>    number of valid bits per rgb component
-					(actual number taken in A/D converter; not all devices report the true value)
+                                        (actual number taken in A/D converter; not all devices report the true value)
       bitsRed         <SmallInteger>    number of red bits (only valid for TrueColor displays)
       bitsGreen       <SmallInteger>    number of green bits (only valid for TrueColor displays)
       bitsBlue        <SmallInteger>    number of blue bits (only valid for TrueColor displays)
@@ -100,8 +100,8 @@
 
       dispatching     <Boolean>         true, if currently in dispatch loop
       exitDispatchOnLastWindowClose
-		      <Boolean>         if true, dispatch is finished when the last
-					window closes (default:true).
+                      <Boolean>         if true, dispatch is finished when the last
+                                        window closes (default:true).
 
       ctrlDown        <Boolean>         true, if control key currently pressed
       shiftDown       <Boolean>         true, if shift key currently pressed
@@ -109,8 +109,8 @@
       altDown         <Boolean>         true, if alt key is currently pressed
 
       motionEventCompression
-		      <Boolean>         if true motion events are compressed
-					(obsolete: now done in sensor)
+                      <Boolean>         if true motion events are compressed
+                                        (obsolete: now done in sensor)
 
       lastId          <Number>          the id of the last events view (internal)
       lastView        <View>            the last events view (internal, for faster id->view mapping)
@@ -118,38 +118,38 @@
       keyboardMap     <KeyBdMap>        mapping for keys
       rootView        <DisplayRootView> this displays root window
       isSlow          <Boolean>         set/cleared from startup - used to turn off
-					things like popup-shadows etc.
+                                        things like popup-shadows etc.
 
       focusMode       <Symbol>          nil, #pointer or #activeWindow
       activeWindow    <View>            WINDOWS only: the currently active (foreground) view
 
       clipBoardEncoding
-		      <Symbol>          encoding of pasted clipBoard text;
-					nil means: iso8859.
-					set this to #shiftJis, if pasting
-					SJIS text (for example, from netscape)
-					Some systems pass encoding information
-					in the clipBoard - there, this is not
-					needed.
+                      <Symbol>          encoding of pasted clipBoard text;
+                                        nil means: iso8859.
+                                        set this to #shiftJis, if pasting
+                                        SJIS text (for example, from netscape)
+                                        Some systems pass encoding information
+                                        in the clipBoard - there, this is not
+                                        needed.
 
     [class variables:]
 
       MultiClickTimeDelta               in ms; controls how long of a delay is
-					required between two clicks, to NOT take
-					it as a multi-click.
+                                        required between two clicks, to NOT take
+                                        it as a multi-click.
 
       ErrorPrinting                     controls low-level (X-) error message printing
 
       AllScreens                        a collectin of known screens
 
     [see also:]
-	GraphicsContext DeviceDrawable
-	WindowSensor WindowGroup WindowEvent
-	ProcessorScheduler
-	PSMedium
+        GraphicsContext DeviceDrawable
+        WindowSensor WindowGroup WindowEvent
+        ProcessorScheduler
+        PSMedium
 
     [author:]
-	Claus Gittinger
+        Claus Gittinger
 "
 !
 
@@ -172,9 +172,9 @@
 
     Individual events can be enabled or disabled. The ones that are enabled
     by default are:
-	keypress / keyRelease
-	buttonPress / buttonRelease / buttonMotion (i.e. motion with button pressed)
-	pointerEnter / pointerLeave
+        keypress / keyRelease
+        buttonPress / buttonRelease / buttonMotion (i.e. motion with button pressed)
+        pointerEnter / pointerLeave
 
     other events have to be enabled by sending a corresponding #enableXXXEvent
     message to the view which shall receive those events.
@@ -199,20 +199,20 @@
 
     Currently, there is are twoconcrete display classes (released to the public):
 
-	XWorkstation    - a plain X window interface
-
-	GLXWorkstation  - an X window interface with a GL(tm) (3D graphic library) 
-			  extension; either simulated (VGL) or a real GL 
-			  (real GL is only available on SGI machines)
+        XWorkstation    - a plain X window interface
+
+        GLXWorkstation  - an X window interface with a GL(tm) (3D graphic library) 
+                          extension; either simulated (VGL) or a real GL 
+                          (real GL is only available on SGI machines)
 
     the following are coming soon:
 
-	OpenGLWorkstation   
-			- an X window interface with a openGL(tm) (3D graphic library) 
-			  extension; either simulated (MESA) or a real openGL 
-			  (real openGL is only available on SGI/NT machines)
-
-	WinWorkstation  - what will that be ?
+        OpenGLWorkstation   
+                        - an X window interface with a openGL(tm) (3D graphic library) 
+                          extension; either simulated (MESA) or a real openGL 
+                          (real openGL is only available on SGI/NT machines)
+
+        WinWorkstation  - what will that be ?
 
     An experimental version for a NeXTStep interface exists, but is currently
     no longer maintained and not released.
@@ -234,15 +234,15 @@
 
     - create a new instance of XWorkstation:
 
-	Smalltalk at:#Display2 put:(XWorkstation new).
+        Smalltalk at:#Display2 put:(XWorkstation new).
       or:
-	Smalltalk at:#Display2 put:(GLXWorkstation new).
+        Smalltalk at:#Display2 put:(GLXWorkstation new).
 
 
     - have it connect to the display (i.e. the xServer):
       (replace 'localhost' below with the name of your display)
 
-	Display2 := Display2 initializeFor:'localhost:0.0'
+        Display2 := Display2 initializeFor:'localhost:0.0'
 
       returns nil, if connection is refused 
       - leaving you with Display2==nil in this case.
@@ -251,31 +251,31 @@
     - start an event dispatcher process for it:
       (this is now no longer needed - the first opened view will do it for you)
 
-	Display2 startDispatch
+        Display2 startDispatch
 
 
     - optionally set its keyboard map
       (since this is usually done for Display in the startup-file,
        the new display does not have all your added key bindings)
 
-	Display2 keyboardMap:(Display keyboardMap)
+        Display2 keyboardMap:(Display keyboardMap)
 
 
     - create a view for it:
 
-	(FileBrowser onDevice:Display2) open
-
-	(Workspace onDevice:Display2) open
-
-	(Launcher onDevice:Display2) open
-	    does not work with Launcher, since its an ApplicationModel (not a view)
-	    use:
-		Launcher openOnDevice:Display2
-	    instead.
+        (FileBrowser onDevice:Display2) open
+
+        (Workspace onDevice:Display2) open
+
+        (Launcher onDevice:Display2) open
+            does not work with Launcher, since its an ApplicationModel (not a view)
+            use:
+                Launcher openOnDevice:Display2
+            instead.
 
     For all of the above, there is now a convenient helper method in
     ApplicationModel, which allows to write:
-	Application openOnXScreenNamed:'foo:0'
+        Application openOnXScreenNamed:'foo:0'
 
     However, as mentioned above, there may be a few places, where the default
     display 'Display' is still hard-coded - especially, in contributed and
@@ -302,21 +302,21 @@
     event dispatchers context.
     For a save environment, you should add static exception handler blocks on those 
     signals; i.e. the setup for remote displays should look somewhat like:
-	|newDpy|
-
-	newDpy := GLXWorkstation new.
-	newDpy := newDpy initializeFor:'localhost:0.0'.
-	newDpy isNil ifTrue:[
-	    self warn:'cannot connect ...'.
-	] ifFalse:[
-	    newDpy deviceIOErrorSignal handlerBlock:[:ex |
-		Transcript beep.
-		Transcript showCR:'Display (' , newDpy displayName , '): connection broken.'.
-		AbortSignal raise.
-	    ].
-	    newDpy startDispatch.
-	    Launcher openOnDevice:newDpy.
-	].
+        |newDpy|
+
+        newDpy := GLXWorkstation new.
+        newDpy := newDpy initializeFor:'localhost:0.0'.
+        newDpy isNil ifTrue:[
+            self warn:'cannot connect ...'.
+        ] ifFalse:[
+            newDpy deviceIOErrorSignal handlerBlock:[:ex |
+                Transcript beep.
+                Transcript showCR:'Display (' , newDpy displayName , '): connection broken.'.
+                AbortSignal raise.
+            ].
+            newDpy startDispatch.
+            Launcher openOnDevice:newDpy.
+        ].
 
     There may still some problems to be expected,
     if the screens have different display capabilities (b&w vs. greyscale vs.
@@ -334,25 +334,25 @@
     "create local error signals; enable errorPrinting"
 
     DeviceErrorSignal isNil ifTrue:[
-	DeviceErrorSignal := (Signal new) mayProceed:true.
-	DeviceErrorSignal notifierString:'device error'.
-	DeviceErrorSignal nameClass:self message:#deviceErrorSignal.
-
-	DeviceIOErrorSignal := (Signal new) mayProceed:false.
-	DeviceIOErrorSignal notifierString:'device IO error'.
-	DeviceIOErrorSignal nameClass:self message:#deviceIOErrorSignal.
-
-	DeviceIOTimeoutErrorSignal := DeviceIOErrorSignal newSignalMayProceed:false.
-	DeviceIOTimeoutErrorSignal notifierString:'device IO timeout error'.
-	DeviceIOTimeoutErrorSignal nameClass:self message:#deviceIOTimeoutErrorSignal.
-
-	CurrentScreenQuerySignal := QuerySignal new.
-	CurrentScreenQuerySignal nameClass:self message:#currentScreenQuerySignal.
-	CurrentScreenQuerySignal notifierString:'asking for current screen'.
-
-	DrawingOnClosedDeviceSignal := DeviceErrorSignal newSignalMayProceed:true.
-	DrawingOnClosedDeviceSignal nameClass:self message:#drawingOnClosedDeviceSignal.
-	DrawingOnClosedDeviceSignal notifierString:'drawing attempt on closed graphics device'.
+        DeviceErrorSignal := (Signal new) mayProceed:true.
+        DeviceErrorSignal notifierString:'device error'.
+        DeviceErrorSignal nameClass:self message:#deviceErrorSignal.
+
+        DeviceIOErrorSignal := (Signal new) mayProceed:false.
+        DeviceIOErrorSignal notifierString:'device IO error'.
+        DeviceIOErrorSignal nameClass:self message:#deviceIOErrorSignal.
+
+        DeviceIOTimeoutErrorSignal := DeviceIOErrorSignal newSignalMayProceed:false.
+        DeviceIOTimeoutErrorSignal notifierString:'device IO timeout error'.
+        DeviceIOTimeoutErrorSignal nameClass:self message:#deviceIOTimeoutErrorSignal.
+
+        CurrentScreenQuerySignal := QuerySignal new.
+        CurrentScreenQuerySignal nameClass:self message:#currentScreenQuerySignal.
+        CurrentScreenQuerySignal notifierString:'asking for current screen'.
+
+        DrawingOnClosedDeviceSignal := DeviceErrorSignal newSignalMayProceed:true.
+        DrawingOnClosedDeviceSignal nameClass:self message:#drawingOnClosedDeviceSignal.
+        DrawingOnClosedDeviceSignal notifierString:'drawing attempt on closed graphics device'.
     ].
 
     ErrorPrinting := true.
@@ -431,7 +431,7 @@
 
     ButtonTranslation := anArray.
     Display notNil ifTrue:[
-	Display buttonTranslation:anArray
+        Display buttonTranslation:anArray
     ].
 ! !
 
@@ -442,9 +442,9 @@
 
     "an error in the devices low level code (typically Xlib or XtLib)
      This is invoked via 
-	XError->errorInterrupt:#DisplayError->registeredErrorInterruptHandlers
+        XError->errorInterrupt:#DisplayError->registeredErrorInterruptHandlers
      or
-	XError->errorInterrupt:#DisplayIOError->registeredErrorInterruptHandlers
+        XError->errorInterrupt:#DisplayIOError->registeredErrorInterruptHandlers
 
      looks if a signal handler for DeviceErrorSignal is present,
      and - if so raises the signal. 
@@ -458,20 +458,20 @@
     'DeviceWorkstation [info]: errorInterrupt: ' infoPrint. errID infoPrintCR.
 
     errID notNil ifTrue:[
-	"/
-	"/ timeoutError passes the device;
-	"/ the others pass the devicesID
-	"/
-	errID == #DisplayIOTimeoutError ifTrue:[
-	    theDevice := aParameter.
-	    "/ 'device timeout error' printCR.
-	] ifFalse:[
-	    AllScreens do:[:aDisplayDevice |
-		aDisplayDevice id = aParameter ifTrue:[
-		    theDevice := aDisplayDevice.
-		]
-	    ]
-	]
+        "/
+        "/ timeoutError passes the device;
+        "/ the others pass the devicesID
+        "/
+        errID == #DisplayIOTimeoutError ifTrue:[
+            theDevice := aParameter.
+            "/ 'device timeout error' printCR.
+        ] ifFalse:[
+            AllScreens do:[:aDisplayDevice |
+                aDisplayDevice id = aParameter ifTrue:[
+                    theDevice := aDisplayDevice.
+                ]
+            ]
+        ]
     ].
     'DeviceWorkstation [info]: device: ' infoPrint. theDevice infoPrintCR.
 
@@ -480,36 +480,36 @@
 
     signalHolder := theDevice ? self.
     errID == #DisplayIOError ifTrue:[
-	"/ always raises an exception
-	msg := 'Display I/O Error'.
-	badResource := theDevice.
-	theSignal := signalHolder deviceIOErrorSignal.
+        "/ always raises an exception
+        msg := 'Display I/O Error'.
+        badResource := theDevice.
+        theSignal := signalHolder deviceIOErrorSignal.
     ] ifFalse:[
-	errID == #DisplayIOTimeoutError ifTrue:[
-	    "/ always raises an exception for the current process
-	    msg := 'Display I/O timeout Error'.
-	    badResource := theDevice.
-	    theSignal := signalHolder deviceIOTimeoutErrorSignal
-	] ifFalse:[
-	    theSignal := signalHolder deviceErrorSignal.
-	    "/ only raises an exception if handled
-
-	    "/ that will become instance-specific information in
-	    "/ the near future ...
-
-	    badId := self resourceIdOfLastError.
-	    badId ~~ 0 ifTrue:[
-		badResource := self resourceOfId:badId.
-	    ].
-	    msg := 'Display error: ' , (self lastErrorString).
-
-	    theSignal isHandled ifFalse:[
-		ErrorPrinting ifTrue:[
-		    ('DeviceWorkstation [error]: ' , msg) errorPrintCR
-		].
-		^ self
-	    ]
-	]
+        errID == #DisplayIOTimeoutError ifTrue:[
+            "/ always raises an exception for the current process
+            msg := 'Display I/O timeout Error'.
+            badResource := theDevice.
+            theSignal := signalHolder deviceIOTimeoutErrorSignal
+        ] ifFalse:[
+            theSignal := signalHolder deviceErrorSignal.
+            "/ only raises an exception if handled
+
+            "/ that will become instance-specific information in
+            "/ the near future ...
+
+            badId := self resourceIdOfLastError.
+            badId ~~ 0 ifTrue:[
+                badResource := self resourceOfId:badId.
+            ].
+            msg := 'Display error: ' , (self lastErrorString).
+
+            theSignal isHandled ifFalse:[
+                ErrorPrinting ifTrue:[
+                    ('DeviceWorkstation [error]: ' , msg) errorPrintCR
+                ].
+                ^ self
+            ]
+        ]
     ].
 
 
@@ -517,60 +517,60 @@
     "/ and force it to shutdown
 
     theDevice notNil ifTrue:[
-	"/ DiplayIOTimeoutError is a synchronous event, that should hit the process
-	"/ that caused the timeout.
-
-	errID ~~ #DisplayIOTimeoutError ifTrue:[
-	    p := theDevice dispatchProcess.
-	    (p notNil and:[p ~~ Processor activeProcess]) ifTrue:[
-		'DeviceWorkstation [info]: interrupting: ' infoPrint. p displayString infoPrintCR.
-		p interruptWith:[
-		    'DeviceWorkstation [warning]: raising - exception' errorPrintCR.
-		    theSignal mayProceed ifTrue:[
-			theSignal raiseRequestWith:badResource errorString:msg.
-		    ] ifFalse:[
-			theSignal raiseWith:badResource errorString:msg.
-		    ].
-		    'DeviceWorkstation [warning]: broken connection' errorPrintCR.
-		    theDevice brokenConnection.
-		    'DeviceWorkstation [warning]: stopping dispatch' errorPrintCR.
-		    theDevice stopDispatch.
-		].
-		^ self.
+        "/ DiplayIOTimeoutError is a synchronous event, that should hit the process
+        "/ that caused the timeout.
+
+        errID ~~ #DisplayIOTimeoutError ifTrue:[
+            p := theDevice dispatchProcess.
+            (p notNil and:[p ~~ Processor activeProcess]) ifTrue:[
+                'DeviceWorkstation [info]: interrupting: ' infoPrint. p displayString infoPrintCR.
+                p interruptWith:[
+                    'DeviceWorkstation [warning]: raising - exception' errorPrintCR.
+                    theSignal mayProceed ifTrue:[
+                        theSignal raiseRequestWith:badResource errorString:msg.
+                    ] ifFalse:[
+                        theSignal raiseWith:badResource errorString:msg.
+                    ].
+                    'DeviceWorkstation [warning]: broken connection' errorPrintCR.
+                    theDevice brokenConnection.
+                    'DeviceWorkstation [warning]: stopping dispatch' errorPrintCR.
+                    theDevice stopDispatch.
+                ].
+                ^ self.
 "/                Processor reschedule.
 "/                AbortSignal raise.
-	    ].
-	].
+            ].
+        ].
     ].
 
     (theSignal isHandled or:[theSignal handlerBlock notNil]) ifTrue:[
 "/        'DeviceWorkstation [info]: interrupting current process: ' infoPrint. 
 "/        Processor activeProcess displayString infoPrintCR.
 
-	'DeviceWorkstation [info]: raising signal in current process' infoPrintCR. 
-	theSignal mayProceed ifTrue:[
-	    theSignal raiseRequestWith:badResource errorString:msg.
-	] ifFalse:[
-	    theSignal raiseWith:badResource errorString:msg.
-	].        
+        'DeviceWorkstation [info]: raising signal in current process' infoPrintCR. 
+        theSignal mayProceed ifTrue:[
+            theSignal raiseRequestWith:badResource errorString:msg.
+        ] ifFalse:[
+            theSignal raiseWith:badResource errorString:msg.
+        ].        
     ].
 
     theDevice notNil ifTrue:[
-	"/ 'broken connection' printCR.
-	'DeviceWorkstation [info]: sending #brokenConnection' infoPrintCR. 
-	theDevice brokenConnection.
-	theDevice dispatchProcess == Processor activeProcess ifTrue:[
-	    "/ I am running in the dispatch process
-	    "/ and nobody handles theSignal, so abort the dispatcher
-
-	   'DeviceWorkstation [info]: raising abortSignal' infoPrintCR. 
-	    AbortSignal raise.
-	] ifFalse:[
-	    "/ Some other process (probably not even guilty - like someone doing a draw after a change) ...
-	    "/ ... see if we can unwind out of the drawing operation
-	   'DeviceWorkstation [info]: should unwind the draw operation' infoPrintCR. 
-	    thisContext fullPrintAll.
-	]
+        "/ 'broken connection' printCR.
+        'DeviceWorkstation [info]: sending #brokenConnection' infoPrintCR. 
+        theDevice brokenConnection.
+        theDevice dispatchProcess == Processor activeProcess ifTrue:[
+            "/ I am running in the dispatch process
+            "/ and nobody handles theSignal, so abort the dispatcher
+
+           'DeviceWorkstation [info]: raising abortSignal' infoPrintCR. 
+            AbortSignal raise.
+        ] ifFalse:[
+            "/ Some other process (probably not even guilty - like someone doing a draw after a change) ...
+            "/ ... see if we can unwind out of the drawing operation
+           'DeviceWorkstation [info]: should unwind the draw operation' infoPrintCR. 
+            thisContext fullPrintAll.
+        ]
     ].
     'DeviceWorkstation [info]: proceeding after error' infoPrintCR. 
 
@@ -613,14 +613,14 @@
      Needed for error handling"
 
     Form allInstancesDo:[:f |
-	f id == id ifTrue:[^ f]
+        f id == id ifTrue:[^ f]
     ].
 
     self allInstancesDo:[:aDisplay |
-	aDisplay allViewsDo:[:aView |
-	    aView id == id ifTrue:[^ aView].
-	    aView gcId == id ifTrue:[^ aView]
-	].
+        aDisplay allViewsDo:[:aView |
+            aView id == id ifTrue:[^ aView].
+            aView gcId == id ifTrue:[^ aView]
+        ].
 
 "/        |views|
 "/        views := aDisplay knownViews.
@@ -633,11 +633,11 @@
     ].
 
     Color allInstancesDo:[:c |
-	c colorId == id ifTrue:[^ c]
+        c colorId == id ifTrue:[^ c]
     ].
 
     Font allInstancesDo:[:f |
-	f fontId == id ifTrue:[^ f]
+        f fontId == id ifTrue:[^ f]
     ].
     ^ nil
 
@@ -828,8 +828,8 @@
     "animate a rubber-rectangle from startRect to endRect.
      Can be used by buttons, which open some dialog for nicer user feedback.
      Notice: since the displays window manager typically allows a topWindow
-	     to be placed by the user, this should not be used for modeless
-	     topViews.
+             to be placed by the user, this should not be used for modeless
+             topViews.
     "
 
     ^ self zoom:startRect to:endRect duration:300    
@@ -846,8 +846,8 @@
     "animate a rubber-rectangle from startRect to endRect.
      Can be used by buttons, which open some dialog for nicer user feedback.
      Notice: since the displays window manager typically allows a topWindow
-	     to be placed by the user, this should not be used for modeless
-	     topViews.
+             to be placed by the user, this should not be used for modeless
+             topViews.
     "
 
     |steps dExt dOrg org ext root|
@@ -858,16 +858,16 @@
     dExt := (endRect extent - startRect extent) / steps.
     dOrg := (endRect origin - startRect origin) / steps.
     0 to:steps do:[:step |
-	org := (startRect origin + (dOrg * step)) rounded.
-	ext := (startRect extent + (dExt * step)) rounded.
-	rootView clippedByChildren:false.
-	rootView xoring:[
-	    rootView displayRectangleX:org x y:org y width:ext x height:ext y
-	].
-	Delay waitForMilliseconds:(milliseconds // steps).
-	rootView xoring:[
-	    rootView displayRectangleX:org x y:org y width:ext x height:ext y
-	].
+        org := (startRect origin + (dOrg * step)) rounded.
+        ext := (startRect extent + (dExt * step)) rounded.
+        rootView clippedByChildren:false.
+        rootView xoring:[
+            rootView displayRectangleX:org x y:org y width:ext x height:ext y
+        ].
+        Delay waitForMilliseconds:(milliseconds // steps).
+        rootView xoring:[
+            rootView displayRectangleX:org x y:org y width:ext x height:ext y
+        ].
     ].
     rootView clippedByChildren:true.
 
@@ -884,8 +884,8 @@
      Can be used by buttons, which open some dialog for nicer user feedback.
      The speed is computed for the longest edge to run at the given speed.
      Notice: since the displays window manager typically allows a topWindow
-	     to be placed by the user, this should not be used for modeless
-	     topViews.
+             to be placed by the user, this should not be used for modeless
+             topViews.
     "
 
     |maxDistance|
@@ -896,7 +896,7 @@
     maxDistance := maxDistance max:(endRect corner - startRect corner).
     maxDistance := maxDistance x max:(maxDistance y).
     ^ self
-	zoom:startRect to:endRect duration:(maxDistance abs / pixelsPerSecond * 1000)       
+        zoom:startRect to:endRect duration:(maxDistance abs / pixelsPerSecond * 1000)       
 
     "
      Screen current zoom:(10@10 corner:20@20) to:(20@20 corner:1000@1000) speed:1000
@@ -919,14 +919,14 @@
     rootView paint:Color black.
     r := aRectangle.
     0 to:bw-1 do:[:i |
-	rootView displayRectangle:r.
-	r := r insetBy:1.
+        rootView displayRectangle:r.
+        r := r insetBy:1.
     ].
     rootView clippedByChildren:true.
 
     "
      Display restoreAfter:[
-	Display border:(10@10 corner:100@100) width:2.
+        Display border:(10@10 corner:100@100) width:2.
      ]
     "
 
@@ -948,7 +948,7 @@
 
     "
      Display restoreAfter:[
-	Display displayOpaqueString:'hello' x:10 y:10.
+        Display displayOpaqueString:'hello' x:10 y:10.
      ]
     "
 
@@ -967,7 +967,7 @@
 
     "
      Display restoreAfter:[
-	Display displayString:'hello' x:10 y:10.
+        Display displayString:'hello' x:10 y:10.
      ]
     "
 
@@ -1164,9 +1164,9 @@
 
     "reverse buttonTranslation"
     buttonTranslation notNil ifTrue:[
-	buttonNr := buttonTranslation indexOf:aButton ifAbsent:[1].
+        buttonNr := buttonTranslation indexOf:aButton ifAbsent:[1].
     ] ifFalse:[
-	buttonNr := aButton.
+        buttonNr := aButton.
     ].
     ^ (aMask bitTest:(self buttonMotionMask:buttonNr))
 !
@@ -1247,7 +1247,7 @@
      It is not guaranteed, that a particular display device supports this."
 
     rootView isNil ifTrue:[
-	rootView := DisplayRootView onDevice:self
+        rootView := DisplayRootView onDevice:self
     ].
     ^ rootView
 
@@ -1341,18 +1341,18 @@
     id := self viewIdFromPoint:aPoint.
     view := self viewFromId:id.
     view isNil ifTrue:[
-	"/ search on other devices (if present).
-	"/ This may find the view, in case another device
-	"/ has its views on the same display screen
-	Screen allScreens do:[:aScreen |
-	    |v|
-
-	    aScreen ~~ self ifTrue:[
-		(v := aScreen viewFromId:id) notNil ifTrue:[
-		    ^ v
-		]
-	    ]
-	]
+        "/ search on other devices (if present).
+        "/ This may find the view, in case another device
+        "/ has its views on the same display screen
+        Screen allScreens do:[:aScreen |
+            |v|
+
+            aScreen ~~ self ifTrue:[
+                (v := aScreen viewFromId:id) notNil ifTrue:[
+                    ^ v
+                ]
+            ]
+        ]
     ].
     ^ view
 !
@@ -1370,13 +1370,13 @@
     "/ along with an illegal id (which happens, if a view from another
     "/ screen-device is picked ...)
     self class deviceErrorSignal handle:[:ex |
-	^ nil
+        ^ nil
     ] do:[
-	[searchId notNil] whileTrue:[
-	    id := self viewIdFromPoint:aPoint in:searchId.
-	    foundId := searchId.
-	    searchId := id
-	]
+        [searchId notNil] whileTrue:[
+            id := self viewIdFromPoint:aPoint in:searchId.
+            foundId := searchId.
+            searchId := id
+        ]
     ].
     ^ foundId
 !
@@ -1408,8 +1408,8 @@
     "return the number of valid bits in the blue component."
 
     bitsBlue isNil ifTrue:[
-	"/ not a truecolor display
-	^ bitsPerRGB
+        "/ not a truecolor display
+        ^ bitsPerRGB
     ].
     ^ bitsBlue
 
@@ -1425,8 +1425,8 @@
     "return the number of valid bits in the green component."
 
     bitsGreen isNil ifTrue:[
-	"/ not a truecolor display
-	^ bitsPerRGB
+        "/ not a truecolor display
+        ^ bitsPerRGB
     ].
     ^ bitsGreen
 
@@ -1459,8 +1459,8 @@
     "return the number of valid bits in the red component."
 
     bitsRed isNil ifTrue:[
-	"/ not a truecolor display
-	^ bitsPerRGB
+        "/ not a truecolor display
+        ^ bitsPerRGB
     ].
     ^ bitsRed
 
@@ -1653,9 +1653,9 @@
 
     visualType := aSymbol.
     (visualType == #StaticGray or:[visualType == #GrayScale]) ifTrue:[
-	hasColors := false
+        hasColors := false
     ] ifFalse:[
-	hasColors := true
+        hasColors := true
     ]
 !
 
@@ -1904,24 +1904,24 @@
     |sizes spec sz sz2|
 
     preferredIconSize isNil ifTrue:[
-	sizes := self iconSizes.
-	sizes notNil ifTrue:[
-	    spec := sizes first.
-
-	    "/ we prefer square icons ...
-
-	    sz := (spec at:#maxWidth) min: (spec at:#maxHeight).
-	    sz > 64 ifTrue:[
-		sz2 := (spec at:#minWidth) max: (spec at:#minHeight).
-		sz2 <= 48 ifTrue:[
-		    sz := 48
-		]
-	    ].
-	    preferredIconSize := sz @ sz
-	].
-	preferredIconSize isNil ifTrue:[
-	    preferredIconSize := 48@48
-	].
+        sizes := self iconSizes.
+        sizes notNil ifTrue:[
+            spec := sizes first.
+
+            "/ we prefer square icons ...
+
+            sz := (spec at:#maxWidth) min: (spec at:#maxHeight).
+            sz > 64 ifTrue:[
+                sz2 := (spec at:#minWidth) max: (spec at:#minHeight).
+                sz2 <= 48 ifTrue:[
+                    sz := 48
+                ]
+            ].
+            preferredIconSize := sz @ sz
+        ].
+        preferredIconSize isNil ifTrue:[
+            preferredIconSize := 48@48
+        ].
     ].
 
     ^ preferredIconSize
@@ -1966,9 +1966,9 @@
      supported, return nil."
 
     self supportedImageFormats do:[:fmt |
-	(fmt at:#depth) == aDepth ifTrue:[
-	    ^fmt
-	]
+        (fmt at:#depth) == aDepth ifTrue:[
+            ^fmt
+        ]
     ].
     ^ nil
 !
@@ -2240,8 +2240,8 @@
      - needed since some displays do not tell the truth or do not know it"
 
     aNumber > 0 ifTrue:[
-	heightMM := aNumber.
-	resolutionVer := nil.
+        heightMM := aNumber.
+        resolutionVer := nil.
     ]
 
     "Modified: 10.9.1996 / 14:25:39 / cg"
@@ -2257,7 +2257,7 @@
     "return the number of horizontal pixels per millimeter of the display"
 
     resolutionHor notNil ifTrue:[
-	^ resolutionHor
+        ^ resolutionHor
     ].
     resolutionHor := (width / widthMM) asFloat.
     ^ resolutionHor
@@ -2327,7 +2327,7 @@
     "return the number of vertical pixels per millimeter of the display"
 
     resolutionVer notNil ifTrue:[
-	^ resolutionVer
+        ^ resolutionVer
     ].
     resolutionVer := (height / heightMM) asFloat.
     ^ resolutionVer
@@ -2385,8 +2385,8 @@
      - needed since some displays do not tell the truth or do not know it"
 
     aNumber > 0 ifTrue:[
-	widthMM := aNumber.
-	resolutionHor := nil.
+        widthMM := aNumber.
+        resolutionHor := nil.
     ].
 
     "Modified: 10.9.1996 / 14:25:27 / cg"
@@ -2526,10 +2526,10 @@
 !
 
 createWindowFor:aView type:typeSymbol origin:org extent:ext 
-	minExtent:minE maxExtent:maxE borderWidth:bw subViewOf:sv 
-	style:styleSymbol inputOnly:inp 
-	label:label owner:owner 
-	icon:icn iconMask:icnM iconView:icnV
+        minExtent:minE maxExtent:maxE borderWidth:bw subViewOf:sv 
+        style:styleSymbol inputOnly:inp 
+        label:label owner:owner 
+        icon:icn iconMask:icnM iconView:icnV
     "must be implemented by a concrete class"
 
     ^ self subclassResponsibility
@@ -2615,13 +2615,13 @@
 
     s := IdentitySet new.
     fixColors notNil ifTrue:[
-	s addAll:fixColors.
+        s addAll:fixColors.
     ].
     fixGrayColors notNil ifTrue:[
-	s addAll:fixGrayColors.
+        s addAll:fixGrayColors.
     ].
     ditherColors notNil ifTrue:[
-	s addAll:ditherColors.
+        s addAll:ditherColors.
     ].
     ^ s asArray
 
@@ -2651,15 +2651,15 @@
      depthUsed mapArray|
 
     visualType == #DirectColor ifTrue:[
-	'DeviceWorkstation [info]: directColor displays not fully supported.' infoPrintCR.
-	^ nil
+        'DeviceWorkstation [info]: directColor displays not fully supported.' infoPrintCR.
+        ^ nil
     ].
         
     (visualType == #StaticGray or:[visualType == #TrueColor]) ifTrue:[
-	"
-	 those have no colorMap - we're done
-	"
-	^ nil
+        "
+         those have no colorMap - we're done
+        "
+        ^ nil
     ].
 
     "
@@ -2672,12 +2672,12 @@
     "/  than 8 bits ...)
 
     depthUsed == 15 ifTrue:[
-	depthUsed := 16
+        depthUsed := 16
     ].
     depthUsed > 16 ifTrue:[
-	"/ do not allocate zillions of colors ...
-	self error:'unreasonably large colorMap ...'.
-	^ nil
+        "/ do not allocate zillions of colors ...
+        self error:'unreasonably large colorMap ...'.
+        ^ nil
     ].
 
     mapSize := (1 bitShift:depthUsed).
@@ -2685,9 +2685,9 @@
     "/ get the palette
     mapArray := Array new:mapSize.
     1 to:mapSize do:[:i |
-	self getRGBFrom:(i-1) into:[:r :g :b |
-	    mapArray at:i put:(Color red:r green:g blue:b)
-	]
+        self getRGBFrom:(i-1) into:[:r :g :b |
+            mapArray at:i put:(Color red:r green:g blue:b)
+        ]
     ].
     ^ mapArray.
 
@@ -2704,7 +2704,7 @@
      Dont use this method, colornames are mostly X specific"
 
     ^ self getScaledRGBFromName:aString into:[:r :g :b |
-	self colorScaledRed:r scaledGreen:g scaledBlue:b
+        self colorScaledRed:r scaledGreen:g scaledBlue:b
       ]
 
 !
@@ -2723,9 +2723,9 @@
 
 colorScaledRed:red scaledGreen:green scaledBlue:blue
     visualType == #TrueColor ifTrue:[
-	^ (((red bitShift:-8) bitShift:redShift)
-	  bitOr:((green bitShift:-8) bitShift:greenShift))
-	  bitOr:((blue bitShift:-8) bitShift:blueShift)
+        ^ (((red bitShift:-8) bitShift:redShift)
+          bitOr:((green bitShift:-8) bitShift:greenShift))
+          bitOr:((blue bitShift:-8) bitShift:blueShift)
     ].
     self subclassResponsibility
 !
@@ -2774,7 +2774,7 @@
 
     triple := self getScaledRGBFrom:index.
     triple notNil ifTrue:[
-	^ triple collect:[:val | self deviceColorValueToPercent:val]
+        ^ triple collect:[:val | self deviceColorValueToPercent:val]
     ].
     ^ nil
 !
@@ -2787,7 +2787,7 @@
 
     triple := self getRGBFrom:index.
     triple notNil ifTrue:[
-	^ aBlock valueWithArguments:triple.
+        ^ aBlock valueWithArguments:triple.
     ].
     ^ nil
 
@@ -2803,57 +2803,57 @@
     |idx names triple r g b|
 
     (colorName startsWith:$#) ifTrue:[
-	"/ color in r/g/b hex notation
-	r := Integer readFrom:(colorName copyFrom:2 to:3) radix:16.
-	g := Integer readFrom:(colorName copyFrom:4 to:5) radix:16.
-	b := Integer readFrom:(colorName copyFrom:6 to:7) radix:16.
-	r := (r * 100 / 255).
-	g := (g * 100 / 255).
-	b := (b * 100 / 255).
-	^ Array with:r with:g with:b
+        "/ color in r/g/b hex notation
+        r := Integer readFrom:(colorName copyFrom:2 to:3) radix:16.
+        g := Integer readFrom:(colorName copyFrom:4 to:5) radix:16.
+        b := Integer readFrom:(colorName copyFrom:6 to:7) radix:16.
+        r := (r * 100 / 255).
+        g := (g * 100 / 255).
+        b := (b * 100 / 255).
+        ^ Array with:r with:g with:b
     ].
 
     names := #(
-		'red' 
-		'green' 
-		'blue' 
-		'yellow' 
-		'magenta' 
-		'cyan' 
-		'white' 
-		'black'
-
-		'olive'
-		'teal'
-		'silver'
-		'lime'
-		'fuchsia'
-		'aqua'
-	      ).
+                'red' 
+                'green' 
+                'blue' 
+                'yellow' 
+                'magenta' 
+                'cyan' 
+                'white' 
+                'black'
+
+                'olive'
+                'teal'
+                'silver'
+                'lime'
+                'fuchsia'
+                'aqua'
+              ).
     idx := names indexOf:colorName.
     idx == 0 ifTrue:[
-	idx := names indexOf:colorName asLowercase.
+        idx := names indexOf:colorName asLowercase.
     ].
     idx ~~ 0 ifTrue:[
-	triple := #(
-			(100   0   0)  "red"
-			(  0 100   0)  "green"
-			(  0   0 100)  "blue"
-			(100 100   0)  "yellow"
-			(100   0 100)  "magenta"
-			(  0 100 100)  "cyan"
-			(100 100 100)  "white"
-			(  0   0   0)  "black"
-
-			( 50  50   0)  "olive"
-			(  0  50  50)  "teal"
-			( 40  40  40)  "silver"
-			( 20 100   0)  "lime"
-			( 60   3 100)  "fuchsia"
-			( 10 100 100)  "aqua"
-		   ) at:idx.
+        triple := #(
+                        (100   0   0)  "red"
+                        (  0 100   0)  "green"
+                        (  0   0 100)  "blue"
+                        (100 100   0)  "yellow"
+                        (100   0 100)  "magenta"
+                        (  0 100 100)  "cyan"
+                        (100 100 100)  "white"
+                        (  0   0   0)  "black"
+
+                        ( 50  50   0)  "olive"
+                        (  0  50  50)  "teal"
+                        ( 40  40  40)  "silver"
+                        ( 20 100   0)  "lime"
+                        ( 60   3 100)  "fuchsia"
+                        ( 10 100 100)  "aqua"
+                   ) at:idx.
                         
-	^ triple
+        ^ triple
     ].
     ^ nil
 
@@ -2867,9 +2867,9 @@
 
     triple := self getScaledRGBFromName:colorName.
     triple notNil ifTrue:[
-	^ aBlock value:(self deviceColorValueToPercent:(triple at:1))
-		 value:(self deviceColorValueToPercent:(triple at:2))
-		 value:(self deviceColorValueToPercent:(triple at:3))
+        ^ aBlock value:(self deviceColorValueToPercent:(triple at:1))
+                 value:(self deviceColorValueToPercent:(triple at:2))
+                 value:(self deviceColorValueToPercent:(triple at:3))
     ].
     ^ nil
 
@@ -2893,7 +2893,7 @@
 
     triple := self getScaledRGBFrom:index.
     triple notNil ifTrue:[
-	^ aBlock valueWithArguments:triple.
+        ^ aBlock valueWithArguments:triple.
     ].
     ^ nil
 
@@ -2907,7 +2907,7 @@
 
     triple := self getRGBFromName:colorName.
     triple notNil ifTrue:[
-	^ triple collect:[:val | self percentToDeviceColorValue:val].
+        ^ triple collect:[:val | self percentToDeviceColorValue:val].
     ].
     ^ nil.
 
@@ -2921,7 +2921,7 @@
 
     triple := self getScaledRGBFromName:colorName.
     triple notNil ifTrue:[
-	^ aBlock valueWithArguments:triple.
+        ^ aBlock valueWithArguments:triple.
     ].
     ^ nil
 !
@@ -3153,7 +3153,7 @@
 !
 
 displayArcX:x y:y width:width height:height from:startAngle angle:angle
-	     in:aDrawableId with:aGCId
+             in:aDrawableId with:aGCId
     "draw an arc"
 
     ^ self subclassResponsibility
@@ -3183,11 +3183,11 @@
     xLast := xStart.
     yLast := (ydata at:1) * yScale + yTrans.
     ydata from:2 do:[:y | |yT|
-	x := xLast + xStep.
-	yT := y * yScale + yTrans.
-	self displayLineFromX:xLast rounded y:yLast rounded toX:x rounded y:yT rounded in:drawableId with:gcId.
-	xLast := x.
-	yLast := y.
+        x := xLast + xStep.
+        yT := y * yScale + yTrans.
+        self displayLineFromX:xLast rounded y:yLast rounded toX:x rounded y:yT rounded in:drawableId with:gcId.
+        xLast := x.
+        yLast := y.
     ]
 !
 
@@ -3196,13 +3196,13 @@
      If the coordinates are not integers, retry with rounded." 
 
     self displayString:aString 
-	 from:index1
-	 to:index2
-	 x:x 
-	 y:y 
-	 in:aDrawableId 
-	 with:aGCId 
-	 opaque:true
+         from:index1
+         to:index2
+         x:x 
+         y:y 
+         in:aDrawableId 
+         with:aGCId 
+         opaque:true
 !
 
 displayOpaqueString:aString x:x y:y in:aDrawableId with:aGCId
@@ -3210,11 +3210,11 @@
      If the coordinates are not integers, retry with rounded." 
 
     self displayString:aString 
-	 x:x 
-	 y:y 
-	 in:aDrawableId 
-	 with:aGCId 
-	 opaque:true
+         x:x 
+         y:y 
+         in:aDrawableId 
+         with:aGCId 
+         opaque:true
 !
 
 displayPointX:x y:y in:aDrawableId with:aGCId
@@ -3245,18 +3245,18 @@
     |startPoint p|
 
     1 to:arrayOfPoints size by:2 do:[:idx |
-	p := arrayOfPoints at:idx.
-	idx odd ifTrue:[
-	    startPoint := p
-	] ifFalse:[  
-	    self 
-		displayLineFromX:startPoint x
-		y:startPoint y
-		toX:p x
-		y:p y
-		in:aDrawableId
-		with:aGCId
-	]
+        p := arrayOfPoints at:idx.
+        idx odd ifTrue:[
+            startPoint := p
+        ] ifFalse:[  
+            self 
+                displayLineFromX:startPoint x
+                y:startPoint y
+                toX:p x
+                y:p y
+                in:aDrawableId
+                with:aGCId
+        ]
     ]
 !
 
@@ -3275,14 +3275,14 @@
      If the coordinates are not integers, retry with rounded." 
 
     self 
-	displayString:aString 
-	from:index1
-	to:index2
-	x:x 
-	y:y 
-	in:aDrawableId 
-	with:aGCId 
-	opaque:false
+        displayString:aString 
+        from:index1
+        to:index2
+        x:x 
+        y:y 
+        in:aDrawableId 
+        with:aGCId 
+        opaque:false
 !
 
 displayString:aString from:i1 to:i2 x:x y:y in:aDrawableId with:aGCId opaque:opaque
@@ -3296,34 +3296,34 @@
      If the coordinates are not integers, retry with rounded." 
 
     self 
-	displayString:aString 
-	x:x 
-	y:y 
-	in:aDrawableId 
-	with:aGCId 
-	opaque:false
+        displayString:aString 
+        x:x 
+        y:y 
+        in:aDrawableId 
+        with:aGCId 
+        opaque:false
 !
 
 displayString:aString x:x y:y in:aDrawableId with:aGCId opaque:opaque
     "draw a string"
 
     self displayString:aString
-		  from:1
-		    to:aString size
-		     x:x 
-		     y:y 
-		     in:aDrawableId 
-		     with:aGCId
-		     opaque:opaque
+                  from:1
+                    to:aString size
+                     x:x 
+                     y:y 
+                     in:aDrawableId 
+                     with:aGCId
+                     opaque:opaque
 !
 
 drawBits:imageBits bitsPerPixel:bitsPerPixel depth:imageDepth padding:pad
-			  width:imageWidth height:imageHeight 
-			      x:srcx y:srcy
-			   into:aDrawableId 
-			      x:dstx y:dsty 
-			  width:w height:h 
-			   with:aGCId
+                          width:imageWidth height:imageHeight 
+                              x:srcx y:srcy
+                           into:aDrawableId 
+                              x:dstx y:dsty 
+                          width:w height:h 
+                           with:aGCId
     "draw a bitimage which has depth id, width iw and height ih into
      the drawable. draw a region of w/h pixels from srcx/srcy to dstx/dsty.
      It has to be checked elsewhere, that server can do it with the given
@@ -3336,12 +3336,12 @@
 !
 
 drawBits:imageBits bitsPerPixel:bitsPerPixel depth:imageDepth 
-			  width:imageWidth height:imageHeight 
-			      x:srcx y:srcy
-			   into:aDrawableId 
-			      x:dstx y:dsty 
-			  width:w height:h 
-			   with:aGCId
+                          width:imageWidth height:imageHeight 
+                              x:srcx y:srcy
+                           into:aDrawableId 
+                              x:dstx y:dsty 
+                          width:w height:h 
+                           with:aGCId
 
     "draw a bitimage which has depth id, width iw and height ih into
      the drawable. draw a region of w/h pixels from srcx/srcy to dstx/dsty.
@@ -3354,23 +3354,23 @@
      which is the natural padding within ST/X."
 
     ^ self
-	drawBits:imageBits
-	bitsPerPixel:bitsPerPixel
-	depth:imageDepth
-	padding:8
-	width:imageWidth height:imageHeight
-	x:srcx y:srcy
-	into:aDrawableId
-	x:dstx y:dsty 
-	width:w height:h 
-	with:aGCId
+        drawBits:imageBits
+        bitsPerPixel:bitsPerPixel
+        depth:imageDepth
+        padding:8
+        width:imageWidth height:imageHeight
+        x:srcx y:srcy
+        into:aDrawableId
+        x:dstx y:dsty 
+        width:w height:h 
+        with:aGCId
 
     "Created: / 16.4.1997 / 14:55:57 / cg"
     "Modified: / 21.1.1998 / 13:27:58 / cg"
 !
 
 drawBits:imageBits depth:imageDepth padding:pad width:imageWidth height:imageHeight
-	x:srcx y:srcy into:aDrawableId x:dstx y:dsty width:w height:h with:aGCId
+        x:srcx y:srcy into:aDrawableId x:dstx y:dsty width:w height:h with:aGCId
 
     "draw a bitimage which has depth id, width iw and height ih into
      the drawable. draw a region of w/h pixels from srcx/srcy to dstx/dsty.
@@ -3378,21 +3378,21 @@
      depth; also it is assumed, that the colormap is setup correctly"
 
     ^ self 
-	drawBits:imageBits 
-	bitsPerPixel:imageDepth 
-	depth:imageDepth 
-	padding:pad
-	width:imageWidth height:imageHeight 
-	x:srcx y:srcy
-	into:aDrawableId 
-	x:dstx y:dsty 
-	width:w height:h 
-	with:aGCId
+        drawBits:imageBits 
+        bitsPerPixel:imageDepth 
+        depth:imageDepth 
+        padding:pad
+        width:imageWidth height:imageHeight 
+        x:srcx y:srcy
+        into:aDrawableId 
+        x:dstx y:dsty 
+        width:w height:h 
+        with:aGCId
 !
 
 drawBits:imageBits depth:imageDepth width:imageWidth height:imageHeight
-		       x:srcx y:srcy
-		    into:aDrawableId x:dstx y:dsty width:w height:h with:aGCId
+                       x:srcx y:srcy
+                    into:aDrawableId x:dstx y:dsty width:w height:h with:aGCId
 
     "draw a bitimage which has depth id, width iw and height ih into
      the drawable. draw a region of w/h pixels from srcx/srcy to dstx/dsty.
@@ -3402,21 +3402,21 @@
      which is the natural padding within ST/X."
 
     ^ self 
-	drawBits:imageBits 
-	bitsPerPixel:imageDepth 
-	depth:imageDepth 
-	width:imageWidth height:imageHeight 
-	x:srcx y:srcy
-	into:aDrawableId 
-	x:dstx y:dsty 
-	width:w height:h 
-	with:aGCId
+        drawBits:imageBits 
+        bitsPerPixel:imageDepth 
+        depth:imageDepth 
+        width:imageWidth height:imageHeight 
+        x:srcx y:srcy
+        into:aDrawableId 
+        x:dstx y:dsty 
+        width:w height:h 
+        with:aGCId
 
     "Modified: / 21.1.1998 / 13:28:34 / cg"
 !
 
 fillArcX:x y:y width:width height:height from:startAngle angle:angle
-	       in:aDrawableId with:aGCId
+               in:aDrawableId with:aGCId
     "fill an arc"
 
     ^ self subclassResponsibility
@@ -3453,7 +3453,7 @@
     setOfViews := IdentitySet new.
 
     knownViews notNil ifTrue:[
-	knownViews validElementsDo:[:v | setOfViews add:v].
+        knownViews validElementsDo:[:v | setOfViews add:v].
     ].
     ^ setOfViews
 
@@ -3474,7 +3474,7 @@
 "/      ]
         
     knownViews notNil ifTrue:[
-	knownViews validElementsDo:aBlock
+        knownViews validElementsDo:aBlock
     ]
 
     "
@@ -3497,8 +3497,8 @@
 
 primitiveFailedOrClosedConnection
     self isOpen ifFalse:[
-	DrawingOnClosedDeviceSignal raiseRequestWith:self.
-	^ nil
+        DrawingOnClosedDeviceSignal raiseRequestWith:self.
+        ^ nil
     ].
     ^ super primitiveFailed
 ! !
@@ -3511,25 +3511,25 @@
     |sensor|
 
     aView isNil ifTrue:[
-	"/ event arrived, after I destroyed it myself
-	^ self
+        "/ event arrived, after I destroyed it myself
+        ^ self
     ].
     (sensor := aView sensor) notNil ifTrue:[
-	sensor buttonMotion:button x:x y:y view:aView
+        sensor buttonMotion:button x:x y:y view:aView
     ] ifFalse:[
-	aView shown ifTrue:[ "/ could be a late event arrival
-	    "
-	     if there is no sensor ...
-	    "
-	    aView
-		dispatchEvent:#buttonMotion:x:y:
-		arguments:(Array with:button with:x with:y)
+        aView shown ifTrue:[ "/ could be a late event arrival
+            "
+             if there is no sensor ...
+            "
+            aView
+                dispatchEvent:#buttonMotion:x:y:
+                arguments:(Array with:button with:x with:y)
 
 "/            WindowEvent
 "/                sendEvent:#buttonMotion:x:y:
 "/                arguments:(Array with:button with:x with:y)
 "/                view:aView
-	]
+        ]
     ]
 
     "Modified: / 20.5.1998 / 22:50:32 / cg"
@@ -3541,25 +3541,25 @@
     |sensor|
 
     aView isNil ifTrue:[
-	"/ event arrived, after I destroyed it myself
-	^ self
+        "/ event arrived, after I destroyed it myself
+        ^ self
     ].
     (sensor := aView sensor) notNil ifTrue:[
-	sensor buttonMultiPress:button x:x y:y view:aView
+        sensor buttonMultiPress:button x:x y:y view:aView
     ] ifFalse:[
-	aView shown ifTrue:[ "/ could be a late event arrival
-	    "
-	     if there is no sensor ...
-	    "
-	    aView
-		dispatchEvent:#buttonMultiPress:x:y:
-		arguments:(Array with:button with:x with:y)
+        aView shown ifTrue:[ "/ could be a late event arrival
+            "
+             if there is no sensor ...
+            "
+            aView
+                dispatchEvent:#buttonMultiPress:x:y:
+                arguments:(Array with:button with:x with:y)
 
 "/            WindowEvent
 "/                sendEvent:#buttonMultiPress:x:y:
 "/                arguments:(Array with:button with:x with:y)
 "/                view:aView
-	]
+        ]
     ]
 
     "Modified: / 20.5.1998 / 22:50:49 / cg"
@@ -3571,32 +3571,32 @@
     |sensor|
 
     aView isNil ifTrue:[
-	"/ event arrived, after I destroyed it myself
-	^ self
+        "/ event arrived, after I destroyed it myself
+        ^ self
     ].
     (sensor := aView sensor) notNil ifTrue:[
-	WindowsRightButtonBehavior == true ifTrue:[
-	    button >= 2 ifTrue:[
-		sensor buttonPress:1 x:x y:y view:aView.
-		^ self.
-	    ]
-	].
-
-	sensor buttonPress:button x:x y:y view:aView
+        WindowsRightButtonBehavior == true ifTrue:[
+            button >= 2 ifTrue:[
+                sensor buttonPress:1 x:x y:y view:aView.
+                ^ self.
+            ]
+        ].
+
+        sensor buttonPress:button x:x y:y view:aView
     ] ifFalse:[
-	aView shown ifTrue:[ "/ could be a late event arrival
-	    "
-	     if there is no sensor ...
-	    "
-	    aView
-		dispatchEvent:#buttonPress:x:y:
-		arguments:(Array with:button with:x with:y)
+        aView shown ifTrue:[ "/ could be a late event arrival
+            "
+             if there is no sensor ...
+            "
+            aView
+                dispatchEvent:#buttonPress:x:y:
+                arguments:(Array with:button with:x with:y)
 
 "/            WindowEvent
 "/                sendEvent:#buttonPress:x:y:
 "/                arguments:(Array with:button with:x with:y)
 "/                view:aView
-	]
+        ]
     ]
 
     "Modified: / 20.5.1998 / 22:51:02 / cg"
@@ -3608,33 +3608,33 @@
     |sensor|
 
     aView isNil ifTrue:[
-	"/ event arrived, after I destroyed it myself
-	^ self
+        "/ event arrived, after I destroyed it myself
+        ^ self
     ].
     (sensor := aView sensor) notNil ifTrue:[
-	WindowsRightButtonBehavior == true ifTrue:[
-	    button >= 2 ifTrue:[
-		sensor buttonRelease:1 x:x y:y view:aView.
-		sensor buttonPress:button x:x y:y view:aView.
-		sensor buttonRelease:button x:x y:y view:aView.
-		^ self.
-	    ].
-	].
-	sensor buttonRelease:button x:x y:y view:aView
+        WindowsRightButtonBehavior == true ifTrue:[
+            button >= 2 ifTrue:[
+                sensor buttonRelease:1 x:x y:y view:aView.
+                sensor buttonPress:button x:x y:y view:aView.
+                sensor buttonRelease:button x:x y:y view:aView.
+                ^ self.
+            ].
+        ].
+        sensor buttonRelease:button x:x y:y view:aView
     ] ifFalse:[
-	aView shown ifTrue:[ "/ could be a late event arrival
-	    "
-	     if there is no sensor ...
-	    "
-	    aView
-		dispatchEvent:#buttonRelease:x:y:
-		arguments:(Array with:button with:x with:y)
+        aView shown ifTrue:[ "/ could be a late event arrival
+            "
+             if there is no sensor ...
+            "
+            aView
+                dispatchEvent:#buttonRelease:x:y:
+                arguments:(Array with:button with:x with:y)
 
 "/            WindowEvent
 "/                sendEvent:#buttonRelease:x:y:
 "/                arguments:(Array with:button with:x with:y)
 "/                view:aView
-	]
+        ]
     ]
 
     "Modified: / 20.5.1998 / 22:51:13 / cg"
@@ -3646,16 +3646,16 @@
     |sensor|
 
     aView isNil ifTrue:[
-	"/ event arrived, after I destroyed it myself
-	^ self
+        "/ event arrived, after I destroyed it myself
+        ^ self
     ].
     (sensor := aView sensor) notNil ifTrue:[
-	sensor configureX:x y:y width:w height:h view:aView
+        sensor configureX:x y:y width:w height:h view:aView
     ] ifFalse:[
-	"
-	 if there is no sensor ...
-	"
-	aView configureX:x y:y width:w height:h 
+        "
+         if there is no sensor ...
+        "
+        aView configureX:x y:y width:w height:h 
     ]
 !
 
@@ -3663,8 +3663,8 @@
     "forward a covered for some view"
 
     aView isNil ifTrue:[
-	"/ event arrived, after I destroyed it myself
-	^ self
+        "/ event arrived, after I destroyed it myself
+        ^ self
     ].
 "/    |sensor|
 "/
@@ -3674,7 +3674,7 @@
 "/        "
 "/         if there is no sensor ...
 "/        "
-	aView coveredBy:otherView 
+        aView coveredBy:otherView 
 "/    ]
 
     "Modified: / 8.2.1999 / 15:24:52 / cg"
@@ -3686,16 +3686,16 @@
     |sensor|
 
     aView isNil ifTrue:[
-	"/ event arrived, after I destroyed it myself
-	^ self
+        "/ event arrived, after I destroyed it myself
+        ^ self
     ].
     (sensor := aView sensor) notNil ifTrue:[
-	sensor destroyedView:aView
+        sensor destroyedView:aView
     ] ifFalse:[
-	"
-	 if there is no sensor ...
-	"
-	aView destroyed
+        "
+         if there is no sensor ...
+        "
+        aView destroyed
     ]
 !
 
@@ -3705,18 +3705,18 @@
     |sensor|
 
     aView isNil ifTrue:[
-	"/ event arrived, after I destroyed it myself
-	^ self
+        "/ event arrived, after I destroyed it myself
+        ^ self
     ].
     (sensor := aView sensor) notNil ifTrue:[
-	sensor exposeX:x y:y width:w height:h view:aView
+        sensor exposeX:x y:y width:w height:h view:aView
     ] ifFalse:[
-	"
-	 if there is no sensor ...
-	"
-	aView
-	    dispatchEvent:#exposeX:y:width:height:
-	    arguments:(Array with:x with:y with:w with:h)
+        "
+         if there is no sensor ...
+        "
+        aView
+            dispatchEvent:#exposeX:y:width:height:
+            arguments:(Array with:x with:y with:w with:h)
 
 "/        WindowEvent
 "/            sendEvent:#exposeX:y:width:height:
@@ -3733,18 +3733,18 @@
     |sensor|
 
     aView isNil ifTrue:[
-	"/ event arrived, after I destroyed it myself
-	^ self
+        "/ event arrived, after I destroyed it myself
+        ^ self
     ].
     (sensor := aView sensor) notNil ifTrue:[
-	sensor focusInView:aView
+        sensor focusInView:aView
     ] ifFalse:[
-	"
-	 if there is no sensor ...
-	"
-	aView
-	    dispatchEvent:#focusIn
-	    arguments:nil
+        "
+         if there is no sensor ...
+        "
+        aView
+            dispatchEvent:#focusIn
+            arguments:nil
 
 "/        WindowEvent
 "/            sendEvent:#focusIn
@@ -3761,18 +3761,18 @@
     |sensor|
 
     aView isNil ifTrue:[
-	"/ event arrived, after I destroyed it myself
-	^ self
+        "/ event arrived, after I destroyed it myself
+        ^ self
     ].
     (sensor := aView sensor) notNil ifTrue:[
-	sensor focusOutView:aView
+        sensor focusOutView:aView
     ] ifFalse:[
-	"
-	 if there is no sensor ...
-	"
-	aView
-	    dispatchEvent:#focusOut
-	    arguments:nil
+        "
+         if there is no sensor ...
+        "
+        aView
+            dispatchEvent:#focusOut
+            arguments:nil
 
 "/        WindowEvent
 "/            sendEvent:#focusOut
@@ -3789,18 +3789,18 @@
     |sensor|
 
     aView isNil ifTrue:[
-	"/ event arrived, after I destroyed it myself
-	^ self
+        "/ event arrived, after I destroyed it myself
+        ^ self
     ].
     (sensor := aView sensor) notNil ifTrue:[
-	sensor graphicsExposeX:x y:y width:w height:h final:final view:aView
+        sensor graphicsExposeX:x y:y width:w height:h final:final view:aView
     ] ifFalse:[
-	"
-	 if there is no sensor ...
-	"
-	aView
-	    dispatchEvent:#graphicsExposeX:y:width:height:final:
-	    arguments:(Array with:x with:y with:w with:h with:final)
+        "
+         if there is no sensor ...
+        "
+        aView
+            dispatchEvent:#graphicsExposeX:y:width:height:final:
+            arguments:(Array with:x with:y with:w with:h with:final)
 
 "/        WindowEvent
 "/            sendEvent:#graphicsExposeX:y:width:height:final:
@@ -3822,37 +3822,37 @@
     "/ ctrl-Esc gives up focus
     "/
     untranslatedKey == #Escape ifTrue:[
-	ctrlDown ifTrue:[
-	    self ungrabPointer.
-	    self setInputFocusTo:nil 
-	]
+        ctrlDown ifTrue:[
+            self ungrabPointer.
+            self setInputFocusTo:nil 
+        ]
     ].
 
     self modifierKeyProcessing:untranslatedKey down:true.
 
     aView isNil ifTrue:[
-	"/ event arrived, after I destroyed it myself
-	^ self
+        "/ event arrived, after I destroyed it myself
+        ^ self
     ].
     (sensor := aView sensor) notNil ifTrue:[
-	sensor keyPress:untranslatedKey x:x y:y view:aView
+        sensor keyPress:untranslatedKey x:x y:y view:aView
     ] ifFalse:[
-	aView shown ifTrue:[ "/ could be a late event arrival
-	    "
-	     if there is no sensor ...
-	    "
-	    xlatedKey := self translateKey:untranslatedKey forView:aView.
-	    xlatedKey notNil ifTrue:[
-		aView
-		    dispatchEvent:#keyPress:x:y:
-		    arguments:(Array with:xlatedKey with:x with:y)
+        aView shown ifTrue:[ "/ could be a late event arrival
+            "
+             if there is no sensor ...
+            "
+            xlatedKey := self translateKey:untranslatedKey forView:aView.
+            xlatedKey notNil ifTrue:[
+                aView
+                    dispatchEvent:#keyPress:x:y:
+                    arguments:(Array with:xlatedKey with:x with:y)
 
 "/                WindowEvent
 "/                  sendEvent:#keyPress:x:y:
 "/                  arguments:(Array with:xlatedKey with:x with:y)
 "/                  view:aView
-	    ]
-	]
+            ]
+        ]
     ]
 
     "Modified: / 20.5.1998 / 22:52:36 / cg"
@@ -3866,28 +3866,28 @@
     self modifierKeyProcessing:untranslatedKey down:false.
 
     aView isNil ifTrue:[
-	"/ event arrived, after I destroyed it myself
-	^ self
+        "/ event arrived, after I destroyed it myself
+        ^ self
     ].
     (sensor := aView sensor) notNil ifTrue:[
-	sensor keyRelease:untranslatedKey x:x y:y view:aView
+        sensor keyRelease:untranslatedKey x:x y:y view:aView
     ] ifFalse:[
-	aView shown ifTrue:[ "/ could be a late event arrival
-	    "
-	     if there is no sensor ...
-	    "
-	    xlatedKey := self translateKey:untranslatedKey forView:aView.
-	    xlatedKey notNil ifTrue:[
-		aView
-		    dispatchEvent:#keyRelease:x:y:
-		    arguments:(Array with:xlatedKey with:x with:y)
+        aView shown ifTrue:[ "/ could be a late event arrival
+            "
+             if there is no sensor ...
+            "
+            xlatedKey := self translateKey:untranslatedKey forView:aView.
+            xlatedKey notNil ifTrue:[
+                aView
+                    dispatchEvent:#keyRelease:x:y:
+                    arguments:(Array with:xlatedKey with:x with:y)
 
 "/                WindowEvent
 "/                    sendEvent:#keyRelease:x:y:
 "/                    arguments:(Array with:xlatedKey with:x with:y)
 "/                    view:aView
-	    ]
-	]
+            ]
+        ]
     ]
 
     "Modified: / 20.5.1998 / 22:52:52 / cg"
@@ -3899,16 +3899,16 @@
     |sensor|
 
     aView isNil ifTrue:[
-	"/ event arrived, after I destroyed it myself
-	^ self
+        "/ event arrived, after I destroyed it myself
+        ^ self
     ].
     (sensor := aView sensor) notNil ifTrue:[
-	sensor mappedView:aView
+        sensor mappedView:aView
     ] ifFalse:[
-	"
-	 if there is no sensor ...
-	"
-	aView mapped
+        "
+         if there is no sensor ...
+        "
+        aView mapped
     ]
 !
 
@@ -3919,20 +3919,20 @@
     |sensor|
 
     aView isNil ifTrue:[
-	"/ event arrived, after I destroyed it myself
-	^ self
+        "/ event arrived, after I destroyed it myself
+        ^ self
     ].
     (sensor := aView sensor) notNil ifTrue:[
-	sensor mouseWheelMotion:buttonState x:x y:y amount:amount deltaTime:dTime view:aView
+        sensor mouseWheelMotion:buttonState x:x y:y amount:amount deltaTime:dTime view:aView
     ] ifFalse:[
-	aView shown ifTrue:[ "/ could be a late event arrival
-	    "
-	     if there is no sensor ...
-	    "
-	    aView
-		dispatchEvent:#mouseWheelMotion:x:y:amount:deltaTime:
-		arguments:(Array with:buttonState with:x with:y with:amount with:dTime )
-	]
+        aView shown ifTrue:[ "/ could be a late event arrival
+            "
+             if there is no sensor ...
+            "
+            aView
+                dispatchEvent:#mouseWheelMotion:x:y:amount:deltaTime:
+                arguments:(Array with:buttonState with:x with:y with:amount with:dTime )
+        ]
     ]
 
     "Modified: / 21.5.1999 / 13:05:53 / cg"
@@ -3944,16 +3944,16 @@
     |sensor|
 
     aView isNil ifTrue:[
-	"/ event arrived, after I destroyed it myself
-	^ self
+        "/ event arrived, after I destroyed it myself
+        ^ self
     ].
     (sensor := aView sensor) notNil ifTrue:[
-	sensor noExposeView:aView
+        sensor noExposeView:aView
     ] ifFalse:[
-	"
-	 if there is no sensor ...
-	"
-	aView noExpose 
+        "
+         if there is no sensor ...
+        "
+        aView noExpose 
     ]
 !
 
@@ -3963,18 +3963,18 @@
     |sensor|
 
     aView isNil ifTrue:[
-	"/ event arrived, after I destroyed it myself
-	^ self
+        "/ event arrived, after I destroyed it myself
+        ^ self
     ].
     (sensor := aView sensor) notNil ifTrue:[
-	sensor pointerEnter:buttonState x:x y:y view:aView
+        sensor pointerEnter:buttonState x:x y:y view:aView
     ] ifFalse:[
-	"
-	 if there is no sensor ...
-	"
-	aView
-	    dispatchEvent:#pointerEnter:x:y:
-	    arguments:(Array with:buttonState with:x with:y)
+        "
+         if there is no sensor ...
+        "
+        aView
+            dispatchEvent:#pointerEnter:x:y:
+            arguments:(Array with:buttonState with:x with:y)
 
 "/        WindowEvent
 "/            sendEvent:#pointerEnter:x:y:
@@ -3991,18 +3991,18 @@
     |sensor|
 
     aView isNil ifTrue:[
-	"/ event arrived, after I destroyed it myself
-	^ self
+        "/ event arrived, after I destroyed it myself
+        ^ self
     ].
     (sensor := aView sensor) notNil ifTrue:[
-	sensor pointerLeave:buttonState view:aView
+        sensor pointerLeave:buttonState view:aView
     ] ifFalse:[
-	"
-	 if there is no sensor ...
-	"
-	aView
-	    dispatchEvent:#pointerLeave:
-	    arguments:(Array with:buttonState)
+        "
+         if there is no sensor ...
+        "
+        aView
+            dispatchEvent:#pointerLeave:
+            arguments:(Array with:buttonState)
 
 "/        WindowEvent
 "/            sendEvent:#pointerLeave:
@@ -4019,16 +4019,16 @@
     |sensor|
 
     aView isNil ifTrue:[
-	"/ event arrived, after I destroyed it myself
-	^ self
+        "/ event arrived, after I destroyed it myself
+        ^ self
     ].
     (sensor := aView sensor) notNil ifTrue:[
-	sensor saveAndTerminateView:aView
+        sensor saveAndTerminateView:aView
     ] ifFalse:[
-	"
-	 if there is no sensor ...
-	"
-	aView saveAndTerminate
+        "
+         if there is no sensor ...
+        "
+        aView saveAndTerminate
     ]
 !
 
@@ -4038,16 +4038,16 @@
     |sensor|
 
     aView isNil ifTrue:[
-	"/ event arrived, after I destroyed it myself
-	^ self
+        "/ event arrived, after I destroyed it myself
+        ^ self
     ].
     (sensor := aView sensor) notNil ifTrue:[
-	sensor terminateView:aView
+        sensor terminateView:aView
     ] ifFalse:[
-	"
-	 if there is no sensor ...
-	"
-	aView terminate
+        "
+         if there is no sensor ...
+        "
+        aView terminate
     ]
 !
 
@@ -4057,16 +4057,16 @@
     |sensor|
 
     aView isNil ifTrue:[
-	"/ event arrived, after I destroyed it myself
-	^ self
+        "/ event arrived, after I destroyed it myself
+        ^ self
     ].
     (sensor := aView sensor) notNil ifTrue:[
-	sensor unmappedView:aView
+        sensor unmappedView:aView
     ] ifFalse:[
-	"
-	 if there is no sensor ...
-	"
-	aView unmapped
+        "
+         if there is no sensor ...
+        "
+        aView unmapped
     ]
 ! !
 
@@ -4081,27 +4081,27 @@
     dispatching ifFalse:[^ self].
 
     self == Display ifTrue:[
-	ExitOnLastClose == true ifFalse:[^ self].
+        ExitOnLastClose == true ifFalse:[^ self].
     ].
     exitOnLastClose == true ifFalse:[^ self].
 
     knownViews notNil ifTrue:[
-	(knownViews findFirst:[:slot | 
-		slot notNil 
-		and:[slot ~~ 0             "/ if there is no non-popup
-		and:[slot isRootView not   "/ non-dialog ...
-		and:[slot isTopView        "/ stop dispatching.
-		and:[slot isPopUpView not
-		and:[slot isModal not
-		"and:[slot realized]"]]]]]]) == 0 ifTrue:[
-	    "/ my last view was closed
-	    dispatching := false.
-	    'DeviceWorkstation [info]: finished dispatch (last view closed)' infoPrintCR.
-	    LastActiveScreen == self ifTrue:[
-		LastActiveScreen := nil.
-		LastActiveProcess := nil.
-	    ].
-	]
+        (knownViews findFirst:[:slot | 
+                slot notNil 
+                and:[slot ~~ 0             "/ if there is no non-popup
+                and:[slot isRootView not   "/ non-dialog ...
+                and:[slot isTopView        "/ stop dispatching.
+                and:[slot isPopUpView not
+                and:[slot isModal not
+                "and:[slot realized]"]]]]]]) == 0 ifTrue:[
+            "/ my last view was closed
+            dispatching := false.
+            'DeviceWorkstation [info]: finished dispatch (last view closed)' infoPrintCR.
+            LastActiveScreen == self ifTrue:[
+                LastActiveScreen := nil.
+                LastActiveProcess := nil.
+            ].
+        ]
     ].
 
     "Modified: 19.9.1995 / 11:31:54 / claus"
@@ -4144,17 +4144,17 @@
     "
     myFd := self displayFileDescriptor.
     [aBlock value] whileTrue:[
-	self eventPending ifFalse:[
-	    myFd isNil ifTrue:[
-		OperatingSystem millisecondDelay:50
-	    ] ifFalse:[
-		OperatingSystem selectOn:myFd withTimeOut:50.
-	    ].
-	    Processor evaluateTimeouts.
-	].
-	self eventPending ifTrue:[
-	    self dispatchEvent
-	].
+        self eventPending ifFalse:[
+            myFd isNil ifTrue:[
+                OperatingSystem millisecondDelay:50
+            ] ifFalse:[
+                OperatingSystem selectOn:myFd withTimeOut:50.
+            ].
+            Processor evaluateTimeouts.
+        ].
+        self eventPending ifTrue:[
+            self dispatchEvent
+        ].
     ]
 !
 
@@ -4164,11 +4164,11 @@
      (i.e. when in the modal debugger)"
 
     Object osSignalInterruptSignal handle:[:ex |
-	ex return
+        ex return
     ] do:[
-	[self eventPending] whileTrue:[
-	    self dispatchEventFor:nil withMask:nil
-	]
+        [self eventPending] whileTrue:[
+            self dispatchEventFor:nil withMask:nil
+        ]
     ]
 !
 
@@ -4187,7 +4187,7 @@
     "dispose (i.e. forget) all events pending on this display"
 
     [self eventPending] whileTrue:[
-	self getEventFor:nil withMask:nil
+        self getEventFor:nil withMask:nil
     ].
 !
 
@@ -4270,7 +4270,7 @@
     dispatching := true.
 
     AllScreens isNil ifTrue:[
-	AllScreens := IdentitySet new:1
+        AllScreens := IdentitySet new:1
     ].
     AllScreens add:self.
 
@@ -4286,56 +4286,56 @@
     inputSema := Semaphore new name:'display inputSema'.
 
     p := [
-	self initializeDeviceResources.
-
-	DeviceIOErrorSignal handle:[:ex |
-	    "/ test for handlerBlock until the signal is changed to be classed based.
-	    ex signal handlerBlock notNil ifTrue:[
-		ex defaultAction.
-	    ] ifFalse:[
-		'DeviceWorkstation [warning]: stop dispatch due to I/O error' errorPrintCR.
-		self brokenConnection.
-	    ].
-	    ex return.
-	] do:[
-	    [
-		[dispatching] whileTrue:[
-		    AbortSignal handle:[:ex |
-			ex return
-		    ] do:[
-			self eventPending ifFalse:[
-			    Processor activeProcess setStateTo:#ioWait if:#active.
-			    inputSema wait.
-			].
-			dispatching ifTrue:[
-			    self dispatchPendingEvents.
-			].
-		    ]
-		]
-	    ] valueOnUnwindDo:[
-		inputSema notNil ifTrue:[
-		    Processor disableSemaphore:inputSema.
-		    inputSema := nil.
-		].
-		dispatchProcess := nil.
-		self emergencyCloseConnection.
-	    ].
-	    inputSema notNil ifTrue:[
-		Processor disableSemaphore:inputSema.
-		inputSema := nil.
-	    ].
-	    dispatchProcess := nil.
-	    self close.
-	].
+        self initializeDeviceResources.
+
+        DeviceIOErrorSignal handle:[:ex |
+            "/ test for handlerBlock until the signal is changed to be classed based.
+            ex signal handlerBlock notNil ifTrue:[
+                ex defaultAction.
+            ] ifFalse:[
+                'DeviceWorkstation [warning]: stop dispatch due to I/O error' errorPrintCR.
+                self brokenConnection.
+            ].
+            ex return.
+        ] do:[
+            [
+                [dispatching] whileTrue:[
+                    AbortSignal handle:[:ex |
+                        ex return
+                    ] do:[
+                        self eventPending ifFalse:[
+                            Processor activeProcess setStateTo:#ioWait if:#active.
+                            inputSema wait.
+                        ].
+                        dispatching ifTrue:[
+                            self dispatchPendingEvents.
+                        ].
+                    ]
+                ]
+            ] valueOnUnwindDo:[
+                inputSema notNil ifTrue:[
+                    Processor disableSemaphore:inputSema.
+                    inputSema := nil.
+                ].
+                dispatchProcess := nil.
+                self emergencyCloseConnection.
+            ].
+            inputSema notNil ifTrue:[
+                Processor disableSemaphore:inputSema.
+                inputSema := nil.
+            ].
+            dispatchProcess := nil.
+            self close.
+        ].
     ] newProcess.
 
     "/
     "/ give the process a nice name (for the processMonitor)
     "/
     (nm := self displayName) notNil ifTrue:[
-	nm := 'event dispatcher (' ,  nm , ')'.
+        nm := 'event dispatcher (' ,  nm , ')'.
     ] ifFalse:[
-	nm := 'event dispatcher'.
+        nm := 'event dispatcher'.
     ].
     p name:nm.
     p priority:(Processor userInterruptPriority).
@@ -4347,11 +4347,11 @@
     "/ is available or #eventPending returns true
 
     fd isNil ifTrue:[
-	"no fd -- so have to check for input also"
-	checkBlock := [self eventPending].
+        "no fd -- so have to check for input also"
+        checkBlock := [self eventPending].
     ] ifFalse:[
-	"there is a fd, so checkblock has to check only the internal queue"
-	checkBlock := [self eventQueued].
+        "there is a fd, so checkblock has to check only the internal queue"
+        checkBlock := [self eventQueued].
     ].
 
     Processor signal:inputSema onInput:fd orCheck:checkBlock.
@@ -4366,14 +4366,14 @@
     |p|
 
     LastActiveScreen == self ifTrue:[
-	LastActiveScreen := nil.
-	LastActiveProcess := nil.
+        LastActiveScreen := nil.
+        LastActiveProcess := nil.
     ].
 
     (p := dispatchProcess) notNil ifTrue:[
-	dispatchProcess := nil.
-	p terminateWithAllSubprocesses.
-	p terminateNoSignal.   "/ just in case
+        dispatchProcess := nil.
+        p terminateWithAllSubprocesses.
+        p terminateNoSignal.   "/ just in case
     ]
 ! !
 
@@ -4397,34 +4397,34 @@
      events. 
      Only a few control characters are supported.
      Notice: not all alien views allow this kind of synthetic input;
-	     some simply ignore it."
+             some simply ignore it."
 
     |control code state|
 
     aCharacterOrString isString ifTrue:[
-	aCharacterOrString do:[:char |
-	    self simulateKeyboardInput:char inViewId:viewId
-	].
-	^ self
+        aCharacterOrString do:[:char |
+            self simulateKeyboardInput:char inViewId:viewId
+        ].
+        ^ self
     ].
 
     control := false.
     code := aCharacterOrString asciiValue.
 
     (aCharacterOrString == Character cr) ifTrue:[
-	code := #Return
+        code := #Return
     ] ifFalse:[
-	(aCharacterOrString == Character tab) ifTrue:[
-	    code := #Tab 
-	] ifFalse:[
-	    (aCharacterOrString == Character esc) ifTrue:[
-		code := #Escape 
-	    ]
-	]
+        (aCharacterOrString == Character tab) ifTrue:[
+            code := #Tab 
+        ] ifFalse:[
+            (aCharacterOrString == Character esc) ifTrue:[
+                code := #Escape 
+            ]
+        ]
     ].
 
     control ifTrue:[
-	state := self ctrlModifierMask
+        state := self ctrlModifierMask
     ].
 
 
@@ -4434,11 +4434,11 @@
     "/ Hopefully, this is correct ...
 
     code isNumber ifTrue:[
-	code >= $A asciiValue ifTrue:[
-	    code <= $Z asciiValue ifTrue:[
-		state := self shiftModifierMask
-	    ]
-	]
+        code >= $A asciiValue ifTrue:[
+            code <= $Z asciiValue ifTrue:[
+                state := self shiftModifierMask
+            ]
+        ]
     ].
 
     self sendKeyOrButtonEvent:#keyPress x:0 y:0 keyOrButton:code state:state toViewId:viewId.
@@ -4535,7 +4535,7 @@
 
     "
      Display facesInFamily:'fixed' filtering:[:f |
-	f encoding notNil and:[f encoding startsWith:'jis']]
+        f encoding notNil and:[f encoding startsWith:'jis']]
     "
 
     "Created: 27.2.1996 / 01:33:25 / cg"
@@ -4577,7 +4577,7 @@
 
     "
      Display fontFamiliesFiltering:[:f | 
-	f encoding notNil and:[f encoding startsWith:'jis']]
+        f encoding notNil and:[f encoding startsWith:'jis']]
     "
 
     "Modified: 29.2.1996 / 04:31:51 / cg"
@@ -4598,13 +4598,13 @@
     maxWidth := self maxWidthOfFont:fontId.
     avgWidth := self widthOf:' ' inFont:fontId.
     aBlock value:encoding 
-	   value:avgAscent
-	   value:avgDescent
-	   value:maxAscent
-	   value:maxDescent
-	   value:minWidth
-	   value:maxWidth
-	   value:avgWidth
+           value:avgAscent
+           value:avgDescent
+           value:maxAscent
+           value:maxDescent
+           value:minWidth
+           value:maxWidth
+           value:avgWidth
 !
 
 fontResolutionOf:fontId
@@ -4626,17 +4626,17 @@
 
     fonts := Set new.
     allFonts do:[:fntDescr |
-	(aFilterBlock isNil or:[aFilterBlock value:fntDescr]) ifTrue:[
-	    fntDescr family notNil ifTrue:[
-		fonts add:fntDescr
-	    ]
-	]
+        (aFilterBlock isNil or:[aFilterBlock value:fntDescr]) ifTrue:[
+            fntDescr family notNil ifTrue:[
+                fonts add:fntDescr
+            ]
+        ]
     ].
     ^ fonts
 
     "
      Display fontsFiltering:[:f | 
-	f encoding notNil and:[f encoding startsWith:'jis']]
+        f encoding notNil and:[f encoding startsWith:'jis']]
     "
 
     "Modified: 29.2.1996 / 04:30:35 / cg"
@@ -4653,19 +4653,19 @@
 
     fonts := Set new.
     allFonts do:[:fntDescr |
-	(aFamilyName match:fntDescr family) ifTrue:[
-	    (aFaceName match:fntDescr face) ifTrue:[
-		(filter isNil or:[filter value:fntDescr]) ifTrue:[
-		    fonts add:fntDescr
-		]
-	    ]
-	]
+        (aFamilyName match:fntDescr family) ifTrue:[
+            (aFaceName match:fntDescr face) ifTrue:[
+                (filter isNil or:[filter value:fntDescr]) ifTrue:[
+                    fonts add:fntDescr
+                ]
+            ]
+        ]
     ].
     ^ fonts
 
     "
      Display fontsInFamily:'fixed' face:'medium' filtering:[:f |
-	f encoding notNil and:[f encoding startsWith:'jis']]
+        f encoding notNil and:[f encoding startsWith:'jis']]
     "
 
     "Created: 29.2.1996 / 04:32:56 / cg"
@@ -4684,25 +4684,25 @@
 
     fonts := Set new.
     allFonts do:[:fntDescr |
-	(aFamilyName match:fntDescr family) ifTrue:[
-	    (aFaceName match:fntDescr face) ifTrue:[
-		(aStyleName match:fntDescr style) ifTrue:[
-		    (filter isNil or:[filter value:fntDescr]) ifTrue:[
-			fonts add:fntDescr
-		    ]    
-		]
-	    ]
-	]
+        (aFamilyName match:fntDescr family) ifTrue:[
+            (aFaceName match:fntDescr face) ifTrue:[
+                (aStyleName match:fntDescr style) ifTrue:[
+                    (filter isNil or:[filter value:fntDescr]) ifTrue:[
+                        fonts add:fntDescr
+                    ]    
+                ]
+            ]
+        ]
     ].
     ^ fonts
 
     "
      Display fontsInFamily:'fixed' face:'medium' style:'roman' filtering:[:f |
-	f encoding notNil and:[f encoding startsWith:'jis']]
+        f encoding notNil and:[f encoding startsWith:'jis']]
     "
     "
      Display fontsInFamily:'fixed' face:'*' style:'roman' filtering:[:f |
-	f encoding notNil and:[f encoding startsWith:'jis']]  
+        f encoding notNil and:[f encoding startsWith:'jis']]  
     "
 
     "Created: 29.2.1996 / 04:25:30 / cg"
@@ -4720,21 +4720,21 @@
 
     fonts := Set new.
     allFonts do:[:fntDescr |
-	(aFamilyName match:fntDescr family) ifTrue:[
-	    (filterBlock isNil or:[filterBlock value:fntDescr]) ifTrue:[
-		fonts add:fntDescr
-	    ]
-	]
+        (aFamilyName match:fntDescr family) ifTrue:[
+            (filterBlock isNil or:[filterBlock value:fntDescr]) ifTrue:[
+                fonts add:fntDescr
+            ]
+        ]
     ].
     ^ fonts
 
     "
      Display fontsInFamily:'fixed' filtering:[:f |
-	f encoding notNil and:[f encoding startsWith:'jis']]
+        f encoding notNil and:[f encoding startsWith:'jis']]
     "
     "
      Display fontsInFamily:'*' filtering:[:f |
-	f encoding notNil and:[f encoding startsWith:'jis']] 
+        f encoding notNil and:[f encoding startsWith:'jis']] 
     "
 
     "Created: 29.2.1996 / 04:27:49 / cg"
@@ -4807,7 +4807,7 @@
 
     "
      Display sizesInFamily:'fixed' face:'medium' style:'roman' filtering:[:f |
-	f encoding notNil and:[f encoding startsWith:'jis']]
+        f encoding notNil and:[f encoding startsWith:'jis']]
     "
 
     "Created: 27.2.1996 / 01:37:56 / cg"
@@ -4840,7 +4840,7 @@
 
     "
      Display stylesInFamily:'fixed' face:'medium' filtering:[:f |
-	f encoding notNil and:[f encoding startsWith:'jis']]
+        f encoding notNil and:[f encoding startsWith:'jis']]
     "
 
     "Created: 27.2.1996 / 01:35:22 / cg"
@@ -4887,12 +4887,12 @@
      Return true if ok, false if it failed for some reason."
 
     activeKeyboardGrab notNil ifTrue:[
-	self ungrabKeyboard.
-	activeKeyboardGrab := nil
+        self ungrabKeyboard.
+        activeKeyboardGrab := nil
     ].
     (self grabKeyboardIn:(aView id)) ifTrue:[
-	activeKeyboardGrab := aView.
-	^ true
+        activeKeyboardGrab := aView.
+        ^ true
     ].
     ^ false
 !
@@ -4924,12 +4924,12 @@
      aView. Return true if ok, false if it failed for some reason."
 
     activePointerGrab notNil ifTrue:[
-	self ungrabPointer.
-	activePointerGrab := nil
+        self ungrabPointer.
+        activePointerGrab := nil
     ].
     (self grabPointerIn:(aView id)) ifTrue:[
-	activePointerGrab := aView.
-	^ true
+        activePointerGrab := aView.
+        ^ true
     ].
     ^ false
 !
@@ -4941,15 +4941,15 @@
     |cId|
 
     activePointerGrab notNil ifTrue:[
-	self ungrabPointer.
-	activePointerGrab := nil
+        self ungrabPointer.
+        activePointerGrab := nil
     ].
     aCursor notNil ifTrue:[
-	cId := aCursor id.
+        cId := aCursor id.
     ].
     (self grabPointerIn:(aView id) withCursorId:cId) ifTrue:[
-	activePointerGrab := aView.
-	^ true
+        activePointerGrab := aView.
+        ^ true
     ].
     ^ false
 !
@@ -5072,31 +5072,31 @@
     displayId := nil.
 
     LastActiveScreen == self ifTrue:[
-	LastActiveScreen := nil.
-	LastActiveProcess := nil.
+        LastActiveScreen := nil.
+        LastActiveProcess := nil.
     ].
 
     "/ tell all of my views about this.
     "/ first, all topViews get a notification ...
 
     self allViews do:[:aView |
-	|wg sensor|
-
-	aView isTopView ifTrue:[
-	    "/ notice: we must manually wakeup the
-	    "/ windowGroup process here (it might be waiting on
-	    "/ an event, and the destroy below is executed by
-	    "/ another thread.
-	    "/ Otherwise, the windowGroup process would
-	    "/ not terminate itself in this case.
-	    (wg := aView windowGroup) notNil ifTrue:[
-		sensor := wg sensor
-	    ].
-	    aView destroyed.
-	    sensor notNil ifTrue:[
-		sensor eventSemaphore signal.
-	    ].
-	]
+        |wg sensor|
+
+        aView isTopView ifTrue:[
+            "/ notice: we must manually wakeup the
+            "/ windowGroup process here (it might be waiting on
+            "/ an event, and the destroy below is executed by
+            "/ another thread.
+            "/ Otherwise, the windowGroup process would
+            "/ not terminate itself in this case.
+            (wg := aView windowGroup) notNil ifTrue:[
+                sensor := wg sensor
+            ].
+            aView destroyed.
+            sensor notNil ifTrue:[
+                sensor eventSemaphore signal.
+            ].
+        ]
     ].
 
     self releaseDeviceResources.
@@ -5136,7 +5136,7 @@
      event dispatching should stop when the last view is closed."
 
     self == Display ifTrue:[
-	ExitOnLastClose := aBoolean
+        ExitOnLastClose := aBoolean
     ].
     exitOnLastClose := aBoolean
 
@@ -5147,8 +5147,8 @@
     "initialize the receiver for a connection to the default display"
 
     idToTableIndexMapping notNil ifTrue:[
-	"/ assume, I am already initialized ...
-	^ self.
+        "/ assume, I am already initialized ...
+        ^ self.
     ].
 
     idToTableIndexMapping := Dictionary new:100.
@@ -5178,9 +5178,9 @@
     "initialize heavily used device resources - to avoid looking them up later"
 
     blackColor isNil ifTrue:[
-	blackColor := Color black onDevice:self.
-	whiteColor := Color white onDevice:self.
-	Color getPrimaryColorsOn:self.
+        blackColor := Color black onDevice:self.
+        whiteColor := Color white onDevice:self.
+        Color getPrimaryColorsOn:self.
     ]
 
     "Modified: 24.2.1997 / 22:07:50 / cg"
@@ -5213,7 +5213,7 @@
     "
 
     keyboardMap isNil ifTrue:[
-	keyboardMap := KeyboardMap new.
+        keyboardMap := KeyboardMap new.
     ].
 
     "
@@ -5236,7 +5236,7 @@
     "setup screen specific properties."
 
     supportsDeepIcons isNil ifTrue:[
-	supportsDeepIcons := false.
+        supportsDeepIcons := false.
     ].
 
     fixColors := fixGrayColors := ditherColors := nil.
@@ -5249,9 +5249,9 @@
     "late viewStyle init - if no viewStyle has been read yet."
 
     View styleSheet isNil ifTrue:[
-	CurrentScreenQuerySignal answer:self do:[
-	    View readStyleSheetAndUpdateAllStyleCaches
-	]
+        CurrentScreenQuerySignal answer:self do:[
+            View readStyleSheetAndUpdateAllStyleCaches
+        ]
     ].
 !
 
@@ -5270,10 +5270,10 @@
     |prevKnownViews prevMapping prevWidth prevHeight|
 
     blackColor notNil ifTrue:[
-	blackColor releaseFromDevice. 
+        blackColor releaseFromDevice. 
     ].
     whiteColor notNil ifTrue:[
-	whiteColor releaseFromDevice.
+        whiteColor releaseFromDevice.
     ].
     self releaseDeviceFonts.
     self releaseDeviceCursors.
@@ -5299,9 +5299,9 @@
 
     self initializeFor:nil.
     displayId isNil ifTrue:[
-	'DevWorkstation [error]: could not connect to display' errorPrintCR.
-	Smalltalk exit.
-	^ self
+        'DevWorkstation [error]: could not connect to display' errorPrintCR.
+        Smalltalk exit.
+        ^ self
     ].
 
     "
@@ -5313,51 +5313,51 @@
 
 "/    prevMapping notNil ifTrue:[
     prevKnownViews notNil ifTrue:[
-	"
-	 first round: flush all device specific stuff
-	"
+        "
+         first round: flush all device specific stuff
+        "
 "/      prevMapping keysAndValuesDo:[:anId :aView |
-	prevKnownViews do:[:aView |
-	    (aView notNil and:[aView ~~ 0]) ifTrue:[
-		aView prepareForReinit
-	    ]
-	].
-
-	"
-	 2nd round: all views should reinstall themself
-		    on the new display
-	"
+        prevKnownViews do:[:aView |
+            (aView notNil and:[aView ~~ 0]) ifTrue:[
+                aView prepareForReinit
+            ]
+        ].
+
+        "
+         2nd round: all views should reinstall themself
+                    on the new display
+        "
 "/      prevMapping keysAndValuesDo:[:anId :aView |
 
-	prevKnownViews do:[:aView |
-	    (aView notNil and:[aView ~~ 0]) ifTrue:[
-		"have to re-create the view"
-		UserInterruptSignal catch:[
-		    AbortSignal catch:[
-			GraphicsContext drawingOnClosedDrawableSignal handle:[:ex |
-			    'DeviceWorkstation [warning]: drawing attempt on closed drawable during reinit' errorPrintCR.
-			    ex return
-			] do:[
-			    aView reinitialize
-			]
-		    ]
-		]
-	    ]
-	].
-
-	(prevWidth ~~ width
-	or:[prevHeight ~~ height]) ifTrue:[
-	    "
-	     3rd round: all views get a chance to handle
-			changed environment (colors, font sizes etc)
-	    "
+        prevKnownViews do:[:aView |
+            (aView notNil and:[aView ~~ 0]) ifTrue:[
+                "have to re-create the view"
+                UserInterruptSignal catch:[
+                    AbortSignal catch:[
+                        GraphicsContext drawingOnClosedDrawableSignal handle:[:ex |
+                            'DeviceWorkstation [warning]: drawing attempt on closed drawable during reinit' errorPrintCR.
+                            ex return
+                        ] do:[
+                            aView reinitialize
+                        ]
+                    ]
+                ]
+            ]
+        ].
+
+        (prevWidth ~~ width
+        or:[prevHeight ~~ height]) ifTrue:[
+            "
+             3rd round: all views get a chance to handle
+                        changed environment (colors, font sizes etc)
+            "
 "/          prevMapping keysAndValuesDo:[:anId :aView |
-	    prevKnownViews do:[:aView |
-		(aView notNil and:[aView ~~ 0]) ifTrue:[
-		    aView reAdjustGeometry
-		]
-	    ].
-	]
+            prevKnownViews do:[:aView |
+                (aView notNil and:[aView ~~ 0]) ifTrue:[
+                    aView reAdjustGeometry
+                ]
+            ].
+        ]
     ].
     dispatching := false.
 
@@ -5370,15 +5370,15 @@
      (i.e. be prepared to not be able to release resources regularily)"
 
     blackColor notNil ifTrue:[
-	blackColor releaseFromDevice. 
+        blackColor releaseFromDevice. 
     ].
     whiteColor notNil ifTrue:[
-	whiteColor releaseFromDevice.
+        whiteColor releaseFromDevice.
     ].
 
     LastActiveScreen == self ifTrue:[
-	LastActiveScreen := nil.
-	LastActiveProcess := nil.
+        LastActiveScreen := nil.
+        LastActiveProcess := nil.
     ].
 
     blackColor := whiteColor := nil.
@@ -5443,42 +5443,42 @@
     root foreground:blackColor background:whiteColor.
 
     root xoring:[
-	|left right top bottom newOrigin newCorner p|
-
-	rect := origin extent:extent.
-	root displayRectangle:rect.
-
-	prevGrab := activePointerGrab.
-	self grabPointerInView:root withCursor:curs.
-
-	[self leftButtonPressed] whileTrue:[
-	    newOrigin := self pointerPosition.
-
-	    (newOrigin ~= origin) ifTrue:[
-		root displayRectangle:rect.
-
-		self 
-		    grabPointerIn:root id 
-		    withCursor:curs id
-		    pointerMode:#async 
-		    keyboardMode:#sync 
-		    confineTo:nil.
-
-		rect := newOrigin extent:extent.
-		root displayRectangle:rect.
-		self disposeButtonEventsFor:nil.
-		self flush.
-		origin := newOrigin.
-	    ] ifFalse:[
-		Delay waitForSeconds:0.05
-	    ]
-	].
-	root displayRectangle:rect.
+        |left right top bottom newOrigin newCorner p|
+
+        rect := origin extent:extent.
+        root displayRectangle:rect.
+
+        prevGrab := activePointerGrab.
+        self grabPointerInView:root withCursor:curs.
+
+        [self leftButtonPressed] whileTrue:[
+            newOrigin := self pointerPosition.
+
+            (newOrigin ~= origin) ifTrue:[
+                root displayRectangle:rect.
+
+                self 
+                    grabPointerIn:root id 
+                    withCursor:curs id
+                    pointerMode:#async 
+                    keyboardMode:#sync 
+                    confineTo:nil.
+
+                rect := newOrigin extent:extent.
+                root displayRectangle:rect.
+                self disposeButtonEventsFor:nil.
+                self flush.
+                origin := newOrigin.
+            ] ifFalse:[
+                Delay waitForSeconds:0.05
+            ]
+        ].
+        root displayRectangle:rect.
     ].
 
     self ungrabPointer.
     prevGrab notNil ifTrue:[
-	self grabPointerInView:prevGrab.
+        self grabPointerInView:prevGrab.
     ].
 
     "flush all events pending on my display"
@@ -5531,7 +5531,7 @@
 
     self ungrabPointer.
     prevGrab notNil ifTrue:[
-	self grabPointerInView:prevGrab
+        self grabPointerInView:prevGrab
     ].
 
     "flush all events pending on myself"
@@ -5603,9 +5603,9 @@
     doRegrab := self class ~~ WinWorkstation.
 
     keepExtent ifTrue:[
-	curs1 := Cursor origin 
+        curs1 := Cursor origin 
     ] ifFalse:[    
-	curs1 := Cursor corner
+        curs1 := Cursor corner
     ].
     curs1 := curs1 onDevice:self.
     root := self rootView.
@@ -5619,91 +5619,91 @@
     root foreground:blackColor background:whiteColor.
 
     root xoring:[
-	|left right top bottom newOrigin newCorner p curs|
-
-	keepExtent ifFalse:[
-	    corner := origin.
-	    rect := origin corner:corner.
-	    root displayRectangle:rect.
-	].
-
-	prevGrab := activePointerGrab.
-	self grabPointerInView:root withCursor:curs1.
-
-	"
-	 just in case; wait for button to be down ...
-	"
-	[self leftButtonPressed] whileFalse:[Delay waitForSeconds:0.05].
-
-	keepExtent ifTrue:[
-	    p := self pointerPosition.
-	    origin := p.
-	    corner := origin + initialRectangle extent.
-	    rect := origin corner:corner.
-	    root displayRectangle:rect.
-	].
-
-	[self leftButtonPressed] whileTrue:[
-	    left := initialRectangle origin x.
-	    top := initialRectangle origin y.
-	    right := initialRectangle corner x.
-	    bottom := initialRectangle corner y.
-
-	    p := self pointerPosition.
-	    keepExtent ifTrue:[
-		newOrigin := p.
-		newCorner := newOrigin + initialRectangle extent.
-		curs := curs1.
-	    ] ifFalse:[
-		p x < initialRectangle left ifTrue:[
-		    p y < initialRectangle top ifTrue:[
-			curs := Cursor topLeft.
-			left := p x.
-			top := p y.
-		    ] ifFalse:[
-			curs := Cursor bottomLeft.
-			left := p x.
-			bottom := p y
-		    ]
-		] ifFalse:[
-		    p y < initialRectangle top ifTrue:[
-			curs := Cursor topRight.
-			right := p x.
-			top := p y
-		    ] ifFalse:[
-			curs := Cursor bottomRight.
-			right := p x.
-			bottom := p y
-		    ]
-		].
-
-		newOrigin := left @ top.
-		newCorner := right @ bottom.
-	    ].
-
-	    ((newOrigin ~= origin) or:[newCorner ~= corner]) ifTrue:[
-		root displayRectangle:rect.
-		doRegrab ifTrue:[
-		    self grabPointerInView:root withCursor:curs1.
-		].
-
-		origin :=  newOrigin.
-		corner :=  newCorner.
-		rect := origin corner:corner.
-		root displayRectangle:rect.
-		self disposeButtonEventsFor:nil.
-		self flush.
-	    ] ifFalse:[
-		Delay waitForSeconds:0.05
-	    ]
-	].
-	root displayRectangle:rect.
+        |left right top bottom newOrigin newCorner p curs|
+
+        keepExtent ifFalse:[
+            corner := origin.
+            rect := origin corner:corner.
+            root displayRectangle:rect.
+        ].
+
+        prevGrab := activePointerGrab.
+        self grabPointerInView:root withCursor:curs1.
+
+        "
+         just in case; wait for button to be down ...
+        "
+        [self leftButtonPressed] whileFalse:[Delay waitForSeconds:0.05].
+
+        keepExtent ifTrue:[
+            p := self pointerPosition.
+            origin := p.
+            corner := origin + initialRectangle extent.
+            rect := origin corner:corner.
+            root displayRectangle:rect.
+        ].
+
+        [self leftButtonPressed] whileTrue:[
+            left := initialRectangle origin x.
+            top := initialRectangle origin y.
+            right := initialRectangle corner x.
+            bottom := initialRectangle corner y.
+
+            p := self pointerPosition.
+            keepExtent ifTrue:[
+                newOrigin := p.
+                newCorner := newOrigin + initialRectangle extent.
+                curs := curs1.
+            ] ifFalse:[
+                p x < initialRectangle left ifTrue:[
+                    p y < initialRectangle top ifTrue:[
+                        curs := Cursor topLeft.
+                        left := p x.
+                        top := p y.
+                    ] ifFalse:[
+                        curs := Cursor bottomLeft.
+                        left := p x.
+                        bottom := p y
+                    ]
+                ] ifFalse:[
+                    p y < initialRectangle top ifTrue:[
+                        curs := Cursor topRight.
+                        right := p x.
+                        top := p y
+                    ] ifFalse:[
+                        curs := Cursor bottomRight.
+                        right := p x.
+                        bottom := p y
+                    ]
+                ].
+
+                newOrigin := left @ top.
+                newCorner := right @ bottom.
+            ].
+
+            ((newOrigin ~= origin) or:[newCorner ~= corner]) ifTrue:[
+                root displayRectangle:rect.
+                doRegrab ifTrue:[
+                    self grabPointerInView:root withCursor:curs1.
+                ].
+
+                origin :=  newOrigin.
+                corner :=  newCorner.
+                rect := origin corner:corner.
+                root displayRectangle:rect.
+                self disposeButtonEventsFor:nil.
+                self flush.
+            ] ifFalse:[
+                Delay waitForSeconds:0.05
+            ]
+        ].
+        root displayRectangle:rect.
     ].
 
 
     self ungrabPointer.
     prevGrab notNil ifTrue:[
-	self grabPointerInView:prevGrab
+        self grabPointerInView:prevGrab
     ].
 
     "flush all events pending on my display"
@@ -5736,7 +5736,7 @@
 
     v := self viewFromUser.
     v notNil ifTrue:[
-	v := v topView
+        v := v topView
     ].
     ^ v 
 
@@ -5841,19 +5841,19 @@
      Called with every keyPress/keyRelease to update the xxxDown flags."
 
     (altModifiers notNil and:[altModifiers includes:key]) ifTrue:[
-	altDown := pressed
+        altDown := pressed
     ] ifFalse:[
-	(metaModifiers notNil and:[metaModifiers includes:key]) ifTrue:[
-	    metaDown := pressed
-	] ifFalse:[
-	    (shiftModifiers notNil and:[shiftModifiers includes:key]) ifTrue:[
-		shiftDown := pressed
-	    ] ifFalse:[
-		(ctrlModifiers notNil and:[ctrlModifiers includes:key]) ifTrue:[
-		    ctrlDown := pressed
-		]
-	    ]
-	]
+        (metaModifiers notNil and:[metaModifiers includes:key]) ifTrue:[
+            metaDown := pressed
+        ] ifFalse:[
+            (shiftModifiers notNil and:[shiftModifiers includes:key]) ifTrue:[
+                shiftDown := pressed
+            ] ifFalse:[
+                (ctrlModifiers notNil and:[ctrlModifiers includes:key]) ifTrue:[
+                    ctrlDown := pressed
+                ]
+            ]
+        ]
     ]
 
     "Modified: 2.1.1996 / 15:00:25 / cg"
@@ -5866,27 +5866,27 @@
     |t modifiers|
 
     key == #Alt ifTrue:[
-	modifiers := altModifiers
+        modifiers := altModifiers
     ] ifFalse:[
-	key == #Cmd ifTrue:[
-	    modifiers := metaModifiers
-	]
+        key == #Cmd ifTrue:[
+            modifiers := metaModifiers
+        ]
     ].
 
     "/ temporary kludge ...
     (modifiers size > 0) ifTrue:[
-	(modifiers includes:'Num_Lock') ifTrue:[
-	    modifiers := modifiers copy.
-	    modifiers remove:'Num_Lock'
-	]
+        (modifiers includes:'Num_Lock') ifTrue:[
+            modifiers := modifiers copy.
+            modifiers remove:'Num_Lock'
+        ]
     ].
 
     (modifiers size > 0) ifTrue:[
-	t := modifiers first.
-	(t includes:$_) ifTrue:[
-	    t := t copyTo:(t indexOf:$_)-1
-	].
-	^ t
+        t := modifiers first.
+        (t includes:$_) ifTrue:[
+            t := t copyTo:(t indexOf:$_)-1
+        ].
+        ^ t
     ].
     ^ key
 
@@ -5904,33 +5904,33 @@
     (untranslatedKey == #Control
     or:[untranslatedKey == #'Control_L'   
     or:[untranslatedKey == #'Control_R']]) ifTrue:[
-	^ #Ctrl
+        ^ #Ctrl
     ].
 
     (untranslatedKey == #Ctrl
     or:[untranslatedKey == #'Ctrl_L' 
     or:[untranslatedKey == #'Ctrl_R']]) ifTrue:[
-	^ #Ctrl
+        ^ #Ctrl
     ].
     (untranslatedKey == #'Shift'   
     or:[untranslatedKey == #'Shift_L'   
     or:[untranslatedKey == #'Shift_R']]) ifTrue:[
-	^ #Shift
+        ^ #Shift
     ].
     (untranslatedKey == #'Alt'   
     or:[untranslatedKey == #'Alt_L'   
     or:[untranslatedKey == #'Alt_R']]) ifTrue:[
-	^ #Alt
+        ^ #Alt
     ].
     (untranslatedKey == #'Meta'   
     or:[untranslatedKey == #'Meta_L'   
     or:[untranslatedKey == #'Meta_R']]) ifTrue:[
-	^ #Meta
+        ^ #Meta
     ].
     (untranslatedKey == #'Cmd'   
     or:[untranslatedKey == #'Cmd_L'   
     or:[untranslatedKey == #'Cmd_R']]) ifTrue:[
-	^ #Cmd
+        ^ #Cmd
     ].
     ^ nil
 
@@ -5997,7 +5997,7 @@
 
     xlatedKey := aView keyboardMap valueFor:xlatedKey.
     xlatedKey isCharacter ifFalse:[
-	xlatedKey := xlatedKey asSymbol
+        xlatedKey := xlatedKey asSymbol
     ].
     ^ xlatedKey
 
@@ -6085,7 +6085,7 @@
     "output an audible beep or bell"
 
     UserPreferences current beepEnabled ifTrue:[
-	Stdout nextPut:(Character bell)
+        Stdout nextPut:(Character bell)
     ]
 
     "Modified: / 13.1.1997 / 22:56:13 / cg"
@@ -6157,13 +6157,13 @@
     newBits := ByteArray new:(bytesPerLineWanted * height).
     srcIndex := dstIndex := 1.
     1 to:height do:[:row |
-	newBits 
-	    replaceFrom:dstIndex
-	    to:(dstIndex + bytesPerLineWanted - 1)
-	    with:givenBits
-	    startingAt:srcIndex.
-	dstIndex := dstIndex + bytesPerLineWanted.
-	srcIndex := srcIndex + bytesPerLineGiven.
+        newBits 
+            replaceFrom:dstIndex
+            to:(dstIndex + bytesPerLineWanted - 1)
+            with:givenBits
+            startingAt:srcIndex.
+        dstIndex := dstIndex + bytesPerLineWanted.
+        srcIndex := srcIndex + bytesPerLineGiven.
     ].
     ^ newBits.
         
@@ -6398,7 +6398,7 @@
 
     aStream nextPut:$(.
     (name := self displayName) isNil ifTrue:[
-	name := 'defaultDisplay'
+        name := 'defaultDisplay'
     ].
     aStream nextPutAll:name.
     aStream nextPut:$)
@@ -6426,12 +6426,12 @@
      in advance, since the X-server is free to return whatever it thinks is a good padding."
 
     ^ self
-	getBitsFromId:aDrawableId 
-	x:srcx 
-	y:srcy 
-	width:w 
-	height:h 
-	into:imageBits
+        getBitsFromId:aDrawableId 
+        x:srcx 
+        y:srcy 
+        width:w 
+        height:h 
+        into:imageBits
 
     "Created: 19.3.1997 / 13:43:04 / cg"
     "Modified: 19.3.1997 / 13:43:38 / cg"
@@ -6445,12 +6445,12 @@
      in advance, since the X-server is free to return whatever it thinks is a good padding."
 
     ^ self
-	getBitsFromId:aDrawableId 
-	x:srcx 
-	y:srcy 
-	width:w 
-	height:h 
-	into:imageBits
+        getBitsFromId:aDrawableId 
+        x:srcx 
+        y:srcy 
+        width:w 
+        height:h 
+        into:imageBits
 
     "Created: 19.3.1997 / 13:43:04 / cg"
     "Modified: 19.3.1997 / 13:43:42 / cg"
@@ -6546,20 +6546,21 @@
     o := self getCopyBuffer.
     s := o.
     o isString ifFalse:[
-	o isNil ifTrue:[
-	    s := ''
-	] ifFalse:[
-	    (o isStringCollection) ifTrue:[
-		s := o asStringWithCRsFrom:1 to:(o size) compressTabs:false withCR:false.
-		s := s string.
-	    ] ifFalse:[
-		Object recursiveStoreStringSignal handle:[:ex |
-		   s := ''
-		] do:[
-		   s := o storeString
-		]
-	    ]
-	]
+        o isNil ifTrue:[
+            s := ''
+        ] ifFalse:[
+            (o isStringCollection) ifTrue:[
+                o := o collect:[:each| each isNil ifTrue:[nil] ifFalse:[each string]].
+                s := o asStringWithCRsFrom:1 to:(o size) compressTabs:false withCR:false.
+                s := s string.
+            ] ifFalse:[
+                Object recursiveStoreStringSignal handle:[:ex |
+                   s := ''
+                ] do:[
+                   s := o storeString
+                ]
+            ]
+        ]
     ].
     ^ s
 
@@ -6617,45 +6618,45 @@
      where the systemDefaults are used ..."
 
     <resource: #style (#viewSpacing 
-		       #borderColor #borderWidth
-		       #viewBackgroundColor #shadowColor #lightColor
-		      )>
+                       #borderColor #borderWidth
+                       #viewBackgroundColor #shadowColor #lightColor
+                      )>
 
     aKey == #viewSpacing ifTrue:[
-	^ self verticalPixelPerMillimeter rounded       "/ 1 millimeter
+        ^ self verticalPixelPerMillimeter rounded       "/ 1 millimeter
     ].
 
     aKey == #borderColor ifTrue:[
-	^ Color black
+        ^ Color black
     ].
     aKey == #borderWidth ifTrue:[
-	^ 1
+        ^ 1
     ].
 
     aKey == #shadowColor ifTrue:[
-	^ Color black
+        ^ Color black
     ].
     aKey == #lightColor ifTrue:[
-	^ Color white
+        ^ Color white
     ].
     aKey == #viewBackgroundColor ifTrue:[
-	^ Color white
+        ^ Color white
     ].
     aKey == #scrollerViewBackgroundColor ifTrue:[
-	^ Color white
+        ^ Color white
     ].
 
     aKey == #textForegroundColor ifTrue:[
-	^ Color black.
+        ^ Color black.
     ].
     aKey == #textBackgroundColor ifTrue:[
-	^ Color white.
+        ^ Color white.
     ].
     aKey == #selectionForegroundColor ifTrue:[
-	^ Color white.
+        ^ Color white.
     ].
     aKey == #selectionBackgroundColor ifTrue:[
-	^ Color black.
+        ^ Color black.
     ].
 
     ^ nil.
@@ -6676,43 +6677,43 @@
     wasBlocked := OperatingSystem blockInterrupts.
 
     knownViews isNil ifTrue:[
-	knownViews := WeakArray new:50.
-	knownIds := Array new:50.
-	freeIdx := 1.
+        knownViews := WeakArray new:50.
+        knownIds := Array new:50.
+        freeIdx := 1.
     ] ifFalse:[
-	freeIdx := knownViews identityIndexOf:nil.
-	freeIdx == 0 ifTrue:[
-	    freeIdx := knownViews identityIndexOf:0.
-	    [freeIdx ~~ 0 
-	     and:[(knownIds at:freeIdx) notNil]] whileTrue:[
-		"/ mhmh - the view is already clear in the weakArray
-		"/ but the id is not.
-		"/ (i.e. its collected, but not yet finalized)
-		"/ skip this entry.
-		"/ 'XXX ' print. (knownIds at:freeIdx) displayString printCR.
-		freeIdx := knownViews identityIndexOf:0 startingAt:(freeIdx + 1).
-	    ].
-	].
+        freeIdx := knownViews identityIndexOf:nil.
+        freeIdx == 0 ifTrue:[
+            freeIdx := knownViews identityIndexOf:0.
+            [freeIdx ~~ 0 
+             and:[(knownIds at:freeIdx) notNil]] whileTrue:[
+                "/ mhmh - the view is already clear in the weakArray
+                "/ but the id is not.
+                "/ (i.e. its collected, but not yet finalized)
+                "/ skip this entry.
+                "/ 'XXX ' print. (knownIds at:freeIdx) displayString printCR.
+                freeIdx := knownViews identityIndexOf:0 startingAt:(freeIdx + 1).
+            ].
+        ].
     ].
 
     freeIdx == 0 ifTrue:[
-	sz := knownViews size.
-	newSize := sz * 2.
-	newArr := WeakArray new:newSize.
-	newArr replaceFrom:1 to:sz with:knownViews.
-	knownViews := newArr.
-
-	newArr := Array new:newSize.
-	newArr replaceFrom:1 to:sz with:knownIds.
-	knownIds := newArr.
-	freeIdx := sz + 1.
+        sz := knownViews size.
+        newSize := sz * 2.
+        newArr := WeakArray new:newSize.
+        newArr replaceFrom:1 to:sz with:knownViews.
+        knownViews := newArr.
+
+        newArr := Array new:newSize.
+        newArr replaceFrom:1 to:sz with:knownIds.
+        knownIds := newArr.
+        freeIdx := sz + 1.
     ].
     knownViews at:freeIdx put:aView.
     knownIds at:freeIdx put:aWindowID.
     wasBlocked ifFalse:[OperatingSystem unblockInterrupts].
 
     idToTableIndexMapping notNil ifTrue:[
-	idToTableIndexMapping at:aWindowID put:freeIdx.
+        idToTableIndexMapping at:aWindowID put:freeIdx.
     ].
 
 "/    dispatching ifFalse:[
@@ -6740,82 +6741,82 @@
     lastId := nil.
     lastView := nil.
     focusView == aView ifTrue:[
-	focusView := nil
+        focusView := nil
     ].
 
     knownViews notNil ifTrue:[
-	wasBlocked := OperatingSystem blockInterrupts.
-
-	index := 0.
-	aViewId notNil ifTrue:[
-	    idToTableIndexMapping notNil ifTrue:[
-		index := idToTableIndexMapping at:aViewId ifAbsent:0.
-	    ]
-	].
-	index == 0 ifTrue:[
-	    aView notNil ifTrue:[
-		index := knownViews identityIndexOf:aView.
-	    ].
-	].
-
-	index ~~ 0 ifTrue:[
-	    idToTableIndexMapping notNil ifTrue:[
-		aViewId notNil ifTrue:[
-		    idToTableIndexMapping removeKey:aViewId ifAbsent:nil
-		] ifFalse:[
-		    id := knownIds at:index.
-		    id notNil ifTrue:[
-			idToTableIndexMapping removeKey:id ifAbsent:nil.
-		    ]
-		]
-	    ].
-	    knownViews at:index put:nil.
-	    knownIds at:index put:nil.
-	    lastId := nil.
-	    lastView := nil.
-	].
-
-	wasBlocked ifFalse:[OperatingSystem unblockInterrupts].
-
-	aView notNil ifTrue:[
-	    aView isTopView ifTrue:[
-		"/ check for sparsely filled knownViews - array
-		wasBlocked := OperatingSystem blockInterrupts.
-		n := 0.
-		knownViews do:[:v |
-		    (v notNil and:[v ~~ 0]) ifTrue:[
-			n := n + 1
-		    ].
-		].
-		n < (knownViews size * 2 // 3) ifTrue:[
-		    newSize := n * 3 // 2.
-		    newSize > 50 ifTrue:[
-			nV := WeakArray new:newSize.
-			nI := Array new:newSize.
-			dstIdx := 1.
-			1 to:knownViews size do:[:srcIdx |
-			    v := knownViews at:srcIdx.
-			    (v notNil and:[v ~~ 0]) ifTrue:[
-				nV at:dstIdx put:v.
-				nI at:dstIdx put:(knownIds at:srcIdx).
-				dstIdx := dstIdx + 1.
-			    ].
-			].
-			idToTableIndexMapping := nil.
-			knownViews := nV.
-			knownIds := nI.
-			idToTableIndexMapping := Dictionary new.
-			knownIds keysAndValuesDo:[:idx :id |
-			    id notNil ifTrue:[
-				idToTableIndexMapping at:id put:idx
-			    ]
-			].
-		    ].
-		].
-		wasBlocked ifFalse:[OperatingSystem unblockInterrupts].
-	    ].
-	].
-	self checkForEndOfDispatch.
+        wasBlocked := OperatingSystem blockInterrupts.
+
+        index := 0.
+        aViewId notNil ifTrue:[
+            idToTableIndexMapping notNil ifTrue:[
+                index := idToTableIndexMapping at:aViewId ifAbsent:0.
+            ]
+        ].
+        index == 0 ifTrue:[
+            aView notNil ifTrue:[
+                index := knownViews identityIndexOf:aView.
+            ].
+        ].
+
+        index ~~ 0 ifTrue:[
+            idToTableIndexMapping notNil ifTrue:[
+                aViewId notNil ifTrue:[
+                    idToTableIndexMapping removeKey:aViewId ifAbsent:nil
+                ] ifFalse:[
+                    id := knownIds at:index.
+                    id notNil ifTrue:[
+                        idToTableIndexMapping removeKey:id ifAbsent:nil.
+                    ]
+                ]
+            ].
+            knownViews at:index put:nil.
+            knownIds at:index put:nil.
+            lastId := nil.
+            lastView := nil.
+        ].
+
+        wasBlocked ifFalse:[OperatingSystem unblockInterrupts].
+
+        aView notNil ifTrue:[
+            aView isTopView ifTrue:[
+                "/ check for sparsely filled knownViews - array
+                wasBlocked := OperatingSystem blockInterrupts.
+                n := 0.
+                knownViews do:[:v |
+                    (v notNil and:[v ~~ 0]) ifTrue:[
+                        n := n + 1
+                    ].
+                ].
+                n < (knownViews size * 2 // 3) ifTrue:[
+                    newSize := n * 3 // 2.
+                    newSize > 50 ifTrue:[
+                        nV := WeakArray new:newSize.
+                        nI := Array new:newSize.
+                        dstIdx := 1.
+                        1 to:knownViews size do:[:srcIdx |
+                            v := knownViews at:srcIdx.
+                            (v notNil and:[v ~~ 0]) ifTrue:[
+                                nV at:dstIdx put:v.
+                                nI at:dstIdx put:(knownIds at:srcIdx).
+                                dstIdx := dstIdx + 1.
+                            ].
+                        ].
+                        idToTableIndexMapping := nil.
+                        knownViews := nV.
+                        knownIds := nI.
+                        idToTableIndexMapping := Dictionary new.
+                        knownIds keysAndValuesDo:[:idx :id |
+                            id notNil ifTrue:[
+                                idToTableIndexMapping at:id put:idx
+                            ]
+                        ].
+                    ].
+                ].
+                wasBlocked ifFalse:[OperatingSystem unblockInterrupts].
+            ].
+        ].
+        self checkForEndOfDispatch.
     ]
 
     "Created: 22.3.1997 / 14:56:20 / cg"
@@ -6828,37 +6829,37 @@
     |index v idx|
 
     aWindowID = lastId ifTrue:[
-	lastView notNil ifTrue:[
-	    ^ lastView
-	]
+        lastView notNil ifTrue:[
+            ^ lastView
+        ]
     ].
 
     idToTableIndexMapping notNil ifTrue:[
-	idx := idToTableIndexMapping at:aWindowID ifAbsent:nil.
-	idx notNil ifTrue:[
-	    v := knownViews at:idx.
-	    (v notNil and:[v ~~ 0]) ifTrue:[
-		lastView := v.
-		lastId := aWindowID.
-		^ v
-	    ].
-	]
+        idx := idToTableIndexMapping at:aWindowID ifAbsent:nil.
+        idx notNil ifTrue:[
+            v := knownViews at:idx.
+            (v notNil and:[v ~~ 0]) ifTrue:[
+                lastView := v.
+                lastId := aWindowID.
+                ^ v
+            ].
+        ]
     ].
 
     knownIds isNil ifTrue:[
-	^ nil
+        ^ nil
     ].
 
     index := knownIds indexOf:aWindowID.
     index == 0 ifTrue:[
-	^ nil
+        ^ nil
     ].
 
     v := knownViews at:index.
     v == 0 ifTrue:[
-	knownViews at:index put:nil.
-	knownIds at:index put:nil.
-	^ nil
+        knownViews at:index put:nil.
+        knownIds at:index put:nil.
+        ^ nil
     ].
 
     lastId := aWindowID.
@@ -6875,20 +6876,20 @@
     |index v|
 
     aWindowID = lastId ifTrue:[
-	lastView notNil ifTrue:[
-	    ^ true
-	]
+        lastView notNil ifTrue:[
+            ^ true
+        ]
     ].
 
     idToTableIndexMapping notNil ifTrue:[
-	index := idToTableIndexMapping at:aWindowID ifAbsent:nil.
+        index := idToTableIndexMapping at:aWindowID ifAbsent:nil.
     ].
     index isNil ifTrue:[
-	index := knownIds indexOf:aWindowID.
+        index := knownIds indexOf:aWindowID.
     ].
     index ~~ 0 ifTrue:[
-	v := knownViews at:index.
-	^ (v notNil and:[v ~~ 0])
+        v := knownViews at:index.
+        ^ (v notNil and:[v ~~ 0])
     ].
     ^ false.
 
@@ -6934,12 +6935,12 @@
     "/ use mapView:...minWidth:minHeight:maxWidth:maxHeight:
 
     ^ self
-	mapView:aView id:aWindowId iconified:aBoolean atX:xPos y:yPos
-	width:w height:h minExtent:nil maxExtent:nil
+        mapView:aView id:aWindowId iconified:aBoolean atX:xPos y:yPos
+        width:w height:h minExtent:nil maxExtent:nil
 !
 
 mapView:aView id:aWindowId iconified:aBoolean atX:xPos y:yPos
-	width:w height:h minExtent:minExt maxExtent:maxExt
+        width:w height:h minExtent:minExt maxExtent:maxExt
     "make a window visible - either as icon or as a real view - needed for restart"
 
     ^ self subclassResponsibility
@@ -7000,17 +7001,17 @@
      This undoes the effect of #setCursors:"
 
     knownViews notNil ifTrue:[
-	knownViews validElementsDo:[:aView |
-	    |c vid cid|
-
-	    (vid := aView id) notNil ifTrue:[
-		c := aView cursor.
-		(c notNil and:[(cid := c id) notNil]) ifTrue:[
-		    self setCursor:cid in:vid
-		]
-	    ]
-	].
-	self flush
+        knownViews validElementsDo:[:aView |
+            |c vid cid|
+
+            (vid := aView id) notNil ifTrue:[
+                c := aView cursor.
+                (c notNil and:[(cid := c id) notNil]) ifTrue:[
+                    self setCursor:cid in:vid
+                ]
+            ]
+        ].
+        self flush
     ]
 
     "
@@ -7058,14 +7059,14 @@
 
     id := (aCursor onDevice:self) id.
     id notNil ifTrue:[
-	knownViews validElementsDo:[:aView |
-	    |vid|
-
-	    (vid := aView id) notNil ifTrue:[
-		self setCursor:id in:vid
-	    ]
-	].
-	self flush
+        knownViews validElementsDo:[:aView |
+            |vid|
+
+            (vid := aView id) notNil ifTrue:[
+                self setCursor:id in:vid
+            ]
+        ].
+        self flush
     ]
 
     "
@@ -7173,9 +7174,9 @@
     "define a bitmap to be used as icon"
 
     self
-	setWindowIcon:aForm 
-	mask:nil 
-	in:aWindowId
+        setWindowIcon:aForm 
+        mask:nil 
+        in:aWindowId
 !
 
 setWindowIcon:aForm mask:aMaskForm in:aWindowId
@@ -7197,12 +7198,12 @@
     |minW minH maxW maxH|
 
     minExt notNil ifTrue:[
-	minW := minExt x.
-	minH := minExt y.
+        minW := minExt x.
+        minH := minExt y.
     ].
     maxExt notNil ifTrue:[
-	maxW := maxExt x.
-	maxH := maxExt y.
+        maxW := maxExt x.
+        maxH := maxExt y.
     ].
     self setWindowMinExtentX:minW y:minH maxExtentX:maxW y:maxH in:aWindowId
 !
@@ -7246,6 +7247,6 @@
 !DeviceWorkstation class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /cvs/stx/stx/libview/DeviceWorkstation.st,v 1.389 2001-01-08 17:33:01 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libview/DeviceWorkstation.st,v 1.390 2001-01-09 16:03:56 penk Exp $'
 ! !
 DeviceWorkstation initialize!