Java Code Examples for javax.swing.plaf.FontUIResource#getSize()
The following examples show how to use
javax.swing.plaf.FontUIResource#getSize() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: LafManagerImplUtil.java From consulo with Apache License 2.0 | 6 votes |
@SuppressWarnings({"HardCodedStringLiteral"}) public static void initFontDefaults(@Nonnull UIDefaults defaults, @Nonnull FontUIResource uiFont) { defaults.put("Tree.ancestorInputMap", null); FontUIResource textFont = new FontUIResource(uiFont); FontUIResource monoFont = new FontUIResource("Monospaced", Font.PLAIN, uiFont.getSize()); for (String fontResource : ourPatchableFontResources) { defaults.put(fontResource, uiFont); } if (!SystemInfo.isMac) { defaults.put("PasswordField.font", monoFont); } defaults.put("TextArea.font", monoFont); defaults.put("TextPane.font", textFont); defaults.put("EditorPane.font", textFont); }
Example 2
Source File: MyLocaleChangeListener.java From radiance with BSD 3-Clause "New" or "Revised" License | 2 votes |
/** * Returns the wrapped font. * * @param systemFont * Original font. * @return Wrapped font. */ private FontUIResource getWrappedFont(FontUIResource systemFont) { return new FontUIResource("Dialog", systemFont.getStyle(), systemFont.getSize()); }
Example 3
Source File: GetFontPolicy.java From radiance with BSD 3-Clause "New" or "Revised" License | 2 votes |
/** * Returns the wrapped font. * * @param systemFont Original font. * @return Wrapped font. */ private FontUIResource getWrappedFont(FontUIResource systemFont) { return new FontUIResource(systemFont.getFontName(), systemFont.getStyle(), systemFont.getSize() + this.extra); }
Example 4
Source File: SetFontPolicy.java From radiance with BSD 3-Clause "New" or "Revised" License | 2 votes |
/** * Returns the wrapped font. * * @param systemFont Original font. * @return Wrapped font. */ private FontUIResource getWrappedFont(FontUIResource systemFont) { return new FontUIResource(systemFont.getFontName(), systemFont.getStyle(), systemFont.getSize() + this.extra); }
Example 5
Source File: ScaledFontSet.java From radiance with BSD 3-Clause "New" or "Revised" License | 2 votes |
/** * Returns the wrapped font. * * @param systemFont * Original font. * @return Wrapped font. */ private FontUIResource getWrappedFont(FontUIResource systemFont) { return new FontUIResource(systemFont.getFontName(), systemFont .getStyle(), (int) (systemFont.getSize() * this.scaleFactor)); }