A cross-platform UI framework for .NET
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

20 lines
513 B

using System;
using System.Text;
using Avalonia.Platform;
using MonoMac.AppKit;
using MonoMac.WebKit;
namespace IntegrationTestApp.Embedding;
internal class MacOSTextBoxFactory : INativeControlFactory
{
public IPlatformHandle CreateControl(IPlatformHandle parent, Func<IPlatformHandle> createDefault)
{
MacHelper.EnsureInitialized();
var textView = new NSTextView();
textView.TextStorage.Append(new("Native text box"));
return new MacOSViewHandle(textView);
}
}