Android N Feature Spotlight: Updated ART Compiler Means No More Obnoxiously Long 'Optimizing Apps' Step And Much Faster App Installs
Android N Feature Spotlight: More Powerful Built-In File Manager Adds Move, Rename, Create, And Multiple Instances
Android N Feature Spotlight: Easily Change Your Device's Display DPI With Screen Zoom
Android N Feature Spotlight: Long Tapping The Flashlight In Quick Settings Launches The Camera, Other Icons Go To Their Respective Settings
Android N Feature Spotlight: New Force Close Pop-Up Has "Reset And Restart" And "Mute Until Device Restarts" Options
- View All 90 Articles In This Series
Android N keeps spilling more and more of its secrets, and we're still trying to go through all the new features added in this latest and sweetest preview of Android. One feature that any developer will applaud and many users will love is the ability to manually fake a specific DPI on your phone, making it think it's got a larger screen with smaller and tighter elements or a smaller one with bigger and more interspersed items. That was previously possible with third-party apps when rooted or with adb on non-rooted devices, but it's now a native and easy to switch feature.
The option is found under Settings > Display > Display size, and it includes three different preview elements — messaging, app drawer, and settings — so you can easily see what to expect from each setting you choose in various areas of the interface. There are 5 levels of size changes: Small, Default, Large, Larger, and Largest. The settings black out and return when you try changing one of them, but once that's done, you'll be set on a new screen resolution.
Large, Larger, Largest
Unlike the Font size setting, this affects all elements on your screen, not just text, which makes it very useful in different circumstances: for developers who want to test their apps on different display resolutions but only have one device in hand, for users who want a more dense layout on their screens, and for those with poor eyesight or weak muscle function who might need bigger and more accessible elements.
Small to Largest with the app drawer preview
As Alan Viverette from the Android Framework team explained on Reddit, the zoom levels go between 0.85x and 1.5x roughly, with the maximum zoom being limited to what is an effective 320dp resolution. The Android developers page calls this option "Screen Zoom" and cites 320dp as the "width of a Nexus 4, a common medium sized phone," and explains what developers need to do to make their apps compatible with this new feature and function well under the different settings. The most important thing is to make sure the app works on 320dp and that all dimensions should be specified in dp and not px pixel units.
Small to Largest with the settings preview
Also worth mentioning is that the "adb shell wm density" command has been fixed in N and it no longer works wonkily and capriciously. Alan said that you can still use that to set a specific arbitrary density and it will show up in the Display size setting as Custom.
- Android Developers