GNU bug report logs -
#42240
Interpretation of 'size' Property in Fontconfig Pattern Strings
Previous Next
To reply to this bug, email your comments to 42240 AT debbugs.gnu.org.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#42240
; Package
emacs
.
(Tue, 07 Jul 2020 11:26:02 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
sebastian.miele <at> gmail.com
:
New bug report received and forwarded. Copy sent to
bug-gnu-emacs <at> gnu.org
.
(Tue, 07 Jul 2020 11:26:02 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
GNU Emacs 27.0.91 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.20)
of 2020-06-28
According to 'man 5 fonts-conf' the Fontconfig property 'size' is a
double and represents the point size. The property 'pixelsize', too, is
a double and represents the pixel size.
In
FC_DEBUG=1 emacs -Q --font=:family=Hack:size=11
the 'size=11' is interpreted as 'pixelsize=11'.
fc-match :family=Hack:size=11 size pixelsize
does interpret it as point size.
Apart from that both
emacs -Q --font=:family=Hack:size=11.1
and
emacs -Q --font=:family=Hack:pixelsize=11.1
both yield the same error: "invalid font property: (:size . 11\.1)",
although according to fontconfig the pixel size is a double, too.
However, fractional pixel sizes may not make sense for Emacs at all. I
do not know.
The following does work as expected:
emacs -Q --font=Hack-11.1
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#42240
; Package
emacs
.
(Thu, 16 Jul 2020 15:04:01 GMT)
Full text and
rfc822 format available.
Message #8 received at 42240 <at> debbugs.gnu.org (full text, mbox):
>>>>> On Tue, 07 Jul 2020 13:25:15 +0200, Sebastian Miele <sebastian.miele <at> gmail.com> said:
Sebastian> GNU Emacs 27.0.91 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.20)
Sebastian> of 2020-06-28
Sebastian> According to 'man 5 fonts-conf' the Fontconfig property 'size' is a
Sebastian> double and represents the point size. The property 'pixelsize', too, is
Sebastian> a double and represents the pixel size.
Is this a build with or without Cairo? (you snipped the part of the
bug report that would have told us)
Sebastian> In
Sebastian> FC_DEBUG=1 emacs -Q --font=:family=Hack:size=11
Sebastian> the 'size=11' is interpreted as 'pixelsize=11'.
Sebastian> fc-match :family=Hack:size=11 size pixelsize
Sebastian> does interpret it as point size.
Sebastian> Apart from that both
Sebastian> emacs -Q --font=:family=Hack:size=11.1
Sebastian> and
Sebastian> emacs -Q --font=:family=Hack:pixelsize=11.1
Sebastian> both yield the same error: "invalid font property: (:size . 11\.1)",
Sebastian> although according to fontconfig the pixel size is a double, too.
Sebastian> However, fractional pixel sizes may not make sense for Emacs at all. I
Sebastian> do not know.
Sebastian> The following does work as expected:
Sebastian> emacs -Q --font=Hack-11.1
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#42240
; Package
emacs
.
(Thu, 16 Jul 2020 15:57:01 GMT)
Full text and
rfc822 format available.
Message #11 received at 42240 <at> debbugs.gnu.org (full text, mbox):
Robert Pluim <rpluim <at> gmail.com> writes:
> Is this a build with or without Cairo? (you snipped the part of the
> bug report that would have told us)
Both issues described happen both with and without cairo (both checked
out from the emacs-27.0.91 tag). Here is the complete information of
`report-emacs-bug' of the build without cairo:
In GNU Emacs 27.0.91 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.20)
of 2020-06-28 built on huette
Repository revision: c36c5a3dedbb2e0349be1b6c3b7567ea7b594f1c
Repository branch: HEAD
Windowing system distributor 'The X.Org Foundation', version 11.0.12008000
System Description: Arch Linux
Recent messages:
For information about GNU Emacs and the GNU system, type C-h C-a.
Making completion list...
Configured using:
'configure --with-x-toolkit=gtk3 --with-mailutils'
Configured features:
XPM JPEG TIFF GIF PNG RSVG SOUND GPM DBUS GSETTINGS GLIB NOTIFY INOTIFY
ACL GNUTLS LIBXML2 FREETYPE HARFBUZZ M17N_FLT LIBOTF XFT ZLIB
TOOLKIT_SCROLL_BARS GTK3 X11 XDBE XIM MODULES THREADS LIBSYSTEMD JSON
PDUMPER LCMS2 GMP
Important settings:
value of $LC_CTYPE: de_DE.UTF-8
value of $LANG: C
locale-coding-system: utf-8-unix
Major mode: Lisp Interaction
Minor modes in effect:
tooltip-mode: t
global-eldoc-mode: t
eldoc-mode: t
electric-indent-mode: t
mouse-wheel-mode: t
tool-bar-mode: t
menu-bar-mode: t
file-name-shadow-mode: t
global-font-lock-mode: t
font-lock-mode: t
blink-cursor-mode: t
auto-composition-mode: t
auto-encryption-mode: t
auto-compression-mode: t
line-number-mode: t
transient-mark-mode: t
Load-path shadows:
None found.
Features:
(shadow sort mail-extr emacsbug message rmc puny dired dired-loaddefs
format-spec rfc822 mml easymenu mml-sec password-cache epa derived epg
epg-config gnus-util rmail rmail-loaddefs text-property-search time-date
subr-x seq byte-opt gv bytecomp byte-compile cconv mm-decode mm-bodies
mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader cl-loaddefs
cl-lib sendmail rfc2047 rfc2045 ietf-drums mm-util mail-prsvr mail-utils
tooltip eldoc electric uniquify ediff-hook vc-hooks lisp-float-type
mwheel term/x-win x-win term/common-win x-dnd tool-bar dnd fontset image
regexp-opt fringe tabulated-list replace newcomment text-mode elisp-mode
lisp-mode prog-mode register page tab-bar menu-bar rfn-eshadow isearch
timer select scroll-bar mouse jit-lock font-lock syntax facemenu
font-core term/tty-colors frame minibuffer cl-generic cham georgian
utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean
japanese eucjp-ms cp51932 hebrew greek romanian slovak czech european
ethiopic indian cyrillic chinese composite charscript charprop
case-table epa-hook jka-cmpr-hook help simple abbrev obarray
cl-preloaded nadvice loaddefs button faces cus-face macroexp files
text-properties overlay sha1 md5 base64 format env code-pages mule
custom widget hashtable-print-readable backquote threads dbusbind
inotify lcms2 dynamic-setting system-font-setting font-render-setting
move-toolbar gtk x-toolkit x multi-tty make-network-process emacs)
Memory information:
((conses 16 44887 6437)
(symbols 48 6007 1)
(strings 32 15413 1544)
(string-bytes 1 501852)
(vectors 16 10087)
(vector-slots 8 129959 12406)
(floats 8 20 33)
(intervals 56 197 0)
(buffers 1000 12))
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#42240
; Package
emacs
.
(Thu, 16 Jul 2020 16:09:01 GMT)
Full text and
rfc822 format available.
Message #14 received at 42240 <at> debbugs.gnu.org (full text, mbox):
Sebastian Miele <sebastian.miele <at> gmail.com>:
> Robert Pluim <rpluim <at> gmail.com>:
>
>> Is this a build with or without Cairo? (you snipped the part of the
>> bug report that would have told us)
>
> Both issues described happen both with and without cairo (both checked
> out from the emacs-27.0.91 tag). Here is the complete information of
> `report-emacs-bug' of the build without cairo:
>
> [..]
The build without cairo also contained '--without-xft' (although I do
not really know the consequences). Here is the complete
`report-emacs-bug' info from that build:
In GNU Emacs 27.0.91 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.21, cairo version 1.17.3)
of 2020-07-06 built on huette
Repository revision: c36c5a3dedbb2e0349be1b6c3b7567ea7b594f1c
Repository branch: HEAD
Windowing system distributor 'The X.Org Foundation', version 11.0.12008000
System Description: Arch Linux
Recent messages:
For information about GNU Emacs and the GNU system, type C-h C-a.
Configured using:
'configure --with-x-toolkit=gtk3 --with-mailutils --with-cairo
--without-xft'
Configured features:
XPM JPEG TIFF GIF PNG RSVG CAIRO SOUND GPM DBUS GSETTINGS GLIB NOTIFY
INOTIFY ACL GNUTLS LIBXML2 FREETYPE HARFBUZZ M17N_FLT LIBOTF ZLIB
TOOLKIT_SCROLL_BARS GTK3 X11 XDBE XIM MODULES THREADS LIBSYSTEMD JSON
PDUMPER LCMS2 GMP
Important settings:
value of $LC_CTYPE: de_DE.UTF-8
value of $LANG: C
locale-coding-system: utf-8-unix
Major mode: Lisp Interaction
Minor modes in effect:
tooltip-mode: t
global-eldoc-mode: t
eldoc-mode: t
electric-indent-mode: t
mouse-wheel-mode: t
tool-bar-mode: t
menu-bar-mode: t
file-name-shadow-mode: t
global-font-lock-mode: t
font-lock-mode: t
blink-cursor-mode: t
auto-composition-mode: t
auto-encryption-mode: t
auto-compression-mode: t
line-number-mode: t
transient-mark-mode: t
Load-path shadows:
None found.
Features:
(shadow sort mail-extr emacsbug message rmc puny dired dired-loaddefs
format-spec rfc822 mml easymenu mml-sec password-cache epa derived epg
epg-config gnus-util rmail rmail-loaddefs text-property-search time-date
subr-x seq byte-opt gv bytecomp byte-compile cconv mm-decode mm-bodies
mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader cl-loaddefs
cl-lib sendmail rfc2047 rfc2045 ietf-drums mm-util mail-prsvr mail-utils
tooltip eldoc electric uniquify ediff-hook vc-hooks lisp-float-type
mwheel term/x-win x-win term/common-win x-dnd tool-bar dnd fontset image
regexp-opt fringe tabulated-list replace newcomment text-mode elisp-mode
lisp-mode prog-mode register page tab-bar menu-bar rfn-eshadow isearch
timer select scroll-bar mouse jit-lock font-lock syntax facemenu
font-core term/tty-colors frame minibuffer cl-generic cham georgian
utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean
japanese eucjp-ms cp51932 hebrew greek romanian slovak czech european
ethiopic indian cyrillic chinese composite charscript charprop
case-table epa-hook jka-cmpr-hook help simple abbrev obarray
cl-preloaded nadvice loaddefs button faces cus-face macroexp files
text-properties overlay sha1 md5 base64 format env code-pages mule
custom widget hashtable-print-readable backquote threads dbusbind
inotify lcms2 dynamic-setting system-font-setting font-render-setting
cairo move-toolbar gtk x-toolkit x multi-tty make-network-process emacs)
Memory information:
((conses 16 44842 6073)
(symbols 48 6005 1)
(strings 32 15430 1775)
(string-bytes 1 504623)
(vectors 16 10098)
(vector-slots 8 130183 10652)
(floats 8 19 39)
(intervals 56 190 0)
(buffers 1000 11))
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#42240
; Package
emacs
.
(Thu, 16 Jul 2020 17:04:01 GMT)
Full text and
rfc822 format available.
Message #17 received at 42240 <at> debbugs.gnu.org (full text, mbox):
>>>>> On Thu, 16 Jul 2020 18:07:50 +0200, Sebastian Miele <sebastian.miele <at> gmail.com> said:
Sebastian> Sebastian Miele <sebastian.miele <at> gmail.com>:
>> Robert Pluim <rpluim <at> gmail.com>:
>>
>>> Is this a build with or without Cairo? (you snipped the part of the
>>> bug report that would have told us)
>>
>> Both issues described happen both with and without cairo (both checked
>> out from the emacs-27.0.91 tag). Here is the complete information of
>> `report-emacs-bug' of the build without cairo:
>>
>> [..]
Sebastian> The build without cairo also contained '--without-xft' (although I do
Sebastian> not really know the consequences). Here is the complete
Sebastian> `report-emacs-bug' info from that build:
Cairo implies --without-xft in any case, so no harm done. Looks like
Iʼll have to boot up my GNU/Linux box (although Iʼm hazy on the
difference between 'size' and 'pixelsize')
Robert
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#42240
; Package
emacs
.
(Thu, 16 Jul 2020 18:11:02 GMT)
Full text and
rfc822 format available.
Message #20 received at 42240 <at> debbugs.gnu.org (full text, mbox):
Robert Pluim <rpluim <at> gmail.com>:
> Cairo implies --without-xft in any case, so no harm done.
Good to know. Thank you.
> Looks like Iʼll have to boot up my GNU/Linux box (although Iʼm hazy on
> the difference between 'size' and 'pixelsize')
The main Fontconfig manual page describing all properties is called 'man
5 fonts-conf' (which can be hard to find, because neither 'fc' nor
'fontconfig' are substrings of 'fonts-conf').
The 'size' is the point size. In general, there are many different
definitions of point size. But in practice only one is used nowadays
(except by TeX which uses a slightly different but very close definition
that works better with its fixed point arithmetics). Usually a point is
1/72 inch (https://en.wikipedia.org/wiki/Point_(typography)).
Together with 'dpi' (dots/pixels per inch) that defines the relation
between point size and pixel size.
X has at least two different places where a dpi may be defined. One for
the entire X display, although that does not really make sense with an X
display having monitors of different pixel densities. Apart from that at
least the Xrandr extension has a notion of distinct dpis per monitor.
In general, Fontconfig has an even separate dpi. I do not really know
what dpi Fontconfig uses, if it is not explicitly set in the Fontconfig
configuration, but, e.g.,
fc-match :family=Hack:size=11.1 size pixelsize dpi
or
fc-match -v :family=Hack:size=11.
display the dpi used.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#42240
; Package
emacs
.
(Thu, 16 Jul 2020 18:12:01 GMT)
Full text and
rfc822 format available.
Message #23 received at 42240 <at> debbugs.gnu.org (full text, mbox):
I have just built a fresh Emacs with cairo from the emacs-27 branch
(commit d24e56a5e4959f82b3da0dfac9ee3c428e077cbd). The two issues are
present there, too.
This bug report was last modified 4 years and 336 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.