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

5
LINES

< > BotCompany Repo | #1031121 // tempSetFontSize

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

Libraryless. Click here for Pure Java version (30L/1K).

1  
static AutoCloseable tempSetFontSize(Graphics g, float size) {
2  
  Font font = g.getFont();
3  
  g.setFont(font.deriveFont(size));
4  
  ret autoCloseable { g.setFont(font); };
5  
}

Author comment

Began life as a copy of #1031120

download  show line numbers  debug dex  old transpilations   

Travelled to 4 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx, vouqrxazstgt

No comments. add comment

Snippet ID: #1031121
Snippet name: tempSetFontSize
Eternal ID of this version: #1031121/3
Text MD5: fd31e04e952537bca835bc1770f3d137
Transpilation MD5: ef8ef554282007ff28c302e2d839643e
Author: stefan
Category: javax / gui
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2021-05-07 15:33:02
Source code size: 173 bytes / 5 lines
Pitched / IR pitched: No / No
Views / Downloads: 132 / 202
Version history: 2 change(s)
Referenced in: [show references]