The previous article we mainly understand why the adaptation, and how to adapt, at the same time to give some of the specification, and in the development process need some considerations, this is mainly from the official guidance from the advice, from a visual angle to say how to fit.
Design cadence of measurement units and grid-DP
In general, a touch control is based on a per-DP basis.
Why is the DP?
In general, the physical size of the DP on the device is 9 mm (there will be some changes). This is precisely within the size range (7-10 mm) recommended by the touch control, and it is also more accurate and easy for users to touch with their fingers. If you design elements that have at least the height and width of the DP, you can guarantee:
When you design an element that is displayed on any screen, it will not be less than the minimum recommended value of 7 mm.
You can get a good balance between information density and the maneuverability of interface elements.
Note: The white space between the interface elements should be 8 DP.
Font Scaling
Introducing a font-size contrast for different controls can help create an orderly, understandable typesetting effect. However, using too many different font sizes in the same interface can cause confusion. The Android design framework uses several of the following limited font sizes:
Color
Different colors are used to emphasize information. Choose the right color for your design and provide a good visual contrast. Note that red and green may not be distinguishable for blindness.
Blue is the standard color in the Android palette. Each color has a corresponding dark version for use.
Icon
An icon is a small picture that represents the contents of the screen and provides a first impression of the action, status, and application.
When designing icons for your app, keep in mind that the devices are diverse, which brings different pixel densities (see device and display). In order to deal with this problem, it is a good idea to provide icons of different sizes. Android optimizes your selection for different devices based on the icons you provide.
Since all icons need to be adapted to different pixel densities, this unit introduces DP, which provides a pixel-density-independent representation of a medium-sized, mdpi screen.
When designing icons, the five main pixel densities (MDPI, HDPI, XHDPI, xxhdpi, and xxxhdpi) should be scaled according to the 2:3:4:6:8 scale. For example, the size of a boot icon is 48x48 DP, which means that on MDPI's screen its actual size should be 48x48 px, its actual size on the HDPI screen is 1.5 times times MDPI (72x72 px), and its actual size on the xdpi screen is MDPI 2 Times (96x96 px), and so on.
Tip: Although Android also supports low pixel density (ldpi) screens, it does not bother to do so, and the system automatically shrinks the HDPI size icon to 1/2 for matching.
Start icon
The launch icon represents your app in the home screen and all apps. Because the user can set the "Home screen" wallpaper, make sure that your startup icon is clearly visible on any background.
Overall size is 48x48 DP
The boot icon size on the mobile device must be 48x48 DP. The boot icon size that appears in the Play store must be 512x512 pixels.
Use a unique silhouette. Three-dimensional frontal view that looks a little bit from the top down to the perspective so that the user can see some depth of field
Action Bar
The Action bar icon is an image button that represents important actions that the user can perform in the app. Each icon uses a simple metaphor to represent the action that will be performed, and the user should be at a glance.
Built-in icons should be used to indicate certain common actions, such as "refresh" and "share". The download link below provides an icon pack with icons that can be scaled to a variety of screen resolutions and suitable for light and dark holo themes. Are there any styling icons in the icon pack that you can match with your own theme and provide Adobe? Illustrator? Source files, you can modify them yourself.
The Cell phone Action bar icon size should be 32x32 DP.
Overall size is 32x32 DP graphics area 24x24 DP
Pictographic, flat, don't have too much detail, smooth arc or sharp shape. If the shape is too narrow, rotate 45° to the left or right to fill the graphics area. The most fine strokes should not be less than 2DP
Color: #333333, usable: 60% transparency, disabling: 30% transparency color: #FFFFFF, usable: 80% transparency, disabling: 30% transparency
Small icons and contextual icons
In the body area of the app, use small icons to indicate actions or specific states. For example, in the Gmail app, each message has a star icon to mark "important."
The small icon size should be 16x16 DP.
Overall size is 16x16 DP graphics area 12x12 DP
Neutral, flat and simple. It is best to use a fill icon instead of a thin line. Use simple visuals to make it easy for the user to understand the purpose of the icon.
Use a small, purposeful icon. For example, in the Gmail app, use the yellow star icon to represent important information. If the icon is operable, use a color that contrasts with the background color.
Notification bar icon
If your app generates notifications, provide an icon for the system to appear on the status bar, indicating a new notification
The notification bar icon size must be 24x24 DP
Overall size is 24x24 DP graphics area 22x22 DP
Use simple planar icons that are visually similar to the app's startup icons
The notification bar icon must be white so the system can scale and deepen your icon
Design Tips
Here are some tips that might help you create icons or other picture resources. Here we assume that you also use such as Adobe? Photoshop? This type of bitmap or vector graphics editing program.
Use vector images whenever possible
Adobe? Photoshop? This type of image editing tool allows users to mix vector plots and bitmaps. Use vectors as much as possible, so you can avoid the loss of detail when you need to zoom in on the icons.
Another benefit of using vector graphs is that it's easier to align edges and corners with pixel boundaries on low-resolution screens.
Use a larger canvas
To better fit different pixel densities, it is best to use a canvas that is several times the size of the target icon. For example, the start icon has a width of 48, 72, 96, and 144 px under MDPI, HDPI, XHDPI, and xxhdpi, and an artboard with 864x864 px can reduce the amount of effort when zooming the icon.
Redraw the bitmap layer on demand when zooming
If the icons that you want to enlarge include a bitmap layer, these layers need to be redrawn manually to get a better display at a higher pixel density. For example, a 60x60 px circle that is drawn for MDPI needs to be redrawn 90x90 px when the HDPI screen is fitted.
Icon Naming conventions
Follow certain icon naming conventions to help manage icon files. We can specify different naming prefixes for different types of icons:
Talk about Android adaptation (bottom)