|
Canorus
0.7
|
Represents a single sheet of paper in the document. More...
#include <sheet.h>
Public Member Functions | |
| CASheet (const QString name, CADocument *doc) | |
| ~CASheet () | |
| CASheet * | clone (CADocument *doc) |
| CASheet * | clone () |
| CAContext * | contextAt (int i) |
| CAContext * | context (const QString name) |
| QList< CAContext * > & | contextList () |
| int | contextIndex (CAContext *context) |
| void | insertContextAfter (CAContext *after, CAContext *c) |
| void | addContext (CAContext *) |
| void | removeContext (CAContext *c) |
| int | contextCount () |
| CAStaff * | addStaff () |
| int | staffCount () |
| CAStaff * | staffAt (int i) |
| QList< CAStaff * > | staffList () |
| QList< CAVoice * > | voiceList () |
| CAVoice * | voiceAt (int i) |
| int | voiceCount () |
| QList< CAPlayable * > | getChord (int time) |
| CADocument * | document () |
| void | setDocument (CADocument *doc) |
| const QString | name () |
| void | setName (const QString name) |
| void | clear () |
Private Attributes | |
| QList< CAContext * > | _contextList |
| CADocument * | _document |
| QString | _name |
Represents a single sheet of paper in the document.
Copyright (c) 2006-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.
CASheet represents a sheet of paper for the composer. The idea was taken out from spreadsheet applications. Each sheet is usually in its own tab.
CASheet parent is CADocument and CASheet includes various contexts CAContext, let it be staffs, lyrics, function marks etc.
| CASheet::CASheet | ( | const QString | name, |
| CADocument * | doc | ||
| ) |
| CASheet::~CASheet | ( | ) |
| void CASheet::addContext | ( | CAContext * | c | ) |
References _contextList, and CAContext::setSheet().
Referenced by clone(), CAPropertiesDialog::createDocumentFromTree(), CAMainWin::pasteAt(), CAMusicXmlImport::readAttributes(), CACanorusMLImport::startElement(), and CAMidiImport::writeMidiFileEventsToScore().


| CAStaff * CASheet::addStaff | ( | ) |
Appends a new staff to the sheet with one empty voice.
References _contextList, CAStaff::addVoice(), and staffCount().
Referenced by CASettingsDialog::buildPreviewSheet().


| void CASheet::clear | ( | ) |
References _contextList.
| CASheet * CASheet::clone | ( | CADocument * | doc | ) |
Clones the current sheet with all its content. If a new parent document doc is given, it also sets the document.
References addContext(), CASheet(), CAContext::clone(), contextAt(), contextCount(), CAContext::contextType(), CAContext::LyricsContext, name(), CAVoice::removeLyricsContext(), CAContext::Staff, voiceAt(), and voiceCount().

|
inline |
References clone(), and document().
Referenced by clone().


| CASheet::context | ( | const QString | name | ) |
Returns the first context with the given name.
Looks up for the context with the given name.
References _contextList, and name().

|
inline |
Return the context with index i counting from 0.
References _contextList.
Referenced by CAPropertiesDialog::buildTree(), clone(), CAMusElementFactory::configureNote(), CAPropertiesDialog::createDocumentFromTree(), CACanorusMLExport::exportDocumentImpl(), CAMidiExport::exportDocumentImpl(), CALilyPondExport::exportScoreBlock(), CALilyPondExport::exportSheetImpl(), CAPlayback::initStreams(), CAMainWin::pasteAt(), CAEngraver::reposit(), and CAUndoCommand::undoDocument().

|
inline |
References _contextList.
Referenced by CATranspose::addSheet(), CAPropertiesDialog::buildTree(), clone(), CAMusElementFactory::configureNote(), CAMainWin::copySelection(), CAPropertiesDialog::createDocumentFromTree(), CACanorusMLExport::exportDocumentImpl(), CAMidiExport::exportDocumentImpl(), CALilyPondExport::exportScoreBlock(), CALilyPondExport::exportSheetImpl(), CAPlayback::initStreams(), CAMainWin::on_uiImportDocument_triggered(), CAMainWin::pasteAt(), CAEngraver::reposit(), CAMainWin::scoreViewPortMousePress(), CACanorusMLImport::startElement(), and CAUndoCommand::undoDocument().

