mbasaglia / Qt-Color-Widgets

Color wheel widget and dialog for Qt
147 stars 54 forks source link

Swatch doesn't resize automatically when palette changes #36

Closed caryoscelus closed 7 years ago

caryoscelus commented 7 years ago

This leads to swatch staying invisible (having zero size) even when palette is being filled, if it was originally added with an empty palette. Looks like when sizeHint changes, updateGeometry() should be called on widget.

mbasaglia commented 7 years ago

I don't think updateGeometry is the issue, looks like if you add colors and the Swatch has a color size policy that requires resizing, paletteModified was not being called (though I just tested this on a widget by itself, outside of a layout).

mbasaglia commented 7 years ago

The issues I've found are fixed in 1511046, can you check if that fixes this in you case?

caryoscelus commented 7 years ago

That fixed it, yeah. Thanks.