Bug 692382 - xfig font selection problem (scalablefont problem?)
Summary: xfig font selection problem (scalablefont problem?)
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Fedora
Classification: Fedora
Component: xfig
Version: 14
Hardware: x86_64
OS: Linux
unspecified
medium
Target Milestone: ---
Assignee: Hans de Goede
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-03-31 07:49 UTC by Bjorge Solli
Modified: 2011-04-15 11:39 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2011-04-02 08:24:51 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
symlink file (107 bytes, application/octet-stream)
2011-04-15 07:44 UTC, Bjorge Solli
no flags Details
dir (3.94 KB, application/octet-stream)
2011-04-15 07:45 UTC, Bjorge Solli
no flags Details
fonts.scale (30.32 KB, text/plain)
2011-04-15 11:39 UTC, Hans de Goede
no flags Details

Description Bjorge Solli 2011-03-31 07:49:38 UTC
Description of problem:
Similar to https://bugzilla.redhat.com/show_bug.cgi?id=436981

Only I see this on every font selected!

Version-Release number of selected component (if applicable):
$ rpm -qa | egrep '(xfig|transfig)'
xfig-common-3.2.5-25.b.fc14.x86_64
xfig-3.2.5-25.b.fc14.x86_64
transfig-3.2.5d-1.fc14.x86_64

How reproducible:
Every time, for many users on many installations.

Steps to Reproduce:
1.Start xfig (/usr/bin/xfig)
2.Click on the "T" icon, for inputing text
3.Click anywhere on the page and start to input your text

Step 3 and 4 from the other issue are not necessary. This was done with the Times-Roman font.
  
Actual results:
A dialog box pops up saying "Can't find -urw-nimbus roman no9 l-medium-r-normal--13-*-*-*-*-*-ISO8859-*, using 6x13"
The text you enter is then a plain block text.

Expected results:
That the text you type is is the font you selected

Additional info:
Using -noscalablefonts disables the popup with the error, but it still does not use the correct font. Always plain block text.

I see others have not had this problem and wonder if I have different fonts than they have or more or less fonts installed. I cannot see the font used as an example in the other issue.

Using Sans Serif LaTeX font produces the error "Can't find -urw-nimbus sans l-medium-r-normal--13-*-*-*-*-*-ISO8859-*, using 6x13"

-Bjørge

Comment 1 Bjorge Solli 2011-03-31 07:51:56 UTC
I tried compiling xfig myself, but got the same problem. Maybe the problem is in dependencies?

Comment 2 Hans de Goede 2011-04-02 08:24:51 UTC
Hi,

Looks like something is wrong with your urw-fonts package installation. You should have urw-fonts
installed, since it is required by xfig-common, if not something has gone wrong with package installation,
to see if you have it installed do:
rpm -q urw-fonts

If this prints a version, verify it is installed correctly:
rpm --verify urw-fonts

This command should give no output.

If this works, likely the fonts.dir / fonts.scale file was not properly generated by the package install scripts for some reason. Open:
/etc/X11/fontpath.d/fonts-default/fonts.dir

In an text editor, the first line is the number of found fonts (in this dir) on my system it is 434
Then there are lots of lines like this one:
a010013l.pfb -urw-urw gothic l-medium-r-normal--0-0-0-0-p-0-iso10646-1

If this is not the case, we've found the cause of the problem. If this file looks fine, verify:
/etc/X11/fontpath.d/fonts-default/fonts.scale

Which should look the same. If either of them is bad, uninstall urw-fonts:
rpm -e --nodeps urw-fonts
And re-install it:
yum install urw-fonts

I hope this helps, either way please let me know the results.

I'm going to close this bug as notabug for now since I cannot reproduce, and this likely is caused by
an incomplete yum transaction, and thus the scripts not running or some such.

Regards,

Hans

Comment 3 Bjorge Solli 2011-04-05 08:34:06 UTC
I have this error on all my 600 Fedoras (well, at least all the ones I tested).

[root@ii122081 ~]# rpm -q urw-fonts
urw-fonts-2.4-9.fc13.noarch
[root@ii122081 ~]# rpm --verify urw-fonts
[root@ii122081 ~]# uname -a
Linux ii122081.klientdrift.uib.no 2.6.35.11-83.fc14.x86_64 #1 SMP Mon Feb 7 07:06:44 UTC 2011 x86_64 x86_64 x86_64 GNU/Linux

I find it strange that the package says fc13. Any ideas? It comes from the fedora repo.

Bjørge

