Warning: session_start(): open(/var/lib/php/sessions/sess_e2vaa0fcrno5rga61j8j1e9p50, O_RDWR) failed: No space left on device (28) in /var/www/tb-usercake/models/config.php on line 51
Warning: session_start(): Failed to read session data: files (path: /var/lib/php/sessions) in /var/www/tb-usercake/models/config.php on line 51
!7
static L sentences;
p {
sentences = toLinesFullTrim(loadSnippet(#1008606));
sentences = notStartingWith("\"", sentences);
JPanel panel = customLayoutPanel_trackWidth(func(Container parent) {
int cols = 2, gap = 10;
Dimension size = parent.getSize();
int w = max(100, size.width)-gap*2;
int y = gap;
LL rows = groupInFixedSizeRows(parent.getComponents(), cols);
new L colWidths;
for i to cols:
colWidths.add((i+1)*w/cols-i*w/cols);
for (L row : rows) {
int h = 0, x = gap;
for (Component c : row) h = max(h, c.getPreferredSize().height);
for i over row: {
row.get(i).setBounds(x, y, colWidths.get(i)-gap, h);
x += colWidths.get(i);
}
y += h + gap;
}
ret componentsBoundingSize(parent, gap);
});
for (S s : takeFirst(10, sentences)) {
panel.add(jlabel("Sentence"));
panel.add(jlabel("Action"));
panel.add(jtextfield(s));
panel.add(jtextfield("screw it"));
}
//showFrame(panel);
showFrame(jscroll(panel));
//showFrame(jscroll_centered(panel));
}