GNOME Bugzilla – Bug 110263
Texttool only puts a dot on drawing
Last modified: 2009-08-15 18:40:50 UTC
When I try to put a textbox on the drawing, only a small black dot appears. Also entering a text dosn't change anything. Any symbol with text in it also shows no text (e.g. uml-class or GRAFCET).
This may be a problem with your installed fonts. Do you have gsfonts or urwfonts packages installed? Dia 0.91 doesn't use the X font services, so your fonts must be local. If you select the 'Other fonts...' item from any font selector widget in Dia, you should be able to see what fonts are available.
Created attachment 15589 [details] Screenshot of fontlist in dia
Hello, thank you for the fast answer. I've installed gsfonts and urwfonts. When I start dia, I only get the following line: ** (dia:1670): WARNING **: No attribute type ((nil)) or no data((nil)) in this attribute No message about missing fonts. But when I try to change the font in the properties-window of a textbox, this is shown in the console: ** (dia:1670): WARNING **: Couldn't load font "Nimbus Sans L, 12" falling back to "Sans 12" ** (dia:1670): WARNING **: Couldn't load font "Nimbus Sans L, 12" falling back to "Sans 12" ** (dia:1670): WARNING **: Couldn't load font "Nimbus Sans L, 12" falling back to "Sans 12" ** (dia:1670): WARNING **: Couldn't load font "Nimbus Sans L, 12" falling back to "Sans 12" Blow is th output of fc-list, hope that helps. Installed: fontconfig-2.1.92 pango-1.2.1 freetype-2.1.3 Output from fc-list: LucidaBright:style=Italic Utopia:style=Bold Italic Nimbus Sans L:style=Regular Italic URW Palladio L:style=Roman Century Schoolbook L:style=Bold Italic Helvetica:style=Bold Italic Nimbus Sans L:style=Bold Times:style=Bold Italic Utopia:style=Bold URW Chancery L:style=Medium Italic Charter:style=Bold Italic Bitstream Charter:style=Bold Italic Nimbus Roman No9 L:style=Regular Century Schoolbook L:style=Bold Century Schoolbook L:style=Italic Courier:style=Bold Italic Nimbus Sans L:style=Regular Courier:style=Regular URW Palladio L:style=Italic Charter:style=Bold Cursor:style=Regular LucidaBright:style=Regular Nimbus Sans L:style=Bold Condensed Terminal:style=Bold URW Gothic L:style=Demi Lucida:style=Italic Nimbus Roman No9 L:style=Medium Italic Bitstream Charter:style=Regular Nimbus Mono L:style=Bold Oblique Dingbats:style= Helvetica:style=Italic Dingbats:style=Regular Nimbus Roman No9 L:style=Medium Times:style=Bold Nimbus Sans L:style=Bold Italic Charter:style=Italic Nimbus Mono L:style=Regular Bitstream Charter:style=Italic URW Gothic L:style=Book Lucida:style=Regular Times:style=Italic New Century Schoolbook:style=Bold Utopia:style=Italic LucidaTypewriter:style=Regular LucidaTypewriter:style=Bold Nimbus Sans L:style=Regular Condensed Italic URW Bookman L:style=Demi Bold URW Bookman L:style=Light Helvetica:style=Bold URW Gothic L:style=Demi Oblique Times:style=Regular Standard Symbols L:style=Regular New Century Schoolbook:style=Bold Italic Lucida:style=Bold Helvetica:style=Regular URW Palladio L:style=Bold Nimbus Sans L:style=Regular Condensed URW Bookman L:style=Light Italic Lucida:style=Bold Italic Courier:style=Italic Century Schoolbook L:style=Roman Nimbus Roman No9 L:style=Regular Italic Charter:style=Regular Terminal:style=Regular URW Gothic L:style=Book Oblique URW Palladio L:style=Bold Italic New Century Schoolbook:style=Italic Nimbus Mono L:style=Regular Oblique Courier:style=Bold Utopia:style=Regular Nimbus Mono L:style=Bold Bitstream Charter:style=Bold New Century Schoolbook:style=Regular Nimbus Sans L:style=Bold Condensed Italic URW Bookman L:style=Demi Bold Italic
That contains enough fonts to satisfy a sans request. Could you check what your /etc/fonts/fonts.conf (which should be where font-config puts it) says about the definition of sans (or sans-serif)?