Comment 4 Bjorge Solli 2011-04-05 08:40:20 UTC
[root@ii122081 ~]# head /etc/X11/fontpath.d/fonts-default/fonts.dir
598
a010013l.pfb -urw-urw gothic l-medium-r-normal--0-0-0-0-p-0-adobe-standard
a010013l.pfb -urw-urw gothic l-medium-r-normal--0-0-0-0-p-0-ascii-0
a010013l.pfb -urw-urw gothic l-medium-r-normal--0-0-0-0-p-0-iso10646-1
a010013l.pfb -urw-urw gothic l-medium-r-normal--0-0-0-0-p-0-iso8859-1
a010013l.pfb -urw-urw gothic l-medium-r-normal--0-0-0-0-p-0-iso8859-10
a010013l.pfb -urw-urw gothic l-medium-r-normal--0-0-0-0-p-0-iso8859-13
a010013l.pfb -urw-urw gothic l-medium-r-normal--0-0-0-0-p-0-iso8859-15
a010013l.pfb -urw-urw gothic l-medium-r-normal--0-0-0-0-p-0-iso8859-16
a010013l.pfb -urw-urw gothic l-medium-r-normal--0-0-0-0-p-0-iso8859-2
[root@ii122081 ~]# head /etc/X11/fontpath.d/fonts-default/fonts.scale
598
a010013l.pfb -urw-urw gothic l-medium-r-normal--0-0-0-0-p-0-adobe-standard
a010013l.pfb -urw-urw gothic l-medium-r-normal--0-0-0-0-p-0-ascii-0
a010013l.pfb -urw-urw gothic l-medium-r-normal--0-0-0-0-p-0-iso10646-1
a010013l.pfb -urw-urw gothic l-medium-r-normal--0-0-0-0-p-0-iso8859-1
a010013l.pfb -urw-urw gothic l-medium-r-normal--0-0-0-0-p-0-iso8859-10
a010013l.pfb -urw-urw gothic l-medium-r-normal--0-0-0-0-p-0-iso8859-13
a010013l.pfb -urw-urw gothic l-medium-r-normal--0-0-0-0-p-0-iso8859-15
a010013l.pfb -urw-urw gothic l-medium-r-normal--0-0-0-0-p-0-iso8859-16
a010013l.pfb -urw-urw gothic l-medium-r-normal--0-0-0-0-p-0-iso8859-2

