#FEATURE by cg
authorClaus Gittinger <cg@exept.de>
Wed, 04 Jul 2018 00:50:00 +0200
changeset 18259 aaf5a643cbf5
parent 18258 9e6191c6f22f
child 18260 45d354b02ade
#FEATURE by cg class: InspectorView changed: #valueForSpecialLine:
InspectorView.st
--- a/InspectorView.st	Tue Jul 03 03:33:28 2018 +0000
+++ b/InspectorView.st	Wed Jul 04 00:50:00 2018 +0200
@@ -1,5 +1,3 @@
-"{ Encoding: utf8 }"
-
 "
  COPYRIGHT (c) 1989 by Claus Gittinger
               All Rights Reserved
@@ -3092,7 +3090,7 @@
         "/ this is returned by collection-inspectors,
         "/ when a field-index for a no-longer-present-index is selected
         "/ (eg. if an OrderedCollection growed to a smaller size in the meantime)
-        ^ '«element no longer present»' withColor:Color grey.
+        ^ '«element no longer present»' withColor:Color grey.
     ].
 
     idx := self theSingleSelectionIndex.
@@ -3392,8 +3390,8 @@
     d := self derivedFields.
     (d isDictionary) ifTrue:[
         actionItems := d keys select:[:k | k first == $!!] as:OrderedCollection .
-        valueItems := d keys select:[:k | '-¤' includes:k first] as:OrderedCollection.
-        otherItems := d keys select:[:k | ('!!-¤' includes: k first) not] as:OrderedCollection.
+        valueItems := d keys select:[:k | '-¤' includes:k first] as:OrderedCollection.
+        otherItems := d keys select:[:k | ('!!-¤' includes: k first) not] as:OrderedCollection.
         ^ ((actionItems sort , valueItems sort) collect:[:k | (k copyTo:1),(k copyFrom:2) allItalic])
           ,
           otherItems sort
@@ -4034,7 +4032,7 @@
     ].
 
     "/ another special (pseudo) entries?
-    (lineEntry startsWith:$¤) ifTrue:[
+    (lineEntry startsWith:$¤) ifTrue:[
         ^ self valueForSpecialLine:lineEntry
     ].
 
@@ -4094,11 +4092,16 @@
 !
 
 valueForSpecialLine:line
-    |idx fieldEntry extraAttributes fields|
+    |idx fieldEntry extraAttributes fields fieldValue|
 
     extraAttributes := self myObjectsInspectorExtraAttributes.
     (extraAttributes includesKey:line) ifTrue:[
-        ^ (extraAttributes at:line) value
+        Error handle:[:ex |
+            fieldValue := 'Error: ',ex description
+        ] do:[
+            fieldValue := (extraAttributes at:line) value
+        ].
+        ^ fieldValue
     ].
 
     idx := self derivedFieldNames findFirst:[:l | l string = line string ].
@@ -4166,6 +4169,7 @@
 
     "Created: / 31-10-2001 / 09:17:45 / cg"
     "Modified: / 06-06-2012 / 11:57:54 / cg"
+    "Modified: / 04-07-2018 / 00:24:10 / Claus Gittinger"
 ! !
 
 !InspectorView methodsFor:'queries'!
@@ -4439,7 +4443,7 @@
 !
 
 tryToSelectKeyNamed:aString
-    "called from the debugger to try to select the previousöy selected
+    "called from the debugger to try to select the previousöy selected
      field (by name)"
      
     |list idx aStringWithSpace|