Thanks for the feedback Albrecht - I'm responding here because most of what follows is just discussion, I don't really want to clutter the STR up with that until we settle on an answer!
On 30 Nov 2008, at 13:07, Albrecht Schlosser wrote: > > I tested, and it seems to work okay on Windows and Linux/Xft, but > there > seem to be some "off-by-one" errors with some glyphs at the right > border > (e.g. the capitol A in your example). However, since this obviously is > glyph dependent, I think this must be a bug in the font itself(?). It is possibly in the font glyphs, but also (sometimes) I think there are maybe "rounding errors" introduced by the anti-aliasing when the font is rendered. I'm not sure though. Sometimes it looks worse on this Mac (for example) than it does under linux/XFT, using ostensibly the same font, and I assume that is because the anti-aliasing mechanisms are different. I could be talking rubbish. > Two implementation notes: > > (1) I wonder if the Windows-specific defines need to be in > fl_font.cxx. > IMHO they should be in fl_font_win32.cxx (without the enclosing > "#ifdef > WIN32"). That was my original intent, but the defines need to be set before the inclusion of windows.h, which is done indirectly in fl_font.cxx via "FL/x.H". So I had to put the defines in fl_font.cxx itself - but they should have no impact anywhere else, so I guess it is safe enough (but see below...) > (2) This update definitely breaks WindowsNT and probably Windows9x > version > support. I started a RFC about future Windows version support in > fltk.development [1] - please discuss there, and we should add a > summary > or decision here later. I know that we could try to load the offending > function "GetGlyphIndicesW" dynamically, but IMHO we should only do > this > if needed. Yes - this is a problem I knew I was creating, even as I created it. I do not know what is best here. I guess the nearest equivalent thing is back when Mike added multi- screen support to fltk-1.1, and I was still maintaining a farm of WinNT4 machines, and of course the multi-screen stuff broke them. So I added a bunch of code to "screen_xywh.cxx" to test for and use the necessary functions at runtime. Now, the NT4 boxes are long gone (so I'm not so bothered about back compatibility!) and we are working on 1.3.x... I guess we need to decide whether we need to support NT4 etc. or not anymore. I think we have to assume the Win9x series is dead, I'm fairly sure a lot of the recent enhancements (e.g. UTF8) are pretty much show- stoppers for Win9x anyway. If we decide we should try to, I will write the code, it should be straightforward (I'll follow the pattern I used in screen_xywh.cxx) but I have no means of testing it properly, so we might have to find someone with an older Windows machine. I don't even have a Win2K box now, the oldest I have is WinXP. Thoughts, anybody? -- Ian _______________________________________________ fltk-dev mailing list [email protected] http://lists.easysw.com/mailman/listinfo/fltk-dev
