Monday, August 15th, 2011, 04:36 UTC | ||
[04:36:18] | k-man: | so on my linux box, CartoGothic is called "CartoGothic Std" however on my mac, it is called "CartoGothic Std <weight>" where weight is the weight of the font |
[04:36:45] | k-man: | this breaks the fontdefs on either mac or linux depending on wich way I define the font |
[04:40:56] | k-man: | can you somehow define multiple choies? like Try font X, if that fails, try font Y? |
[07:48:09] | simonckenyon (simonckenyon!~simoncken@195.7.61.12) has joined #mythtv-theming | |
[09:19:56] | simonckenyon (simonckenyon!~simoncken@195.7.61.12) has quit (Remote host closed the connection) | |
[09:26:37] | simonckenyon (simonckenyon!~simoncken@195.7.61.12) has joined #mythtv-theming | |
[13:56:52] | sphery: | k-man: -v gui,file,extra actually shows a different name for the font name at the end of: In file '%1', found font(s) '%2' , depending on platform? If so, it sounds like Mac OS X Qt isn't using fontconfig for font management, and is using whatever Mac OS X uses--which must have incompatible naming. |
[13:58:29] | k-man: | sphery, I'll double check hang on |
[14:02:20] | k-man: | sphery, yes, it appears that way: http://pastie.org/2375326 |
[14:02:58] | k-man: | that was the output from my mac |
[14:03:43] | k-man: | very annoying |
[14:06:31] | sphery: | If that's the case, I suppose it would be possible to modify our font loading to check exactMatch() ( http://doc.trolltech.com/4.6/qfont.html#exactMatch ), and if it's false try some fallback face name--with appropriate changes to the theme code to allow specifying fallback faces... like face="CartoGothic Std, CartoGothic Std <weight>, Helvetica, Sans Serif" (similar to CSS style font-family). And, with that approach, we could have a ... |
[14:06:37] | sphery: | ... fallback "generic" family names at the end that we prefer with styleHint() ( http://doc.trolltech.com/4.6/qfont.html#styleHint + http://doc.trolltech.com/4.6/qfont.html#StyleHint-enum ). Though it would still be a different font (unless you actually wanted Helvetica or whatever), it would allow you to specify a fallback that would definitely have a certain style (sans serif, serif, typewriter, etc.). |
[14:07:38] | sphery: | Might want to ask the guys who know the UI stuff (stuartm, iamlindoro, etc.) if they would support such an approach, and if so, you could work on a patch if you like? |
[14:09:37] | k-man: | hehe |
[14:09:38] | k-man: | joy |
[14:10:29] | k-man: | maybe there is some way to get the correct font names? |
[14:10:33] | k-man: | I mean in osx |
[14:11:17] | k-man: | anyway, I have to go to bed |
[14:11:17] | justinh: | use a font editor? ;-) |
[14:11:28] | k-man: | :) |
[14:12:09] | k-man: | ok, night all |
[14:12:39] | sphery: | Heh, it should be a pretty good patch to get start with... There's already code checking exactMatch()--and then complaining loudly in the log files when you get a different font--so it's just a matter of having it try some fallbacks before it complains. |
[14:13:43] | sphery: | k-man: the font name that's output is the name that Qt sees, which is the name provided by the underlying platform's font management. So, it sounds like Mac OS X font naming/matching is incompatible with fontconfig's. |
[14:14:41] | justinh: | Think Different (TM) ? ;-) |
[14:14:52] | sphery: | which means there isn't any "correct font name"--it's different on different platforms due to different font managers |
[14:14:53] | justinh: | or was that somebody else's TM? |
[14:15:31] | sphery: | heh, yeah, it's Apple's :) |
[14:15:40] | sphery: | and very appropriate, it seems |
[14:15:59] | justinh: | they never saw cross-platform apps coming |
[14:16:19] | justinh: | mind, I found it hard initially to work out font names in linux |
[14:16:27] | justinh: | linux/qt/whatever |
[14:17:19] | sphery: | yeah... with the MythFontManager, it should be easy enough, now--just use -v file,gui,extra (or in master -v gui,extra) and see: In file '/Users/jason/.mythtv/themes/MythCenterNew/CartoGothicStd-Bold.otf', found font(s) 'CartoGothic Std Bold' |
[14:17:51] | justinh: | I dunno much about font files themselves but I'm guessing there's more than one name field |
[14:18:12] | sphery: | (oh, you only get the log statement if you put the actually ttf or otf into the theme dir) |
[14:18:25] | justinh: | sphery: good enough for me :) |
[14:20:59] | sphery: | open up a font in fontforge and you'll see the actual name in Element|Font Info... It has Fontname, Family Name (which is what Qt uses), and Name for Humans (which is often the same as Family Name)... It seems that Mac OS X font manager uses a combination of Family Name and Weight, based on k-man's description. |
[14:21:42] | justinh: | methinks me opening a font in fontforge is the thin edge of a very slippery slope ;) |
[14:21:57] | sphery: | I think those are the only supported names for ttf/otf--but if OS X is using more Adobe PS fonts or something, it may be different |
[14:49:56] | natanojl (natanojl!~jonatan@c83-252-237-63.bredband.comhem.se) has joined #mythtv-theming | |
[15:12:24] | natanojl (natanojl!~jonatan@c83-252-237-63.bredband.comhem.se) has quit (Ping timeout: 258 seconds) | |
[19:39:29] | natanojl (natanojl!~jonatan@c83-252-237-63.bredband.comhem.se) has joined #mythtv-theming | |
[22:59:18] | natanojl (natanojl!~jonatan@c83-252-237-63.bredband.comhem.se) has quit (Ping timeout: 246 seconds) |
IRC Logs collected by
BeirdoBot.
Please use the above link to report any bugs.