Revision: 14328
          http://sourceforge.net/p/skim-app/code/14328
Author:   hofman
Date:     2024-06-11 14:29:08 +0000 (Tue, 11 Jun 2024)
Log Message:
-----------
fix resolution for bitmaps for tiff data

Modified Paths:
--------------
    trunk/PDFPage_SKExtensions.m

Modified: trunk/PDFPage_SKExtensions.m
===================================================================
--- trunk/PDFPage_SKExtensions.m        2024-06-11 14:26:32 UTC (rev 14327)
+++ trunk/PDFPage_SKExtensions.m        2024-06-11 14:29:08 UTC (rev 14328)
@@ -223,8 +223,8 @@
 }
 
 - (NSAttributedString *)thumbnailAttachmentWithSize:(CGFloat)aSize {
-    NSBitmapImageRep *imageRep1 = [self bitmapImageRepWithSize:aSize scale:2.0 
forBox:kPDFDisplayBoxCropBox hasShadow:YES highlights:nil];
-    NSBitmapImageRep *imageRep2 = [self bitmapImageRepWithSize:aSize scale:1.0 
forBox:kPDFDisplayBoxCropBox hasShadow:YES highlights:nil];
+    NSBitmapImageRep *imageRep1 = [self bitmapImageRepWithSize:aSize scale:1.0 
forBox:kPDFDisplayBoxCropBox hasShadow:YES highlights:nil];
+    NSBitmapImageRep *imageRep2 = [self bitmapImageRepWithSize:aSize scale:2.0 
forBox:kPDFDisplayBoxCropBox hasShadow:YES highlights:nil];
     NSData *data = [NSBitmapImageRep 
TIFFRepresentationOfImageRepsInArray:@[imageRep1, imageRep2]];
     NSFileWrapper *wrapper = [[NSFileWrapper alloc] 
initRegularFileWithContents:data];
     NSString *filename = [NSString stringWithFormat:@"page_%lu.tiff", 
(unsigned long)([self pageIndex] + 1)];
@@ -273,8 +273,8 @@
         return nil;
     
     PDFDisplayBox box = NSEqualRects(rect, [self 
boundsForBox:kPDFDisplayBoxCropBox]) ? kPDFDisplayBoxCropBox : 
kPDFDisplayBoxMediaBox;
-    NSBitmapImageRep *imageRep1 = [self bitmapImageRepWithSize:0.0 scale:2.0 
forBox:kPDFDisplayBoxCropBox hasShadow:NO highlights:nil];
-    NSBitmapImageRep *imageRep2 = [self bitmapImageRepWithSize:0.0 scale:1.0 
forBox:kPDFDisplayBoxCropBox hasShadow:NO highlights:nil];
+    NSBitmapImageRep *imageRep1 = [self bitmapImageRepWithSize:0.0 scale:1.0 
forBox:kPDFDisplayBoxCropBox hasShadow:NO highlights:nil];
+    NSBitmapImageRep *imageRep2 = [self bitmapImageRepWithSize:0.0 scale:2.0 
forBox:kPDFDisplayBoxCropBox hasShadow:NO highlights:nil];
     
     NSRect bounds = [self boundsForBox:box];
     

This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.



_______________________________________________
Skim-app-commit mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/skim-app-commit

Reply via email to