MuseScore  3.4
Music composition and notation
Public Member Functions | Private Member Functions | Private Attributes | List of all members
Bww::Parser Class Reference

The bww parser. More...

#include <parser.h>

Collaboration diagram for Bww::Parser:
Collaboration graph
[legend]

Public Member Functions

 Parser (Lexer &l, Writer &w)
 Parser constructor, using Lexer l and Writer w. More...
 
void parse ()
 Parse the input stream and write result. More...
 

Private Member Functions

void errorHandler (QString s)
 Display error s. More...
 
void parseBar (Bww::MeasureEndFlags &mef)
 Parse a bww bar symbol. More...
 
void parseNote ()
 Parse a bww note. More...
 
void parseGraces ()
 Parse a bww embellishment. More...
 
void parsePart (Bww::MeasureBeginFlags &mbf, Bww::MeasureEndFlags &mef)
 Parse a bww part symbol. More...
 
void parseSeqNonNotes ()
 Parse a sequence of non-notes. More...
 
void parseSeqNotes ()
 Parse a sequence of notes. More...
 
void parseString ()
 Parse a bww string. More...
 
void parseTempo ()
 Parse a bww tempo symbol. More...
 
void parseTSig ()
 Parse a bww tsig symbol. More...
 

Private Attributes

Lexerlex
 The lexer. More...
 
Writerwrt
 The writer. More...
 
QString title
 Title read from the header. More...
 
QString type
 Type read from the header. More...
 
QString composer
 Composer read from the header. More...
 
QString footer
 Footer read from the header. More...
 
int tempo
 Tune tempo read from the header. More...
 
int beat
 Beat type, read from the clef line. More...
 
int beats
 Number of beats, read from the clef line. More...
 
bool tieStart
 Tie start pending. More...
 
bool inTie
 In a tie. More...
 
bool tripletStart
 Triplet start pending. More...
 
bool inTriplet
 In a triplet. More...
 
QList< MeasureDescriptionmeasures
 Parsed measures. More...
 
bool tsigFound
 A valid time signature was found. More...
 

Detailed Description

The bww parser.

Constructor & Destructor Documentation

◆ Parser()

Bww::Parser::Parser ( Lexer l,
Writer w 
)

Parser constructor, using Lexer l and Writer w.

Member Function Documentation

◆ errorHandler()

void Bww::Parser::errorHandler ( QString  s)
private

Display error s.

◆ parse()

void Bww::Parser::parse ( )

Parse the input stream and write result.

◆ parseBar()

void Bww::Parser::parseBar ( Bww::MeasureEndFlags mef)
private

Parse a bww bar symbol.

◆ parseGraces()

void Bww::Parser::parseGraces ( )
private

Parse a bww embellishment.

◆ parseNote()

void Bww::Parser::parseNote ( )
private

Parse a bww note.

◆ parsePart()

void Bww::Parser::parsePart ( Bww::MeasureBeginFlags mbf,
Bww::MeasureEndFlags mef 
)
private

Parse a bww part symbol.

◆ parseSeqNonNotes()

void Bww::Parser::parseSeqNonNotes ( )
private

Parse a sequence of non-notes.

◆ parseSeqNotes()

void Bww::Parser::parseSeqNotes ( )
private

Parse a sequence of notes.

Includes handling ties and triplets, but without extensive error checking. May break on invalid input.

◆ parseString()

void Bww::Parser::parseString ( )
private

Parse a bww string.

Extract text and type. Example: "Air",(Y,C,0,0,Times New Roman,14,400,0,0,18,0,0,0)

◆ parseTempo()

void Bww::Parser::parseTempo ( )
private

Parse a bww tempo symbol.

◆ parseTSig()

void Bww::Parser::parseTSig ( )
private

Parse a bww tsig symbol.

Member Data Documentation

◆ beat

int Bww::Parser::beat
private

Beat type, read from the clef line.

◆ beats

int Bww::Parser::beats
private

Number of beats, read from the clef line.

◆ composer

QString Bww::Parser::composer
private

Composer read from the header.

◆ footer

QString Bww::Parser::footer
private

Footer read from the header.

◆ inTie

bool Bww::Parser::inTie
private

In a tie.

◆ inTriplet

bool Bww::Parser::inTriplet
private

In a triplet.

◆ lex

Lexer& Bww::Parser::lex
private

The lexer.

◆ measures

QList<MeasureDescription> Bww::Parser::measures
private

Parsed measures.

◆ tempo

int Bww::Parser::tempo
private

Tune tempo read from the header.

◆ tieStart

bool Bww::Parser::tieStart
private

Tie start pending.

◆ title

QString Bww::Parser::title
private

Title read from the header.

◆ tripletStart

bool Bww::Parser::tripletStart
private

Triplet start pending.

◆ tsigFound

bool Bww::Parser::tsigFound
private

A valid time signature was found.

◆ type

QString Bww::Parser::type
private

Type read from the header.

◆ wrt

Writer& Bww::Parser::wrt
private

The writer.


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