Konuyu Oyla:
  • Derecelendirme: 0/5 - 0 oy
  • 1
  • 2
  • 3
  • 4
  • 5
Android 16 Uygulama Ekran Taşma Sorunu
#1
Merhaba arkadaşlar

Başlıkta da belirttiğim gibi Google playdeki bir uygulamamın android son versiyonda ekrandan taşma yaptığını farkettim üst bar saat ve diğer bildirimlerin altında kalıyor. Aynı zamanda alt barda navigasyon tuşlarının altında kalıyor. Bu sorunlardan farklı olarak geri tuşu son versiyonda ekranın sol köşesine taşınmış ve uygulamada işlevini sağlamıyor.
Bununla ilgili aynı sorunlarla karşılaşan var mı gerçekten kötü bir görüntüye sebep oluyor bu durum kullanıcı açısından kötü deneyim sağlıyor ve kullanıcı kaybı yaratıyor bu sorunu nasıl çözerim yardımlarınızı bekliyorum

Not : Rad studio 13.1 36.1 SDK kullanıyorum.
Cevapla
#2
https://developer.android.com/develop/ui...edge?hl=tr
https://developer.android.com/guide/navi...ture?hl=tr
MSWindows, AndroidRAD Studio 13 Florence ve kafamda bir fikir  Tongue  
WWW
Cevapla
#3
ARMandroid Splash Tool ( for FMX Android Developers )
Android 15 and edge-to-edge enforcement
App overlaps Android system bar
Cevapla
#4
NOTE:  Google translator it's horrible ok!!!


Scenary:
a) Delphi 13.1
b) Android 16 ( API 36 ) - using Android Simulator by Google

1) in fact, the solutions already exists in Delphi 13.x using "Form.... SafeAreaChanged" event:
a) use a "container" ( like TLayout, TPanel, etc... ) to accomodate your visual components, define the "Align" property to "Client"
b) in "SafeAreaChanged" from Form, just re-define the 4 "Padding" properties

procedure TForm1.FormSafeAreaChanged( Sender: TObject; const AInsets: TRectF );
begin
 Padding.Top    := AInsets.Top;
 Padding.Left   := AInsets.Left;
 Padding.Right  := AInsets.Right;
 Padding.Bottom := AInsets.Bottom;
 //
 // visual tests...
 Memo1.Text := Format( 'NL=%f, NT=%f, NR=%f, NB=%f', //
   [ AInsets.Left, AInsets.Top, AInsets.Right, AInsets.Bottom ] );
end;

bds-cgme0n-Bz-Tq.gif




To demonstrate that the event is working correctly, you could switch the Android theme and observe the margins being respected.

The TForm uses "Fill.Kind = SOLID" to correctly render the Android theme, but this is not required for rotation or form margin management.

Additionally, there is a native Android API call that utilizes the "OnLayoutChange" event (which Embarcadero likely uses for the SafeAreaChanged event).

This event is part of the Android callback system; it offers greater control—being essential for class and system-level registration—and provides additional functionality.

The form's "SafeAreaChanged" event is the most practical and straightforward option, given the form class!



procedure TWindowLayoutChangeListener.onLayoutChange( V: JView; left, top, right, bottom, oldLeft, oldTop, oldRight, oldBottom: Integer );
var
  LInsets                                         : JWindowInsets;
  LLeftInset, LTopInset, LRightInset, LBottomInset: Single;
  LNewLeft, LNewTop, LNewRight, LNewBottom        : Single;
  LScreenScale                                    : Single;
begin
  if Assigned( V ) and Assigned( FForm ) then
  begin
    LInsets := V.getRootWindowInsets;
    //
    if Assigned( LInsets ) then   
    begin

     // To illustrate the concepts, I am using many variables, but this isn't strictly necessary! Just be sure to watch out for division by zero!
      // 
      // Now, based on the device's current scale, you will be able to calculate the new values...
      // LScreenScale := TAndroidHelper.Activity.getResources.getDisplayMetrics.density;
      LScreenScale := GetScreenScale;
      //
      if LScreenScale = 0 then
        LScreenScale := 1;
      //
      LTopInset    := LInsets.getSystemWindowInsetTop;
      LLeftInset   := LInsets.getSystemWindowInsetLeft;
      LRightInset  := LInsets.getSystemWindowInsetRight;
      LBottomInset := LInsets.getSystemWindowInsetBottom;
      //
      // TForm olmadan doğrudan uygulama veya dolgu
      LNewTop    := LTopInset / LScreenScale;
      LNewLeft   := LLeftInset / LScreenScale;
      LNewRight  := LRightInset / LScreenScale;
      LNewBottom := LBottomInset / LScreenScale;
      //
      FForm.Padding.top    := LNewTop;
      FForm.Padding.left   := LNewLeft;
      FForm.Padding.right  := LNewRight;
      FForm.Padding.bottom := LNewBottom;
      //
      // Form_InsetsListener is my Form main...
      Form_InsetsListener.Memo1.Lines.Add( 'Scale=' + LScreenScale.ToString );
      Form_InsetsListener.Memo1.Lines.Add( //
        Format( 'LI=%f, TI=%f, RI=%f, BI=%f', [ LLeftInset, LTopInset, LRightInset, LBottomInset ] ) );
      Form_InsetsListener.Memo1.Lines.Add( //
        Format( 'NL=%f, NT=%f, NR=%f, NB=%f', [ LNewLeft, LNewTop, LNewRight, LNewBottom ] ) );
    end
    else
      Form_InsetsListener.Memo1.Lines.Add( 'LInsets is NIL' );
  end
  else
    Form_InsetsListener.Memo1.Lines.Add( '"V" is NIL' );
end;
MSWindows, AndroidRAD Studio 13 Florence ve kafamda bir fikir  Tongue  
WWW
Cevapla


Konu ile Alakalı Benzer Konular
Konular Yazar Yorumlar Okunma Son Yorum
  Google Play Billing Versiyon Sorunu codder71 8 159 27 dakika önce
Son Yorum: codder71
  PHPickerDelegate Derleme Sorunu [ÇÖZÜLDÜ] codder71 13 494 18-07-2026, Saat: 22:54
Son Yorum: emailx45
  ios için uygulama derleme [ÇÖZÜLDÜ] codder71 29 2.006 01-07-2026, Saat: 14:39
Son Yorum: codder71
  Delphi FMX - Modern Android Bileşen ve Tema Yapılandırması | Rehber Mr.X 0 166 29-06-2026, Saat: 13:44
Son Yorum: Mr.X
  Webbrowser Sorunu [ÇÖZÜLDÜ] codder71 7 623 10-02-2026, Saat: 17:04
Son Yorum: codder71



Konuyu Okuyanlar: 1 Ziyaretçi