I am working on a project where I want to use custom fonts to draw text on image. I don't want to use the inbuilt OpenIMAJ fonts. Is there a way to do that?
Asked
Active
Viewed 100 times
1 Answers
0
Use the GeneralFont
class to access all system fonts via AWT:
MBFImage img = new MBFImage( 800, 600, 3 );
img.drawText( "OpenIMAJ", 20, 100, new GeneralFont("Arial", Font.PLAIN ), 120, RGBColour.WHITE );

Jon
- 841
- 4
- 5
-
I want to use other third-party fonts like google fonts – Arif Rabbani May 08 '18 at 15:22