Community
Participate
Working Groups
A specific composite is created in ListButtonsField so that list and buttons can be correctly placed within the parent composite (e.g. wizard page). With this specific composite, it becomes possible to compute the right width of the buttons (not too large, not too thin); computation which is ensured by LayoutUtil. When trying to create and use StringButtonField, we observe that obtained result is different: button size is not controlled! I suggest StringButtonField should be enhanced so that an equivalent 'specific composite' is created within the field. It would also allow to be independent from the number of columns of the parent composite (which may cause strange fields alignments and sizes). In addition, I noticed that test on button style in LayoutUtil was not completely right (it uses exact equal instead of mask comparison).
Created attachment 206107 [details] Proposed patch for StringButtonField enhancement The proposed attached patch contains the following enhancements: ¤ In LayoutUtil: * Created new methods to allow clients to specify additional arguments (e.g. hgrab and vgrab); * Fixed button style check for width computation; ¤ Moved 'createSpecificComposite' from ListButtonsField to BasicField so that it is now accessible from both ListButtonsField and StringButtonField; ¤ Review the use/setting of GridLayout and GridData in this two fields; ¤ Wrote JavaDoc on modified methods. I would appreciate your review feedbacks!
Applied proposed patch like enhancement description.
Mass-closing Resolved tickets