diff options
Diffstat (limited to 'libs/canvas/note.cc')
-rw-r--r-- | libs/canvas/note.cc | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/libs/canvas/note.cc b/libs/canvas/note.cc index 05c66afd4e..653fe1f1c1 100644 --- a/libs/canvas/note.cc +++ b/libs/canvas/note.cc @@ -74,12 +74,12 @@ Note::render (Rect const & area, Cairo::RefPtr<Cairo::Context> context) const outline_width() margin on left. set width based on velocity. */ - - self.y0 = self.y0 + outline_width() + 2; - self.y1 = self.y1 - outline_width() - 1; + const double center = (self.y1 - self.y0) * 0.5; + self.y1 = self.y0 + center + 2; + self.y0 = self.y0 + center - 1; const double width = (self.x1 - self.x0) - (2 * outline_width()); - self.x0 = self.x0 + outline_width(); - self.x1 = self.x0 + (width * _velocity); + self.x0 = self.x0 + outline_width()+1; + self.x1 = self.x0 + ((width-2) * _velocity); const Rect draw = self.intersection (area); |