Merge pull request #66 from diizy/stable-0.4

UI changes so far
This commit is contained in:
Tobias Doerffel
2014-01-19 02:55:42 -08:00
22 changed files with 108 additions and 88 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 457 B

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 449 B

After

Width:  |  Height:  |  Size: 780 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 747 B

After

Width:  |  Height:  |  Size: 3.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 721 B

After

Width:  |  Height:  |  Size: 228 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 736 B

After

Width:  |  Height:  |  Size: 337 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 610 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.4 KiB

After

Width:  |  Height:  |  Size: 692 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 736 B

After

Width:  |  Height:  |  Size: 244 B

View File

@@ -13,6 +13,17 @@ AutomationEditor {
}
QLineEdit {
border-radius: 4px;
border: 2px inset rgba(91,101,113,128);
background: #49515b;
color: #e0e0e0;
}
QLineEdit:focus {
border: 1px solid rgba(0,0,0, 128);
}
QToolTip {
border-radius: 4px;
@@ -91,11 +102,10 @@ trackOperationsWidget > QPushButton {
max-width: 26px;
min-height: 26px;
min-width: 26px;
background-color: #c9c9c9;
border-radius: 2px;
border: 1px solid rgba(0,0,0,64);
background: none;
border:none;
}
/*
trackOperationsWidget > QPushButton:hover {
background: qlineargradient(spread:reflect, x1:0.5, y1:0.5, x2:0.5, y2:0, stop:0 rgba(224, 224, 224, 255), stop:1 rgba(201, 201, 201, 255));
border: 1px solid rgba(0,0,0,255);
@@ -113,23 +123,27 @@ trackOperationsWidget > QPushButton:flat {
border-radius: 2px;
border: none;
}
trackOperationsWidget#automationDisabled > QPushButton::menu-indicator {
image: url(resources:track_op_menu_disabled.png);
}
trackOperationsWidget#automationEnabled > QPushButton::menu-indicator {
image: url(resources:track_op_menu.png);
}
*/
trackOperationsWidget > QPushButton::menu-indicator {
subcontrol-origin: padding;
subcontrol-position: center;
image: url(resources:trackop.png);
subcontrol-origin: padding;
subcontrol-position: center;
position: relative;
top: 2px;
}
trackOperationsWidget > QPushButton::menu-indicator:pressed {
position: relative;
top: 1px;
trackOperationsWidget > QPushButton::menu-indicator:hover {
image: url(resources:trackop_h.png);
}
trackOperationsWidget > QPushButton::menu-indicator:pressed,
trackOperationsWidget > QPushButton::menu-indicator:checked
{
image: url(resources:trackop_c.png);
position: relative;
top: 3px;
}
trackWidget {
@@ -150,81 +164,78 @@ QToolBar {
}
QToolButton, toolButton {
padding: 2px 1px 1px 2px;
padding: 1px 1px 1px 1px;
border-radius: 2px;
border: 1px solid rgba(0,0,0,64);
background: qradialgradient(cx:0.3, cy:0.3, radius:0.8, fx:0.3, fy:0.3, stop:0 #c9c9c9, stop:0.5 #c0c0c0, stop:1 #747474 );
border: 1px solid rgba(0,0,0,32);
background: qradialgradient(cx:0.3, cy:0.3, radius:0.8, fx:0.3, fy:0.3, stop:0 #c9c9c9, stop:1 #969696 );
font-size:10px;
color: black;
}
QToolButton:hover, toolButton:hover {
background: qradialgradient(cx:0.3, cy:0.3, radius:0.8, fx:0.3, fy:0.3, stop:0 #e0e0e0, stop:0.5 #c9c9c9, stop:1 #747474 );
border: 1px solid rgba(0,0,0,255);
background: qradialgradient(cx:0.3, cy:0.3, radius:0.8, fx:0.3, fy:0.3, stop:0 #e0e0e0, stop:0.5 #c9c9c9, stop:1 #969696 );
border: 1px solid rgba(0,0,0,128);
color: white;
}
QToolButton:pressed, ToolButton:pressed {
background: qradialgradient(cx:0.3, cy:0.3, radius:0.8, fx:0.3, fy:0.3, stop:0 #c9c9c9, stop:0.5 #c0c0c0, stop:1 #747474 );
padding: 3px 1px 0px 2px;
border: 1px solid rgba(0,0,0,255);
QToolButton:pressed, toolButton:pressed {
background: qlineargradient(x1:0, y1:0, x2:0, y2:1, stop:0 #969696, stop:0.5 #c9c9c9, stop:1 #969696 );
padding: 2px 1px 0px 1px;
border: 1px solid rgba(0,0,0,128);
color: white;
}
QToolButton:checked, ToolButton:checked {
QToolButton:checked, toolButton:checked {
background: qradialgradient(cx:0.3, cy:0.3, radius:0.8, fx:0.3, fy:0.3, stop:0 #e0e0e0, stop:0.8 #c9c9c9, stop:1 #c0c0c0 );
border-radius: 3px;
padding: 3px 1px 0px 2px;
padding: 2px 1px 0px 1px;
border: 1px solid rgba(0,0,0,255);
color: black;
}
trackLabelButton {
background-color: #5b6571;
color: #c9c9c9;
font-size: 10px;
font-weight: normal;
border-radius: 1px;
border: 1px solid rgba(0,0,0,64);
background-color: #5b6571;
color: #c9c9c9;
font-size: 10px;
font-weight: normal;
border-radius: 1px;
border: none;
padding: 2px 1px;
}
trackLabelButton:hover {
background-color: #7b838d;
color: white;
border: 1px solid black;
background-color: qlineargradient(spread:reflect, x1:0, y1:0, x2:0, y2:0.5, stop:0 #5b6571, stop:0.75 #7b838d, stop:1 #7b838d );
color: white;
border: 1px solid rgba(0,0,0,64);
padding: 1px 0px;
}
trackLabelButton:pressed {
background: qlineargradient(spread:reflect, x1:0.5, y1:0, x2:0.5, y2:1, stop:0 #49515b, stop:0.5 #5b6571, stop:1 #6b7581 );
background: qlineargradient(spread:reflect, x1:0.5, y1:0, x2:0.5, y2:1, stop:0 #49515b, stop:0.3 #5b6571, stop:1 #6b7581 );
color: white;
border: 1px solid black;
border: 1px solid rgba(0,0,0,64);
padding: 2px 0px 0px;
font-weight: bold;
}
trackLabelButton:checked {
background: qlineargradient(spread:reflect, x1:0.5, y1:0, x2:0.5, y2:1, stop:0 #49515b, stop:0.5 #5b6571, stop:1 #6b7581 );
color: #c9c9c9;
border: 1px solid rgba(0,0,0,64);
background: qlineargradient(spread:reflect, x1:0.5, y1:0, x2:0.5, y2:1, stop:0 #49515b, stop:0.3 #5b6571, stop:1 #6b7581 );
color: white;
border: 1px solid rgba(0,0,0,128);
padding: 2px 0px 0px;
font-weight: bold;
}
trackLabelButton:checked:hover {
background-color: #7b838d;
color: white;
border: 1px solid black;
font-weight: bold;
background-color: qlineargradient(spread:reflect, x1:0, y1:0, x2:0, y2:0.5, stop:0 #5b6571, stop:0.75 #7b838d, stop:1 #7b838d );
}
trackLabelButton:checked:pressed {
background: qlineargradient(spread:reflect, x1:0.5, y1:0, x2:0.5, y2:1, stop:0 #49515b, stop:0.5 #5b6571, stop:1 #6b7581 );
color: white;
border: 1px solid black;
font-weight: bold;
background: qlineargradient(spread:reflect, x1:0.5, y1:0, x2:0.5, y2:1, stop:0 #49515b, stop:0.3 #5b6571, stop:1 #6b7581 );
}
SideBar {
background: qlineargradient(x1:0, y1:0, x2:1, y2:0, stop: 0 #98a2a7, stop: 1.0 #5b646f);
}
@@ -311,11 +322,11 @@ sf2InstrumentView knob {
}
opl2instrumentView knob {
color: rgb(128,128,128);
qproperty-outerColor: rgb(255,255,255);
qproperty-innerRadius: 2;
qproperty-outerRadius: 9;
qproperty-lineWidth: 2;
color: rgb(128,128,128);
qproperty-outerColor: rgb(255,255,255);
qproperty-innerRadius: 2;
qproperty-outerRadius: 9;
qproperty-lineWidth: 2;
}
/* palette information - each colour definition must be on a single line, and the line must begin with "palette:", with no leading whitespace
@@ -329,7 +340,7 @@ palette:button {color: #c9c9c9}
palette:shadow {color: #000000}
palette:buttontext {color: #000000}
palette:brighttext {color: #4afd85}
palette:highlight {color: #303030}
palette:highlight {color: #202020}
palette:highlightedtext {color: #ffffff}
/* Notes:

Binary file not shown.

After

Width:  |  Height:  |  Size: 746 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 787 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 746 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 82 KiB

After

Width:  |  Height:  |  Size: 113 KiB

View File

@@ -803,34 +803,34 @@ lb302SynthView::lb302SynthView( Instrument * _instrument, QWidget * _parent ) :
m_vcfCutKnob = new knob( knobBright_26, this );
m_vcfCutKnob->move( 75, 130 );
m_vcfCutKnob->setHintText( tr( "Cutoff Freq:" ) + " ", "" );
m_vcfCutKnob->setLabel( tr("CUT") );
m_vcfCutKnob->setLabel( "" );
m_vcfResKnob = new knob( knobBright_26, this );
m_vcfResKnob->move( 120, 130 );
m_vcfResKnob->setHintText( tr( "Resonance:" ) + " ", "" );
m_vcfResKnob->setLabel( tr("RES") );
m_vcfResKnob->setLabel( "" );
m_vcfModKnob = new knob( knobBright_26, this );
m_vcfModKnob->move( 165, 130 );
m_vcfModKnob->setHintText( tr( "Env Mod:" ) + " ", "" );
m_vcfModKnob->setLabel( tr("ENV MOD") );
m_vcfModKnob->setLabel( "" );
m_vcfDecKnob = new knob( knobBright_26, this );
m_vcfDecKnob->move( 210, 130 );
m_vcfDecKnob->setHintText( tr( "Decay:" ) + " ", "" );
m_vcfDecKnob->setLabel( tr("DEC") );
m_vcfDecKnob->setLabel( "" );
m_slideToggle = new ledCheckBox( "Slide", this );
m_slideToggle = new ledCheckBox( "", this );
m_slideToggle->move( 10, 180 );
m_accentToggle = new ledCheckBox( "Accent", this );
m_accentToggle = new ledCheckBox( "", this );
m_accentToggle->move( 10, 200 );
m_accentToggle->setDisabled(true);
m_deadToggle = new ledCheckBox( "Dead", this );
m_deadToggle = new ledCheckBox( "", this );
m_deadToggle->move( 10, 220 );
m_db24Toggle = new ledCheckBox( "24dB/oct", this );
m_db24Toggle = new ledCheckBox( "", this );
m_db24Toggle->setWhatsThis(
tr( "303-es-que, 24dB/octave, 3 pole filter" ) );
m_db24Toggle->move( 10, 150);
@@ -839,12 +839,12 @@ lb302SynthView::lb302SynthView( Instrument * _instrument, QWidget * _parent ) :
m_slideDecKnob = new knob( knobBright_26, this );
m_slideDecKnob->move( 210, 75 );
m_slideDecKnob->setHintText( tr( "Slide Decay:" ) + " ", "" );
m_slideDecKnob->setLabel( tr( "SLIDE"));
m_slideDecKnob->setLabel( "");
m_distKnob = new knob( knobBright_26, this );
m_distKnob->move( 210, 190 );
m_distKnob->setHintText( tr( "DIST:" ) + " ", "" );
m_distKnob->setLabel( tr( "DIST"));
m_distKnob->setLabel( tr( ""));
// Shapes

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.4 KiB

After

Width:  |  Height:  |  Size: 2.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 83 KiB

After

Width:  |  Height:  |  Size: 112 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 285 B

After

Width:  |  Height:  |  Size: 2.4 KiB

View File

@@ -214,6 +214,7 @@ static QString getCacheKey( const QString & _key,
}
LmmsStyle::LmmsStyle() :
QPlastiqueStyle()
{
@@ -229,8 +230,12 @@ LmmsStyle::LmmsStyle() :
QPalette LmmsStyle::standardPalette( void ) const
{
QPalette pal = QPlastiqueStyle::standardPalette();
/* pal.setColor( QPalette::Background, QColor( 91, 101, 113 ) );
/* sane defaults in case fetching from stylesheet fails*/
pal.setColor( QPalette::Background, QColor( 91, 101, 113 ) );
pal.setColor( QPalette::WindowText, QColor( 240, 240, 240 ) );
pal.setColor( QPalette::Base, QColor( 128, 128, 128 ) );
pal.setColor( QPalette::Text, QColor( 224, 224, 224 ) );
@@ -239,21 +244,23 @@ QPalette LmmsStyle::standardPalette( void ) const
pal.setColor( QPalette::ButtonText, QColor( 0, 0, 0 ) );
pal.setColor( QPalette::BrightText, QColor( 74, 253, 133 ) );
pal.setColor( QPalette::Highlight, QColor( 100, 100, 100 ) );
pal.setColor( QPalette::HighlightedText, QColor( 255, 255, 255 ) );*/
pal.setColor( QPalette::HighlightedText, QColor( 255, 255, 255 ) );
/* fetch from stylesheet using regexp */
QStringList paletteData = qApp->styleSheet().split( '\n' ).filter( QRegExp( "^palette:*" ) );
foreach( QString s, paletteData )
{
if (s.contains("background")) { pal.setColor( QPalette::Background, QColor( s.mid( s.indexOf("#"), 7 ) ) ); }
else if (s.contains("windowtext")) { pal.setColor( QPalette::WindowText, QColor( s.mid( s.indexOf("#"), 7 ) ) ); }
else if (s.contains("base")) { pal.setColor( QPalette::Base, QColor( s.mid( s.indexOf("#"), 7 ) ) ); }
else if (s.contains("buttontext")) { pal.setColor( QPalette::ButtonText, QColor( s.mid( s.indexOf("#"), 7 ) ) ); }
else if (s.contains("brighttext")) { pal.setColor( QPalette::BrightText, QColor( s.mid( s.indexOf("#"), 7 ) ) ); }
else if (s.contains("text")) { pal.setColor( QPalette::Text, QColor( s.mid( s.indexOf("#"), 7 ) ) ); }
else if (s.contains("button")) { pal.setColor( QPalette::Button, QColor( s.mid( s.indexOf("#"), 7 ) ) ); }
else if (s.contains("shadow")) { pal.setColor( QPalette::Shadow, QColor( s.mid( s.indexOf("#"), 7 ) ) ); }
else if (s.contains("highlightedtext")) { pal.setColor( QPalette::HighlightedText, QColor( s.mid( s.indexOf("#"), 7 ) ) ); }
else if (s.contains("highlight")) { pal.setColor( QPalette::Highlight, QColor( s.mid( s.indexOf("#"), 7 ) ) ); };
if (s.contains(":background")) { pal.setColor( QPalette::Background, QColor( s.mid( s.indexOf("#"), 7 ) ) ); }
else if (s.contains(":windowtext")) { pal.setColor( QPalette::WindowText, QColor( s.mid( s.indexOf("#"), 7 ) ) ); }
else if (s.contains(":base")) { pal.setColor( QPalette::Base, QColor( s.mid( s.indexOf("#"), 7 ) ) ); }
else if (s.contains(":buttontext")) { pal.setColor( QPalette::ButtonText, QColor( s.mid( s.indexOf("#"), 7 ) ) ); }
else if (s.contains(":brighttext")) { pal.setColor( QPalette::BrightText, QColor( s.mid( s.indexOf("#"), 7 ) ) ); }
else if (s.contains(":text")) { pal.setColor( QPalette::Text, QColor( s.mid( s.indexOf("#"), 7 ) ) ); }
else if (s.contains(":button")) { pal.setColor( QPalette::Button, QColor( s.mid( s.indexOf("#"), 7 ) ) ); }
else if (s.contains(":shadow")) { pal.setColor( QPalette::Shadow, QColor( s.mid( s.indexOf("#"), 7 ) ) ); }
else if (s.contains(":highlightedtext")) { pal.setColor( QPalette::HighlightedText, QColor( s.mid( s.indexOf("#"), 7 ) ) ); }
else if (s.contains(":highlight")) { pal.setColor( QPalette::Highlight, QColor( s.mid( s.indexOf("#"), 7 ) ) ); };
}
return( pal );

View File

@@ -252,7 +252,7 @@ songEditor::songEditor( song * _song, songEditor * & _engine_ptr ) :
// fill own tool-bar
m_playButton = new toolButton( embed::getIconPixmap( "play", 24, 24 ),
m_playButton = new toolButton( embed::getIconPixmap( "play" ),
tr( "Play song (Space)" ),
this, SLOT( play() ), m_toolBar );
@@ -275,7 +275,7 @@ songEditor::songEditor( song * _song, songEditor * & _engine_ptr ) :
m_recordAccompanyButton->setDisabled( true );
}
m_stopButton = new toolButton( embed::getIconPixmap( "stop", 24, 24 ),
m_stopButton = new toolButton( embed::getIconPixmap( "stop" ),
tr( "Stop song (Space)" ),
this, SLOT( stop() ), m_toolBar );

View File

@@ -99,10 +99,10 @@ void fadeButton::paintEvent( QPaintEvent * _pe )
int w = rect().right();
int h = rect().bottom();
p.setPen( QColor( 37, 39, 46 ) );
p.setPen( m_normalColor.darker(130) );
p.drawLine( w, 1, w, h );
p.drawLine( 1, h, w, h );
p.setPen( QColor( 145, 147, 154 ) );
p.setPen( m_normalColor.lighter(130) );
p.drawLine( 0, 0, 0, h-1 );
p.drawLine( 0, 0, w, 0 );
}

View File

@@ -290,7 +290,7 @@ void fader::paintEvent( QPaintEvent * ev)
if( m_persistentPeak_L > 0.05 )
{
painter.fillRect( QRect( 2, persistentPeak_L, 4, 1 ), (m_persistentPeak_L < 1.0 )? QColor( 0, 200, 0) : QColor( 200, 0, 0));
painter.fillRect( QRect( 2, persistentPeak_L, 4, 1 ), (m_persistentPeak_L < 1.0 )? QColor( 74, 253, 133) : QColor( 255, 100, 100));
}
int peak_R = calculateDisplayPeak( m_fPeakValue_R - m_fMinPeak );
@@ -299,11 +299,11 @@ void fader::paintEvent( QPaintEvent * ev)
if( m_persistentPeak_R > 0.05 )
{
painter.fillRect( QRect( 16, persistentPeak_R, 4, 1 ), (m_persistentPeak_R < 1.0 )? QColor( 0, 200, 0) : QColor( 200, 0, 0));
painter.fillRect( QRect( 16, persistentPeak_R, 4, 1 ), (m_persistentPeak_R < 1.0 )? QColor( 74, 253, 133) : QColor( 255, 100, 100));
}
// knob
painter.drawPixmap( 4, knobPosY() - m_knob.height(), m_knob );
painter.drawPixmap( 0, knobPosY() - m_knob.height(), m_knob );
}

View File

@@ -1007,8 +1007,10 @@ InstrumentTrackView::InstrumentTrackView( InstrumentTrack * _it, TrackContainerV
m_midiInputAction->setText( tr( "Input" ) );
m_midiOutputAction->setText( tr( "Output" ) );
m_activityIndicator = new fadeButton( QColor( 56, 60, 72 ),
QColor( 64, 255, 16 ),
m_activityIndicator = new fadeButton( QApplication::palette().color( QPalette::Active,
QPalette::Background),
QApplication::palette().color( QPalette::Active,
QPalette::BrightText ),
getTrackSettingsWidget() );
m_activityIndicator->setGeometry(
widgetWidth-2*24-11, 2, 8, 28 );