Bug 304196

Summary: Borked fonts and missing italic/bold
Product: [Unmaintained] Necessitas Reporter: Marco Bernasocchi <marco>
Component: Android Qt4Assignee: BogDan Vatra <bogdan>
Status: RESOLVED UNMAINTAINED    
Severity: normal CC: florian, lasconic, nilson.aguiar1, tomaslov
Priority: NOR    
Version: alpha4   
Target Milestone: Unspecified   
Platform: Android   
OS: Unspecified   
URL: https://sourceforge.net/p/necessitas/tickets/193/
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description Marco Bernasocchi 2012-07-28 17:56:33 UTC
https://sourceforge.net/p/necessitas/tickets/193/
Comment 1 Florian Apolloner 2012-09-18 16:37:16 UTC
I have the same issue on Asus Transformer Tf700, although üÜ works for me, ÖöÄä are not shown. I will attach the fonts in a second, please tell me what else you need.
Comment 2 Florian Apolloner 2012-09-18 16:49:58 UTC
Actually no, the attachment is to big, uploading it to http://apolloner.eu/~apollo13/fonts.tar.bz2 (has around 37 mb). The font test app referenced in the other tickets only shows squares and a paragraph symbol for me. Italic/Bold does work though…
Comment 3 Nilson Aguiar 2012-10-31 13:48:47 UTC
I've got the same problem but this happens only in the Galaxy tab 2 7.0 (GT-P3100).
I cant use these characters { á. à, é, í, ó, ã, õ, ç }.

I've downloaded the fonts and tested using Qdebug to see the name of the font (I found out that the name is Helvetica), I saw that doesn't exists a font named Helvetica on the folder "/system/fonts", so I search a bit more on the folders and found a .xml file named system_fonts, that makes links with font names and font files, so this tablet uses a font named Roboto that is linked to Helvetica. But i've installed that font on linux and worked with that characters, so i dont know what else to do.

If you want me to attach the fonts ask me to do, because its arround 37mb.

The system_fonts.xml it's described down here:

<?xml version="1.0" encoding="utf-8"?>
<!--
    System Fonts

    This file lists the font families that will be used by default for all supported glyphs.
    Each entry consists of a family, various names that are supported by that family, and
    up to four font files. The font files are listed in the order of the styles which they
    support: regular, bold, italic and bold-italic. If less than four styles are listed, then
    the styles with no associated font file will be supported by the other font files listed.

    The first family is also the default font, which handles font request that have not specified
    specific font names.

    Any glyph that is not handled by the system fonts will cause a search of the fallback fonts.
    The default fallback fonts are specified in the file /system/etc/fallback_fonts.xml, and there
    is an optional file which may be supplied by vendors to specify other fallback fonts to use
    in /vendor/etc/fallback_fonts.xml.
-->
<familyset>

    <family>
        <nameset>
            <name>sans-serif</name>
            <name>arial</name>
            <name>helvetica</name>
            <name>tahoma</name>
            <name>verdana</name>
        </nameset>
        <fileset>
            <file>Roboto-Regular.ttf</file>
            <file>Roboto-Bold.ttf</file>
            <file>Roboto-Italic.ttf</file>
            <file>Roboto-BoldItalic.ttf</file>
        </fileset>
    </family>

    <family>
        <nameset>
            <name>serif</name>
            <name>times</name>
            <name>times new roman</name>
            <name>palatino</name>
            <name>georgia</name>
            <name>baskerville</name>
            <name>goudy</name>
            <name>fantasy</name>
            <name>cursive</name>
            <name>ITC Stone Serif</name>
        </nameset>
        <fileset>
            <file>DroidSerif-Regular.ttf</file>
            <file>DroidSerif-Bold.ttf</file>
            <file>DroidSerif-Italic.ttf</file>
            <file>DroidSerif-BoldItalic.ttf</file>
        </fileset>
    </family>

    <family>
        <nameset>
            <name>Droid Sans</name>
        </nameset>
        <fileset>
            <file>DroidSans.ttf</file>
            <file>DroidSans-Bold.ttf</file>
        </fileset>
    </family>

    <family>
        <nameset>
            <name>monospace</name>
            <name>courier</name>
            <name>courier new</name>
            <name>monaco</name>
        </nameset>
        <fileset>
            <file>DroidSansMono.ttf</file>
        </fileset>
    </family>

</familyset>
Comment 4 lasconic 2012-11-13 15:45:31 UTC
More info here https://groups.google.com/forum/?fromgroups=#!topic/android-qt/e2uCoWmoGW0
I think the bug is only present in ICS and higher with the introduction of Roboto as the default system font while Droid Sans is expected to be the default font by necessitas. The fallbackforFamily function then fallbacks to DroidFallback and this font doesn't contain some diacritical characters. I suggest adding Roboto in the fallback list or to change the default font.

As a workaround, Roboto can be defined as the application font with app.setFont("Roboto"). This workaround seems to work for ICS+ and doesn't break 2.3.3+
Comment 5 lasconic 2012-11-13 15:47:50 UTC
This one is probably a duplicate btw https://bugs.kde.org/show_bug.cgi?id=309680
Comment 6 Andrew Crouthamel 2018-09-04 16:17:08 UTC
Hello! Sorry to be the bearer of bad news, but this project has been unmaintained for many years and I will be closing this bug.