Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

1) Remap underline format keyboard shortcut.

2) Prevent a network staff member from banning themselves through a G:Line
3) Add option to disable inline images for specific channels
4) Add option to disable join, part, and quit activity for specific channels
5) Fix support for the command "/join 0" in order to part all channels
6) Bring over support for regular expression highlights from the master branch
7) Bring over new caching engine from master branch
8) Do not compile modern regular expression engine by default
9) Fix bug in simplified light resulting in it not displaying some content properly
10) Fix plugins not being compiled alongside Textual
11) Added support for multiple inline images
12) Added support for Textual not to show duplicate inline images when it does multiple
13) Groundwork for ability to hide an inline image
  • Loading branch information...
commit e7e8897471a8b1cd08ef46b730d859a749668cf7 1 parent b2f191e
@emsquared emsquared authored
Showing with 1,296 additions and 850 deletions.
  1. +14 −4 Classes/Controllers/MasterController.m
  2. +6 −2 Classes/Controllers/MenuController.m
  3. +10 −0 Classes/Dialogs/ChannelSheet.m
  4. +22 −0 Classes/Dialogs/Preferences/PreferencesController.m
  5. +11 −0 Classes/Dialogs/Preferences/ScriptsWrapper.m
  6. +6 −0 Classes/Headers/ChannelSheet.h
  7. +0 −1  Classes/Headers/IRC.h
  8. +4 −0 Classes/Headers/IRCChannelConfig.h
  9. 0  Classes/{Views → Headers}/ListSeparatorCell.h
  10. +2 −3 Classes/Headers/Preferences.h
  11. +6 −0 Classes/Headers/PreferencesController.h
  12. +2 −1  Classes/Headers/StaticDefinitions.h
  13. +13 −4 Classes/Helpers/NSBundleHelper.m
  14. +1 −1  Classes/Helpers/NSStringHelper.m
  15. +8 −0 Classes/IRC/IRCChannelConfig.m
  16. +66 −65 Classes/IRC/IRCClient.m
  17. +10 −10 Classes/Library/TXRegularExpression.m
  18. +10 −9 Classes/Preferences/Preferences.m
  19. +10 −70 Classes/Preferences/ViewTheme.m
  20. +10 −6 Classes/Views/Log/ImageURLParser.m
  21. +43 −30 Classes/Views/Log/LogController.m
  22. +102 −72 Classes/Views/Log/LogRenderer.m
  23. +4 −0 Classes/Views/Log/LogScriptEventSink.m
  24. +4 −5 English.lproj/BasicLanguage.strings
  25. +666 −523 English.lproj/ChannelSheet.xib
  26. +250 −33 English.lproj/Preferences.xib
  27. BIN  Frameworks/Blowfish/BlowfishEncryption.framework/Versions/A/BlowfishEncryption
  28. +5 −1 Resources/Javascript/API/core.js
  29. +2 −2 Resources/Miscellaneous/Info.plist
  30. +1 −0  Resources/Styles/Simplified Light/design.css
  31. +8 −8 Textual.xcodeproj/project.pbxproj
