in my App I have an Editor inside ScrollView. If the text ist larger than Editor height, I want to be able to scroll the Editor without clicking inside the Editor. I have a CustomRenderer for Editor and ScollView, but which Settings are possible ?
Thanks.
If you want to let Editor scroll to bottom automatically, you can use the following code in your EditorRenderer
protected override void OnElementChanged(ElementChangedEventArgs<Editor> e)
{
base.OnElementChanged(e);
if(Control!=null)
{
Control.LayoutManager.AllowsNonContiguousLayout = false;
Control.ScrollRangeToVisible(new NSRange(Control.Text.Length-1,1));
}
}
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.