#include <drawablecontext.h>

Public Types | |
| enum | CADrawableContextType { DrawableStaff, DrawableLyricsContext, DrawableFunctionMarkingContext } |
Public Member Functions | |
| CADrawableContext (CAContext *c, int x, int y) | |
| CAContext * | context () |
| CADrawableContextType | drawableContextType () |
| virtual void | addMElement (CADrawableMusElement *elt) |
| virtual int | removeMElement (CADrawableMusElement *elt) |
| CADrawableMusElement * | lastDrawableMusElement () |
| virtual CADrawableContext * | clone ()=0 |
| CADrawableMusElement * | findMElement (CAMusElement *elt) |
| QList < CADrawableMusElement * > | findInRange (int x1, int x2) |
Protected Member Functions | |
| void | setDrawableContextType (CADrawableContextType type) |
Protected Attributes | |
| CADrawableContextType | _drawableContextType |
| CAContext * | _context |
| QList < CADrawableMusElement * > | _drawableMusElementList |
Definition at line 18 of file drawablecontext.h.
Definition at line 20 of file drawablecontext.h.
| CADrawableContext::CADrawableContext | ( | CAContext * | c, | |
| int | x, | |||
| int | y | |||
| ) |
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 COPYING for details.
Definition at line 10 of file drawablecontext.cpp.
References _context, CADrawable::_drawableType, and CADrawable::DrawableContext.
| CAContext* CADrawableContext::context | ( | ) | [inline] |
Definition at line 27 of file drawablecontext.h.
References _context.
Referenced by CAMainWin::insertMusElementAt(), CADrawableLyricsContext::lyricsContext(), CAMainWin::onTextEditKeyPressEvent(), CAMainWin::pasteAt(), CAEngraver::reposit(), CAMainWin::scoreViewPortKeyPress(), and CAMainWin::scoreViewPortMousePress().

| CADrawableContextType CADrawableContext::drawableContextType | ( | ) | [inline] |
Definition at line 28 of file drawablecontext.h.
References _drawableContextType.
Referenced by CAScoreViewPort::addCElement(), CADrawableRest::CADrawableRest(), CAMainWin::pasteAt(), CAEngraver::reposit(), and CAMainWin::scoreViewPortMouseMove().

| virtual void CADrawableContext::addMElement | ( | CADrawableMusElement * | elt | ) | [inline, virtual] |
Reimplemented in CADrawableStaff.
Definition at line 29 of file drawablecontext.h.
References _drawableMusElementList, and CADrawable::xPos().
Referenced by CAScoreViewPort::addMElement().


| virtual int CADrawableContext::removeMElement | ( | CADrawableMusElement * | elt | ) | [inline, virtual] |
Reimplemented in CADrawableStaff.
Definition at line 34 of file drawablecontext.h.
References _drawableMusElementList.
Referenced by CAScoreViewPort::removeMElement().

| CADrawableMusElement* CADrawableContext::lastDrawableMusElement | ( | ) | [inline] |
| virtual CADrawableContext* CADrawableContext::clone | ( | ) | [pure virtual] |
Reimplemented from CADrawable.
Implemented in CADrawableFunctionMarkingContext, CADrawableLyricsContext, and CADrawableStaff.
Referenced by CAScoreViewPort::importCElements().

| CADrawableMusElement* CADrawableContext::findMElement | ( | CAMusElement * | elt | ) | [inline] |
Definition at line 38 of file drawablecontext.h.
References _drawableMusElementList.
Referenced by CAEngraver::reposit().

| QList< CADrawableMusElement * > CADrawableContext::findInRange | ( | int | x1, | |
| int | x2 | |||
| ) |
Returns a list of drawable music elements the current drawable context includes between the horizontal coordinates x1 and x2. The element is in a list already if only part of the element is touched by the region. That is the first returned element's left border is smaller than x1 and the last returned element's right border is larger than x2.
Definition at line 22 of file drawablecontext.cpp.
References _drawableMusElementList, CADrawable::width(), and CADrawable::xPos().

| void CADrawableContext::setDrawableContextType | ( | CADrawableContextType | type | ) | [inline, protected] |
Definition at line 48 of file drawablecontext.h.
References _drawableContextType.
Referenced by CADrawableLyricsContext::CADrawableLyricsContext().

Definition at line 50 of file drawablecontext.h.
Referenced by CADrawableFunctionMarkingContext::CADrawableFunctionMarkingContext(), CADrawableStaff::CADrawableStaff(), drawableContextType(), and setDrawableContextType().
CAContext* CADrawableContext::_context [protected] |
Definition at line 51 of file drawablecontext.h.
Referenced by CADrawableContext(), CADrawableFunctionMarkingContext::clone(), context(), and CADrawableStaff::staff().
QList<CADrawableMusElement *> CADrawableContext::_drawableMusElementList [protected] |
Definition at line 52 of file drawablecontext.h.
Referenced by CADrawableStaff::addMElement(), addMElement(), findInRange(), findMElement(), CADrawableStaff::getAccs(), lastDrawableMusElement(), CADrawableStaff::removeMElement(), and removeMElement().
1.5.3