MonobjcMonobjc Documented Class Library
TokenFieldCompletionsForSubstringIndexOfTokenIndexOfSelectedItem Method (tokenField, substring, tokenIndex, selectedIndex)
NamespacesMonobjc.AppKitINSTokenFieldDelegateTokenFieldCompletionsForSubstringIndexOfTokenIndexOfSelectedItem(NSTokenField, NSString, NSInteger, NSInteger%)

Allows the delegate to provide an array of appropriate completions for the contents of the receiver.

Original signature is '- (NSArray *)tokenField:(NSTokenField *)tokenField completionsForSubstring:(NSString *)substring indexOfToken:(NSInteger)tokenIndex indexOfSelectedItem:(NSInteger *)selectedIndex'

Available in Mac OS X v10.4 and later.

Declaration Syntax
C#Visual BasicVisual C++
NSArray TokenFieldCompletionsForSubstringIndexOfTokenIndexOfSelectedItem(
	NSTokenField tokenField,
	NSString substring,
	NSInteger tokenIndex,
	out NSInteger selectedIndex
)
Function TokenFieldCompletionsForSubstringIndexOfTokenIndexOfSelectedItem ( _
	tokenField As NSTokenField, _
	substring As NSString, _
	tokenIndex As NSInteger, _
	<OutAttribute> ByRef selectedIndex As NSInteger _
) As NSArray
NSArray^ TokenFieldCompletionsForSubstringIndexOfTokenIndexOfSelectedItem(
	NSTokenField^ tokenField, 
	NSString^ substring, 
	NSInteger tokenIndex, 
	[OutAttribute] NSInteger% selectedIndex
)
Parameters
tokenField (NSTokenField)
The token field where editing is occurring.
substring (NSString)
The partial string that is to be completed.
tokenIndex (NSInteger)
The index of the token being edited.
selectedIndex (NSInteger%)
Optionally, you can return by-reference an index into the returned array that specifies which of the completions should be initially selected. If none are to be selected, return by reference -1.
Return Value
An array of strings that are possible completions.
Version Information
  • Available in Monobjc Bridge: 10.6 (For Mac OS X 10.6 and later), 10.5 (For Mac OS X 10.5 and later)

Assembly: Monobjc.AppKit (Module: Monobjc.AppKit)