Comment 5 Stanislav Ochotnicky 2011-04-05 08:49:04 UTC
(In reply to comment #3)
> I find it strange that the package says fc13. Any ideas? It comes from the
> fedora repo.

That's not a problem, F14 didn't have a mass rebuild so it inherited some packages from previous Fedoras

Comment 6 Hans de Goede 2011-04-05 09:01:02 UTC
Hmm, all I can think of as a cause is that your fontpath is not setup properly. Are you perhaps using an xorg.conf file ? Note that the use of that has been deprecated for quite a while ow. Now a days Xorg should automatically probe everything correct automatically.

Can you please attach /var/log/Xorg.0.log to this bug report, I'm specifically looking for lines like these:

[    11.995] (==) FontPath set to:
        catalogue:/etc/X11/fontpath.d,
        built-ins

If that looks different in your xorg log file that is likely the cause. If it does not look different maybe something has messed up your fontpath runtime?
(using xset fp) ?

Try:
xset fp default
xset fp rehash

And then start xfig again and see if you still have the problem.

Comment 7 Bjorge Solli 2011-04-05 10:26:57 UTC
No xorg.conf on this machine, but we do use it with the nvidia driver from rpmfusion (well, an xorg.conf.d/file.conf) on other machines.

The Xorg.0.log contained the lines you mentioned:
[195723.608] (==) FontPath set to:
        catalogue:/etc/X11/fontpath.d,
        built-ins

Do you want to see it all? `grep -i font` only got the two lines above.

I do think these two lines might have fixed the problem, but I have to get this confirmed from my end user which is back next week.

mkfontscale /usr/share/fonts/default/Type1/;
mkfontdir /usr/share/fonts/default/Type1/;

Bjørge

Comment 8 Bjorge Solli 2011-04-06 12:12:49 UTC
I have tested this on a new machine with similar setup. First I verified the problem, then I ran the two commands and tested again. The error persisted until the next reboot, but then it was solved.

I am wondering why my file contains more fonts than yours. Might the problem here might be that other packages might write to the same files and they don't do it correctly (running the commands afterwards)? How could I figure out what other packages write to those files? Or is there another reason why our files are different? rpm does not report the files as config files, maybe they should be?

Bjørge

Comment 9 Hans de Goede 2011-04-06 13:47:11 UTC
(In reply to comment #8)
> I have tested this on a new machine with similar setup. First I verified the
> problem, then I ran the two commands and tested again. The error persisted
> until the next reboot, but then it was solved.
> 
> I am wondering why my file contains more fonts than yours. Might the problem
> here might be that other packages might write to the same files and they don't
> do it correctly (running the commands afterwards)? How could I figure out what
> other packages write to those files? Or is there another reason why our files
> are different? rpm does not report the files as config files, maybe they should
> be?

It would be useful to check if your file after regenerating is reduced to the same amount as entries as mine. As to why they are different to begin with, I've no idea.

Regards,

Hans

Comment 10 Bjorge Solli 2011-04-11 06:38:26 UTC
Running

mkfontscale /usr/share/fonts/default/Type1/;
mkfontdir /usr/share/fonts/default/Type1/;

and then reboot, helped. The fonts are now appearing as separate styles, but although reportedly good enough, they do look different than before.

I have no more ideas on how to make them look as before.

xset fp default
xset fp rehash

did not make any difference, but might have fixed the original problem. Will investigate on this.

Regards,
Bjørge

Comment 11 Bjorge Solli 2011-04-14 06:50:02 UTC
Doing the xset commands on a machine with the original problem did not solve the original problem.

I checked all files in /usr/share/fonts/default/Type1 and /usr/share/fonts/default. They all belong to the rpm urw-fonts-2.4-9.fc13.noarch.

I also checked if removing it resulted in a smaller font number in the files:
--------------START-------------
[root@btest2 Type1]# rpm -e --nodeps urw-fonts

[root@btest2 Type1]# head /etc/X11/fontpath.d/fonts-default/fonts.dir
head: cannot open `/etc/X11/fontpath.d/fonts-default/fonts.dir' for reading: No such file or directory

[root@btest2 Type1]# head /etc/X11/fontpath.d/fonts-default/fonts.scale
head: cannot open `/etc/X11/fontpath.d/fonts-default/fonts.scale' for reading: No such file or directory

[root@btest2 Type1]# yum -y install urw-fonts
Loaded plugins: firefoxwarn, langpacks, presto, refresh-packagekit
------<snip>-------
Installing:
 urw-fonts                                          noarch                                          2.4-9.fc13                                           fedora                                          3.0 M
-------<snip>------
Installed:
  urw-fonts.noarch 0:2.4-9.fc13                                                                    
Complete!

[root@btest2 Type1]# head /etc/X11/fontpath.d/fonts-default/fonts.scale
598
a010013l.pfb -urw-urw gothic l-medium-r-normal--0-0-0-0-p-0-adobe-standard
a010013l.pfb -urw-urw gothic l-medium-r-normal--0-0-0-0-p-0-ascii-0
a010013l.pfb -urw-urw gothic l-medium-r-normal--0-0-0-0-p-0-iso10646-1
a010013l.pfb -urw-urw gothic l-medium-r-normal--0-0-0-0-p-0-iso8859-1
a010013l.pfb -urw-urw gothic l-medium-r-normal--0-0-0-0-p-0-iso8859-10
a010013l.pfb -urw-urw gothic l-medium-r-normal--0-0-0-0-p-0-iso8859-13
a010013l.pfb -urw-urw gothic l-medium-r-normal--0-0-0-0-p-0-iso8859-15
a010013l.pfb -urw-urw gothic l-medium-r-normal--0-0-0-0-p-0-iso8859-16
a010013l.pfb -urw-urw gothic l-medium-r-normal--0-0-0-0-p-0-iso8859-2

[root@btest2 Type1]# head /etc/X11/fontpath.d/fonts-default/fonts.dir
598
a010013l.pfb -urw-urw gothic l-medium-r-normal--0-0-0-0-p-0-adobe-standard
a010013l.pfb -urw-urw gothic l-medium-r-normal--0-0-0-0-p-0-ascii-0
a010013l.pfb -urw-urw gothic l-medium-r-normal--0-0-0-0-p-0-iso10646-1
a010013l.pfb -urw-urw gothic l-medium-r-normal--0-0-0-0-p-0-iso8859-1
a010013l.pfb -urw-urw gothic l-medium-r-normal--0-0-0-0-p-0-iso8859-10
a010013l.pfb -urw-urw gothic l-medium-r-normal--0-0-0-0-p-0-iso8859-13
a010013l.pfb -urw-urw gothic l-medium-r-normal--0-0-0-0-p-0-iso8859-15
a010013l.pfb -urw-urw gothic l-medium-r-normal--0-0-0-0-p-0-iso8859-16
a010013l.pfb -urw-urw gothic l-medium-r-normal--0-0-0-0-p-0-iso8859-2
[root@btest2 Type1]#

--------------END-------------

I really don't understand why my fonts-files are different from yours.

Any ideas on how to get the original look on the fonts?

Bjørge

Comment 12 Hans de Goede 2011-04-14 17:57:45 UTC
Hi,

(In reply to comment #11)
> Doing the xset commands on a machine with the original problem did not solve
> the original problem.
> 

<snip snip>

> 
> I really don't understand why my fonts-files are different from yours.

The only thing I can think of is the LANG environment variable influencing
fontdir generation.

What does printenv LANG say on your system? Also can you try running:
LANG=C mkfontdir /etc/X11/fontpath.d/fonts-default

As root and see if that makes any difference?

Comment 13 Bjorge Solli 2011-04-14 20:07:19 UTC
This did not change anything:

[root@it011015 ~]# head -n1 /etc/X11/fontpath.d/fonts-default/fonts.dir 
598
[root@it011015 ~]# printenv LANG
en_GB.UTF-8
[root@it011015 ~]# LANG=C mkfontdir /etc/X11/fontpath.d/fonts-default
[root@it011015 ~]# head -n1 /etc/X11/fontpath.d/fonts-default/fonts.dir 
598

Now I'm out of ideas.

Bjørge

Comment 14 Hans de Goede 2011-04-15 07:24:25 UTC
(In reply to comment #13)
> Now I'm out of ideas.
> 

I can think of some more or less random things to try to figure this one out.

First of all mkfontdir uses fonts.scale as a base, so you can do (as root again):
LANG=C mkfontscale /etc/X11/fontpath.d/fonts-default
LANG=C mkfontdir /etc/X11/fontpath.d/fonts-default

Also can you please do:
rpm -q xorg-x11-font-utils
which mkfontscale
which mkfontdir
And paste the output of all of those here ?

And also:
ls -l /etc/X11/fontpath.d/fonts-default > dir

And attach "dir" here (I want to see if maybe you just have more font files
there then I do).

Comment 15 Bjorge Solli 2011-04-15 07:42:43 UTC
As requested:

[root@solli ~]# LANG=C mkfontscale /etc/X11/fontpath.d/fonts-default
[root@solli ~]# LANG=C mkfontdir /etc/X11/fontpath.d/fonts-default
[root@solli ~]# head -n1 /etc/X11/fontpath.d/fonts-default/fonts.dir 
598
[root@solli ~]# head -n1 /etc/X11/fontpath.d/fonts-default/fonts.scale 
598
[root@solli ~]# rpm -q xorg-x11-font-utils
xorg-x11-font-utils-7.4-4.fc14.x86_64
[root@solli ~]# which mkfontscale
/usr/bin/mkfontscale
[root@solli ~]# which mkfontdir
/usr/bin/mkfontdir

I also did:
[root@solli fonts-default]# cd /etc/X11/fontpath.d/fonts-default;for foo in $(ls -1 /etc/X11/fontpath.d/fonts-default); do rpm -qf $foo; done| grep -v ^urw-fonts

Which returns no output (all files in dir come from urw-fonts package).

-b

Comment 16 Bjorge Solli 2011-04-15 07:44:39 UTC
Created attachment 492297 [details]
symlink file

ls -l /etc/X11/fontpath.d/fonts-default > symlink

Comment 17 Bjorge Solli 2011-04-15 07:45:12 UTC
Created attachment 492298 [details]
dir

ls -l /etc/X11/fontpath.d/fonts-default/ > dir

Comment 18 Bjorge Solli 2011-04-15 07:45:54 UTC
Also attatche are the output from

[root@solli tmp]# ls -l /etc/X11/fontpath.d/fonts-default/ > dir
[root@solli tmp]# ls -l /etc/X11/fontpath.d/fonts-default > symlink

Comment 19 Hans de Goede 2011-04-15 11:39:49 UTC
Created attachment 492351 [details]
fonts.scale

Hi,

Your /etc/X11/fontpath.d/fonts-default/ dir seems to be identical to mine, no idea why your mkfontscale output differers I'm afraid.

I've attached my fonts.scale file, rerunning mkfontdir after overwriting your fonts.scale with this will likely fix your xfig issues. This is still no answer as to why this is happening though :|

Regards,

Hans


Note You need to log in before you can comment on or make changes to this bug.