title: How do I make sure one control is prioritized over another in a StackLayout in Xamarin Forms?
body: <pre><code>&lt;StackLayout Orientation="Horizontal"&gt;
    &lt;SearchBar Placeholder="Search"
               FontSize="Medium"
               HeightRequest="50"/&gt;
    &lt;ImageButton Command="{Binding FilterCommand}" Source="filter.png" MinimumWidthRequest="27" Margin="0,13,0,13" BackgroundColor="Transparent"&gt;&lt;/ImageButton&gt;
  &lt;/StackLayout&gt;
  </code></pre>
  
  <p>This is my XAML code to display a searchbar on the left, and an image button on the right. I want the image button to take up as much space as it needs to display properly, but I don't know how to do that. This is in Xamarin Forms, so cross platform, for iOS and Android.</p>
  
  <p>Thanks!</p>