Decreased the pin body widget sizes for the QFP target widget

Plan to correct the labelling later
This commit is contained in:
Nav
2021-10-23 12:45:39 +01:00
parent 56a3c7d6ce
commit f76e3d8a07
4 changed files with 10 additions and 11 deletions

View File

@@ -23,8 +23,8 @@ void BodyWidget::drawWidget(QPainter& painter) {
painter.setBrush(targetBodyColor); painter.setBrush(targetBodyColor);
const auto containerSize = this->size(); const auto containerSize = this->size();
auto targetBodyWidth = containerSize.width() - 16; auto targetBodyWidth = containerSize.width() - 14;
auto targetBodyHeight = containerSize.height() - 16; auto targetBodyHeight = containerSize.height() - 14;
auto targetBodyPoint = QPoint( auto targetBodyPoint = QPoint(
(containerSize.width() / 2) - (targetBodyWidth / 2), (containerSize.width() / 2) - (targetBodyWidth / 2),
@@ -42,7 +42,7 @@ void BodyWidget::drawWidget(QPainter& painter) {
painter.drawEllipse(QRectF( painter.drawEllipse(QRectF(
targetBodyPoint.x() + 13, targetBodyPoint.x() + 13,
targetBodyPoint.y() + 13, targetBodyPoint.y() + 13,
20, 18,
20 18
)); ));
} }

View File

@@ -15,8 +15,8 @@ namespace Bloom::Widgets::InsightTargetWidgets::Qfp
Q_OBJECT Q_OBJECT
public: public:
static const int WIDTH = 30; static const int WIDTH = 25;
static const int HEIGHT = 40; static const int HEIGHT = 34;
PinBodyWidget(QWidget* parent, Targets::TargetPinDescriptor pinDescriptor, bool isVertical): PinBodyWidget(QWidget* parent, Targets::TargetPinDescriptor pinDescriptor, bool isVertical):
TargetPinBodyWidget(parent, std::move(pinDescriptor)), isVertical(isVertical) { TargetPinBodyWidget(parent, std::move(pinDescriptor)), isVertical(isVertical) {

View File

@@ -16,7 +16,7 @@ namespace Bloom::Widgets::InsightTargetWidgets::Qfp
public: public:
static const int PIN_WIDGET_LAYOUT_PADDING = 46; static const int PIN_WIDGET_LAYOUT_PADDING = 46;
static const int WIDTH_SPACING = 8; static const int WIDTH_SPACING = 7;
static const int MAXIMUM_LABEL_COUNT = 3; static const int MAXIMUM_LABEL_COUNT = 3;
static const int LABEL_HEIGHT = 20; static const int LABEL_HEIGHT = 20;
static const int MAXIMUM_LABEL_WIDTH = PinBodyWidget::WIDTH; static const int MAXIMUM_LABEL_WIDTH = PinBodyWidget::WIDTH;

View File

@@ -1,10 +1,8 @@
#target-pin-number,
#target-pin-number { #target-pin-number {
font-size: 14px; font-size: 12px;
} }
#target-pin-name, #target-pin-name {
#target-pin-direction {
font-size: 11px; font-size: 11px;
} }
@@ -14,6 +12,7 @@
#target-pin-direction { #target-pin-direction {
color: #8a8a8d; color: #8a8a8d;
font-size: 10px;
} }
#target-pin-body { #target-pin-body {