Why my StackLaout doesn't display 5% from left edge?

LorenoArlaLorenoArla USMember ✭✭

Hello,
I wanted to display a StackLayout that would be 5% from top, left and right and would take about 1/3 of screen height.
Here's my XAML:
`<?xml version="1.0" encoding="UTF-8"?>

<AbsoluteLayout BackgroundColor="Yellow" >
    <StackLayout AbsoluteLayout.LayoutBounds="0.05, 0.05, 0.9, 0.25" AbsoluteLayout.LayoutFlags="All" BackgroundColor="Aqua">

    </StackLayout>
</AbsoluteLayout>

`

I get this result:

What's wrong with my layout? I can't think of a solution.

Best Answer

  • LorenoArlaLorenoArla US ✭✭
    edited August 2017 Accepted Answer

    I found solution:
    AbsoluteLayout.LayoutBounds="0.5, 0.05, 0.9, 0.25"

Answers

  • LorenoArlaLorenoArla USMember ✭✭
    edited August 2017 Accepted Answer

    I found solution:
    AbsoluteLayout.LayoutBounds="0.5, 0.05, 0.9, 0.25"

Sign In or Register to comment.