unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* Parsing of fontconfig font names and other font related stuff.
@ 2009-07-07 18:57 Jan Djärv
  2009-07-08  0:55 ` Kenichi Handa
  2009-07-08  7:12 ` Yavor Doganov
  0 siblings, 2 replies; 18+ messages in thread
From: Jan Djärv @ 2009-07-07 18:57 UTC (permalink / raw)
  To: Emacs-Devel

Hello.

I'm in the process of getting Emacs to use GConf defaults for font, 
antialiasing, hints and dpi.

The parser in Emacs does not accept "Monospace 8:dpi=96.0".
First float values for dpi is not accepted, even they are floats in fontconfig.
Secondly spaces before the size isn't accepted either, it is assumed to be in 
Gtk+-format when a space is there.

But fc-match do accept that type of font specification, as do all applications 
I tried that has xft.  Admittedly, the docs (the user manual) seem to indicate 
that a '-' is required before the size.

Ideally I wouldn't like to put stuff like dpi in the font string, but instead 
have the appropriate backend use the GConf value if no other value is 
specified.  Where would it be appropriate to insert that information?  In the 
xft-backend or in Ffont-spec, or perhaps somewhere else?

Thanks,

	Jan D.




^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: Parsing of fontconfig font names and other font related stuff.
  2009-07-07 18:57 Parsing of fontconfig font names and other font related stuff Jan Djärv
@ 2009-07-08  0:55 ` Kenichi Handa
  2009-07-08  8:36   ` Jan Djärv
  2009-07-08  7:12 ` Yavor Doganov
  1 sibling, 1 reply; 18+ messages in thread
From: Kenichi Handa @ 2009-07-08  0:55 UTC (permalink / raw)
  To: =?UTF-8?B?SmFuIERqw6Rydg==?=; +Cc: emacs-devel

In article <4A539AB0.3010605@swipnet.se>, =?UTF-8?B?SmFuIERqw6Rydg==?= <jan.h.d@swipnet.se> writes:

> I'm in the process of getting Emacs to use GConf defaults for font, 
> antialiasing, hints and dpi.

> The parser in Emacs does not accept "Monospace 8:dpi=96.0".
> First float values for dpi is not accepted, even they are floats in fontconfig.
> Secondly spaces before the size isn't accepted either, it is assumed to be in 
> Gtk+-format when a space is there.

> But fc-match do accept that type of font specification, as do all applications 
> I tried that has xft.  Admittedly, the docs (the user manual) seem to indicate 
> that a '-' is required before the size.

At least fc-match doesn't treat this kind of format
correctly; "Monospace 8".  But, I agree that
font_parse_fcname in font.c should be improved.

> Ideally I wouldn't like to put stuff like dpi in the font string, but instead 
> have the appropriate backend use the GConf value if no other value is 
> specified.  Where would it be appropriate to insert that information?  In the 
> xft-backend or in Ffont-spec, or perhaps somewhere else?

I think it should be done in xft-backend.

By the way, a spec for searching for a font, and a spec for
using the found font should be different.  I think
antialiasing and hints are specs of the latter category.
Currently Emacs doesn't distinguish them.  This should be
fixed somehow.

And, I don't know what dpi is for.  That information should
be available via X server.  Is it a way to pretend that you
are using a screen of the different DPI?

---
Kenichi Handa
handa@m17n.org




^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: Parsing of fontconfig font names and other font related stuff.
  2009-07-07 18:57 Parsing of fontconfig font names and other font related stuff Jan Djärv
  2009-07-08  0:55 ` Kenichi Handa
@ 2009-07-08  7:12 ` Yavor Doganov
  2009-07-08  8:56   ` Jan Djärv
  1 sibling, 1 reply; 18+ messages in thread
From: Yavor Doganov @ 2009-07-08  7:12 UTC (permalink / raw)
  To: emacs-devel

Jan Djärv wrote:
> I'm in the process of getting Emacs to use GConf defaults for font, 
> antialiasing, hints and dpi.

