Description
First of all I'm setting On<Microsoft.Maui.Controls.PlatformConfiguration.Android>().UseWindowSoftInputModeAdjust(WindowSoftInputModeAdjust.Unspecified); because I want control it myself. Despite if WindowSoftInputModeAdjust is set to Pan or Unspecified there are some issues.
SoftInput inside Default
<ContentPage xmlns="http://schemas.microsoft.com/dotnet/2021/maui" xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml" SafeAreaEdges="Default" x:Class="SafeAreaEdgesBug.MainPage" BackgroundColor="Green"> <Grid RowDefinitions="80, auto, *, Auto" SafeAreaEdges="SoftInput" BackgroundColor="Red"> <Label Grid.Row="0" Text="Hello World!" HorizontalTextAlignment="Center" VerticalOptions="Start" /> <Entry Grid.Row="2" VerticalOptions="Start" HorizontalOptions="Fill" HeightRequest="56" /> <Button Grid.Row="3" Text="Button"/> </Grid> </ContentPage>
1.A WindowSoftInputModeAdjust set to Pan
Bottom button is not visible
example1a.mp4
1.B WindowSoftInputModeAdjust set to Unspecified
Bottom button is partially visible
example1b.mp4
Default inside None
<?xml version="1.0" encoding="utf-8"?> <ContentPage xmlns="http://schemas.microsoft.com/dotnet/2021/maui" xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml" SafeAreaEdges="None" x:Class="SafeAreaEdgesBug.MainPage" BackgroundColor="Green"> <Grid RowDefinitions="80, auto, *, Auto" SafeAreaEdges="Default" BackgroundColor="Red"> <Label Grid.Row="0" Text="Hello World!" HorizontalTextAlignment="Center" VerticalOptions="Start" /> <Entry Grid.Row="2" VerticalOptions="Start" HorizontalOptions="Fill" HeightRequest="56" /> <Button Grid.Row="3" Text="Button"/> </Grid> </ContentPage>
2.A WindowSoftInputModeAdjust set to Pan
Correct behavior
example2a.mp4
2.B WindowSoftInputModeAdjust set to Unspecified
Bottom inset for Grid is set to 0 while keyboard is show which restults in jumping of the button.
example2b.mp4
Steps to Reproduce
See attached project.
(https://github.com/user-attachments/files/23780187/SafeAreaEdgesBug.zip )
Link to public reproduction project repository
No response
Version with bug
10.0.11
Is this a regression from previous behavior?
Not sure, did not test other versions
Last version that worked well
Unknown/Other
Affected platforms
Android
Affected platform versions
No response
Did you find any workaround?
No response
Relevant log output
Description
First of all I'm setting
On<Microsoft.Maui.Controls.PlatformConfiguration.Android>().UseWindowSoftInputModeAdjust(WindowSoftInputModeAdjust.Unspecified);because I want control it myself. Despite if WindowSoftInputModeAdjust is set to Pan or Unspecified there are some issues.<ContentPage xmlns="http://schemas.microsoft.com/dotnet/2021/maui" xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml" SafeAreaEdges="Default" x:Class="SafeAreaEdgesBug.MainPage" BackgroundColor="Green"> <Grid RowDefinitions="80, auto, *, Auto" SafeAreaEdges="SoftInput" BackgroundColor="Red"> <Label Grid.Row="0" Text="Hello World!" HorizontalTextAlignment="Center" VerticalOptions="Start" /> <Entry Grid.Row="2" VerticalOptions="Start" HorizontalOptions="Fill" HeightRequest="56" /> <Button Grid.Row="3" Text="Button"/> </Grid> </ContentPage>1.A WindowSoftInputModeAdjust set to Pan
Bottom button is not visible
example1a.mp4
1.B WindowSoftInputModeAdjust set to Unspecified
Bottom button is partially visible
example1b.mp4
<?xml version="1.0" encoding="utf-8"?> <ContentPage xmlns="http://schemas.microsoft.com/dotnet/2021/maui" xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml" SafeAreaEdges="None" x:Class="SafeAreaEdgesBug.MainPage" BackgroundColor="Green"> <Grid RowDefinitions="80, auto, *, Auto" SafeAreaEdges="Default" BackgroundColor="Red"> <Label Grid.Row="0" Text="Hello World!" HorizontalTextAlignment="Center" VerticalOptions="Start" /> <Entry Grid.Row="2" VerticalOptions="Start" HorizontalOptions="Fill" HeightRequest="56" /> <Button Grid.Row="3" Text="Button"/> </Grid> </ContentPage>2.A WindowSoftInputModeAdjust set to Pan
Correct behavior
example2a.mp4
2.B WindowSoftInputModeAdjust set to Unspecified
Bottom inset for Grid is set to 0 while keyboard is show which restults in jumping of the button.
example2b.mp4
Steps to Reproduce
See attached project.
(https://github.com/user-attachments/files/23780187/SafeAreaEdgesBug.zip)
Link to public reproduction project repository
No response
Version with bug
10.0.11
Is this a regression from previous behavior?
Not sure, did not test other versions
Last version that worked well
Unknown/Other
Affected platforms
Android
Affected platform versions
No response
Did you find any workaround?
No response
Relevant log output