Multiline TableHeader

This forum is used by users to request and discuss new product features. Please do not use this forum for technical support including bug reports.

Moderator: JIDE Support

Forum rules
Product suggestions only. Please do not use this forum for technical support including bug reports.

Re: Multiline TableHeader

Postby JIDE Support » Tue Oct 05, 2010 3:39 pm

Please give the following code a try. The reason is that, when you drop down, the header is in editing mode so renderer would not be invoked at this moment.
Code: Select all
    class CustomAutoFilterTableHeader extends AutoFilterTableHeader {
        public CustomAutoFilterTableHeader(JTable table) {

        protected TableCellEditor createDefaultEditor() {
            if (isAutoFilterEnabled()) {
                return new AutoFilterTableHeaderEditor() {
                    private static final long serialVersionUID = -7347944435632932543L;

                    protected AutoFilterBox createAutoFilterBox() {
                        return new AutoFilterBox() {
                            protected void customizeList(JList list) {

                            public Object[] getPossibleValues() {
                                return super.getPossibleValues(); // return your possible values list here to change the drop down list

                    protected void customizeAutoFilterBox(AutoFilterBox autoFilterBox) {
            else {
                return null;

JIDE Software Technical Support Team
JIDE Support
Site Admin
Posts: 34939
Joined: Sun Sep 14, 2003 10:49 am


Return to Product Suggestions

Who is online

Users browsing this forum: No registered users and 1 guest