Are you sure this is a good idea?  AFAIK there are plans to deprecate
GConf for GNOME 3.0 next year, and replace it with dconf/GSettings.
The precise plan is not clear yet, I think.

GConf is also not used in other GTK+ based desktops like Xfce/LXDE and
of course anything that's not GNOME.





^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: Parsing of fontconfig font names and other font related stuff.
  2009-07-08  0:55 ` Kenichi Handa
@ 2009-07-08  8:36   ` Jan Djärv
  2009-07-08 11:27     ` Jason Rumney
  2009-07-08 12:09     ` Jan Djärv
  0 siblings, 2 replies; 18+ messages in thread
From: Jan Djärv @ 2009-07-08  8:36 UTC (permalink / raw)
  To: Kenichi Handa; +Cc: emacs-devel

Kenichi Handa skrev:
> In article <4A539AB0.3010605@swipnet.se>, =?UTF-8?B?SmFuIERqw6Rydg==?= <jan.h.d@swipnet.se> writes:
> 
>> I'm in the process of getting Emacs to use GConf defaults for font, 
>> antialiasing, hints and dpi.
> 
>> The parser in Emacs does not accept "Monospace 8:dpi=96.0".
>> First float values for dpi is not accepted, even they are floats in fontconfig.
>> Secondly spaces before the size isn't accepted either, it is assumed to be in 
>> Gtk+-format when a space is there.
> 
>> But fc-match do accept that type of font specification, as do all applications 
>> I tried that has xft.  Admittedly, the docs (the user manual) seem to indicate 
>> that a '-' is required before the size.
> 
> At least fc-match doesn't treat this kind of format
> correctly; "Monospace 8".  But, I agree that
> font_parse_fcname in font.c should be improved.
> 

The problem is that in Gnome the default monospaced font has the format, i.e. 
space instead of -.  But it isn't that important, I was just playing around 
with different dpi values.  It isn't required for the GConf stuff to work.

>> Ideally I wouldn't like to put stuff like dpi in the font string, but instead 
>> have the appropriate backend use the GConf value if no other value is 
>> specified.  Where would it be appropriate to insert that information?  In the 
>> xft-backend or in Ffont-spec, or perhaps somewhere else?
> 
> I think it should be done in xft-backend.

That makes sense.

> 
> By the way, a spec for searching for a font, and a spec for
> using the found font should be different.  I think
> antialiasing and hints are specs of the latter category.
> Currently Emacs doesn't distinguish them.  This should be
> fixed somehow.

I don't quite follow.  Isn't it plausable that a user wants to search for 
fonts that are antialiased?

> 
> And, I don't know what dpi is for.  That information should
> be available via X server.  Is it a way to pretend that you
> are using a screen of the different DPI?

Yes.  Gnome has 96 dpi as default (settable in a user desktop settings 
dialog), fontconfig seems to have 75. My monitor is actually 84 dpi.  Other 
applications in Gnome, like gnome-terminal, uses the 96 dpi value, but Emacs 
uses the default.  That makes Emacs and gnome-terminal look different even 
though they both use monospace-8.

So I'd like Emacs to react to changes in the user desktop settings for these 
values.  This would enable Emacs to use the same default monospaced font as 
other applications, and also change font, dpi, etc. on the fly, as 
Gnome-applications do,  when the user changes it in the desktop settings.

	Jan D.




^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: Parsing of fontconfig font names and other font related stuff.
  2009-07-08  7:12 ` Yavor Doganov
@ 2009-07-08  8:56   ` Jan Djärv
  2009-07-08 10:01     ` Yavor Doganov
  2009-07-14 14:55     ` Jan Djärv
  0 siblings, 2 replies; 18+ messages in thread
From: Jan Djärv @ 2009-07-08  8:56 UTC (permalink / raw)
  To: Emacs-Devel, yavor

Yavor Doganov skrev:
> Jan Djärv wrote:
>> I'm in the process of getting Emacs to use GConf defaults for font, 
>> antialiasing, hints and dpi.
> 
> Are you sure this is a good idea?  AFAIK there are plans to deprecate
> GConf for GNOME 3.0 next year, and replace it with dconf/GSettings.
> The precise plan is not clear yet, I think.

