Skip to content

Commit

Permalink
Don't draw note detuning info over the volume/panning area (LMMS#4965)
Browse files Browse the repository at this point in the history
  • Loading branch information
PhysSong authored May 5, 2019
1 parent 3a069da commit a4301de
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/gui/editors/PianoRoll.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -883,6 +883,9 @@ void PianoRoll::drawDetuningInfo( QPainter & _p, const Note * _n, int _x,
{
int middle_y = _y + KEY_LINE_HEIGHT / 2;
_p.setPen( noteColor() );
_p.setClipRect(WHITE_KEY_WIDTH, PR_TOP_MARGIN,
width() - WHITE_KEY_WIDTH,
keyAreaBottom() - PR_TOP_MARGIN);

int old_x = 0;
int old_y = 0;
Expand Down Expand Up @@ -3077,6 +3080,10 @@ void PianoRoll::paintEvent(QPaintEvent * pe )
}
}

p.setClipRect(WHITE_KEY_WIDTH, PR_TOP_MARGIN,
width() - WHITE_KEY_WIDTH,
height() - PR_TOP_MARGIN - PR_TOP_MARGIN);

p.setPen( QPen( noteColor(), NOTE_EDIT_LINE_WIDTH + 2 ) );
p.drawPoints( editHandles );

Expand Down

0 comments on commit a4301de

Please sign in to comment.