diff options
Diffstat (limited to 'muse2')
-rw-r--r-- | muse2/muse/ctrl/ctrlcanvas.cpp | 2 | ||||
-rw-r--r-- | muse2/muse/midiedit/scoreedit.cpp | 11 | ||||
-rw-r--r-- | muse2/muse/midiedit/scoreedit.h | 5 |
3 files changed, 15 insertions, 3 deletions
diff --git a/muse2/muse/ctrl/ctrlcanvas.cpp b/muse2/muse/ctrl/ctrlcanvas.cpp index 64a17b4f..70d1ad63 100644 --- a/muse2/muse/ctrl/ctrlcanvas.cpp +++ b/muse2/muse/ctrl/ctrlcanvas.cpp @@ -2232,7 +2232,7 @@ QRect CtrlCanvas::overlayRect() const r.translate(2, y); if (noEvents) { - QRect r2(fm.boundingRect(QString("Use ctrlKey + pencil or line tool to draw new events"))); + QRect r2(fm.boundingRect(QString("Use shift + pencil or line tool to draw new events"))); //r2.translate(width()/2-100, height()/2-10); r2.translate(2, y * 2); r |= r2; diff --git a/muse2/muse/midiedit/scoreedit.cpp b/muse2/muse/midiedit/scoreedit.cpp index 9534abf9..c7170014 100644 --- a/muse2/muse/midiedit/scoreedit.cpp +++ b/muse2/muse/midiedit/scoreedit.cpp @@ -1145,6 +1145,11 @@ void ScoreCanvas::song_changed(int flags) redraw(); } + + if (flags & SC_SELECTION) + { + redraw(); + } } int ScoreCanvas::canvas_width() @@ -1223,6 +1228,7 @@ void ScoreCanvas::init_pixmaps() mycolors[i]=config.partColors[i]; mycolors[BLACK_PIXMAP]=Qt::black; mycolors[HIGHLIGHTED_PIXMAP]=Qt::red; + mycolors[SELECTED_PIXMAP]=QColor(255,160,0); for (int i=0; i<64; i++) mycolors[i+VELO_PIXMAP_BEGIN]=QColor(i*4,0,0xff); @@ -2698,9 +2704,14 @@ void ScoreCanvas::draw_items(QPainter& p, int y_offset, staff_t& staff, ScoreIte color_index=VELO_PIXMAP_BEGIN + it->source_event->velo(); break; } + + if (it->source_event->selected()) + color_index=SELECTED_PIXMAP; + if (audio->isPlaying() && it->is_active) color_index=HIGHLIGHTED_PIXMAP; + draw_pixmap(p,it->x -x_pos+x_left,y_offset + it->y,it->pix[color_index]); //draw dots diff --git a/muse2/muse/midiedit/scoreedit.h b/muse2/muse/midiedit/scoreedit.h index ed242aae..26687ea5 100644 --- a/muse2/muse/midiedit/scoreedit.h +++ b/muse2/muse/midiedit/scoreedit.h @@ -440,8 +440,9 @@ struct cumulative_t #define BLACK_PIXMAP (NUM_PARTCOLORS) #define HIGHLIGHTED_PIXMAP (NUM_PARTCOLORS+1) -#define NUM_MYCOLORS (NUM_PARTCOLORS+2 + 128) -#define VELO_PIXMAP_BEGIN (NUM_PARTCOLORS+2) +#define SELECTED_PIXMAP (NUM_PARTCOLORS+2) +#define NUM_MYCOLORS (NUM_PARTCOLORS+3 + 128) +#define VELO_PIXMAP_BEGIN (NUM_PARTCOLORS+3) struct timesig_t { |