|
inline |
References _contextList.
Referenced by CAMainWin::pasteAt().

|
inline |
References _contextList.
Referenced by CATranspose::addSheet(), CATranspose::CATranspose(), CAMainWin::copySelection(), and CAMainWin::pasteAt().

|
inline |
References _document.
Referenced by clone(), CAPropertiesDialog::contextProperties(), CAPropertiesDialog::sheetProperties(), and CAPropertiesDialog::voiceProperties().

| QList< CAPlayable * > CASheet::getChord | ( | int | time | ) |
Returns a list of notes and rests (chord) for all the voices in all the staffs in the given time slice time.
This is useful for determination of the harmony at certain point in time.
References CAStaff::getChord(), staffAt(), and staffCount().
Referenced by CAMainWin::insertMusElementAt(), and CAFunctionMarkContext::repositFunctions().


References _contextList.
Referenced by CAMainWin::pasteAt(), CAMusicXmlImport::readNote(), CAMainWin::scoreViewPortMousePress(), and CAMainWin::sourceViewPortCommit().

|
inline |
References _name.
Referenced by CAMainWin::addSheet(), CAPropertiesDialog::buildTree(), CASheet(), clone(), context(), CACanorusMLExport::exportDocumentImpl(), setName(), and CAMainWin::updateSheetToolBar().

|
inline |
References _contextList.
Referenced by CAPropertiesDialog::createDocumentFromTree(), CAMainWin::on_uiRemoveContext_triggered(), and CAMainWin::sourceViewPortCommit().

|
inline |
References _document.
Referenced by CADocument::addSheet().

|
inline |
Referenced by CAMainWin::on_uiSheetName_returnPressed().


| CAStaff * CASheet::staffAt | ( | int | i | ) |
References _contextList, and CAContext::Staff.
Referenced by CASettingsDialog::buildPreviewSheet(), CACanorusMLImport::endElement(), getChord(), CASettingsDialog::setupPages(), and voiceList().

| int CASheet::staffCount | ( | ) |
References _contextList, and CAContext::Staff.
Referenced by addStaff(), CACanorusMLImport::endElement(), getChord(), CAMainWin::pasteAt(), CAMusicXmlImport::readAttributes(), CAMainWin::scoreViewPortMousePress(), CACanorusMLImport::startElement(), and voiceList().

| QList< CAStaff * > CASheet::staffList | ( | ) |
References _contextList, and CAContext::Staff.
Referenced by CATransposeView::show(), and CAMidiImport::writeMidiFileEventsToScore().

|
inline |
References voiceList().
Referenced by clone(), and CAUndoCommand::undoDocument().


|
inline |
References voiceList().
Referenced by clone(), and CAUndoCommand::undoDocument().


| QList< CAVoice * > CASheet::voiceList | ( | ) |
Returns the list of all the voices in the sheets staffs.
References staffAt(), staffCount(), and CAStaff::voiceList().
Referenced by CACanorusMLImport::endElement(), CACanorusMLExport::exportDocumentImpl(), CAMidiDevice::freeMidiChannel(), CAMainWin::on_uiAssociatedVoice_activated(), CAMainWin::scoreViewPortMousePress(), CAMainWin::updateContextToolBar(), voiceAt(), and voiceCount().


|
private |
List of all the contexts in the sheet (lyrics, staffs, tablatures, general-bas marks etc.).
Referenced by addContext(), addStaff(), clear(), context(), contextAt(), contextCount(), contextIndex(), contextList(), insertContextAfter(), removeContext(), staffAt(), staffCount(), and staffList().
|
private |
Referenced by CASheet(), document(), and setDocument().
1.8.3