Debugger UI improvements
authorJan Vrany <jan.vrany@fit.cvut.cz>
Thu, 08 Jun 2017 13:43:34 +0100
changeset 44 41cc5a7840fe
parent 43 c98aa29401f7
child 45 cd9f46746fd1
Debugger UI improvements * fixed exec-button enablements in main debugger UI * improved thread group (inferior) presentation to show whether it has finished or it has been terminated prematurely. * added option to flush event log in log view * added option to enable frame filters and pretty printing for VDB UI (i.e, when enabled VDB shows pretty printed values and frames in backtrace list view and frame view * use code font in both hacktrace view and frame view (code font is likely non-proportional and this makes things easier to read when pretty printer / frame decorator formats additional info in "columns" * doubleclick on variable copies the value to clipboard
VDBAbstractConsoleApplication.st
VDBAbstractListApplication.st
VDBAbstractTreeApplication.st
VDBDebuggerApplication.st
VDBEventLogApplication.st
VDBFrameApplication.st
VDBInferiorConsoleApplication.st
VDBModelPresenter.st
VDBSourceApplication.st
VDBThreadGroupPresenter.st
VDBVariablePresenter.st
--- a/VDBAbstractConsoleApplication.st	Thu Jun 08 14:16:29 2017 +0100
+++ b/VDBAbstractConsoleApplication.st	Thu Jun 08 13:43:34 2017 +0100
@@ -94,7 +94,9 @@
     consoleView isNil ifTrue:[ 
         consoleView :=VT100TerminalView new.
         consoleView foregroundColor: Color white
-                    backgroundColor: Color black.
+                    backgroundColor: Color black;
+                    cursorForegroundColor: Color white
+                          backgroundColor: Color white.
         debugger notNil ifTrue:[ 
             consoleView inStream: self consoleInput.
             consoleView outStream: self consoleOutput.
@@ -104,7 +106,7 @@
     ^ consoleView
 
     "Created: / 06-06-2014 / 21:33:14 / Jan Vrany <jan.vrany@fit.cvut.cz>"
-    "Modified: / 01-06-2017 / 09:44:56 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+    "Modified: / 06-06-2017 / 13:57:34 / Jan Vrany <jan.vrany@fit.cvut.cz>"
 ! !
 
 !VDBAbstractConsoleApplication methodsFor:'initialization & release'!
--- a/VDBAbstractListApplication.st	Thu Jun 08 14:16:29 2017 +0100
+++ b/VDBAbstractListApplication.st	Thu Jun 08 13:43:34 2017 +0100
@@ -9,6 +9,85 @@
 	category:'VDB-UI-Abstract'
 !
 
+!VDBAbstractListApplication class methodsFor:'interface specs'!
+
+columnsSpec
+    ^ #()
+
+    "Created: / 02-06-2017 / 07:26:32 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+! !
+
+!VDBAbstractListApplication class methodsFor:'menu specs'!
+
+contextMenu
+    "This resource specification was automatically generated
+     by the MenuEditor of ST/X."
+
+    "Do not manually edit this!! If it is corrupted,
+     the MenuEditor may not be able to read the specification."
+
+
+    "
+     MenuEditor new openOnClass:VDBStackApplication andSelector:#contextMenu
+     (Menu new fromLiteralArrayEncoding:(VDBStackApplication contextMenu)) startUp
+    "
+
+    <resource: #menu>
+
+    ^ 
+     #(Menu
+        (
+         (MenuItem
+            label: 'Menu Slice'
+            submenuChannel: contextMenuInspectSlice
+            isMenuSlice: true
+          )
+         )
+        nil
+        nil
+      )
+!
+
+contextMenuInspectSlice
+    "This resource specification was automatically generated
+     by the MenuEditor of ST/X."
+
+    "Do not manually edit this!! If it is corrupted,
+     the MenuEditor may not be able to read the specification."
+
+
+    "
+     MenuEditor new openOnClass:VDBAbstractListApplication andSelector:#contextMenuInspectSlice
+     (Menu new fromLiteralArrayEncoding:(VDBAbstractListApplication contextMenuInspectSlice)) startUp
+    "
+
+    <resource: #menu>
+
+    ^ 
+     #(Menu
+        (
+         (MenuItem
+            enabled: hasSelection
+            label: 'Inspect Model'
+            itemValue: doInspectModel
+          )
+         (MenuItem
+            label: 'Inspect Presenter'
+            itemValue: doInspectPresenter
+          )
+         (MenuItem
+            label: '-'
+          )
+         (MenuItem
+            label: 'Update'
+            itemValue: duUpdateList
+          )
+         )
+        nil
+        nil
+      )
+! !
+
 !VDBAbstractListApplication class methodsFor:'queries'!
 
 isAbstract
@@ -19,6 +98,27 @@
     ^ self == VDBAbstractListApplication.
 ! !
 
+!VDBAbstractListApplication methodsFor:'actions'!
+
+postBuildInternalListView: aView
+    <resource: #uiCallback>
+
+    | columns |
+
+    internalListView := aView.
+    internalListView font: CodeView defaultFont.
+
+    columns := self class columnsSpec.
+    columns notEmptyOrNil ifTrue:[
+        | renderer |
+
+        renderer := aView setupTableRenderer.
+        renderer columnDescriptors: columns
+    ].
+
+    "Modified: / 11-06-2017 / 22:16:54 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+! !
+
 !VDBAbstractListApplication methodsFor:'aspects-private'!
 
 internalListHolder
@@ -91,11 +191,43 @@
 
     "Created: / 18-09-2014 / 00:29:21 / Jan Vrany <jan.vrany@fit.cvut.cz>"
     "Modified: / 20-09-2014 / 23:50:11 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+! !
+
+!VDBAbstractListApplication methodsFor:'menu'!
+
+contextMenu
+    ^ builder menuFor: #contextMenu
+
+    "Created: / 12-06-2017 / 12:02:29 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+! !
+
+!VDBAbstractListApplication methodsFor:'menu actions'!
+
+doInspectModel
+    | selection |
+
+    selection := self internalSelectionHolder value.
+    selection notEmptyOrNil ifTrue:[ 
+        selection isThreadGroupPresenter ifTrue: [ selection threadGroup inspect ].
+        selection isThreadPresenter ifTrue: [ selection thread inspect ].
+        selection isFramePresenter ifTrue: [ selection frame inspect ].    
+        selection isVariablePresenter ifTrue: [ selection variable inspect ].    
+    ].
+
+    "Modified: / 02-06-2017 / 00:05:16 / Jan Vrany <jan.vrany@fit.cvut.cz>"
 !
 
-postBuildInternalListView: aView
-    internalListView := aView
+doInspectPresenter
+    self internalSelectionHolder value inspect
+
+    "Modified: / 22-09-2014 / 01:17:52 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+!
 
-    "Modified: / 30-09-2014 / 00:00:28 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+duUpdateList
+    <resource: #uiCallback>
+
+    self enqueueDelayedUpdateInternalList
+
+    "Modified: / 12-06-2017 / 12:00:53 / Jan Vrany <jan.vrany@fit.cvut.cz>"
 ! !
 
--- a/VDBAbstractTreeApplication.st	Thu Jun 08 14:16:29 2017 +0100
+++ b/VDBAbstractTreeApplication.st	Thu Jun 08 13:43:34 2017 +0100
@@ -9,14 +9,9 @@
 	category:'VDB-UI-Abstract'
 !
 
+
 !VDBAbstractTreeApplication class methodsFor:'interface specs'!
 
-columnsSpec
-    ^ #()
-
-    "Created: / 02-06-2017 / 07:26:32 / Jan Vrany <jan.vrany@fit.cvut.cz>"
-!
-
 windowSpec
     "This resource specification was automatically generated
      by the UIPainter of ST/X."
@@ -25,9 +20,9 @@
      the UIPainter may not be able to read the specification."
 
     "
-     UIPainter new openOnClass:VDBStackApplication andSelector:#windowSpec
-     VDBStackApplication new openInterface:#windowSpec
-     VDBStackApplication open
+     UIPainter new openOnClass:VDBAbstractTreeApplication andSelector:#windowSpec
+     VDBAbstractTreeApplication new openInterface:#windowSpec
+     VDBAbstractTreeApplication open
     "
 
     <resource: #canvas>
@@ -55,6 +50,7 @@
              listModel: internalListHolder
              useIndex: false
              highlightMode: line
+             doubleClickSelector: doDoubleClick
              showLines: false
              useDefaultIcons: false
              showRoot: false
@@ -66,70 +62,23 @@
      )
 ! !
 
-!VDBAbstractTreeApplication class methodsFor:'menu specs'!
-
-contextMenu
-    "This resource specification was automatically generated
-     by the MenuEditor of ST/X."
-
-    "Do not manually edit this!! If it is corrupted,
-     the MenuEditor may not be able to read the specification."
-
-
-    "
-     MenuEditor new openOnClass:VDBStackApplication andSelector:#contextMenu
-     (Menu new fromLiteralArrayEncoding:(VDBStackApplication contextMenu)) startUp
-    "
+!VDBAbstractTreeApplication class methodsFor:'plugIn spec'!
 
-    <resource: #menu>
+aspectSelectors
+    "This resource specification was automatically generated
+     by the UIPainter of ST/X."
 
-    ^ 
-     #(Menu
-        (
-         (MenuItem
-            label: 'Menu Slice'
-            submenuChannel: contextMenuInspectSlice
-            isMenuSlice: true
-          )
-         )
-        nil
-        nil
-      )
-!
+    "Do not manually edit this. If it is corrupted,
+     the UIPainter may not be able to read the specification."
 
