Is there a way the measure the hight of the navigation bar at the bottom in pixels?
相关问题
- How can I create this custom Bottom Navigation on
- Bottom Navigation View gets Shrink Down
- How to make that the snackbar action button be sho
- Listening to outgoing sms not working android
- How to create Circular view on android wear?
相关文章
- android开发 怎么把图片放入drawable的文件夹下
- android上如何获取/storage/emulated/下的文件列表
- androidStudio有个箭头不认识
- SQLite不能创建表
- Windows - Android SDK manager not listing any plat
- Animate Recycler View grid when number of columns
- Why is the app closing suddenly without showing an
- Android OverlayItem.setMarker(): Change the marker
By the way... for anyone else like me who stumbled upon this question looking for the actual number, it's 48 pixels (on the Motorola Xoom, at least). This was based upon the debug output of this (admittedly crude) test Activity, combined with a Theme with no title bar (e.g., @android:style/Theme.NoTitleBar) and a single-View LinearLayout with both height and width set to "match_parent" (e.g., the one created when creating a new Android app) :
On a Motorola Xoom running Android 3.1 (as well as a Samsung Galaxy 10.1V running 3.0), the output from the onLayoutChange method when entering portrait mode is :
and when entering landscape :
meanwhile i found the solution. there is a new
OnLayoutChangeListener
event in honycomb wich allows you wait for the layout to be finished and then measure the size of your layout instead of the screensize.