mirror of
https://github.com/qelectrotech/qelectrotech-source-mirror.git
synced 2026-06-29 21:24:13 +02:00
f55ba568f6
saveConfig() serialises Qt::AlignHCenter as the string "AlignHCenter" via QMetaEnum::valueToKey(), but loadConfig() matched against Qt::AlignCenter (0x0084 = AlignHCenter|AlignVCenter) instead of Qt::AlignHCenter (0x0004). The two values differ, so the switch fell through to the default (Right) every time center was saved and reloaded. Add Qt::AlignHCenter as the primary case and keep Qt::AlignCenter as a fallthrough for any config files that were hand-edited by users following the workaround documented in issue #283. Verified with a standalone Qt test: QMetaEnum::keyToValue("AlignHCenter") returns 4 (AlignHCenter), which now correctly resolves to combobox index 1 (Center) instead of 2 (Right). Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>