Recent Changes‎ > ‎

New Layout Editor Property Sheet

posted Apr 17, 2012, 3:24 PM by Tor Norbye   [ updated Apr 17, 2012, 3:26 PM ]
In ADT 20 we're replacing the property sheet in the layout editor with a much better one (based on the WindowBuilder codebase):

There are several things to note here:
  • Important attributes are highlighted in bold
  • Values which have been edited for this widget are shown in blue.
  • Some default values are shown. For example, in this case the Text Color Link is not defined, but the default value is apparently (for this theme) @android:color/holo_blue_light, and a preview of that color is rendered.
  • Attributes can be nested; for example, the layout parameters are all nested in a single layout parameters section. All attributes from each defining class (such as TextView) are grouped together. You can use the Collapse All and Expand All buttons in the toolbar to quickly collapse/expand these categories.
  • You can switch to alphabetical sorting instead, if you know you want a particular attribute by name.
  • Advanced properties are hidden by default, and can be shown if you toggle the show advanced button:
In the above screenshot all the attributes with gray italics labels are advanced attributes which were hidden before we toggled the show advanced button (the leftmost button in the toolbar above). Notice also how it's rendering previews of not just colors, but drawable icons as well; the above shows the default text selection handles on an EditText.

There is improved support for entering values. Boolean values have a tri-state checkbox (on, off, default). The "..." button continues to open the resource chooser, but if you click into a value text field to edit it, you get completion support as you're typing. For example, when you're entering a resource value, it shows the possible completions:
And if you're entering an enum or flag, you get completion on the possible values:
You can also enter multiple flags:
NOTE: The new property sheet works best as a tall window, but the default Eclipse property sheet viewer is a wide window in the bottom area. We're working on a scheme to deal with this, but in the meantime, you may want to simply drag the property sheet window and dock it on the right, either sharing a tab with the outline window, or perhaps better yet docking it below the outline window.
Comments