Bug 178534 [Forms] Expandable Composite right margin computation bug
Build ID: I20070222-0951 Steps To Reproduce: 1.Make a form with a section 2.Add controls to the form More information: I noticed there was (marginWidth + thmargin) less to what should be the section's client width. I compared what i get to the screen shots in "UI Forms enhancements in release 3.3" (yes i did that! :)) and found that i add a two big margin on the right. I debugged the private layout of ExpandableComposite and i found that at line 332 (in release 3.3M5) int areaWidth = clientArea.width - marginWidth - marginWidth - thmargin - thmargin; int cx = marginWidth + thmargin; if ((expansionStyle & CLIENT_INDENT) != 0) { cx = x; areaWidth -= x; } But when that is called x equals to (marginWidth + thmargin) so after that areaWidth equals to clientArea.width - 3*marginWidth - 3*thmargin. Is that a bug or a feature ? If it is a bug then i propose the following: int areaWidth = clientArea.width - marginWidth - thmargin; int cx = marginWidth + thmargin; if ((expansionStyle & CLIENT_INDENT) != 0) { cx = x; } areaWidth -= cx;
bundles/org.eclipse.ui.forms/src/org/eclipse/ui/forms/widgets/ExpandableComposite.java
* text.
	 */
	public static final int TITLE_BAR = 1 << 8;
	/**
	 * If this style is used, a short version of the title bar decoration will
	 * be painted behind the text. This style is useful when a more descrete
	 * option is needed for the title bar.
	 * 
	 * @since 3.1
	 */
	public static final int SHORT_TITLE_BAR = 1 << 9;
	/**
	 * If this style is used, title will not be rendered.
	 */
	public static final int NO_TITLE = 1 << 12;
	/**
	 * By default, text client is right-aligned. If this style is used, it will
	 * be positioned after the text control and vertically centered with it.
	 */
	public static final int LEFT_TEXT_CLIENT_ALIGNMENT = 1 << 13;
	/**
	 * By default, a focus box is painted around the title when it receives focus.
	 * If this style is used, the focus box will not be painted.  This style does
	 * not apply when FOCUS_TITLE is used.
	 * @since 3.5
	 */
	public static final int NO_TITLE_FOCUS_BOX = 1 << 14;
	
	/**
	 * Width of the margin that will be added around the control (default is 0).