Mercurial > hg > sonic-visualiser
changeset 1383:bf4f7a12fee0 more-hidpi
Scale the sizes of a few more UI elements
author | Chris Cannam |
---|---|
date | Mon, 05 Dec 2016 12:04:23 +0000 (2016-12-05) |
parents | a1e0ddadbf22 |
children | 56ebbbefdaf0 |
files | .hgsubstate main/MainWindow.cpp |
diffstat | 2 files changed, 11 insertions(+), 14 deletions(-) [+] |
line wrap: on
line diff
--- a/.hgsubstate Fri Dec 02 09:14:11 2016 +0000 +++ b/.hgsubstate Mon Dec 05 12:04:23 2016 +0000 @@ -9,5 +9,5 @@ 5f67a29f0fc7f1b908f7cde4866173a7af337862 sv-dependency-builds 0d5c3abc965812805053cc2b399b6696178a1cd9 svapp a421e752d22c71a9cd55db40a62f053f61d9ce57 svcore -db90fee630bc756c3c64a6f904b551acb13e000f svgui +3f5c82034f9b8b0eb71ff7343f7fedcfd098530a svgui 0eebd22a081a824067bf3d5de65326696feab653 vamp-plugin-sdk
--- a/main/MainWindow.cpp Fri Dec 02 09:14:11 2016 +0000 +++ b/main/MainWindow.cpp Mon Dec 05 12:04:23 2016 +0000 @@ -210,7 +210,7 @@ m_overview = new Overview(frame); m_overview->setViewManager(m_viewManager); - m_overview->setFixedHeight(40); + m_overview->setFixedHeight(m_viewManager->scalePixelSize(40)); #ifndef _WIN32 // For some reason, the contents of the overview never appear if we // make this setting on Windows. I have no inclination at the moment @@ -241,8 +241,8 @@ m_playSpeed->setMinimum(0); m_playSpeed->setMaximum(120); m_playSpeed->setValue(60); - m_playSpeed->setFixedWidth(32); - m_playSpeed->setFixedHeight(32); + m_playSpeed->setFixedWidth(m_viewManager->scalePixelSize(32)); + m_playSpeed->setFixedHeight(m_viewManager->scalePixelSize(32)); m_playSpeed->setNotchesVisible(true); m_playSpeed->setPageStep(10); m_playSpeed->setObjectName(tr("Playback Speed")); @@ -258,24 +258,21 @@ m_playControlsSpacer = new QFrame; - layout->setSpacing(4); - layout->addWidget(m_mainScroll, 0, 0, 1, 5); - layout->addWidget(m_overview, 1, 1); - layout->addWidget(m_playControlsSpacer, 1, 2); - layout->addWidget(m_playSpeed, 1, 3); - layout->addWidget(m_fader, 1, 4); + layout->setSpacing(m_viewManager->scalePixelSize(4)); + layout->addWidget(m_mainScroll, 0, 0, 1, 4); + layout->addWidget(m_overview, 1, 0); + layout->addWidget(m_playControlsSpacer, 1, 1); + layout->addWidget(m_playSpeed, 1, 2); + layout->addWidget(m_fader, 1, 3); m_playControlsWidth = m_fader->width() + m_playSpeed->width() + layout->spacing() * 2; - layout->setColumnMinimumWidth(0, 14); - layout->setColumnStretch(0, 0); - m_paneStack->setPropertyStackMinWidth(m_playControlsWidth + 2 + layout->spacing()); m_playControlsSpacer->setFixedSize(QSize(2, 2)); - layout->setColumnStretch(1, 10); + layout->setColumnStretch(0, 10); connect(m_paneStack, SIGNAL(propertyStacksResized(int)), this, SLOT(propertyStacksResized(int)));