title: How to make ItemMargin of CarouselControl adaptive in UWP?
body: <p>I am working on a UWP app where my page has 2 columns. In the first column, I have used a Carousel Control to display different images. I would like to set the ItemMargin of the Carousel Control such that the second image just peeks enough to be seen by the user and I would like it to be adaptive such that the next image peeks in the same location of the column each time. Any ideas on how to go on about this?</p>
  <p>Edit: Added a sample xaml code</p>
  <pre><code>&lt;Page xmlns=&quot;http://schemas.microsoft.com/winfx/2006/xaml/presentation&quot;
    xmlns:x=&quot;http://schemas.microsoft.com/winfx/2006/xaml&quot;
    xmlns:controls=&quot;using:Microsoft.Toolkit.Uwp.UI.Controls&quot;
    xmlns:d=&quot;http://schemas.microsoft.com/expression/blend/2008&quot;
    xmlns:mc=&quot;http://schemas.openxmlformats.org/markup-compatibility/2006&quot;
    mc:Ignorable=&quot;d&quot;&gt;
  
   &lt;Grid&gt;
     &lt;Border Margin=&quot;0&quot;&gt;
      &lt;controls:Carousel x:Name=&quot;CarouselControl&quot;
                InvertPositive=&quot;True&quot;
                ItemDepth=&quot;300&quot;
                ItemMargin=&quot;336&quot;
                ItemRotationX=&quot;-180&quot;
                ItemRotationY=&quot;-180&quot;
                ItemRotationZ =&quot;-180&quot;
                Orientation=&quot;Horizontal&quot;
                SelectedIndex=&quot;0&quot;&gt;
      &lt;controls:Carousel.EasingFunction&gt;
        &lt;CubicEase EasingMode=&quot;EaseOut&quot; /&gt;
      &lt;/controls:Carousel.EasingFunction&gt;
      &lt;controls:Carousel.ItemTemplate&gt;
        &lt;DataTemplate&gt;
          &lt;Image Width=&quot;200&quot;
                Height=&quot;200&quot;
                VerticalAlignment=&quot;Bottom&quot;
                Source=&quot;{Binding Thumbnail}&quot;
                Stretch=&quot;Uniform&quot; /&gt;
        &lt;/DataTemplate&gt;
      &lt;/controls:Carousel.ItemTemplate&gt;
    &lt;/controls:Carousel&gt;
  &lt;/Border&gt;
  </code></pre>
    
  
  <p>As you can see, I have fixed the value of ItemMargin to 336. However, when I resize this app, the position of the peeking image doesn't remain the same. I would like to have something where the position of the peeking image remains the same even when the app window is resized.</p>