Main Page | Modules | Class Hierarchy | Alphabetical List | Compound List | File List | Compound Members | Related Pages

TClef Class Reference

Represents a clef. More...

#include <TClef.h>

Inheritance diagram for TClef:

visitable smartable List of all members.

Public Types

enum  {
  undefined = -1, none = 1, G, F,
  C, percussion, TAB, last = TAB
}

Public Member Functions

virtual void accept (TScoreVisitor &visitor)
void setStaffNum (long num)
void setSign (long sign)
void setLine (long line)
void setOctave (long oct)
long getStaffNum () const
long getSign () const
long getLine () const
long getOctave () const

Static Public Member Functions

const string xmlsign (int d)
 convert an integer clef sign to a MusicXML string

int xmlsign (const string str)
 convert an MusicXML string to an integer clef sign


Friends

EXP friend SMARTP< TClefnewClef ()

Detailed Description

Clefs are represented by the sign, line, and clef-octave-change elements. Sign values include G, F, C, percussion, TAB, and none. Line numbers are counted from the bottom of the staff. Standard values are 2 for the G sign (treble clef), 4 for the F sign (bass clef), 3 for the C sign (alto clef) and 5 for TAB (on a 6-line staff). The clef-octave-change element is used for transposing clefs (e.g., a treble clef for tenors would have a clef-octave-change value of -1). The optional number attribute refers to staff numbers, from top to bottom on the system. A value of 1 is assumed if not present.
TClef corresponds to the MusicXML clef element as defined in attributes.dtd


Generated on Tue Mar 23 09:49:57 2004 for LibMusicXML by doxygen 1.3.3