Well, if it isn't clear, we must work with what we have :-)
Yes I think it is a good idea.  As I said in my reply to Handa-san, the dpi 
values used by Emacs and other Gnome applications doesn't match, so Emacs 
looks different even if it uses the same font.

It would also be nice to have Emacs use the same hinting and antialiasing as 
other applications.  We get a free GUI for setting these things (Gnome desktop 
preferences).  It is somewhat cumbersome to set these in Emacs now.

If the infrastructure to set these values from desktop preferences are in 
place it is easy to change the actual means of getting the values, be it 
GConf, dconf or whatever.

It is not like the whole world will switch to Gnome 3.0 the second it is 
released.  But if there will be a new Emacs release that isn't just bug fixes 
before Gnome 3.0 is another matter :-).

> 
> GConf is also not used in other GTK+ based desktops like Xfce/LXDE and
> of course anything that's not GNOME.

Nor does KDE.  Gnome is the GNU desktop after all.  It will fallback to not 
using GConf if it isn't present.

	Jan D.





^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: Parsing of fontconfig font names and other font related stuff.
  2009-07-08  8:56   ` Jan Djärv
@ 2009-07-08 10:01     ` Yavor Doganov
  2009-07-08 11:42       ` Jan Djärv
  2009-07-14 14:55     ` Jan Djärv
  1 sibling, 1 reply; 18+ messages in thread
From: Yavor Doganov @ 2009-07-08 10:01 UTC (permalink / raw)
  To: emacs-devel

Jan Djärv wrote:
> It would also be nice to have Emacs use the same hinting and
> antialiasing as other applications.  We get a free GUI for setting
> these things (Gnome desktop preferences).

That's definitely a nice thing.

> If the infrastructure to set these values from desktop preferences
> are in place it is easy to change the actual means of getting the
> values, be it GConf, dconf or whatever.

Sounds convincing.  (Plus there would be a fairly long transition
period with GConf compatibility layer, so hopefully your work will not
be wasted.)

> Gnome is the GNU desktop after all.  It will fallback to not using
> GConf if it isn't present.

Right, that's good.  But if your plan involves linking against
libgconf, that's not of much use for distributors of binary packages,
who'll have to ship the GTK+ flavor with GConf support anyway and thus
will inflict the dependency on all users.





^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: Parsing of fontconfig font names and other font related stuff.
  2009-07-08  8:36   ` Jan Djärv
@ 2009-07-08 11:27     ` Jason Rumney
  2009-07-08 11:34       ` Kenichi Handa
  2009-07-08 12:01       ` Jason Rumney
  2009-07-08 12:09     ` Jan Djärv
  1 sibling, 2 replies; 18+ messages in thread
From: Jason Rumney @ 2009-07-08 11:27 UTC (permalink / raw)
  To: Jan Djärv; +Cc: emacs-devel, Kenichi Handa

Jan Djärv wrote:
> Yes.  Gnome has 96 dpi as default (settable in a user desktop settings 
> dialog), fontconfig seems to have 75.

I'm surprised that both Gnome and fontconfig are using hard-coded 
values, and not getting the monitor spec from X (at least on my system 
the X server reports the physical size it has read from the monitor at 
startup, so the information required to get the proper dpi setting 
appears to be in there somewhere).





^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: Parsing of fontconfig font names and other font related stuff.
  2009-07-08 11:27     ` Jason Rumney
@ 2009-07-08 11:34       ` Kenichi Handa
  2009-07-08 12:01       ` Jason Rumney
  1 sibling, 0 replies; 18+ messages in thread
From: Kenichi Handa @ 2009-07-08 11:34 UTC (permalink / raw)
  To: Jason Rumney; +Cc: jan.h.d, emacs-devel

In article <4A5482B4.2090101@gnu.org>, Jason Rumney <jasonr@gnu.org> writes:

> Jan Djärv wrote:
> > Yes.  Gnome has 96 dpi as default (settable in a user desktop settings 
> > dialog), fontconfig seems to have 75.

