SuavePirate / Xamarin.Forms.Controls.FloatingActionButton

A custom view to create a FloatingActionButton for both Android and iOS as part of Material Design
MIT License
120 stars 38 forks source link

Absolute Layout example #24

Closed jon-peel closed 6 years ago

jon-peel commented 6 years ago

I have been trying to get this to show properly using an absolute layout (so I can have the FAB on the bottom right, about 16 from the edge, over any other content on the screen).

I am not coming right. I have been checking other examples of AbsoluteLayout, but nothing is working.

Could anyone create an example of this FAB in the bottom right of the layout?

SuavePirate commented 6 years ago

To get it in the bottom right, I wrap everything in a Grid then using HorizontalOptions and VerticalOptions with Margin - so something like this:

<ContentPage>
    <Grid>
        <ListView .../>
        <fab:FloatingActionButton HorizontalOptions="End" VerticalOptions="End" Margin="0,0,16,16" ... />
    </Grid>
</ContentPage>
jon-peel commented 6 years ago

Thank you so much, that works 100%

On Fri, Aug 3, 2018 at 4:16 PM Alex Dunn notifications@github.com wrote:

To get it in the bottom right, I wrap everything in a Grid then using HorizontalOptions and VerticalOptions with Margin - so something like this:

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/SuavePirate/Xamarin.Forms.Controls.FloatingActionButton/issues/24#issuecomment-410263566, or mute the thread https://github.com/notifications/unsubscribe-auth/AON4uH7h9qyYIXz2-eI5VVXLYku2hlH1ks5uNFstgaJpZM4Vtikh .