I was not sure which line is important, so here is the whole file (/etc/fonts/fonts.conf): <?xml version="1.0"?> <!DOCTYPE fontconfig SYSTEM "fonts.dtd"> <!-- /etc/fonts/fonts.conf file to configure system font access --> <fontconfig> <!-- DO NOT EDIT THIS FILE. IT WILL BE REPLACED WHEN FONTCONFIG IS UPDATED. LOCAL CHANGES BELONG IN 'local.conf'. The intent of this standard configuration file is to be adequate for most environments. If you have a reasonably normal environment and have found problems with this configuration, they are probably things that others will also want fixed. Please send any suggested changes to fonts@xfree86.org so that future releases can include such changes. Note that the normal 'make install' procedure for fontconfig is to replace any existing fonts.conf file with the new version. Place any local customizations in local.conf which this file references. Keith Packard --> <!-- Font directory list configured on Wed Apr 9 02:13:19 CEST 2003 --> <dir>/usr/share/fonts</dir> <dir>/usr/X11R6/lib/X11/fonts/100dpi</dir> <dir>/usr/X11R6/lib/X11/fonts/Type1</dir> <dir>~/.fonts</dir> <!-- Enable sub-pixel rendering <match target="font"> <test qual="all" name="rgba"> <const>unknown</const> </test> <edit name="rgba" mode="assign"><const>rgb</const></edit> </match> --> <!-- Accept deprecated 'mono' alias, replacing it with 'monospace' --> <match target="pattern"> <test qual="any" name="family"> <string>mono</string> </test> <edit name="family" mode="assign"> <string>monospace</string> </edit> </match> <!-- Accept alternate 'sans serif' spelling, replacing it with 'sans-serif' --> <match target="pattern"> <test qual="any" name="family"> <string>sans serif</string> </test> <edit name="family" mode="assign"> <string>sans-serif</string> </edit> </match> <!-- Accept deprecated 'sans' alias, replacing it with 'sans-serif' --> <match target="pattern"> <test qual="any" name="family"> <string>sans</string> </test> <edit name="family" mode="assign"> <string>sans-serif</string> </edit> </match> <!-- Mark common families with their generics so we'll get something reasonable --> <!-- Serif faces --> <alias> <family>Times</family> <family>Times New Roman</family> <family>Nimbus Roman No9 L</family> <family>Luxi Serif</family> <family>Kochi Mincho</family> <family>AR PL SungtiL GB</family> <family>AR PL Mingti2L Big5</family> <family>Baekmuk Batang</family> <default><family>serif</family></default> </alias> <!-- Sans-serif faces --> <alias> <family>Helvetica</family> <family>Arial</family> <family>Verdana</family> <family>Nimbus Sans L</family> <family>Luxi Sans</family> <family>Kochi Gothic</family> <family>AR PL KaitiM GB</family> <family>AR PL KaitiM Big5</family> <family>Baekmuk Dotum</family> <family>SimSun</family> <default><family>sans-serif</family></default> </alias> <!-- Monospace faces --> <alias> <family>Courier</family> <family>Courier New</family> <family>Andale Mono</family> <family>Luxi Mono</family> <family>Nimbus Mono L</family> <family>NSimSun</family> <default><family>monospace</family></default> </alias> <!-- If the font still has no generic name, add sans-serif --> <match target="pattern"> <test qual="all" name="family" compare="not_eq"> <string>sans-serif</string> </test> <test qual="all" name="family" compare="not_eq"> <string>serif</string> </test> <test qual="all" name="family" compare="not_eq"> <string>monospace</string> </test> <edit name="family" mode="append_last"> <string>sans-serif</string> </edit> </match> <!-- Some Asian fonts misadvertise themselves as monospaced when in fact they are dual-spaced (half and full). This makes FreeType very confused as it forces all widths to match. Undo this magic by disabling the width forcing code --> <match target="font"> <test name="family"><string>GulimChe</string></test> <edit name="globaladvance"><bool>false</bool></edit> </match> <match target="font"> <test name="family"><string>DotumChe</string></test> <edit name="globaladvance"><bool>false</bool></edit> </match> <match target="font"> <test name="family"><string>BatangChe</string></test> <edit name="globaladvance"><bool>false</bool></edit> </match> <match target="font"> <test name="family"><string>GungsuhChe</string></test> <edit name="globaladvance"><bool>false</bool></edit> </match> <!-- Load per-user customization file --> <include ignore_missing="yes">~/.fonts.conf</include> <!-- Load local system customization file --> <include ignore_missing="yes">local.conf</include> <!-- Alias well known font names to available TrueType fonts --> <alias> <family>Times</family> <accept><family>Times New Roman</family></accept> </alias> <alias> <family>Helvetica</family> <accept><family>Verdana</family></accept> </alias> <alias> <family>Arial</family> <accept><family>Verdana</family></accept> </alias> <alias> <family>Courier</family> <accept><family>Courier New</family></accept> </alias> <!-- Check user preference to avoid bitmap fonts and replace bitmap face names with equivalent scalable fonts --> <match target="pattern"> <test name="prefer_outline"> <bool>true</bool> </test> <test name="family"> <string>Helvetica</string> </test> <edit name="family" mode="prepend" binding="same"> <string>Arial</string> </edit> </match> <match target="pattern"> <test name="prefer_outline"> <bool>true</bool> </test> <test name="family"> <string>Times</string> </test> <edit name="family" mode="prepend" binding="same"> <string>Times New Roman</string> </edit> </match> <!-- Provide required aliases for standard names --> <alias> <family>serif</family> <prefer> <family>Times New Roman</family> <family>Nimbus Roman No9 L</family> <family>Luxi Serif</family> <family>Times</family> <family>Kochi Mincho</family> <family>AR PL SungtiL GB</family> <family>AR PL Mingti2L Big5</family> <family>Baekmuk Batang</family> </prefer> </alias> <alias> <family>sans-serif</family> <prefer> <family>Verdana</family> <family>Nimbus Sans L</family> <family>Luxi Sans</family> <family>Arial</family> <family>Helvetica</family> <family>Kochi Gothic</family> <family>AR PL KaitiM GB</family> <family>AR PL KaitiM Big5</family> <family>Baekmuk Dotum</family> <family>SimSun</family> </prefer> </alias> <alias> <family>monospace</family> <prefer> <family>Andale Mono</family> <family>Courier New</family> <family>Luxi Mono</family> <family>Nimbus Mono L</family> <family>Kochi Gothic</family> <family>AR PL KaitiM GB</family> <family>Baekmuk Dotum</family> </prefer> </alias> <!-- Artificial oblique for fonts without an italic or oblique version --> <match target="font"> <!-- check to see if the font is roman --> <test name="slant"> <const>roman</const> </test> <!-- check to see if the pattern requested non-roman --> <test target="pattern" name="slant" compare="not_eq"> <const>roman</const> </test> <!-- multiply the matrix to slant the font --> <edit name="matrix" mode="assign"> <times> <name>matrix</name> <matrix><double>1</double><double>.2</double> <double>0</double><double>1</double> </matrix> </times> </edit> <!-- pretend the font is oblique now --> <edit name="slant" mode="assign"> <const>oblique</const> </edit> </match> <config> <!-- These are the default Unicode chars that are expected to be blank in fonts. All other blank chars are assumed to be broken and won't appear in the resulting charsets --> <blank> <int>0x0020</int> <!-- SPACE --> <int>0x00a0</int> <!-- NO-BREAK SPACE --> <int>0x00ad</int> <!-- SOFT HYPHEN --> <int>0x115f</int> <!-- HANGUL CHOSEONG FILLER --> <int>0x1160</int> <!-- HANGUL JUNGSEONG FILLER --> <int>0x1680</int> <!-- OGHAM SPACE MARK --> <int>0x2000</int> <!-- EN QUAD --> <int>0x2001</int> <!-- EM QUAD --> <int>0x2002</int> <!-- EN SPACE --> <int>0x2003</int> <!-- EM SPACE --> <int>0x2004</int> <!-- THREE-PER-EM SPACE --> <int>0x2005</int> <!-- FOUR-PER-EM SPACE --> <int>0x2006</int> <!-- SIX-PER-EM SPACE --> <int>0x2007</int> <!-- FIGURE SPACE --> <int>0x2008</int> <!-- PUNCTUATION SPACE --> <int>0x2009</int> <!-- THIN SPACE --> <int>0x200a</int> <!-- HAIR SPACE --> <int>0x200b</int> <!-- ZERO WIDTH SPACE --> <int>0x200c</int> <!-- ZERO WIDTH NON-JOINER --> <int>0x200d</int> <!-- ZERO WIDTH JOINER --> <int>0x200e</int> <!-- LEFT-TO-RIGHT MARK --> <int>0x200f</int> <!-- RIGHT-TO-LEFT MARK --> <int>0x2028</int> <!-- LINE SEPARATOR --> <int>0x2029</int> <!-- PARAGRAPH SEPARATOR --> <int>0x202a</int> <!-- LEFT-TO-RIGHT EMBEDDING --> <int>0x202b</int> <!-- RIGHT-TO-LEFT EMBEDDING --> <int>0x202c</int> <!-- POP DIRECTIONAL FORMATTING --> <int>0x202d</int> <!-- LEFT-TO-RIGHT OVERRIDE --> <int>0x202e</int> <!-- RIGHT-TO-LEFT OVERRIDE --> <int>0x202f</int> <!-- NARROW NO-BREAK SPACE --> <int>0x205f</int> <!-- MEDIUM MATHEMATICAL SPACE --> <int>0x2060</int> <!-- WORD JOINER --> <int>0x2061</int> <!-- FUNCTION APPLICATION --> <int>0x2062</int> <!-- INVISIBLE TIMES --> <int>0x2063</int> <!-- INVISIBLE SEPARATOR --> <int>0x206A</int> <!-- INHIBIT SYMMETRIC SWAPPING --> <int>0x206B</int> <!-- ACTIVATE SYMMETRIC SWAPPING --> <int>0x206C</int> <!-- INHIBIT ARABIC FORM SHAPING --> <int>0x206D</int> <!-- ACTIVATE ARABIC FORM SHAPING --> <int>0x206E</int> <!-- NATIONAL DIGIT SHAPES --> <int>0x206F</int> <!-- NOMINAL DIGIT SHAPES --> <int>0x3000</int> <!-- IDEOGRAPHIC SPACE --> <int>0x3164</int> <!-- HANGUL FILLER --> <int>0xfeff</int> <!-- ZERO WIDTH NO-BREAK SPACE --> <int>0xffa0</int> <!-- HALFWIDTH HANGUL FILLER --> <int>0xfff9</int> <!-- INTERLINEAR ANNOTATION ANCHOR --> <int>0xfffa</int> <!-- INTERLINEAR ANNOTATION SEPARATOR --> <int>0xfffb</int> <!-- INTERLINEAR ANNOTATION TERMINATOR --> </blank> <!-- Rescan configuration every 30 seconds when FcFontSetList is called --> <rescan> <int>30</int> </rescan> </config> </fontconfig>
That fonts.conf looks perfectly fine to me. If I knew of any other programs that use pangoft2, I'd ask you to try them. Hmmm... what happens if you export GDK_USE_XFT=1 before you start Dia?
export GDK_USE_XFT=1 results in a dia without any text displayed anywhere (menu, splash screen ...) and again no warning in the console. The tests mentioned on the pango homepage ( http://www.pango.org/download.shtml) work all fine. I tried testtext and testgtk from GTK+, as long I don't do an export GDK_USE_XFT=1 everything is ok. With export GDK_USE_XFT=1 no text is displayed like in dia.
Created attachment 15598 [details] Screenshot of DIA with export GDK_USE_XFT=1
Created attachment 15599 [details] Screenshot of testtext (GTK+) with export GDK_USE_XFT=0
Created attachment 15600 [details] Screenshot of testtext (GTK+) with export GDK_USE_XFT=1
This is definitely a Pango problem rather than a Dia problem. Either ask gtk-list@gnome.org (or gtk-i18n-list@gnome.org), or file a bug report on the appropriate component. They'll know what to look for.
Most likely the user simply has not run fc-cache and fontconfig does not any fonts for that reason. On the other hand, PangoFT2 tends to call exit() if it can not find any font at all... BTW, WONTFIX is definitely the wrong bug resolution. If you think this is a Pango bug, you should reassign to Pango.
Thanks for the info, Sven. Kuno, could you try Sven's suggestion? If that doesn't work, I'm sending the bug to Pango.
I tried fc-cache, but nothing changed. The output of fc-list above, also shows that there are many fonts installed. Thank you!
Moving bug to Pango. The GDK_USE_XFT problems indicate that this is not a Dia bug.
Could you check the permissions on the font file for Nimbus Sans L -- if it was readable by root but not by the user, it would problems like this. Running: fc-list 'Nimbus Sans L' - family style file Will let you figure out what the file is.
*** Bug 106586 has been marked as a duplicate of this bug. ***
Thank you for helping me Owen! The permissions on the files seems to be ok. Here is the desired output: fc-list 'Nimbus Sans L' - family style file /usr/X11R6/lib/X11/fonts/100dpi/n019044l.pfb: Nimbus Sans L:style=Bold Condensed /usr/X11R6/lib/X11/fonts/100dpi/n019043l.pfb: Nimbus Sans L:style=Regular Condensed /usr/X11R6/lib/X11/fonts/Type1/n019044l.pfb: Nimbus Sans L:style=Bold Condensed /usr/X11R6/lib/X11/fonts/Type1/n019003l.pfb: Nimbus Sans L:style=Regular /usr/X11R6/lib/X11/fonts/Type1/n019024l.pfb: Nimbus Sans L:style=Bold Italic /usr/X11R6/lib/X11/fonts/100dpi/n019004l.pfb: Nimbus Sans L:style=Bold /usr/X11R6/lib/X11/fonts/Type1/n019004l.pfb: Nimbus Sans L:style=Bold /usr/X11R6/lib/X11/fonts/Type1/n019043l.pfb: Nimbus Sans L:style=Regular Condensed /usr/X11R6/lib/X11/fonts/100dpi/n019063l.pfb: Nimbus Sans L:style=Regular Condensed Italic /usr/X11R6/lib/X11/fonts/Type1/n019064l.pfb: Nimbus Sans L:style=Bold Condensed Italic /usr/share/fonts/type1/gsfonts/n019063l.pfb: Nimbus Sans L:style=Regular Condensed Italic /usr/X11R6/lib/X11/fonts/Type1/n019023l.pfb: Nimbus Sans L:style=Regular Italic /usr/X11R6/lib/X11/fonts/Type1/n019063l.pfb: Nimbus Sans L:style=Regular Condensed Italic /usr/share/fonts/type1/gsfonts/n019064l.pfb: Nimbus Sans L:style=Bold Condensed Italic /usr/X11R6/lib/X11/fonts/100dpi/n019024l.pfb: Nimbus Sans L:style=Bold Italic /usr/share/fonts/type1/gsfonts/n019043l.pfb: Nimbus Sans L:style=Regular Condensed /usr/share/fonts/type1/gsfonts/n019044l.pfb: Nimbus Sans L:style=Bold Condensed /usr/X11R6/lib/X11/fonts/100dpi/n019064l.pfb: Nimbus Sans L:style=Bold Condensed Italic /usr/share/fonts/type1/gsfonts/n019023l.pfb: Nimbus Sans L:style=Regular Italic /usr/share/fonts/type1/gsfonts/n019024l.pfb: Nimbus Sans L:style=Bold Italic /usr/X11R6/lib/X11/fonts/100dpi/n019023l.pfb: Nimbus Sans L:style=Regular Italic /usr/share/fonts/type1/gsfonts/n019004l.pfb: Nimbus Sans L:style=Bold /usr/X11R6/lib/X11/fonts/100dpi/n019003l.pfb: Nimbus Sans L:style=Regular /usr/share/fonts/type1/gsfonts/n019003l.pfb: Nimbus Sans L:style=Regular fc-list 'Nimbus Sans L' - family style file|awk 'BEGIN { FS = ":" } ; { system("ls -lisa " $1) }' 438848 28 -rw-r--r-- 1 root root 27960 16. Okt 1997 /usr/X11R6/lib/X11/fonts/100dpi/n019044l.pfb 438845 28 -rw-r--r-- 1 root root 27406 16. Okt 1997 /usr/X11R6/lib/X11/fonts/100dpi/n019043l.pfb 515587 28 -rw-r--r-- 1 root root 27960 16. Okt 1997 /usr/X11R6/lib/X11/fonts/Type1/n019044l.pfb 515580 28 -rw-r--r-- 1 root root 27505 16. Okt 1997 /usr/X11R6/lib/X11/fonts/Type1/n019003l.pfb 515585 32 -rw-r--r-- 1 root root 28971 16. Okt 1997 /usr/X11R6/lib/X11/fonts/Type1/n019024l.pfb 438834 28 -rw-r--r-- 1 root root 26762 16. Okt 1997 /usr/X11R6/lib/X11/fonts/100dpi/n019004l.pfb 515583 28 -rw-r--r-- 1 root root 26762 16. Okt 1997 /usr/X11R6/lib/X11/fonts/Type1/n019004l.pfb 515586 28 -rw-r--r-- 1 root root 27406 16. Okt 1997 /usr/X11R6/lib/X11/fonts/Type1/n019043l.pfb 438851 28 -rw-r--r-- 1 root root 28298 16. Okt 1997 /usr/X11R6/lib/X11/fonts/100dpi/n019063l.pfb 515592 32 -rw-r--r-- 1 root root 29384 16. Okt 1997 /usr/X11R6/lib/X11/fonts/Type1/n019064l.pfb 466329 40 -rw-r--r-- 1 root root 37247 11. Mai 2001 /usr/share/fonts/type1/gsfonts/n019063l.pfb 515584 28 -rw-r--r-- 1 root root 28397 16. Okt 1997 /usr/X11R6/lib/X11/fonts/Type1/n019023l.pfb 515588 28 -rw-r--r-- 1 root root 28298 16. Okt 1997 /usr/X11R6/lib/X11/fonts/Type1/n019063l.pfb 466330 40 -rw-r--r-- 1 root root 38310 11. Mai 2001 /usr/share/fonts/type1/gsfonts/n019064l.pfb 438842 32 -rw-r--r-- 1 root root 28971 16. Okt 1997 /usr/X11R6/lib/X11/fonts/100dpi/n019024l.pfb 466327 36 -rw-r--r-- 1 root root 36615 11. Mai 2001 /usr/share/fonts/type1/gsfonts/n019043l.pfb 466328 40 -rw-r--r-- 1 root root 37240 11. Mai 2001 /usr/share/fonts/type1/gsfonts/n019044l.pfb 438854 32 -rw-r--r-- 1 root root 29384 16. Okt 1997 /usr/X11R6/lib/X11/fonts/100dpi/n019064l.pfb 466325 40 -rw-r--r-- 1 root root 38314 11. Mai 2001 /usr/share/fonts/type1/gsfonts/n019023l.pfb 466326 40 -rw-r--r-- 1 root root 39013 11. Mai 2001 /usr/share/fonts/type1/gsfonts/n019024l.pfb 438837 28 -rw-r--r-- 1 root root 28397 16. Okt 1997 /usr/X11R6/lib/X11/fonts/100dpi/n019023l.pfb 466324 36 -rw-r--r-- 1 root root 35941 11. Mai 2001 /usr/share/fonts/type1/gsfonts/n019004l.pfb 438831 28 -rw-r--r-- 1 root root 27505 16. Okt 1997 /usr/X11R6/lib/X11/fonts/100dpi/n019003l.pfb 466323 36 -rw-r--r-- 1 root root 36026 11. Mai 2001 /usr/share/fonts/type1/gsfonts/n019003l.pfb
hard to say. I'd have to guess that one of the many copies of these fonts on your system is corrupt. I'd start by removing the URW files from: /usr/X11R6/lib/X11/fonts/100dpi/n019044l.pfb They look like a leftover from a very old installation on your system.
Added these two lines to /etc/X11/XF86Config-4 (before I added it to the old file XF86Config): Section "Module" ... Load "type1" Load "freetype" EndSection After that I did ./configure make make install in the pango-dir again and it worked. Don't know if there is a relation between these two lines in the XF86Config-4 and pango or if there where other things which were wrong before. At the end of configure the following appears: configuration: backends: FreeType X I'm not sure if that line appeared in the runs before. Kuno