-
... window.bounds; margin = 4; gap = 2; topBarH = 22; tranBarH = 22; centerBounds = Rect(0,0, bounds.width-8, bounds.height-( topBarH + tranBarH + (2*margin) + (2*gap) )); //centerView = CompositeView(view, centerBounds).resize_(5); scoreView = ...
-
... per.new.init(title, string) } init { |title, string| window = Window.new(title, Rect(100, 100, 500, 400)); textView = TextView(window, Rect(0, 0, 500, 400)).resize_(5); layerView = UserView(window, Rect(0, 0, 500, 400)); window.front; } edi ...
-
... //--private prMake {|parent, bounds, name| var cmp; if(bounds.isNil, { bounds= Rect(0, 0, defaultWidth, defaultHeight); }, { bounds= bounds.asRect; }); cmp= CompositeView(parent, bounds); cmp.decorator= FlowLayout(bounds, 4@0, 4@0); numb= ...
-
... // example mix with (H|V)Layouts and FlowLayout w = Window("pane view", { |wh| Rect.aboutPoint(Window.availableBounds.center, wh.x/2, wh.y/2) }.(800@600)).front; p = PaneView(w.view, \horizontal, 3, [1,2,1]); Slider2D(p.panes[0], p.panes[0 ...
-
... play var <>needsTab = false; var <>basicPointPrim = "oval"; // options: oval or rect *new { arg name = "untitled", width = 320, height = 240, publishing = true, fileType = "pdf", frames = 30, fps = 30; ^super.newCopyArgs(name, width, height ...
-
... / ((x.size - 1) * xDev * yDev) }; //--window var win= Window("fft plot widget", Rect(1500, 1500, 512, 338)); var fs= "Frequency (Hz)"; var as= "Amplitude (uV)"; win.view.minSize= Size(502, 145); win.background= Color.white; win.drawFunc= { ...
-
... /////// GRAPHICS: // make a userview to draw on ~win = Window("basic graphics", Rect(0,0,400,400)).front; ~uv = UserView.new(~win, Rect(0,0,400,400)); ~uv.background = Color.white; // tell it what to draw: ~uv.drawFunc = { Pen.strokeRect(Re ...
-
... eView { // shouldnt really do this to an h or v layout resizeToFit { var r; r = Rect(0,0,0,0); this.children.do({ |kid| r = r.union(kid.bounds) }); this.bounds = r; } }
-
... eView { // shouldnt really do this to an h or v layout resizeToFit { var r; r = Rect(0, 0, 0, 0); this.children.do({ |kid| r = r.union(kid.bounds) }); this.bounds = r; } }
-
... ke {|parent, bounds, name| var cmp, width1, height1; if(bounds.isNil, { bounds= Rect(0, 0, defaultWidth, defaultHeight); }, { bounds= bounds.asRect; }); cmp= CompositeView(parent, bounds); cmp.decorator= FlowLayout(bounds, 4@0, 4@0); width1 ...