MCPcopy Create free account
hub / github.com/computationalpathologygroup/ASAP / getToolButton

Method getToolButton

ASAP/annotation/PolyAnnotationTool.cpp:92–105  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

90}
91
92QAction* PolyAnnotationTool::getToolButton() {
93 if (!_button) {
94 _button = new QAction("&PolyAnnotation", this);
95 _button->setObjectName(QString::fromStdString(name()));
96 if (QApplication::styleHints()->colorScheme() == Qt::ColorScheme::Dark) {
97 _button->setIcon(QIcon(QPixmap(":/AnnotationWorkstationExtensionPlugin_icons/poly_dark.png")));
98 }
99 else {
100 _button->setIcon(QIcon(QPixmap(":/AnnotationWorkstationExtensionPlugin_icons/poly.png")));
101 }
102 _button->setShortcut(QKeySequence("p"));
103 }
104 return _button;
105}
106
107std::string PolyAnnotationTool::name() {
108 return std::string("polyannotation");

Callers

nothing calls this directly

Calls 1

QPixmapClass · 0.50

Tested by

no test coverage detected