-contextMenuInspectSlice
-    "This resource specification was automatically generated
-     by the MenuEditor of ST/X."
-
-    "Do not manually edit this!! If it is corrupted,
-     the MenuEditor may not be able to read the specification."
-
-
-    "
-     MenuEditor new openOnClass:VDBStackApplication andSelector:#contextMenu
-     (Menu new fromLiteralArrayEncoding:(VDBStackApplication contextMenu)) startUp
-    "
-
-    <resource: #menu>
+    "Return a description of exported aspects;
+     these can be connected to aspects of an embedding application
+     (if this app is embedded in a subCanvas)."
 
-    ^ 
-     #(Menu
-        (
-         (MenuItem
-            enabled: hasSelection
-            label: 'Inspect Model'
-            itemValue: doInspectModel
-          )
-         (MenuItem
-            label: 'Inspect Presenter'
-            itemValue: doInspectPresenter
-          )
-         )
-        nil
-        nil
-      )
+    ^ #(
+        #debuggerHolder
+      ).
 
-    "Created: / 02-06-2017 / 00:00:50 / Jan Vrany <jan.vrany@fit.cvut.cz>"
 ! !
 
 !VDBAbstractTreeApplication class methodsFor:'queries'!
@@ -144,20 +93,10 @@
 
 !VDBAbstractTreeApplication methodsFor:'actions'!
 
