mirror of
https://github.com/gnustep/libs-back.git
synced 2025-02-23 20:01:22 +00:00
* Source/cairo/CairoContext.m (-beginPrologueBBox:...):
Add a hack to get landscape printing working. Comment in the source reproduced here: FIXME: This is confusing... When an 8.5x11 page is set to landscape, NSPrintInfo also swaps the paperSize to be 11x8.5, but gui also adds a 90 degree rotation as if it will be drawing on a 8.5x11 page. So, swap 11x8.5 back to 8.5x11 here. git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/back/trunk@34356 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
4f613a2a66
commit
b6588a43bd
2 changed files with 21 additions and 0 deletions
10
ChangeLog
10
ChangeLog
|
@ -1,3 +1,13 @@
|
||||||
|
2011-12-24 Eric Wasylishen <ewasylishen@gmail.com>
|
||||||
|
|
||||||
|
* Source/cairo/CairoContext.m (-beginPrologueBBox:...):
|
||||||
|
Add a hack to get landscape printing working. Comment in the source
|
||||||
|
reproduced here:
|
||||||
|
FIXME: This is confusing... When an 8.5x11 page is set to
|
||||||
|
landscape, NSPrintInfo also swaps the paperSize to be 11x8.5,
|
||||||
|
but gui also adds a 90 degree rotation as if it will
|
||||||
|
be drawing on a 8.5x11 page. So, swap 11x8.5 back to 8.5x11 here.
|
||||||
|
|
||||||
2011-12-23 Eric Wasylishen <ewasylishen@gmail.com>
|
2011-12-23 Eric Wasylishen <ewasylishen@gmail.com>
|
||||||
|
|
||||||
* Source/cairo/CairoContext.m (-beginPrologueBBox:...): Use
|
* Source/cairo/CairoContext.m (-beginPrologueBBox:...): Use
|
||||||
|
|
|
@ -233,6 +233,17 @@
|
||||||
if (printInfo != nil)
|
if (printInfo != nil)
|
||||||
{
|
{
|
||||||
size = [printInfo paperSize];
|
size = [printInfo paperSize];
|
||||||
|
|
||||||
|
// FIXME: This is confusing..
|
||||||
|
// When an 8.5x11 page is set to landscape,
|
||||||
|
// NSPrintInfo also swaps the paperSize to be 11x8.5,
|
||||||
|
// but gui also adds a 90 degree rotation as if it will
|
||||||
|
// be drawing on a 8.5x11 page. So, swap 11x8.5 back to
|
||||||
|
// 8.5x11 here.
|
||||||
|
if ([printInfo orientation] == NSLandscapeOrientation)
|
||||||
|
{
|
||||||
|
size = NSMakeSize(size.height, size.width);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue