JFXtras / jfxtras-styles

Java, JavaFX themes or look and feels. Currently contains JMetro theme.
https://pixelduke.com/java-javafx-theme-jmetro/
642 stars 144 forks source link

Collapsing a TreeItem in a TreeView with a selected child causes a visual bug while pressing #199

Closed Exopandora closed 2 years ago

Exopandora commented 3 years ago

Issue: Collapsing a TreeItem in a TreeView with a selected child causes a visual bug at the bottom of the TreeView while pressing the mouse button

Steps to reproduce:

  1. Start the same app as in issue #198

grafik

  1. Expand "root"

grafik

  1. Select "child"

grafik

  1. Collapse (and hold) "root". There will be a visual bug at the bottom of the srceen

grafik

EDIT: The color you see at the bottom is cell_pressed_color from light_theme.css/dark_theme.css. I suspect that this issue is caused by not properly propagating the mouse input to the correct row cell.

Exopandora commented 3 years ago

Clicking (and holding) on the arrow without selecting any row also causes the same issue

dukke commented 3 years ago

Cool, thanks.

I think this might be an issue with JavaFX itself as I use the same standard skin of the JDK for the treeview. It appears as though a cell down below gets styled as if it had the mouse hover it (even though it doesn't)..

Exopandora commented 3 years ago

I already noticed that. I guess there is nothing you can do about that, really.

dukke commented 3 years ago

That might be the case, but I can do a little more research.. That's my hunch. Have you tried with more recent javafx versions?

Exopandora commented 3 years ago

Im using jfx 16

dukke commented 3 years ago

OK, thanks.

I'll have to research. We could file an issue on the javafx issue tracker if it's a javafx bug.

On Sat, May 8, 2021 at 9:33 PM Exopandora @.***> wrote:

Im using jfx 16

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/JFXtras/jfxtras-styles/issues/199#issuecomment-835502003, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAUVAH2KV7IUHY3DRCWPK7TTMWN27ANCNFSM44NXFQ2Q .

-- Pedro Duque Vieira - https://www.pixelduke.com

Exopandora commented 3 years ago

Have you found anything yet?

dukke commented 3 years ago

Hi @Exopandora, sorry for the late reply. I've been very busy in my payed work.

I'm pretty inclined to this being a JavaFX bug. Have you tried using Modena and setting just an hover effect for the cells then see if this happens?

Thanks, kind regards,

Exopandora commented 3 years ago

After some testing i located the issue and created a PR. But as i said in the PR i don't know if this causes any side effects

dukke commented 2 years ago

Hi @Exopandora

Sorry for the late reply, I've been very busy with my work.

I can't seem to reproduce this issue in javafx 17. Would it be possible for you to pull the latest version and check?

Sorry again. Cheers.