diff options
-rw-r--r-- | Source/SPBundleCommandTextView.m | 4 | ||||
-rw-r--r-- | Source/SPQueryController.m | 2 | ||||
-rw-r--r-- | Source/SPTextView.m | 3 |
3 files changed, 8 insertions, 1 deletions
diff --git a/Source/SPBundleCommandTextView.m b/Source/SPBundleCommandTextView.m index b5436ca5..4ca63451 100644 --- a/Source/SPBundleCommandTextView.m +++ b/Source/SPBundleCommandTextView.m @@ -62,6 +62,10 @@ [commandScrollView setHasHorizontalRuler:NO]; [commandScrollView setHasVerticalRuler:YES]; [commandScrollView setRulersVisible:YES]; + + // disable typo stuff in 10.8+ SDK + [self setAutomaticDashSubstitutionEnabled:NO]; + [self setAutomaticQuoteSubstitutionEnabled:NO]; // Re-define tab stops for a better editing [self setTabStops]; diff --git a/Source/SPQueryController.m b/Source/SPQueryController.m index 01cb50e1..718a5ff3 100644 --- a/Source/SPQueryController.m +++ b/Source/SPQueryController.m @@ -338,7 +338,7 @@ static SPQueryController *sharedQueryController = nil; #pragma mark Other /** - * Called whenver the test within the search field changes. + * Called whenever the text within the search field changes. */ - (void)controlTextDidChange:(NSNotification *)notification { diff --git a/Source/SPTextView.m b/Source/SPTextView.m index 8edbb6d0..abe89c5b 100644 --- a/Source/SPTextView.m +++ b/Source/SPTextView.m @@ -202,6 +202,9 @@ static inline NSPoint SPPointOnLine(NSPoint a, NSPoint b, CGFloat t) { return NS [self _setTextSelectionColor:[NSUnarchiver unarchiveObjectWithData:[prefs dataForKey:SPCustomQueryEditorSelectionColor]] onBackgroundColor:backgroundColor]; + [self setAutomaticDashSubstitutionEnabled:NO]; // prevents -- from becoming —, the em dash. + [self setAutomaticQuoteSubstitutionEnabled:NO]; // prevents ' and " from becoming ‘, ’ and “, ” respectively. + // Register observers for the when editor background colors preference changes [prefs addObserver:self forKeyPath:SPCustomQueryEditorSelectionColor options:NSKeyValueObservingOptionNew context:NULL]; [prefs addObserver:self forKeyPath:SPCustomQueryEditorCaretColor options:NSKeyValueObservingOptionNew context:NULL]; |