ParaView crashes when selecting "Use Window Location" for Text Source position after a state load
If Text Source was saved with "AnyLocation" property set, switching it to "Use Window Location" in Display dock after a state load crashes ParaView.
Affected versions: 5.9.1, 5.10.1
One of the possible solutions (no crash):
//-----------------------------------------------------------------------------
void pqTextLocationWidget::radioButtonLocationClicked()
{
auto button = this->Internals->Ui.buttonGroupLocation->checkedButton();
// --- there can be no checked button after a state loaded
if (!button)
{
button = this->Internals->Ui.toolButtonUL;
button->setChecked(true);
}
QString locationStr(button->property("location").toString());
this->setWindowLocation(locationStr);
}
The other one is to set a default checked button in UI file. Did not tested that.