Canorus  0.7
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Types | Public Member Functions | Private Attributes | List of all members
CADrawableFunctionMarkSupport Class Reference

Rectangles, key names, numbers below/above function, lines etc. Support class which draws the key of the function, rectangle around it, chord area, ellipse etc. These drawable music elements aren't selectable, but they can't be drawn by a single CADrawableFunctionMark because they're usually dependent on more than one function mark. More...

#include <drawablefunctionmark.h>

Inheritance diagram for CADrawableFunctionMarkSupport:
Inheritance graph
[legend]

Public Types

enum  CADrawableFunctionMarkSupportType {
  Key, Rectangle, ChordArea, Tonicization,
  Ellipse, Alterations
}
 
- Public Types inherited from CADrawableMusElement
enum  CADrawableMusElementType {
  DrawableNote, DrawableRest, DrawableClef, DrawableKeySignature,
  DrawableTimeSignature, DrawableBarline, DrawableAccidental, DrawableSlur,
  DrawableTuplet, DrawableSyllable, DrawableFunctionMark, DrawableFunctionMarkSupport,
  DrawableMark
}
 
- Public Types inherited from CADrawable
enum  CADrawableType { DrawableMusElement, DrawableContext }
 
enum  CADirection {
  Undefined, Top, Bottom, Left,
  Right, TopLeft, TopRight, BottomLeft,
  BottomRight
}
 

Public Member Functions

 CADrawableFunctionMarkSupport (CADrawableFunctionMarkSupportType, const QString key, CADrawableContext *c, double x, double y)
 
 CADrawableFunctionMarkSupport (CADrawableFunctionMarkSupportType, CADrawableFunctionMark *function, CADrawableContext *c, double x, double y, CADrawableFunctionMark *function2=0)
 
 CADrawableFunctionMarkSupport (CADrawableFunctionMarkSupportType, CAFunctionMark *function, CADrawableContext *c, double x, double y)
 
 ~CADrawableFunctionMarkSupport ()
 
void draw (QPainter *p, const CADrawSettings s)
 
CADrawableFunctionMarkSupportclone (CADrawableContext *newContext=0)
 
CADrawableFunctionMarkSupportType drawableFunctionMarkSupportType ()
 
bool isExtenderLineVisible ()
 
void setExtenderLineVisible (bool visible)
 
bool rectWider ()
 
void setRectWider (bool wider)
 
- Public Member Functions inherited from CADrawableMusElement
 CADrawableMusElement (CAMusElement *musElement, CADrawableContext *drawableContext, double x, double y)
 
CADrawableMusElementType drawableMusElementType ()
 
CAMusElementmusElement ()
 
CADrawableContextdrawableContext ()
 
void setDrawableContext (CADrawableContext *context)
 
- Public Member Functions inherited from CADrawable
 CADrawable (double x, double y)
 
virtual ~CADrawable ()
 
virtual CADrawableclone ()
 
void drawHScaleHandles (QPainter *p, const CADrawSettings s)
 
void drawVScaleHandles (QPainter *p, const CADrawSettings s)
 
CADrawableType drawableType ()
 
double xPos ()
 
double yPos ()
 
double width ()
 
double height ()
 
double neededSpaceWidth ()
 
double neededSpaceHeight ()
 
double neededWidth ()
 
double neededHeight ()
 
double xCenter ()
 
double yCenter ()
 
const QRect bBox ()
 
bool isVisible ()
 
bool isSelectable ()
 
bool isHScalable ()
 
bool isVScalable ()
 
void setXPos (double xPos)
 
void setYPos (double yPos)
 
void setWidth (double width)
 
void setHeight (double height)
 
void setNeededSpaceWidth (double width)
 
void setNeededSpaceHeight (double height)
 
void setVisible (bool v)
 
void setSelectable (bool s)
 
void setHScalable (bool s)
 
void setVScalable (bool s)
 

Private Attributes

CADrawableFunctionMarkSupportType _drawableFunctionMarkSupportType
 