View
18 Classes/Controllers/MasterController.m
@@ -885,9 +885,6 @@ - (void)completeNick:(BOOL)forward
if (commandMode) {
choices = [NSMutableArray array];
-
- NSArray *resourceFiles = [_NSFileManager() contentsOfDirectoryAtPath:[Preferences whereScriptsPath] error:NULL];
-
for (NSString *command in [[Preferences commandIndexList] allKeys]) {
[choices safeAddObject:[command lowercaseString]];
}
@@ -900,6 +897,19 @@ - (void)completeNick:(BOOL)forward
}
}
+ NSArray *resourceFiles = [_NSFileManager() contentsOfDirectoryAtPath:[Preferences whereScriptsPath] error:NULL];
+
+ for (NSString *file in resourceFiles) {
+ NSArray *parts = [NSArray arrayWithArray:[file componentsSeparatedByString:@"."]];
+ NSString *cmdl = [[parts stringAtIndex:0] lowercaseString];
+
+ if ([choices containsObject:cmdl] == NO) {
+ [choices safeAddObject:cmdl];
+ }
+ }
+
+ resourceFiles = [_NSFileManager() contentsOfDirectoryAtPath:[Preferences whereScriptsLocalPath] error:NULL];
+
for (NSString *file in resourceFiles) {
NSArray *parts = [NSArray arrayWithArray:[file componentsSeparatedByString:@"."]];
NSString *cmdl = [[parts stringAtIndex:0] lowercaseString];
@@ -1349,7 +1359,7 @@ - (void)registerKeyHandlers
[self handler:@selector(sendMsgAction:) code:KEY_RETURN mods:NSCommandKeyMask];
[self handler:@selector(textFormattingBold:) char:'b' mods:NSCommandKeyMask];
- [self handler:@selector(textFormattingUnderline:) char:'u' mods:NSCommandKeyMask];
+ [self handler:@selector(textFormattingUnderline:) char:'u' mods:(NSCommandKeyMask | NSShiftKeyMask)];
[self handler:@selector(textFormattingItalic:) char:'i' mods:(NSCommandKeyMask | NSShiftKeyMask)];
[self handler:@selector(textFormattingForegroundColor:) char:'c' mods:(NSCommandKeyMask | NSShiftKeyMask)];
[self handler:@selector(textFormattingBackgroundColor:) char:'c' mods:(NSCommandKeyMask | NSShiftKeyMask | NSAlternateKeyMask)];
View
8 Classes/Controllers/MenuController.m
@@ -1422,8 +1422,12 @@ - (void)onMemberGline:(id)sender
if (NO_CLIENT_OR_CHANNEL || IS_CLIENT) return;
for (IRCUser *m in [self selectedMembers:sender]) {
- [u sendCommand:[NSString stringWithFormat:@"GLINE %@ %@", m.nick, [Preferences IRCopDefaultGlineMessage]]];
- }
+ if ([m.nick isEqualNoCase:u.myNick]) {
+ [u printDebugInformation:TXTFLS(@"SELF_BAN_DETECTED_MESSAGE", u.serverHostname) channel:c];
+ } else {
+ [u sendCommand:[NSString stringWithFormat:@"GLINE %@ %@", m.nick, [Preferences IRCopDefaultGlineMessage]]];
+ }
+ }
[self deselectMembers:sender];
}
View
10 Classes/Dialogs/ChannelSheet.m
@@ -29,6 +29,9 @@ @implementation ChannelSheet
@synthesize contentView;
@synthesize generalView;
@synthesize encryptView;
+@synthesize defaultsView;
+@synthesize inlineImagesCheck;
+@synthesize JPQActivityCheck;
- (id)init
{
@@ -60,6 +63,9 @@ - (void)onMenuBarItemChanged:(id)sender
case 1:
[self firstPane:encryptView];
break;
+ case 2:
+ [self firstPane:defaultsView];
+ break;
default:
[self firstPane:generalView];
break;
@@ -122,6 +128,8 @@ - (void)load
growlCheck.state = config.growl;
autoJoinCheck.state = config.autoJoin;
ihighlights.state = config.ihighlights;
+ JPQActivityCheck.state = config.iJPQActivity;
+ inlineImagesCheck.state = config.inlineImages;
}
- (void)save
@@ -135,6 +143,8 @@ - (void)save
config.growl = growlCheck.state;
config.autoJoin = autoJoinCheck.state;
config.ihighlights = ihighlights.state;
+ config.iJPQActivity = JPQActivityCheck.state;
+ config.inlineImages = inlineImagesCheck.state;
if ([config.name isChannelName] == NO) {
config.name = [@"#" stringByAppendingString:config.name];
View
22 Classes/Dialogs/Preferences/PreferencesController.m
@@ -46,7 +46,9 @@ @implementation PreferencesController
@synthesize scriptsView;
@synthesize stylesView;
@synthesize themeButton;
+@synthesize highlightNicknameButton;
@synthesize transcriptFolderButton;
+@synthesize addExcludeWordButton;
@synthesize transfersView;
@synthesize updatesView;
@synthesize world;
@@ -107,6 +109,7 @@ - (void)show
[self.window makeKeyAndOrderFront:nil];
[self setUpToolbarItemsAndMenus];
+ [self onHighlightTypeChanged:nil];
[self firstPane:generalView selectedItem:0];
}
@@ -485,6 +488,25 @@ - (void)onChangedTransparency:(id)sender
#pragma mark -
#pragma mark Actions
+- (void)onHighlightTypeChanged:(id)sender
+{
+ if ([Preferences keywordMatchingMethod] == KEYWORD_MATCH_REGEX) {
+ [highlightNicknameButton setEnabled:NO];
+ [addExcludeWordButton setEnabled:YES];
+ [excludeWordsTable setEnabled:YES];
+ } else {
+ [highlightNicknameButton setEnabled:YES];
+
+ if ([Preferences keywordMatchingMethod] == KEYWORD_MATCH_PARTIAL) {
+ [addExcludeWordButton setEnabled:YES];
+ [excludeWordsTable setEnabled:YES];
+ } else {
+ [addExcludeWordButton setEnabled:NO];
+ [excludeWordsTable setEnabled:NO];
+ }
+ }
+}
+
- (void)editTable:(NSTableView *)table
{
NSInteger row = ([table numberOfRows] - 1);
View
11 Classes/Dialogs/Preferences/ScriptsWrapper.m
@@ -27,6 +27,17 @@ - (void)populateData;
[scripts safeAddObject:script];
}
}
+
+ resourceFiles = [_NSFileManager() contentsOfDirectoryAtPath:[Preferences whereScriptsLocalPath] error:NULL];
+
+ for (NSString *file in resourceFiles) {
+ NSArray *nameParts = [file componentsSeparatedByString:@"."];
+ NSString *script = [[nameParts stringAtIndex:0] lowercaseString];
+
+ if ([scripts containsObject:script] == NO) {
+ [scripts safeAddObject:script];
+ }
+ }
for (NSString *cmd in world.bundlesForUserInput) {
cmd = [cmd lowercaseString];
View
6 Classes/Headers/ChannelSheet.h
@@ -12,6 +12,7 @@
IBOutlet NSView *contentView;
IBOutlet NSView *generalView;
IBOutlet NSView *encryptView;
+ IBOutlet NSView *defaultsView;
IBOutlet NSTextField *nameText;
IBOutlet NSTextField *passwordText;
@@ -24,6 +25,8 @@
IBOutlet NSButton *ihighlights;
IBOutlet NSButton *autoJoinCheck;
IBOutlet NSButton *growlCheck;
+ IBOutlet NSButton *inlineImagesCheck;
+ IBOutlet NSButton *JPQActivityCheck;
}
@property (nonatomic, assign) NSInteger uid;
@@ -31,6 +34,7 @@
@property (nonatomic, retain) NSView *contentView;
@property (nonatomic, retain) NSView *generalView;
@property (nonatomic, retain) NSView *encryptView;
+@property (nonatomic, retain) NSView *defaultsView;
@property (nonatomic, retain) IRCChannelConfig *config;
@property (nonatomic, retain) NSTextField *nameText;
@property (nonatomic, retain) NSTextField *passwordText;
@@ -41,6 +45,8 @@
@property (nonatomic, retain) NSButton *autoJoinCheck;
@property (nonatomic, retain) NSButton *ihighlights;
@property (nonatomic, retain) NSButton *growlCheck;
+@property (nonatomic, retain) NSButton *inlineImagesCheck;
+@property (nonatomic, retain) NSButton *JPQActivityCheck;
- (void)start;
- (void)show;
View
1  Classes/Headers/IRC.h
@@ -75,7 +75,6 @@
#define IRCCI_RAW @"RAW"
#define IRCCI_REJOIN @"REJOIN"
#define IRCCI_REMOVE @"REMOVE"
-#define IRCCI_RESETFILES @"RESETFILES"
#define IRCCI_SEND @"SEND"
#define IRCCI_SERVER @"SERVER"
#define IRCCI_SHUN @"SHUN"
View
4 Classes/Headers/IRCChannelConfig.h
@@ -17,6 +17,8 @@ typedef enum {
BOOL growl;
BOOL autoJoin;
BOOL ihighlights;
+ BOOL inlineImages;
+ BOOL iJPQActivity;
NSString *mode;
NSString *topic;
@@ -29,6 +31,8 @@ typedef enum {
@property (nonatomic, assign) BOOL autoJoin;
@property (nonatomic, assign) BOOL growl;
@property (nonatomic, assign) BOOL ihighlights;
+@property (nonatomic, assign) BOOL inlineImages;
+@property (nonatomic, assign) BOOL iJPQActivity;
@property (nonatomic, retain) NSString *mode;
@property (nonatomic, retain) NSString *topic;
@property (nonatomic, retain) NSString *encryptionKey;
View
0  Classes/Views/ListSeparatorCell.h → Classes/Headers/ListSeparatorCell.h
File renamed without changes
View
5 Classes/Headers/Preferences.h
@@ -2,12 +2,13 @@
// Modifications by Codeux Software <support AT codeux DOT com> <https://github.com/codeux/Textual>
// You can redistribute it and/or modify it under the new BSD license.
-#define DEFAULT_TEXTUAL_STYLE @"user:Simplified Dark"
+#define DEFAULT_TEXTUAL_STYLE @"resource:Simplified Dark"
#define DEFAULT_TEXTUAL_FONT @"Lucida Grande"
typedef enum {
KEYWORD_MATCH_PARTIAL = 0,
KEYWORD_MATCH_EXACT,
+ KEYWORD_MATCH_REGEX,
} KeywordMatchType;
typedef enum {
@@ -53,8 +54,6 @@ typedef enum {
+ (NSString *)applicationName;
+ (NSInteger)applicationProcessID;
-+ (BOOL)forceReplaceExtensions;
-
+ (NSDictionary *)textualInfoPlist;
+ (NSDictionary *)systemInfoPlist;
View
6 Classes/Headers/PreferencesController.h
@@ -27,6 +27,9 @@
IBOutlet NSView *IRCopServicesView;
IBOutlet NSView *channelManagementView;
IBOutlet NSView *experimentalSettingsView;
+
+ IBOutlet NSButton *highlightNicknameButton;
+ IBOutlet NSButton *addExcludeWordButton;
IBOutlet NSTableView *keywordsTable;
IBOutlet NSTableView *excludeWordsTable;
@@ -68,6 +71,8 @@
@property (nonatomic, retain) NSView *IRCopServicesView;
@property (nonatomic, retain) NSView *channelManagementView;
@property (nonatomic, retain) NSView *experimentalSettingsView;
+@property (nonatomic, retain) NSButton *highlightNicknameButton;
+@property (nonatomic, retain) NSButton *addExcludeWordButton;
@property (nonatomic, retain) NSTableView *keywordsTable;
@property (nonatomic, retain) NSTableView *excludeWordsTable;
@property (nonatomic, retain) NSTableView *installedScriptsTable;
@@ -86,6 +91,7 @@
- (void)onAddKeyword:(id)sender;
- (void)onAddExcludeWord:(id)sender;
+- (void)onHighlightTypeChanged:(id)sender;
- (void)onSelectFont:(id)sender;
- (void)onStyleChanged:(id)sender;
- (void)onChangedTheme:(id)sender;
View
3  Classes/Headers/StaticDefinitions.h
@@ -1,5 +1,6 @@
/* Availability Macros */
-#define _LOAD_MAC_OS_LION_LIBRARIES 0
+#define _LOAD_MAC_OS_LION_LIBRARIES 1
+//#define _USES_MODERN_REGULAR_EXPRESSION
#if _LOAD_MAC_OS_LION_LIBRARIES
#if defined(MAC_OS_X_VERSION_10_7)
View
17 Classes/Helpers/NSBundleHelper.m
@@ -82,7 +82,8 @@ + (void)deallocBundlesFromMemory:(IRCWorld *)world
+ (void)loadBundlesIntoMemory:(IRCWorld *)world
{
- NSString *path = [Preferences wherePluginsPath];
+ NSString *path_1 = [Preferences wherePluginsPath];
+ NSString *path_2 = [Preferences wherePluginsLocalPath];
if (NSObjectIsNotEmpty(world.allLoadedBundles)) {
[self deallocBundlesFromMemory:world];
@@ -95,11 +96,19 @@ + (void)loadBundlesIntoMemory:(IRCWorld *)world
NSMutableDictionary *serverInputBundles = [NSMutableDictionary new];
NSMutableDictionary *outputRulesDict = [NSMutableDictionary new];
- NSArray *resourceFiles = [_NSFileManager() contentsOfDirectoryAtPath:path error:NULL];
-
+ NSArray *resourceFiles_1 = [_NSFileManager() contentsOfDirectoryAtPath:path_1 error:NULL];
+ NSArray *resourceFiles_2 = [_NSFileManager() contentsOfDirectoryAtPath:path_2 error:NULL];
+
+ NSArray *resourceFiles = [resourceFiles_1 arrayByAddingObjectsFromArray:resourceFiles_2];
+
for (NSString *file in resourceFiles) {
if ([file hasSuffix:@".bundle"]) {
- NSString *fullPath = [path stringByAppendingPathComponent:file];
+ NSString *fullPath = [path_2 stringByAppendingPathComponent:file];
+
+ if ([_NSFileManager() fileExistsAtPath:fullPath] == NO) {
+ fullPath = [path_1 stringByAppendingPathComponent:file];
+ }
+
NSBundle *currBundle = [NSBundle bundleWithPath:fullPath];
TextualPluginItem *plugin = [TextualPluginItem new];
View
2  Classes/Helpers/NSStringHelper.m
@@ -512,7 +512,7 @@ - (NSRange)rangeOfChannelNameStart:(NSInteger)start
NSString *shortstring = [self safeSubstringFromIndex:start];
- NSRange rs = [TXRegularExpression string:shortstring rangeOfRegex:@"(#\\w\\w+)"];
+ NSRange rs = [TXRegularExpression string:shortstring rangeOfRegex:@"#([a-zA-Z0-9\\#\\-]+)"];
if (rs.location == NSNotFound) return NSMakeRange(NSNotFound, 0);
NSRange r = NSMakeRange((rs.location + start), rs.length);
View
8 Classes/IRC/IRCChannelConfig.m
@@ -13,12 +13,16 @@ @implementation IRCChannelConfig
@synthesize topic;
@synthesize ihighlights;
@synthesize encryptionKey;
+@synthesize iJPQActivity;
+@synthesize inlineImages;
- (id)init
{
if ((self = [super init])) {
type = CHANNEL_TYPE_CHANNEL;
+ inlineImages = NO;
+ iJPQActivity = NO;
ihighlights = NO;
autoJoin = YES;
growl = YES;
@@ -45,6 +49,8 @@ - (id)initWithDictionary:(NSDictionary *)dic
growl = [dic boolForKey:@"growl"];
autoJoin = [dic boolForKey:@"auto_join"];
ihighlights = [dic boolForKey:@"ignore_highlights"];
+ inlineImages = [dic boolForKey:@"disable_images"];
+ iJPQActivity = [dic boolForKey:@"ignore_join,leave"];
mode = (([[dic stringForKey:@"mode"] retain]) ?: NSNullObject);
topic = (([[dic stringForKey:@"topic"] retain]) ?: NSNullObject);
@@ -73,6 +79,8 @@ - (NSMutableDictionary *)dictionaryValue
[dic setBool:growl forKey:@"growl"];
[dic setBool:autoJoin forKey:@"auto_join"];
[dic setBool:ihighlights forKey:@"ignore_highlights"];
+ [dic setBool:inlineImages forKey:@"disable_images"];
+ [dic setBool:iJPQActivity forKey:@"ignore_join,leave"];
if (name) [dic setObject:name forKey:@"name"];
if (password) [dic setObject:password forKey:@"password"];
View
131 Classes/IRC/IRCClient.m
@@ -977,7 +977,11 @@ - (void)joinUnlistedChannel:(NSString *)channel password:(NSString *)password
}
[self forceJoinChannel:channel password:password];
- }
+ } else {
+ if ([channel isEqualToString:@"0"]) {
+ [self forceJoinChannel:channel password:password];
+ }
+ }
}
- (void)forceJoinChannel:(NSString *)channel password:(NSString *)password
@@ -1578,7 +1582,7 @@ - (BOOL)sendCommand:(NSString *)str completeTarget:(BOOL)completeTarget target:(
} else {
targetChannelName = [s getToken];
- if ([targetChannelName isChannelName] == NO) {
+ if ([targetChannelName isChannelName] == NO && [targetChannelName isEqualToString:@"0"] == NO) {
targetChannelName = [@"#" stringByAppendingString:targetChannelName];
}
}
@@ -2418,35 +2422,6 @@ - (BOOL)sendCommand:(NSString *)str completeTarget:(BOOL)completeTarget target:(
return YES;
break;
}
- case 90: // Command: RESETFILES
- {
- NSString *path = [Preferences whereApplicationSupportPath];
-
- BOOL doAction = [PopupPrompts dialogWindowWithQuestion:TXTFLS(@"RESOURCES_FILE_RESET_WARNING_MESSAGE", path)
- title:TXTLS(@"RESOURCES_FILE_RESET_WARNING_TITLE")
- defaultButton:TXTLS(@"CONTINUE_BUTTON")
- alternateButton:TXTLS(@"CANCEL_BUTTON")
- suppressionKey:nil suppressionText:nil];
-
- if (doAction) {
- if ([_NSFileManager() removeItemAtPath:path error:NULL] == NO) {
- NSLog(@"Silently ignoring failed resource removal.");
- }
-
- [PopupPrompts dialogWindowWithQuestion:TXTLS(@"RESOURCES_FILE_RESET_QUITTING_MESSAGE")
- title:TXTLS(@"RESOURCES_FILE_RESET_QUITTING_TITLE")
- defaultButton:TXTLS(@"OK_BUTTON")
- alternateButton:nil suppressionKey:nil
- suppressionText:nil];
-
- world.master.terminating = YES;
-
- [NSApp terminate:nil];
- }
-
- return YES;
- break;
- }
case 74: // Command: MUTE
{
if (world.soundMuted) {
@@ -2595,22 +2570,34 @@ - (BOOL)sendCommand:(NSString *)str completeTarget:(BOOL)completeTarget target:(
{
NSArray *extensions = [NSArray arrayWithObjects:@".scpt", @".py", @".pyc", @".rb", @".pl", @".sh", @".bash", @"", nil];
NSString *scriptPath = [NSString string];
+ NSString *command = [cmd lowercaseString];
BOOL scriptFound;
for (NSString *i in extensions) {
- scriptPath = [[Preferences whereScriptsPath] stringByAppendingPathComponent:[NSString stringWithFormat:@"%@%@", [cmd lowercaseString], i]];
+ NSString *filename = [NSString stringWithFormat:@"%@%@", cmd, i];
+
+ scriptPath = [[Preferences whereScriptsPath] stringByAppendingPathComponent:filename];
scriptFound = [_NSFileManager() fileExistsAtPath:scriptPath];
if (scriptFound == YES) {
break;
+ } else {
+ scriptPath = [[Preferences whereScriptsLocalPath] stringByAppendingPathComponent:filename];
+ scriptFound = [_NSFileManager() fileExistsAtPath:scriptPath];
+
+ if (scriptFound == YES) {
+ break;
+ } else {
+ continue;
+ }
}
}
BOOL pluginFound = BOOLValueFromObject([world.bundlesForUserInput objectForKey:cmd]);
if (pluginFound && scriptFound) {
- NSLog(@"Command %@ shared by both a script and plugin. Sending to server because of inability to determine priority.", cmd);
+ NSLog(TXTLS(@"PLUGIN_COMMAND_CLASH_ERROR_MESSAGE") ,cmd);
} else {
if (pluginFound) {
[[self invokeInBackgroundThread] processBundlesUserMessage:[NSArray arrayWithObjects:[NSString stringWithString:s], cmd, nil]];
@@ -3206,13 +3193,15 @@ - (BOOL)printChannel:(id)chan type:(LogLineType)type nick:(NSString *)nick text:
keywords = [Preferences keywords];
excludeWords = [Preferences excludeWords];
- if ([Preferences keywordCurrentNick]) {
- NSMutableArray *ary = [[keywords mutableCopy] autodrain];
-
- [ary safeInsertObject:myNick atIndex:0];
-
- keywords = ary;
- }
+ if ([Preferences keywordMatchingMethod] != KEYWORD_MATCH_REGEX) {
+ if ([Preferences keywordCurrentNick]) {
+ NSMutableArray *ary = [[keywords mutableCopy] autodrain];
+
+ [ary safeInsertObject:myNick atIndex:0];
+
+ keywords = ary;
+ }
+ }
}
}
}
@@ -3829,31 +3818,35 @@ - (void)receiveJoin:(IRCMessage *)m
[c addMember:u];
}
+ AddressBook *ignoreChecks = [self checkIgnoreAgainstHostmask:m.sender.raw
+ withMatches:[NSArray arrayWithObjects:@"ignoreJPQE", @"notifyJoins", nil]];
+
+ if ([ignoreChecks ignoreJPQE] == YES && myself == NO) {
+ return;
+ }
+
+ if (hasIRCopAccess == NO) {
+ if ([ignoreChecks notifyJoins] == YES) {
+ NSString *tracker = [ignoreChecks trackingNickname];
+
+ BOOL ison = [trackedUsers boolForKey:tracker];
+
+ if (ison == NO) {
+ [self handleUserTrackingNotification:ignoreChecks
+ nickname:m.sender.nick
+ hostmask:[m.sender.raw hostmaskFromRawString]
+ langitem:@"USER_TRACKING_HOSTMASK_NOW_AVAILABLE"];
+
+ [trackedUsers setBool:YES forKey:tracker];
+ }
+ }
+ }
+
if ([Preferences showJoinLeave]) {
- AddressBook *ignoreChecks = [self checkIgnoreAgainstHostmask:m.sender.raw
- withMatches:[NSArray arrayWithObjects:@"ignoreJPQE", @"notifyJoins", nil]];
-
- if ([ignoreChecks ignoreJPQE] == YES && myself == NO) {
- return;
- }
-
- if (hasIRCopAccess == NO) {
- if ([ignoreChecks notifyJoins] == YES) {
- NSString *tracker = [ignoreChecks trackingNickname];
-
- BOOL ison = [trackedUsers boolForKey:tracker];
-
- if (ison == NO) {
- [self handleUserTrackingNotification:ignoreChecks
- nickname:m.sender.nick
- hostmask:[m.sender.raw hostmaskFromRawString]
- langitem:@"USER_TRACKING_HOSTMASK_NOW_AVAILABLE"];
-
- [trackedUsers setBool:YES forKey:tracker];
- }
- }
- }
-
+ if (c.config.iJPQActivity) {
+ return;
+ }
+
NSString *text = TXTFLS(@"IRC_USER_JOINED_CHANNEL", nick, m.sender.user, m.sender.address);
[self printBoth:c type:LINE_TYPE_JOIN text:text];
@@ -3878,6 +3871,10 @@ - (void)receivePart:(IRCMessage *)m
[c removeMember:nick];
if ([Preferences showJoinLeave]) {
+ if (c.config.iJPQActivity) {
+ return;
+ }
+
AddressBook *ignoreChecks = [self checkIgnoreAgainstHostmask:m.sender.raw
withMatches:[NSArray arrayWithObjects:@"ignoreJPQE", nil]];
@@ -3909,6 +3906,10 @@ - (void)receiveKick:(IRCMessage *)m
[c removeMember:target];
if ([Preferences showJoinLeave]) {
+ if (c.config.iJPQActivity) {
+ return;
+ }
+
AddressBook *ignoreChecks = [self checkIgnoreAgainstHostmask:m.sender.raw
withMatches:[NSArray arrayWithObjects:@"ignoreJPQE", nil]];
@@ -3979,7 +3980,7 @@ - (void)receiveQuit:(IRCMessage *)m
for (IRCChannel *c in channels) {
if ([c findMember:nick]) {
- if ([Preferences showJoinLeave]) {
+ if ([Preferences showJoinLeave] && c.config.iJPQActivity == NO) {
[self printChannel:c type:LINE_TYPE_QUIT text:text];
}
View
20 Classes/Library/TXRegularExpression.m
@@ -25,7 +25,7 @@ + (BOOL)string:(NSString *)haystack isMatchedByRegex:(NSString *)needle withoutC
{
NSRange strRange = NSMakeRange(0, [haystack length]);
-#ifdef _RUNNING_MAC_OS_LION
+#ifdef _USES_MODERN_REGULAR_EXPRESSION
if ([self useNewRegularExpressionEngine]) {
NSRegularExpression *regex;
@@ -46,8 +46,8 @@ + (BOOL)string:(NSString *)haystack isMatchedByRegex:(NSString *)needle withoutC
} else {
return [haystack isMatchedByRegex:needle];
}
-
-#ifdef _RUNNING_MAC_OS_LION
+
+#ifdef _USES_MODERN_REGULAR_EXPRESSION
}
#endif
}
@@ -61,7 +61,7 @@ + (NSRange)string:(NSString *)haystack rangeOfRegex:(NSString *)needle withoutCa
{
NSRange strRange = NSMakeRange(0, [haystack length]);
-#ifdef _RUNNING_MAC_OS_LION
+#ifdef _USES_MODERN_REGULAR_EXPRESSION
if ([self useNewRegularExpressionEngine]) {
NSRegularExpression *regex;
@@ -83,14 +83,14 @@ + (NSRange)string:(NSString *)haystack rangeOfRegex:(NSString *)needle withoutCa
return [haystack rangeOfRegex:needle];
}
-#ifdef _RUNNING_MAC_OS_LION
+#ifdef _USES_MODERN_REGULAR_EXPRESSION
}
#endif
}
+ (NSString *)string:(NSString *)haystack replacedByRegex:(NSString *)needle withString:(NSString *)puppy
{
-#ifdef _RUNNING_MAC_OS_LION
+#ifdef _USES_MODERN_REGULAR_EXPRESSION
if ([self useNewRegularExpressionEngine]) {
NSRange strRange = NSMakeRange(0, [haystack length]);
@@ -104,11 +104,11 @@ + (NSString *)string:(NSString *)haystack replacedByRegex:(NSString *)needle wit
return [haystack stringByReplacingOccurrencesOfRegex:needle withString:puppy];
-#ifdef _RUNNING_MAC_OS_LION
+#ifdef _USES_MODERN_REGULAR_EXPRESSION
}
#endif
}
-
+
+ (NSArray *)matchesInString:(NSString *)haystack withRegex:(NSString *)needle
{
return [self matchesInString:haystack withRegex:needle withoutCase:NO];
@@ -118,7 +118,7 @@ + (NSArray *)matchesInString:(NSString *)haystack withRegex:(NSString *)needle w
{
NSRange strRange = NSMakeRange(0, [haystack length]);
-#ifdef _RUNNING_MAC_OS_LION
+#ifdef _USES_MODERN_REGULAR_EXPRESSION
if ([self useNewRegularExpressionEngine]) {
NSRegularExpression *regex;
@@ -150,7 +150,7 @@ + (NSArray *)matchesInString:(NSString *)haystack withRegex:(NSString *)needle w
return [haystack componentsSeparatedByRegex:needle];
}
-#ifdef _RUNNING_MAC_OS_LION
+#ifdef _USES_MODERN_REGULAR_EXPRESSION
}
#endif
}
View
19 Classes/Preferences/Preferences.m
@@ -132,7 +132,6 @@ + (void)populateCommandIndex
[commandIndex setObject:@"87" forKey:IRCCI_LOCOPS];
[commandIndex setObject:@"88" forKey:IRCCI_NACHAT];
[commandIndex setObject:@"89" forKey:IRCCI_ADCHAT];
- [commandIndex setObject:@"90" forKey:IRCCI_RESETFILES];
[commandIndex setObject:@"91" forKey:IRCCI_LOAD_PLUGINS];
[commandIndex setObject:@"92" forKey:IRCCI_SME];
[commandIndex setObject:@"93" forKey:IRCCI_SMSG];
@@ -464,11 +463,6 @@ + (BOOL)countPublicMessagesInIconBadge
return [_NSUserDefaults() boolForKey:@"Preferences.General.dockbadge_countpub"];
}
-+ (BOOL)forceReplaceExtensions
-{
- return [_NSUserDefaults() boolForKey:@"Preferences.Plugins.force_replace"];
-}
-
+ (TabActionType)tabAction
{
return [_NSUserDefaults() integerForKey:@"Preferences.General.tab_action"];
@@ -982,11 +976,9 @@ + (void)initPreferences
[d setBool:YES forKey:@"eventNewtalkGrowl"];
[d setBool:YES forKey:@"eventAddressBookMatch"];
[d setBool:YES forKey:@"WebKitDeveloperExtras"];
- [d setBool:YES forKey:@"Preferences.General.log_transcript"];
[d setBool:YES forKey:@"Preferences.General.confirm_quit"];
[d setBool:YES forKey:@"Preferences.General.use_growl"];
[d setBool:YES forKey:@"Preferences.General.stop_growl_on_active"];
- [d setBool:YES forKey:@"Preferences.Plugins.force_replace"];
[d setBool:YES forKey:@"Preferences.General.display_servmotd"];
[d setBool:YES forKey:@"Preferences.General.dockbadges"];
[d setBool:YES forKey:@"Preferences.General.autoadd_scrollbackmark"];
@@ -996,6 +988,7 @@ + (void)initPreferences
[d setBool:YES forKey:@"Preferences.Keyword.current_nick"];
[d setBool:YES forKey:@"Preferences.Theme.predetermine_fonts"];
[d setBool:NO forKey:DeveloperEnvironmentToken];
+ [d setBool:NO forKey:@"Preferences.General.log_transcript"];
[d setBool:NO forKey:@"ForceServerListBadgeLocalization"];
[d setBool:NO forKey:@"Preferences.General.copyonselect"];
[d setBool:NO forKey:@"Preferences.General.strip_formatting"];
@@ -1083,7 +1076,15 @@ + (void)initPreferences
NSString *themePath = [[Preferences whereThemesPath] stringByAppendingPathComponent:themeName];
if ([_NSFileManager() fileExistsAtPath:themePath] == NO) {
- [_NSUserDefaults() setObject:DEFAULT_TEXTUAL_STYLE forKey:@"Preferences.Theme.name"];
+ themePath = [[Preferences whereThemesLocalPath] stringByAppendingPathComponent:themeName];
+
+ if ([_NSFileManager() fileExistsAtPath:themePath] == NO) {
+ [_NSUserDefaults() setObject:DEFAULT_TEXTUAL_STYLE forKey:@"Preferences.Theme.name"];
+ } else {
+ NSString *newName = [NSString stringWithFormat:@"resource:%@", themeName];
+
+ [_NSUserDefaults() setObject:newName forKey:@"Preferences.Theme.name"];
+ }
}
}
View
80 Classes/Preferences/ViewTheme.m
@@ -19,7 +19,7 @@ - (id)init
if ((self = [super init])) {
other = [OtherTheme new];
- core_js = [FileWithContent new];
+ core_js = [FileWithContent new];
core_js.filename = [[Preferences whereResourcePath] stringByAppendingPathComponent:@"/JavaScript/API/core.js"];
}
@@ -43,7 +43,7 @@ - (NSString *)name
- (void)setName:(NSString *)value
{
- if (NSDissimilarObjects(name, value)) {
+ if (name != value) {
[name drain];
name = [value retain];
}
@@ -54,8 +54,8 @@ - (void)setName:(NSString *)value
- (void)validateFilePathExistanceAndReload:(BOOL)reload
{
if (name) {
- NSString *kind = [ViewTheme extractThemeSource:[Preferences themeName]];
- NSString *filename = [ViewTheme extractThemeName:[Preferences themeName]];
+ NSString *kind = [ViewTheme extractThemeSource:[Preferences themeName]];
+ NSString *filename = [ViewTheme extractThemeName:[Preferences themeName]];
if (NSObjectIsNotEmpty(kind) && NSObjectIsNotEmpty(filename)) {
if ([kind isEqualToString:@"resource"]) {
@@ -68,9 +68,7 @@ - (void)validateFilePathExistanceAndReload:(BOOL)reload
if ([kind isEqualToString:@"resource"] == NO) {
path = [[Preferences whereThemesLocalPath] stringByAppendingPathComponent:filename];
- if (reload) {
- [self reload];
- }
+ if (reload) [self reload];
}
}
@@ -100,76 +98,18 @@ - (void)reload
[other reload];
}
-+ (void)copyItemsUsingRecursionFrom:(NSString *)location to:(NSString *)dest whileForcing:(BOOL)force_reset
++ (void)createDirectoryAtLocation:(NSString *)dest
{
- BOOL isDirectory = NO;
-
- NSDate *oneDayAgo = [NSDate dateWithTimeIntervalSinceNow:-86400];
-
if ([_NSFileManager() fileExistsAtPath:dest] == NO) {
[_NSFileManager() createDirectoryAtPath:dest withIntermediateDirectories:YES attributes:nil error:NULL];
}
-
- NSArray *resourceFiles = [_NSFileManager() contentsOfDirectoryAtPath:location error:NULL];
-
- for (NSString *file in resourceFiles) {
- NSString *sdest = [dest stringByAppendingPathComponent:file];
- NSString *source = [location stringByAppendingPathComponent:file];
-
- [_NSFileManager() fileExistsAtPath:source isDirectory:&isDirectory];
- [_NSFileManager() setAttributes:[NSDictionary dictionaryWithObjectsAndKeys:oneDayAgo, NSFileCreationDate, oneDayAgo, NSFileModificationDate, nil]
- ofItemAtPath:source
- error:NULL];
-
- BOOL resetAttrInfo = NO;
-
- if ([_NSFileManager() fileExistsAtPath:sdest]) {
- if (isDirectory) {
- resetAttrInfo = YES;
-
- [self copyItemsUsingRecursionFrom:source to:sdest whileForcing:force_reset];
- } else {
- NSDictionary *attributes = [_NSFileManager() attributesOfItemAtPath:sdest error:nil];
-
- if (attributes) {
- NSTimeInterval creationDate = [[attributes objectForKey:NSFileCreationDate] timeIntervalSince1970];
- NSTimeInterval modificationDate = [[attributes objectForKey:NSFileModificationDate] timeIntervalSince1970];
-
- if (creationDate == modificationDate || creationDate < 1 || force_reset) {
- [_NSFileManager() removeItemAtPath:sdest error:NULL];
-
- resetAttrInfo = [_NSFileManager() copyItemAtPath:source toPath:sdest error:NULL];
- }
- }
- }
- } else {
- if (isDirectory) {
- resetAttrInfo = YES;
-
- [self copyItemsUsingRecursionFrom:source to:sdest whileForcing:force_reset];
- } else {
- resetAttrInfo = [_NSFileManager() copyItemAtPath:source toPath:sdest error:NULL];
- }
- }
-
- if (resetAttrInfo || force_reset) {
- [_NSFileManager() setAttributes:[NSDictionary dictionaryWithObjectsAndKeys:oneDayAgo, NSFileCreationDate, oneDayAgo, NSFileModificationDate, nil]
- ofItemAtPath:sdest
- error:NULL];
- }
- }
}
+ (void)createUserDirectory:(BOOL)force_reset
{
- [self copyItemsUsingRecursionFrom:[Preferences whereScriptsLocalPath] to:[Preferences whereScriptsPath] whileForcing:force_reset];
-
- if ([Preferences forceReplaceExtensions]) {
- force_reset = YES;
- }
-
- [self copyItemsUsingRecursionFrom:[Preferences whereThemesLocalPath] to:[Preferences whereThemesPath] whileForcing:force_reset];
- [self copyItemsUsingRecursionFrom:[Preferences wherePluginsLocalPath] to:[Preferences wherePluginsPath] whileForcing:force_reset];
+ [self createDirectoryAtLocation:[Preferences whereScriptsPath]];
+ [self createDirectoryAtLocation:[Preferences whereThemesPath]];
+ [self createDirectoryAtLocation:[Preferences wherePluginsPath]];
}
+ (NSString *)buildResourceFilename:(NSString *)name
@@ -194,7 +134,7 @@ + (NSString *)extractThemeName:(NSString *)source
{
if ([source hasPrefix:@"user:"] == NO &&
[source hasPrefix:@"resource:"] == NO) return nil;
-
+
return [source safeSubstringAfterIndex:[source stringPosition:@":"]];
}
View
16 Classes/Views/Log/ImageURLParser.m
@@ -6,21 +6,25 @@ @implementation ImageURLParser
+ (NSString *)imageURLForURL:(NSString *)url
{
NSString *lowerUrl = [url lowercaseString];
+
+ NSURL *u = [NSURL URLWithString:[url encodeURIFragment]];
+
+ NSString *host = [u.host lowercaseString];
+ NSString *path = u.path;
if ([lowerUrl hasSuffix:@".jpg"]
|| [lowerUrl hasSuffix:@".jpeg"] || [lowerUrl hasSuffix:@".png"]
|| [lowerUrl hasSuffix:@".gif"] || [lowerUrl hasSuffix:@".tif"]
|| [lowerUrl hasSuffix:@".tiff"] || [lowerUrl hasSuffix:@".bmp"]) {
+ if ([host hasSuffix:@"wikipedia.org"]) {
+ return nil;
+ }
+
return url;
}
- NSURL *u = [NSURL URLWithString:[url encodeURIFragment]];
-
- NSString *host = [u.host lowercaseString];
- NSString *path = u.path;
-
- if ([host hasSuffix:@"twitpic.com"]) {
+ if ([host hasSuffix:@"twitpic.com"]) {
if (NSObjectIsNotEmpty(path)) {
NSString *s = [path safeSubstringFromIndex:1];
View
73 Classes/Views/Log/LogController.m
@@ -500,8 +500,10 @@ - (BOOL)print:(LogLine *)line withHTML:(BOOL)rawHTML
BOOL showInlineImage = NO;
BOOL isText = (type == LINE_TYPE_PRIVMSG || type == LINE_TYPE_NOTICE || type == LINE_TYPE_ACTION);
- BOOL drawLinks = BOOLReverseValue([[URLParser bannedURLRegexLineTypes] containsObject:lineTypeString]);
+ BOOL isNormalMsg = (type == LINE_TYPE_PRIVMSG || type == LINE_TYPE_ACTION);
+ BOOL drawLinks = BOOLReverseValue([[URLParser bannedURLRegexLineTypes] containsObject:lineTypeString]);
+
NSArray *urlRanges = [NSArray array];
if (rawHTML == NO) {
@@ -519,7 +521,7 @@ - (BOOL)print:(LogLine *)line withHTML:(BOOL)rawHTML
[inputDictionary setBool:drawLinks forKey:@"renderLinks"];
body = [LogRenderer renderBody:line.body
- controller:((type == LINE_TYPE_PRIVMSG || type == LINE_TYPE_ACTION) ? self : nil)
+ controller:((isNormalMsg) ? self : nil)
renderType:ASCII_TO_HTML
properties:inputDictionary
resultInfo:&outputDictionary];
@@ -559,35 +561,46 @@ - (BOOL)print:(LogLine *)line withHTML:(BOOL)rawHTML
[s appendFormat:@">%@</span> ", logEscape(line.nick)];
}
- if (isText && NSObjectIsNotEmpty(urlRanges) && [Preferences showInlineImages]) {
- NSString *imagePageUrl = nil;
- NSString *imageUrl = nil;
-
- for (NSValue *rangeValue in urlRanges) {
- NSString *url = [line.body safeSubstringWithRange:[rangeValue rangeValue]];
-
- imageUrl = [ImageURLParser imageURLForURL:url];
-
- if (imageUrl) {
- imagePageUrl = url;
-
- break;
- }
- }
-
- if (imageUrl) {
- showInlineImage = YES;
-
- [s appendFormat:@"<span class=\"message\" type=\"%@\">%@<br/>", lineTypeString, body];
- [s appendFormat:@"<a href=\"%@\"><img src=\"%@\" class=\"inlineimage\" style=\"max-width:%ipx;\"/></a></span>", imagePageUrl, imageUrl, [Preferences inlineImagesMaxWidth]];
- }
- }
-
- if (showInlineImage == NO) {
- [s appendFormat:@"<span class=\"message\" type=\"%@\">%@</span>", lineTypeString, body];
+ [s appendFormat:@"<span class=\"message\" type=\"%@\">%@", lineTypeString, body];
+
+ if (isNormalMsg && NSObjectIsNotEmpty(urlRanges) && [Preferences showInlineImages]) {
+ if (([channel isChannel] && channel.config.inlineImages == NO) || [channel isTalk]) {
+ NSString *imageUrl = nil;
+ NSString *lineBreak = nil;
+
+ NSMutableArray *postedUrls = [NSMutableArray array];
+
+ for (NSValue *rangeValue in urlRanges) {
+ NSString *url = [line.body safeSubstringWithRange:[rangeValue rangeValue]];
+
+ imageUrl = [ImageURLParser imageURLForURL:url];
+
+ if (imageUrl) {
+ if ([postedUrls containsObject:imageUrl]) {
+ continue;
+ } else {
+ [postedUrls safeAddObject:imageUrl];
+ }
+
+ showInlineImage = YES;
+
+ if (NSObjectIsNotEmpty(lineBreak)) {
+ lineBreak = @"<br />";
+ } else {
+ lineBreak = @"<br /><br /";
+ }
+
+ [s appendFormat:@"%@<a href=\"%@\"><img src=\"%@\" class=\"inlineimage\" style=\"max-width: %ipx;\"/></a></span>", lineBreak, url, imageUrl, [Preferences inlineImagesMaxWidth]];
+ }
+ }
+
+ if (showInlineImage) {
+ [s appendString:@"<br />"];
+ }
+ }
}
-
- [s appendFormat:@"</p>"];
+
+ [s appendFormat:@"</span></p>"];
NSMutableDictionary *attrs = [NSMutableDictionary dictionary];
View
174 Classes/Views/Log/LogRenderer.m
@@ -263,6 +263,7 @@ + (NSString *)renderBody:(NSString *)body
BOOL renderLinks = [inputDictionary boolForKey:@"renderLinks"];
BOOL exactWordMatching = ([Preferences keywordMatchingMethod] == KEYWORD_MATCH_EXACT);
+ BOOL regexWordMatching = ([Preferences keywordMatchingMethod] == KEYWORD_MATCH_REGEX);
NSArray *keywords = [inputDictionary arrayForKey:@"keywords"];
NSArray *excludeWords = [inputDictionary arrayForKey:@"excludeWords"];
@@ -456,78 +457,107 @@ + (NSString *)renderBody:(NSString *)body
}
}
- for (NSString *keyword in keywords) {
- start = 0;
-
- while (start < len) {
- NSRange r = [body rangeOfString:keyword
- options:NSCaseInsensitiveSearch
- range:NSMakeRange(start, (len - start))];
-
- if (r.location == NSNotFound) {
- break;
- }
-
- BOOL enabled = YES;
-
- for (NSValue *e in excludeRanges) {
- if (NSIntersectionRange(r, [e rangeValue]).length > 0) {
- enabled = NO;
-
- break;
- }
- }
-
- if (exactWordMatching) {
- if (enabled) {
- UniChar c = [body characterAtIndex:r.location];
-
- if ([UnicodeHelper isAlphabeticalCodePoint:c]) {
- NSInteger prev = (r.location - 1);
-
- if (0 <= prev && prev < len) {
- UniChar c = [body characterAtIndex:prev];
-
- if ([UnicodeHelper isAlphabeticalCodePoint:c]) {
- enabled = NO;
- }
- }
- }
- }
-
- if (enabled) {
- UniChar c = [body characterAtIndex:(NSMaxRange(r) - 1)];
-
- if ([UnicodeHelper isAlphabeticalCodePoint:c]) {
- NSInteger next = NSMaxRange(r);
-
- if (next < len) {
- UniChar c = [body characterAtIndex:next];
-
- if ([UnicodeHelper isAlphabeticalCodePoint:c]) {
- enabled = NO;
- }
- }
- }
- }
- }
-
- if (enabled) {
- if (isClear(attrBuf, URL_ATTR, r.location, r.length)) {
- setFlag(attrBuf, HIGHLIGHT_KEYWORD_ATTR, r.location, r.length);
-
- foundKeyword = YES;
-
- break;
- }
- }
-
- start = (NSMaxRange(r) + 1);
- }
-
- if (foundKeyword) break;
- }
-
+
+ if (regexWordMatching) {
+ for (NSString *keyword in keywords) {
+ NSRange matchRange = [TXRegularExpression string:body rangeOfRegex:keyword withoutCase:YES];
+
+ if (matchRange.location == NSNotFound) {
+ continue;
+ } else {
+ BOOL enabled = YES;
+
+ for (NSValue *e in excludeRanges) {
+ if (NSIntersectionRange(matchRange, [e rangeValue]).length > 0) {
+ enabled = NO;
+
+ break;
+ }
+ }
+
+ if (enabled) {
+ setFlag(attrBuf, HIGHLIGHT_KEYWORD_ATTR, matchRange.location, matchRange.length);
+
+ foundKeyword = YES;
+
+ break;
+ }
+ }
+ }
+ } else {
+ for (NSString *keyword in keywords) {
+ start = 0;
+
+ while (start < len) {
+ NSRange r = [body rangeOfString:keyword
+ options:NSCaseInsensitiveSearch
+ range:NSMakeRange(start, (len - start))];
+
+ if (r.location == NSNotFound) {
+ break;
+ }
+
+ BOOL enabled = YES;
+
+ for (NSValue *e in excludeRanges) {
+ if (NSIntersectionRange(r, [e rangeValue]).length > 0) {
+ enabled = NO;
+
+ break;
+ }
+ }
+
+ if (exactWordMatching) {
+ if (enabled) {
+ UniChar c = [body characterAtIndex:r.location];
+
+ if ([UnicodeHelper isAlphabeticalCodePoint:c]) {
+ NSInteger prev = (r.location - 1);
+
+ if (0 <= prev && prev < len) {
+ UniChar c = [body characterAtIndex:prev];
+
+ if ([UnicodeHelper isAlphabeticalCodePoint:c]) {
+ enabled = NO;
+ }
+ }
+ }
+ }
+
+ if (enabled) {
+ UniChar c = [body characterAtIndex:(NSMaxRange(r) - 1)];
+
+ if ([UnicodeHelper isAlphabeticalCodePoint:c]) {
+ NSInteger next = NSMaxRange(r);
+
+ if (next < len) {
+ UniChar c = [body characterAtIndex:next];
+
+ if ([UnicodeHelper isAlphabeticalCodePoint:c]) {
+ enabled = NO;
+ }
+ }
+ }
+ }
+ }
+
+ if (enabled) {
+ if (isClear(attrBuf, URL_ATTR, r.location, r.length)) {
+ setFlag(attrBuf, HIGHLIGHT_KEYWORD_ATTR, r.location, r.length);
+
+ foundKeyword = YES;
+
+ break;
+ }
+ }
+
+ start = (NSMaxRange(r) + 1);
+ }
+
+ if (foundKeyword) break;
+ }
+ }
+
[resultInfo setBool:foundKeyword forKey:@"wordMatchFound"];
/* IP Address and Channel Name Detection */
View
4 Classes/Views/Log/LogScriptEventSink.m
@@ -85,6 +85,10 @@ - (BOOL)shouldStopDoubleClick:(id)e
return res;
}
+- (void)hideInlineImage:(NSString *)url parent:(NSString *)lineNumber
+{
+}
+
- (void)setUrl:(NSString *)s
{
[policy setUrl:[s gtm_stringByUnescapingFromHTML]];
View
9 English.lproj/BasicLanguage.strings
@@ -23,11 +23,6 @@
"CHANNEL_APPLICATION_TITLE_USERS" = " (%i Users)";
"CHANNEL_APPLICATION_TITLE_MODES" = " (%@)";
-"RESOURCES_FILE_RESET_WARNING_TITLE" = "Reset Resources";
-"RESOURCES_FILE_RESET_WARNING_MESSAGE" = "Execution of this command will erase the contents of the folder \"%@\" which contains cached files used by the Textual IRC Client. Are you sure you wish to continue with this action? There is no undo.\n\nIMPORTANT: This folder does contain any custom addons such as scripts, plugins, and styles you may have created. Please backup before continuing.";
-"RESOURCES_FILE_RESET_QUITTING_TITLE" = "Action Completed";
-"RESOURCES_FILE_RESET_QUITTING_MESSAGE" = "Textual will now quit to apply changes. Relaunch when ready for use.";
-
"SOUND_IS_NOT_MUTED" = "Sound is not muted.";
"SOUND_HAS_BEEN_MUTED" = "Sound has been muted.";
"SOUND_IS_ALREADY_MUTED" = "Sound is already muted.";
@@ -64,6 +59,10 @@
"WANT_QUIT_TITLE" = "Do you want to quit Textual?";
"WANT_QUIT_MESSAGE" = "Quitting will disconnect you from all IRC networks until you restart Textual.";
+"SELF_BAN_DETECTED_MESSAGE" = "Textual has prevented you from banning yourself from %@.";
+
+"PLUGIN_COMMAND_CLASH_ERROR_MESSAGE" = "The command %@ is shared by both a script and plugin. Sending to server because of inability to determine priority.";
+
"WANT_SERVER_DELETE_TITLE" = "Do you want to delete the selection?";
"WANT_SERVER_DELETE_MESSAGE" = "There is no undo and all data related to this server will be erased.";
View
1,189 English.lproj/ChannelSheet.xib
@@ -2,35 +2,39 @@
<archive type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="7.10">
<data>
<int key="IBDocument.SystemTarget">1050</int>
- <string key="IBDocument.SystemVersion">11A459e</string>
- <string key="IBDocument.InterfaceBuilderVersion">1565</string>
- <string key="IBDocument.AppKitVersion">1121.2</string>
- <string key="IBDocument.HIToolboxVersion">557.00</string>
+ <string key="IBDocument.SystemVersion">11A511</string>
+ <string key="IBDocument.InterfaceBuilderVersion">1617</string>
+ <string key="IBDocument.AppKitVersion">1138</string>
+ <string key="IBDocument.HIToolboxVersion">566.00</string>
<object class="NSMutableDictionary" key="IBDocument.PluginVersions">
<string key="NS.key.0">com.apple.InterfaceBuilder.CocoaPlugin</string>
- <string key="NS.object.0">1565</string>
+ <string key="NS.object.0">1617</string>
</object>
<object class="NSArray" key="IBDocument.IntegratedClassDependencies">
<bool key="EncodedWithXMLCoder">YES</bool>
- <string>NSTextField</string>
- <string>NSView</string>
- <string>NSWindowTemplate</string>
- <string>NSCustomObject</string>
- <string>NSTextFieldCell</string>
+ <string>NSUserDefaultsController</string>
<string>NSSegmentedControl</string>
- <string>NSSegmentedCell</string>
- <string>NSCustomView</string>
- <string>NSButtonCell</string>
<string>NSButton</string>
+ <string>NSTextFieldCell</string>
+ <string>NSButtonCell</string>
<string>NSBox</string>
+ <string>NSCustomView</string>
+ <string>NSSegmentedCell</string>
+ <string>NSView</string>
+ <string>NSWindowTemplate</string>
+ <string>NSTextField</string>
+ <string>NSCustomObject</string>
</object>
<object class="NSArray" key="IBDocument.PluginDependencies">
<bool key="EncodedWithXMLCoder">YES</bool>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
</object>
<object class="NSMutableDictionary" key="IBDocument.Metadata">
- <string key="NS.key.0">PluginDependencyRecalculationVersion</string>
- <integer value="1" key="NS.object.0"/>
+ <bool key="EncodedWithXMLCoder">YES</bool>
+ <object class="NSArray" key="dict.sortedKeys" id="0">
+ <bool key="EncodedWithXMLCoder">YES</bool>
+ </object>
+ <reference key="dict.values" ref="0"/>
</object>
<object class="NSMutableArray" key="IBDocument.RootObjects" id="285530636">
<bool key="EncodedWithXMLCoder">YES</bool>
@@ -63,8 +67,10 @@
<object class="NSSegmentedControl" id="161170383">
<reference key="NSNextResponder" ref="884577729"/>
<int key="NSvFlags">268</int>
- <string key="NSFrame">{{83, 387}, {159, 20}}</string>
+ <string key="NSFrame">{{47, 387}, {230, 20}}</string>
<reference key="NSSuperview" ref="884577729"/>
+ <reference key="NSWindow"/>
+ <reference key="NSNextKeyView"/>
<bool key="NSEnabled">YES</bool>
<object class="NSSegmentedCell" key="NSCell" id="277046012">
<int key="NSCellFlags">67239424</int>
@@ -78,7 +84,7 @@
<object class="NSMutableArray" key="NSSegmentImages">
<bool key="EncodedWithXMLCoder">YES</bool>
<object class="NSSegmentItem">
- <double key="NSSegmentItemWidth">70</double>
+ <double key="NSSegmentItemWidth">71</double>
<string key="NSSegmentItemLabel">General</string>
<int key="NSSegmentItemImageScaling">0</int>
</object>
@@ -88,6 +94,10 @@
<bool key="NSSegmentItemSelected">YES</bool>
<int key="NSSegmentItemImageScaling">0</int>
</object>
+ <object class="NSSegmentItem">
+ <string key="NSSegmentItemLabel">Defaults</string>
+ <int key="NSSegmentItemImageScaling">0</int>
+ </object>
</object>
<int key="NSSelectedSegment">1</int>
<int key="NSSegmentStyle">3</int>
@@ -98,12 +108,14 @@
<int key="NSvFlags">268</int>
<string key="NSFrameSize">{325, 388}</string>
<reference key="NSSuperview" ref="884577729"/>
+ <reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="161170383"/>
<string key="NSClassName">NSView</string>
</object>
</object>
<string key="NSFrameSize">{325, 426}</string>
<reference key="NSSuperview"/>
+ <reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="1047415136"/>
</object>
<string key="NSScreenRect">{{0, 0}, {2560, 1418}}</string>
@@ -119,7 +131,7 @@
<object class="NSTextField" id="65154215">
<reference key="NSNextResponder" ref="698554361"/>
<int key="NSvFlags">256</int>
- <string key="NSFrame">{{23, 399}, {65, 17}}</string>
+ <string key="NSFrame">{{23, 283}, {65, 17}}</string>
<reference key="NSSuperview" ref="698554361"/>
<reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="332369330"/>
@@ -157,7 +169,7 @@
<object class="NSTextField" id="25978085">
<reference key="NSNextResponder" ref="698554361"/>
<int key="NSvFlags">256</int>
- <string key="NSFrame">{{17, 371}, {71, 17}}</string>
+ <string key="NSFrame">{{17, 255}, {71, 17}}</string>
<reference key="NSSuperview" ref="698554361"/>
<reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="345000287"/>
@@ -172,49 +184,13 @@
<reference key="NSTextColor" ref="574710092"/>
</object>
</object>
- <object class="NSTextField" id="845157355">
- <reference key="NSNextResponder" ref="698554361"/>
- <int key="NSvFlags">256</int>
- <string key="NSFrame">{{33, 144}, {53, 17}}</string>
- <reference key="NSSuperview" ref="698554361"/>
- <reference key="NSWindow"/>
- <reference key="NSNextKeyView" ref="176006758"/>
- <bool key="NSEnabled">YES</bool>
- <object class="NSTextFieldCell" key="NSCell" id="1022121758">
- <int key="NSCellFlags">67239424</int>
- <int key="NSCellFlags2">71303168</int>
- <string key="NSContents">Modes:</string>
- <reference key="NSSupport" ref="876066128"/>
- <reference key="NSControlView" ref="845157355"/>
- <reference key="NSBackgroundColor" ref="360518997"/>
- <reference key="NSTextColor" ref="574710092"/>
- </object>
- </object>
- <object class="NSTextField" id="371752663">
- <reference key="NSNextResponder" ref="698554361"/>
- <int key="NSvFlags">256</int>
- <string key="NSFrame">{{6, 220}, {80, 17}}</string>
- <reference key="NSSuperview" ref="698554361"/>
- <reference key="NSWindow"/>
- <reference key="NSNextKeyView" ref="810841718"/>
- <bool key="NSEnabled">YES</bool>
- <object class="NSTextFieldCell" key="NSCell" id="553611302">
- <int key="NSCellFlags">67239424</int>
- <int key="NSCellFlags2">71303168</int>
- <string key="NSContents">Topic:</string>
- <reference key="NSSupport" ref="876066128"/>
- <reference key="NSControlView" ref="371752663"/>
- <reference key="NSBackgroundColor" ref="360518997"/>
- <reference key="NSTextColor" ref="574710092"/>
- </object>
- </object>
<object class="NSTextField" id="427214428">
<reference key="NSNextResponder" ref="698554361"/>
<int key="NSvFlags">256</int>
- <string key="NSFrame">{{93, 366}, {164, 22}}</string>
+ <string key="NSFrame">{{93, 250}, {164, 22}}</string>
<reference key="NSSuperview" ref="698554361"/>
<reference key="NSWindow"/>
- <reference key="NSNextKeyView" ref="998579738"/>
+ <reference key="NSNextKeyView" ref="20273255"/>
<bool key="NSEnabled">YES</bool>
<object class="NSTextFieldCell" key="NSCell" id="632796608">
<int key="NSCellFlags">-1804468671</int>
@@ -240,48 +216,10 @@
</object>
</object>
</object>
- <object class="NSTextField" id="176006758">
- <reference key="NSNextResponder" ref="698554361"/>
- <int key="NSvFlags">256</int>
- <string key="NSFrame">{{91, 142}, {211, 22}}</string>
- <reference key="NSSuperview" ref="698554361"/>
- <reference key="NSWindow"/>
- <reference key="NSNextKeyView" ref="970982311"/>
- <bool key="NSEnabled">YES</bool>
- <object class="NSTextFieldCell" key="NSCell" id="181859639">
- <int key="NSCellFlags">-1804468671</int>
- <int key="NSCellFlags2">272630784</int>
- <string key="NSContents"/>
- <reference key="NSSupport" ref="876066128"/>
- <reference key="NSControlView" ref="176006758"/>
- <bool key="NSDrawsBackground">YES</bool>
- <reference key="NSBackgroundColor" ref="254505662"/>
- <reference key="NSTextColor" ref="962927987"/>
- </object>
- </object>
- <object class="NSTextField" id="810841718">
- <reference key="NSNextResponder" ref="698554361"/>
- <int key="NSvFlags">256</int>
- <string key="NSFrame">{{91, 174}, {211, 66}}</string>
- <reference key="NSSuperview" ref="698554361"/>
- <reference key="NSWindow"/>
- <reference key="NSNextKeyView" ref="845157355"/>
- <bool key="NSEnabled">YES</bool>
- <object class="NSTextFieldCell" key="NSCell" id="1070131665">
- <int key="NSCellFlags">-1805517311</int>
- <int key="NSCellFlags2">4194304</int>
- <string key="NSContents"/>
- <reference key="NSSupport" ref="876066128"/>
- <reference key="NSControlView" ref="810841718"/>
- <bool key="NSDrawsBackground">YES</bool>
- <reference key="NSBackgroundColor" ref="254505662"/>
- <reference key="NSTextColor" ref="962927987"/>
- </object>
- </object>
<object class="NSButton" id="998579738">
<reference key="NSNextResponder" ref="698554361"/>
<int key="NSvFlags">256</int>
- <string key="NSFrame">{{91, 332}, {195, 18}}</string>
+ <string key="NSFrame">{{24, 189}, {195, 18}}</string>
<reference key="NSSuperview" ref="698554361"/>
<reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="14450102"/>
@@ -356,7 +294,7 @@
<object class="NSTextField" id="332369330">
<reference key="NSNextResponder" ref="698554361"/>
<int key="NSvFlags">256</int>
- <string key="NSFrame">{{93, 396}, {209, 22}}</string>
+ <string key="NSFrame">{{93, 280}, {209, 22}}</string>
<reference key="NSSuperview" ref="698554361"/>
<reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="25978085"/>
@@ -372,66 +310,10 @@
<reference key="NSTextColor" ref="962927987"/>
</object>
</object>
- <object class="NSBox" id="600164771">
- <reference key="NSNextResponder" ref="698554361"/>
- <int key="NSvFlags">256</int>
- <string key="NSFrame">{{14, 257}, {298, 5}}</string>
- <string key="NSBounds">{{6.2857200000000004, 0}, {298, 5}}</string>
- <reference key="NSSuperview" ref="698554361"/>
- <reference key="NSWindow"/>
- <reference key="NSNextKeyView" ref="371752663"/>
- <string key="NSOffsets">{0, 0}</string>
- <object class="NSTextFieldCell" key="NSTitleCell">
- <int key="NSCellFlags">67239424</int>
- <int key="NSCellFlags2">0</int>
- <string key="NSContents">Box</string>
- <reference key="NSSupport" ref="876066128"/>
- <reference key="NSBackgroundColor" ref="254505662"/>
- <object class="NSColor" key="NSTextColor">
- <int key="NSColorSpace">3</int>
- <bytes key="NSWhite">MCAwLjgwMDAwMDAxMTkAA</bytes>
- </object>
- </object>
- <int key="NSBorderType">3</int>
- <int key="NSBoxType">2</int>
- <int key="NSTitlePosition">0</int>
- <bool key="NSTransparent">NO</bool>
- </object>
- <object class="NSTextField" id="970982311">
- <reference key="NSNextResponder" ref="698554361"/>
- <int key="NSvFlags">256</int>
- <string key="NSFrame">{{88, 75}, {217, 56}}</string>
- <reference key="NSSuperview" ref="698554361"/>
- <reference key="NSWindow"/>
- <reference key="NSNextKeyView" ref="116706423"/>
- <bool key="NSEnabled">YES</bool>
- <object class="NSTextFieldCell" key="NSCell" id="300430276">
- <int key="NSCellFlags">69336577</int>
- <int key="NSCellFlags2">272629760</int>
- <string key="NSContents">If you jon a channel that is empty, then the above topic and mode settings will be used to establish the basic structure of the newly joined channel.</string>
- <object class="NSFont" key="NSSupport" id="26">
- <string key="NSName">LucidaGrande</string>
- <double key="NSSize">11</double>
- <int key="NSfFlags">3100</int>
- </object>
- <reference key="NSControlView" ref="970982311"/>
- <reference key="NSBackgroundColor" ref="360518997"/>
- <object class="NSColor" key="NSTextColor" id="438995388">
- <int key="NSColorSpace">6</int>
- <string key="NSCatalogName">System</string>
- <string key="NSColorName">controlShadowColor</string>
- <object class="NSColor" key="NSColor" id="910154649">
- <int key="NSColorSpace">3</int>
- <bytes key="NSWhite">MC4zMzMzMzMzMzMzAA</bytes>
- </object>
- </object>
- </object>
- </object>
<object class="NSBox" id="116706423">
<reference key="NSNextResponder" ref="698554361"/>
<int key="NSvFlags">256</int>
- <string key="NSFrame">{{13, 57}, {301, 5}}</string>
- <string key="NSBounds">{{14.7142, 0}, {301, 5}}</string>
+ <string key="NSFrame">{{12, 58}, {301, 5}}</string>
<reference key="NSSuperview" ref="698554361"/>
<reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="675878913"/>
@@ -455,7 +337,7 @@
<object class="NSButton" id="14450102">
<reference key="NSNextResponder" ref="698554361"/>
<int key="NSvFlags">268</int>
- <string key="NSFrame">{{91, 305}, {181, 18}}</string>
+ <string key="NSFrame">{{24, 162}, {181, 18}}</string>
<reference key="NSSuperview" ref="698554361"/>
<reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="678517690"/>
@@ -479,7 +361,7 @@
<object class="NSTextField" id="345000287">
<reference key="NSNextResponder" ref="698554361"/>
<int key="NSvFlags">268</int>
- <string key="NSFrame">{{39, 361}, {49, 11}}</string>
+ <string key="NSFrame">{{39, 245}, {49, 11}}</string>
<reference key="NSSuperview" ref="698554361"/>
<reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="427214428"/>
@@ -499,17 +381,20 @@
<int key="NSColorSpace">6</int>
<string key="NSCatalogName">System</string>
<string key="NSColorName">disabledControlTextColor</string>
- <reference key="NSColor" ref="910154649"/>
+ <object class="NSColor" key="NSColor" id="910154649">
+ <int key="NSColorSpace">3</int>
+ <bytes key="NSWhite">MC4zMzMzMzMzMzMzAA</bytes>
+ </object>
</object>
</object>
</object>
<object class="NSButton" id="678517690">
<reference key="NSNextResponder" ref="698554361"/>
<int key="NSvFlags">268</int>
- <string key="NSFrame">{{91, 278}, {168, 18}}</string>
+ <string key="NSFrame">{{24, 135}, {168, 18}}</string>
<reference key="NSSuperview" ref="698554361"/>
<reference key="NSWindow"/>
- <reference key="NSNextKeyView" ref="600164771"/>
+ <reference key="NSNextKeyView" ref="161564123"/>
<bool key="NSEnabled">YES</bool>
<object class="NSButtonCell" key="NSCell" id="996146670">
<int key="NSCellFlags">67239424</int>
@@ -527,23 +412,276 @@
<int key="NSPeriodicInterval">25</int>
</object>
</object>
+ <object class="NSButton" id="161564123">
+ <reference key="NSNextResponder" ref="698554361"/>
+ <int key="NSvFlags">268</int>
+ <string key="NSFrame">{{24, 108}, {168, 18}}</string>
+ <reference key="NSSuperview" ref="698554361"/>
+ <reference key="NSWindow"/>
+ <reference key="NSNextKeyView" ref="1068350763"/>
+ <bool key="NSEnabled">YES</bool>
+ <object class="NSButtonCell" key="NSCell" id="759289226">
+ <int key="NSCellFlags">67239424</int>
+ <int key="NSCellFlags2">0</int>
+ <string key="NSContents">Disable inline images</string>
+ <reference key="NSSupport" ref="876066128"/>
+ <reference key="NSControlView" ref="161564123"/>
+ <int key="NSButtonFlags">1211912703</int>
+ <int key="NSButtonFlags2">2</int>
+ <reference key="NSNormalImage" ref="151677773"/>
+ <reference key="NSAlternateImage" ref="264120294"/>
+ <string key="NSAlternateContents"/>
+ <string key="NSKeyEquivalent"/>
+ <int key="NSPeriodicDelay">200</int>
+ <int key="NSPeriodicInterval">25</int>
+ </object>
+ </object>
+ <object class="NSButton" id="1068350763">
+ <reference key="NSNextResponder" ref="698554361"/>
+ <int key="NSvFlags">268</int>
+ <string key="NSFrame">{{24, 81}, {209, 18}}</string>
+ <reference key="NSSuperview" ref="698554361"/>
+ <reference key="NSWindow"/>
+ <reference key="NSNextKeyView" ref="116706423"/>
+ <bool key="NSEnabled">YES</bool>
+ <object class="NSButtonCell" key="NSCell" id="200132775">
+ <int key="NSCellFlags">67239424</int>
+ <int key="NSCellFlags2">0</int>
+ <string key="NSContents">Disable join/part/quit activity</string>
+ <reference key="NSSupport" ref="876066128"/>
+ <reference key="NSControlView" ref="1068350763"/>
+ <int key="NSButtonFlags">1211912703</int>
+ <int key="NSButtonFlags2">2</int>
+ <reference key="NSNormalImage" ref="151677773"/>
+ <reference key="NSAlternateImage" ref="264120294"/>
+ <string key="NSAlternateContents"/>
+ <string key="NSKeyEquivalent"/>
+ <int key="NSPeriodicDelay">200</int>
+ <int key="NSPeriodicInterval">25</int>
+ </object>
+ </object>
+ <object class="NSBox" id="20273255">
+ <reference key="NSNextResponder" ref="698554361"/>
+ <int key="NSvFlags">256</int>
+ <string key="NSFrame">{{12, 225}, {301, 5}}</string>
+ <reference key="NSSuperview" ref="698554361"/>
+ <reference key="NSWindow"/>
+ <reference key="NSNextKeyView" ref="998579738"/>
+ <string key="NSOffsets">{0, 0}</string>
+ <object class="NSTextFieldCell" key="NSTitleCell">
+ <int key="NSCellFlags">67239424</int>
+ <int key="NSCellFlags2">0</int>
+ <string key="NSContents">Box</string>
+ <reference key="NSSupport" ref="876066128"/>
+ <reference key="NSBackgroundColor" ref="254505662"/>
+ <object class="NSColor" key="NSTextColor">
+ <int key="NSColorSpace">3</int>
+ <bytes key="NSWhite">MCAwLjgwMDAwMDAxMTkAA</bytes>
+ </object>
+ </object>
+ <int key="NSBorderType">3</int>
+ <int key="NSBoxType">2</int>
+ <int key="NSTitlePosition">0</int>
+ <bool key="NSTransparent">NO</bool>
+ </object>
</object>
- <string key="NSFrameSize">{325, 447}</string>
+ <string key="NSFrameSize">{325, 331}</string>
<reference key="NSSuperview"/>
<reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="65154215"/>
</object>
- <object class="NSView" id="346484559">
+ <object class="NSView" id="387988488">
<reference key="NSNextResponder"/>
<int key="NSvFlags">256</int>
<object class="NSMutableArray" key="NSSubviews">
<bool key="EncodedWithXMLCoder">YES</bool>
+ <object class="NSTextField" id="11866765">
+ <reference key="NSNextResponder" ref="387988488"/>
+ <int key="NSvFlags">256</int>
+ <string key="NSFrame">{{34, 145}, {53, 17}}</string>
+ <reference key="NSSuperview" ref="387988488"/>
+ <reference key="NSWindow"/>
+ <reference key="NSNextKeyView" ref="236523889"/>
+ <bool key="NSEnabled">YES</bool>
+ <object class="NSTextFieldCell" key="NSCell" id="1067232516">
+ <int key="NSCellFlags">67239424</int>
+ <int key="NSCellFlags2">71303168</int>
+ <string key="NSContents">Modes:</string>
+ <reference key="NSSupport" ref="876066128"/>
+ <reference key="NSControlView" ref="11866765"/>
+ <reference key="NSBackgroundColor" ref="360518997"/>
+ <reference key="NSTextColor" ref="574710092"/>
+ </object>
+ </object>
+ <object class="NSTextField" id="856641808">
+ <reference key="NSNextResponder" ref="387988488"/>
+ <int key="NSvFlags">256</int>
+ <string key="NSFrame">{{7, 221}, {80, 17}}</string>
+ <reference key="NSSuperview" ref="387988488"/>
+ <reference key="NSWindow"/>
+ <reference key="NSNextKeyView" ref="122496466"/>
+ <bool key="NSEnabled">YES</bool>
+ <object class="NSTextFieldCell" key="NSCell" id="472133684">
+ <int key="NSCellFlags">67239424</int>
+ <int key="NSCellFlags2">71303168</int>
+ <string key="NSContents">Topic:</string>
+ <reference key="NSSupport" ref="876066128"/>
+ <reference key="NSControlView" ref="856641808"/>
+ <reference key="NSBackgroundColor" ref="360518997"/>
+ <reference key="NSTextColor" ref="574710092"/>
+ </object>
+ </object>
+ <object class="NSTextField" id="236523889">
+ <reference key="NSNextResponder" ref="387988488"/>
+ <int key="NSvFlags">256</int>
+ <string key="NSFrame">{{92, 143}, {211, 22}}</string>
+ <reference key="NSSuperview" ref="387988488"/>
+ <reference key="NSWindow"/>
+ <reference key="NSNextKeyView" ref="54489938"/>
+ <bool key="NSEnabled">YES</bool>
+ <object class="NSTextFieldCell" key="NSCell" id="966327875">
+ <int key="NSCellFlags">-1804468671</int>
+ <int key="NSCellFlags2">272630784</int>
+ <string key="NSContents"/>
+ <reference key="NSSupport" ref="876066128"/>
+ <reference key="NSControlView" ref="236523889"/>
+ <bool key="NSDrawsBackground">YES</bool>
+ <reference key="NSBackgroundColor" ref="254505662"/>
+ <reference key="NSTextColor" ref="962927987"/>
+ </object>
+ </object>
+ <object class="NSTextField" id="122496466">
+ <reference key="NSNextResponder" ref="387988488"/>
+ <int key="NSvFlags">256</int>
+ <string key="NSFrame">{{92, 175}, {211, 66}}</string>
+ <reference key="NSSuperview" ref="387988488"/>
+ <reference key="NSWindow"/>
+ <reference key="NSNextKeyView" ref="11866765"/>
+ <bool key="NSEnabled">YES</bool>
+ <object class="NSTextFieldCell" key="NSCell" id="940556092">
+ <int key="NSCellFlags">-1805517311</int>
+ <int key="NSCellFlags2">4194304</int>
+ <string key="NSContents"/>
+ <reference key="NSSupport" ref="876066128"/>
+ <reference key="NSControlView" ref="122496466"/>
+ <bool key="NSDrawsBackground">YES</bool>
+ <reference key="NSBackgroundColor" ref="254505662"/>
+ <reference key="NSTextColor" ref="962927987"/>
+ </object>
+ </object>
+ <object class="NSButton" id="58344492">
+ <reference key="NSNextResponder" ref="387988488"/>
+ <int key="NSvFlags">256</int>
+ <string key="NSFrame">{{227, 12}, {82, 32}}</string>
+ <reference key="NSSuperview" ref="387988488"/>
+ <reference key="NSWindow"/>
+ <reference key="NSNextKeyView"/>
+ <bool key="NSEnabled">YES</bool>
+ <object class="NSButtonCell" key="NSCell" id="1042878633">
+ <int key="NSCellFlags">67239424</int>
+ <int key="NSCellFlags2">134217728</int>
+ <string key="NSContents">OK</string>
+ <reference key="NSSupport" ref="876066128"/>
+ <reference key="NSControlView" ref="58344492"/>
+ <int key="NSButtonFlags">-2038284033</int>
+ <int key="NSButtonFlags2">1</int>
+ <reference key="NSAlternateImage" ref="876066128"/>
+ <string key="NSAlternateContents"/>
+ <string type="base64-UTF8" key="NSKeyEquivalent">DQ</string>
+ <int key="NSPeriodicDelay">200</int>
+ <int key="NSPeriodicInterval">25</int>
+ </object>
+ </object>
+ <object class="NSButton" id="420546697">
+ <reference key="NSNextResponder" ref="387988488"/>
+ <int key="NSvFlags">256</int>
+ <string key="NSFrame">{{148, 12}, {82, 32}}</string>
+ <reference key="NSSuperview" ref="387988488"/>
+ <reference key="NSWindow"/>
+ <reference key="NSNextKeyView" ref="58344492"/>
+ <bool key="NSEnabled">YES</bool>
+ <object class="NSButtonCell" key="NSCell" id="612920800">
+ <int key="NSCellFlags">67239424</int>
+ <int key="NSCellFlags2">134217728</int>
+ <string key="NSContents">Cancel</string>
+ <reference key="NSSupport" ref="876066128"/>
+ <reference key="NSControlView" ref="420546697"/>
+ <int key="NSButtonFlags">-2038284033</int>
+ <int key="NSButtonFlags2">1</int>
+ <reference key="NSAlternateImage" ref="876066128"/>
+ <string key="NSAlternateContents"/>
+ <string key="NSKeyEquivalent"/>
+ <int key="NSPeriodicDelay">200</int>
+ <int key="NSPeriodicInterval">25</int>
+ </object>
+ </object>
+ <object class="NSTextField" id="54489938">
+ <reference key="NSNextResponder" ref="387988488"/>
+ <int key="NSvFlags">256</int>
+ <string key="NSFrame">{{89, 76}, {217, 56}}</string>
+ <reference key="NSSuperview" ref="387988488"/>
+ <reference key="NSWindow"/>
+ <reference key="NSNextKeyView" ref="400492040"/>
+ <bool key="NSEnabled">YES</bool>
+ <object class="NSTextFieldCell" key="NSCell" id="109953429">
+ <int key="NSCellFlags">69336577</int>
+ <int key="NSCellFlags2">272629760</int>
+ <string key="NSContents">If you jon a channel that is empty, then the above topic and mode settings will be used to establish the basic structure of the newly joined channel.</string>
+ <object class="NSFont" key="NSSupport" id="26">
+ <string key="NSName">LucidaGrande</string>
+ <double key="NSSize">11</double>
+ <int key="NSfFlags">3100</int>
+ </object>
+ <reference key="NSControlView" ref="54489938"/>
+ <reference key="NSBackgroundColor" ref="360518997"/>
+ <object class="NSColor" key="NSTextColor" id="438995388">
+ <int key="NSColorSpace">6</int>
+ <string key="NSCatalogName">System</string>
+ <string key="NSColorName">controlShadowColor</string>
+ <reference key="NSColor" ref="910154649"/>
+ </object>
+ </object>
+ </object>
+ <object class="NSBox" id="400492040">
+ <reference key="NSNextResponder" ref="387988488"/>
+ <int key="NSvFlags">256</int>
+ <string key="NSFrame">{{14, 58}, {301, 5}}</string>
+ <reference key="NSSuperview" ref="387988488"/>
+ <reference key="NSWindow"/>
+ <reference key="NSNextKeyView" ref="420546697"/>
+ <string key="NSOffsets">{0, 0}</string>
+ <object class="NSTextFieldCell" key="NSTitleCell">
+ <int key="NSCellFlags">67239424</int>
+ <int key="NSCellFlags2">0</int>
+ <string key="NSContents">Box</string>
+ <reference key="NSSupport" ref="876066128"/>
+ <reference key="NSBackgroundColor" ref="254505662"/>
+ <object class="NSColor" key="NSTextColor">
+ <int key="NSColorSpace">3</int>
+ <bytes key="NSWhite">MCAwLjgwMDAwMDAxMTkAA</bytes>
+ </object>
+ </object>
+ <int key="NSBorderType">3</int>
+ <int key="NSBoxType">2</int>
+ <int key="NSTitlePosition">0</int>
+ <bool key="NSTransparent">NO</bool>
+ </object>
+ </object>
+ <string key="NSFrameSize">{325, 270}</string>
+ <reference key="NSSuperview"/>
+ <reference key="NSWindow"/>
+ <reference key="NSNextKeyView" ref="856641808"/>
+ </object>
+ <object class="NSView" id="346484559">
+ <nil key="NSNextResponder"/>
+ <int key="NSvFlags">256</int>
+ <object class="NSMutableArray" key="NSSubviews">
+ <bool key="EncodedWithXMLCoder">YES</bool>
<object class="NSTextField" id="298693433">
<reference key="NSNextResponder" ref="346484559"/>
<int key="NSvFlags">256</int>
<string key="NSFrame">{{17, 150}, {80, 17}}</string>
<reference key="NSSuperview" ref="346484559"/>
- <reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="1054322750"/>
<bool key="NSEnabled">YES</bool>
<object class="NSTextFieldCell" key="NSCell" id="728399246">
@@ -561,8 +699,6 @@
<int key="NSvFlags">256</int>
<string key="NSFrame">{{229, 12}, {82, 32}}</string>
<reference key="NSSuperview" ref="346484559"/>
- <reference key="NSWindow"/>
- <reference key="NSNextKeyView"/>
<bool key="NSEnabled">YES</bool>
<object class="NSButtonCell" key="NSCell" id="1071517475">
<int key="NSCellFlags">67239424</int>
@@ -584,7 +720,6 @@
<int key="NSvFlags">256</int>
<string key="NSFrame">{{147, 12}, {82, 32}}</string>
<reference key="NSSuperview" ref="346484559"/>
- <reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="945002892"/>
<bool key="NSEnabled">YES</bool>
<object class="NSButtonCell" key="NSCell" id="857140177">
@@ -607,7 +742,6 @@
<int key="NSvFlags">256</int>
<string key="NSFrame">{{102, 147}, {203, 22}}</string>
<reference key="NSSuperview" ref="346484559"/>
- <reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="692461126"/>
<bool key="NSEnabled">YES</bool>
<object class="NSTextFieldCell" key="NSCell" id="932293639">