You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
37 lines
786 B
37 lines
786 B
10 years ago
|
package mightypork.gamecore.backends.lwjgl.graphics.font;
|
||
|
|
||
|
|
||
|
import java.awt.Font;
|
||
|
import java.io.IOException;
|
||
|
|
||
|
import mightypork.utils.annotations.Alias;
|
||
|
|
||
|
|
||
|
/**
|
||
|
* Font obtained from the OS
|
||
|
*
|
||
|
* @author Ondřej Hruška (MightyPork)
|
||
|
*/
|
||
|
@Alias(name = "FontNative")
|
||
|
public class DeferredLwjglFontFromSystem extends DeferredLwjglFont {
|
||
|
|
||
|
/**
|
||
|
* A font from OS, found by name
|
||
|
*
|
||
|
* @param fontName font family name
|
||
|
* @param chars chars to load; null to load basic chars only
|
||
|
* @param size size (pt)
|
||
|
*/
|
||
|
public DeferredLwjglFontFromSystem(String fontName, String chars, double size) {
|
||
|
super(fontName, chars, size);
|
||
|
}
|
||
|
|
||
|
|
||
|
@Override
|
||
|
protected Font getAwtFont(String resource, float size, int style) throws IOException
|
||
|
{
|
||
|
return new Font(resource, style, (int) size);
|
||
|
}
|
||
|
|
||
|
}
|