]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/simple-spacer.cc
Release: bump Welcome versions.
[lilypond.git] / lily / simple-spacer.cc
index 5244d33c9e6d58ba8a3da4ece88ff4467855b0bd..cf4fd5849e35601ad8cf839394d7f6d6ba407c8e 100644 (file)
@@ -32,8 +32,6 @@
 #include "spring.hh"
 #include "warn.hh"
 
-using std::vector;
-
 /*
   A simple spacing constraint solver. The approach:
 
@@ -127,9 +125,9 @@ Simple_spacer::add_rod (int l, int r, Real dist)
 
       return;
     }
-  force_ = std::max (force_, block_force);
+  force_ = max (force_, block_force);
   for (int i = l; i < r; i++)
-    springs_[i].set_blocking_force (std::max (block_force, springs_[i].blocking_force ()));
+    springs_[i].set_blocking_force (max (block_force, springs_[i].blocking_force ()));
 }
 
 Real
@@ -225,7 +223,7 @@ Simple_spacer::compress_line ()
   if (line_len_ > (1 + 1e-6) * cur_len)
     programming_error ("misuse of compress_line");
   vector<Spring> sorted_springs = springs_;
-  sort (sorted_springs.begin (), sorted_springs.end (), std::greater<Spring> ());
+  sort (sorted_springs.begin (), sorted_springs.end (), greater<Spring> ());
 
   /* inv_hooke is the total flexibility of currently-active springs */
   double inv_hooke = 0;
@@ -269,7 +267,7 @@ Simple_spacer::compress_line ()
 void
 Simple_spacer::add_spring (Spring const &sp)
 {
-  force_ = std::max (force_, sp.blocking_force ());
+  force_ = max (force_, sp.blocking_force ());
   springs_.push_back (sp);
 }
 
@@ -291,7 +289,7 @@ Simple_spacer::force_penalty (bool ragged) const
      but according to the amount of whitespace that is present after the end
      of the line. */
   if (ragged)
-    return std::max (0.0, line_len_ - configuration_length (0.0));
+    return max (0.0, line_len_ - configuration_length (0.0));
 
   /* Use a convex compression penalty. */
   Real f = force_;
@@ -472,7 +470,7 @@ get_line_forces (vector<Grob *> const &columns,
                 force[b * breaks.size () + c] = infinity_f;
               break;
             }
-          if (end < cols.size () && cols[end].break_permission_ == force_break)
+          if (end < cols.size () && scm_is_eq (cols[end].break_permission_, force_break))
             break;
         }
     }