I am trying to implement autocomplete with an NSTextField where the user will type in some string and suggestions will be fetched from an API to be displayed under the text field. Optionally display a progress indicator inside the text field. So far I have designed the UI in Xcode IB and hooked the event to get the text change event.
public class UserTextFieldDelegate: NSTextFieldDelegate
{
public NSTextField Username { get; set; }
public UserTextFieldDelegate()
{
}
public UserTextFieldDelegate(NSTextField username)
{
this.Username = username;
}
public override void Changed(NSNotification notification)
{
Console.WriteLine(Username.StringValue);
}
}
Just like on google search
How do I achieve this in Xamarin.Mac?