Any way to place an html text box in the SfImageViewer? I have text containing HTML which I would like to display on-screen in the image viewer. Using the default text box obviously I end up displaying the html itself. I'm hoping you have a trick for it, or else I'd like this to be considered a feat
I haven't been able to get something like this to work:
var webView = new WebView() { WidthRequest = 100, HeightRequest = 100 };
webView.Source = new HtmlWebViewSource() { Html = @"<span style=""color:blue"";font-size:16px;>TEST</span>" };
imageEditor.AddCustomView(webView, new CustomViewSettings() { Bounds = new Rectangle(25, 25, 50, 50), Angle = 0 });
|
<imageeditor:SfImageEditor Source="{Binding Image}" x:Name="imageEditor" ImageLoaded="imageEditor_ImageLoaded" /> |
|
private void imageEditor_ImageLoaded(object sender, ImageLoadedEventArgs args)
{
var webView = new WebView() { WidthRequest = 100, HeightRequest = 100 };
webView.Source = new HtmlWebViewSource() { Html = @"<span style=""color:blue"";font-size:16px;>TEST</span>" };
imageEditor.AddCustomView(webView, new CustomViewSettings() { Bounds = new Rectangle(25, 25, 50, 50), Angle = 0 });
} |
Ah, I was testing in iOS at the time so that explains why I could see it. Thank you for looking at this.