Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » NatTable » Validation error style
Validation error style [message #1817774] Fri, 29 November 2019 02:18 Go to next message
zida wang is currently offline zida wangFriend
Messages: 7
Registered: November 2019
Junior Member
I want to change the cell border,but it doesn't work,I can change the background color and foreground color but how to change the border when in validation error style. here is my code

Style style =new Style();
style.setAttributeValue(CellStyleAttributes.BACKGROUND_COLOR,GUIHelper.COLOR_RED);
style.setAttributeValue(CellStyleAttributes.BORDER_STYLE,new BorderStyle(2,GUIHelper.COLOR_RED,LineStyleEnum.SOLID));
configRegistry.registerConfigAttribute(EditConfigAttributes.VALIDATION_ERROR_STYLE,style, DisplayMode.EDIT);
Re: Validation error style [message #1817816 is a reply to message #1817774] Fri, 29 November 2019 15:02 Go to previous messageGo to next message
Dirk Fauth is currently offline Dirk FauthFriend
Messages: 2814
Registered: July 2012
Senior Member
If you use the RenderErrorHandling you should see in the code that changing the border is not supported in there. So you need to extend it to add that support.

Feel free to provide a patch to add that support to NatTable core directly.
Re: Validation error style [message #1817820 is a reply to message #1817816] Fri, 29 November 2019 17:20 Go to previous messageGo to next message
zida wang is currently offline zida wangFriend
Messages: 7
Registered: November 2019
Junior Member
I'm new to natTable, how to extend it. can you give some advice, thank you very much
Re: Validation error style [message #1817823 is a reply to message #1817820] Fri, 29 November 2019 18:13 Go to previous messageGo to next message
Dirk Fauth is currently offline Dirk FauthFriend
Messages: 2814
Registered: July 2012
Senior Member
That is a Java topic.

MyRenderErrorHandler extends RenderErrorHandler

and then do whatever you want to do.
Re: Validation error style [message #1817834 is a reply to message #1817823] Sat, 30 November 2019 07:34 Go to previous message
zida wang is currently offline zida wangFriend
Messages: 7
Registered: November 2019
Junior Member
I've tried it ,I think it's useful, but I have another problem before solving it. SWT Text don't have API to set border. I have to solve this first. thanks again
Previous Topic:Validation error style
Next Topic:CellOverrideLabelAccumulator
Goto Forum:
  


Current Time: Fri Jul 23 23:35:57 GMT 2021

Powered by FUDForum. Page generated in 0.01446 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top