summary refs log tree commit diff
path: root/src/ui
diff options
context:
space:
mode:
authorKonstantinos Sideris <sideris.konstantin@gmail.com>2017-07-15 17:11:46 +0300
committerKonstantinos Sideris <sideris.konstantin@gmail.com>2017-07-15 17:11:46 +0300
commit30fb46e25b5a2eaeb66f68c9488c5784ed64190d (patch)
tree0091ac126af6168907798fc41b150f1bd5942d9f /src/ui
parentLinting (diff)
downloadnheko-30fb46e25b5a2eaeb66f68c9488c5784ed64190d.tar.xz
Use pixels to specify the font sizes
Basically reverts the last font related commits since pointSize isn't
as reliable as pixelSize.

Also some layout values (margins, spacings) have been moved out to Config.h.
Diffstat (limited to 'src/ui')
-rw-r--r--src/ui/FlatButton.cc2
-rw-r--r--src/ui/TextField.cc2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/ui/FlatButton.cc b/src/ui/FlatButton.cc
index 183b2294..7526ba9c 100644
--- a/src/ui/FlatButton.cc
+++ b/src/ui/FlatButton.cc
@@ -189,7 +189,7 @@ void FlatButton::setFontSize(qreal size)
 	font_size_ = size;
 
 	QFont f(font());
-	f.setPointSizeF(size);
+	f.setPixelSize(size);
 	setFont(f);
 
 	update();
diff --git a/src/ui/TextField.cc b/src/ui/TextField.cc
index a93d801d..fea808bb 100644
--- a/src/ui/TextField.cc
+++ b/src/ui/TextField.cc
@@ -74,7 +74,7 @@ void TextField::setLabelFontSize(qreal size)
 
 	if (label_) {
 		QFont font(label_->font());
-		font.setPointSizeF(size);
+		font.setPixelSize(size);
 		label_->setFont(font);
 		label_->update();
 	}