Android 应用程序不占据整个屏幕
我试图在自定义屏幕分辨率上运行我的应用程序,但我的应用程序居中,仅占据屏幕的 320x480(纵向)和 480x320(横向),并且与 Activity 的顶部水平对齐。
虽然其他应用程序和默认的 Android 活动表现得很好,但我的应用程序却不然。我没有使用任何固定值或布局属性。这只是一个你好世界应用程序。
我尝试过主题和窗口功能,但似乎没有任何效果。任何指示将不胜感激。谢谢。
I am trying to run my application on a custom screen resolution but my application is centered and only occupies 320x480 (Portrait) and 480x320 (Landscape) of the screen and is horizontally aligned to the top of the activity.
While other apps and the default android activities behave aptly my application doesn't. I haven't used any fixed values or layout properties. It's just a hello world app.
I have tried themes and window features but nothing seem to work. Any pointers would be greatly appreciated. Thanks.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
Kumar Bibek 在类似的帖子< /a>.
该应用程序在平板电脑兼容模式下运行。我将以下内容添加到我的 AndroidManifest.xml 中,它工作正常。
Kumar Bibek has answerd this question in a similar post.
The application was running in compatibility mode for tablets. I added the following to my AndroidManifest.xml and it works fine.