Request: the default global font and mouse cursor

Hi Julian!

It would be nice if we would have the ability to set a font (the Font class) as the default font for the entire application (through some LookAndFeel class method, I guess). Thus, it would be possible to set even an embedded font as the global font for an application.

So, it would be great if we could set a mouse cursor image (the MouseCursor class) as the global mouse cursor image for the entire application.

Happy new year! :slight_smile:

[quote=“Ptomaine”]Hi Julian!

It would be nice if we would have the ability to set a font (the Font class) as the default font for the entire application (through some LookAndFeel class method, I guess). Thus, it would be possible to set even an embedded font as the global font for an application.

Happy new year! :)[/quote]

I second the idea! Although I’ve looked into using embedded default font and it is not so trivial - would require quite a tweak in the font class.

Happy new year to y’all too!

You’ve always been able to set the default font - it’s Font::setDefaultSansSerifFontName()

The mouse cursor thing is a good request, I’ll have a think about that.

The method takes a name of a font as a string, but I’m talking about the Font class instance instead of a string. In your case, how am I supposed to set the default font if it’s stored (embedded) in my resources in the binary format produced with “Typeface::serialize”?

I’m talking of this: Font::setDefaultSansSerifFont(const Font &defaultFont)

Oh, sorry, I see now. Hmm, that’s certainly a good request, I’ll try to implement something to do that soon. Shouldn’t be difficult.

Thank you, Julian! :slight_smile:

This way, any application can use embedded fonts to look pixel-to-pixel familiar to its users no matter what OSes they use. Moreover, embedding Unicode fonts guarantees support for language specific strings that can be absent at some OS’s font repository.

Thanks again!