[WinRT/UWP] Adjust margin for centered Slider #604

Merged
merged 1 commit into from Dec 5, 2016

Conversation

Projects
None yet
5 participants
@pauldipietro
Member

pauldipietro commented Dec 4, 2016

Description of Change

The Slider control has an odd behavior when centered via VerticalOptions and wasn't looking truly centered, like this:

nofix

Making adjustments to ArrangeOverride at an initial glance didn't seem to do enough, even when setting VerticalAlignment (although this was needed for cases where a MinimumHeightRequest was set, since as it exists it wasn't close to centering at all) so there was always a few pixels' difference as shown above. There is a slight difference in the default template between 8.1 and UWP templates so a slight adjustment using the Margin has been added depending on the platform so the result looks like this on each:

wp81-slider

uwp-slider

Bugs Fixed

https://bugzilla.xamarin.com/show_bug.cgi?id=29110

API Changes

None

Behavioral Changes

Sliders were not centering as mentioned when a minimum height was specified so in those cases the result might be more obvious.

PR Checklist

  • Has tests (if omitted, state reason in description)
  • Rebased on top of master at time of PR
  • Changes adhere to coding standard
  • Consolidate commits as makes sense

@rmarinho rmarinho merged commit 3692786 into master Dec 5, 2016

4 of 6 checks passed

iOS10-UITests-C8 Finished TeamCity Build Xamarin.Forms :: Debug :: Cycle 8 :: UI Tests :: OSX Test Cloud Package - Run iOS Unified iOS10 : Tests failed: 98…
Details
iOS8-UITests-C8 Finished TeamCity Build Xamarin.Forms :: Debug :: Cycle 8 :: UI Tests :: OSX Test Cloud Package - Run iOS Unified IOS8 : Tests failed: 1, …
Details
Android-UITests-C8 Finished TeamCity Build Xamarin.Forms :: Debug :: Cycle 8 :: UI Tests :: OSX Test Cloud Package - Run Android 6.0.1 : Tests passed: 349, i…
Details
OSX-Debug-C8 Finished TeamCity Build Xamarin.Forms :: Debug :: Cycle 8 :: OSX Debug : Running
Details
Windows-Debug-C8 Finished TeamCity Build Xamarin.Forms :: Debug :: Cycle 8 :: Windows Debug : Tests passed: 3615, ignored: 10
Details
iOS9-UITests-C8 Finished TeamCity Build Xamarin.Forms :: Debug :: Cycle 8 :: UI Tests :: OSX Test Cloud Package - Run iOS Unified iOS9 : Tests passed: 346…
Details

@rmarinho rmarinho deleted the fix-bugzilla29110 branch Jun 22, 2017

@samhouts samhouts added this to the 2.3.4 milestone Jun 27, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment