ra3xdh / qucs_s

Qucs-S is a circuit simulation program with Qt-based GUI
https://ra3xdh.github.io/
GNU General Public License v2.0
844 stars 109 forks source link

Fix #739: Restore QPainter state after paining the id_text element #740

Closed wawuwo closed 3 months ago

wawuwo commented 3 months ago

The 'paint' function of ID_text missed the restore() call on painter, which led to carrying the changes made to painter further down the call chain. In other words, the painter state after painting the ID_text wasn't the same as before doing it, and everything painted after the ID_text was affected by this change in painter's state.

This commit add missing restore() call.

Fixes: ra3xdh/qucs_s#739

ra3xdh commented 3 months ago

Thanks! Now everything works as expected on my side. Waiting for feedback from @tomhajjar

ra3xdh commented 3 months ago

Thanks for the fix! Merging.