> I'm surprised that both Gnome and fontconfig are using hard-coded 
> values, and not getting the monitor spec from X

Me too.  I understand that there may be a case that a user
want to pretend the different DPI, but the default should be
the correct value.

---
Kenichi Handa
handa@m17n.org




^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: Parsing of fontconfig font names and other font related stuff.
  2009-07-08 10:01     ` Yavor Doganov
@ 2009-07-08 11:42       ` Jan Djärv
  2009-07-08 13:12         ` Yavor Doganov
  0 siblings, 1 reply; 18+ messages in thread
From: Jan Djärv @ 2009-07-08 11:42 UTC (permalink / raw)
  To: Emacs-Devel, yavor

Yavor Doganov skrev:
> Jan Djärv wrote:
> 
>> Gnome is the GNU desktop after all.  It will fallback to not using
>> GConf if it isn't present.
> 
> Right, that's good.  But if your plan involves linking against
> libgconf, that's not of much use for distributors of binary packages,
> who'll have to ship the GTK+ flavor with GConf support anyway and thus
> will inflict the dependency on all users.
> 

They can always compile without GConf if they want.

	Jan D.




^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: Parsing of fontconfig font names and other font related stuff.
  2009-07-08 11:27     ` Jason Rumney
  2009-07-08 11:34       ` Kenichi Handa
@ 2009-07-08 12:01       ` Jason Rumney
  1 sibling, 0 replies; 18+ messages in thread
From: Jason Rumney @ 2009-07-08 12:01 UTC (permalink / raw)
  To: Jan Djärv; +Cc: emacs-devel

Jason Rumney wrote:
> Jan Djärv wrote:
>> Yes.  Gnome has 96 dpi as default (settable in a user desktop 
>> settings dialog), fontconfig seems to have 75.
>
> I'm surprised that both Gnome and fontconfig are using hard-coded 
> values, and not getting the monitor spec from X (at least on my system 
> the X server reports the physical size it has read from the monitor at 
> startup, so the information required to get the proper dpi setting 
> appears to be in there somewhere).

Actually, re-reading what you wrote, they may be doing that but snapping 
to a commonly used dpi value (Windows does that, defaulting to either 
72, 96dpi or 120dpi, depending on monitor resolution).  Since your 
actual monitor resolution is about half way between 75 and 96, 
fontconfig and Gnome may be doing that snapping differently - also a lot 
of X fonts seem to be either 75 or 100dpi, so font config may be using 
those to snap to, while Gnome is using the same values as Windows.

It'd be good if someone like freedesktop.org could work out a spec for 
everyone to follow so that things were consistent, as lack of 
consistency in areas like this is one of the biggest complaints from 
Windows and Mac users trying to switch to Free software.





^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: Parsing of fontconfig font names and other font related stuff.
  2009-07-08  8:36   ` Jan Djärv
  2009-07-08 11:27     ` Jason Rumney
@ 2009-07-08 12:09     ` Jan Djärv
  2009-07-08 12:36       ` Kenichi Handa
  1 sibling, 1 reply; 18+ messages in thread
From: Jan Djärv @ 2009-07-08 12:09 UTC (permalink / raw)
  To: Kenichi Handa; +Cc: emacs-devel

Jan Djärv skrev:
> Kenichi Handa skrev:
>> And, I don't know what dpi is for.  That information should
>> be available via X server.  Is it a way to pretend that you
>> are using a screen of the different DPI?
> 
> Yes.  Gnome has 96 dpi as default (settable in a user desktop settings 
> dialog), fontconfig seems to have 75. My monitor is actually 84 dpi.  
> Other applications in Gnome, like gnome-terminal, uses the 96 dpi value, 
> but Emacs uses the default.  That makes Emacs and gnome-terminal look 
> different even though they both use monospace-8.

