window) to a combobox listing the known interpreters.
@interface FileSettings : NSObject <FileSettingsSource>
{
NSString *interpreter; // The pathname of the interpreter to use
+ NSArray *interpreters; // List of known interpreters
BOOL debug; // -d option: debug parser
BOOL verbose; // -v option: verbose import
BOOL inspect; // -i option: interactive mode after script
//- (void)applyUserDefaults: (NSString *)filetype;
- (void)applyValuesFromDict: (NSDictionary *)dict;
- (void)reset;
+- (NSArray *) interpreters;
@end
int i;
NSString *filename;
NSDictionary *dict;
- NSArray *interpreters;
static NSDictionary *factorySettings;
self = [super init];
fsdefaults = [FileSettings getFactorySettingsForFileType: filetype];
self = [self initWithFileSettings: fsdefaults];
if (!self) return self;
+ interpreters = [fsdefaults->interpreters retain];
[self applyUserDefaults: filetype];
prefskey = [filetype retain];
return self;
tabs?" -t":"",
others,
script,
- with_terminal? "&& exit" : " &"];
+ with_terminal? "&& echo Exit status: $? && exit 1" : " &"];
}
+- (NSArray *) interpreters { return interpreters;};
+
// FileSettingsSource protocol
- (NSString *) interpreter { return interpreter;};
- (BOOL) debug { return debug;};
IBClasses = (
{CLASS = FirstResponder; LANGUAGE = ObjC; SUPERCLASS = NSObject; },
{
- ACTIONS = {do_apply = id; do_filetype = id; do_reset = id; };
+ ACTIONS = {"do_apply" = id; "do_filetype" = id; "do_reset" = id; };
CLASS = PreferencesWindowController;
LANGUAGE = ObjC;
OUTLETS = {
others = NSTextField;
tabs = NSButton;
verbose = NSButton;
- with_terminal = NSButton;
+ "with_terminal" = NSButton;
};
SUPERCLASS = NSWindowController;
}
<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE plist SYSTEM "file://localhost/System/Library/DTDs/PropertyList.dtd">
-<plist version="0.9">
+<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
+<plist version="1.0">
<dict>
<key>IBDocumentLocation</key>
- <string>237 -80 356 240 0 0 1280 938 </string>
+ <string>126 59 356 240 0 0 1024 746 </string>
<key>IBFramework Version</key>
- <string>263.2</string>
+ <string>291.0</string>
<key>IBOpenObjects</key>
<array>
<integer>5</integer>
</array>
<key>IBSystem Version</key>
- <string>5S66</string>
+ <string>6G30</string>
</dict>
</plist>
- (void)controlTextDidChange:(NSNotification *)aNotification;
+- (unsigned int)comboBox:(NSComboBox *)aComboBox indexOfItemWithStringValue:(NSString *)aString;
+- (id)comboBox:(NSComboBox *)aComboBox objectValueForItemAtIndex:(int)index;
+- (int)numberOfItemsInComboBox:(NSComboBox *)aComboBox;
+
+
@end
[self update_display];
};
+// NSComboBoxDataSource protocol
+- (unsigned int)comboBox:(NSComboBox *)aComboBox indexOfItemWithStringValue:(NSString *)aString
+{
+ return [[settings interpreters] indexOfObjectIdenticalTo: aString];
+}
+
+- (id)comboBox:(NSComboBox *)aComboBox objectValueForItemAtIndex:(int)index
+{
+ return [[settings interpreters] objectAtIndex: index];
+}
+
+- (int)numberOfItemsInComboBox:(NSComboBox *)aComboBox
+{
+ return [[settings interpreters] count];
+}
+
@end
4A9504D0FFE6A4CB11CA0CBA,
4A9504D1FFE6A4CB11CA0CBA,
);
+ hasScannedForEncodings = 1;
isa = PBXProject;
mainGroup = 2A37F4AAFDCFA73011CA2CEA;
projectDirPath = "";
refType = 4;
};
2A37F4ACFDCFA73011CA2CEA = {
+ fileEncoding = 30;
isa = PBXFileReference;
path = MyDocument.m;
refType = 4;
};
2A37F4AEFDCFA73011CA2CEA = {
+ fileEncoding = 30;
isa = PBXFileReference;
path = MyDocument.h;
refType = 4;
refType = 4;
};
2A37F4B0FDCFA73011CA2CEA = {
+ fileEncoding = 30;
isa = PBXFileReference;
path = main.m;
refType = 4;
</dict>
</plist>
";
- shouldUseHeadermap = 1;
};
2A37F4C7FDCFA73011CA2CEA = {
buildActionMask = 2147483647;
//F53
//F54
F52A90CD02EB5C6A01000102 = {
+ fileEncoding = 30;
isa = PBXFileReference;
path = FileSettings.m;
refType = 4;
};
F52A90CE02EB5C6A01000102 = {
+ fileEncoding = 30;
isa = PBXFileReference;
path = FileSettings.h;
refType = 4;
};
};
F5A42167038BDD8E0110C447 = {
+ fileEncoding = 30;
isa = PBXFileReference;
path = factorySettings.plist;
refType = 4;
};
};
F5A4C14002F2055C01000102 = {
+ fileEncoding = 30;
isa = PBXFileReference;
path = PreferencesWindowController.h;
refType = 4;
};
F5A4C14102F2055C01000102 = {
+ fileEncoding = 30;
isa = PBXFileReference;
path = PreferencesWindowController.m;
refType = 4;
};
};
F5A4C14402F2070D01000102 = {
+ fileEncoding = 30;
isa = PBXFileReference;
path = MyAppDelegate.m;
refType = 4;
};
F5A4C14502F2070D01000102 = {
+ fileEncoding = 30;
isa = PBXFileReference;
path = MyAppDelegate.h;
refType = 4;
};
};
F5AA9C6A02F8042D0110C447 = {
+ fileEncoding = 30;
isa = PBXFileReference;
path = doscript.h;
refType = 4;
};
};
F5AAA21D02F8115D0110C447 = {
+ fileEncoding = 30;
isa = PBXFileReference;
path = doscript.m;
refType = 4;
<string>/sw/bin/python</string>
<string>/Library/Frameworks/Python.framework/Versions/Current/bin/python</string>
<string>/usr/bin/python</string>
+ <string>/usr/local/bin/pythonw</string>
+ <string>/sw/bin/pythonw</string>
+ <string>/Library/Frameworks/Python.framework/Versions/Current/Resources/Python.app/Contents/MacOS/python</string>
+ <string>/usr/bin/pythonw</string>
+ <string>/Applications/MacPython-OSX/python-additions/Python.app/Contents/MacOS/python</string>
</array>
<key>nosite</key>
<false/>