-postBuildInternalListView: aView
-    <resource: #uiCallback>
-
-    | columns |
-
-    columns := self class columnsSpec.
-    columns notEmptyOrNil ifTrue:[
-        | renderer |
-
-        renderer := aView setupTableRenderer.
-        renderer columnDescriptors: columns
-    ].
-
-    "Modified (format): / 02-06-2017 / 07:30:03 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+doDoubleClick
+    "Invoked when user double-clicks to list item.
+     Nothing by default, subclasses may override."
+    "Modified: / 13-06-2017 / 17:08:36 / Jan Vrany <jan.vrany@fit.cvut.cz>"
 ! !
 
 !VDBAbstractTreeApplication methodsFor:'aspects-private'!
@@ -167,33 +106,20 @@
 
     internalListHolder isNil ifTrue:[
         internalListHolder := HierarchicalList new.
+        internalListHolder application: self.
         internalListHolder showRoot: false.
         internalListHolder root: HierarchicalItem new.
     ].
     ^ internalListHolder
 
     "Created: / 20-09-2014 / 23:03:07 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+    "Modified: / 06-06-2017 / 23:33:07 / Jan Vrany <jan.vrany@fit.cvut.cz>"
 ! !
 
-!VDBAbstractTreeApplication methodsFor:'menu actions'!
-
-doInspectModel
-    | selection |
+!VDBAbstractTreeApplication class methodsFor:'documentation'!
 
-    selection := self internalSelectionHolder value.
-    selection notEmptyOrNil ifTrue:[ 
-        selection isThreadGroupPresenter ifTrue: [ selection threadGroup inspect ].
-        selection isThreadPresenter ifTrue: [ selection thread inspect ].
-        selection isFramePresenter ifTrue: [ selection frame inspect ].    
-        selection isVariablePresenter ifTrue: [ selection variable inspect ].    
-    ].
+version_HG
 
-    "Modified: / 02-06-2017 / 00:05:16 / Jan Vrany <jan.vrany@fit.cvut.cz>"
-!
-
-doInspectPresenter
-    self internalSelectionHolder value inspect
-
-    "Modified: / 22-09-2014 / 01:17:52 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+    ^ '$Changeset: <not expanded> $'
 ! !
 
--- a/VDBDebuggerApplication.st	Thu Jun 08 14:16:29 2017 +0100
+++ b/VDBDebuggerApplication.st	Thu Jun 08 13:43:34 2017 +0100
@@ -6,14 +6,24 @@
 	instanceVariableNames:'layoutSpecHolder selectedThreadGroupHolder selectedThreadHolder
 		selectedFrameHolder containerBottom canExecRestartHolder
 		canExecResumeHolder canExecRunHolder canExecStepIntoHolder
-		canExecStepOverHolder canExecStepReturn canExecSuspendHolder
-		canExecTerminateHolder'
+		canExecStepOverHolder canExecStepReturnHolder
+		canExecSuspendHolder canExecTerminateHolder'
 	classVariableNames:''
 	poolDictionaries:''
 	category:'VDB-UI'
 !
 
 
