static new Map<S, Font> loadFont_cached_cache; static synchronized Font loadFont_cached(S snippetID) ctex { snippetID = formatSnippetID(snippetID); Font f = loadFont_cached_cache.get(snippetID); if (f == null) loadFont_cached_cache.put(snippetID, f = loadFont(snippetID, 12f)); ret f; } static synchronized Font loadFont_cached(S snippetID, float size) ctex { ret loadFont_cached(snippetID).deriveFont(size); }
Began life as a copy of #1000994
download show line numbers debug dex old transpilations
Travelled to 14 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, ddnzoavkxhuk, gwrvuhgaqvyk, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt
No comments. add comment
Snippet ID: | #1004610 |
Snippet name: | loadFont_cached (accepts snippet ID) |
Eternal ID of this version: | #1004610/3 |
Text MD5: | 1a66abefadde7041996a708922b6fed1 |
Author: | stefan |
Category: | |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2022-02-20 19:05:06 |
Source code size: | 438 bytes / 13 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 536 / 586 |
Version history: | 2 change(s) |
Referenced in: | #1006654 - Standard functions list 2 (LIVE, continuation of #761) |