Fix obvious indenting errors after removal of old code
... by commit e0405d2135
This commit is contained in:
parent
e0405d2135
commit
26387c3538
@ -4483,7 +4483,7 @@ static NSBitmapImageRep *scale_nsbitmapimagerep(NSBitmapImageRep *img, float sca
|
||||
|
||||
static void write_bitmap_inside(NSBitmapImageRep *to, int to_width, NSBitmapImageRep *from,
|
||||
int to_x, int to_y)
|
||||
/* Copies in bitmap "to" the bitmap "from" with its top-left angle at coordinates to_x, to_y
|
||||
/* Copies in bitmap "to" the bitmap "from" with its top-left angle at coordinates to_x, to_y
|
||||
On retina displays both bitmaps have double width and height
|
||||
to_width is the width in screen units of "to". On retina, its pixel width is twice that.
|
||||
*/
|
||||
@ -4675,11 +4675,11 @@ static void nsbitmapProviderReleaseData (void *info, const void *data, size_t si
|
||||
}
|
||||
|
||||
CGImageRef Fl_Cocoa_Window_Driver::CGImage_from_window_rect(int x, int y, int w, int h, bool capture_subwins)
|
||||
/* Returns a capture of a rectangle of a mapped window as a CGImage.
|
||||
{
|
||||
/* Returns a capture of a rectangle of a mapped window as a CGImage.
|
||||
With retina displays, the returned image has twice the width and height.
|
||||
CFRelease the returned CGImageRef after use
|
||||
*/
|
||||
{
|
||||
CGImageRef img;
|
||||
NSBitmapImageRep *bitmap = rect_to_NSBitmapImageRep_subwins(pWindow, x, y, w, h, capture_subwins);
|
||||
img = (CGImageRef)[bitmap performSelector:@selector(CGImage)]; // requires Mac OS 10.5
|
||||
|
||||
@ -489,7 +489,7 @@ Fl_RGB_Image* Fl_Cocoa_Gl_Window_Driver::capture_gl_rectangle(int x, int y, int
|
||||
CGImageRelease(cgimg);
|
||||
return rgb;
|
||||
[(NSOpenGLContext*)glw->context() makeCurrentContext];
|
||||
// to capture also the overlay and for directGL demo
|
||||
// to capture also the overlay and for directGL demo
|
||||
[(NSOpenGLContext*)glw->context() flushBuffer];
|
||||
// Read OpenGL context pixels directly.
|
||||
// For extra safety, save & restore OpenGL states that are changed
|
||||
|
||||
@ -123,14 +123,15 @@ int Fl_Cocoa_Printer_Driver::begin_job (int pagecount, int *frompage, int *topag
|
||||
contextInfo:&retval];
|
||||
while (retval < 0) Fl::wait(100);
|
||||
[main makeKeyAndOrderFront:nil];
|
||||
} else
|
||||
} else {
|
||||
retval = [panel runModalWithPrintInfo:info]; //from 10.5
|
||||
}
|
||||
#if MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_9
|
||||
const NSInteger NSModalResponseOK = NSOKButton;
|
||||
#endif
|
||||
if (retval != NSModalResponseOK) return 1;
|
||||
printSession = (PMPrintSession)[info PMPrintSession];//from 10.5
|
||||
pageFormat = (PMPageFormat)[info PMPageFormat];//from 10.5
|
||||
printSession = (PMPrintSession)[info PMPrintSession]; //from 10.5
|
||||
pageFormat = (PMPageFormat)[info PMPageFormat]; //from 10.5
|
||||
printSettings = (PMPrintSettings)[info PMPrintSettings];//from 10.5
|
||||
UInt32 from32, to32;
|
||||
PMGetFirstPage(printSettings, &from32);
|
||||
@ -167,8 +168,7 @@ void Fl_Cocoa_Printer_Driver::margins(int *left, int *top, int *right, int *bott
|
||||
if (top) *top = (int)(margins.top / scale_y + 0.5);
|
||||
if (right) *right = (int)(margins.right / scale_x + 0.5);
|
||||
if (bottom) *bottom = (int)(margins.bottom / scale_y + 0.5);
|
||||
}
|
||||
else {
|
||||
} else {
|
||||
if (left) *left = (int)(margins.top / scale_x + 0.5);
|
||||
if (top) *top = (int)(margins.left / scale_y + 0.5);
|
||||
if (right) *right = (int)(margins.bottom / scale_x + 0.5);
|
||||
|
||||
Loading…
Reference in New Issue
Block a user