Actually it is too late to add DPI in xftfont.c, because it must be added long 
before that.  Font.c does DPI calculations all over the place, and assumes 
that either dpi=... is given in the font spec, or that the DPI for the monitor 
can be used.  In fact, it is either 75 (fontconfig default) or 96 (GNOME 
default) that is used, so font.c is wrong (wrong == different from other 
applications) when a plain font name like monospace-8 is given.

It would be nice to be able to use XftDefaultSubstitute to pick up the GConf 
settings from the X database (GConf puts them there).  But by the time the Xft 
driver has been choosen, the pixel size for the font has already been 
calculated, using another dpi-value.

How can we fix this?  Can we choose driver without calculating a pixel size?
The fast but kind of ugly way would be to add the defaults from 
XftDefaultSubstitute to the name if it is an fcname and Xft is present.

	Jan D.




^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: Parsing of fontconfig font names and other font related stuff.
  2009-07-08 12:09     ` Jan Djärv
@ 2009-07-08 12:36       ` Kenichi Handa
  2009-07-08 13:43         ` Miles Bader
  2009-07-08 14:07         ` Jan Djärv
  0 siblings, 2 replies; 18+ messages in thread
From: Kenichi Handa @ 2009-07-08 12:36 UTC (permalink / raw)
  To: =?ISO-8859-1?Q?Jan_Dj=E4rv?=; +Cc: emacs-devel

In article <4A548C7A.5020309@swipnet.se>, =?ISO-8859-1?Q?Jan_Dj=E4rv?= <jan.h.d@swipnet.se> writes:

> Actually it is too late to add DPI in xftfont.c, because it must be added long 
> before that.  Font.c does DPI calculations all over the place, and assumes 
> that either dpi=... is given in the font spec, or that the DPI for the monitor 
> can be used.  In fact, it is either 75 (fontconfig default) or 96 (GNOME 
> default) that is used, so font.c is wrong (wrong == different from other 
> applications) when a plain font name like monospace-8 is given.

Ah, sure.

> It would be nice to be able to use XftDefaultSubstitute to pick up the GConf 
> settings from the X database (GConf puts them there).  But by the time the Xft 
> driver has been choosen, the pixel size for the font has already been 
> calculated, using another dpi-value.

> How can we fix this?  Can we choose driver without calculating a pixel size?

I think it's not that difficult of modify the current code
to do that, but...

> The fast but kind of ugly way would be to add the defaults from 
> XftDefaultSubstitute to the name if it is an fcname and Xft is present.

shouldn't the DPI value from GConf be reflected to (struct
x_display_info).resy or (struct frame).resy?

---
Kenichi Handa
handa@m17n.org




^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: Parsing of fontconfig font names and other font related stuff.
  2009-07-08 11:42       ` Jan Djärv
@ 2009-07-08 13:12         ` Yavor Doganov
  0 siblings, 0 replies; 18+ messages in thread
From: Yavor Doganov @ 2009-07-08 13:12 UTC (permalink / raw)
  To: emacs-devel

Jan Djärv wrote:
> They can always compile without GConf if they want.

But it would be a pity to sacrifice better GNOME integration just for
the sake of non-GNOME users.  Emacs is currently a GTK+ application,
but such a change would make it (optionally) a GNOME app.  That's
perfect for GNOME users (which should be the primary concern, I agree)
and bad for others.

I guess the only viable choice for such distributors would be to
introduce another flavor -- GNOME (the default), and -gtk (with
stripped GConf support), similar to the way AbiWord, Dia, and many
other GNOME/GTK+ applications are shipped as binary packages.  The
drawback is that there are too many Emacs flavors already, and this
adds more to the downstream maintenance burden.

(Please don't misunderstand me -- I'm not an Emacs developer so I
can't possibly even oppose such a change.  And I'm not actually
opposing it; I've been a GNOME user since the 0.30 release more than a
decade ago, so your intention is excellent news to me.  I'm just
curious about the details of the implementation and the impact on the
"binary" distros.)





^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: Parsing of fontconfig font names and other font related stuff.
  2009-07-08 12:36       ` Kenichi Handa
@ 2009-07-08 13:43         ` Miles Bader
  2009-07-08 14:29           ` Jan Djärv
  2009-07-08 14:07         ` Jan Djärv
  1 sibling, 1 reply; 18+ messages in thread
From: Miles Bader @ 2009-07-08 13:43 UTC (permalink / raw)
  To: Kenichi Handa; +Cc: =?ISO-8859-1?Q?Jan_Dj=E4rv?=, emacs-devel

Kenichi Handa <handa@m17n.org> writes:
>> The fast but kind of ugly way would be to add the defaults from 
>> XftDefaultSubstitute to the name if it is an fcname and Xft is present.
>
> shouldn't the DPI value from GConf be reflected to (struct
> x_display_info).resy or (struct frame).resy?

You'd think, but IIRC, Gnome just fucks this up.

[I think it's a "policy" fuckup rather than a technical one.]

-Miles

-- 
Happiness, n. An agreeable sensation arising from contemplating the misery of
another.




^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: Parsing of fontconfig font names and other font related stuff.
  2009-07-08 12:36       ` Kenichi Handa
  2009-07-08 13:43         ` Miles Bader
@ 2009-07-08 14:07         ` Jan Djärv
  1 sibling, 0 replies; 18+ messages in thread
From: Jan Djärv @ 2009-07-08 14:07 UTC (permalink / raw)
  To: Kenichi Handa; +Cc: emacs-devel

Kenichi Handa skrev:
> In article <4A548C7A.5020309@swipnet.se>, =?ISO-8859-1?Q?Jan_Dj=E4rv?= <jan.h.d@swipnet.se> writes:

>> It would be nice to be able to use XftDefaultSubstitute to pick up the GConf 
>> settings from the X database (GConf puts them there).  But by the time the Xft 
>> driver has been choosen, the pixel size for the font has already been 
>> calculated, using another dpi-value.
> 
>> How can we fix this?  Can we choose driver without calculating a pixel size?
> 
> I think it's not that difficult of modify the current code
> to do that, but...
> 
>> The fast but kind of ugly way would be to add the defaults from 
>> XftDefaultSubstitute to the name if it is an fcname and Xft is present.
> 
> shouldn't the DPI value from GConf be reflected to (struct
> x_display_info).resy or (struct frame).resy?
> 

I don't know.  Xft picks up its specific values from X defaults, and GConf 
puts them there.  So if we could use XftDefaultSubstitute we would get the 
GConf values without using GConf directly. Also, those values only makes sense 
for Xft fonts, so it isn't a general DPI-value for everything X does.
Then again, it seems to be used mostly for fonts in Emacs, I found one 
instance where it is used to calculate the size of an image.

I'll look in to it some more.

	Jan D.





^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: Parsing of fontconfig font names and other font related stuff.
  2009-07-08 13:43         ` Miles Bader
@ 2009-07-08 14:29           ` Jan Djärv
  2009-07-08 22:54             ` Miles Bader
  0 siblings, 1 reply; 18+ messages in thread
From: Jan Djärv @ 2009-07-08 14:29 UTC (permalink / raw)
  To: Miles Bader; +Cc: emacs-devel, Kenichi Handa

Miles Bader skrev:
> Kenichi Handa <handa@m17n.org> writes:
>>> The fast but kind of ugly way would be to add the defaults from 
>>> XftDefaultSubstitute to the name if it is an fcname and Xft is present.
>> shouldn't the DPI value from GConf be reflected to (struct
>> x_display_info).resy or (struct frame).resy?
> 
> You'd think, but IIRC, Gnome just fucks this up.
> 
> [I think it's a "policy" fuckup rather than a technical one.]
> 

The argument I've seen is that selecting font sizes isn't a linear operation 
(i.e. proportional to dpi), but an angular one (i.e. depends on the size of 
the screen and the distance to the screen).  So for example laptop users sit 
closer to the screen and don't want fonts to be so much bigger as implied by 
the dpi difference.  Another one is that DPI is kind of fuzzy anyway, for 
example for projectors.

I think a good compromize for an Emacs that uses Xft, is just to check if 
Xft.dpi is in the Xdefaults, and if it is, just use it.  Which is what 
Handa-san suggested.

	Jan D.




^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: Parsing of fontconfig font names and other font related stuff.
  2009-07-08 14:29           ` Jan Djärv
@ 2009-07-08 22:54             ` Miles Bader
  0 siblings, 0 replies; 18+ messages in thread
From: Miles Bader @ 2009-07-08 22:54 UTC (permalink / raw)
  To: Jan Djärv; +Cc: Kenichi Handa, emacs-devel

Jan Djärv <jan.h.d@swipnet.se> writes:
>> You'd think, but IIRC, Gnome just fucks this up.
>>
>> [I think it's a "policy" fuckup rather than a technical one.]
>
> The argument I've seen is that selecting font sizes isn't a linear
> operation (i.e. proportional to dpi), but an angular one (i.e. depends
> on the size of the screen and the distance to the screen).  So for
> example laptop users sit closer to the screen and don't want fonts to be
> so much bigger as implied by the dpi difference.  Another one is that
> DPI is kind of fuzzy anyway, for example for projectors.

That's an argument for making the DPI user-settable/tweakable and/or
with default adjustments based on display type.

It does't seem related to fixing DPI at 96 dpi though.

[My impression was that Gnome was just copying the identical MS fuckup,
which _does_ seem to have been a technical one...]

-Miles

-- 
`Life is a boundless sea of bitterness'




^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: Parsing of fontconfig font names and other font related stuff.
  2009-07-08  8:56   ` Jan Djärv
  2009-07-08 10:01     ` Yavor Doganov
@ 2009-07-14 14:55     ` Jan Djärv
  1 sibling, 0 replies; 18+ messages in thread
From: Jan Djärv @ 2009-07-14 14:55 UTC (permalink / raw)
  To: Emacs-Devel, yavor



Jan Djärv skrev:
> Yavor Doganov skrev:
>> Jan Djärv wrote:
>>> I'm in the process of getting Emacs to use GConf defaults for font, 
>>> antialiasing, hints and dpi.
>>
>> Are you sure this is a good idea?  AFAIK there are plans to deprecate
>> GConf for GNOME 3.0 next year, and replace it with dconf/GSettings.
>> The precise plan is not clear yet, I think.
> 
> Well, if it isn't clear, we must work with what we have :-)
> Yes I think it is a good idea.  As I said in my reply to Handa-san, the 
> dpi values used by Emacs and other Gnome applications doesn't match, so 
> Emacs looks different even if it uses the same font.
> 
> It would also be nice to have Emacs use the same hinting and 
> antialiasing as other applications.  We get a free GUI for setting these 
> things (Gnome desktop preferences).  It is somewhat cumbersome to set 
> these in Emacs now.

It seems XSettings is much further along than I thought.  So basically GConf 
is out and XSettings is in (well, working on it anyway).

	Jan D.




^ permalink raw reply	[flat|nested] 18+ messages in thread

end of thread, other threads:[~2009-07-14 14:55 UTC | newest]

Thread overview: 18+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-07-07 18:57 Parsing of fontconfig font names and other font related stuff Jan Djärv
2009-07-08  0:55 ` Kenichi Handa
2009-07-08  8:36   ` Jan Djärv
2009-07-08 11:27     ` Jason Rumney
2009-07-08 11:34       ` Kenichi Handa
2009-07-08 12:01       ` Jason Rumney
2009-07-08 12:09     ` Jan Djärv
2009-07-08 12:36       ` Kenichi Handa
2009-07-08 13:43         ` Miles Bader
2009-07-08 14:29           ` Jan Djärv
2009-07-08 22:54             ` Miles Bader
2009-07-08 14:07         ` Jan Djärv
2009-07-08  7:12 ` Yavor Doganov
2009-07-08  8:56   ` Jan Djärv
2009-07-08 10:01     ` Yavor Doganov
2009-07-08 11:42       ` Jan Djärv
2009-07-08 13:12         ` Yavor Doganov
2009-07-14 14:55     ` Jan Djärv

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).