+!VDBDebuggerApplication class methodsFor:'initialization'!
+
+initializeDefaultKeyboardMap
+    defaultKeyboardMap := DebugView defaultKeyboardMap copy.
+    defaultKeyboardMap bindValue: #DebuggerRestart to: ('Ctrl', (defaultKeyboardMap bindingForLogical: #DebuggerContinue)) asSymbol.
+
+    "Created: / 05-06-2017 / 23:01:45 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+    "Modified: / 11-06-2017 / 20:08:05 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+! !
+
 !VDBDebuggerApplication class methodsFor:'interface opening'!
 
 open
@@ -115,7 +125,7 @@
                       )
                     
                    )
-                   handles: (Any 0.7 1.0)
+                   handles: (Any 0.5 1.0)
                  )
                 (SubCanvasSpec
                    name: 'SourceCanvas'
@@ -160,7 +170,7 @@
        )
      )
 
-    "Modified: / 27-02-2015 / 16:08:40 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+    "Modified: / 06-06-2017 / 08:12:55 / Jan Vrany <jan.vrany@fit.cvut.cz>"
 !
 
 layoutSingleSpec
@@ -299,6 +309,7 @@
             enabled: canExecResumeHolder
             label: 'Resume'
             itemValue: doExecResume
+            shortcutKey: DebuggerContinue
             labelImage: (ResourceRetriever VDBIconLibrary actionContinue16x16 'Resume')
           )
          (MenuItem
@@ -317,6 +328,7 @@
             enabled: canExecRestartHolder
             label: 'Restart'
             itemValue: doExecRestart
+            shortcutKey: DebuggerRestart
             labelImage: (ResourceRetriever VDBIconLibrary actionTerminateAndRun6x16 'Restart')
           )
          (MenuItem
@@ -326,16 +338,18 @@
             enabled: canExecStepOverHolder
             label: 'Step Over'
             itemValue: doExecStepOver
+            shortcutKey: DebuggerNext
             labelImage: (ResourceRetriever VDBIconLibrary actionStepOver6x16 'Step Over')
           )
          (MenuItem
             enabled: canExecStepIntoHolder
             label: 'Step Into'
             itemValue: doExecStepInto
+            shortcutKey: DebuggerSend
             labelImage: (ResourceRetriever VDBIconLibrary actionStepInto6x16 'Step Into')
           )
          (MenuItem
-            enabled: canExecStepReturn
+            enabled: canExecStepReturnHolder
             label: 'Step Return'
             itemValue: doExecStepReturn
             labelImage: (ResourceRetriever VDBIconLibrary actionStepReturn6x16 'Step Return')
@@ -344,8 +358,6 @@
         nil
         nil
       )
-
-    "Modified: / 23-09-2014 / 09:28:22 / Jan Vrany <jan.vrany@fit.cvut.cz>"
 !
 
 mainMenu
@@ -392,15 +404,33 @@
             submenuChannel: execMenu
           )
          (MenuItem
-            label: 'Window'
+            label: 'View'
             submenu: 
            (Menu
               (
                (MenuItem
                   label: 'Stack'
-                  itemValue: doWindowOpen:
+                  itemValue: doViewOpenClass:
                   argument: VDBStackApplication
                 )
+               (MenuItem
+                  label: 'Frame'
+                  itemValue: doViewOpenClass:
+                  argument: VDBFrameApplication
+                )
+               (MenuItem
+                  label: '-'
+                )
+               (MenuItem
+                  enabled: canViewEnableFrameFilters
+                  label: 'Enable Frame Filters'
+                  itemValue: doViewEnableFrameFilters
+                )
+               (MenuItem
+                  enabled: canViewEnablePrettyPrinting
+                  label: 'Enable Pretty Printing'
+                  itemValue: doViewEnablePrettyPrinting
+                )
                )
               nil
               nil
@@ -424,8 +454,12 @@
                   label: '-'
                 )
                (MenuItem
-                  label: 'Reopen Window'
-                  itemValue: doDebugReopenWindow
+                  label: 'Reopen'
+                  itemValue: doDebugReopenDebugger
+                )
+               (MenuItem
+                  label: 'Launcher'
+                  itemValue: doDebugReopenLauncher
                 )
                )
               nil
