Skip to content

[iOS] Shell.TitleView doesn't show accurate if not using just a string bindingΒ #11309

Closed

Description

@AndreasReitberger

Description

When setting the Shell.TitleView in XAML, the content isn't shown up accurate on iOS 16.1.

<Shell.TitleView>
        <Grid
            ColumnDefinitions="*,Auto"
            BackgroundColor="Red"
            >
            <Label
                Text="Headline"
                />
            <Button
                Grid.Column="1"
                Text="Button"
                />
        </Grid>
    </Shell.TitleView>

image

The Label isn't shown at all, the Button is only displayed half and setting a BackgroundColor has no effect (just for seeing the bounds of the Grid.
I just updated my repro for another issue with this issue.

Android works fine with the same project.

image

Steps to Reproduce

  1. Create a new MAUI app
  2. Add the snippet above to the MainPage
  3. Run it on iOS

Link to public reproduction project repository

https://github.com/AndreasReitberger/ReproScrollingIssueModal

Version with bug

7.0 (current)

Last version that worked well

Unknown/Other

Affected platforms

iOS

Affected platform versions

iOS 16.1

Did you find any workaround?

No response

Relevant log output

No response

Activity

  1. added
    t/bug
    on Nov 12, 2022
  2. added this to the Backlog milestone on Nov 14, 2022
  3. AndreasReitberger commented on Nov 23, 2022

    @AndreasReitberger
    Author

    @jsuarezruiz
    Is there any workaround for that? This also is keeping me from the app release. Or at least an ETA when this will be addressed?
    Thank you!

  4. FM1973 commented on Dec 6, 2022

    @FM1973

    I got the same problem...

  5. MaksimAdamenko commented on Dec 6, 2022

    @MaksimAdamenko

    I got the same problem.

  6. DDHSchmidt commented on Dec 15, 2022

    @DDHSchmidt

    @jsuarezruiz Is there any workaround for that? This also is keeping me from the app release. Or at least an ETA when this will be addressed? Thank you!

    You could try
    <Grid Margin="{OnPlatform Default='0', iOS='0,0,0,-50'}>
    That should fix the offset of the TitleView.
    Downside is: You can't limit this to iOS 16 only. If your user has iOS 15, this will probably look screwed.

  7. FM1973 commented on Dec 19, 2022

    @FM1973

    Happens on IOS 16, 15 and lower is fine.

  8. FM1973 commented on Dec 21, 2022

    @FM1973

    Hey there.
    The following workaround works form me:
    xamarin/Xamarin.Forms#15512
    In mauiprogram I then configure the handler like this:

    .ConfigureMauiHandlers((handlers) => { #if IOS16_0_OR_GREATER handlers.AddHandler(typeof(Shell), typeof(CustomShellRenderer)); #endif });

  9. harrykontopoulos commented on Jan 2, 2023

    @harrykontopoulos

    It happens on iOS 15.5 and 16 for me, unless I use the custom handler workaround suggestion above.

  10. added a commit that references this issue on Feb 18, 2023
    445f9a9
  11. added a commit that references this issue on Feb 21, 2023
    aa746eb
  12. added
    fixed-in-8.0.0-preview.1.7762
    on Feb 22, 2023
  13. modified the milestones: Backlog, 8.0-preview1 on Feb 22, 2023
  14. ghost locked as resolved and limited conversation to collaborators on Mar 24, 2023
  15. added a commit that references this issue on Apr 3, 2023
    c77486b
  16. added a commit that references this issue on Apr 4, 2023
    572087a
  17. added
    fixed-in-7.0.92
    on Jul 11, 2023
  18. added
    area-controls-shell
    on Oct 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area-controls-shellfixed-in-7.0.100fixed-in-7.0.101fixed-in-7.0.92fixed-in-8.0.0-preview.1.7762platform/iost/bugversion/ios-16

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions