summaryrefslogtreecommitdiffstats
path: root/dives/33.xml
diff options
context:
space:
mode:
authorGravatar Linus Torvalds <torvalds@linux-foundation.org>2011-09-07 14:37:47 -0700
committerGravatar Linus Torvalds <torvalds@linux-foundation.org>2011-09-07 14:37:47 -0700
commitd4a1dfb3d9a6a8f89d5f543ba1ad2eea091c813c (patch)
treee87447603878999600ef1e68942e3636ff73046c /dives/33.xml
parent96f5bea1ac89866aa58fe9fd39e625947bfa910a (diff)
downloadsubsurface-d4a1dfb3d9a6a8f89d5f543ba1ad2eea091c813c.tar.gz
Fix up horribly broken cairo scaling
The way cairo does scaling is really really inconvenient, and one of the things in cairo that is fundamentally mis-designed. Cairo scaling always affects both coordinates and object sizes, and the two can apparently never be split apart. Which is very much not what we want: we want just coordinate scaling. So we cannot use 'cairo_scale()' to scale our canvas, because that screws up lines and text size too. And no, you cannot "fix" that by de-scaling the line size etc - because line size is one-dimensional, so you can't undo the (different) scaling in X/Y. Sad. I realize that often you do want to scale object size with coordinate transformation, but quite often you *don't* want to. Yeah, we could do random context save/restore in odd places etc, but that's just a sign of the bad design of cairo scaling. Work around it by introducing our own graphics context with scaling, which does it right. I don't like this, but it seems to be better than the alternatives. Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'dives/33.xml')
0 files changed, 0 insertions, 0 deletions