Skip to content

pqDoubleLineWidget HotFix

Hi all (especially @mwestphal, @charles.gueunet, and @timothee.chabat), this PR introduces a hotfix for the rendering issue of pqDoubleLineWidgets in the Node Editor. In short, this PR only changes the implementation file of the pqDoubleLineWidget class to perform upon construction a check if one of its parents is the widget container of a node (which can be done by comparing the objectName property of QWidgets). If the widget is a child of the container (if it is drawn in the node editor), then the widget will always use full precision for rendering (the simplified rendering is broken in the graphics framework which is the reason for this hotfix). Otherwise the widget will behave as before, so users will not notice any difference in the properties panel. Although the simplified notation will not be available in the node editor, I think it is much better to render the widget with full precision than nothing at all (which makes the editor seem broken). So I think this hotfix should be merged in before PV 5.10.

In the long run, the pqDoubleLineWidget class should inherit from QDoubleSpinBox instead of QLineEdit to implement the "simplified number representation" feature.

Merge request reports