mirror of
https://git.tartarus.org/simon/putty.git
synced 2025-07-09 07:13:43 -05:00

On my test case, this reduces Xwayland's CPU usage by 5-10%, though curiously in glamor_block_handler rather than the drawing routine itself. XDrawImageString16 isn't as helpful as it might be for two reasons. First, "M" type fonts (e.g. Courier Oblique) can extend beyond the rectangle erased by XDrawImageString16, and PuTTY tries to support such fonts. And second, we really want to blank the pixmap after drawing rather than before, because otherwise we have to muck around clipping the mask operation. So avoinding the XFillRectangle calls is difficult, at which point we may as well use XDrawString16.