Re: font dialog error
"John Selverian" <[email protected]> Thu, 4 Sep 2025 12:00:35 -0400
| Newsgroups | gmane.comp.lib.fox-toolkit.user |
|---|---|
| Organization | JAHM Software |
| Message-ID | <[email protected]> |
v1.7.50 It is a custom widget derived form the standard font dialog. I'll look into what you said. -----Original Message----- From: [email protected] <[email protected]> Sent: Thursday, September 4, 2025 11:28 AM To: [email protected] Cc: [email protected] Subject: Re: [Foxgui-users] font dialog error On 2025-08-29 16:34, John Selverian wrote: > On Ubuntu when I enumerate the system fonts and go through them I get > the following error in the cmd window: > > > > > > X Error: code 16 major 140 minor 20: BadLength (poly request too large > or internal Xlib length error). Do you know what version of FOX this was? Stuff with long strings was recently fixed and on the linux side, there should be no buffer length issues at this time. The fix is two-fold: 1) FXTextField fix which now limits draw calls to visible area. This should be well below buffer limits. 2) FXFont::getTextWidth() change which now measures utf8 character at a time. [basically implements exact commands that XftTextExtentsUtf8() was calling under the hood. 3) On Windows, limitations may still exist. We've removed buffer limitations in FXDCWindow::drawText() and FXDCWindow::drawImageText() on windows. Note: drawing APIs are less likely to hit the limits, but measuring APIs like getTextWidth() are; optimal drawing should limit itself to visible parts only, and we're now doing a bit more work to avoid drawing in clipped areas; chiefly, this was FXTextField as FXText already does this. If you have custom widgets, perhaps they may have been drawing clipped parts of text. A typical screen, e.g. 4k, would only be able to show a few hundreds of characters, even at really small font sizes. -- JVZ