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

fixed PropertyPanel fill background for flatlaf l&f #7332

Merged
merged 1 commit into from
Apr 29, 2024

Conversation

DJ-Raven
Copy link
Contributor

This PR I has fixed fill the PropertyPanel background color for flatlaf look and feel. Can you please review it, Thank you.

2024-04-25_210338

@neilcsmith-net
Copy link
Member

What's the issue you're fixing here, exactly? The visual artefacts under Editor:. etc.?

-1 to any more checks for look and feel name (and is lowercase flatlaf correct anyway?)

@DJ-Raven
Copy link
Contributor Author

What's the issue you're fixing here, exactly? The visual artefacts under Editor:. etc.?

Yes in editor, I see this issue with TableCustomizer class

-1 to any more checks for look and feel name (and is lowercase flatlaf correct anyway?)

flatlaf is the package name com.formdev.flatlaf.FlatDarkLaf I thing future netbean have com.formdev.flatlaf.IntelliJTheme

@DevCharly
Copy link
Member

Better remove the isGtk field completely.
isGtk is only used in PropertyPanel.paint() to decide whether to fill the component background
and should be replaced with isOpaque() in that method.

Class PropertyPanel extends JComponent, which does not fill it background.
So when using setOpaque(true), which is done in constructor of PropertyPanel, it is required to fill its background.

Following comment should be also removed:

* Overridden to fill in the background color, since Synth/GTKLookAndFeel ignores
* setOpaque(true).
* @see https://bz.apache.org/netbeans/show_bug.cgi?id=43024

@neilcsmith-net
Copy link
Member

neilcsmith-net commented Apr 25, 2024

Was just writing the same comment as @DevCharly . +1 to taking that approach. Whoever wrote that comment misunderstood the use of setOpaque. It's possible this should have been a JPanel to start with, but safer not to change now.

Also, please make sure this is based on top of the delivery branch rather than master. I think this might be good to get into NB22.

@neilcsmith-net neilcsmith-net requested a review from ebarboni April 25, 2024 17:58
@mbien mbien added UI User Interface ci:dev-build [ci] produce a dev-build zip artifact (7 days expiration, see link on workflow summary page) labels Apr 26, 2024
@neilcsmith-net neilcsmith-net changed the base branch from master to delivery April 26, 2024 16:19
@neilcsmith-net neilcsmith-net changed the base branch from delivery to master April 26, 2024 16:20
@neilcsmith-net neilcsmith-net added the do not merge Don't merge this PR, it is not ready or just demonstration purposes. label Apr 26, 2024
@neilcsmith-net neilcsmith-net added this to the NB22 milestone Apr 26, 2024
@neilcsmith-net
Copy link
Member

Please can you rebase the branch on top of delivery - eg. git rebase HEAD~1 --onto delivery? Would be good to get this fix in the next release, but needs to not bring in later commits from master.

@DJ-Raven DJ-Raven changed the base branch from master to delivery April 26, 2024 17:39
@DJ-Raven DJ-Raven changed the base branch from delivery to master April 26, 2024 18:15
@mbien
Copy link
Member

mbien commented Apr 26, 2024

@DJ-Raven also squash to one commit and push with -f to the remote branch. Then you can change the target here and everything will update.

@DJ-Raven
Copy link
Contributor Author

@neilcsmith-net @mbien Sorry, I no experience with git rebase, I has try it but failed.

@mbien
Copy link
Member

mbien commented Apr 27, 2024

@DJ-Raven no worries, let me do this quickly.

 - removed obsolet isGtk field in PropertyPanel
@mbien mbien changed the base branch from master to delivery April 27, 2024 09:43
@mbien
Copy link
Member

mbien commented Apr 27, 2024

@DJ-Raven could you check that the author information is correct? Patch file: https://github.com/apache/netbeans/pull/7332.patch (one commit had just raven, I took the header from the other commit)

also please note that your master branch is now in fact the delivery branch ;). I can fix this again once this PR is integrated if you want.

@DJ-Raven
Copy link
Contributor Author

Yes raven

also please note that your master branch is now in fact the delivery branch ;). I can fix this again once this PR is integrated if you want.

I will check it

@mbien
Copy link
Member

mbien commented Apr 27, 2024

oh no you changed back :(

@DJ-Raven
Copy link
Contributor Author

Ohh sorry that I have updated my master branch 😔.

@mbien
Copy link
Member

mbien commented Apr 27, 2024

going to force push again. don't touch anything please :D

@mbien mbien removed the do not merge Don't merge this PR, it is not ready or just demonstration purposes. label Apr 29, 2024
@ebarboni ebarboni merged commit b1f593e into apache:delivery Apr 29, 2024
32 checks passed
@mbien
Copy link
Member

mbien commented Apr 29, 2024

@DJ-Raven congrats on your first contribution

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ci:dev-build [ci] produce a dev-build zip artifact (7 days expiration, see link on workflow summary page) UI User Interface
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants