Added antialiasing

This commit is contained in:
Borna Rajković 2022-06-12 13:43:35 +02:00
parent 6dfe86335d
commit e6bbaabde4
2 changed files with 3 additions and 1 deletions

View File

@ -95,7 +95,7 @@ namespace display {
} }
} }
} }
} else { } else if(!pinConnections.empty()) {
auto pinConnection = pinConnections[0]; auto pinConnection = pinConnections[0];
if(auto busConnection = dynamic_cast<domain::BusConnectionInstance*>(pinConnection)) { if(auto busConnection = dynamic_cast<domain::BusConnectionInstance*>(pinConnection)) {
menu.addSection(QString::fromStdString(busConnection->bus->name)); menu.addSection(QString::fromStdString(busConnection->bus->name));

View File

@ -13,6 +13,8 @@ namespace display {
Schema::Schema() { Schema::Schema() {
schema = nullptr; schema = nullptr;
library = std::nullopt; library = std::nullopt;
setRenderHint(QPainter::Antialiasing);
setAlignment(Qt::AlignCenter);
this->setScene(&scene); this->setScene(&scene);
this->setAcceptDrops(true); this->setAcceptDrops(true);
} }