GeonBit.UI icon indicating copy to clipboard operation
GeonBit.UI copied to clipboard

Support for non-monospace fonts

Open ayousuf23 opened this issue 3 years ago • 3 comments

GeonBit.UI needs to support non-monospace fonts. What should be done to support them?

ayousuf23 avatar May 20 '21 12:05 ayousuf23

@RonenNess what needs to be done to support non-monospace fonts?

ayousuf23 avatar May 20 '21 12:05 ayousuf23

Hi @ayousuf23, I'm afraid that would be quite difficult as I do a lot of size calculations based on font size, assuming all characters are equal. You can try setting non mono font and see what breaks, maybe the stuff that would break happen to be elements you don't use.

Bottom line- no idea, but might be complicated.

RonenNess avatar May 20 '21 13:05 RonenNess

Just as an idea: there are some programs which generating .xml or .json files of the font containing information like the size of each character. I would go that route and implement this funtionallity into the content pipeline or add a reference to JSON and implement (De-)Serializing methods.

Then it should be easily possible to work with any font in GeonBit.UI.

At least if someone is willing to do the work of course 😜

BlizzCrafter avatar May 20 '21 18:05 BlizzCrafter