Skip to content

Commit 8831f33

Browse files
committed
Update the code documentation
1 parent 0b42cf7 commit 8831f33

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

SDWebImagePDFCoder/Classes/SDImagePDFCoder.h

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -13,16 +13,16 @@
1313

1414
NS_ASSUME_NONNULL_BEGIN
1515

16+
static const SDImageFormat SDImageFormatPDF = 13;
17+
1618
/***
1719
SDImagePDFCoder is a PDF image coder, which use the built-in UIKit/AppKit method to decode PDF images. And it will use the Core Graphics to draw PDF images when needed (For example, current firmware does not support built-in rendering). This class does not use PDFKit framwork because we focus on PDF vector images but not document pages rendering.
1820
19-
@note: For iOS/tvOS, from iOS/tvOS 11+, Apple support built-in vector scale for PDF image in `UIImage`. Which means you can just get set a image to the `UIImaegView`, then changing image view's bounds, contentMode to adjust the PDF image without losing any detail. However, when running on lower firmware, we don't support vector scaling and parse PDF image as a bitmap image. You can use `SDWebImageContextPDFImageSize` and `SDWebImageContextPDFImagePreserveAspectRatio` during image loading to specify a desired size (such as larger size for view rendering).
20-
@note: For macOS, Apple support built-in vector scale for PDF image in `NSImage`. However, `NSImage` is mutable, you can change the size after image was loaded.
21-
@note: By default we parse the first page (pageNumber = 1) of PDF image, for custom page number, check `SDWebImageContextPDFPageNumber` context option.
21+
@note For iOS/tvOS, from iOS/tvOS 11+, Apple support built-in vector scale for PDF image in `UIImage`. Which means you can just get set a image to the `UIImaegView`, then changing image view's bounds, contentMode to adjust the PDF image without losing any detail. However, when running on lower firmware, we don't support vector scaling and parse PDF image as a bitmap image. You can use `SDImageCoderDecodeThumnailPixelSize` and `SDWebImageContextImagePreserveAspectRatio` during image loading to specify a desired size (such as larger size for view rendering).
22+
@note For macOS, Apple support built-in vector scale for PDF image in `NSImage`. However, `NSImage` is mutable, you can change the size after image was loaded.
23+
@note By default we parse the first page (pageNumber = 1) of PDF image, for custom page number, check `SDWebImageContextPDFPageNumber` context option.
24+
@note If you call the coder directly, use the coder option (See `SDWebImagePDFCoderDefine.h`) instead of the context option.
2225
*/
23-
24-
static const SDImageFormat SDImageFormatPDF = 13;
25-
2626
@interface SDImagePDFCoder : NSObject <SDImageCoder>
2727

2828
@property (nonatomic, class, readonly) SDImagePDFCoder *sharedCoder;

0 commit comments

Comments
 (0)