community icon indicating copy to clipboard operation
community copied to clipboard

Flickering screen and jumping widgets

Open Matan22g opened this issue 5 years ago • 10 comments
trafficstars

Software Versions

  • Python: 3.7.6
  • OS: Android
  • Kivy: was with fork: kivy==5ed7a1335bd66c4365b666eccce049f27ebfc51b and tried with the 2.0.0rc3 release as well.
  • Kivy installation method: Buildozer
  • Buildozer spec code: https://paste.ofcode.org/HuAyRRRgBzvCLVbAPCnVVw

:Describe the bug

When the notification bar is dragged down and then goes back. Or when the android keyboard appears and disappeares. and also when android navigations buttons being sticked to the screen - The screen does this flickering where all widgets hoping down and up and a white/black flash appears at the top of the screen.

Expected behavior

The screen and widgets to stay stable and not move or resize themselves

Code and Logs and screenshots

ezgif com-gif-maker (4)

I also tried with a simple hello world app - with the latest kivy release I mentioned.

ezgif com-gif-maker (6)

that same bug effect happen when sticking the navigation buttons of android to the screen, theres a kivy app that it doesnt happen with the notifcation bar, but it does happer with the sticking, maybe its all related somehow?

ezgif com-gif-maker (7)

Additional context

The bug occurrs on every screen in the app. Not only in a particular one. The fixes I've tried (for both the apps Ive shown above) are:

  1. Settling at the Buildozer specs fullscreen to 0 and to 1, without any improvement.
  2. Ive also tried to set Config.set('graphics' , 'resizeable', False) At the beginning of main.py import code.
  3. And Ive tried to set a function to Window.on_resize that gives the window the exact size it had when the app was lunched - without any success

You can see my app code at my Fitness App repo. I really appreciate anyone trying to help. Thanks in advance!

Matan22g avatar Oct 07 '20 07:10 Matan22g

These do not look like standard kivy widgets (possibly Kivy MD). Can you reproduce the problem using standard kivy widgets? If not, then it's an issue with the widgets. And if you're using KivyMD, then you should probably log the issue there?

Zen-CODE avatar Oct 17 '20 15:10 Zen-CODE

@Matan22g did you ever resolve this? We are having a similar problem. In our case, sometimes the "jumping" never jumps back, and the app is permanently shifted down. it goes away if you try to minimize / restore the app (or pull down the system menu again)

brentpicasso avatar Nov 21 '22 18:11 brentpicasso

Hi @brentpicasso !

This is happening on multiple devices or only on devices from a specific vendor / vendors?

misl6 avatar Nov 21 '22 19:11 misl6

Hi @brentpicasso !

This is happening on multiple devices or only on devices from a specific vendor / vendors?

Multiple devices; samsung as well as Fire Tablets.

brentpicasso avatar Nov 21 '22 19:11 brentpicasso

https://user-images.githubusercontent.com/3267533/203146691-5d741ef9-a3b9-4979-b922-90e2104b5e1b.mov

https://user-images.githubusercontent.com/3267533/203146735-60755bed-d70d-43d3-88b9-84791d7fda29.mov

brentpicasso avatar Nov 21 '22 19:11 brentpicasso

Is that happening on both kivy/python-for-android==master and kivy/python-for-android==develop ?

misl6 avatar Nov 22 '22 19:11 misl6

We can test for this.

brentpicasso avatar Nov 22 '22 19:11 brentpicasso

Any update on this? Experiencing the same issue

chisomnriezedi avatar Dec 04 '23 06:12 chisomnriezedi

@chisomnriezedi: As you can see, there are lot of unanswered questions that previous experts have asked. Please help by answering them:

Can you reproduce the problem using standard Kivy widgets? What version of kivy/python-for-android are you using?

Julian-O avatar Dec 04 '23 06:12 Julian-O

I'm having this issue also.

From what I understood trying to fixit was:

This only happen when using the buildozer option: fulscreen = 1

Setting fullscreen = 0 and then, with the help of pyjnius, in application code, hidding status and navigation bars, the issue doesn't happen.

You can check https://github.com/rpedroso/kivy_bug_7133. There are 3 branches:

Branch master: minimal kivy app, a Label only, where the issue can be seen. fullscreen = 1 in buildozer

Branch fix: fullscreen = 0 in buildozer Using a Label and changing to fullscreen in "def build:". The jumping doesn't happen. Enter and exit fullscreen can be done with a double tap. The moment of switching we can see a jump.

Branch fix_test_with_textinput: Same as above but with a TextInput

This was not easy to explain in English, but ...

rpedroso avatar Dec 15 '23 23:12 rpedroso