Mercurial > projects > dwt-mac
diff dwt/internal/cocoa/NSSpellChecker.d @ 1:8b48be5454ce
The internal cocoa classes compile now
author | Jacob Carlborg <doob@me.com> <jacob.carlborg@gmail.com> |
---|---|
date | Tue, 19 Aug 2008 17:35:17 +0200 |
parents | 380af2bdd8e5 |
children | f565d3a95c0a |
line wrap: on
line diff
--- a/dwt/internal/cocoa/NSSpellChecker.d Sat Aug 09 17:00:02 2008 +0200 +++ b/dwt/internal/cocoa/NSSpellChecker.d Tue Aug 19 17:35:17 2008 +0200 @@ -39,28 +39,28 @@ public NSView accessoryView () { - objc.id result = OS.objc_msgSend(this.id, OS.sel_accessoryView); + objc.id result = OS.objc_msgSend(this.id_, OS.sel_accessoryView); return result !is null ? new NSView(result) : null; } public NSArray availableLanguages () { - objc.id result = OS.objc_msgSend(this.id, OS.sel_availableLanguages); + objc.id result = OS.objc_msgSend(this.id_, OS.sel_availableLanguages); return result !is null ? new NSArray(result) : null; } public NSRange checkGrammarOfString (NSString stringToCheck, NSInteger startingOffset, NSString language, bool wrapFlag, NSInteger tag, /*NSArray** */objc.id** details) { NSRange result; - OS.objc_msgSend_stret(result, this.id, OS.sel_checkGrammarOfString_1startingAt_1language_1wrap_1inSpellDocumentWithTag_1details_1, - stringToCheck !is null ? stringToCheck.id : null, startingOffset, language !is null ? language.id : null, wrapFlag, tag, details); + OS.objc_msgSend_stret(&result, this.id_, OS.sel_checkGrammarOfString_1startingAt_1language_1wrap_1inSpellDocumentWithTag_1details_1, + stringToCheck !is null ? stringToCheck.id_ : null, startingOffset, language !is null ? language.id_ : null, wrapFlag, tag, details); return result; } public NSRange checkSpellingOfString_startingAt_ (NSString stringToCheck, NSInteger startingOffset) { NSRange result; - OS.objc_msgSend_stret(result, this.id, OS.sel_checkSpellingOfString_1startingAt_1, stringToCheck !is null ? stringToCheck.id : null, + OS.objc_msgSend_stret(&result, this.id_, OS.sel_checkSpellingOfString_1startingAt_1, stringToCheck !is null ? stringToCheck.id_ : null, startingOffset); return result; } @@ -69,85 +69,85 @@ NSString language, bool wrapFlag, NSInteger tag, NSInteger* wordCount) { NSRange result; - OS.objc_msgSend_stret(result, this.id, OS.sel_checkSpellingOfString_1startingAt_1language_1wrap_1inSpellDocumentWithTag_1wordCount_1, - stringToCheck !is null ? stringToCheck.id : null, startingOffset, language !is null ? language.id : null, wrapFlag, tag, wordCount); + OS.objc_msgSend_stret(&result, this.id_, OS.sel_checkSpellingOfString_1startingAt_1language_1wrap_1inSpellDocumentWithTag_1wordCount_1, + stringToCheck !is null ? stringToCheck.id_ : null, startingOffset, language !is null ? language.id_ : null, wrapFlag, tag, wordCount); return result; } public void closeSpellDocumentWithTag (NSInteger tag) { - OS.objc_msgSend(this.id, OS.sel_closeSpellDocumentWithTag_1, tag); + OS.objc_msgSend(this.id_, OS.sel_closeSpellDocumentWithTag_1, tag); } public NSArray completionsForPartialWordRange (NSRange range, NSString string, NSString language, NSInteger tag) { - objc.id result = OS.objc_msgSend(this.id, OS.sel_completionsForPartialWordRange_1inString_1language_1inSpellDocumentWithTag_1, range, - string !is null ? string.id : null, language !is null ? language.id : null, tag); + objc.id result = OS.objc_msgSend(this.id_, OS.sel_completionsForPartialWordRange_1inString_1language_1inSpellDocumentWithTag_1, range, + string !is null ? string.id_ : null, language !is null ? language.id_ : null, tag); return result !is null ? new NSArray(result) : null; } public NSInteger countWordsInString (NSString stringToCount, NSString language) { - return cast(NSInteger) OS.objc_msgSend(this.id, OS.sel_countWordsInString_1language_1, stringToCount !is null ? stringToCount.id : null, - language !is null ? language.id : null); + return cast(NSInteger) OS.objc_msgSend(this.id_, OS.sel_countWordsInString_1language_1, stringToCount !is null ? stringToCount.id_ : null, + language !is null ? language.id_ : null); } public void forgetWord (NSString word) { - OS.objc_msgSend(this.id, OS.sel_forgetWord_1, word !is null ? word.id : null); + OS.objc_msgSend(this.id_, OS.sel_forgetWord_1, word !is null ? word.id_ : null); } public NSArray guessesForWord (NSString word) { - objc.id result = OS.objc_msgSend(this.id, OS.sel_guessesForWord_1, word !is null ? word.id : null); + objc.id result = OS.objc_msgSend(this.id_, OS.sel_guessesForWord_1, word !is null ? word.id_ : null); return result !is null ? new NSArray(result) : null; } public bool hasLearnedWord (NSString word) { - return OS.objc_msgSend(this.id, OS.sel_hasLearnedWord_1, word !is null ? word.id : null) !is null; + return OS.objc_msgSend(this.id_, OS.sel_hasLearnedWord_1, word !is null ? word.id_ : null) !is null; } public void ignoreWord (NSString wordToIgnore, NSInteger tag) { - OS.objc_msgSend(this.id, OS.sel_ignoreWord_1inSpellDocumentWithTag_1, wordToIgnore !is null ? wordToIgnore.id : null, tag); + OS.objc_msgSend(this.id_, OS.sel_ignoreWord_1inSpellDocumentWithTag_1, wordToIgnore !is null ? wordToIgnore.id_ : null, tag); } public NSArray ignoredWordsInSpellDocumentWithTag (NSInteger tag) { - objc.id result = OS.objc_msgSend(this.id, OS.sel_ignoredWordsInSpellDocumentWithTag_1, tag); + objc.id result = OS.objc_msgSend(this.id_, OS.sel_ignoredWordsInSpellDocumentWithTag_1, tag); return result !is null ? new NSArray(result) : null; } public NSString language () { - objc.id result = OS.objc_msgSend(this.id, OS.sel_language); + objc.id result = OS.objc_msgSend(this.id_, OS.sel_language); return result !is null ? new NSString(result) : null; } public void learnWord (NSString word) { - OS.objc_msgSend(this.id, OS.sel_learnWord_1, word !is null ? word.id : null); + OS.objc_msgSend(this.id_, OS.sel_learnWord_1, word !is null ? word.id_ : null); } public void setAccessoryView (NSView aView) { - OS.objc_msgSend(this.id, OS.sel_setAccessoryView_1, aView !is null ? aView.id : null); + OS.objc_msgSend(this.id_, OS.sel_setAccessoryView_1, aView !is null ? aView.id_ : null); } public void setIgnoredWords (NSArray words, NSInteger tag) { - OS.objc_msgSend(this.id, OS.sel_setIgnoredWords_1inSpellDocumentWithTag_1, words !is null ? words.id : null, tag); + OS.objc_msgSend(this.id_, OS.sel_setIgnoredWords_1inSpellDocumentWithTag_1, words !is null ? words.id_ : null, tag); } public bool setLanguage (NSString language) { - return OS.objc_msgSend(this.id, OS.sel_setLanguage_1, language !is null ? language.id : null) !is null; + return OS.objc_msgSend(this.id_, OS.sel_setLanguage_1, language !is null ? language.id_ : null) !is null; } public void setWordFieldStringValue (NSString aString) { - OS.objc_msgSend(this.id, OS.sel_setWordFieldStringValue_1, aString !is null ? aString.id : null); + OS.objc_msgSend(this.id_, OS.sel_setWordFieldStringValue_1, aString !is null ? aString.id_ : null); } public static NSSpellChecker sharedSpellChecker () @@ -163,7 +163,7 @@ public NSPanel spellingPanel () { - objc.id result = OS.objc_msgSend(this.id, OS.sel_spellingPanel); + objc.id result = OS.objc_msgSend(this.id_, OS.sel_spellingPanel); return result !is null ? new NSPanel(result) : null; } @@ -174,18 +174,18 @@ public void unlearnWord (NSString word) { - OS.objc_msgSend(this.id, OS.sel_unlearnWord_1, word !is null ? word.id : null); + OS.objc_msgSend(this.id_, OS.sel_unlearnWord_1, word !is null ? word.id_ : null); } public void updateSpellingPanelWithGrammarString (NSString string, NSDictionary detail) { - OS.objc_msgSend(this.id, OS.sel_updateSpellingPanelWithGrammarString_1detail_1, string !is null ? string.id : null, - detail !is null ? detail.id : null); + OS.objc_msgSend(this.id_, OS.sel_updateSpellingPanelWithGrammarString_1detail_1, string !is null ? string.id_ : null, + detail !is null ? detail.id_ : null); } public void updateSpellingPanelWithMisspelledWord (NSString word) { - OS.objc_msgSend(this.id, OS.sel_updateSpellingPanelWithMisspelledWord_1, word !is null ? word.id : null); + OS.objc_msgSend(this.id_, OS.sel_updateSpellingPanelWithMisspelledWord_1, word !is null ? word.id_ : null); } }