Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to make my app full screen on Galaxy Tab

Tags:

android

I've been trying everything I can think of to get my app to display full screen on the Galaxy Tab.

Basically, it works like the Lunar Lander example app that comes with the Android SDK. What would you do to make that Lunar Lander app display in full screen on Large screen devices like the Galaxy Tab?

I'm not concerned about the quality of the graphics at this point, but just how an app created like this can fill the screen. It was basically designed to work on a 320x480 MDPI screen with images in the drawable folder and it uses a SurfaceHolder and view to draw the individual bitmaps.

Any advice?

CLARIFICATION: Sorry, I don't mean full screen as in removing the notification and title bar, I mean that everything has a giant black border around it and it the graphics don't take up the whole screen.

like image 338
Ben Mc Avatar asked Feb 03 '11 01:02

Ben Mc


People also ask

How do I make my apps full screen completely?

The easiest way to go full screen in an application or a game is to use the Alt + Enter keyboard shortcut. This method works for most games and apps unless they use it to enable other features. The shortcut is also used to switch from full-screen mode to windowed.

Why are some apps not full screen?

This is due to the aspect ratio the app has been designed to run in by the developer. Running the app in 18:9 screen aspect ratio (Full Screen) should allow full use of the application.

How do you make a tab full screen?

The quickest way to get Chrome in full-screen mode in Windows is to press F11 on the keyboard. The other way is through the Chrome menu: In the upper-right corner of Chrome, select the menu (three-dot) icon. In the Zoom section, select the square icon on the right.


2 Answers

If you set your target sdk level to anything less than 9, then support for extra-large screens is assumed to be false. If you set targetSdkVersion=9 in the manifest, then xlarge support is assumed to be true. See the documentation on Supporting Multiple Screens, in particular the description of compatibility mode.

like image 143
Ted Hopp Avatar answered Nov 29 '22 06:11

Ted Hopp


another way to do is creating a xml called styles.xml in res/values

define a style:

<style name="Theme.FullScreen" parent="android:Theme">
        <item name="android:windowFullscreen">true</item>
        <item name="android:windowNoTitle">true</item>
    </style>

later in the manifest, tell android what activity must be in fullscreen setting the style above:

<activity android:name=".activity.NewSearchBrowserActivity" android:theme="@style/Theme.FullScreen" android:screenOrientation="landscape"></activity>

in this way you make a reusable theme what can be applied to any activity.

like image 25
Franco Avatar answered Nov 29 '22 06:11

Franco