Author: François Vogel <email@example.com> Author: François Vogel <firstname.lastname@example.org> State: Final Type: Project Vote: Done Created: 18-Jan-2016 Post-History: Keywords: Tk,listbox Tcl-Version: 8.6.5
Despite the listbox widget already having numerous configuration options, some users need more refinements and have requested the possibility to control the justification of the text displayed in the items of the listbox. This TIP proposes to add this option.
Currently the listbox widget always aligns its items leftwards. Some users miss a configuration options allowing to justify items in the listbox widget. These RFE include:
RFE 454303, https://core.tcl.tk/tk/tktview/454303
RFE 3f456a5bb9, https://core.tcl.tk/tk/tktview/3f456a5bb9
It is proposed to add the -justify configuration option to the Tk listbox widget.
Possible values are as already documented in the options manual page (i.e., left, center, or right), and translate internally into standard Tk_Justify values, i.e., TK_JUSTIFY_LEFT, TK_JUSTIFY_CENTER, and TK_JUSTIFY_RIGHT, respectively.
Default value is left on all platforms, for backwards compatibility reasons.
A reference implementation is available in branch tip-441 of the fossil repository.
This document has been placed in the public domain.