BUG - Scalable fonts incorrect size on F265/F265s/F965/Venu3/Venu3s

The font returned from Graphics.getVectorFont() is way too large on the F265/F265s/F965/Venu3/Venu3s.

This is what it should look like on all watches:

Venu3:

Related bug in the simulator: forums.garmin.com/.../simulator-bug-with-scalable-fonts

  • I began with fr965, so I think the other way, bug is in all others (group 1)

    I didn't try doubled Fontsizes, but made something like this for group 1:

    AddFontSize = (-1)*Math.round(screenWidth*Factor);

    the Factor depends on the Fontsize and i have tried and change it till it looks the same.

    This is working in Simulator for all Devices until they change/fix this ;-)

  • Seems the BionicBold font has issues.  Try using another one and see how that works.  I'm pretty much sticking with the Roboto fonts as they are available for all devices with scalable fonts and seem to be working fine.

  • I wrote at test app to see what is going on, both in the sim and the real devices.  In both cases, the font size issues is dependent on the font, not on the device.  So, whatever compensation factor calculation you are doing, it needs to be font-specific, not device specific.

    Unfortunately, the sim's support for scalable fonts is so messed up, it is hard to ensure that an app/WF will look right on all the supported devices.

    Garmin:  Please fix the sim ASAP.  Without this fix, I'm hesitant to publish any apps using scalable fonts since I can't test on all the actual supported devices.

  • Here is the test app on the sim.  I added a bounding box in Garmin's sample app's "Font Mapping" page.

    Code:

        function onUpdate(dc as Dc) as Void {
            dc.setColor(Graphics.COLOR_WHITE, Graphics.COLOR_BLACK);
            dc.clear();
    
            dc.setPenWidth(1);
            dc.setColor(Graphics.COLOR_WHITE, Graphics.COLOR_TRANSPARENT);
            var inset = dc.getWidth() / 8;
            var cx = inset;
            var cy = dc.getHeight() / 2 - (_maxLinesPerScreen * _fontSize) / 2;
            var just = Graphics.TEXT_JUSTIFY_LEFT;
            var colors = [Graphics.COLOR_RED, Graphics.COLOR_GREEN];
    
            for (var i = _viewId * _maxLinesPerScreen; i < (_viewId + 1) * _maxLinesPerScreen && i < _fontsArray.size(); ++i) {
                var vectorFont = Graphics.getVectorFont({:face =>_fontsArray[i] , :size => _fontSize});
                var dy = dc.getFontHeight(vectorFont);
                dc.setColor(colors[i%2], Graphics.COLOR_TRANSPARENT);
                dc.drawRectangle(cx, cy, dc.getWidth() - inset*2, dy);
                dc.setColor(Graphics.COLOR_WHITE, Graphics.COLOR_TRANSPARENT);
                dc.drawText(cx, cy, vectorFont, "Ay0!'.]:" + _fontsArray[i], just);
                cy += dy + 4;
            }
    
            dc.setColor(Graphics.COLOR_BLUE, Graphics.COLOR_TRANSPARENT);
            dc.drawText(dc.getWidth()/2, dc.getHeight() / 8, Graphics.FONT_XTINY, (_viewId + 1) + " / " + _viewIdMax, Graphics.TEXT_JUSTIFY_CENTER);
        }
    

  • Here I've printed a test string in each of the above fonts on the sim.  BionicBold isn't the only one that is seriously amiss!

  • Yes, Roboto fonts seems to work best.  Here is the sample app mentioned running on the F7 and Venu3:

  • What this says to me, is it may not be the SDK, but the font files specified in the simulator.json files for the devices.

    Which might me good news.  Devices can be updated and done fairly quickly, without waiting for an SDK update that takes longer.  Do a bug report and list the specific fonts and devices where you see an issue.

  • There are rendering bugs for several fonts, including RobotoCondensedBold so it isn't just the json files that need to be fixed ASAP.

  • I found this order of fonts works best for me: 

            var C_FONTS = [
                "RobotoCondensedBold",    // D2 Mach 1, Epix 2/42/47/51, F7, FR265/s FR255, FR965, MARQ 2
                "RobotoCondensedRegular", // D2 Mach 1, Epix 2/42/47/51, F7, FR265/s, FR255, FR965, MARQ 2
                "RobotoRegular",          // Venu 3, FR265/s, FR255, FR965
            ] as Array<String>;
    

  • Do a bug report and include pictures and code to reproduce.  That's the way to get something fixed.