You are not logged in.

#1 2010-09-07 23:35:07

jalu
Member
Registered: 2009-04-05
Posts: 140

fonts.conf: Creating a font alias for specific programs only?

The Wiki provides great documentation on creating an "alias" for a font. Aliases allow a user to say something like, for example, "Whenever a program tries to use Helvetica, use Bitstream Vera Sans instead".

Is it possible to do this for specific programs only? I don't want to replace Helvetica with Bitstream Vera Sans wholesale, but I do want to replace Helvetica with Bitstream Vera Sans in all Flash programs. (Flash doesn't fallback to a default font. If you don't have the font that the author of a Flash program used, you're sadly out of luck and see no text.)

Any insight would be greatly appreciated. Thanks!

Offline

#2 2010-09-08 00:59:26

LeafStorm
Member
From: North Carolina
Registered: 2009-05-20
Posts: 51
Website

Re: fonts.conf: Creating a font alias for specific programs only?

jalu wrote:

Is it possible to do this for specific programs only? I don't want to replace Helvetica with Bitstream Vera Sans wholesale, but I do want to replace Helvetica with Bitstream Vera Sans in all Flash programs.

As far as I can tell from reading the fontconfig docs, probably not. If you were insane enough, you could wrap the libflashplayer.so library with a stub that defines a fake FcInit function that loads a specialized Flash config instead of the default, but I don't know how to do that or if that's even possible. (Not to mention it would be gigantic overkill.) Sorry.


Thanks,
Matthew Frazier

Offline

#3 2010-09-08 01:27:10

frabjous
Member
Registered: 2010-07-13
Posts: 367

Re: fonts.conf: Creating a font alias for specific programs only?

I hope someone knows the answer to your question: this would be really great.

But in the meantime... well, I can understand that you wouldn't want to alias Helvetica to Bitstream Vera Sans, since those two fonts are clearly distinct, but is there a reason you don't want to alias Helvetica to one of its free, open sourced clones, like Nimbus Sans L (which you probably already have installed) or TeX Gyre Heros?

If you can tell the difference between those and Helvetica, you deserve a medal. I can't tell the difference, and I'm someone who can easily tell the difference between, e.g., Helvetica and Arial, which is more often used as a replacement.

Offline

#4 2010-09-08 01:54:47

jalu
Member
Registered: 2009-04-05
Posts: 140

Re: fonts.conf: Creating a font alias for specific programs only?

Interesting thoughts, frabjous.

I used Bitstream Vera Sans in my example because it is what the documentation uses, but you make a good point about aliasing Helvetica to a true replacement. I'll definitely keep it in mind.

As an aside, this is something I've always wondered about -- what about Nimbus Sans L makes it free? If it looks identical, why isn't it infringing Helvetica's copyright in some way? Is it the implementation that is free?

Offline

#5 2010-09-08 02:18:07

frabjous
Member
Registered: 2010-07-13
Posts: 367

Re: fonts.conf: Creating a font alias for specific programs only?

At least in the United States, typeface designs cannot be put under copyright. You can copyright the name, and you can copyright the software itself, but not the overall look, unless it's distinct enough that it falls under another artistic category. Helvetica manifestly isn't that; in fact, it borrows heavily from previous typefaces in the Grotesk family. In fact, the Nimbus Sans family is itself older than Helvetica, though Nimbus Sans L itself isn't. This was the URW foundry's version of Helvetica. I'm not entirely sure, but I think URW went bankrupt, and either lost the rights to their fonts as part of a legal settlement, or deliberately gave up those rights. In any case, you'll find a lot of URW fonts under the GPL or similar license (e.g. LPPL).

A lot of the other free fonts, like the TeX Gyre fonts, are modifications of these URW fonts. TeX Gyre Heros is an extended and updated version of Nimbus Sans L, and obviously therefore under a similar license.

Last edited by frabjous (2010-09-08 02:20:41)

Offline

#6 2010-09-08 02:36:23

jalu
Member
Registered: 2009-04-05
Posts: 140

Re: fonts.conf: Creating a font alias for specific programs only?

Very, very interesting.

I just ran across a URW font today, URW Palladio L. In fact, this is what got me into the whole fonts.conf craze in the first place. Apparently, Palatino is known to render badly in Unix. By applying the configuration suggested in the link, I was able to fix my issue.

Anyway, I still think the original question is interesting, though it doesn't look like there is an easy way to do what I had originally hoped.

Offline

#7 2010-09-08 05:56:32

frabjous
Member
Registered: 2010-07-13
Posts: 367

Re: fonts.conf: Creating a font alias for specific programs only?

I'm still hoping someone else might have an idea about how to address your original question.

Anyway, this discussion made me realize that the TeX Gyre fonts hadn't been packaged for Arch, so I went ahead and made some a PKGBUILD for them, otf-texgyre (and one other for another open source font I like) and uploaded them to AUR. My first public PKGBUILDs; I hope I didn't screw them up too badly!

Anyway, you might be interested in TeX Gyre Pagella, which is an extended version of the URW Palladio L Palatino clone. The collection also has clones of Times, Courier, New Century Schoolbook, Zapf Chancery, Century Gothic and ITC Bookman. The other font PKGBUILD I uploaded (otf-goudy) is for a clone of Goudy Old Style. From what I've seen, most common fonts have a nice, sometimes higher quality, open source clone.

Offline

#8 2010-09-08 06:16:48

brebs
Member
Registered: 2007-04-03
Posts: 3,742

Re: fonts.conf: Creating a font alias for specific programs only?

frabjous wrote:

the TeX Gyre fonts hadn't been packaged

They are part of the texlive behemoth.

Offline

#9 2010-09-08 21:06:38

frabjous
Member
Registered: 2010-07-13
Posts: 367

Re: fonts.conf: Creating a font alias for specific programs only?

brebs wrote:
frabjous wrote:

the TeX Gyre fonts hadn't been packaged

They are part of the texlive behemoth.

Didn't think of that, but I think it's worth having them separately available, in just otf format. (The TeX packages probably use Type-1 fonts.)

Last edited by frabjous (2010-09-08 21:08:04)

Offline

#10 2010-09-12 20:20:46

jalu
Member
Registered: 2009-04-05
Posts: 140

Re: fonts.conf: Creating a font alias for specific programs only?

So as it turns out, I installed the ttf-liberation fonts. These fonts, together with the default aliases provided by fontconfig (fontconfig aliases MS fonts to liberation equivalents by default), resolved my issue of sometimes not being able to see text in Flash programs.

I'll leave this thread as unsolved, as the original question remains open.

Thanks to everyone, especially frabjous, for the help.

Last edited by jalu (2010-09-12 20:21:08)

Offline

Board footer

Powered by FluxBB