Excessive repaints due to double rowHeight setting in AquaTreeUI
karlvr opened this issue · 1 comments
karlvr commented
AquaTreeUI
's updateCellSizes
method installs a rowHeight
property twice with different values. This causes an infinite loop of repainting in my application. I presume this is intentional? Commenting out the first installProperty
resolves the infinite repaint for me. Is it intentional? Shall I do some more investigation into the infinite loop?
protected void updateCellSizes() {
int h = Math.max(tree.getRowHeight(), -1);
LookAndFeel.installProperty(tree, "rowHeight", h + 1);
LookAndFeel.installProperty(tree, "rowHeight", h);
updateSize();
}
cbfiddle commented
It certainly appears intentional. I would guess that the goal is to ensure that a property change event is generated, but investigation is needed.
Also, it would be good to know what your app is doing that triggers this problem. I have programs that use trees and do not have this problem.
… On Jun 20, 2022, at 1:28 PM, Karl von Randow ***@***.***> wrote:
AquaTreeUI's updateCellSizes method installs a rowHeight property twice with different values. This causes an infinite loop of repainting in my application. I presume this is intentional? Commenting out the first installProperty resolves the infinite repaint for me. Is it intentional? Shall I do some more investigation into the infinite loop?
protected void updateCellSizes() {
int h = Math.max(tree.getRowHeight(), -1);
LookAndFeel.installProperty(tree, "rowHeight", h + 1);
LookAndFeel.installProperty(tree, "rowHeight", h);
updateSize();
}
—
Reply to this email directly, view it on GitHub <#20>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/ABSSJGNMJ4MQVQMTSHGYJUDVQDH6FANCNFSM5ZKAEOZQ>.
You are receiving this because you are subscribed to this thread.