From 163225c0cbb1055dfd3614615350ab9f3aaba74c Mon Sep 17 00:00:00 2001 From: Han-Wen Nienhuys Date: Thu, 9 Dec 2004 00:13:05 +0000 Subject: [PATCH] (Paper_column): copy rank_. This fixes lyric spacing on the penultimate column. --- ChangeLog | 5 ++++ flower/include/parray.hh | 2 +- lily/accidental-placement.cc | 4 ++-- lily/afm.cc | 4 ++-- lily/align-interface.cc | 14 +++++------ lily/audio-element-info.cc | 4 ++-- lily/axis-group-engraver.cc | 2 +- lily/bar-engraver.cc | 2 +- lily/bar-number-engraver.cc | 4 ++-- lily/beam-engraver.cc | 10 ++++---- lily/beam-quanting.cc | 6 ++--- lily/beam.cc | 30 ++++++++++++------------ lily/bezier.cc | 10 ++++---- lily/break-algorithm.cc | 4 ++-- lily/break-align-interface.cc | 8 +++---- lily/break-substitution.cc | 2 +- lily/chord-name-engraver.cc | 2 +- lily/chord-tremolo-engraver.cc | 2 +- lily/clef-engraver.cc | 2 +- lily/collision-engraver.cc | 11 ++++----- lily/context-def.cc | 4 ++-- lily/context-handle.cc | 4 ++-- lily/context.cc | 8 +++---- lily/dimension-cache.cc | 4 ++-- lily/dot-column-engraver.cc | 4 ++-- lily/dot-column.cc | 8 +++---- lily/drum-note-engraver.cc | 6 ++--- lily/drum-note-performer.cc | 8 +++---- lily/dynamic-engraver.cc | 4 ++-- lily/engraver-group-engraver.cc | 2 +- lily/extender-engraver.cc | 2 +- lily/fingering-engraver.cc | 4 ++-- lily/folded-repeat-iterator.cc | 2 +- lily/glissando-engraver.cc | 4 ++-- lily/global-context.cc | 2 +- lily/global-ctor.cc | 2 +- lily/gourlay-breaking.cc | 2 +- lily/grob-pitch-tuple.cc | 2 +- lily/grob.cc | 2 +- lily/hyphen-engraver.cc | 4 ++-- lily/include/break-algorithm.hh | 2 +- lily/include/grace-fixup.hh | 2 +- lily/include/grob.hh | 2 +- lily/item.cc | 4 ++-- lily/least-squares.cc | 8 +++---- lily/ledger-line-spanner.cc | 2 +- lily/lexer.ll | 6 ++--- lily/lyric-combine-music-iterator.cc | 4 ++-- lily/mark-engraver.cc | 4 ++-- lily/metronome-engraver.cc | 4 ++-- lily/midi-walker.cc | 2 +- lily/misc.cc | 2 +- lily/multi-measure-rest-engraver.cc | 8 +++---- lily/multi-measure-rest.cc | 2 +- lily/music-iterator.cc | 2 +- lily/music-sequence.cc | 2 +- lily/new-lyric-combine-music-iterator.cc | 4 ++-- lily/note-collision.cc | 10 ++++---- lily/note-heads-engraver.cc | 2 +- lily/note-name-engraver.cc | 2 +- lily/note-performer.cc | 6 ++--- lily/ottava-engraver.cc | 2 +- lily/paper-column.cc | 2 +- lily/part-combine-engraver.cc | 2 +- lily/percent-repeat-engraver.cc | 2 +- lily/performance.cc | 2 +- lily/performer-group-performer.cc | 2 +- lily/piano-pedal-performer.cc | 2 +- lily/repeated-music.cc | 4 ++-- lily/rest-collision-engraver.cc | 4 ++-- lily/rest-engraver.cc | 12 +++++----- lily/rhythmic-column-engraver.cc | 18 +++++++------- lily/rod.cc | 2 +- lily/score-engraver.cc | 10 ++++---- lily/score-performer.cc | 2 +- lily/script-column-engraver.cc | 6 ++--- lily/separating-line-group-engraver.cc | 8 +++---- lily/sequential-iterator.cc | 2 +- lily/simple-spacer.cc | 26 ++++++++++---------- lily/simultaneous-music-iterator.cc | 2 +- lily/slash-repeat-engraver.cc | 2 +- lily/slur-configuration.cc | 2 +- lily/source-file.cc | 2 +- lily/spacing-engraver.cc | 6 ++--- lily/spacing-spanner.cc | 10 ++++---- lily/span-arpeggio-engraver.cc | 2 +- lily/span-bar-engraver.cc | 6 ++--- lily/span-dynamic-performer.cc | 2 +- lily/spanner.cc | 6 ++--- lily/spring-smob.cc | 2 +- lily/staff-spacing.cc | 4 ++-- lily/staff-symbol-engraver.cc | 4 ++-- lily/staff-symbol.cc | 2 +- lily/stem-engraver.cc | 2 +- lily/system.cc | 2 +- lily/tab-note-heads-engraver.cc | 4 ++-- lily/text-engraver.cc | 6 ++--- lily/text-spanner-engraver.cc | 2 +- lily/tfm-reader.cc | 2 +- lily/tie-engraver.cc | 4 ++-- lily/timing-translator.cc | 2 +- lily/translator-ctors.cc | 2 +- lily/translator.cc | 2 +- lily/trill-spanner-engraver.cc | 2 +- lily/tuplet-bracket.cc | 2 +- lily/tuplet-engraver.cc | 2 +- lily/vertical-align-engraver.cc | 2 +- lily/volta-bracket.cc | 6 ++--- lily/volta-engraver.cc | 4 ++-- 109 files changed, 247 insertions(+), 245 deletions(-) diff --git a/ChangeLog b/ChangeLog index 5b2abac1f2..5697c51252 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2004-12-09 Han-Wen Nienhuys + + * lily/paper-column.cc (Paper_column): copy rank_. This fixes + lyric spacing on the penultimate column. + 2004-12-05 Christian Hitz * configure.in: diff --git a/flower/include/parray.hh b/flower/include/parray.hh index 67ce868a70..86c0a4f97d 100644 --- a/flower/include/parray.hh +++ b/flower/include/parray.hh @@ -283,7 +283,7 @@ binsearch_links (Link_array const &arr, T *t, { cmp = (lo + hi) / 2; - result = compare (t, arr[cmp]); + result = (*compare) (t, arr[cmp]); if (result < 0) hi = cmp; diff --git a/lily/accidental-placement.cc b/lily/accidental-placement.cc index 1051f0ada4..fae8a012db 100644 --- a/lily/accidental-placement.cc +++ b/lily/accidental-placement.cc @@ -142,7 +142,7 @@ struct Accidental_placement_entry int notename_; Accidental_placement_entry () { - offset_ =0.0; + offset_ = 0.0; notename_ = -1; } }; @@ -188,7 +188,7 @@ stagger_apes (Link_array *apes) apes->clear (); - int i =0; + int i = 0; int parity = 1; while (i < asc.size ()) { diff --git a/lily/afm.cc b/lily/afm.cc index e0961d7f45..fb2b761df7 100644 --- a/lily/afm.cc +++ b/lily/afm.cc @@ -24,7 +24,7 @@ Adobe_font_metric::Adobe_font_metric (AFM_Font_info *fi) for (int i = 256 >? fi->numOfChars; i--;) ascii_to_metric_idx_.push (-1); - for (int i=0; i < fi->numOfChars; i++) + for (int i= 0; i < fi->numOfChars; i++) { AFM_CharMetricInfo * c = fi->cmi + i; @@ -55,7 +55,7 @@ Adobe_font_metric::make_afm (AFM_Font_info *fi, AFM_CharMetricInfo const* Adobe_font_metric::find_ascii_metric (int a) const { - if (ascii_to_metric_idx_[a] >=0) + if (ascii_to_metric_idx_[a] >= 0) { int code = ascii_to_metric_idx_[a]; if (code >= 0) diff --git a/lily/align-interface.cc b/lily/align-interface.cc index 87fb32e6fb..343275fed2 100644 --- a/lily/align-interface.cc +++ b/lily/align-interface.cc @@ -60,7 +60,7 @@ Align_interface::align_to_fixed_distance (Grob *me , Axis a) Link_array elems = Pointer_group_interface__extract_grobs (me, (Grob*) 0, "elements"); - Real where_f=0; + Real where_f= 0; Interval v; v.set_empty (); @@ -85,7 +85,7 @@ Align_interface::align_to_fixed_distance (Grob *me , Axis a) elems.del (j); } - for (int j =0; j < elems.size (); j++) + for (int j = 0; j < elems.size (); j++) { where_f += stacking_dir * dy; translates.push (where_f); @@ -135,7 +135,7 @@ Align_interface::align_elements_to_extents (Grob * me, Axis a) Link_array elems; Link_array all_grobs = Pointer_group_interface__extract_grobs (me, (Grob*) 0, "elements"); - for (int i=0; i < all_grobs.size (); i++) + for (int i= 0; i < all_grobs.size (); i++) { Interval y = all_grobs[i]->extent (me, a); if (!y.is_empty ()) @@ -166,9 +166,9 @@ Align_interface::align_elements_to_extents (Grob * me, Axis a) Array translates ; Interval total; - Real where_f=0; + Real where_f= 0; - for (int j=0 ; j < elems.size (); j++) + for (int j= 0 ; j < elems.size (); j++) { Real dy = - dims[j][-stacking_dir]; if (j) @@ -198,8 +198,8 @@ Align_interface::align_elements_to_extents (Grob * me, Axis a) Array all_translates; if (translates.size ()) { - int i =0; - int j =0; + int i = 0; + int j = 0; Real w = translates[0]; while (j < all_grobs.size ()) { diff --git a/lily/audio-element-info.cc b/lily/audio-element-info.cc index da5170ab0c..e0384c2087 100644 --- a/lily/audio-element-info.cc +++ b/lily/audio-element-info.cc @@ -14,7 +14,7 @@ Audio_element_info::Audio_element_info (Audio_element*s, Music *r) { elem_ = s; - origin_trans_ =0; + origin_trans_ = 0; event_ = r; } @@ -23,7 +23,7 @@ Audio_element_info::Audio_element_info () { elem_ = 0; event_ = 0; - origin_trans_ =0; + origin_trans_ = 0; } diff --git a/lily/axis-group-engraver.cc b/lily/axis-group-engraver.cc index 76f1fda1b2..a53a676eee 100644 --- a/lily/axis-group-engraver.cc +++ b/lily/axis-group-engraver.cc @@ -102,7 +102,7 @@ Axis_group_engraver::process_acknowledged_grobs () if (!staffline_) return ; - for (int i=0; i < elts_.size (); i++) + for (int i= 0; i < elts_.size (); i++) { if (!unsmob_grob (elts_[i]->get_property ("axis-group-parent-Y"))) { diff --git a/lily/bar-engraver.cc b/lily/bar-engraver.cc index 0483857e01..10444fbc2e 100644 --- a/lily/bar-engraver.cc +++ b/lily/bar-engraver.cc @@ -36,7 +36,7 @@ private: Bar_engraver::Bar_engraver () { - bar_ =0; + bar_ = 0; } void diff --git a/lily/bar-number-engraver.cc b/lily/bar-number-engraver.cc index 373cdf4c07..dc80bd4b13 100644 --- a/lily/bar-number-engraver.cc +++ b/lily/bar-number-engraver.cc @@ -65,7 +65,7 @@ Bar_number_engraver::process_music () Bar_number_engraver::Bar_number_engraver () { - text_ =0; + text_ = 0; } @@ -91,7 +91,7 @@ Bar_number_engraver::stop_translation_timestep () { text_->set_property ("side-support-elements", get_property ("stavesFound")); - text_ =0; + text_ = 0; } } diff --git a/lily/beam-engraver.cc b/lily/beam-engraver.cc index 88265759f4..bf194f978c 100644 --- a/lily/beam-engraver.cc +++ b/lily/beam-engraver.cc @@ -83,12 +83,12 @@ Beam_engraver::valid_end_point () Beam_engraver::Beam_engraver () { beam_ = 0; - finished_beam_ =0; - finished_beam_info_=0; - beam_info_ =0; + finished_beam_ = 0; + finished_beam_info_= 0; + beam_info_ = 0; now_stop_ev_ = 0; start_ev_ = 0; - prev_start_ev_ =0; + prev_start_ev_ = 0; } bool @@ -164,7 +164,7 @@ Beam_engraver::typeset_beam () Beam::set_beaming (finished_beam_, finished_beam_info_); delete finished_beam_info_; - finished_beam_info_ =0; + finished_beam_info_ = 0; finished_beam_ = 0; } } diff --git a/lily/beam-quanting.cc b/lily/beam-quanting.cc index ae8730daba..553b8c4bcb 100644 --- a/lily/beam-quanting.cc +++ b/lily/beam-quanting.cc @@ -213,8 +213,8 @@ Beam::quanting (SCM smob) Array qscores; - for (int l =0; l < quantsl.size (); l++) - for (int r =0; r < quantsr.size (); r++) + for (int l = 0; l < quantsl.size (); l++) + for (int r = 0; r < quantsr.size (); r++) { Quant_score qs; qs.yl = quantsl[l]; @@ -336,7 +336,7 @@ Beam::score_stem_lengths (Link_array const &stems, Drul_array score (0, 0); Drul_array count (0, 0); - for (int i=0; i < stems.size (); i++) + for (int i= 0; i < stems.size (); i++) { Grob* s = stems[i]; if (Stem::is_invisible (s)) diff --git a/lily/beam.cc b/lily/beam.cc index 127054c7e8..d73bfc4fc3 100644 --- a/lily/beam.cc +++ b/lily/beam.cc @@ -207,7 +207,7 @@ position_with_maximal_common_beams (SCM left_beaming, SCM right_beaming, for (int i = lslice[-left_dir]; (i - lslice[left_dir])* left_dir <= 0 ; i+= left_dir) { - int count =0; + int count = 0; for ( SCM s = scm_car (right_beaming); scm_is_pair (s); s = scm_cdr (s)) { int k = - right_dir * scm_to_int (scm_car (s)) + i; @@ -404,7 +404,7 @@ Beam::print (SCM grob) Real break_overshoot = 3.0; Real w = (i > 0 && st) ? (xposn - last_xposn) : break_overshoot; - Real stem_offset =0.0; + Real stem_offset = 0.0; if (i > 0) { w += last_stem_width / 2; @@ -547,7 +547,7 @@ Beam::get_default_dir (Grob *me) Link_array stems= Pointer_group_interface__extract_grobs (me, (Grob*)0, "stems"); - for (int i=0; i < stems.size (); i++) + for (int i= 0; i < stems.size (); i++) do { Grob *s = stems[i]; Direction sd = get_grob_direction (s); @@ -586,7 +586,7 @@ Beam::set_stem_directions (Grob *me, Direction d) Link_array stems =Pointer_group_interface__extract_grobs (me, (Grob*) 0, "stems"); - for (int i=0; i hps_array; - for (int i=0; i < stems.size (); i++) + for (int i= 0; i < stems.size (); i++) { Grob* stem = stems[i]; if (Stem::is_invisible (stem)) @@ -655,7 +655,7 @@ Beam::consider_auto_knees (Grob* me) } Interval max_gap; - Real max_gap_len =0.0; + Real max_gap_len = 0.0; for (int i = gaps.allowed_regions_.size () -1; i >= 0 ; i--) { @@ -839,7 +839,7 @@ Beam::least_squares (SCM smob) + lvs->relative_coordinate (commony, Y_AXIS) - my_y); Real x0 = first_visible_stem (me)->relative_coordinate (commonx, X_AXIS); - for (int i=0; i < stems.size (); i++) + for (int i= 0; i < stems.size (); i++) { Grob* s = stems[i]; @@ -849,7 +849,7 @@ Beam::least_squares (SCM smob) Real dx = last_visible_stem (me)->relative_coordinate (commonx, X_AXIS) - x0; - Real y =0; + Real y = 0; Real slope = 0; Real dy = 0; @@ -888,7 +888,7 @@ Beam::least_squares (SCM smob) else { Array ideals; - for (int i=0; i < stems.size (); i++) + for (int i= 0; i < stems.size (); i++) { Grob* s = stems[i]; if (Stem::is_invisible (s)) @@ -947,7 +947,7 @@ Beam::shift_region_to_valid (SCM grob) return SCM_UNSPECIFIED; Real x0 =fvs->relative_coordinate (commonx, X_AXIS); - for (int i=0; i < stems.size (); i++) + for (int i= 0; i < stems.size (); i++) { Grob* s = stems[i]; @@ -976,7 +976,7 @@ Beam::shift_region_to_valid (SCM grob) */ Interval feasible_left_point; feasible_left_point.set_full (); - for (int i=0; i < stems.size (); i++) + for (int i= 0; i < stems.size (); i++) { Grob* s = stems[i]; if (Stem::is_invisible (s)) @@ -1155,7 +1155,7 @@ Beam::set_stem_lengths (Grob *me) scale_drul (&pos, staff_space); bool gap = false; - Real thick =0.0; + Real thick = 0.0; if (scm_is_number (me->get_property ("gap-count")) &&scm_to_int (me->get_property ("gap-count"))) { @@ -1170,7 +1170,7 @@ Beam::set_stem_lengths (Grob *me) Real xl = fvs ? fvs->relative_coordinate (common[X_AXIS], X_AXIS) : 0.0; Real xr = lvs ? lvs->relative_coordinate (common[X_AXIS], X_AXIS) : 0.0; - for (int i=0; i < stems.size (); i++) + for (int i= 0; i < stems.size (); i++) { Grob* s = stems[i]; if (Stem::is_invisible (s)) @@ -1199,7 +1199,7 @@ Beam::set_beaming (Grob *me, Beaming_info_list *beaming) Pointer_group_interface__extract_grobs (me, (Grob *)0, "stems"); Direction d = LEFT; - for (int i=0; i < stems.size (); i++) + for (int i= 0; i < stems.size (); i++) { /* Don't overwrite user settings. @@ -1236,7 +1236,7 @@ Beam::forced_stem_count (Grob *me) Link_arraystems = Pointer_group_interface__extract_grobs (me, (Grob*) 0, "stems"); int f = 0; - for (int i=0; i < stems.size (); i++) + for (int i= 0; i < stems.size (); i++) { Grob *s = stems[i]; diff --git a/lily/bezier.cc b/lily/bezier.cc index 5b815e6b76..87c0623ba2 100644 --- a/lily/bezier.cc +++ b/lily/bezier.cc @@ -57,7 +57,7 @@ translate (Array* array, Offset o) Formula of the bezier 3-spline - sum_{j=0}^3 (3 over j) z_j (1-t)^ (3-j) t^j + sum_{j= 0}^3 (3 over j) z_j (1-t)^ (3-j) t^j A is the axis of X coordinate. @@ -91,7 +91,7 @@ Bezier::curve_point (Real t)const Real one_min_tj = (1-t)* (1-t)* (1-t); Offset o; - for (int j=0 ; j < 4; j++) + for (int j= 0 ; j < 4; j++) { o += control_[j] * binomial_coefficient (3, j) * pow (t,j) * pow (1-t, 3-j); @@ -114,7 +114,7 @@ Polynomial Bezier::polynomial (Axis a)const { Polynomial p (0.0); - for (int j=0; j <= 3; j++) + for (int j= 0; j <= 3; j++) { p += (control_[j][a] * binomial_coefficient (3, j)) @@ -219,7 +219,7 @@ Bezier::translate (Offset o) void Bezier::assert_sanity () const { - for (int i=0; i < CONTROL_COUNT; i++) + for (int i= 0; i < CONTROL_COUNT; i++) assert (!isnan (control_[i].length ()) && !isinf (control_[i].length ())); } @@ -228,7 +228,7 @@ void Bezier::reverse () { Bezier b2; - for (int i =0; i < CONTROL_COUNT; i++) + for (int i = 0; i < CONTROL_COUNT; i++) b2.control_[CONTROL_COUNT-i-1] = control_[i]; *this = b2; } diff --git a/lily/break-algorithm.cc b/lily/break-algorithm.cc index 4d44c06841..50064dad46 100644 --- a/lily/break-algorithm.cc +++ b/lily/break-algorithm.cc @@ -24,7 +24,7 @@ Break_algorithm::find_break_indices () const Link_array all = pscore_->system_->columns (); Array retval; - for (int i=0; i < all.size (); i++) + for (int i= 0; i < all.size (); i++) if (Item::is_breakable (all[i])) retval.push (i); @@ -42,7 +42,7 @@ Break_algorithm::find_breaks () const Link_array all = pscore_->system_->columns (); Link_array retval; - for (int i=0; i < all.size (); i++) + for (int i= 0; i < all.size (); i++) if (Item::is_breakable (all[i])) retval.push (all[i]); diff --git a/lily/break-align-interface.cc b/lily/break-align-interface.cc index 1d302e6aea..1b1b1abde3 100644 --- a/lily/break-align-interface.cc +++ b/lily/break-align-interface.cc @@ -120,7 +120,7 @@ Break_align_interface::do_alignment (Grob *grob) Array extents; int last_nonempty = -1; - for (int i=0; i < elems.size (); i++) + for (int i= 0; i < elems.size (); i++) { Interval y = elems[i]->extent (elems[i], X_AXIS); extents.push (y); @@ -246,8 +246,8 @@ Break_align_interface::do_alignment (Grob *grob) Real here = 0.0; Interval total_extent; - Real alignment_off =0.0; - for (int i =0 ; i < offsets.size (); i++) + Real alignment_off = 0.0; + for (int i = 0 ; i < offsets.size (); i++) { here += offsets[i]; if (i == edge_idx) @@ -264,7 +264,7 @@ Break_align_interface::do_alignment (Grob *grob) alignment_off = -total_extent[LEFT]; here = alignment_off; - for (int i =0 ; i < offsets.size (); i++) + for (int i = 0 ; i < offsets.size (); i++) { here += offsets[i]; elems[i]->translate_axis (here, X_AXIS); diff --git a/lily/break-substitution.cc b/lily/break-substitution.cc index d97bdb5a51..3fcf35b6f6 100644 --- a/lily/break-substitution.cc +++ b/lily/break-substitution.cc @@ -285,7 +285,7 @@ struct Substitution_entry } Substitution_entry () { - grob_ =0; + grob_ = 0; left_ = right_ = -2; } diff --git a/lily/chord-name-engraver.cc b/lily/chord-name-engraver.cc index 7982645663..cb92fe9589 100644 --- a/lily/chord-name-engraver.cc +++ b/lily/chord-name-engraver.cc @@ -71,7 +71,7 @@ Chord_name_engraver::process_music () SCM pitches = SCM_EOL; Music* inversion_event = 0; - for (int i =0 ; i < notes_.size (); i++) + for (int i = 0 ; i < notes_.size (); i++) { Music *n = notes_[i]; SCM p = n->get_property ("pitch"); diff --git a/lily/chord-tremolo-engraver.cc b/lily/chord-tremolo-engraver.cc index b7ecae6d21..705e53e83c 100644 --- a/lily/chord-tremolo-engraver.cc +++ b/lily/chord-tremolo-engraver.cc @@ -69,7 +69,7 @@ protected: Chord_tremolo_engraver::Chord_tremolo_engraver () { beam_ = finished_beam_ = 0; - repeat_ =0; + repeat_ = 0; flags_ = 0; stem_tremolo_ = 0; sequential_body_b_ = false; diff --git a/lily/clef-engraver.cc b/lily/clef-engraver.cc index c38d0cb69a..999e553f05 100644 --- a/lily/clef-engraver.cc +++ b/lily/clef-engraver.cc @@ -178,7 +178,7 @@ Clef_engraver::stop_translation_timestep () } } - clef_ =0; + clef_ = 0; octavate_ = 0; } diff --git a/lily/collision-engraver.cc b/lily/collision-engraver.cc index c468b61061..f18f1dc612 100644 --- a/lily/collision-engraver.cc +++ b/lily/collision-engraver.cc @@ -12,9 +12,6 @@ #include "engraver.hh" #include "axis-group-interface.hh" -/* - collect Note_column, and as soon as there are 2 or more, put them in - a collision object. */ class Collision_engraver : public Engraver { Item * col_; @@ -40,7 +37,7 @@ Collision_engraver::process_acknowledged_grobs () } - for (int i=0; i< note_columns_.size (); i++) + for (int i= 0; i< note_columns_.size (); i++) Note_collision_interface::add_column (col_,note_columns_[i]); } @@ -60,20 +57,20 @@ Collision_engraver::acknowledge_grob (Grob_info i) void Collision_engraver::stop_translation_timestep () { - col_ =0; + col_ = 0; note_columns_.clear (); } Collision_engraver::Collision_engraver () { - col_ =0; + col_ = 0; } ENTER_DESCRIPTION (Collision_engraver, -/* descr */ "", +/* descr */ "Collect NoteColumns, and as soon as there are two or more, put them in a NoteCollision object.", /* creats*/ "NoteCollision", /* accepts */ "", /* acks */ "note-column-interface", diff --git a/lily/context-def.cc b/lily/context-def.cc index 82b32ef4b7..6c0f7f87b5 100644 --- a/lily/context-def.cc +++ b/lily/context-def.cc @@ -169,7 +169,7 @@ Context_def::path_to_acceptable_context (SCM type_sym, Output_def *odef) const accepteds.push (t); Link_array best_result; - for (int i=0; i < accepteds.size (); i++) + for (int i= 0; i < accepteds.size (); i++) { /* do not check aliases, because \context Staff should not create RhythmicStaff. */ @@ -181,7 +181,7 @@ Context_def::path_to_acceptable_context (SCM type_sym, Output_def *odef) const } int best_depth= INT_MAX; - for (int i=0; i < accepteds.size (); i++) + for (int i= 0; i < accepteds.size (); i++) { Context_def * g = accepteds[i]; diff --git a/lily/context-handle.cc b/lily/context-handle.cc index b1e150a407..a18a9eba05 100644 --- a/lily/context-handle.cc +++ b/lily/context-handle.cc @@ -11,12 +11,12 @@ Interpretation_context_handle::Interpretation_context_handle () { - outlet_ =0; + outlet_ = 0; } Interpretation_context_handle::Interpretation_context_handle (Interpretation_context_handle const&s) { - outlet_ =0; + outlet_ = 0; if (s.outlet_) up (s.outlet_); } diff --git a/lily/context.cc b/lily/context.cc index 5d0b1ffb3f..8dc53e2645 100644 --- a/lily/context.cc +++ b/lily/context.cc @@ -127,7 +127,7 @@ Context::create_unique_context (SCM n, SCM operations) Context * current = this; // start at 1. The first one (index 0) will be us. - for (int i=0; i < path.size (); i++) + for (int i= 0; i < path.size (); i++) { SCM ops = (i == path.size () -1) ? operations : SCM_EOL; @@ -150,7 +150,7 @@ Context::create_unique_context (SCM n, SCM operations) { warning (_f ("Cannot find or create new `%s'", ly_symbol2string (n).to_str0 ())); - ret =0; + ret = 0; } return ret; } @@ -186,7 +186,7 @@ Context::find_create_context (SCM n, String id, SCM operations) Context * current = this; // start at 1. The first one (index 0) will be us. - for (int i=0; i < path.size (); i++) + for (int i= 0; i < path.size (); i++) { SCM ops = (i == path.size () -1) ? operations : SCM_EOL; @@ -216,7 +216,7 @@ Context::find_create_context (SCM n, String id, SCM operations) { warning (_f ("Cannot find or create `%s' called `%s'", ly_symbol2string (n).to_str0 (), id)); - ret =0; + ret = 0; } return ret; } diff --git a/lily/dimension-cache.cc b/lily/dimension-cache.cc index 8fe7318f81..893f2bc687 100644 --- a/lily/dimension-cache.cc +++ b/lily/dimension-cache.cc @@ -36,9 +36,9 @@ Dimension_cache::init () offsets_left_ = 0; offset_callbacks_ = SCM_EOL; - offset_ =0.0; + offset_ = 0.0; - parent_ =0; + parent_ = 0; } diff --git a/lily/dot-column-engraver.cc b/lily/dot-column-engraver.cc index 0a45cea586..e6678cc145 100644 --- a/lily/dot-column-engraver.cc +++ b/lily/dot-column-engraver.cc @@ -44,9 +44,9 @@ Dot_column_engraver::stop_translation_timestep () if (stem_ && dotcol_) dotcol_->set_property ("stem", stem_->self_scm ()); - dotcol_ =0; + dotcol_ = 0; heads_.clear (); - stem_ =0; + stem_ = 0; } void diff --git a/lily/dot-column.cc b/lily/dot-column.cc index d44c11ef6d..e464b52fa0 100644 --- a/lily/dot-column.cc +++ b/lily/dot-column.cc @@ -80,7 +80,7 @@ struct Dot_position Dot_position () { dot_ = 0; - pos_ =0; + pos_ = 0; dir_ = CENTER; } }; @@ -165,7 +165,7 @@ shift_one (Dot_configuration const &cfg, { if (new_cfg.find (p) == new_cfg.end ()) { - offset =0; + offset = 0; } new_cfg[p + offset] = i->second; } @@ -194,7 +194,7 @@ shift_one (Dot_configuration const &cfg, { if (new_cfg.find (p) == new_cfg.end ()) { - offset =0; + offset = 0; } new_cfg[p + offset] = i->second; @@ -259,7 +259,7 @@ Dot_column::do_shifts (Grob*me) dots.del (i); Dot_configuration cfg; - for (int i =0;i < dots.size (); i++) + for (int i = 0;i < dots.size (); i++) { Dot_position dp; dp.dot_ = dots[i]; diff --git a/lily/drum-note-engraver.cc b/lily/drum-note-engraver.cc index f650589012..a1527b237f 100644 --- a/lily/drum-note-engraver.cc +++ b/lily/drum-note-engraver.cc @@ -54,7 +54,7 @@ void Drum_notes_engraver::process_music () { SCM tab = 0; - for (int i=0; i < events_.size (); i++) + for (int i= 0; i < events_.size (); i++) { if (!tab) tab = get_property ("drumStyleTable"); @@ -125,7 +125,7 @@ Drum_notes_engraver::acknowledge_grob (Grob_info inf) { if (Stem::has_interface (inf.grob_)) { - for (int i=0; i < scripts_.size (); i++) + for (int i= 0; i < scripts_.size (); i++) { Grob*e = scripts_[i]; @@ -141,7 +141,7 @@ Drum_notes_engraver::acknowledge_grob (Grob_info inf) } else if (Note_column::has_interface (inf.grob_)) { - for (int i=0; i < scripts_.size (); i++) + for (int i= 0; i < scripts_.size (); i++) { Grob *e = scripts_[i]; diff --git a/lily/drum-note-performer.cc b/lily/drum-note-performer.cc index f104ae705f..d143e883ff 100644 --- a/lily/drum-note-performer.cc +++ b/lily/drum-note-performer.cc @@ -29,7 +29,7 @@ private: void Drum_note_performer::create_audio_elements () { - SCM tab =0; + SCM tab = 0; if (!tab) tab = get_property ("drumPitchTable"); while (note_evs_.size ()) @@ -60,7 +60,7 @@ Drum_note_performer::stop_translation_timestep () // why don't grace notes show up here? // --> grace notes effectively do not get delayed Global_context * global = get_global_context (); - for (int i=0; i < notes_.size (); i++) + for (int i= 0; i < notes_.size (); i++) { Audio_note* n = notes_[i]; Moment m= n->delayed_until_mom_; @@ -75,13 +75,13 @@ Drum_note_performer::stop_translation_timestep () } Moment now = now_mom (); - for (int i=0; i < notes_.size (); i++) + for (int i= 0; i < notes_.size (); i++) { play_element (notes_[i]); } notes_.clear (); note_evs_.clear (); - for (int i=0; i < delayeds_.size (); i++) + for (int i= 0; i < delayeds_.size (); i++) { Audio_note* n = delayeds_[i]; if (n->delayed_until_mom_ <= now) diff --git a/lily/dynamic-engraver.cc b/lily/dynamic-engraver.cc index 4675737005..be821ca7f6 100644 --- a/lily/dynamic-engraver.cc +++ b/lily/dynamic-engraver.cc @@ -76,7 +76,7 @@ Dynamic_engraver::Dynamic_engraver () line_spanner_ = 0; finished_line_spanner_ = 0; current_cresc_ev_ = 0; - cresc_ =0; + cresc_ = 0; script_ev_ = 0; accepted_spanreqs_drul_[START] = 0; @@ -333,7 +333,7 @@ Dynamic_engraver::typeset_all () add_bound_item (finished_line_spanner_, finished_cresc_->get_bound (RIGHT)); } - finished_cresc_ =0; + finished_cresc_ = 0; } script_ = 0; diff --git a/lily/engraver-group-engraver.cc b/lily/engraver-group-engraver.cc index dcb46f9792..5592d7b55c 100644 --- a/lily/engraver-group-engraver.cc +++ b/lily/engraver-group-engraver.cc @@ -36,7 +36,7 @@ Engraver_group_engraver::acknowledge_grobs () SCM meta_sym = ly_symbol2scm ("meta"); - for (int j =0; j < announce_infos_.size (); j++) + for (int j = 0; j < announce_infos_.size (); j++) { Grob_info info = announce_infos_[j]; diff --git a/lily/extender-engraver.cc b/lily/extender-engraver.cc index c6fb7167e3..73f8f58b7e 100644 --- a/lily/extender-engraver.cc +++ b/lily/extender-engraver.cc @@ -147,7 +147,7 @@ Extender_engraver::finalize () if (!pending_extender_->get_bound (RIGHT)) pending_extender_->warning (_ ("unterminated extender")); - pending_extender_ =0; + pending_extender_ = 0; } } diff --git a/lily/fingering-engraver.cc b/lily/fingering-engraver.cc index 95a4b559cd..9b2c9cae59 100644 --- a/lily/fingering-engraver.cc +++ b/lily/fingering-engraver.cc @@ -47,14 +47,14 @@ Fingering_engraver::acknowledge_grob (Grob_info inf) { if (Stem::has_interface (inf.grob_)) { - for (int i=0; i < fingerings_.size (); i++) + for (int i= 0; i < fingerings_.size (); i++) { Side_position_interface::add_support (fingerings_[i], inf.grob_); } } else if (Rhythmic_head::has_interface (inf.grob_)) { - for (int i=0; i < fingerings_.size (); i++) + for (int i= 0; i < fingerings_.size (); i++) { Grob*t = fingerings_[i]; Side_position_interface::add_support (t,inf.grob_); diff --git a/lily/folded-repeat-iterator.cc b/lily/folded-repeat-iterator.cc index cf9b5438ed..16456ed41f 100644 --- a/lily/folded-repeat-iterator.cc +++ b/lily/folded-repeat-iterator.cc @@ -84,7 +84,7 @@ Folded_repeat_iterator::process (Moment m) if (!alternative_iter_->ok ()) { alternative_iter_->quit (); - alternative_iter_ =0; + alternative_iter_ = 0; } } } diff --git a/lily/glissando-engraver.cc b/lily/glissando-engraver.cc index e1ebe69182..511badf58e 100644 --- a/lily/glissando-engraver.cc +++ b/lily/glissando-engraver.cc @@ -79,7 +79,7 @@ Glissando_engraver::stop_translation_timestep () { if (last_line_ && last_line_->get_bound (RIGHT)) { - last_line_ =0; + last_line_ = 0; } if (line_) { @@ -104,7 +104,7 @@ Glissando_engraver::finalize () warning (msg); line_->suicide (); - line_ =0; + line_ = 0; } } diff --git a/lily/global-context.cc b/lily/global-context.cc index e7be444321..6b6ba4e5a6 100644 --- a/lily/global-context.cc +++ b/lily/global-context.cc @@ -53,7 +53,7 @@ Global_context::add_moment_to_process (Moment m) if (m < now_mom_) programming_error ("Trying to freeze in time."); - for (int i=0; i < extra_mom_pq_.size (); i++) + for (int i= 0; i < extra_mom_pq_.size (); i++) if (extra_mom_pq_[i] == m) return; extra_mom_pq_.insert (m); diff --git a/lily/global-ctor.cc b/lily/global-ctor.cc index 70e7dc848a..ce0c6224c2 100644 --- a/lily/global-ctor.cc +++ b/lily/global-ctor.cc @@ -24,6 +24,6 @@ add_constructor (Global_ctor c) void call_constructors () { - for (int i=0; i < ctor_global_statics_->size (); i++) + for (int i= 0; i < ctor_global_statics_->size (); i++) (ctor_global_statics_->elem (i)) (); } diff --git a/lily/gourlay-breaking.cc b/lily/gourlay-breaking.cc index 1c6fa03f27..c25d2403a6 100644 --- a/lily/gourlay-breaking.cc +++ b/lily/gourlay-breaking.cc @@ -56,7 +56,7 @@ struct Break_node { void print_break_nodes (Array const & arr) { - for (int i =0; i < arr.size (); i++) + for (int i = 0; i < arr.size (); i++) { printf ( "node %d: ", i); arr[i].print (); diff --git a/lily/grob-pitch-tuple.cc b/lily/grob-pitch-tuple.cc index 883af20ca6..c112c5ebcb 100644 --- a/lily/grob-pitch-tuple.cc +++ b/lily/grob-pitch-tuple.cc @@ -21,7 +21,7 @@ int compare (Grob_pitch_tuple const &a, Grob_pitch_tuple const &b) Grob_pitch_tuple::Grob_pitch_tuple () { - head_ =0; + head_ = 0; end_ = 0; } diff --git a/lily/grob.cc b/lily/grob.cc index 978fb1a345..ffee088446 100644 --- a/lily/grob.cc +++ b/lily/grob.cc @@ -90,7 +90,7 @@ Grob::Grob (SCM basicprops, { SCM l = get_property (onames[a]); - if (scm_ilength (l) >=0) + if (scm_ilength (l) >= 0) { dim_cache_[a].offset_callbacks_ = l; dim_cache_[a].offsets_left_ = scm_ilength (l); diff --git a/lily/hyphen-engraver.cc b/lily/hyphen-engraver.cc index 8f7193fad1..6d18b63ff0 100644 --- a/lily/hyphen-engraver.cc +++ b/lily/hyphen-engraver.cc @@ -109,7 +109,7 @@ Hyphen_engraver::finalize () finished_hyphen_->warning (_("unterminated hyphen; removing")); finished_hyphen_->suicide (); } - finished_hyphen_ =0; + finished_hyphen_ = 0; } } @@ -135,7 +135,7 @@ Hyphen_engraver::stop_translation_timestep () if (finished_hyphen_ && hyphen_) { programming_error ("Haven't finished hyphen yet."); - finished_hyphen_ =0; + finished_hyphen_ = 0; } if (hyphen_) diff --git a/lily/include/break-algorithm.hh b/lily/include/break-algorithm.hh index 6d0eb51181..e4e6590f07 100644 --- a/lily/include/break-algorithm.hh +++ b/lily/include/break-algorithm.hh @@ -32,7 +32,7 @@ protected: Simple_spacer_wrapper* generate_spacing_problem (Link_array const &, Interval) const; - virtual Array do_solve () const=0; + virtual Array do_solve () const= 0; public: Simple_spacer* (*get_line_spacer) (); diff --git a/lily/include/grace-fixup.hh b/lily/include/grace-fixup.hh index 22b4a74136..c655969c4e 100644 --- a/lily/include/grace-fixup.hh +++ b/lily/include/grace-fixup.hh @@ -28,7 +28,7 @@ voiceA = \notes { \grace b16 c'2 } voiceB = \notes { c'2 \voiceA } - the iterator for voiceB will contain a fixup entry with (START=0/1, + the iterator for voiceB will contain a fixup entry with (START= 0/1, LENGTH=2/1, GRACE_START=(0G-1/16) ) Graces at the start of a sequential music iterator are handled diff --git a/lily/include/grob.hh b/lily/include/grob.hh index f77bd09480..17b6cfa475 100644 --- a/lily/include/grob.hh +++ b/lily/include/grob.hh @@ -18,7 +18,7 @@ for administration of what was done already */ enum Grob_status { - ORPHAN=0, // not yet added to Paper_score + ORPHAN= 0, // not yet added to Paper_score PRECALCING, PRECALCED, // calcs before spacing done POSTCALCING, // busy calculating. This is used to trap cyclic deps. diff --git a/lily/item.cc b/lily/item.cc index 2f4ba5f361..df7a6c5c75 100644 --- a/lily/item.cc +++ b/lily/item.cc @@ -25,7 +25,7 @@ Item::clone (int count) const Item::Item (SCM s, Object_key const *key) : Grob (s, key) { - broken_to_drul_[LEFT] = broken_to_drul_[RIGHT]=0; + broken_to_drul_[LEFT] = broken_to_drul_[RIGHT]= 0; Group_interface::add_thing (this, ly_symbol2scm ("interfaces"), ly_symbol2scm ("item-interface")); } @@ -35,7 +35,7 @@ Item::Item (SCM s, Object_key const *key) Item::Item (Item const &s, int copy_count) : Grob (s, copy_count) { - broken_to_drul_[LEFT] = broken_to_drul_[RIGHT] =0; + broken_to_drul_[LEFT] = broken_to_drul_[RIGHT] = 0; } diff --git a/lily/least-squares.cc b/lily/least-squares.cc index abac75b1bd..78f42bd1d7 100644 --- a/lily/least-squares.cc +++ b/lily/least-squares.cc @@ -17,10 +17,10 @@ minimise_least_squares (Real * coef, Real * offset, { Real sx = 0.0; Real sy = 0.0; - Real sqx =0.0; + Real sqx = 0.0; Real sxy = 0.0; - for (int i=0; i < input.size ();i++) + for (int i= 0; i < input.size ();i++) { Real x=input[i][X_AXIS]; Real y = input[i][Y_AXIS]; @@ -31,8 +31,8 @@ minimise_least_squares (Real * coef, Real * offset, } int N = input.size (); - *coef =0.0; - *offset =0.; + *coef = 0.0; + *offset = 0.; Real den = (N*sqx - sqr (sx)); if (!N || !den) diff --git a/lily/ledger-line-spanner.cc b/lily/ledger-line-spanner.cc index f72caba6ea..14074a44a9 100644 --- a/lily/ledger-line-spanner.cc +++ b/lily/ledger-line-spanner.cc @@ -213,7 +213,7 @@ Ledger_line_spanner::print (SCM smob) Interval max_size = reqs[Paper_column::get_rank (h->get_column ())][Direction (sign(pos))].ledger_extent_; ledger_size.intersect (max_size); - Real left_shorten =0.0; + Real left_shorten = 0.0; if (Grob * g = unsmob_grob (h->get_property ("accidental-grob"))) { Interval accidental_size = g->extent (common[X_AXIS], X_AXIS); diff --git a/lily/lexer.ll b/lily/lexer.ll index b0d9d9f051..5d317a2979 100644 --- a/lily/lexer.ll +++ b/lily/lexer.ll @@ -294,7 +294,7 @@ HYPHEN -- error_level_ = 1; } - for (int i=0; i < n; i++) + for (int i= 0; i < n; i++) { yyinput (); } @@ -772,7 +772,7 @@ Lily_lexer::is_figure_state () const void strip_leading_white (String&s) { - int i=0; + int i= 0; for (; i < s.length (); i++) if (!isspace (s[i])) break; @@ -829,7 +829,7 @@ lyric_fudge (String s) s = String (chars); delete[] chars; - int i =0; + int i = 0; if ((i=s.index ("\\,")) != -1) // change "\," to TeX's "\c " { * (s.get_str0 () + i + 1) = 'c'; diff --git a/lily/lyric-combine-music-iterator.cc b/lily/lyric-combine-music-iterator.cc index feebdceb0f..6f118427a8 100644 --- a/lily/lyric-combine-music-iterator.cc +++ b/lily/lyric-combine-music-iterator.cc @@ -62,8 +62,8 @@ Music *melisma_playing_req; Lyric_combine_music_iterator::Lyric_combine_music_iterator () { - music_iter_ =0; - lyric_iter_ =0; + music_iter_ = 0; + lyric_iter_ = 0; if (!busy_req) { diff --git a/lily/mark-engraver.cc b/lily/mark-engraver.cc index 37f903b3a7..8d22aba1c5 100644 --- a/lily/mark-engraver.cc +++ b/lily/mark-engraver.cc @@ -42,7 +42,7 @@ private: Mark_engraver::Mark_engraver () { - text_ =0; + text_ = 0; mark_ev_ = 0; } @@ -68,7 +68,7 @@ Mark_engraver::stop_translation_timestep () { SCM lst = get_property ("stavesFound"); text_->set_property ("side-support-elements" , lst); - text_ =0; + text_ = 0; } mark_ev_ = 0; } diff --git a/lily/metronome-engraver.cc b/lily/metronome-engraver.cc index 19049500b8..752b3358a9 100644 --- a/lily/metronome-engraver.cc +++ b/lily/metronome-engraver.cc @@ -36,7 +36,7 @@ protected: Metronome_mark_engraver::Metronome_mark_engraver () { - text_ =0; + text_ = 0; mark_ev_ = 0; } @@ -49,7 +49,7 @@ Metronome_mark_engraver::stop_translation_timestep () text_->set_parent (mc, X_AXIS); text_->set_property ("side-support-elements" , get_property ("stavesFound")); - text_ =0; + text_ = 0; } mark_ev_ = 0; } diff --git a/lily/midi-walker.cc b/lily/midi-walker.cc index 59ed2193d4..72c175a956 100644 --- a/lily/midi-walker.cc +++ b/lily/midi-walker.cc @@ -58,7 +58,7 @@ Midi_walker::do_start_note (Midi_note* note) Moment stop_mom = note->get_length () + ptr->audio_column_->at_mom (); bool play_start = true; - for (int i=0; i < stop_note_queue.size (); i++) + for (int i= 0; i < stop_note_queue.size (); i++) { /* if this pith already in queue */ if (stop_note_queue[i].val->get_pitch () == note->get_pitch ()) diff --git a/lily/misc.cc b/lily/misc.cc index 95d730b9e7..01e72f6258 100644 --- a/lily/misc.cc +++ b/lily/misc.cc @@ -18,7 +18,7 @@ int intlog2 (int d) { assert (d); - int i=0; + int i= 0; while ((d != 1)) { d /= 2; diff --git a/lily/multi-measure-rest-engraver.cc b/lily/multi-measure-rest-engraver.cc index a1557679c7..b9cbec39c8 100644 --- a/lily/multi-measure-rest-engraver.cc +++ b/lily/multi-measure-rest-engraver.cc @@ -49,7 +49,7 @@ Multi_measure_rest_engraver::Multi_measure_rest_engraver () bar_seen_ = false; start_measure_ = 0; mmrest_ = 0; - last_rest_ =0; + last_rest_ = 0; rest_ev_ = 0; } @@ -105,8 +105,8 @@ Multi_measure_rest_engraver::process_music () */ Direction d = DOWN; do { - Grob *last =0; - for (int i=0; i get_property ("direction")) { @@ -118,7 +118,7 @@ Multi_measure_rest_engraver::process_music () } while (flip (&d) != DOWN); } - for (int i =0 ; i < numbers_.size (); i++) + for (int i = 0 ; i < numbers_.size (); i++) { Side_position_interface::add_support (numbers_[i], mmrest_); numbers_[i]->set_parent (mmrest_, Y_AXIS); diff --git a/lily/multi-measure-rest.cc b/lily/multi-measure-rest.cc index 30c1d0e06c..1b13aad8c5 100644 --- a/lily/multi-measure-rest.cc +++ b/lily/multi-measure-rest.cc @@ -319,7 +319,7 @@ Multi_measure_rest::set_spacing_rods (SCM smob) Real sym_width = symbol_stencil (me, 0.0).extent (X_AXIS).length (); - for (int i=0; i < 4; i++) + for (int i= 0; i < 4; i++) { Item *li = combinations[i][0]; Item *ri = combinations[i][1]; diff --git a/lily/music-iterator.cc b/lily/music-iterator.cc index 7cf30a3c2c..e6fbf64304 100644 --- a/lily/music-iterator.cc +++ b/lily/music-iterator.cc @@ -76,7 +76,7 @@ Music_iterator::ok () const SCM Music_iterator::get_static_get_iterator (Music *m) { - Music_iterator * p =0; + Music_iterator * p = 0; SCM ctor = m->get_property ("iterator-ctor") ; SCM iter = SCM_EOL; diff --git a/lily/music-sequence.cc b/lily/music-sequence.cc index acaf88d389..928b8617bf 100644 --- a/lily/music-sequence.cc +++ b/lily/music-sequence.cc @@ -81,7 +81,7 @@ Pitch music_list_to_relative (SCM l,Pitch p, bool ret_first) { Pitch first = p; - int count=0; + int count= 0; Pitch last = p; for (SCM s = l; scm_is_pair (s); s = scm_cdr (s)) diff --git a/lily/new-lyric-combine-music-iterator.cc b/lily/new-lyric-combine-music-iterator.cc index 690e828b98..e14512c861 100644 --- a/lily/new-lyric-combine-music-iterator.cc +++ b/lily/new-lyric-combine-music-iterator.cc @@ -52,8 +52,8 @@ New_lyric_combine_music_iterator::New_lyric_combine_music_iterator () { music_found_ = false; made_association_ = false; - lyric_iter_ =0; - music_context_ =0; + lyric_iter_ = 0; + music_context_ = 0; lyrics_context_ = 0; /* diff --git a/lily/note-collision.cc b/lily/note-collision.cc index dcb43adc85..b314cb2faf 100644 --- a/lily/note-collision.cc +++ b/lily/note-collision.cc @@ -140,7 +140,7 @@ check_meshing_chords (Grob *me, bool distant_half_collide = false; bool full_collide = false; - int i = 0, j=0; + int i = 0, j= 0; while (i < ups.size () && j < dps.size ()) { if (abs (ups[i] - dps[j]) == 1) @@ -288,7 +288,7 @@ check_meshing_chords (Grob *me, Direction d = UP; do { - for (int i=0; i < clash_groups[d].size (); i++) + for (int i= 0; i < clash_groups[d].size (); i++) (*offsets)[d][i] += d * shift_amount; } while ((flip (&d))!= UP); @@ -395,7 +395,7 @@ Note_collision_interface::automatic_shift (Grob *me, Array & shift (shifts[d]); Link_array & clashes (clash_groups[d]); - for (int i=0; i < clashes.size (); i++) + for (int i= 0; i < clashes.size (); i++) { SCM sh = clashes[i]->get_property ("horizontal-shift"); @@ -422,7 +422,7 @@ Note_collision_interface::automatic_shift (Grob *me, d = UP; do { - for (int i=0; i < clash_groups[d].size (); i++) + for (int i= 0; i < clash_groups[d].size (); i++) { Slice s (Note_column::head_positions_interval (clash_groups[d][i])); s[LEFT] --; @@ -465,7 +465,7 @@ Note_collision_interface::automatic_shift (Grob *me, do { - for (int i=0; i < clash_groups[d].size (); i++) + for (int i= 0; i < clash_groups[d].size (); i++) tups = scm_cons (scm_cons (clash_groups[d][i]->self_scm (), scm_make_real (offsets[d][i])), tups); diff --git a/lily/note-heads-engraver.cc b/lily/note-heads-engraver.cc index 8ca7dc97c3..595750e244 100644 --- a/lily/note-heads-engraver.cc +++ b/lily/note-heads-engraver.cc @@ -53,7 +53,7 @@ Note_heads_engraver::try_music (Music *m) void Note_heads_engraver::process_music () { - for (int i=0; i < note_evs_.size (); i++) + for (int i= 0; i < note_evs_.size (); i++) { Music * ev = note_evs_[i]; diff --git a/lily/note-name-engraver.cc b/lily/note-name-engraver.cc index af468e0753..e9787ce7a1 100644 --- a/lily/note-name-engraver.cc +++ b/lily/note-name-engraver.cc @@ -37,7 +37,7 @@ void Note_name_engraver::process_music () { String s ; - for (int i=0; i < events_.size (); i++) + for (int i= 0; i < events_.size (); i++) { if (i) s += " "; diff --git a/lily/note-performer.cc b/lily/note-performer.cc index c0ed895f00..71799e1c07 100644 --- a/lily/note-performer.cc +++ b/lily/note-performer.cc @@ -66,7 +66,7 @@ Note_performer::stop_translation_timestep () // why don't grace notes show up here? // --> grace notes effectively do not get delayed Global_context * global = get_global_context (); - for (int i=0; i < notes_.size (); i++) + for (int i= 0; i < notes_.size (); i++) { Audio_note* n = notes_[i]; Moment m= n->delayed_until_mom_; @@ -81,13 +81,13 @@ Note_performer::stop_translation_timestep () } Moment now = now_mom (); - for (int i=0; i < notes_.size (); i++) + for (int i= 0; i < notes_.size (); i++) { play_element (notes_[i]); } notes_.clear (); note_evs_.clear (); - for (int i=0; i < delayeds_.size (); i++) + for (int i= 0; i < delayeds_.size (); i++) { Audio_note* n = delayeds_[i]; if (n->delayed_until_mom_ <= now) diff --git a/lily/ottava-engraver.cc b/lily/ottava-engraver.cc index bb771d6761..0cf47d5039 100644 --- a/lily/ottava-engraver.cc +++ b/lily/ottava-engraver.cc @@ -39,7 +39,7 @@ Ottava_spanner_engraver::derived_mark () const Ottava_spanner_engraver::Ottava_spanner_engraver () { finished_ = 0; - span_ =0; + span_ = 0; last_ottavation_ = SCM_EOL; } diff --git a/lily/paper-column.cc b/lily/paper-column.cc index bb3d8ad42e..1c297f0a33 100644 --- a/lily/paper-column.cc +++ b/lily/paper-column.cc @@ -80,7 +80,7 @@ Paper_column::Paper_column (Paper_column const& src, int count) : Item (src, count) { system_ = 0; - rank_ = count; + rank_ = src.rank_; } diff --git a/lily/part-combine-engraver.cc b/lily/part-combine-engraver.cc index fd70968f15..2938f281d4 100644 --- a/lily/part-combine-engraver.cc +++ b/lily/part-combine-engraver.cc @@ -40,7 +40,7 @@ Part_combine_engraver::try_music (Music*m) Part_combine_engraver::Part_combine_engraver () { text_ = 0; - event_ =0; + event_ = 0; } void diff --git a/lily/percent-repeat-engraver.cc b/lily/percent-repeat-engraver.cc index 8b5c04f530..325f9306b6 100644 --- a/lily/percent-repeat-engraver.cc +++ b/lily/percent-repeat-engraver.cc @@ -66,7 +66,7 @@ Percent_repeat_engraver::Percent_repeat_engraver () { perc_ = 0; finished_perc_ = 0; - repeat_ =0; + repeat_ = 0; double_percent_ = 0; } diff --git a/lily/performance.cc b/lily/performance.cc index acb78d194c..c2b822e765 100644 --- a/lily/performance.cc +++ b/lily/performance.cc @@ -25,7 +25,7 @@ Performance::Performance () { - midi_ =0; + midi_ = 0; audio_elem_p_list_ = 0; } diff --git a/lily/performer-group-performer.cc b/lily/performer-group-performer.cc index a4bfbfa925..5d35c40448 100644 --- a/lily/performer-group-performer.cc +++ b/lily/performer-group-performer.cc @@ -37,7 +37,7 @@ Performer_group_performer::announce_element (Audio_element_info info) void Performer_group_performer::acknowledge_audio_elements () { - for (int j =0; j < announce_infos_.size (); j++) + for (int j = 0; j < announce_infos_.size (); j++) { Audio_element_info info = announce_infos_[j]; diff --git a/lily/piano-pedal-performer.cc b/lily/piano-pedal-performer.cc index 25f8c618af..cd665d6da0 100644 --- a/lily/piano-pedal-performer.cc +++ b/lily/piano-pedal-performer.cc @@ -105,7 +105,7 @@ Piano_pedal_performer::create_audio_elements () void Piano_pedal_performer::stop_translation_timestep () { - for (int i=0; i< audios_.size (); i++) + for (int i= 0; i< audios_.size (); i++) play_element (audios_[i]); audios_.clear (); } diff --git a/lily/repeated-music.cc b/lily/repeated-music.cc index ea2805b1c4..6cf1ff9ce9 100644 --- a/lily/repeated-music.cc +++ b/lily/repeated-music.cc @@ -64,8 +64,8 @@ Repeated_music::alternatives_get_length (bool fold) const if (fold) return Music_sequence::maximum_length (alternatives ()); - Moment m =0; - int done =0; + Moment m = 0; + int done = 0; SCM p = alternatives (); while (scm_is_pair (p) && done < repeat_count ()) diff --git a/lily/rest-collision-engraver.cc b/lily/rest-collision-engraver.cc index 7af8ad7a73..b6616cce2b 100644 --- a/lily/rest-collision-engraver.cc +++ b/lily/rest-collision-engraver.cc @@ -26,7 +26,7 @@ public: Rest_collision_engraver::Rest_collision_engraver () { - rest_collision_ =0; + rest_collision_ = 0; rest_count_ = 0; } @@ -43,7 +43,7 @@ Rest_collision_engraver::process_acknowledged_grobs () rest_collision_ = make_item ("RestCollision", SCM_EOL); - for (int i=0; i < note_columns_.size (); i++) + for (int i= 0; i < note_columns_.size (); i++) Rest_collision::add_column (rest_collision_,note_columns_[i]); } diff --git a/lily/rest-engraver.cc b/lily/rest-engraver.cc index e3f379c076..91e447613a 100644 --- a/lily/rest-engraver.cc +++ b/lily/rest-engraver.cc @@ -33,22 +33,22 @@ public: */ Rest_engraver::Rest_engraver () { - rest_req_ =0; - rest_ =0; - dot_ =0; + rest_req_ = 0; + rest_ = 0; + dot_ = 0; } void Rest_engraver::start_translation_timestep () { - rest_req_ =0; + rest_req_ = 0; } void Rest_engraver::stop_translation_timestep () { - rest_ =0; - dot_ =0; + rest_ = 0; + dot_ = 0; } void diff --git a/lily/rhythmic-column-engraver.cc b/lily/rhythmic-column-engraver.cc index 8ec466dde5..8b4a1f7f1b 100644 --- a/lily/rhythmic-column-engraver.cc +++ b/lily/rhythmic-column-engraver.cc @@ -61,12 +61,12 @@ protected: Rhythmic_column_engraver::Rhythmic_column_engraver () { - spacing_ =0 ; + spacing_ = 0 ; last_spacing_ = 0; - stem_ =0; - note_column_=0; - dotcol_ =0; + stem_ = 0; + note_column_= 0; + dotcol_ = 0; } @@ -94,7 +94,7 @@ Rhythmic_column_engraver::process_acknowledged_grobs () } - for (int i=0; i < rheads_.size (); i++) + for (int i= 0; i < rheads_.size (); i++) { if (!rheads_[i]->get_parent (X_AXIS)) Note_column::add_head (note_column_, rheads_[i]); @@ -144,16 +144,16 @@ Rhythmic_column_engraver::acknowledge_grob (Grob_info i) void Rhythmic_column_engraver::stop_translation_timestep () { - note_column_ =0; + note_column_ = 0; if (spacing_) { last_spacing_ = spacing_; - spacing_ =0; + spacing_ = 0; } - dotcol_ =0; - stem_ =0; + dotcol_ = 0; + stem_ = 0; } diff --git a/lily/rod.cc b/lily/rod.cc index 0d179d75c8..c1ce62177e 100644 --- a/lily/rod.cc +++ b/lily/rod.cc @@ -17,7 +17,7 @@ Rod::Rod () { distance_ = 0.0; - item_l_drul_[LEFT] = item_l_drul_[RIGHT] =0; + item_l_drul_[LEFT] = item_l_drul_[RIGHT] = 0; } diff --git a/lily/score-engraver.cc b/lily/score-engraver.cc index bfd7c065c6..bfd0908a05 100644 --- a/lily/score-engraver.cc +++ b/lily/score-engraver.cc @@ -26,10 +26,10 @@ */ Score_engraver::Score_engraver () { - system_ =0; - command_column_ =0; - musical_column_ =0; - breaks_ =0; + system_ = 0; + command_column_ = 0; + musical_column_ = 0; + breaks_ = 0; pscore_ = 0; } @@ -170,7 +170,7 @@ Score_engraver::announce_grob (Grob_info info) void Score_engraver::typeset_all () { - for (int i =0; i < elems_.size (); i++) + for (int i = 0; i < elems_.size (); i++) { Grob * elem = elems_[i]; diff --git a/lily/score-performer.cc b/lily/score-performer.cc index ab4843b740..bf5eeb1fa1 100644 --- a/lily/score-performer.cc +++ b/lily/score-performer.cc @@ -85,7 +85,7 @@ Music_output * Score_performer::get_output () { Music_output * o = performance_; - performance_ =0; + performance_ = 0; return o; } diff --git a/lily/script-column-engraver.cc b/lily/script-column-engraver.cc index fa0fb9ffd9..27cdc606d2 100644 --- a/lily/script-column-engraver.cc +++ b/lily/script-column-engraver.cc @@ -30,13 +30,13 @@ protected: Script_column_engraver::Script_column_engraver () { - scol_ =0; + scol_ = 0; } void Script_column_engraver::stop_translation_timestep () { - scol_ =0; + scol_ = 0; scripts_.clear (); } @@ -65,7 +65,7 @@ Script_column_engraver::process_acknowledged_grobs () if (scol_) { - for (int i=0; i < scripts_.size (); i++) + for (int i= 0; i < scripts_.size (); i++) Script_column::add_staff_sided (scol_, scripts_[i]); scripts_.clear (); } diff --git a/lily/separating-line-group-engraver.cc b/lily/separating-line-group-engraver.cc index 1a784ad152..9fb12d6686 100644 --- a/lily/separating-line-group-engraver.cc +++ b/lily/separating-line-group-engraver.cc @@ -63,7 +63,7 @@ Separating_line_group_engraver::Separating_line_group_engraver () { sep_span_ = 0; break_item_ = 0; - musical_item_ =0; + musical_item_ = 0; } void @@ -88,7 +88,7 @@ Separating_line_group_engraver::finalize () Grob *column = unsmob_grob (ccol); sep_span_->set_bound (RIGHT, unsmob_grob (ccol)); - sep_span_ =0; + sep_span_ = 0; for (int i= 0 ; i < last_spacings_.note_spacings_.size (); i++) { @@ -176,7 +176,7 @@ Separating_line_group_engraver::start_translation_timestep () { if (break_item_) context ()->unset_property (ly_symbol2scm ("breakableSeparationItem")); - break_item_ =0; + break_item_ = 0; } void @@ -212,7 +212,7 @@ Separating_line_group_engraver::stop_translation_timestep () Separating_group_spanner::add_spacing_unit (sep_span_, musical_item_); } - musical_item_ =0; + musical_item_ = 0; } diff --git a/lily/sequential-iterator.cc b/lily/sequential-iterator.cc index a1133033cd..370f6a8574 100644 --- a/lily/sequential-iterator.cc +++ b/lily/sequential-iterator.cc @@ -171,7 +171,7 @@ Sequential_iterator::next_element (bool) else if (len.grace_part_ && !len.main_part_) { last_mom_ = here_mom_; - here_mom_.grace_part_ =0; + here_mom_.grace_part_ = 0; } else { diff --git a/lily/simple-spacer.cc b/lily/simple-spacer.cc index 590cbbf58d..d257874666 100644 --- a/lily/simple-spacer.cc +++ b/lily/simple-spacer.cc @@ -71,7 +71,7 @@ Simple_spacer::Simple_spacer () */ active_count_ = 0; force_ = 0.; - indent_ =0.0; + indent_ = 0.0; default_space_ = 20 PT; } @@ -116,7 +116,7 @@ Simple_spacer::add_rod (int l, int r, Real dist) Real Simple_spacer::range_ideal_len (int l, int r) const { - Real d =0.; + Real d = 0.; for (int i=l; i < r; i++) d += springs_[i].ideal_; return d; @@ -125,7 +125,7 @@ Simple_spacer::range_ideal_len (int l, int r) const Real Simple_spacer::range_stiffness (int l, int r) const { - Real den =0.0; + Real den = 0.0; for (int i=l; i < r; i++) { if (springs_[i].is_active_) @@ -139,7 +139,7 @@ Real Simple_spacer::active_blocking_force () const { Real bf = - infinity_f; - for (int i=0; i < springs_.size (); i++) + for (int i= 0; i < springs_.size (); i++) if (springs_[i].is_active_) { bf = bf >? springs_[i].block_force_; @@ -160,7 +160,7 @@ Simple_spacer::active_springs_stiffness () const Real max_block_force = -infinity_f; int max_i = -1; - for (int i=0; i < springs_.size (); i++) + for (int i= 0; i < springs_.size (); i++) { if (springs_[i].block_force_ > max_block_force) { @@ -178,7 +178,7 @@ void Simple_spacer::set_active_states () { /* float comparison is safe, since force is only copied. */ - for (int i=0 ; i = force_) { @@ -190,8 +190,8 @@ Simple_spacer::set_active_states () Real Simple_spacer::configuration_length () const { - Real l =0.; - for (int i=0; i < springs_.size (); i++) + Real l = 0.; + for (int i= 0; i < springs_.size (); i++) l += springs_[i].length (force_); return l; @@ -335,8 +335,8 @@ LY_DEFINE(ly_solve_spring_rod_problem, "ly:solve-spring-rod-problem", Spring_description::Spring_description () { - ideal_ =0.0; - hooke_ =0.0; + ideal_ = 0.0; + hooke_ = 0.0; is_active_ = true; block_force_ = 0.0; } @@ -390,7 +390,7 @@ Simple_spacer_wrapper::solve (Column_x_positions *positions, bool ragged) fucked up wtk1-fugue2 (taking 3 full pages.) */ positions->config_.push (spacer_->indent_); - for (int i=0; i < spacer_->springs_.size (); i++) + for (int i= 0; i < spacer_->springs_.size (); i++) { Real l = spacer_->springs_[i].length ((ragged) ? 0.0 : spacer_->force_); positions->config_.push (positions->config_.top () + l); @@ -487,7 +487,7 @@ Simple_spacer_wrapper::add_columns (Link_array const &icols) } spaced_cols_ = cols; - for (int i=0; i < cols.size () - 1; i++) + for (int i= 0; i < cols.size () - 1; i++) { Spring_smob *spring = 0; @@ -513,7 +513,7 @@ Simple_spacer_wrapper::add_columns (Link_array const &icols) spacer_->add_spring (ideal, hooke); } - for (int i=0; i < cols.size () - 1; i++) + for (int i= 0; i < cols.size () - 1; i++) { for (SCM s = Spaceable_grob::get_minimum_distances (cols[i]); scm_is_pair (s); s = scm_cdr (s)) diff --git a/lily/simultaneous-music-iterator.cc b/lily/simultaneous-music-iterator.cc index 1849c85acd..e2e3c1977b 100644 --- a/lily/simultaneous-music-iterator.cc +++ b/lily/simultaneous-music-iterator.cc @@ -142,7 +142,7 @@ Simultaneous_music_iterator::run_always () const Music_iterator* Simultaneous_music_iterator::try_music_in_children (Music *m) const { - Music_iterator * b=0; + Music_iterator * b= 0; for (SCM s = children_list_; !b && scm_is_pair (s); s = scm_cdr (s)) b =unsmob_iterator (scm_car (s))->try_music (m); return b; diff --git a/lily/slash-repeat-engraver.cc b/lily/slash-repeat-engraver.cc index 14d4de8899..60d4afc2f8 100644 --- a/lily/slash-repeat-engraver.cc +++ b/lily/slash-repeat-engraver.cc @@ -55,7 +55,7 @@ protected: Slash_repeat_engraver::Slash_repeat_engraver () { - repeat_ =0; + repeat_ = 0; beat_slash_ = 0; } diff --git a/lily/slur-configuration.cc b/lily/slur-configuration.cc index d13f96f8e2..626d709a0f 100644 --- a/lily/slur-configuration.cc +++ b/lily/slur-configuration.cc @@ -224,7 +224,7 @@ Slur_configuration::score_encompass (Slur_score_state const &state) { Real x = state.encompass_infos_[j].x_; - bool l_edge = j==0; + bool l_edge = j== 0; bool r_edge = j==state.encompass_infos_.size ()-1; bool edge = l_edge || r_edge; diff --git a/lily/source-file.cc b/lily/source-file.cc index bad88ec625..674b935ec1 100644 --- a/lily/source-file.cc +++ b/lily/source-file.cc @@ -249,7 +249,7 @@ Source_file::get_line (char const* pos_str0) const if (!newline_locations_.size ()) return 1; - int lo=0; + int lo= 0; int hi = newline_locations_.size (); if (newline_locations_[lo] > pos_str0) diff --git a/lily/spacing-engraver.cc b/lily/spacing-engraver.cc index 4ba9f8fb4f..a27820498b 100644 --- a/lily/spacing-engraver.cc +++ b/lily/spacing-engraver.cc @@ -91,7 +91,7 @@ Spacing_engraver::finalize () Grob * p = unsmob_grob (get_property ("currentCommandColumn")); spacing_->set_bound (RIGHT, p); - spacing_ =0; + spacing_ = 0; } } @@ -127,7 +127,7 @@ Spacing_engraver::stop_translation_timestep () { Moment shortest_playing; shortest_playing.set_infinite (1); - for (int i=0; i < playing_durations_.size (); i++) + for (int i= 0; i < playing_durations_.size (); i++) { Music * mus = playing_durations_[i].info_.music_cause (); if (mus) @@ -139,7 +139,7 @@ Spacing_engraver::stop_translation_timestep () Moment starter; starter.set_infinite (1); - for (int i=0; i < now_durations_.size (); i++) + for (int i= 0; i < now_durations_.size (); i++) { Moment m = now_durations_[i].info_.music_cause ()->get_length (); if (m.to_bool ()) diff --git a/lily/spacing-spanner.cc b/lily/spacing-spanner.cc index 14aeee2d7d..a3029ed7af 100644 --- a/lily/spacing-spanner.cc +++ b/lily/spacing-spanner.cc @@ -163,7 +163,7 @@ Spacing_spanner::prune_loose_columns (Grob*me,Link_array *cols, Rational s { Link_array newcols; Real increment = robust_scm2double (me->get_property ("spacing-increment"), 1.2); - for (int i=0; i < cols->size (); i++) + for (int i= 0; i < cols->size (); i++) { if (Item::is_breakable (cols->elem (i)) || Paper_column::is_musical (cols->elem (i))) { @@ -264,7 +264,7 @@ Spacing_spanner::prune_loose_columns (Grob*me,Link_array *cols, Rational s void Spacing_spanner::set_explicit_neighbor_columns (Link_array cols) { - for (int i=0; i < cols.size (); i++) + for (int i= 0; i < cols.size (); i++) { SCM right_neighbors = SCM_EOL; int min_rank = 100000; // inf. @@ -427,7 +427,7 @@ Spacing_spanner::find_shortest (Grob *me, Link_array const &cols) Rational shortest_in_measure; shortest_in_measure.set_infinite (1); - for (int i =0 ; i < cols.size (); i++) + for (int i = 0 ; i < cols.size (); i++) { if (Paper_column::is_musical (cols[i])) { @@ -583,8 +583,8 @@ Spacing_spanner::musical_column_spacing (Grob *me, Item * lc, Item *rc, Real inc music. */ if (Note_spacing::has_interface (wish)) { - Real space =0.0; - Real fixed =0.0; + Real space = 0.0; + Real fixed = 0.0; Note_spacing::get_spacing (wish, rc, base_note_space, increment, &space, &fixed); diff --git a/lily/span-arpeggio-engraver.cc b/lily/span-arpeggio-engraver.cc index d75ff0173b..1c6d9afe3e 100644 --- a/lily/span-arpeggio-engraver.cc +++ b/lily/span-arpeggio-engraver.cc @@ -76,7 +76,7 @@ Span_arpeggio_engraver::stop_translation_timestep () we do this very late, to make sure we also catch `extra' side-pos support like accidentals. */ - for (int i=0; i < arpeggios_.size (); i ++) + for (int i= 0; i < arpeggios_.size (); i ++) { for (SCM s = arpeggios_[i]->get_property ("stems"); scm_is_pair (s); s = scm_cdr (s)) diff --git a/lily/span-bar-engraver.cc b/lily/span-bar-engraver.cc index a36c0ce5f1..f374931cee 100644 --- a/lily/span-bar-engraver.cc +++ b/lily/span-bar-engraver.cc @@ -34,7 +34,7 @@ protected: Span_bar_engraver::Span_bar_engraver () { - spanbar_ =0; + spanbar_ = 0; } void @@ -61,7 +61,7 @@ Span_bar_engraver::stop_translation_timestep () { if (spanbar_) { - for (int i=0; i < bars_.size () ; i++) + for (int i= 0; i < bars_.size () ; i++) Span_bar::add_bar (spanbar_,bars_[i]); SCM vissym =ly_symbol2scm ("break-visibility"); @@ -70,7 +70,7 @@ Span_bar_engraver::stop_translation_timestep () spanbar_->internal_set_property (vissym, vis); - spanbar_ =0; + spanbar_ = 0; } bars_.set_size (0); } diff --git a/lily/span-dynamic-performer.cc b/lily/span-dynamic-performer.cc index e282ba4bba..52afe553a4 100644 --- a/lily/span-dynamic-performer.cc +++ b/lily/span-dynamic-performer.cc @@ -147,7 +147,7 @@ Span_dynamic_performer::stop_translation_timestep () } Moment start_mom = finished_dynamic_tuples_[0].mom_; Moment dt = finished_dynamic_tuples_.top ().mom_ - start_mom; - for (int i=0; i < finished_dynamic_tuples_.size (); i++) + for (int i= 0; i < finished_dynamic_tuples_.size (); i++) { Audio_dynamic_tuple* a = &finished_dynamic_tuples_[i]; Real volume = start_volume + dv * (Real) (a->mom_ - start_mom).main_part_ diff --git a/lily/spanner.cc b/lily/spanner.cc index 3f7ebd7e4b..18f470499a 100644 --- a/lily/spanner.cc +++ b/lily/spanner.cc @@ -212,8 +212,8 @@ Spanner::Spanner (SCM s, Object_key const*key) : Grob (s, key) { break_index_ = 0; - spanned_drul_[LEFT]=0; - spanned_drul_[RIGHT]=0; + spanned_drul_[LEFT]= 0; + spanned_drul_[RIGHT]= 0; Group_interface::add_thing (this, ly_symbol2scm ("interfaces"), ly_symbol2scm ("spanner-interface")); } @@ -221,7 +221,7 @@ Spanner::Spanner (SCM s, Object_key const*key) Spanner::Spanner (Spanner const &s, int count) : Grob (s, count) { - spanned_drul_[LEFT] = spanned_drul_[RIGHT] =0; + spanned_drul_[LEFT] = spanned_drul_[RIGHT] = 0; } Real diff --git a/lily/spring-smob.cc b/lily/spring-smob.cc index e7cc63cc0a..f05f02462f 100644 --- a/lily/spring-smob.cc +++ b/lily/spring-smob.cc @@ -13,7 +13,7 @@ Spring_smob::Spring_smob () { - distance_ =0.; + distance_ = 0.; strength_ =1.0; expand_only_b_ = false; other_ = 0; diff --git a/lily/staff-spacing.cc b/lily/staff-spacing.cc index 88ebb31089..866c33dbb1 100644 --- a/lily/staff-spacing.cc +++ b/lily/staff-spacing.cc @@ -125,7 +125,7 @@ Real Staff_spacing::next_notes_correction (Grob *me, Grob * last_grob) { Interval bar_size = bar_y_positions (last_grob); - Real max_corr =0.0; + Real max_corr = 0.0; for (SCM s = me->get_property ("right-items"); scm_is_pair (s); s = scm_cdr (s)) @@ -148,7 +148,7 @@ Staff_spacing::get_spacing_params (Grob *me, Real * space, Real * fixed) *space = 1.0; *fixed = 1.0; - Grob * separation_item=0; + Grob * separation_item= 0; Item * me_item = dynamic_cast (me); for (SCM s = me->get_property ("left-items"); diff --git a/lily/staff-symbol-engraver.cc b/lily/staff-symbol-engraver.cc index 38c39dffc4..8472086258 100644 --- a/lily/staff-symbol-engraver.cc +++ b/lily/staff-symbol-engraver.cc @@ -61,7 +61,7 @@ Staff_symbol_engraver::finalize () { span_->set_bound (RIGHT,unsmob_grob (get_property ("currentCommandColumn"))); } - span_ =0; + span_ = 0; } void @@ -101,7 +101,7 @@ Tab_staff_symbol_engraver::process_music () if (init) { int k = scm_ilength (get_property ("stringTunings")); - if (k>=0) + if (k>= 0) span_->set_property ("line-count", scm_int2num (k)); } } diff --git a/lily/staff-symbol.cc b/lily/staff-symbol.cc index e458ffdc80..0cd364d81d 100644 --- a/lily/staff-symbol.cc +++ b/lily/staff-symbol.cc @@ -76,7 +76,7 @@ Staff_symbol::print (SCM smob) t); Stencil m; - for (int i=0; i < l; i++) + for (int i= 0; i < l; i++) { Stencil b(a); b.translate_axis (height - i * staff_space (me), Y_AXIS); diff --git a/lily/stem-engraver.cc b/lily/stem-engraver.cc index 11a567dbd0..e2feae158c 100644 --- a/lily/stem-engraver.cc +++ b/lily/stem-engraver.cc @@ -42,7 +42,7 @@ Stem_engraver::Stem_engraver () tremolo_ev_ = 0; stem_ = 0; tremolo_ = 0; - rhythmic_ev_ =0; + rhythmic_ev_ = 0; } void diff --git a/lily/system.cc b/lily/system.cc index cf8854825d..0fad02b0c7 100644 --- a/lily/system.cc +++ b/lily/system.cc @@ -113,7 +113,7 @@ System::get_lines () fixups must be done in broken line_of_scores, because new elements are put over there. */ int count = 0; - for (int i=0; i < broken_intos_.size (); i++) + for (int i= 0; i < broken_intos_.size (); i++) { Grob *se = broken_intos_[i]; SCM all = se->get_property ("all-elements"); diff --git a/lily/tab-note-heads-engraver.cc b/lily/tab-note-heads-engraver.cc index 5730980092..68357bac1c 100644 --- a/lily/tab-note-heads-engraver.cc +++ b/lily/tab-note-heads-engraver.cc @@ -68,7 +68,7 @@ void Tab_note_heads_engraver::process_music () { int j = 0; - for (int i=0; i < note_events_.size (); i++) + for (int i= 0; i < note_events_.size (); i++) { SCM stringTunings = get_property ("stringTunings"); int number_of_strings = ((int) ly_length (stringTunings)); @@ -79,7 +79,7 @@ Tab_note_heads_engraver::process_music () Item * note = make_item ("TabNoteHead", event->self_scm ()); - Music * tabstring_event=0; + Music * tabstring_event= 0; for (SCM s =event->get_property ("articulations"); !tabstring_event && scm_is_pair (s); s = scm_cdr (s)) diff --git a/lily/text-engraver.cc b/lily/text-engraver.cc index c84eefab18..d66196a655 100644 --- a/lily/text-engraver.cc +++ b/lily/text-engraver.cc @@ -46,7 +46,7 @@ Text_engraver::acknowledge_grob (Grob_info inf) { if (Rhythmic_head::has_interface (inf.grob_)) { - for (int i=0; i < texts_.size (); i++) + for (int i= 0; i < texts_.size (); i++) { Grob*t = texts_[i]; Side_position_interface::add_support (t,inf.grob_); @@ -65,7 +65,7 @@ Text_engraver::acknowledge_grob (Grob_info inf) if (Stem::has_interface (inf.grob_)) { - for (int i=0; i < texts_.size (); i++) + for (int i= 0; i < texts_.size (); i++) { Side_position_interface::add_support (texts_[i],inf.grob_); } @@ -77,7 +77,7 @@ Text_engraver::process_acknowledged_grobs () { if (texts_.size ()) return; - for (int i=0; i < evs_.size (); i++) + for (int i= 0; i < evs_.size (); i++) { Music * r = evs_[i]; diff --git a/lily/text-spanner-engraver.cc b/lily/text-spanner-engraver.cc index c60ca144ce..38bebe1254 100644 --- a/lily/text-spanner-engraver.cc +++ b/lily/text-spanner-engraver.cc @@ -34,7 +34,7 @@ Text_spanner_engraver::Text_spanner_engraver () { finished_ = 0; current_req_ = 0; - span_ =0; + span_ = 0; req_drul_[START] = 0; req_drul_[STOP] = 0; } diff --git a/lily/tfm-reader.cc b/lily/tfm-reader.cc index bc62f65ba3..76c55cbc28 100644 --- a/lily/tfm-reader.cc +++ b/lily/tfm-reader.cc @@ -24,7 +24,7 @@ Tex_font_metric_reader::Tex_font_metric_reader (String name) : input_ (name) { - for (int i=0; i < TFM_SIZE; i++) + for (int i= 0; i < TFM_SIZE; i++) ascii_to_metric_idx_.push (-1); read_header (); diff --git a/lily/tie-engraver.cc b/lily/tie-engraver.cc index 2176a3af98..4b7cee39da 100644 --- a/lily/tie-engraver.cc +++ b/lily/tie-engraver.cc @@ -144,14 +144,14 @@ Tie_engraver::stop_translation_timestep () if (ties_.size ()) { heads_to_tie_.clear (); - for (int i=0; i< ties_.size (); i++) + for (int i= 0; i< ties_.size (); i++) { typeset_tie (ties_[i]); } ties_.clear (); last_event_ = 0; - tie_column_ =0; + tie_column_ = 0; } if (event_) diff --git a/lily/timing-translator.cc b/lily/timing-translator.cc index 304be3699c..d5b526b665 100644 --- a/lily/timing-translator.cc +++ b/lily/timing-translator.cc @@ -82,7 +82,7 @@ Timing_translator::measure_position () const { SCM sm = get_property ("measurePosition"); - Moment m =0; + Moment m = 0; if (unsmob_moment (sm)) { m = *unsmob_moment (sm); diff --git a/lily/translator-ctors.cc b/lily/translator-ctors.cc index 3b08edc159..af70427a43 100644 --- a/lily/translator-ctors.cc +++ b/lily/translator-ctors.cc @@ -14,7 +14,7 @@ should delete these after exit. */ -Scheme_hash_table *global_translator_dict=0; +Scheme_hash_table *global_translator_dict= 0; LY_DEFINE (get_all_translators,"ly:get-all-translators", 0, 0, 0, (), "Return a list of all translator objects that may be instantiated. " diff --git a/lily/translator.cc b/lily/translator.cc index d6a4a79ca2..ae0bb1a0e4 100644 --- a/lily/translator.cc +++ b/lily/translator.cc @@ -24,7 +24,7 @@ Translator::init () { must_be_last_ = false; self_scm_ = SCM_EOL; - daddy_context_ =0; + daddy_context_ = 0; smobify_self (); } diff --git a/lily/trill-spanner-engraver.cc b/lily/trill-spanner-engraver.cc index 2857a123c5..594db99e36 100644 --- a/lily/trill-spanner-engraver.cc +++ b/lily/trill-spanner-engraver.cc @@ -42,7 +42,7 @@ Trill_spanner_engraver::Trill_spanner_engraver () { finished_ = 0; current_req_ = 0; - span_ =0; + span_ = 0; req_drul_[START] = 0; req_drul_[STOP] = 0; } diff --git a/lily/tuplet-bracket.cc b/lily/tuplet-bracket.cc index c011f2e369..137a314d3b 100644 --- a/lily/tuplet-bracket.cc +++ b/lily/tuplet-bracket.cc @@ -197,7 +197,7 @@ Tuplet_bracket::print (SCM smob) if (bracket_visibility) { Real ss = Staff_symbol_referencer::staff_space (me); - Real gap=0.; + Real gap= 0.; if (!num.extent (X_AXIS).is_empty ()) gap = num.extent (X_AXIS).length () + 1.0; diff --git a/lily/tuplet-engraver.cc b/lily/tuplet-engraver.cc index f2838a32c4..48f06caf97 100644 --- a/lily/tuplet-engraver.cc +++ b/lily/tuplet-engraver.cc @@ -92,7 +92,7 @@ Tuplet_engraver::acknowledge_grob (Grob_info i) { if (Note_column::has_interface (i.grob_)) { - for (int j =0; j < tuplets_.size (); j++) + for (int j = 0; j < tuplets_.size (); j++) if (tuplets_[j].spanner_) Tuplet_bracket::add_column (tuplets_[j].spanner_, dynamic_cast (i.grob_)); diff --git a/lily/vertical-align-engraver.cc b/lily/vertical-align-engraver.cc index 7ad89b9b34..4eb9a2224f 100644 --- a/lily/vertical-align-engraver.cc +++ b/lily/vertical-align-engraver.cc @@ -27,7 +27,7 @@ protected: Vertical_align_engraver::Vertical_align_engraver () { - valign_ =0; + valign_ = 0; } void diff --git a/lily/volta-bracket.cc b/lily/volta-bracket.cc index 78d1e39f9a..edb8e38353 100644 --- a/lily/volta-bracket.cc +++ b/lily/volta-bracket.cc @@ -55,8 +55,8 @@ Volta_bracket_interface::print (SCM smob) const char* cs = str.to_str0 (); no_vertical_end |= - (strcmp (cs,":|")!=0 && strcmp (cs,"|:")!=0 && strcmp (cs,"|.")!=0 - && strcmp (cs,":|:")!=0 && strcmp (cs,".|")!=0); + (strcmp (cs,":|")!= 0 && strcmp (cs,"|:")!= 0 && strcmp (cs,"|.")!= 0 + && strcmp (cs,":|:")!= 0 && strcmp (cs,".|")!= 0); Output_def * layout =me->get_layout (); Real half_space = 0.5; @@ -66,7 +66,7 @@ Volta_bracket_interface::print (SCM smob) /* not a start, but really broken in two */ - Real left =0.; + Real left = 0.; if (bound->break_status_dir () == RIGHT) { Paper_column *pc = bound->get_column (); diff --git a/lily/volta-engraver.cc b/lily/volta-engraver.cc index 263bca5aed..846f31fad6 100644 --- a/lily/volta-engraver.cc +++ b/lily/volta-engraver.cc @@ -142,7 +142,7 @@ Volta_engraver::process_music () else if (end) { end_volta_span_ = volta_span_; - volta_span_ =0; + volta_span_ = 0; } if (volta_span_ && @@ -234,7 +234,7 @@ Volta_engraver::stop_translation_timestep () end_volta_span_->set_bound (RIGHT, ci); } - end_volta_span_ =0; + end_volta_span_ = 0; if (volta_span_ && !volta_span_->get_bound (LEFT)) { -- 2.39.2