summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--muse2/ChangeLog6
-rw-r--r--muse2/muse/appearance.cpp2
-rw-r--r--muse2/muse/widgets/appearancebase.ui2
-rw-r--r--muse2/muse/widgets/bigtime.cpp27
4 files changed, 25 insertions, 12 deletions
diff --git a/muse2/ChangeLog b/muse2/ChangeLog
index 900ce3b5..9e678af3 100644
--- a/muse2/ChangeLog
+++ b/muse2/ChangeLog
@@ -1,3 +1,9 @@
+29.12.2010:
+ - Fixed Bigtime display when using a style sheet for MusE. (Tim)
+ Set window font using a style sheet. Bigtime used QFont::setPixelSize().
+ Application style sheets (even a blank one) override with the fixed application
+ font size (evidenced by adjusting MusE config font#0, then bigtime font size changed).
+ TODO: Darn, the tooltips fonts are as big as the labels! Must fix.
28.12.2010:
- Tweaked and added some delays during project load to counter threading
issues during loading of projects (rj)
diff --git a/muse2/muse/appearance.cpp b/muse2/muse/appearance.cpp
index db983cae..287001bd 100644
--- a/muse2/muse/appearance.cpp
+++ b/muse2/muse/appearance.cpp
@@ -108,7 +108,7 @@ Appearance::Appearance(Arranger* a, QWidget* parent)
fontName6->setToolTip(tr("Mixer label font. Auto-font-sizing up to chosen font size.\nWord-breaking but only with spaces."));
fontSize6->setToolTip(tr("Maximum mixer label auto-font-sizing font size."));
- globalAlphaSlider->setToolTip(tr("Global opaqueness (inverse of transparency)."));
+ globalAlphaSlider->setToolTip(tr("Global opacity (opposite of transparency)."));
// ARRANGER
diff --git a/muse2/muse/widgets/appearancebase.ui b/muse2/muse/widgets/appearancebase.ui
index 0a23b73c..67f1ea7c 100644
--- a/muse2/muse/widgets/appearancebase.ui
+++ b/muse2/muse/widgets/appearancebase.ui
@@ -734,7 +734,7 @@
</sizepolicy>
</property>
<property name="text">
- <string>Global opaqueness</string>
+ <string>Global opacity</string>
</property>
<property name="alignment">
<set>Qt::AlignCenter</set>
diff --git a/muse2/muse/widgets/bigtime.cpp b/muse2/muse/widgets/bigtime.cpp
index 6e49ee62..ba9defa9 100644
--- a/muse2/muse/widgets/bigtime.cpp
+++ b/muse2/muse/widgets/bigtime.cpp
@@ -66,12 +66,14 @@ BigTime::BigTime(QWidget* parent)
oldAbsTick = oldAbsFrame = -1;
setString(MAXINT);
+ dwin->setStyleSheet("font-size:10px; font-family:'Courier'; "); // Tim p4.0.8
+
configChanged();
- QFont f(QString("Courier"));
- f.setPixelSize(10);
+ //QFont f(QString("Courier"));
+ //f.setPixelSize(10);
+ //dwin->setFont(f);
- dwin->setFont(f);
setWindowTitle(tr("MusE: Bigtime"));
}
@@ -315,21 +317,26 @@ void BigTime::resizeEvent(QResizeEvent *ev)
//int tw = fm.width(QString("00:00:00:00"));
int tw = fm.width(QString("000:00:00:00"));
- int nfs = ((ev->size().width() - hspace*2)*fs) / tw;
+ fs = ((ev->size().width() - hspace*2)*fs) / tw;
// set min/max
- if (nfs < 10)
- nfs = 10;
- else if (nfs > 256)
- nfs = 256;
+ if (fs < 10)
+ fs = 10;
+ else if (fs > 256)
+ fs = 256;
//if(debugMsg)
// printf("resize BigTime: Font name:%s CurSize:%d NewSize:%d, NewWidth:%d\n",
// f.family().toLatin1().constData(), fs, nfs, ev->size().width());
- f.setPixelSize(nfs);
+ //f.setPixelSize(fs);
- dwin->setFont(f);
+ //dwin->setFont(f);
+ QString fstr = QString("font-size:%1px; font-family:'Courier'; ").arg(fs); // Tim p4.0.8
+ dwin->setStyleSheet(fstr);
+ setBgColor(config.bigTimeBackgroundColor);
+ setFgColor(config.bigTimeForegroundColor);
+
int digitWidth = dwin->fontMetrics().width(QString("0"));
int vspace = (ev->size().height() - (fs*2)) / 3;
int tickY = vspace;