We now have several new lint rules since the initial set from last week:
Typography suggestions: Looks at your string files and suggests replacing hyphens in numeric ranges with en dash characters, double hyphens with an em dash character, triple dots with an ellipsis character, (c) with a copyright symbol, and so on. There is also a rule checking for quotes usage, suggesting replacing straight quotes with directional quotes (both for single quotes and double quotes), and it also warns about using the grave accent character as a quoting character, like `this'. This last check is disabled by default because whether directional quotes is preferred isn't settled yet, but you can enable this check with
Wrong layout parameters: Makes sure that layout parameters found on views matches the parent layout. When moving view code around it's pretty easy to end up with obsolete layout parameters, such as a
Overdraw Detector: Looks for "overdraw", where you have a layout which specifies a background drawable to be painted all over the background, where the same layout is using a theme which also paints a background. This means that the theme background will be painted and then completely covered by the view background. It's more efficient in this case to use a custom theme with a null theme background (or if your background is translucent, it's more efficient to premix a single image and use that instead.)
Layout performance: Finds LinearLayouts with weights where you should set
Deprecation: Warns about usages of deprecated APIs (currently just AbsoluteLayout, more planned).
(You can download a preview of lint as part of the ADT 16 Preview. See the Download page for details.)
Recent Changes >