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

FlatTableHeaderUI #228

Closed
thammoud opened this issue Dec 17, 2020 · 3 comments
Closed

FlatTableHeaderUI #228

thammoud opened this issue Dec 17, 2020 · 3 comments
Milestone

Comments

@thammoud
Copy link

Hello,

Thank you for such a wonderful library. We use a combination of JTable and Jide tables (SortableTable etc). Noticed that the header column borders do not have the borders painted as FlatLF installs an empty border and does the painting in the FlatTableHeaderUI.paintColumnBorders for normal JTables. Jide installs their own header UI's and augment the painting using the DefaultTableHeaderRenderer.

It feels that the standard way is to provide a column border that does all the painting so that any Swing table (Subclasses) will simply work. Just wanted to hear your thoughts on this. Perhaps I am missing something. Thank you.

Tarek

@DevCharly
Copy link
Collaborator

Thank you for such a wonderful library.

Thx 😃

The reason for painting in FlatTableHeaderUI was to be able to paint the full scrollpane width
if JTable's autoResizeMode is set to OFF.

image

Here is what it looks like in Metal, which paints in column header borders:

image

Anyway I agree with you that doing it the standard way would be better.
Probably a combination of using column border painting and painting in FlatTableHeaderUI could archive the same result.
Will try this...

DevCharly added a commit that referenced this issue Apr 14, 2021
…eHeaderUI` to new border `FlatTableHeaderBorder` to improve compatibility with custom table header implementations (issue #228)
@DevCharly
Copy link
Collaborator

I've changed the painting in commit 4f2256f

It is now done the standard way in border FlatTableHeaderBorder

If you've sub-classed FlatTableHeaderUI, then this change may break it.
CC @ingokegel

Please try the latest snapshot and report issues:
https://github.com/JFormDesigner/FlatLaf#snapshots

@DevCharly DevCharly added this to the 1.2 milestone Apr 14, 2021
@ingokegel
Copy link
Contributor

Excellent and thanks for the heads up. It works fine if I just remove the call to paintColumnBorders in my derived classes.

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

No branches or pull requests

3 participants