1

I'm developing a game, my background has 1920x1080 resolution. It looks fine when on a device with hardware buttons (Galaxy 5), but on Nexus 5 (with software buttons) the background is visibly shortened (square looks like a rectangle now), because the softwarte buttons take some of this resolution.

How can I handle this situation? Can I make soft buttons "overlap" my activity and have some gradient instead of black background?

navarion
  • 91
  • 5

2 Answers2

0

This is a possible duplicate of this. I think what you need to do is to set your main container's bottom margin to whatever value you get from the virtual buttons' height. Good luck, I did it this way and it works fine for me.

Community
  • 1
  • 1
Giggs
  • 851
  • 10
  • 16
0

As an option can use notlong qualifiers for layout and resource folders. e.g. devices with software buttons will use the resources from layout-notlong folder if exists.

Taras
  • 2,526
  • 3
  • 33
  • 63