From: Alexandre F. <ale...@gm...> - 2008-11-29 00:42:33
|
FWIW, I believe I understand why the round trip through a fixed-distance unit (here millimeters) was done. The reason is that a screen distance like "2i" means a different number of pixels on two windows belonging to screens of different resolutions. So it is in theory possible that the cached, pixel-converted value of this distance be unduly used as is on another screen. However, once this (extremely improbable) situation has been spotted, it is fairly trivial to avoid it, by invalidating the internal rep when a change of pixelPtr->tkwin is detected. That's the purpose of the just-committed update. -Alex > > * generic/tkCanvUtil.c Millimeter patch. Fixes [1813597,2218964] > * generic/tkInt.h by eliminating the functional redundancy > * generic/tkObj.c and unnecessary loss of precision of the > * generic/tkText.c {pixel,mm}ObjType tandem. > > So, millimeters as an objtype can start decaying. Will be gone in 1e31 > years, like protons. > > Help appreciated for backports. > > -Alex > |