From d74f59106aa7403287982789b469243d7aab3a62 Mon Sep 17 00:00:00 2001 From: Sergey Vartanov Date: Tue, 20 Aug 2024 02:00:58 +0400 Subject: [PATCH] Increase line width --- include/symbol.hpp | 9 +++++++-- src/symbol.cpp | 9 +++++---- 2 files changed, 12 insertions(+), 6 deletions(-) diff --git a/include/symbol.hpp b/include/symbol.hpp index 7ce07f1..c8572a2 100644 --- a/include/symbol.hpp +++ b/include/symbol.hpp @@ -6,7 +6,12 @@ #include "visual.hpp" -/* Describes a graphical element: how and where to draw it. */ +/* + * Describes a graphical element of a symbol. + * + * Graphical element is a horizontal, vertical or diagonal line, which can be + * a simple line, a curved line, a polyline, can be double or short. + */ enum class ElementDescriptor { // Direction. @@ -41,7 +46,7 @@ std::string sortParameters(std::string parameters); class SymbolStyle { public: - float lineWidth = 0.4f; + float lineWidth = 0.6f; Vector position = Vector(0, 0); bool useBackground = false; float zoom = 1.0f; diff --git a/src/symbol.cpp b/src/symbol.cpp index 547cf6c..28d7fae 100644 --- a/src/symbol.cpp +++ b/src/symbol.cpp @@ -332,12 +332,13 @@ void Element::draw( float size, std::vector elements) { - if (this->isDouble and position == 0) { - draw(painter, style, center, size, getNorm() * 0.3f, elements); - draw(painter, style, center, size, getNorm() * -1 * 0.3f, elements); + if (isDouble and position == 0) { + draw(painter, style, center, size, indirectedNorm * 0.4f, elements); + draw( + painter, style, center, size, indirectedNorm * -1 * 0.4f, elements); } else { draw(painter, style, center, size, getNorm() * 1.0f, elements); - if (this->isDouble) { + if (isDouble) { draw( painter, style,