![]() |
Verovio
Source code documentation
|
This class models a stem as a layer element part and has no direct MEI equivalent. More...
#include <elementpart.h>
Public Member Functions | |
bool | HasToBeAligned () const override |
Override the method since alignment is required. | |
char32_t | GetFlagGlyph (data_STEMDIRECTION stemDir) const |
Point | GetStemUpSE (const Doc *doc, int staffSize, bool graceSize) const |
Point | GetStemDownNW (const Doc *doc, int staffSize, bool graceSize) const |
Constructors, destructors, reset and class name methods | |
Reset method resets all attribute classes | |
Flag () | |
virtual | ~Flag () |
void | Reset () override |
Reset the object, that is 1) removing all children and 2) resetting all attributes. More... | |
std::string | GetClassName () const override |
Object * | Clone () const override |
Method call for copying child classes. More... | |
FunctorCode | Accept (Functor &functor) override |
Interface for class functor visitation. | |
FunctorCode | Accept (ConstFunctor &functor) const override |
FunctorCode | AcceptEnd (Functor &functor) override |
FunctorCode | AcceptEnd (ConstFunctor &functor) const override |
![]() | |
void | CloneReset () override |
Overriding CloneReset() method to be called after copy / assignment calls. | |
virtual bool | IsScoreDefElement () const |
Return true if the element is part of a scoreDef or staffDef. | |
virtual bool | IsRelativeToStaff () const |
Return true if the element is relative to the staff and not to its parent. More... | |
int | GetOriginalLayerN () const |
void | CenterDrawingX () |
Adjust the m_drawingYRel for the element to be centered on the inner content of the measure. | |
int | GetDrawingTop (const Doc *doc, int staffSize, bool withArtic=true, ArticType articType=ARTIC_INSIDE) const |
Returns the drawing top and bottom taking into accound stem, etc. More... | |
int | GetDrawingBottom (const Doc *doc, int staffSize, bool withArtic=true, ArticType articType=ARTIC_INSIDE) const |
int | GetDrawingRadius (const Doc *doc, bool isInLigature=false) const |
Return the drawing radius for notes and chords. | |
data_STAFFREL_basic | GetCrossStaffRel () const |
Retrieve the direction of a cross-staff situation. | |
void | GetOverflowStaffAlignments (StaffAlignment *&above, StaffAlignment *&below) |
Get the StaffAlignment for which overflows need to be calculated against. More... | |
Fraction | GetAlignmentDuration (const AlignMeterParams ¶ms, bool notGraceOnly=true, data_NOTATIONTYPE notationType=NOTATIONTYPE_cmn) const |
Return the duration if the element has a DurationInterface. | |
Fraction | GetAlignmentDuration (bool notGraceOnly=true, data_NOTATIONTYPE notationType=NOTATIONTYPE_cmn) const |
Return the duration if the element has a DurationInterface. More... | |
Fraction | GetSameAsContentAlignmentDuration (const AlignMeterParams ¶ms, bool notGraceOnly=true, data_NOTATIONTYPE notationType=NOTATIONTYPE_cmn) const |
Return the duration if the content of the layer element with a @sameas attribute. More... | |
Fraction | GetContentAlignmentDuration (const AlignMeterParams ¶ms, bool notGraceOnly=true, data_NOTATIONTYPE notationType=NOTATIONTYPE_cmn) const |
Fraction | GetContentAlignmentDuration (bool notGraceOnly=true, data_NOTATIONTYPE notationType=NOTATIONTYPE_cmn) const |
bool | GenerateZoneBounds (int *ulx, int *uly, int *lrx, int *lry) const |
Get zone bounds using child elements with facsimile information. More... | |
virtual int | AdjustOverlappingLayers (const Doc *doc, const std::vector< LayerElement * > &otherElements, bool areDotsAdjusted, bool &isUnison, bool &stemSameAs) |
Helper to adjust overlapping layers for notes, chords, stems, etc. More... | |
std::pair< int, bool > | CalcElementHorizontalOverlap (const Doc *doc, const std::vector< LayerElement * > &otherElements, bool areDotsAdjusted, bool isChordElement, bool isLowerElement=false, bool unison=true) |
Calculate note horizontal overlap with elemenents from another layers. More... | |
virtual data_STEMMODIFIER | GetDrawingStemMod () const |
Get the stem mod for the element (if any) | |
virtual bool | HasCrossStaff () const |
Return true if cross-staff is set. | |
char32_t | StemModToGlyph (data_STEMMODIFIER stemMod) const |
Convert stem mode to corresponding glyph code. | |
MapOfDotLocs | CalcOptimalDotLocations () |
Calculate the optimal dot location for a note or chord Takes two layers into account in order to avoid collisions of dots between corresponding notes/chords. | |
LayerElement () | |
LayerElement (ClassId classId) | |
virtual | ~LayerElement () |
void | Reset () override |
Virtual reset method. More... | |
FacsimileInterface * | GetFacsimileInterface () override |
const FacsimileInterface * | GetFacsimileInterface () const override |
LinkingInterface * | GetLinkingInterface () override |
const LinkingInterface * | GetLinkingInterface () const override |
LayerElement * | ThisOrSameasLink () |
Return itself or the resolved @sameas (if any) | |
const LayerElement * | ThisOrSameasLink () const |
ElementScoreDefRole | GetScoreDefRole () const |
void | SetScoreDefRole (ElementScoreDefRole scoreDefRole) |
bool | IsGraceNote () const |
Return true if the element is a grace note. | |
bool | IsInLigature () const |
Return true if the element is a note within a ligature. | |
FTrem * | GetAncestorFTrem () |
Return the FTrem parten if the element is a note or a chord within a fTrem. | |
const FTrem * | GetAncestorFTrem () const |
Beam * | GetAncestorBeam () |
Return the beam parent if in beam Look if the note or rest is in a beam. More... | |
const Beam * | GetAncestorBeam () const |
bool | IsInBeam () const |
void | SetDrawingCueSize (bool drawingCueSize) |
bool | GetDrawingCueSize () const |
void | SetIsInBeamSpan (bool isInBeamSpan) |
bool | GetIsInBeamSpan () const |
int | GetAlignmentLayerN () const |
void | SetAlignmentLayerN (int alignmentLayerN) |
int | GetDrawingX () const override |
int | GetDrawingY () const override |
int | GetDrawingXRel () const |
virtual void | SetDrawingXRel (int drawingXRel) |
void | CacheXRel (bool restore=false) |
int | GetDrawingYRel () const |
virtual void | SetDrawingYRel (int drawingYRel) |
void | CacheYRel (bool restore=false) |
Alignment * | GetAlignment () |
Alignment setter and getter. | |
const Alignment * | GetAlignment () const |
void | ResetAlignment () |
void | SetAlignment (Alignment *alignment) |
Staff * | GetAncestorStaff (StaffSearch strategy=ANCESTOR_ONLY, bool assertExistence=true) |
Get the ancestor or cross staff. | |
const Staff * | GetAncestorStaff (StaffSearch strategy=ANCESTOR_ONLY, bool assertExistence=true) const |
Staff * | GetCrossStaff (Layer *&layer) |
Look for a cross or a a parent LayerElement (note, chord, rest) with a cross staff. More... | |
const Staff * | GetCrossStaff (const Layer *&layer) const |
Alignment * | GetGraceAlignment () |
const Alignment * | GetGraceAlignment () const |
void | ResetGraceAlignment () |
void | SetGraceAlignment (Alignment *graceAlignment) |
bool | HasGraceAlignment () const |
FunctorCode | Accept (Functor &functor) override |
Interface for class functor visitation. | |
FunctorCode | Accept (ConstFunctor &functor) const override |
FunctorCode | AcceptEnd (Functor &functor) override |
FunctorCode | AcceptEnd (ConstFunctor &functor) const override |
![]() | |
bool | IsFloatingObject () const |
Wrapper for checking if an element is a floating object (system elements and control elements) | |
const Resources * | GetDocResources () const |
Resource access from the document. | |
Object (const Object &object) | |
Copy constructor that also copy the children. More... | |
Object & | operator= (const Object &object) |
Copy assignement - see copy constructor. | |
void | MoveChildrenFrom (Object *sourceParent, int idx=-1, bool allowTypeChange=false) |
Move all the children of the object passed as parameter to this one. More... | |
void | ReplaceChild (Object *currentChild, Object *replacingChild) |
Replace the currentChild with the replacingChild. More... | |
void | SortChildren (binaryComp comp) |
void | MoveItselfTo (Object *targetParent) |
Move an object to another parent. More... | |
virtual bool | CopyChildren () const |
Indicate whereas children have to be copied in copy / assignment constructors. More... | |
const std::string & | GetID () const |
void | SetID (const std::string &id) |
void | SwapID (Object *other) |
void | ResetID () |
std::string | GetComment () const |
Methods for setting / getting comments. | |
void | SetComment (std::string comment) |
bool | HasComment () const |
std::string | GetClosingComment () const |
void | SetClosingComment (std::string endComment) |
bool | HasClosingComment () const |
ArrayOfObjects & | GetChildrenForModification () |
Return a reference to the children that allows modification. More... | |
void | CopyAttributesTo (Object *target) const |
Copy all the attributes of an obejct to target. More... | |
int | GetAttributes (ArrayOfStrAttr *attributes) const |
Fill an array of pairs with all attributes and their values. More... | |
bool | HasAttribute (std::string attribute, std::string value) const |
Check if an Object has an attribute with the specified value. | |
void | SetParent (Object *parent) |
Set the parent of the Object. More... | |
void | ResetParent () |
Reset the parent of the Object. More... | |
virtual bool | IsSupportedChild (ClassId classId) |
Base method for checking if a child can be added. More... | |
virtual void | AddChild (Object *object) |
Base method for adding children. More... | |
virtual bool | AddChildAdditionalCheck (Object *child) |
Additional check when adding a child. | |
virtual int | GetInsertOrderFor (ClassId classId) const |
Return the child order for a the given ClassId. More... | |
int | GetInsertOrderForIn (ClassId classId, const std::vector< ClassId > &order) const |
Find the order from an overriden GetInsertOrderFor method. | |
int | GetIdx () const |
Return the index position of the object in its parent (-1 if not found) | |
int | GetChildIndex (const Object *child) const |
Look for the Object in the children and return its position (-1 if not found) | |
int | GetDescendantIndex (const Object *child, const ClassId classId, int depth) |
Look for all Objects of a class and return its position (-1 if not found) | |
void | InsertChild (Object *element, int idx) |
Insert an element at the idx position. | |
void | RotateChildren (int first, int middle, int last) |
Rotates the child elements of the object leftwards, using std::rotate() with the given indices. More... | |
Object * | DetachChild (int idx) |
Detach the child at the idx position (NULL if not found) The parent pointer is set to NULL. | |
void | ReplaceWithCopyOf (Object *object) |
Replace an object with a copy of the other. More... | |
bool | HasDescendant (const Object *child, int deepness=UNLIMITED_DEPTH) const |
Return true if the object has the child Object as descendant (reference of direct). More... | |
Object * | Relinquish (int idx) |
Give up ownership of the child at the idx position (NULL if not found) This is a method to be used only in the very particular case where the child object cannot be detached straight away. More... | |
void | ClearRelinquishedChildren () |
Removes all the children that were previously relinquished. More... | |
void | ClearChildren () |
Clear the children vector and delete all the objects. | |
bool | DeleteChild (Object *child) |
Remove and delete the child. More... | |
int | DeleteChildrenByComparison (Comparison *comparison) |
Delete the children that match the comparison. More... | |
void | FillFlatList (ListOfConstObjects &list) const |
Fill the list of all the children LayerElement. More... | |
bool | IsModified () const |
Check if the content was modified or not. | |
void | Modify (bool modified=true) const |
Mark the object and its parent (if any) as modified. | |
bool | HasEditorialContent () |
Return true if the object contains any editorial content. | |
bool | HasNonEditorialContent () |
Return true if the object contains anything that is not editorial content. | |
void | SaveObject (Output *output, bool basic) |
Saves the object (and its children) using the specified output stream. | |
template<class Compare > | |
void | StableSort (Compare comp) |
Sort the child elements using std::stable_sort. | |
void | ReorderByXPos () |
Object * | FindNextChild (Comparison *comp, Object *start) |
Object * | FindPreviousChild (Comparison *comp, Object *start) |
Object () | |
Object (ClassId classId) | |
virtual | ~Object () |
ClassId | GetClassId () const final |
void | SetAsReferenceObject () |
Make an object a reference object that do not own children. More... | |
bool | IsReferenceObject () const |
bool | IsMilestoneElement () |
Wrapper for checking if an element has a milestone start interface and also if is set as a milestone element. | |
Object * | GetMilestoneEnd () |
bool | IsControlElement () const |
bool | IsEditorialElement () const |
bool | IsLayerElement () const |
bool | IsPageElement () const |
bool | IsRunningElement () const |
bool | IsScoreDefElement () const |
bool | IsSystemElement () const |
bool | IsTextElement () const |
void | RegisterAttClass (AttClassId attClassId) |
bool | HasAttClass (AttClassId attClassId) const |
void | RegisterInterface (std::vector< AttClassId > *attClasses, InterfaceId interfaceId) |
bool | HasInterface (InterfaceId interfaceId) const |
virtual AltSymInterface * | GetAltSymInterface () |
virtual const AltSymInterface * | GetAltSymInterface () const |
virtual AreaPosInterface * | GetAreaPosInterface () |
virtual const AreaPosInterface * | GetAreaPosInterface () const |
virtual BeamDrawingInterface * | GetBeamDrawingInterface () |
virtual const BeamDrawingInterface * | GetBeamDrawingInterface () const |
virtual DurationInterface * | GetDurationInterface () |
virtual const DurationInterface * | GetDurationInterface () const |
virtual PitchInterface * | GetPitchInterface () |
virtual const PitchInterface * | GetPitchInterface () const |
virtual PlistInterface * | GetPlistInterface () |
virtual const PlistInterface * | GetPlistInterface () const |
virtual PositionInterface * | GetPositionInterface () |
virtual const PositionInterface * | GetPositionInterface () const |
virtual ScoreDefInterface * | GetScoreDefInterface () |
virtual const ScoreDefInterface * | GetScoreDefInterface () const |
virtual StemmedDrawingInterface * | GetStemmedDrawingInterface () |
virtual const StemmedDrawingInterface * | GetStemmedDrawingInterface () const |
virtual TextDirInterface * | GetTextDirInterface () |
virtual const TextDirInterface * | GetTextDirInterface () const |
virtual TimePointInterface * | GetTimePointInterface () |
virtual const TimePointInterface * | GetTimePointInterface () const |
virtual TimeSpanningInterface * | GetTimeSpanningInterface () |
virtual const TimeSpanningInterface * | GetTimeSpanningInterface () const |
void | InsertBefore (Object *child, Object *newChild) |
void | InsertAfter (Object *child, Object *newChild) |
int | GetChildCount () const |
int | GetChildCount (const ClassId classId) const |
int | GetChildCount (const ClassId classId, int depth) const |
int | GetDescendantCount (const ClassId classId) const |
Object * | GetChild (int idx) |
Child access (generic) | |
const Object * | GetChild (int idx) const |
Object * | GetChild (int idx, const ClassId classId) |
const Object * | GetChild (int idx, const ClassId classId) const |
ArrayOfConstObjects | GetChildren () const |
Return the children as const reference or copy. | |
const ArrayOfObjects & | GetChildren () |
Object * | GetFirst (const ClassId classId=UNSPECIFIED) |
const Object * | GetFirst (const ClassId classId=UNSPECIFIED) const |
Object * | GetNext () |
const Object * | GetNext () const |
Object * | GetNext (const Object *child, const ClassId classId=UNSPECIFIED) |
const Object * | GetNext (const Object *child, const ClassId classId=UNSPECIFIED) const |
Object * | GetPrevious (const Object *child, const ClassId classId=UNSPECIFIED) |
const Object * | GetPrevious (const Object *child, const ClassId classId=UNSPECIFIED) const |
Object * | GetLast (const ClassId classId=UNSPECIFIED) |
Return the last child of the object (if any, NULL otherwise) | |
const Object * | GetLast (const ClassId classId=UNSPECIFIED) const |
Object * | GetParent () |
Get the parent of the Object. | |
const Object * | GetParent () const |
int | GetDrawingX () const override |
int | GetDrawingY () const override |
void | ResetCachedDrawingX () const override |
void | ResetCachedDrawingY () const override |
Object * | FindDescendantByID (const std::string &id, int deepness=UNLIMITED_DEPTH, bool direction=FORWARD) |
Look for a descendant with the specified id (returns NULL if not found) This method is a wrapper for the Object::FindByID functor. | |
const Object * | FindDescendantByID (const std::string &id, int deepness=UNLIMITED_DEPTH, bool direction=FORWARD) const |
Object * | FindDescendantByType (ClassId classId, int deepness=UNLIMITED_DEPTH, bool direction=FORWARD) |
Look for a descendant with the specified type (returns NULL if not found) This method is a wrapper for the Object::FindByType functor. | |
const Object * | FindDescendantByType (ClassId classId, int deepness=UNLIMITED_DEPTH, bool direction=FORWARD) const |
Object * | FindDescendantByComparison (Comparison *comparison, int deepness=UNLIMITED_DEPTH, bool direction=FORWARD) |
Return the first element matching the Comparison functor Deepness allow to limit the depth search (EditorialElements are not count) | |
const Object * | FindDescendantByComparison (Comparison *comparison, int deepness=UNLIMITED_DEPTH, bool direction=FORWARD) const |
Object * | FindDescendantExtremeByComparison (Comparison *comparison, int deepness=UNLIMITED_DEPTH, bool direction=FORWARD) |
Return the element matching the extreme value with an Comparison functor Deepness allow to limit the depth search (EditorialElements are not count) | |
const Object * | FindDescendantExtremeByComparison (Comparison *comparison, int deepness=UNLIMITED_DEPTH, bool direction=FORWARD) const |
ListOfObjects | FindAllDescendantsByType (ClassId classId, bool continueDepthSearchForMatches=true, int deepness=UNLIMITED_DEPTH) |
Return all the objects with specified type. | |
ListOfConstObjects | FindAllDescendantsByType (ClassId classId, bool continueDepthSearchForMatches=true, int deepness=UNLIMITED_DEPTH) const |
void | FindAllDescendantsByComparison (ListOfObjects *objects, Comparison *comparison, int deepness=UNLIMITED_DEPTH, bool direction=FORWARD, bool clear=true) |
Return all the objects matching the Comparison functor Deepness allow to limit the depth search (EditorialElements are not count) | |
void | FindAllDescendantsByComparison (ListOfConstObjects *objects, Comparison *comparison, int deepness=UNLIMITED_DEPTH, bool direction=FORWARD, bool clear=true) const |
void | FindAllDescendantsBetween (ListOfObjects *objects, Comparison *comparison, const Object *start, const Object *end, bool clear=true, int depth=UNLIMITED_DEPTH) |
Return all the objects matching the Comparison functor and being between start and end in the tree. More... | |
void | FindAllDescendantsBetween (ListOfConstObjects *objects, Comparison *comparison, const Object *start, const Object *end, bool clear=true, int depth=UNLIMITED_DEPTH) const |
ListOfObjects | GetAncestors () |
Returns all ancestors. | |
ListOfConstObjects | GetAncestors () const |
Object * | GetFirstAncestor (const ClassId classId, int maxSteps=-1) |
Return the first ancestor of the specified type. More... | |
const Object * | GetFirstAncestor (const ClassId classId, int maxSteps=-1) const |
Object * | GetFirstAncestorInRange (const ClassId classIdMin, const ClassId classIdMax, int maxDepth=-1) |
const Object * | GetFirstAncestorInRange (const ClassId classIdMin, const ClassId classIdMax, int maxDepth=-1) const |
Object * | GetLastAncestorNot (const ClassId classId, int maxSteps=-1) |
Return the last ancestor that is NOT of the specified type. More... | |
const Object * | GetLastAncestorNot (const ClassId classId, int maxSteps=-1) const |
Object * | GetFirstChildNot (const ClassId classId) |
Return the first child that is NOT of the specified type. | |
const Object * | GetFirstChildNot (const ClassId classId) const |
bool | IsAttribute () const |
void | IsAttribute (bool isAttribute) |
bool | IsExpansion () const |
void | IsExpansion (bool isExpansion) |
void | Process (Functor &functor, int deepness=UNLIMITED_DEPTH, bool skipFirst=false) |
Main method that processes functors. More... | |
void | Process (ConstFunctor &functor, int deepness=UNLIMITED_DEPTH, bool skipFirst=false) const |
void | LogDebugTree (int maxDepth=UNLIMITED_DEPTH, int level=0) |
Output the class name of the object (or a custom msg) and of its children recursively. | |
virtual std::string | LogDebugTreeMsg () |
![]() | |
virtual void | ResetBoundingBox () |
Reset the bounding box values. | |
bool | Encloses (const Point point) const |
Return true if the bounding box encloses the point. | |
int | Intersects (const FloatingCurvePositioner *curve, Accessor type, int margin=0) const |
Return intersection between the bounding box and the curve represented by the FloatingPositioner. More... | |
int | Intersects (const BeamDrawingInterface *beamInterface, Accessor type, int margin=0, bool fromBeamContentSide=false) const |
Return intersection between the bounding box and the beam represented by the BeamDrawingInterface. More... | |
BoundingBox () | |
virtual | ~BoundingBox () |
bool | Is (ClassId classId) const |
bool | Is (const std::vector< ClassId > &classIds) const |
virtual void | UpdateContentBBoxX (int x1, int x2) |
virtual void | UpdateContentBBoxY (int y1, int y2) |
virtual void | UpdateSelfBBoxX (int x1, int x2) |
virtual void | UpdateSelfBBoxY (int y1, int y2) |
void | SetEmptyBB () |
bool | HasSelfBB () const |
bool | HasSelfHorizontalBB () const |
bool | HasSelfVerticalBB () const |
bool | HasContentBB () const |
bool | HasContentHorizontalBB () const |
bool | HasContentVerticalBB () const |
bool | HasEmptyBB () const |
void | SetBoundingBoxGlyph (char32_t smuflGlyph, int fontSize) |
Set and get the smuflGlyph / fontsize for a bounding box that is the one of a single SMuFL glyph. | |
char32_t | GetBoundingBoxGlyph () const |
int | GetBoundingBoxGlyphFontSize () const |
int | GetSelfBottom () const |
int | GetSelfTop () const |
int | GetSelfLeft () const |
int | GetSelfRight () const |
int | GetContentBottom () const |
int | GetContentTop () const |
int | GetContentLeft () const |
int | GetContentRight () const |
int | GetSelfX1 () const |
int | GetSelfX2 () const |
int | GetSelfY1 () const |
int | GetSelfY2 () const |
int | GetContentX1 () const |
int | GetContentX2 () const |
int | GetContentY1 () const |
int | GetContentY2 () const |
int | GetBottomBy (Accessor type) const |
int | GetTopBy (Accessor type) const |
int | GetLeftBy (Accessor type) const |
int | GetRightBy (Accessor type) const |
int | GetX1By (Accessor type) const |
int | GetX2By (Accessor type) const |
int | GetY1By (Accessor type) const |
int | GetY2By (Accessor type) const |
bool | HorizontalContentOverlap (const BoundingBox *other, int margin=0) const |
bool | VerticalContentOverlap (const BoundingBox *other, int margin=0) const |
bool | HorizontalSelfOverlap (const BoundingBox *other, int margin=0) const |
bool | VerticalSelfOverlap (const BoundingBox *other, int margin=0) const |
int | HorizontalLeftOverlap (const BoundingBox *other, const Doc *doc, int margin=0, int vMargin=0) const |
int | HorizontalRightOverlap (const BoundingBox *other, const Doc *doc, int margin=0, int vMargin=0) const |
int | VerticalTopOverlap (const BoundingBox *other, const Doc *doc, int margin=0, int hMargin=0) const |
int | VerticalBottomOverlap (const BoundingBox *other, const Doc *doc, int margin=0, int hMargin=0) const |
int | GetCutOutTop (const Resources &resources) const |
int | GetCutOutBottom (const Resources &resources) const |
int | GetCutOutLeft (const Resources &resources) const |
int | GetCutOutRight (const Resources &resources) const |
int | GetCutOutLeft (const Resources &resources, bool fromTop) const |
int | GetCutOutRight (const Resources &resources, bool fromTop) const |
![]() | |
int | GetWidth () const |
int | GetHeight () const |
double | GetDrawingRotate () const |
bool | HasFacsimile () const |
Check if the object has a facsimile. | |
void | AttachZone (Zone *zone) |
Link to the zone. | |
int | GetSurfaceY () const |
FacsimileInterface () | |
virtual | ~FacsimileInterface () |
InterfaceId | IsInterface () const override |
Virtual method returning the InterfaceId of the interface. More... | |
Zone * | GetZone () |
Get the zone. | |
const Zone * | GetZone () const |
Surface * | GetSurface () |
Get the surface. | |
const Surface * | GetSurface () const |
FunctorCode | InterfacePrepareFacsimile (PrepareFacsimileFunctor &functor, Object *object) |
We have functor code in the interface for avoiding code duplication in each implementation class. More... | |
FunctorCode | InterfaceResetData (ResetDataFunctor &functor, Object *object) |
![]() | |
void | RegisterInterfaceAttClass (AttClassId attClassId) |
Method for registering an MEI att classes in the interface. | |
std::vector< AttClassId > * | GetAttClasses () |
Method for obtaining a pointer to the attribute class vector of the interface. | |
Interface () | |
virtual | ~Interface () |
![]() | |
void | AddBackLink (const Object *object) |
Set @corresp attribute to the ID (or @corresp) of the object. | |
LinkingInterface () | |
virtual | ~LinkingInterface () |
void | Reset () override |
Virtual reset method. More... | |
InterfaceId | IsInterface () const override |
Virtual method returning the InterfaceId of the interface. More... | |
void | SetNextLink (Object *next) |
Object * | GetNextLink () |
const Object * | GetNextLink () const |
void | SetSameasLink (Object *sameas) |
Object * | GetSameasLink () |
const Object * | GetSameasLink () const |
bool | HasNextLink () const |
Return true if a object is given and resolved. | |
bool | HasSameasLink () const |
Measure * | GetNextMeasure () |
Return the start measure of the next object (if any, NULL otherwise) | |
const Measure * | GetNextMeasure () const |
FunctorCode | InterfacePrepareLinking (PrepareLinkingFunctor &functor, Object *object) |
We have functor code in the interface for avoiding code duplication in each implementation class. More... | |
FunctorCode | InterfacePrepareStaffCurrentTimeSpanning (PrepareStaffCurrentTimeSpanningFunctor &functor, Object *object) |
FunctorCode | InterfaceResetData (ResetDataFunctor &functor, Object *object) |
Public Attributes | |
int | m_drawingNbFlags |
The number of flags to be drawn. | |
![]() | |
int | m_drawingFacsX |
Absolute position X. More... | |
int | m_drawingFacsY |
Staff * | m_crossStaff |
This stores a pointer to the cross-staff (if any) and the appropriate layer See PrepareCrossStaffFunctor. | |
Layer * | m_crossLayer |
![]() | |
ArrayOfStrAttr | m_unsupported |
Keep an array of unsupported attributes as pairs. More... | |
Additional Inherited Members | |
![]() | |
typedef bool(* | binaryComp) (Object *, Object *) |
Sort children by a function that takes two arguments and returns true if the first argument is less than the second. More... | |
![]() | |
static void | SeedID (uint32_t seed=0) |
static std::string | GenerateHashID () |
static uint32_t | Hash (uint32_t number, bool reverse=false) |
static bool | sortByUlx (Object *a, Object *b) |
static bool | IsPreOrdered (const Object *left, const Object *right) |
Return true if left appears before right in preorder traversal. | |
static bool | IsControlElement (ClassId classId) |
static bool | IsEditorialElement (ClassId classId) |
static bool | IsLayerElement (ClassId classId) |
static bool | IsPageElement (ClassId classId) |
static bool | IsRunningElement (ClassId classId) |
static bool | IsScoreDefElement (ClassId classId) |
static bool | IsSystemElement (ClassId classId) |
static bool | IsTextElement (ClassId classId) |
![]() | |
static std::pair< double, int > | ApproximateBezierExtrema (const Point bezier[4], bool isMaxExtrema, int approximationSteps=BEZIER_APPROXIMATION) |
static double | CalcDistance (const Point &p1, const Point &p2) |
Calculate the euclidean distance between two points. | |
static bool | ArePointsClose (const Point &p1, const Point &p2, int margin) |
static double | CalcSlope (const Point &p1, const Point &p2) |
Calculate the slope represented by two points. | |
static Point | CalcPositionAfterRotation (Point point, float alpha, Point center) |
Calculate the position of a point after a rotation of alpha (in radian) around the center. | |
static double | CalcBezierParamAtPosition (const Point bezier[4], int x) |
Calculate the t parameter of a bezier at position x. | |
static int | CalcBezierAtPosition (const Point bezier[4], int x) |
Calculate the y position of a bezier at position x. | |
static void | CalcLinearInterpolation (Point &dest, const Point &a, const Point &b, double t) |
Calculate linear interpolation between two points at time t. | |
static Point | CalcPointAtBezier (const Point bezier[4], double t) |
Calculate point (X,Y) coordinaties on the bezier curve. | |
static double | GetBezierThicknessCoefficient (const Point bezier[4], int currentThickness, int penWidth) |
Calculate thickness coefficient to be applient for bezier curve to fit MEI units thickness. | |
static Point | CalcDeCasteljau (const Point bezier[4], double t) |
Calculate the point bezier point position for a t between 0.0 and 1.0. | |
static void | CalcThickBezier (const Point bezier[4], int thickness, Point topBezier[4], Point bottomBezier[4]) |
Calculate the position of the bezier above and below for a thick bezier. | |
static void | ApproximateBezierBoundingBox (const Point bezier[4], Point &pos, int &width, int &height, int &minYPos, int &maxYPos) |
Approximate the bounding box of a bezier taking into accound the height and the width. | |
static std::set< double > | SolveCubicPolynomial (double a, double b, double c, double d) |
Solve the cubic equation ax^3 + bx^2 + cx + d = 0 Returns up to three real roots. | |
static int | RectLeftOverlap (const Point rect1[2], const Point rect2[2], int margin, int vMargin) |
Calculate the left / right / top / bottom overlap of two rectangle taking into account the margin / v-h-Margins. | |
static int | RectRightOverlap (const Point rect1[2], const Point rect2[2], int margin, int vMargin) |
static int | RectTopOverlap (const Point rect1[2], const Point rect2[2], int margin, int hMargin) |
static int | RectBottomOverlap (const Point rect1[2], const Point rect2[2], int margin, int hMargin) |
![]() | |
std::vector< int > | GetElementsInUnison (const std::set< int > &firstChord, const std::set< int > &secondChord, data_STEMDIRECTION stemDirection) const |
Helper to figure whether two chords are in fully in unison based on the locations of the notes. More... | |
virtual MapOfNoteLocs | CalcNoteLocations (NotePredicate predicate=NULL) const |
The note locations w.r.t. More... | |
virtual MapOfDotLocs | CalcDotLocations (int layerCount, bool primary) const |
The dot locations w.r.t. More... | |
![]() | |
void | SetIDStr () |
Extract the fragment of the start or end @xml:id if given. | |
![]() | |
static int | GetDotCount (const MapOfDotLocs &dotLocations) |
Helper to count the number of dots This can be used as an indicator to choose between different sets of dots. | |
static int | GetCollisionCount (const MapOfDotLocs &dotLocs1, const MapOfDotLocs &dotLocs2) |
Helper to count the collisions between two sets of dots. | |
![]() | |
Alignment * | m_alignment |
Alignment * | m_graceAlignment |
An alignment for grace notes. | |
int | m_drawingYRel |
The Y drawing relative position of the object. More... | |
int | m_cachedYRel |
The cached value for m_drawingYRel for caching horizontal layout. | |
int | m_drawingXRel |
The X drawing relative position of the object. More... | |
int | m_cachedXRel |
The cached value for m_drawingXRel for caching horizontal layout. | |
bool | m_drawingCueSize |
The cached drawing cue size set by PrepareCueSizeFunctor. | |
![]() | |
int | m_cachedDrawingX |
The cached version of the drawingX and drawingY values. More... | |
int | m_cachedDrawingY |
This class models a stem as a layer element part and has no direct MEI equivalent.
|
inlineoverridevirtual |
Method call for copying child classes.
The method has to be overridden.
Reimplemented from vrv::Object.
|
overridevirtual |
Reset the object, that is 1) removing all children and 2) resetting all attributes.
The method is virtual, so always call the parent in the method overriding it.
Reimplemented from vrv::Object.