|
Canorus
0.7
|
Instrument change during the score. More...
#include <instrumentchange.h>

Public Member Functions | |
| CAInstrumentChange (int instrument, CANote *note) | |
| virtual | ~CAInstrumentChange () |
| CAInstrumentChange * | clone (CAMusElement *elt=0) |
| int | compare (CAMusElement *) |
| const int | instrument () |
| void | setInstrument (const int instrument) |
Private Attributes | |
| int | _instrument |
Instrument change during the score.
Copyright (c) 2007, Matevž Jekovec, Canorus development team
All Rights Reserved. See AUTHORS for a complete list of authors.
Licensed under the GNU GENERAL PUBLIC LICENSE. See LICENSE.GPL for details.
This class is used to allow the playback to change the default voice instrument.| CAInstrumentChange::CAInstrumentChange | ( | int | instrument, |
| CANote * | note | ||
| ) |
References setInstrument().
Referenced by clone().


| CAInstrumentChange::~CAInstrumentChange | ( | ) | [virtual] |
| CAInstrumentChange * CAInstrumentChange::clone | ( | CAMusElement * | elt = 0 | ) | [virtual] |
Reimplemented from CAMark.
References CAInstrumentChange(), instrument(), CAMusElement::musElementType(), and CAMusElement::Note.

| int CAInstrumentChange::compare | ( | CAMusElement * | elt | ) | [virtual] |
Compares the music element with the given elt and returns number of differences in their properties. Returns 0, if the music elements are exact; -1 if the music element type differs; otherwise number greater than 0.
This method is usually used when opening a score document where music elements are written in various voices (eg. barlines), but are eventually merged and written only once per staff.
Reimplemented from CAMark.
References instrument(), CAMark::InstrumentChange, CAMusElement::Mark, and CAMusElement::musElementType().

| const int CAInstrumentChange::instrument | ( | ) | [inline] |
References _instrument.
Referenced by clone(), compare(), CACanorusMLExport::exportMarks(), setInstrument(), and CAMainWin::updateInstrumentToolBar().

| void CAInstrumentChange::setInstrument | ( | const int | instrument | ) | [inline] |
References _instrument, and instrument().
Referenced by CAInstrumentChange(), and CAMainWin::on_uiInstrumentChange_activated().


int CAInstrumentChange::_instrument [private] |
Referenced by instrument(), and setInstrument().
1.8.0