https://github.com/orta/preferences
Add preferences support for your Xcode plugins.
https://github.com/orta/preferences
Last synced: 11 months ago
JSON representation
Add preferences support for your Xcode plugins.
- Host: GitHub
- URL: https://github.com/orta/preferences
- Owner: orta
- License: mit
- Created: 2015-03-21T22:02:44.000Z (about 11 years ago)
- Default Branch: master
- Last Pushed: 2015-03-23T12:32:24.000Z (about 11 years ago)
- Last Synced: 2025-04-30T21:42:27.026Z (about 1 year ago)
- Language: Objective-C
- Homepage:
- Size: 232 KB
- Stars: 29
- Watchers: 4
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Add preferences for your Xcode plugins.

Currently in Developer release, if you would like to add support for your plugin, you need to:
Add support for this protocol to one of the classes in your plugin
```objc
#import
@protocol ORPreferenceHost
+ (NSString *)titleForPreferences;
+ (NSViewController *)viewControllerForPreferences;
@end
```
and return a view controller, currently the view frame is 500 by 440. If you'd like to check if someone has the plugin installed, see if `NSClassFromString(@"ORPreferencesEnhancer")` returns something.
### Installation
```
git clone https://github.com/orta/Preferences.git
cd Preferences
xcodebuild
```
Then restart Xcode.
### Example
There is an example plugin which has support for Preferences in the example folder.