diff options
| -rw-r--r-- | init.go | 33 | ||||
| -rw-r--r-- | stdoutShow.go | 5 | ||||
| -rw-r--r-- | treeAdd.go | 2 |
3 files changed, 12 insertions, 28 deletions
@@ -40,26 +40,15 @@ func toolkitInit() { w.dumpTree("MM") w.dumpWindows("WW") + // SETUP HELP START me.baseGui.Update(testRefresh) log.Info("gocui toolkitInit() trying showHelp() me.ok =", me.ok) showHelp() - log.Info("gocui toolkitInit() trying showHelp() me.ok =", me.ok) hideHelp() - log.Info("gocui toolkitInit() trying showHelp() me.ok =", me.ok) showHelp() - /* - if me.stdout.outputOnTop { - me.stdout.outputOnTop = false - setThingsOnTop() - } else { - me.stdout.outputOnTop = true - setThingsOnTop() - } - relocateStdoutOffscreen() - log.Info("refresh triggered") - */ - // me.newWindowTrigger <- me.treeRoot.TK.(*guiWidget) - // time.Sleep(1 * time.Second) + // SETUP HELP END + + // SETUP STDOUT START time.Sleep(300 * time.Millisecond) log.Info("gocui toolkitInit() me.ok =", me.ok) me.baseGui.Update(testRefresh) @@ -68,11 +57,12 @@ func toolkitInit() { me.stdout.init = true relocateStdoutOffscreen() } - time.Sleep(1 * time.Second) me.stdout.outputOnTop = false setThingsOnTop() + // SETUP STDOUT END + // PUT INIT DEBUG COOE HERE var toggle bool for i := 0; i < 3; i++ { w := me.treeRoot.TK.(*guiWidget) @@ -88,9 +78,9 @@ func toolkitInit() { log.Info("gocui toolkitInit() put testing false stuff here") } } - log.Info("gocui toolkitInit() trying showHelp() me.ok =", me.ok) - showHelp() + // PUT INIT DEBUG COOE HERE END + // TEST TEXTBOX START time.Sleep(1 * time.Second) log.Info("gocui toolkitInit() me.ok =", me.ok) me.baseGui.Update(testRefresh) @@ -99,12 +89,7 @@ func toolkitInit() { initTextbox() me.textbox.tk.prepTextbox() } - // tk.makeWindowActive() - - time.Sleep(1 * time.Second) - log.Info("gocui toolkitInit() me.ok =", me.ok) - // me.baseGui.Close() - // os.Exit(-1) + // TEST TEXTBOX END } func toolkitClose() { diff --git a/stdoutShow.go b/stdoutShow.go index 75a4ae5..68ec55b 100644 --- a/stdoutShow.go +++ b/stdoutShow.go @@ -161,13 +161,15 @@ func (w stdout) Write(p []byte) (n int, err error) { lines := strings.Split(strings.TrimSpace(string(p)), "\n") me.stdout.outputS = append(me.stdout.outputS, lines...) + fmt.Fprint(outf, string(p)) return len(p), nil } func (w *guiWidget) Write(p []byte) (n int, err error) { + lines := strings.Split(strings.TrimSpace(string(p)), "\n") + fmt.Fprint(outf, string(p)) if w == nil { - lines := strings.Split(strings.TrimSpace(string(p)), "\n") me.stdout.outputS = append(me.stdout.outputS, lines...) return len(p), nil } @@ -175,7 +177,6 @@ func (w *guiWidget) Write(p []byte) (n int, err error) { me.writeMutex.Lock() defer me.writeMutex.Unlock() - lines := strings.Split(strings.TrimSpace(string(p)), "\n") me.stdout.outputS = append(me.stdout.outputS, lines...) tk := me.stdout.tk @@ -54,8 +54,6 @@ func addWidget(n *tree.Node) { // tk.setColor(&colorWindow) me.newWindowTrigger <- tk redoWindows(0, 0) - hideHelp() - showHelp() return case widget.Stdout: tk.labelN = "moreSTDOUT" |
