Libraryless. Click here for Pure Java version (5597L/32K).
1 | sclass LeftAlignedLine extends JPanel {
|
2 | *(int spacing, Component... components) {
|
3 | this(components); |
4 | setSpacing(spacing); |
5 | } |
6 | |
7 | *(Component... components) {
|
8 | setLayout(LetterLayout.leftAlignedRow()); |
9 | addAll(this, components); |
10 | } |
11 | |
12 | void setSpacing(int spacing) {
|
13 | ((LetterLayout) getLayout()).setSpacing(spacing, spacing); |
14 | } |
15 | |
16 | public void add(String text) {
|
17 | add(new JLabel(text)); |
18 | } |
19 | } |
Began life as a copy of #1005943
download show line numbers debug dex old transpilations
Travelled to 14 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, onxytkatvevr, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt
No comments. add comment
| Snippet ID: | #1006225 |
| Snippet name: | LeftAlignedLine |
| Eternal ID of this version: | #1006225/6 |
| Text MD5: | e1273b045c2c094a16989cf4b3d7a8b2 |
| Transpilation MD5: | 3e7f134abc718523f6b7a1ba3ff10762 |
| Author: | stefan |
| Category: | javax |
| Type: | JavaX fragment (include) |
| Public (visible to everyone): | Yes |
| Archived (hidden from active list): | No |
| Created/modified: | 2022-03-16 16:11:35 |
| Source code size: | 438 bytes / 19 lines |
| Pitched / IR pitched: | No / No |
| Views / Downloads: | 868 / 1630 |
| Version history: | 5 change(s) |
| Referenced in: | [show references] |