Very large fonts cause loss of connection to X server

Troy Rollo wine at troy.rollo.name
Tue Jun 20 22:54:14 CDT 2006


Rendering text to a screen DC with a font height on the order of 17,000 pixels 
results in glyphs being uploaded to the X server that are on the order of 
30MB in size (or more for some wide characters). The next attempt to make a 
request of the server results in a SIGPIPE.

This is possible if an app has the ability to zoom in on a document containing 
text and allows the user to specify the scaling factor without limiting it. 
Very large screen fonts can also arise when some WYSIWYG display strategies 
are used, although this would not ordinarily get to the 17,000 pixel range. 
Windows deals with such behaviour without problems.

I'm not sure there's anything that can be done about this other than imposing 
an arbitrary sanity check on the size of the screen font prior to uploading 
the glyph - if the font is much larger than the screen, for instance, then 
perhaps the best thing is just not to upload the glyph but mark it internally 
as having been uploaded. Presumably that will prevent the loss of connection 
without breaking WYSIWYG display strategies that involve calculating 
positions using large fonts in a screen DC.
-- 
Troy Rollo - wine at troy.rollo.name



More information about the wine-devel mailing list