| 90 | } |
| 91 | |
| 92 | void ReferenceLine::initActions() { |
| 93 | // Orientation |
| 94 | auto* orientationActionGroup = new QActionGroup(this); |
| 95 | orientationActionGroup->setExclusive(true); |
| 96 | connect(orientationActionGroup, &QActionGroup::triggered, this, &ReferenceLine::orientationChangedSlot); |
| 97 | |
| 98 | orientationHorizontalAction = new QAction(QIcon::fromTheme(QStringLiteral("labplot-axis-horizontal")), i18n("Horizontal"), orientationActionGroup); |
| 99 | orientationHorizontalAction->setCheckable(true); |
| 100 | |
| 101 | orientationVerticalAction = new QAction(QIcon::fromTheme(QStringLiteral("labplot-axis-vertical")), i18n("Vertical"), orientationActionGroup); |
| 102 | orientationVerticalAction->setCheckable(true); |
| 103 | |
| 104 | // Line |
| 105 | lineStyleActionGroup = new QActionGroup(this); |
| 106 | lineStyleActionGroup->setExclusive(true); |
| 107 | connect(lineStyleActionGroup, &QActionGroup::triggered, this, &ReferenceLine::lineStyleChanged); |
| 108 | |
| 109 | lineColorActionGroup = new QActionGroup(this); |
| 110 | lineColorActionGroup->setExclusive(true); |
| 111 | connect(lineColorActionGroup, &QActionGroup::triggered, this, &ReferenceLine::lineColorChanged); |
| 112 | } |
| 113 | |
| 114 | void ReferenceLine::initMenus() { |
| 115 | this->initActions(); |