Skip to content
NSSavePanel wrapper for image save dialogs, similar to those in Preview.app
Objective-C Shell Ruby C
Find file
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.
Example
Pod
.gitignore
.travis.yml
JFImageSavePanel.podspec
LICENSE
README.md
screenshot.png

README.md

JFImageSavePanel

Version License Platform

NSSavePanel wrapper for image save dialogs, similar to those in Preview.app.

A quick note about IKSaveOptions

Apple provides IKSaveOptions, a class that offers similar functionality which I wasn't aware of when I first wrote this library. It might be worth checking this out first to see if it meets your needs; thanks to Marek Hrušovský for heads-up.

Example

To run the example project, clone the repo, and run pod install from the Example directory first.

Installation

JFImageSavePanel is available through CocoaPods. To install it, simply add the following line to your Podfile:

pod "JFImageSavePanel"

Screenshot

JFImageSavePanel

Usage Example

JFImageSavePanel *panel = [JFImageSavePanel savePanel];

NSImage *image = [[NSImage alloc] initWithContentsOfURL:[NSURL URLWithString:@"http://..."]];

// This is the default image type, which can be changed.
// Possible values: kUTTypeJPEG, kUTTypeJPEG2000, kUTTypePNG, kUTTypeTIFF.
[panel setImageType:kUTTypeJPEG];

// Image will be saved to selected path if 'OK' button is pressed
[panel runModalForImage:image error:NULL];

Contributors

Copyright and License

© 2012 Jason Frame [ jason@onehackoranother.com / @jaz303 ]
MIT Licensed

Something went wrong with that request. Please try again.