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

8
LINES

< > TinyBrain | #1007197 - setFontSize

JavaX fragment (include)

static <A extends JComponent> A setFontSize(int size, A a) {
  if (a != null) a.setFont(a.getFont().deriveFont((float) size));
  ret a;
}

static <A extends JComponent> A setFontSize(A a, int size) {
  ret setFontSize(size, a);
}

Author comment

Began life as a copy of #1007147

download  show line numbers  debug dex   

Travelled to 2 computer(s): cfunsshuasjs, tvejysmllsmz

No comments. add comment

Snippet ID: #1007197
Snippet name: setFontSize
Eternal ID of this version: #1007197/5
Text MD5: 7c8378bb3b59380739e1735ed4025449
Author: stefan
Category: javax / gui
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2017-04-21 16:42:49
Source code size: 236 bytes / 8 lines
Pitched / IR pitched: No / No
Views / Downloads: 35 / 19
Version history: 4 change(s)
Referenced in: [show]