QCAD Bugtracker

  • Status Closed
  • Percent Complete
    100%
  • Task Type Bug Report
  • Category ECMAScript
  • Assigned To
    Andrew
  • Operating System All
  • Severity Low
  • Priority Very Low
  • Reported Version 3.22.0
  • Due in Version Undecided
  • Due Date Undecided
  • Votes
  • Private
Attached to Project: QCAD Bugtracker
Opened by JieFK - 22.03.2019
Last edited by Andrew - 22.03.2019

FS#1862 - (Groups of) Radio Button does not remember its state.

Also, the way the state of radioButtons is saved on Qcad3.conf is rather confusing.

Exemple :
Two radioButtons _cr_i and _cr_x are in the same QWidget.
- check _cr_i
- validate the form with OK
- reopen the form, check _cr_x
- validate the form with OK

the config file reads

[_myPlenum2]
VisibleInMenu=true
...
_cr_i=_cr_i
_cr_x=_cr_x
...

On next form run, even if I select _cr_i, the radiobutton QWidget always takes the value of _cr_x.

Closed by  Andrew
22.03.2019 17:23
Reason for closing:  Not a bug
JieFK commented on 22.03.2019 17:02

If I can suggest a bug fix, I would save the state as this :

[_myPlenum2]
VisibleInMenu=true
...
_cr_i=enabled
_cr_x=disabled
...
Admin
Andrew commented on 22.03.2019 17:23

Radio buttons must be grouped in the same QGroupBox (visibe) or QButtonGroup (invisible).

The values are then stored as:
[Name of QGroupBox]=[Name of checked QRadioButton]
or
[Name of QButtonGroup]=[Name of checked QRadioButton]

See MirrorDialog for an example:
https://github.com/qcad/qcad/blob/master/scripts/Modify/Mirror/MirrorDialog.ui

Loading...

Available keyboard shortcuts

Tasklist

Task Details

Task Editing