Discussion:
X fonts
AGC
2012-08-17 20:55:57 UTC
Permalink
Hey everyone,

I've got a question about X fonts that I know will likely have some
simple solution but I can't find it anywhere on Google.

I'm just trying to run xclock remotely (over SSH). However, this
doesn't work:

$ /usr/X11R6/bin/xclock -digital -update 1 -bg black -fg green -title
tick:xclock -fn -*-helvetica-*-r-*-*-22-*-*-*-*-*-*-* -strftime "%a, %b
%e, %Y %H:%M:%S %Z" -geometry 400x40
Warning: Cannot convert string "" to type XftFont
Segmentation fault (core dumped)


It does work if I add -norender to the command.

It seems X fonts are mystical magic. If they work you're lucky, if they
don't you're lost.

The system is headless so only the core of X for the clients and some
fonts are installed.
Mouse
2012-08-17 22:41:01 UTC
Permalink
Post by AGC
I'm just trying to run xclock remotely (over SSH). However, this
$ /usr/X11R6/bin/xclock -digital -update 1 -bg black -fg green -title tick:xclock -fn -*-helvetica-*-r-*-*-22-*-*-*-*-*-*-* -strftime "%a, %b %e, %Y %H:%M:%S %Z" -geometry 400x40
Depending on your shell, the -*-helvetica-*-r-*-*-22-*-*-*-*-*-*-*
glob pattern may not turn into what you want. I'm going to assume your
shell turns it into a single argument identical to what you specified.
Post by AGC
Warning: Cannot convert string "" to type XftFont
Segmentation fault (core dumped)
It does work if I add -norender to the command.
Based on trying that command with and without -norender using my 4.0.1
system's /usr/X11R6/bin/xclock, I'm fairly sure the version without
-norender is not using X fonts, or at least not fonts as provided by
the core X protcol. It's doing some kind of antialiased font
rendering, which is beyond what core X font support provides.
Post by AGC
It seems X fonts are mystical magic. If they work you're lucky, if
they don't you're lost.
They're pretty straightforward, if you stick to core X.

My guess - and a guess is all it is - is that when you use -norender,
it's using core X font support, with the -fn argument being turned into
a font, and rendered, on the server, whereas with -norender, all the
rendering is happening client-side and sent as bitmaps. Running it
under xscope reveals that the no--norender version heavily uses an
extension called RENDER; I have so far been unable to find
documentation on this, so I don't know what it's doing with it.

/~\ The ASCII Mouse
\ / Ribbon Campaign
X Against HTML ***@rodents-montreal.org
/ \ Email! 7D C8 61 52 5D E7 2D 39 4E F1 31 3E E8 B3 27 4B

Loading...