QString _key
 
CADrawableFunctionMark_function1
 
CADrawableFunctionMark_function2
 
bool _extenderLineVisible
 
bool _rectWider
 

Additional Inherited Members

- Protected Member Functions inherited from CADrawableMusElement
void setDrawableMusElementType (CADrawableMusElementType t)
 
- Protected Attributes inherited from CADrawableMusElement
CADrawableMusElementType _drawableMusElementType
 
CADrawableContext_drawableContext
 
CAMusElement_musElement
 
bool _selectable
 
- Static Protected Attributes inherited from CADrawable
static const int SCALE_HANDLES_SIZE = 2
 

Detailed Description

Rectangles, key names, numbers below/above function, lines etc. Support class which draws the key of the function, rectangle around it, chord area, ellipse etc. These drawable music elements aren't selectable, but they can't be drawn by a single CADrawableFunctionMark because they're usually dependent on more than one function mark.

See Also
CADrawableFunctionMark

Member Enumeration Documentation

Enumerator
Key 
Rectangle 
ChordArea 
Tonicization 
Ellipse 
Alterations 

Constructor & Destructor Documentation

CADrawableFunctionMarkSupport::CADrawableFunctionMarkSupport ( CADrawableFunctionMarkSupportType  type,
const QString  key,
CADrawableContext c,
double  x,
double  y 
)

KeyName constructor.

Todo:
Width determination should be done automatically using QPainter::boundingRect() method

References _drawableFunctionMarkSupportType, CADrawableMusElement::_drawableMusElementType, _function1, _function2, CADrawable::_height, _key, CADrawable::_width, CADrawableMusElement::DrawableFunctionMarkSupport, Key, CADrawable::setSelectable(), and CADrawable::setWidth().

Referenced by clone().

Here is the call graph for this function:

Here is the caller graph for this function:

CADrawableFunctionMarkSupport::CADrawableFunctionMarkSupport ( CADrawableFunctionMarkSupportType  type,
CADrawableFunctionMark f1,
CADrawableContext c,
double  x,
double  y,
CADrawableFunctionMark f2 = 0 
)
CADrawableFunctionMarkSupport::CADrawableFunctionMarkSupport ( CADrawableFunctionMarkSupportType  type,
CAFunctionMark function,
CADrawableContext c,
double  x,
double  y 
)
CADrawableFunctionMarkSupport::~CADrawableFunctionMarkSupport ( )

Member Function Documentation

CADrawableFunctionMarkSupport * CADrawableFunctionMarkSupport::clone ( CADrawableContext newContext = 0)
virtual
void CADrawableFunctionMarkSupport::draw ( QPainter *  p,
const CADrawSettings  s 
)
virtual
CADrawableFunctionMarkSupportType CADrawableFunctionMarkSupport::drawableFunctionMarkSupportType ( )
inline
bool CADrawableFunctionMarkSupport::isExtenderLineVisible ( )
inline

References _extenderLineVisible.

bool CADrawableFunctionMarkSupport::rectWider ( )
inline

References _rectWider.

void CADrawableFunctionMarkSupport::setExtenderLineVisible ( bool  visible)
inline

References _extenderLineVisible.

void CADrawableFunctionMarkSupport::setRectWider ( bool  wider)
inline

References CADrawable::_height, _rectWider, and CADrawable::_yPos.

Referenced by CAEngraver::reposit().

Here is the caller graph for this function:

Member Data Documentation

CADrawableFunctionMarkSupportType CADrawableFunctionMarkSupport::_drawableFunctionMarkSupportType
private
bool CADrawableFunctionMarkSupport::_extenderLineVisible
private
CADrawableFunctionMark* CADrawableFunctionMarkSupport::_function1
private
CADrawableFunctionMark * CADrawableFunctionMarkSupport::_function2
private
QString CADrawableFunctionMarkSupport::_key
private
bool CADrawableFunctionMarkSupport::_rectWider
private

The documentation for this class was generated from the following files: