diff --git a/Xamarin.Forms.Controls.Issues/Xamarin.Forms.Controls.Issues.Shared/Issue4143.xaml b/Xamarin.Forms.Controls.Issues/Xamarin.Forms.Controls.Issues.Shared/Issue4143.xaml index 3f36124e5e3..04d8e6fe6fc 100644 --- a/Xamarin.Forms.Controls.Issues/Xamarin.Forms.Controls.Issues.Shared/Issue4143.xaml +++ b/Xamarin.Forms.Controls.Issues/Xamarin.Forms.Controls.Issues.Shared/Issue4143.xaml @@ -43,12 +43,39 @@ + + + + + + + + + + + + + + + @@ -95,11 +122,18 @@ - - + + + + + + - diff --git a/Xamarin.Forms.Controls.Issues/Xamarin.Forms.Controls.Issues.Shared/Issue4143.xaml.cs b/Xamarin.Forms.Controls.Issues/Xamarin.Forms.Controls.Issues.Shared/Issue4143.xaml.cs index 864aaa44504..950d35eea0a 100644 --- a/Xamarin.Forms.Controls.Issues/Xamarin.Forms.Controls.Issues.Shared/Issue4143.xaml.cs +++ b/Xamarin.Forms.Controls.Issues/Xamarin.Forms.Controls.Issues.Shared/Issue4143.xaml.cs @@ -44,6 +44,22 @@ void OnLink5Tapped(object sender, EventArgs e) { SetRandomBackgroundColor(Link5); } + void OnLink6Tapped(object sender, EventArgs e) + { + SetRandomBackgroundColor(Link6); + } + void OnLink7Tapped(object sender, EventArgs e) + { + SetRandomBackgroundColor(Link7); + } + void OnLink8Tapped(object sender, EventArgs e) + { + SetRandomBackgroundColor(Link8); + } + void OnLink9Tapped(object sender, EventArgs e) + { + SetRandomBackgroundColor(Link9); + } #endif void SetRandomBackgroundColor(Span span) diff --git a/Xamarin.Forms.Platform.Android/Extensions/TextViewExtensions.cs b/Xamarin.Forms.Platform.Android/Extensions/TextViewExtensions.cs index 800bf0c52c6..31991004499 100644 --- a/Xamarin.Forms.Platform.Android/Extensions/TextViewExtensions.cs +++ b/Xamarin.Forms.Platform.Android/Extensions/TextViewExtensions.cs @@ -130,7 +130,7 @@ public static void RecalculateSpanPositions(this TextView textView, Label elemen var lineHeight = bounds.Height(); var lineStartOffset = layout.GetLineStart(curLine); - var lineVisibleEndOffset = layout.GetLineVisibleEnd(curLine); + var lineVisibleEndOffset = layout.GetLineVisibleEnd(curLine) - 1; var startOffset = (curLine == spanStartLine) ? spanStartOffset : lineStartOffset; var spanStartX = (int)layout.GetPrimaryHorizontal(startOffset);