@@ -515,7 +549,7 @@
          (MenuItem
             enabled: canExecStepOverHolder
             label: 'Step Over'
-            itemValue: doExecStepOverRun
+            itemValue: doExecStepOver
             labelImage: (ResourceRetriever VDBIconLibrary actionStepOver6x16)
           )
          (MenuItem
@@ -559,6 +593,35 @@
     "Modified: / 01-06-2017 / 23:32:13 / Jan Vrany <jan.vrany@fit.cvut.cz>"
 ! !
 
+!VDBDebuggerApplication methodsFor:'accessing'!
+
+currentThreadGroup
+    "Return 'current' thread group (inferior) or nil. 'Current' thread group is
+     either the selected one or, if none's selected or the only one thread group
+     (if there's only one)"
+
+    | tg |
+
+    tg := self selectedThreadGroup.
+    tg isNil ifTrue:[
+        | tgs |
+
+        tgs := debugger inferiors.
+        tgs size == 1 ifTrue:[ 
+            tg := tgs anyOne.
+        ].
+    ].
+    ^ tg.
+
+    "Created: / 03-07-2017 / 06:58:06 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+!
+
+selectedThreadGroup
+    ^ self selectedThreadGroupHolder value
+
+    "Created: / 03-07-2017 / 06:51:02 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+! !
+
 !VDBDebuggerApplication methodsFor:'aspects'!
 
 layoutSpecHolder
@@ -720,23 +783,25 @@
 !
 
 updateButtonEnablements
-    | inferior inferiorIsStopped |
+    | inferior inferiorIsStopped inferiorIsRunning |
 
-    inferior := self selectedThreadGroupHolder value.
+    inferior := self currentThreadGroup.
     inferiorIsStopped := inferior notNil and:[ inferior isStopped ].
+    inferiorIsRunning := inferior notNil and:[ inferior isRunning ].
 
-    self canExecResumeHolder value: ( inferiorIsStopped ).
-    self canExecStepIntoHolder value: ( inferiorIsStopped ).
-    self canExecStepOverHolder value: ( inferiorIsStopped ). 
-    self canExecStepReturn value: ( inferiorIsStopped ).
-    self canExecSuspendHolder value: ( inferiorIsStopped not ).
+    self canExecResumeHolder value:     inferiorIsRunning & inferiorIsStopped .
+    self canExecStepIntoHolder value:   inferiorIsRunning & inferiorIsStopped.
+    self canExecStepOverHolder value:   inferiorIsRunning & inferiorIsStopped.
+    self canExecStepReturnHolder value: inferiorIsRunning & inferiorIsStopped.
+    self canExecSuspendHolder value:    inferiorIsRunning &(inferiorIsStopped not).
 
-    self canExecTerminateHolder value: ( inferior notNil ).
-    self canExecRestartHolder value: ( inferior notNil ).
+    self canExecTerminateHolder value: ( inferiorIsRunning ).
+    self canExecRestartHolder value: ( true ).
 
-    self canExecRunHolder value: ( inferior isNil ).
+    self canExecRunHolder value: ( inferiorIsRunning not ).
 
     "Created: / 01-06-2017 / 23:18:09 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+    "Modified: / 03-07-2017 / 07:00:12 / Jan Vrany <jan.vrany@fit.cvut.cz>"
 ! !
 
 !VDBDebuggerApplication methodsFor:'event handling'!
@@ -776,16 +841,23 @@
 
 !VDBDebuggerApplication methodsFor:'initialization & release'!
 
+commonPostOpen
+    self updateButtonEnablements
+
+    "Created: / 05-06-2017 / 22:50:35 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+!
+
 release
     "remove all dependencies from the receiver"
 
     super release.
     self unsubscribe.
-    debugger isConnected ifTrue:[ 
+    (debugger notNil and:[debugger isConnected]) ifTrue:[ 
         debugger send: GDBMI_gdb_exit new andWait: false.
     ].
 
     "Created: / 01-06-2017 / 13:41:15 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+    "Modified: / 12-06-2017 / 12:48:08 / Jan Vrany <jan.vrany@fit.cvut.cz>"
 !
 
 subscribe   
@@ -804,11 +876,23 @@
 
 !VDBDebuggerApplication methodsFor:'menu actions'!
 
-doDebugReopenWindow
+doDebugReopenDebugger
+    | d |
+
+    d := debugger.
+    self unsubscribe.
+    debugger := nil.
+    debuggerHolder setValue: nil.
     self closeDownViews.
-    (Smalltalk at: self class name) openFor: debugger.
+    (Smalltalk at: self class name) openFor: d.
+
+    "Created: / 20-06-2017 / 20:56:59 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+!
 
-    "Modified: / 21-09-2014 / 22:26:46 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+doDebugReopenLauncher
+    NewLauncher open
+
+    "Created: / 20-06-2017 / 20:58:01 / Jan Vrany <jan.vrany@fit.cvut.cz>"
 !
 
 doOpenExecutable
@@ -829,18 +913,22 @@
     "Modified: / 01-06-2017 / 13:46:42 / Jan Vrany <jan.vrany@fit.cvut.cz>"
 !
 
-doWindowOpen: applicationClassName        
-    | applicationClass application screen |
+doViewEnableFrameFilters
+    debugger enableFrameFilters.
+
+    "Modified (format): / 12-06-2017 / 09:42:42 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+!
 
-    applicationClass := Smalltalk at: applicationClassName asSymbol.
-    applicationClass isNil ifTrue:[ 
-        Dialog warn: ('No application class named %1' bindWith: applicationClassName).
-        ^ self.
-    ].
-    application := applicationClass new.
-    application debuggerHolder: self debuggerHolder.
+doViewEnablePrettyPrinting
+    debugger enablePrettyPrinting
+
+    "Modified: / 12-06-2017 / 09:42:05 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+!
+
+doViewOpen: application         
+    | screen |
+
     application open.
-
     "/ On X11, use ICCCM hints to tell the WM about a transient tool window
     "/ and let WM to handle this according to DE standards. It has the nice
     "/ side effect (on most modern WM) that these windows don't show up in
@@ -854,7 +942,22 @@
         screen setWindowType:#'_NET_WM_WINDOW_TYPE_UTILITY' in:application window topView id
     ].
 
-    "Modified: / 17-09-2014 / 23:36:48 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+    "Created: / 11-06-2017 / 20:21:35 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+!
+
+doViewOpenClass: applicationClassName        
+    | applicationClass application |
+
+    applicationClass := Smalltalk at: applicationClassName asSymbol.
+    applicationClass isNil ifTrue:[ 
+        Dialog warn: ('No application class named %1' bindWith: applicationClassName).
+        ^ self.
+    ].
+    application := applicationClass new.
+    application debuggerHolder: self debuggerHolder.
+    self doViewOpen: application
+
+    "Created: / 11-06-2017 / 20:21:07 / Jan Vrany <jan.vrany@fit.cvut.cz>"
 ! !
 
 !VDBDebuggerApplication methodsFor:'menu actions-exec'!
@@ -868,16 +971,9 @@
 doExecRestart
     <resource: #uiCallback>
 
-    "automatically generated by UIEditor ..."
+    self doExecTerminate; doExecRun.
 
-    "*** the code below performs no action"
-    "*** (except for some feedback on the Transcript)"
-    "*** Please change as required and accept in the browser."
-    "*** (and replace this comment by something more useful ;-)"
-
-    "action to be added ..."
-
-    Logger info:'action for #doExecRestart ...'.
+    "Modified: / 11-06-2017 / 20:12:57 / Jan Vrany <jan.vrany@fit.cvut.cz>"
 !
 
 doExecResume
@@ -917,10 +1013,23 @@
 !
 
 doExecTerminate
-    self shouldImplement.
-"/    self doExec: GDBMI_exec_abort new
+    self doExec: 'kill'
+
+    "Modified: / 05-06-2017 / 23:13:13 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+! !
+
+!VDBDebuggerApplication methodsFor:'menu apects'!
 
-    "Modified: / 30-09-2014 / 00:21:47 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+canViewEnableFrameFilters
+    ^ [ debugger isFrameFiltersEnabled not ]
+
+    "Modified: / 12-06-2017 / 09:54:02 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+!
+
+canViewEnablePrettyPrinting
+    ^ [ debugger isPrettyPrintingEnabled not ].
+
+    "Modified: / 12-06-2017 / 09:54:06 / Jan Vrany <jan.vrany@fit.cvut.cz>"
 ! !
 
 !VDBDebuggerApplication methodsFor:'menu aspects-exec'!
@@ -980,15 +1089,15 @@
     "Modified: / 01-06-2017 / 23:15:52 / Jan Vrany <jan.vrany@fit.cvut.cz>"
 !
 
-canExecStepReturn
+canExecStepReturnHolder
     "return/create the 'canExecStepReturn' value holder (automatically generated)"
 
-    canExecStepReturn isNil ifTrue:[
-        canExecStepReturn := ValueHolder with: false.
+    canExecStepReturnHolder isNil ifTrue:[
+        canExecStepReturnHolder := ValueHolder with: false.
     ].
-    ^ canExecStepReturn
+    ^ canExecStepReturnHolder
 
-    "Modified: / 01-06-2017 / 23:15:55 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+    "Created: / 05-06-2017 / 22:41:44 / Jan Vrany <jan.vrany@fit.cvut.cz>"
 !
 
 canExecSuspendHolder
--- a/VDBEventLogApplication.st	Thu Jun 08 14:16:29 2017 +0100
+++ b/VDBEventLogApplication.st	Thu Jun 08 13:43:34 2017 +0100
@@ -118,8 +118,12 @@
         (
          (MenuItem
             enabled: hasEventSelectedHolder
-            label: 'Inspect'
-            itemValue: eventMenuInspect
+            label: 'Inspect Event'
+            itemValue: doInspect
+          )
+         (MenuItem
+            label: 'Clear Events'
+            itemValue: doClear
           )
          )
         nil
@@ -220,11 +224,21 @@
 
 !VDBEventLogApplication methodsFor:'menu actions'!
 
-eventMenuInspect
+doClear
+    <resource: #uiCallback>
+
+    eventList removeAll
+
+    "Modified: / 11-06-2017 / 20:18:47 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+!
+
+doInspect
     | event |
 
     event := self eventSelectionHolder value.
-    event notNil ifTrue:[event inspect].
+    event notNil ifTrue:[
+        event inspect
+    ].
 
     "Modified: / 07-06-2014 / 14:36:26 / Jan Vrany <jan.vrany@fit.cvut.cz>"
 ! !
--- a/VDBFrameApplication.st	Thu Jun 08 14:16:29 2017 +0100
+++ b/VDBFrameApplication.st	Thu Jun 08 13:43:34 2017 +0100
@@ -25,19 +25,58 @@
     <resource: #tableColumns>
 
     ^#(
-       (DataSetColumnSpec
+      (DataSetColumnSpec
          label: 'Value'
          labelAlignment: left
          labelButtonType: Button
+         width: 1.0
          height: heightOfFirstRow
          menuFromApplication: false
          printSelector: value
+         backgroundSelector: backgroundColor
          showRowSeparator: false
          showColSeparator: false
        )
       )
+    
+! !
 
-    "Created: / 02-06-2017 / 07:25:38 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+!VDBFrameApplication class methodsFor:'menu specs'!
+
+contextMenu
+    "This resource specification was automatically generated
+     by the MenuEditor of ST/X."
+
+    "Do not manually edit this!! If it is corrupted,
+     the MenuEditor may not be able to read the specification."
+
+
+    "
+     MenuEditor new openOnClass:VDBFrameApplication andSelector:#contextMenu
+     (Menu new fromLiteralArrayEncoding:(VDBFrameApplication contextMenu)) startUp
+    "
+
+    <resource: #menu>
+
+    ^ 
+     #(Menu
+        (
+         (MenuItem
+            label: 'Copy Value'
+            itemValue: doCopyValue
+          )
+         (MenuItem
+            label: '-'
+          )
+         (MenuItem
+            label: 'Menu Slice'
+            submenuChannel: contextMenuInspectSlice
+            isMenuSlice: true
+          )
+         )
+        nil
+        nil
+      )
 ! !
 
 !VDBFrameApplication class methodsFor:'plugIn spec'!
@@ -76,6 +115,16 @@
     ^ self shouldImplement
 ! !
 
+!VDBFrameApplication methodsFor:'actions'!
+
+doDoubleClick
+    "Invoked when user double-clicks to list item."
+    
+    self doCopyValue
+
+    "Created: / 13-06-2017 / 17:09:46 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+! !
+
 !VDBFrameApplication methodsFor:'aspects'!
 
 frameHolder
@@ -198,3 +247,11 @@
     ^ self shouldImplement
 ! !
 
+!VDBFrameApplication methodsFor:'menu actions'!
+
+doCopyValue
+    internalListView setClipboardText: (self selectedVariableHolder value varobj value)
+
+    "Modified: / 13-06-2017 / 14:58:48 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+! !
+
--- a/VDBInferiorConsoleApplication.st	Thu Jun 08 14:16:29 2017 +0100
+++ b/VDBInferiorConsoleApplication.st	Thu Jun 08 13:43:34 2017 +0100
@@ -10,50 +10,6 @@
 !
 
 
-!VDBInferiorConsoleApplication class methodsFor:'interface specs'!
-
-windowSpec
-    "This resource specification was automatically generated
-     by the UIPainter of ST/X."
-
-    "Do not manually edit this!! If it is corrupted,
-     the UIPainter may not be able to read the specification."
-
-    "
-     UIPainter new openOnClass:VDBConsoleApplication andSelector:#windowSpec
-     VDBConsoleApplication new openInterface:#windowSpec
-     VDBConsoleApplication open
-    "
-
-    <resource: #canvas>
-
-    ^ 
-    #(FullSpec
-       name: windowSpec
-       window: 
-      (WindowSpec
-         label: 'Inferior Console'
-         name: 'Inferior Console'
-         min: (Point 10 10)
-         bounds: (Rectangle 0 0 782 332)
-       )
-       component: 
-      (SpecCollection
-         collection: (
-          (ArbitraryComponentSpec
-             name: 'Console'
-             layout: (LayoutFrame 0 0 0 0 0 1 0 1)
-             hasBorder: false
-             component: consoleView
-           )
-          )
-        
-       )
-     )
-
-    "Modified: / 09-06-2014 / 09:57:38 / Jan Vrany <jan.vrany@fit.cvut.cz>"
-! !
-
 !VDBInferiorConsoleApplication class methodsFor:'startup-web applications'!
 
 initialPageSpec
--- a/VDBModelPresenter.st	Thu Jun 08 14:16:29 2017 +0100
+++ b/VDBModelPresenter.st	Thu Jun 08 13:43:34 2017 +0100
@@ -10,6 +10,20 @@
 !
 
 
+!VDBModelPresenter methodsFor:'accessing'!
+
+backgroundColor
+    | app |
+
+    app := self application.
+    app notNil ifTrue:[ 
+        ^ app perform: #backgroundColorFor: with: self ifNotUnderstood: [ nil ].
+    ].
+    ^ nil
+
+    "Created: / 06-06-2017 / 23:38:37 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+! !
+
 !VDBModelPresenter methodsFor:'change & update'!
 
 updateChildren
@@ -20,6 +34,14 @@
     "Created: / 21-09-2014 / 23:43:20 / Jan Vrany <jan.vrany@fit.cvut.cz>"
 ! !
 
+!VDBModelPresenter methodsFor:'displaying'!
+
+displayString
+    ^ self label
+
+    "Created: / 10-06-2017 / 12:24:38 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+! !
+
 !VDBModelPresenter methodsFor:'testing'!
 
 isFramePresenter
--- a/VDBSourceApplication.st	Thu Jun 08 14:16:29 2017 +0100
+++ b/VDBSourceApplication.st	Thu Jun 08 13:43:34 2017 +0100
@@ -184,7 +184,7 @@
         frame notNil ifTrue:[ 
             | line |
 
-            self sourceFileHolder value: frame fullname.
+            self sourceFileHolder value: frame file.
             line := frame line.
             line notNil ifTrue:[  
                 sourceView selectLine: line.
@@ -210,7 +210,7 @@
     ].
     super update:aspect with:param from:sender
 
-    "Modified: / 21-09-2014 / 00:15:31 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+    "Modified: / 11-06-2017 / 20:57:48 / Jan Vrany <jan.vrany@fit.cvut.cz>"
 ! !
 
 !VDBSourceApplication class methodsFor:'documentation'!
--- a/VDBThreadGroupPresenter.st	Thu Jun 08 14:16:29 2017 +0100
+++ b/VDBThreadGroupPresenter.st	Thu Jun 08 13:43:34 2017 +0100
@@ -23,31 +23,38 @@
 !
 
 label
-    | pidOrEmpty state |
+    | executableOrThreadGrouppId pidOrEmpty state |
+
+    threadGroup executable notNil ifTrue:[ 
+        executableOrThreadGrouppId := threadGroup executable contractTo: 30 
+    ] ifFalse:[ 
+        executableOrThreadGrouppId := 'thread group ', threadGroup id.
+    ].
 
     (threadGroup type = 'process' and:[ threadGroup pid notNil ]) ifTrue:[
         pidOrEmpty := 'pid ', threadGroup pid printString , ', '.
     ].
+    threadGroup isStopped ifTrue:[ 
+        state := 'stopped'
+    ] ifFalse:[ 
     threadGroup isRunning ifTrue:[ 
         state := 'running'
     ] ifFalse:[ 
-        threadGroup isStopped ifTrue:[ 
-            state := 'stopped'
-        ] ifFalse:[ 
-            threadGroup isDead ifTrue:[ 
-                state := 'terminated'
-            ] ifFalse:[
-                state := 'not run'
-            ]
-        ].
-    ].
+    threadGroup isFinished ifTrue:[ 
+        state := 'finished'
+    ] ifFalse:[ 
+    threadGroup isTerminated ifTrue:[ 
+        state := 'terminated'
+    ] ifFalse:[ 
+        state := 'not run'
+    ]]]].
 
-    ^ 'thread group %1 [%2%3]' bindWith: threadGroup id 
-                                   with: pidOrEmpty ? ''
-                                   with: state
+    ^ '%1 [%2%3]' bindWith: executableOrThreadGrouppId 
+                      with: pidOrEmpty ? ''
+                      with: state
 
     "Created: / 22-09-2014 / 00:14:26 / Jan Vrany <jan.vrany@fit.cvut.cz>"
-    "Modified: / 02-03-2015 / 06:58:19 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+    "Modified: / 07-06-2017 / 07:47:48 / Jan Vrany <jan.vrany@fit.cvut.cz>"
 !
 
 threadGroup
--- a/VDBVariablePresenter.st	Thu Jun 08 14:16:29 2017 +0100
+++ b/VDBVariablePresenter.st	Thu Jun 08 13:43:34 2017 +0100
@@ -18,9 +18,16 @@
 !
 
 value
-    ^ variable value
+    ^ variable valueString
 
     "Created: / 02-06-2017 / 07:32:38 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+    "Modified: / 11-06-2017 / 23:25:54 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+!
+
+valueString
+    ^ variable valueString
+
+    "Created: / 11-06-2017 / 23:25:28 / Jan Vrany <jan.vrany@fit.cvut.cz>"
 !
 
 variable