care for bad emphasis when displaying.
authorClaus Gittinger <cg@exept.de>
Wed, 07 Jul 1999 01:58:49 +0200
changeset 762 59768d57ab94
parent 761 d77e2c17f2a1
child 763 765361446bb7
care for bad emphasis when displaying.
Text.st
--- a/Text.st	Wed Jul 07 00:27:28 1999 +0200
+++ b/Text.st	Wed Jul 07 01:58:49 1999 +0200
@@ -713,20 +713,22 @@
                         ifFalse:[
                             (entry isMemberOf:Association) ifTrue:[
                                 value := entry value.
-                                k := entry key.
-                                k == #color ifTrue:[
-                                    color := value onDevice:device.
-                                    entry value:color.
-                                ] ifFalse:[k == #backgroundColor ifTrue:[
-                                    bgPaint := value onDevice:device.
-                                    entry value:bgPaint.
-                                ] ifFalse:[k == #underlineColor ifTrue:[
-                                    ulPaint := value onDevice:device.
-                                    entry value:ulPaint.
-                                ] ifFalse:[k == #strikeoutColor ifTrue:[
-                                    strikePaint := value onDevice:device.
-                                    entry value:ulPaint.
-                                ]]]]
+                                value notNil ifTrue:[
+                                    k := entry key.
+                                    k == #color ifTrue:[
+                                        color := value onDevice:device.
+                                        entry value:color.
+                                    ] ifFalse:[k == #backgroundColor ifTrue:[
+                                        bgPaint := value onDevice:device.
+                                        entry value:bgPaint.
+                                    ] ifFalse:[k == #underlineColor ifTrue:[
+                                        ulPaint := value onDevice:device.
+                                        entry value:ulPaint.
+                                    ] ifFalse:[k == #strikeoutColor ifTrue:[
+                                        strikePaint := value onDevice:device.
+                                        entry value:ulPaint.
+                                    ]]]]
+                                ]
                             ]
                         ]]]]]]]]]]
                     ]
@@ -1267,6 +1269,6 @@
 !Text class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /cvs/stx/stx/libbasic2/Text.st,v 1.56 1999-07-06 22:27:28 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libbasic2/Text.st,v 1.57 1999-07-06 23:58:49 cg Exp $'
 ! !
 Text initialize!