Customize JTable

Discuss here any questions about the WebLaF library.
Bugs can be posted directly to GitHub issues tracker.

Customize JTable

Postby iamchathu » Thu Apr 23, 2015 6:39 am

I need to define style change(eg: Change Boarder color) to JTables in my custom skin. Is there specific way to do it?
iamchathu
 
Posts: 4
Joined: Thu Apr 23, 2015 6:37 am

Re: Customize JTable

Postby mgarin » Mon May 11, 2015 5:26 pm

To apply custom style globally you might use some of WebTableStyle class static fields - simply assign new values to those before creating any table and it will be used instead of the default settings.

You can also use default Swing methods to apply some table color settings like JTable.setGridColor.
User avatar
mgarin
Site Admin
 
Posts: 223
Joined: Mon Apr 16, 2012 1:01 pm
Location: Russia, Saint-Petersburg

Re: Customize JTable

Postby mgarin » Mon May 11, 2015 5:27 pm

With future updates WebLaF will be applying custom styles to all components through StyleManager and will have much better tools to provide customization for all components.
User avatar
mgarin
Site Admin
 
Posts: 223
Joined: Mon Apr 16, 2012 1:01 pm
Location: Russia, Saint-Petersburg

Re: Customize JTable

Postby iamchathu » Tue May 12, 2015 10:49 am

I like to use Style Manager is there any date of the new version release?
iamchathu
 
Posts: 4
Joined: Thu Apr 23, 2015 6:37 am

Re: Customize JTable

Postby iamchathu » Tue May 12, 2015 12:01 pm

I asked question how change boarder color on JTable in CustomSkin.xml using style manager.
iamchathu
 
Posts: 4
Joined: Thu Apr 23, 2015 6:37 am

Re: Customize JTable

Postby mgarin » Wed May 13, 2015 1:07 am

iamchathu wrote:I like to use Style Manager is there any date of the new version release?

Unfortunately no, I cannot say any specific release date or even a time window.
Though all major features are released separately and included into pre-release artifacts:
http://weblookandfeel.com/downloads/prerelease/


iamchathu wrote:I asked question how change boarder color on JTable in CustomSkin.xml using style manager.

You asked about how that style can be changed and I answered:
mgarin wrote:To apply custom style globally you might use some of WebTableStyle class static fields - simply assign new values to those before creating any table and it will be used instead of the default settings.

You can also use default Swing methods to apply some table color settings like JTable.setGridColor.

I can only add that it is not yet possible to do this using custom skin.
Skinning is available only for a small amount of components as a preview of the upcoming features.
User avatar
mgarin
Site Admin
 
Posts: 223
Joined: Mon Apr 16, 2012 1:01 pm
Location: Russia, Saint-Petersburg


Return to Questions

Who is online

Users browsing this forum: No registered users and 1 guest

cron