May 2015
Intermediate to advanced
225 pages
5h 30m
English
Supporting different screen sizes, resolutions, and pixel densities is important because you want your application to look its best on as many Android devices as possible. Android will try to scale your user interface to fit the device, but it doesn’t always do a great job of it. The only way to tell is through, you guessed it, testing. Use the emulator types recommended in Gentlemen, Start Your Emulators to make sure your program works on the most common sizes.
As a test, try running the Tic-Tac-Toe program in the Nexus 9 emulator. You’ll find that the menu on the main activity and the board in the game activity look too small. That’s because all the sizes are specified in dps, but the tablet has a much larger ...