Not logged in.  Login/Logout/Register | List snippets | | Create snippet | Upload image | Upload data

8
LINES

< > BotCompany Repo | #1033800 // withSideAndBottomMargin

JavaX fragment (include) [tags: use-pretranspiled]

Libraryless. Click here for Pure Java version (4869L/27K).

1  
static JPanel withSideAndBottomMargin(int w default defaultMargin(), Component c) {
2  
  ret swing(-> {
3  
    JPanel p = marginPanel();
4  
    p.setBorder(BorderFactory.createEmptyBorder(0, w, w, w));
5  
    p.add(c);
6  
    ret p;
7  
  });
8  
}

Author comment

Began life as a copy of #1019840

download  show line numbers  debug dex  old transpilations   

Travelled to 3 computer(s): bhatertpkbcr, mowyntqkapby, mqqgnosmbjvj

No comments. add comment

Snippet ID: #1033800
Snippet name: withSideAndBottomMargin
Eternal ID of this version: #1033800/2
Text MD5: 95ab6de0f4383b85d07cab5dc1ed40bc
Transpilation MD5: d5c77c7a67bea30afad44c94918f0f16
Author: stefan
Category: javax / gui
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2022-01-05 04:40:51
Source code size: 234 bytes / 8 lines
Pitched / IR pitched: No / No
Views / Downloads: 147 / 210
Version history: 1 change(s)
Referenced in: [show references]