LEFT | RIGHT |
1 /* | 1 /* |
2 This file is part of LilyPond, the GNU music typesetter. | 2 This file is part of LilyPond, the GNU music typesetter. |
3 | 3 |
4 Copyright (C) 1997--2012 Han-Wen Nienhuys <hanwen@xs4all.nl> | 4 Copyright (C) 1997--2012 Han-Wen Nienhuys <hanwen@xs4all.nl> |
5 | 5 |
6 Jan Nieuwenhuizen <janneke@gnu.org> | 6 Jan Nieuwenhuizen <janneke@gnu.org> |
7 | 7 |
8 LilyPond is free software: you can redistribute it and/or modify | 8 LilyPond is free software: you can redistribute it and/or modify |
9 it under the terms of the GNU General Public License as published by | 9 it under the terms of the GNU General Public License as published by |
10 the Free Software Foundation, either version 3 of the License, or | 10 the Free Software Foundation, either version 3 of the License, or |
(...skipping 318 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
329 /* | 329 /* |
330 TODO: deprecate? | 330 TODO: deprecate? |
331 */ | 331 */ |
332 Stencil | 332 Stencil |
333 Lookup::frame (Box b, Real thick, Real blot) | 333 Lookup::frame (Box b, Real thick, Real blot) |
334 { | 334 { |
335 Stencil m; | 335 Stencil m; |
336 for (Axis a = X_AXIS; a < NO_AXES; a = Axis (a + 1)) | 336 for (Axis a = X_AXIS; a < NO_AXES; a = Axis (a + 1)) |
337 { | 337 { |
338 Axis o = Axis ((a + 1) % NO_AXES); | 338 Axis o = Axis ((a + 1) % NO_AXES); |
339 for(LEFT_and_RIGHT(d)) | 339 for (LEFT_and_RIGHT (d)) |
340 { | 340 { |
341 Box edges; | 341 Box edges; |
342 edges[a] = b[a][d] + 0.5 * thick * Interval (-1, 1); | 342 edges[a] = b[a][d] + 0.5 * thick * Interval (-1, 1); |
343 edges[o][DOWN] = b[o][DOWN] - thick / 2; | 343 edges[o][DOWN] = b[o][DOWN] - thick / 2; |
344 edges[o][UP] = b[o][UP] + thick / 2; | 344 edges[o][UP] = b[o][UP] + thick / 2; |
345 | 345 |
346 m.add_stencil (round_filled_box (edges, blot)); | 346 m.add_stencil (round_filled_box (edges, blot)); |
347 } | 347 } |
348 } | 348 } |
349 return m; | 349 return m; |
(...skipping 217 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
567 { | 567 { |
568 if (points[i - 1].is_sane () && points[i].is_sane ()) | 568 if (points[i - 1].is_sane () && points[i].is_sane ()) |
569 { | 569 { |
570 Stencil line | 570 Stencil line |
571 = Line_interface::make_line (thick, points[i - 1], points[i]); | 571 = Line_interface::make_line (thick, points[i - 1], points[i]); |
572 ret.add_stencil (line); | 572 ret.add_stencil (line); |
573 } | 573 } |
574 } | 574 } |
575 return ret; | 575 return ret; |
576 } | 576 } |
LEFT | RIGHT |