Re: Tk Unicode is slow
- From: Jeff Hobbs <jeffh@xxxxxxxxxxxxxxx>
- Date: Thu, 29 Sep 2005 08:33:04 -0700
Keith Nash wrote:
As Donal noted, the delay is due to Tk doing a font lookup to find a suitable font for characters that are not recognized in the current font you have chosen to display. Use one with all the chars, and everything is fast. I have considered adding extra Tcl-level control over this fallback behavior, but it is hard to design a clean API to control this.
(...the feature requests keep rolling in...)
At the minimum, it would be useful if Tcl could be told to use the specified font *only*, i.e. not to search every font on the system whenever it encounters a missing glyph.
Ideally, one would be able to create a virtual font that borrows different glyphs from different real fonts. It sounds as if this is what Tcl's font lookup actually does - but it doesn't cache the virtual font metadata, and it doesn't tell us what it is.
At a minimum, this might not be to hard, if it is layered on top of named fonts. In fact, I think any control of font fallback would be layered on top of named fonts. Something like font create myfont -family Courier -size 10 -fallback 0
-- Jeff Hobbs, The Tcl Guy http://www.ActiveState.com/, a division of Sophos .
- References:
- Tk Unicode is slow
- From: Keith Nash
- Re: Tk Unicode is slow
- From: Bryan Oakley
- Re: Tk Unicode is slow
- From: Jeff Hobbs
- Re: Tk Unicode is slow
- From: Keith Nash
- Tk Unicode is slow
- Prev by Date: retrieving line number in case of error - "simple debugger"
- Next by Date: Re: tk_chooseDirectory -mustexist 1
- Previous by thread: Re: Tk Unicode is slow
- Next by thread: Re: Tk Unicode is slow
- Index(es):
Relevant Pages
|