Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Different colors for each side of the cell #97

Open
kruthikarshankar opened this issue Aug 4, 2020 · 8 comments
Open

Different colors for each side of the cell #97

kruthikarshankar opened this issue Aug 4, 2020 · 8 comments

Comments

@kruthikarshankar
Copy link

I have a requirement where I need the table's overall border to be one color (BLACK) and the interior rows of the table separated with a GRAY color and no color for the column separators. Is there a way to maybe set the table border color to be BLACK after the rows are all added, and keep individual row border color to be GRAY?

@vandeseer
Copy link
Owner

Hi @kruthikarshankar,

as of now there is now way (yet!) to set the border colors of each side individually. But this can be added to easytable soon. There was simply no one before you asking for it. 😉

What you could do in the meantime is to work around it, e.g. something like this: https://gist.github.com/vandeseer/85e7124a1f153bc402b76123e2feb263

You would need to extend some of the table drawing classes which is a bit more involved ...
If I find some time I can give it another shot, but just to get an idea.

Hope this helps,
Stefan

@kruthikarshankar
Copy link
Author

I will look at the custom drawer here and try to implement it. I ended up adding a lot of extra functionality to accommodate 508 compatibility to the table structure, but we are out of time, and may not have the bandwidth to implement this although I am curious to try.

@vandeseer
Copy link
Owner

Basically the implementation should be more or less the same as for different border widths (they can be set separately already). I would be more than happy to review a pull request, otherwise I will try to implement this in the next weeks ... 😉

Regarding your changes for 508 compatibility: Is this something the whole library could benefit from or is it something specific for your current context?

@vandeseer
Copy link
Owner

I implemented the feature of individual border colors. You can try it out with this branch: feature/individual-border-colors

In the next days I'll try to add some tests and then publish it on maven.

@kruthikarshankar
Copy link
Author

Haa, I was halfway through the implementation when I read your message. Thank you. I was able to incorporate the remainder of the updates as well.
About the 508, currently it is not very portable. I am cleaning it up so it is not tightly coupled with my application. Once that is done, I will need to add tagging for areas that I did not need to tag for my needs. Then I can add it to a branch here? Let me know. I am looking at a month's time.

@Aidan-OS
Copy link

Hi, when will this branch be merged in? I would love to use this library for what I am currently working on, but due to the nature of the project I am required to use it through maven. I would need this feature to be able to use the library.

@vandeseer
Copy link
Owner

Hey @Aidan-OS,

thanks for reminding me! 😄

I merged this to develop just now. It only needs a proper test and then it can be released. Shouldn't be too hard to add the test – in the meantime just checkout the develop branch and install it locally.

Best,
Stefan

@Aidan-OS
Copy link

Great to hear!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants