updated background image

git-svn-id: https://lmms.svn.sf.net/svnroot/lmms/trunk/lmms@54 0778d3d1-df1d-0410-868b-ea421aaaa00d
This commit is contained in:
Andreas Brandmaier
2006-01-22 12:05:02 +00:00
parent 1f275d562e
commit a0b758887e
3 changed files with 8 additions and 8 deletions

View File

@@ -219,10 +219,10 @@ bitInvader::bitInvader( channelTrack * _channel_track ) :
emit( sinWaveClicked() );
m_graph = new graph( "", this );
m_graph->move(55,120);
m_graph->move(53,118); // 55,120 - 2px border
m_graph->setSamplePointer( sample_shape, sample_length );
QPixmap p = PLUGIN_NAME::getIconPixmap("wavegraph") ;
QPixmap p = PLUGIN_NAME::getIconPixmap("wavegraph3") ;
m_graph->setBackground( p );

View File

@@ -52,7 +52,7 @@ graph::graph( const QString & _text, QWidget * _parent) :
m_background = NULL;
setFixedSize( 128, 101 );
setFixedSize( 132, 104 );
@@ -149,17 +149,17 @@ void graph::paintEvent( QPaintEvent * )
p.setPen( QColor( 0xFF, 0xAA, 0x00 ) );
p.drawLine( sampleLength, 0, sampleLength, 100);
p.drawLine( 1+sampleLength, 2, 1+sampleLength, 102);
// float xscale = 200.0 / sampleLength;
float xscale = 1.0;
for (int i=0; i < sampleLength-1; i++)
{
p.drawLine(static_cast<int>(i*xscale),
static_cast<int>(-samplePointer[i]*50) + 50,
static_cast<int>((i+1)*xscale),
static_cast<int>(-samplePointer[i+1]*50 + 50)
p.drawLine(2+static_cast<int>(i*xscale),
2+static_cast<int>(-samplePointer[i]*50) + 50,
2+static_cast<int>((i+1)*xscale),
2+static_cast<int>(-samplePointer[i+1]*50 + 50)
);
}

Binary file not shown.