\name {monitor2} \children {monitor2.graph monitor2.txt monitor2.socket} \class {vpane} \script { switch (arg[0]) { case "graph": return send(nthChild(0), arg[0], arg[1]); break; case "txt": return send(nthChild(1), arg[0], arg[1]); break; } usual(); } \width {400} \height {400} \border {3} \ \name {monitor2.graph} \parent {monitor2} \class {field} \script { switch (arg[0]) { case "graph": y = arg[1] / 100.0 * hh; drawLine(1, y, 1, hh); copyArea(0, 0, ww, hh, 1, 0); return; break; case "config": usual(); clearWindow(); ww = get("width"); hh = get("height"); return; break; } usual(); } \BGColor {blue} \FGColor {white} \gapH {4} \gapV {4} \ \name {monitor2.txt} \parent {monitor2} \children {monitor2.txt.tf monitor2.txt.sb} \class {hpane} \script { switch (arg[0]) { case "txt": send(nthChild(0), arg[0], arg[1]); return; break; } usual(); } \gapH {4} \gapV {4} \ \name {monitor2.txt.tf} \parent {monitor2.txt} \class {txtEdit} \shownDepend {monitor2.txt.sb} \script { switch (arg[0]) { case "txt": /* t = concat(t, arg[1], "\n"); set("content", t); render(); */ if (configed) { insert(arg[1]); insert('\n'); } return; break; case "config": configed = 1; break; } usual(); } \ \name {monitor2.txt.sb} \parent {monitor2.txt} \class {slider} \shownNotify {monitor2.txt.tf} \maxWidth {20} \ \name {monitor2.socket} \parent {monitor2} \class {socket} \host {pebble.ebay.gnn.com} \port {7777} \script { /* sym share price */ switch (arg[0]) { case "input": data = input(); send(parent(), "graph", int(nthWord(data, 3))); send(parent(), "txt", data); return; break; case "init": usual(); set("outDelimStr", "\r\n"); set("inDelimStr1", '\n'); startClient(); return; break; } usual(); } \maxHeight {1} \