VectorLinux
July 23, 2014, 05:19:54 am *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
News: Visit our home page for VL info. To search the old message board go to http://vectorlinux.com/forum1. The first VL forum is temporarily offline until we can find a host for it. Thanks for your patience.
 
Now powered by KnowledgeDex.
   Home   Help Search Login Register  
Please support VectorLinux!
Pages: [1]
  Print  
Author Topic: Can't install font package  (Read 1752 times)
JHAx86
Member
*
Posts: 22



« on: November 28, 2008, 08:29:41 am »

Hi all,

I installed the IPA fonts to be able to display japanese fonts in firefox, but even after add their paths to the Path section of xorg.conf file they are not available for firefox nor AbiWord, etc. I am studying that language so I need to be able to display its native characters.

Thanks for read.
Logged
kukibl
Guest
« Reply #1 on: November 28, 2008, 09:06:11 am »

How did you install them? By manually copying font files to some directory or by installing some VL/Slackware package?

I don't know much about fonts, but I think you should cd to directory where you installed new fonts, then as root:

Code:
#mkfontdir
#fc-cache
 -a
 

Hope it helps.
Logged
JHAx86
Member
*
Posts: 22



« Reply #2 on: November 28, 2008, 10:11:52 am »

Hi, thanks for the answer,

First of all, I installed those fonts from a slackware package.
I followed your instructions but the fonts don't appear to be available for any application.

I also tried:

mkfontdir
fc-cache -f -v

and fc-cache said:
/usr/share/fonts/OTF: caching, 23 fonts, 0 dirs
/usr/share/fonts/TTF: caching, 75 fonts, 0 dirs
/root/.fonts: skipping, no such directory
/var/cache/fontconfig: cleaning cache directory
/root/.fontconfig: not cleaning unwritable cache directory
fc-cache: succeeded

My ipa fonts dir is /usr/share/fonts/ipa and it appears not to be scanned for fc-cache. Any idea?

Thanks.
Logged
kukibl
Guest
« Reply #3 on: November 28, 2008, 04:08:44 pm »

Probably it is not the most elegant solution Grin, but maybe you should copy your fonts to directory that is scanned by fc-cache (/usr/share/fonts/TTF - for example) and then run fc-cache. Just an idea... I hope someone else will come up with better solution. Undecided
Logged
GrannyGeek
Packager
Vectorian
****
Posts: 2567


« Reply #4 on: November 28, 2008, 06:47:08 pm »

I use tons of my own fonts and the easiest way I've found to add them is this:
*  create a /.fonts directory in your home directory
*  add your fonts there
*  run fc-cache

A /.fonts directory in your home directory will be scanned for fonts. The fonts will be available only to you, not system wide. There are ways you can add the fonts so they're available to all users, but it's more complicated, has to be done as root, and requires modifying various system files in /etc. Also, I think the way fonts are installed system wide has changed recently. However, if I do it the old way it does work though every step probably isn't necessary. I'll tell you what has worked for me if you're interested.

However, if you're the only user (or you don't mind doing it for each user), the /.fonts and fc-cache is the easiest way. You can run fc-cache as user if you're adding fonts to ~/.fonts.
--GrannyGeek
Logged

Registered Linux User #397786

Happily running VL 7 Gold on  a Sempron LE-1300 desktop (2.3 GHz), 4 G RAM,  GeForce 6150 SE onboard graphics and on an HP Pavilion dv7 i7, 6 gigs, Intel 2nd Generation Integrated Graphics Controller
JHAx86
Member
*
Posts: 22



« Reply #5 on: November 28, 2008, 07:52:28 pm »

I had the same idea than kukibl and ended copy and paste the fonts manually inside TTF directory. This way I was able to see the fonts in Firefox, Sea Monkey and AbiWord. But "it is not the most elegant solution", the original package installed to /usr/share/fonts/ipa for some reason and there must be a way to make it work.

Anyway, for now this works for me. I will try Anthy later.

Thanks both of you for the help, if you find an explanation to my problem, please tell me about it.

Goodbye.
Logged
GrannyGeek
Packager
Vectorian
****
Posts: 2567


« Reply #6 on: November 28, 2008, 08:20:37 pm »

the original package installed to /usr/share/fonts/ipa for some reason and there must be a way to make it work.

If you take these steps, I think the fonts will be found and made active. You have to do them as root.

* Move the fonts to /usr/share/fonts/ipa. In /usr/share/fonts/ipa run these commands at a terminal prompt:
mkfontscale
mkfontdir

*  Edit /etc/X11/xorg.conf by adding in Section "Files":
FontPath     "/usr/share/fonts/ipa"

*  Go to /etc/fonts and copy fonts.conf to local.conf. Edit local.conf by adding this line to
<!-- Font directory list -->                                                   
                                                                               
        <dir>/usr/share/fonts/ipa</dir>         

*  As root run fc-cache

* Restart the X server and your window manager.

Your added fonts should now appear in the list and be available to all users.

It may be that all these steps aren't necessary, but when I do them all I do have the fonts available system wide. I think you can see why I prefer to simply put the fonts into ~/.fonts.

Of course, if you want to give this a try, you should move the fonts from /usr/share/fonts/TTF to /usr/share/fonts/ipa.
--GrannyGeek
« Last Edit: November 28, 2008, 08:23:14 pm by GrannyGeek » Logged

Registered Linux User #397786

Happily running VL 7 Gold on  a Sempron LE-1300 desktop (2.3 GHz), 4 G RAM,  GeForce 6150 SE onboard graphics and on an HP Pavilion dv7 i7, 6 gigs, Intel 2nd Generation Integrated Graphics Controller
JHAx86
Member
*
Posts: 22



« Reply #7 on: November 29, 2008, 01:55:34 pm »

Thank you. Yes, that works.

After follow the steps you told me, fc-cache said this:

/usr/share/fonts/OTF: caching, 23 fonts, 0 dirs
/usr/share/fonts/TTF: caching, 75 fonts, 0 dirs
/usr/share/fonts/ipa: caching, 5 fonts, 0 dirs
/root/.fonts: skipping, no such directory
/var/cache/fontconfig: cleaning cache directory
/root/.fontconfig: not cleaning unwritable cache directory
fc-cache: succeeded

It seems that the step I was missing was to edit local.conf, remember that the ipa directory was already added to section "File". About calling mkfontscale, the package already came with .scale, .dir and .alias files, so I jumped that step. Also, I was unable to locate a local.conf file so I created one in the font.conf directory in order to be able to follow your instructions. After doing that, that five fonts exists only in /usr/share/fonts/ipa and they can be used normally.

Thank you again, goodbye.
Logged
GrannyGeek
Packager
Vectorian
****
Posts: 2567


« Reply #8 on: November 29, 2008, 09:05:29 pm »

I'm glad to hear your fonts are now available.
--GrannyGeek
Logged

Registered Linux User #397786

Happily running VL 7 Gold on  a Sempron LE-1300 desktop (2.3 GHz), 4 G RAM,  GeForce 6150 SE onboard graphics and on an HP Pavilion dv7 i7, 6 gigs, Intel 2nd Generation Integrated Graphics Controller
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2013, Simple Machines Valid XHTML 1.0! Valid CSS!