RegisterSearchFAQ UsergroupsLog in
JTableHeader old-fashioned - > (Delegator Implementation

 
Reply to topic    Citra Technologies Forum Index » Request a Feature View previous topic
View next topic

JTableHeader old-fashioned - > (Delegator Implementation
Author Message
xn00147



Joined: 19 Apr 2006
Posts: 8

Post JTableHeader old-fashioned - > (Delegator Implementation Reply with quote
Hi,
i am using the Windows Look&Feel and would like participate from the nice looking table header.
I have now a look, which is really viewable in a Windows 8/10 OS environment.

Your implementation looks a litte bit old fashioned.
My customers want to have a modern UI. The next time i want to mix JavaFX and TableLib.
I really ask for help.
In my extensions of renderer (Combobox as TreeComboBox, ...), i always use a delegator implementation, to keep the look and feel stable.

In my opinion it should be possible to implement a way where the Standard Look&Feel of JTableHeader and it's renderer it's catched
and in the further way the base rendering is delegated.

Your delegator implementation would use the base rendering as 'Sorting button' Smile
setting your sorting arrows as images in the JLabel. The button you emulate with a simple Mouselistener.
Your real table header implemenation would be a composite of the standard header and the JButton (filtering).

Or you take the standard render twice. The second with a underlying JLayerPane adding over a button not opaque.
So create you an new TableHeader not loosing representation of look and feel, usable with all Look & Feels.

PS: Please answer also via email.
Sat Jul 02, 2016 6:38 am View user's profile Send private message
support



Joined: 21 Feb 2006
Posts: 1443

Post Reply with quote
Hi,

Our library is already Look and Feel independent, in the sense that we do not override any UI classes. Using a label instead of a button in SortTableModel is easy enough.

I will let you know.

Thanks
Fri Jul 08, 2016 12:50 am View user's profile Send private message
support



Joined: 21 Feb 2006
Posts: 1443

Post Reply with quote
Hi,

As of version 4.8.2, you can use SortTableDefaultRenderer that uses JTableHeader's default renderer for drawing the sorted header cells. In this way, the table's appearance follows the installed L&F. As for filtering, you can set DefaultFilterRenderer to also use the default renderer with:

Code:
filterRenderer.setUseDefaultRenderer(true);


Hope this helps!
Wed Nov 30, 2016 8:11 pm View user's profile Send private message
Display posts from previous:    

Reply to topic    Citra Technologies Forum Index » Request a Feature All times are GMT - 5 Hours
Page 1 of 1

 
Jump to: 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group