[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Sc-devel] MIDIKeyboard not placed properly by FlowLayout



Hi List /Thor,

I just found this - using latest release 3.2RC6:

// this MIDIKeyboard is displayed ok
(
a = SCWindow.new;
a.front;

b = SCCompositeView(a,Rect(0,0,500,500));
b.decorator = FlowLayout(b.bounds);

m = MIDIKeyboard.new(b, Rect(0, 0, 300, 80), 4, 48);
m.keyDownAction_({arg note; note.postln;});

SC2DSlider(b,Rect(0,0,100,100));
SC2DSlider(b,Rect(0,0,100,100));
SC2DSlider(b,Rect(0,0,100,100));
SC2DSlider(b,Rect(0,0,100,100));
SC2DSlider(b,Rect(0,0,100,100));

)

// this MIDIKeyboard is displayed wrongly - not being placed by the decorator
(
a = SCWindow.new;
a.front;

b = SCCompositeView(a,Rect(0,0,500,500));
b.decorator = FlowLayout(b.bounds);

SC2DSlider(b,Rect(0,0,100,100));
SC2DSlider(b,Rect(0,0,100,100));
SC2DSlider(b,Rect(0,0,100,100));
SC2DSlider(b,Rect(0,0,100,100));
SC2DSlider(b,Rect(0,0,100,100));

m = MIDIKeyboard.new(b, Rect(0, 0, 300, 80), 4, 48);
m.keyDownAction_({arg note; note.postln;});

)

Cheers,

Paul