is there a way to draw a text with a built-in font of the same size as the one on the standard digital watch face of fenix 3 HR? The maximum size of text I'm able to get is something like 75 px versus ~110-115 px on the standard WF. In addition, for the built-in font, some vertical spacing seems to be embedded in the font, so that the getFontHeight function returns the height of the space the font+spacing occupies (e.g. 116 for FONT_NUMBER_THAI_HOT), and not the height of the font itself (i.e. 75 for FONT_NUMBER_THAI_HOT). Because of this, I'm not able to align the text correctly with other drawables on the WF.
Do I understand correctly that the only way to overcome this is to use a custom font?
Standard WF:
Custom WF:
Code for the "Custom WF":
function onUpdate(dc) {
var txt = "10:36";
var txtFont = Gfx.FONT_NUMBER_THAI_HOT;
var width = dc.getWidth();
var height = dc.getHeight();
dc.setColor(Gfx.COLOR_WHITE, Gfx.COLOR_LT_GRAY);
dc.drawText(width / 2, height / 2, txtFont, txt, Gfx.TEXT_JUSTIFY_CENTER | Gfx.TEXT_JUSTIFY_VCENTER);
}
Thank you,
Evgeny.