LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Red Hat
User Name
Password
Red Hat This forum is for the discussion of Red Hat Linux.

Notices


Reply
  Search this Thread
Old 08-17-2011, 04:13 PM   #1
roygbiiv
LQ Newbie
 
Registered: May 2011
Distribution: Arch Linux
Posts: 25

Rep: Reputation: 13
Installing fonts as non-root user


I want to use the nice looking Tamsyn programming font for my terminals on the universitys Red Hat pc's, but obviously I don't have root privileges there. By using it I mean to put something like this in an .Xresources file and make it work in the terminal:
Code:
XTerm.font:    xft:Tamsyn:size=10
The font directory downloaded from the Tamsyn website contains the following files:

Code:
-rw------- 1 wictorht wictorht  18K 2011-02-09 09:09 Tamsyn6x11b.pcf
-rw------- 1 wictorht wictorht 3.3K 2011-02-09 09:09 Tamsyn6x11b.psf
-rw------- 1 wictorht wictorht  18K 2011-02-09 09:09 Tamsyn6x11r.pcf
-rw------- 1 wictorht wictorht 3.3K 2011-02-09 09:09 Tamsyn6x11r.psf
-rw------- 1 wictorht wictorht  19K 2011-02-09 09:09 Tamsyn7x12b.pcf
-rw------- 1 wictorht wictorht 3.6K 2011-02-09 09:09 Tamsyn7x12b.psf
-rw------- 1 wictorht wictorht  19K 2011-02-09 09:09 Tamsyn7x12r.pcf
-rw------- 1 wictorht wictorht 3.6K 2011-02-09 09:09 Tamsyn7x12r.psf
-rw------- 1 wictorht wictorht  20K 2011-02-09 09:09 Tamsyn7x14b.pcf
-rw------- 1 wictorht wictorht 4.1K 2011-02-09 09:09 Tamsyn7x14b.psf
-rw------- 1 wictorht wictorht  21K 2011-02-09 09:09 Tamsyn7x14r.pcf
-rw------- 1 wictorht wictorht 4.1K 2011-02-09 09:09 Tamsyn7x14r.psf
-rw------- 1 wictorht wictorht  21K 2011-02-09 09:09 Tamsyn8x15b.pcf
-rw------- 1 wictorht wictorht 4.3K 2011-02-09 09:09 Tamsyn8x15b.psf
-rw------- 1 wictorht wictorht  21K 2011-02-09 09:09 Tamsyn8x15r.pcf
-rw------- 1 wictorht wictorht 4.3K 2011-02-09 09:09 Tamsyn8x15r.psf
-rw------- 1 wictorht wictorht  23K 2011-02-09 09:09 Tamsyn8x17b.pcf
-rw------- 1 wictorht wictorht 4.8K 2011-02-09 09:09 Tamsyn8x17b.psf
-rw------- 1 wictorht wictorht  23K 2011-02-09 09:09 Tamsyn8x17r.pcf
-rw------- 1 wictorht wictorht 4.8K 2011-02-09 09:09 Tamsyn8x17r.psf
How can I possibly install or enable this font for my user without root privileges? Any answer possibly leading me somewhere is great, as I don't have experience with installing fonts manually on my other pc running Arch Linux.

Thanks
 
Old 08-18-2011, 09:54 AM   #2
andrewthomas
Senior Member
 
Registered: May 2010
Location: Chicago Metro
Distribution: Arch, Gentoo, Slackware
Posts: 1,690

Rep: Reputation: 312Reputation: 312Reputation: 312Reputation: 312
The ~/.fonts directory can be used for installing fonts locally.

Create it if it does not exist.
 
Old 08-18-2011, 01:49 PM   #3
roygbiiv
LQ Newbie
 
Registered: May 2011
Distribution: Arch Linux
Posts: 25

Original Poster
Rep: Reputation: 13
Thanks alot! I have put all the files in ~/.fonts dir and the fonts works fine with gnome-terminal. That was easy! But wait... what? It does not work with Xterm and my ~/.Xresources file?
Code:
XTerm.faceName: xft:Tamsyn:size=10
!or
XTerm.faceName: xft:Tamsyn:pixelsize=10
Any suggestions people?

Some output:
Code:
fc-list | grep Tamsyn
Tamsyn:style=Regular
Tamsyn:style=Bold

Last edited by roygbiiv; 08-18-2011 at 02:31 PM. Reason: Added more info
 
Old 08-18-2011, 02:56 PM   #4
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,511

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
man xterm http://linux.die.net/man/1/xterm

I am not sure, that you can trick xterm to use other fonts,
than those compiled into the binary ?

More information : cat /usr/lib/X11/app-defaults/Xterm
> > Using a different font, example :
xterm -fn -misc-fixed-medium-r-normal--20-200-75-75-c-100-iso10646-1

.
 
Old 08-18-2011, 03:03 PM   #5
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,511

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
*

Sorry, it's "/usr/share/X11/app-defaults/XTerm" in Redhat EL 5.

And: The example in #4 also works with : xterm -fn 10x20

..

Last edited by knudfl; 08-18-2011 at 03:08 PM.
 
Old 08-18-2011, 03:16 PM   #6
roygbiiv
LQ Newbie
 
Registered: May 2011
Distribution: Arch Linux
Posts: 25

Original Poster
Rep: Reputation: 13
Thank, but /usr/share/X11/app-defaults/ is empty.

I tried putting the following in an .Xdefaults instead, but it didn't work:
Code:
XTerm*faceName:             Tamsyn
XTerm*faceSize:             10
Don't know if this has something to do with the xterm version at school:
Code:
me@school $ xterm -version
XTerm(215)
me@home $ xterm -version
XTerm(271)
I will check if this works on my own computer.
 
Old 08-18-2011, 03:54 PM   #7
roygbiiv
LQ Newbie
 
Registered: May 2011
Distribution: Arch Linux
Posts: 25

Original Poster
Rep: Reputation: 13
Ok, I think found a solution.

On my homecomputer the font worked perfectly by putting the *.pcf file into the ~/.fonts dir and having this setting in ~/.Xresources:
Code:
XTerm*faceName: xft:Tamsyn:size=10
and also by specifying the font on the command line:
Code:
$ xterm -fa xft:Tamsyn -fs 10
On my school computer it doesn't seem to like xft, so it falls back to Bistream Vera Sans Mono - by ommitting xft it seems that it works:
Code:
$ xterm -fa Tamsyn -fs 10
 
1 members found this post helpful.
Old 08-18-2011, 04:36 PM   #8
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,511

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
Quote:
xterm -fa Tamsyn -fs 10
Well done. Works here too with the Tamsyn fonts in /usr/share/fonts/misc/


But I still think, you get a much nicer font with : xterm -fn 10x20
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
no fonts under non-root user deggial Slackware 8 04-11-2006 10:30 AM
Fonts ok as root, but bad as user BroX Debian 11 11-01-2004 03:30 AM
Firefox fonts look awful for user, great for root. Raoul_Duke_M Slackware 8 10-01-2004 05:55 PM
9.2 strange fonts for user root daffyduke Mandriva 2 02-02-2004 06:37 PM
truetype fonts fail to display in any user but root... Thikasabrik Linux - Software 2 09-05-2003 11:14 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Red Hat

All times are GMT -5. The time now is 02:11 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration