From ff98fe3b386d46c6d78d6752cce48afce11260bd Mon Sep 17 00:00:00 2001 From: fred Date: Sun, 24 Mar 2002 19:42:41 +0000 Subject: [PATCH] lilypond-0.0.61 --- flower/include/fproto.hh | 4 ++-- flower/include/list.hh | 2 +- flower/include/pcursor.hh | 10 +++++----- flower/include/plist.hh | 26 +++++++++++++------------- flower/include/plist.icc | 2 +- flower/include/plist.tcc | 8 ++++---- lily/include/beam.hh | 2 +- lily/include/input-music.hh | 4 ++-- lily/include/input-register.hh | 2 +- lily/include/input-score.hh | 2 +- lily/include/input-staff.hh | 2 +- lily/include/molecule.hh | 2 +- lily/include/p-col.hh | 4 ++-- lily/include/p-score.hh | 14 +++++++------- lily/include/p-staff.hh | 4 ++-- lily/include/pulk-voices.hh | 6 +++--- lily/include/register-group.hh | 2 +- lily/include/request-column.hh | 4 ++-- lily/include/rest-column.hh | 1 + lily/include/score.hh | 6 +++--- lily/include/scoreline.hh | 4 ++-- lily/include/staff.hh | 6 +++--- lily/include/voice-element.hh | 2 +- lily/include/voice.hh | 2 +- 24 files changed, 61 insertions(+), 60 deletions(-) diff --git a/flower/include/fproto.hh b/flower/include/fproto.hh index 5f3bdfcff4..ef4c6422b2 100644 --- a/flower/include/fproto.hh +++ b/flower/include/fproto.hh @@ -21,8 +21,8 @@ template struct Array; template struct sstack; template struct Assoc; template struct List; -template struct PointerList; -template struct IPointerList; +template struct Pointer_list; +template struct IPointer_list; template struct Cursor; template struct PCursor; template struct Link; diff --git a/flower/include/list.hh b/flower/include/list.hh index a7389ed489..cdf57ced99 100644 --- a/flower/include/list.hh +++ b/flower/include/list.hh @@ -15,7 +15,7 @@ template class Link; items are always stored as copies in List, but: #List# : copies of #String# stored #List# : copies of #String*# stored! - (do not use, use \Ref{PointerList} ## instead.) + (do not use, use \Ref{Pointer_list} ## instead.) {\bf note:} retrieving "invalid" cursors, i.e. diff --git a/flower/include/pcursor.hh b/flower/include/pcursor.hh index 459977a471..dffe02b9ef 100644 --- a/flower/include/pcursor.hh +++ b/flower/include/pcursor.hh @@ -10,14 +10,14 @@ #include "plist.hh" #include "cursor.hh" -/** cursor to go with PointerList. - don't create PointerList's. +/** cursor to go with Pointer_list. + don't create Pointer_list's. This cursor is just an interface class for Cursor. It takes care of the appropriate type casts */ template class PCursor : private Cursor { - friend class IPointerList; + friend class IPointer_list; /// delete contents void junk(); @@ -36,14 +36,14 @@ public: return remove_p(); } - PointerList &list() { return (PointerList&)Cursor::list(); } + Pointer_list &list() { return (Pointer_list&)Cursor::list(); } PCursor operator++(int) { return Cursor::operator++(0);} PCursor operator--(int) { return Cursor::operator--(0); } PCursor operator+=(int i) { return Cursor::operator+=(i);} PCursor operator-=(int i) { return Cursor::operator-=(i); } PCursor operator -(int no) const { return Cursor::operator-(no);} int operator -(PCursor op) const { return Cursor::operator-(op);} - PCursor operator +( int no) const {return Cursor::operator+(no);} PCursor(const PointerList & l) : Cursor (l) {} + PCursor operator +( int no) const {return Cursor::operator+(no);} PCursor(const Pointer_list & l) : Cursor (l) {} PCursor() : Cursor () {} PCursor( const Cursor& cursor ) : Cursor(cursor) { } void* vptr() const { return *((Cursor &) *this); } diff --git a/flower/include/plist.hh b/flower/include/plist.hh index 80d780e3d6..afbf942c73 100644 --- a/flower/include/plist.hh +++ b/flower/include/plist.hh @@ -12,14 +12,14 @@ /** A list of pointers. - Use for list of pointers, e.g. PointerList. + Use for list of pointers, e.g. Pointer_list. This class does no deletion of the pointers, but it knows how to copy itself (shallow copy). We could have derived it from List, - but this design saves a lot of code dup; for all PointerLists in the + but this design saves a lot of code dup; for all Pointer_lists in the program only one parent List is instantiated. */ template -class PointerList : public List +class Pointer_list : public List { public: PCursor top() const{ @@ -29,11 +29,11 @@ class PointerList : public List return PCursor (List::bottom()); } PCursor find(T) const; - void concatenate(PointerList const &s) { List::concatenate(s); } - PointerList() {} + void concatenate(Pointer_list const &s) { List::concatenate(s); } + Pointer_list() {} }; -/** PointerList which deletes pointers given to it. +/** Pointer_list which deletes pointers given to it. NOTE: The copy constructor doesn't do what you'd want: @@ -41,25 +41,25 @@ class PointerList : public List new T(*cursor) - You have to copy this yourself, or use the macro PointerList__copy + You have to copy this yourself, or use the macro Pointer_list__copy */ template -class IPointerList : public PointerList { +class IPointer_list : public Pointer_list { public: - IPointerList(IPointerList const &) { set_empty(); } - IPointerList() { } - ~IPointerList(); + IPointer_list(IPointer_list const &) { set_empty(); } + IPointer_list() { } + ~IPointer_list(); }; -#define IPointerList__copy(T, to, from, op) \ +#define IPointer_list__copy(T, to, from, op) \ for (PCursor _pc_(from); _pc_.ok(); _pc_++)\ to.bottom().add(_pc_->op)\ \ template -void PL_copy(IPointerList &dst,IPointerList const&src); +void PL_copy(IPointer_list &dst,IPointer_list const&src); diff --git a/flower/include/plist.icc b/flower/include/plist.icc index 8b5f8eea56..f24e0ddf45 100644 --- a/flower/include/plist.icc +++ b/flower/include/plist.icc @@ -9,7 +9,7 @@ template void -PL_copy(IPointerList &to, IPointerList const&src) +PL_copy(IPointer_list &to, IPointer_list const&src) { for (PCursor pc(src); pc.ok(); pc++) { T *q = pc; diff --git a/flower/include/plist.tcc b/flower/include/plist.tcc index d18e01f902..7129cdbe3d 100644 --- a/flower/include/plist.tcc +++ b/flower/include/plist.tcc @@ -1,12 +1,12 @@ #include "plist.hh" -#define PL_instantiate(a) template class PointerList; \ +#define PL_instantiate(a) template class Pointer_list; \ template class PCursor; #define IPL_instantiate(a) PL_instantiate(a); \ - template class IPointerList + template class IPointer_list template -IPointerList::~IPointerList() +IPointer_list::~IPointer_list() { PCursor c( *this ); while (c.ok()) { @@ -16,7 +16,7 @@ IPointerList::~IPointerList() template PCursor -PointerList::find(T what ) const +Pointer_list::find(T what ) const { PCursor i(*this); for (; i.ok(); i++) diff --git a/lily/include/beam.hh b/lily/include/beam.hh index a85858bad8..f1ac0c1eaa 100644 --- a/lily/include/beam.hh +++ b/lily/include/beam.hh @@ -14,7 +14,7 @@ make sure that they reach the beam and that point in the correct direction */ struct Beam: public Directional_spanner { - PointerList stems; + Pointer_list stems; /// the slope of the beam in posns / point (dimension) Real slope; diff --git a/lily/include/input-music.hh b/lily/include/input-music.hh index 7102ed35eb..b34fedc183 100644 --- a/lily/include/input-music.hh +++ b/lily/include/input-music.hh @@ -12,7 +12,7 @@ #include "voice.hh" #include "moment.hh" -struct Voice_list : public PointerList { +struct Voice_list : public Pointer_list { void translate_time(Moment dt); }; @@ -67,7 +67,7 @@ struct Simple_music : Input_music { /// Complex_music consists of multiple voices struct Complex_music : Input_music { - IPointerList elts; + IPointer_list elts; /* *************** */ virtual void transpose(Melodic_req const&) const ; virtual void set_default_group(String g); diff --git a/lily/include/input-register.hh b/lily/include/input-register.hh index 6149121e29..bf945ab100 100644 --- a/lily/include/input-register.hh +++ b/lily/include/input-register.hh @@ -16,7 +16,7 @@ #include "input.hh" struct Input_register : Input { - IPointerList ireg_list_; + IPointer_list ireg_list_; String name_str_; void add(Input_register*); diff --git a/lily/include/input-score.hh b/lily/include/input-score.hh index a55b7a4378..6e6a3ceaaf 100644 --- a/lily/include/input-score.hh +++ b/lily/include/input-score.hh @@ -24,7 +24,7 @@ public: /// paper_, staffs_ and commands_ form the problem definition. Paper_def *paper_p_; Midi_def* midi_p_; - IPointerList staffs_; + IPointer_list staffs_; /* *************************************************************** */ diff --git a/lily/include/input-staff.hh b/lily/include/input-staff.hh index 0a35b460b6..0bbdc13266 100644 --- a/lily/include/input-staff.hh +++ b/lily/include/input-staff.hh @@ -16,7 +16,7 @@ class Input_staff:public Input { public: - IPointerList music_; + IPointer_list music_; Input_register * ireg_p_; /* *************** */ diff --git a/lily/include/molecule.hh b/lily/include/molecule.hh index 084321ce4e..312111bff2 100644 --- a/lily/include/molecule.hh +++ b/lily/include/molecule.hh @@ -30,7 +30,7 @@ struct Atom { /** a group of individually translated symbols. You can add molecules to the top, to the right, etc. */ struct Molecule { - IPointerList ats; // change to List? + IPointer_list ats; // change to List? /* *************** */ diff --git a/lily/include/p-col.hh b/lily/include/p-col.hh index 2a2dd92afc..58206b4306 100644 --- a/lily/include/p-col.hh +++ b/lily/include/p-col.hh @@ -22,8 +22,8 @@ class PCol { public: - PointerList its; - PointerList stoppers, starters; + Pointer_list its; + Pointer_list stoppers, starters; /** prebreak is put before end of line. if broken here, then (*this) column is discarded, and prebreak diff --git a/lily/include/p-score.hh b/lily/include/p-score.hh index 3177613ec5..0cc7a2bc15 100644 --- a/lily/include/p-score.hh +++ b/lily/include/p-score.hh @@ -18,25 +18,25 @@ struct PScore { Paper_def *paper_l_; /// the columns, ordered left to right - IPointerList cols; + IPointer_list cols; /// the idealspacings, no particular order - IPointerList suz; + IPointer_list suz; /// the staffs ordered top to bottom - IPointerList staffs; + IPointer_list staffs; /// all symbols in score. No particular order. - IPointerList its; + IPointer_list its; /// if broken, the different lines - IPointerList lines; + IPointer_list lines; /// crescs etc; no particular order - IPointerList spanners; + IPointer_list spanners; /// broken spanners - IPointerList broken_spans; + IPointer_list broken_spans; /* *************** */ /* CONSTRUCTION */ diff --git a/lily/include/p-staff.hh b/lily/include/p-staff.hh index c95834c2fb..a1c5fb4daa 100644 --- a/lily/include/p-staff.hh +++ b/lily/include/p-staff.hh @@ -11,8 +11,8 @@ struct PStaff { PScore * pscore_l_; - PointerList spans; - PointerList its; + Pointer_list spans; + Pointer_list its; /* *************** */ void add(Item*i); diff --git a/lily/include/pulk-voices.hh b/lily/include/pulk-voices.hh index 2cc5a48831..e871517388 100644 --- a/lily/include/pulk-voices.hh +++ b/lily/include/pulk-voices.hh @@ -34,15 +34,15 @@ int compare(Voice_l const &p1, Voice_l const &p2); class Pulk_voices { PQueue< Voice_l > voice_pq_; - IPointerList< Pulk_voice * > pulk_p_list_; - PointerList staff_l_list_; + IPointer_list< Pulk_voice * > pulk_p_list_; + Pointer_list staff_l_list_; Moment next_mom_; public: Moment last_; bool ok() const; Moment next_mom() { return next_mom_; } - Pulk_voices(PointerList const&); + Pulk_voices(Pointer_list const&); void get_aligned_request(Request_column *col_l ); }; diff --git a/lily/include/register-group.hh b/lily/include/register-group.hh index fcfc4ba5c6..be21d7fd5e 100644 --- a/lily/include/register-group.hh +++ b/lily/include/register-group.hh @@ -21,7 +21,7 @@ */ class Register_group_register : public Request_register { protected: - IPointerList reg_list_; + IPointer_list reg_list_; virtual void do_print()const; public: diff --git a/lily/include/request-column.hh b/lily/include/request-column.hh index 32a6f63773..e3d5d3184e 100644 --- a/lily/include/request-column.hh +++ b/lily/include/request-column.hh @@ -18,12 +18,12 @@ */ class Request_column { - IPointerList staff_cols_; + IPointer_list staff_cols_; Array staff_col_l_arr_; public: Score_column *musical_column_l_, *command_column_l_; - Request_column(PointerList const& ); + Request_column(Pointer_list const& ); bool used_b()const; Moment when(); void add_reqs(int staff_idx, Array const&); diff --git a/lily/include/rest-column.hh b/lily/include/rest-column.hh index 04e86e581a..a753c61d93 100644 --- a/lily/include/rest-column.hh +++ b/lily/include/rest-column.hh @@ -23,6 +23,7 @@ public: void add(Notehead *); NAME_MEMBERS(Rest_column); void translate_y(Real dy); + Rest_column(); }; #endif // REST_COLUMN_HH diff --git a/lily/include/score.hh b/lily/include/score.hh index e83540533b..7376e97976 100644 --- a/lily/include/score.hh +++ b/lily/include/score.hh @@ -24,12 +24,12 @@ struct Score { /// paper_, staffs_ and commands_ form the problem definition. Paper_def *paper_p_; Midi_def *midi_p_; - IPointerList staffs_; + IPointer_list staffs_; /// "runtime" fields for setting up spacing - IPointerList rcols_; + IPointer_list rcols_; - IPointerList cols_; + IPointer_list cols_; PScore *pscore_p_; Input input_; diff --git a/lily/include/scoreline.hh b/lily/include/scoreline.hh index 9196a96ab3..33bbc4a2d8 100644 --- a/lily/include/scoreline.hh +++ b/lily/include/scoreline.hh @@ -13,10 +13,10 @@ /// the columns of a score that form one line. struct Line_of_score { - PointerList cols; + Pointer_list cols; // need to store height of each staff. - IPointerList staffs; + IPointer_list staffs; PScore * pscore_l_; // needed to generate staffs /* *************** */ diff --git a/lily/include/staff.hh b/lily/include/staff.hh index e0613136f2..29f6839f73 100644 --- a/lily/include/staff.hh +++ b/lily/include/staff.hh @@ -20,9 +20,9 @@ class Staff { public: Input_register * ireg_p_; - PointerList voice_list_; + Pointer_list voice_list_; /// runtime field - PointerList cols_; + Pointer_list cols_; Score *score_l_; PScore *pscore_l_; @@ -30,7 +30,7 @@ public: /* *************************************************************** */ - void add(const PointerList &s); + void add(const Pointer_list &s); void add_voice(Voice *v_p); Paper_def*paper()const; diff --git a/lily/include/voice-element.hh b/lily/include/voice-element.hh index cd02239f5e..fc85b58e3b 100644 --- a/lily/include/voice-element.hh +++ b/lily/include/voice-element.hh @@ -24,7 +24,7 @@ public: Voice_element */ Moment duration_; Voice const *voice_C_; - IPointerList req_p_list_; + IPointer_list req_p_list_; Request * principal_req_l_; /* *************** */ diff --git a/lily/include/voice.hh b/lily/include/voice.hh index 5ddcc91933..475fc44668 100644 --- a/lily/include/voice.hh +++ b/lily/include/voice.hh @@ -18,7 +18,7 @@ struct Voice { /** the elements, earliest first. Please use the member #add()# to add a new element */ - IPointerList elts_; + IPointer_list elts_; Moment start_; /* *************** */ -- 2.39.5