OLD | NEW |
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) 2000--2020 Jan Nieuwenhuizen <janneke@gnu.org> | 4 Copyright (C) 2000--2020 Jan Nieuwenhuizen <janneke@gnu.org> |
5 | 5 |
6 LilyPond is free software: you can redistribute it and/or modify | 6 LilyPond is free software: you can redistribute it and/or modify |
7 it under the terms of the GNU General Public License as published by | 7 it under the terms of the GNU General Public License as published by |
8 the Free Software Foundation, either version 3 of the License, or | 8 the Free Software Foundation, either version 3 of the License, or |
9 (at your option) any later version. | 9 (at your option) any later version. |
10 | 10 |
(...skipping 319 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
330 } | 330 } |
331 | 331 |
332 Stencil line; | 332 Stencil line; |
333 for (LEFT_and_RIGHT (d)) | 333 for (LEFT_and_RIGHT (d)) |
334 { | 334 { |
335 span_points[d] += -d * gaps[d] * magstep * dz.direction (); | 335 span_points[d] += -d * gaps[d] * magstep * dz.direction (); |
336 | 336 |
337 if (stencils[d]) | 337 if (stencils[d]) |
338 { | 338 { |
339 Stencil s = stencils[d]->translated (span_points[d]); | 339 Stencil s = stencils[d]->translated (span_points[d]); |
340 SCM align = ly_assoc_get (ly_symbol2scm ("stencil-align-dir-y"), | 340 s.align_label (me, ly_assoc_get (ly_symbol2scm ("label-alignments"), |
341 bounds[d], SCM_BOOL_F); | 341 bounds[d], SCM_BOOL_F)); |
| 342 |
342 SCM off = ly_assoc_get (ly_symbol2scm ("stencil-offset"), | 343 SCM off = ly_assoc_get (ly_symbol2scm ("stencil-offset"), |
343 bounds[d], SCM_BOOL_F); | 344 bounds[d], SCM_BOOL_F); |
344 | |
345 if (scm_is_number (align)) | |
346 s.align_to (Y_AXIS, scm_to_double (align)); | |
347 | |
348 if (is_number_pair (off)) | 345 if (is_number_pair (off)) |
349 s.translate (ly_scm2offset (off) * magstep); | 346 s.translate (ly_scm2offset (off) * magstep); |
350 | 347 |
351 line.add_stencil (s); | 348 line.add_stencil (s); |
352 } | 349 } |
353 } | 350 } |
354 | 351 |
355 for (LEFT_and_RIGHT (d)) | 352 for (LEFT_and_RIGHT (d)) |
356 { | 353 { |
357 if (stencils[d]) | 354 if (stencils[d]) |
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
404 " So, a value of -1 (or @code{LEFT}) makes the line start/end" | 401 " So, a value of -1 (or @code{LEFT}) makes the line start/end" |
405 " at the left side of the note head it is attached to.\n" | 402 " at the left side of the note head it is attached to.\n" |
406 "@item X\n" | 403 "@item X\n" |
407 "This is the absolute X@tie{}coordinate of the end point." | 404 "This is the absolute X@tie{}coordinate of the end point." |
408 " Usually computed on the fly.\n" | 405 " Usually computed on the fly.\n" |
409 "@item stencil\n" | 406 "@item stencil\n" |
410 "Line spanners may have symbols at the beginning or end, which" | 407 "Line spanners may have symbols at the beginning or end, which" |
411 " is contained in this sub-property. For internal use.\n" | 408 " is contained in this sub-property. For internal use.\n" |
412 "@item text\n" | 409 "@item text\n" |
413 "This is a markup that is evaluated to yield the stencil.\n" | 410 "This is a markup that is evaluated to yield the stencil.\n" |
414 "@item stencil-align-dir-y\n" | 411 "@item label-alignments\n" |
415 "@itemx stencil-offset\n" | 412 "@itemx stencil-offset\n" |
416 "Without setting one of these, the stencil is simply put at the" | 413 "Without setting one of these, the stencil is simply put at the" |
417 " end-point, centered on the line, as defined by the @code{X}" | 414 " end-point, centered on the line, as defined by the @code{X}" |
418 " and @code{Y} sub-properties. Setting" | 415 " and @code{Y} sub-properties. Setting" |
419 " @code{stencil-align-dir-y} moves the symbol at the edge" | 416 " @code{label-alignments} moves the symbol at the edge" |
420 " vertically relative to the end point of the line. With" | 417 " vertically relative to the end point of the line. This" |
| 418 " property expects a pair of numbers for spanners below and" |
| 419 " above the staff. With" |
421 " @code{stencil-offset}, expecting a number pair, the stencil" | 420 " @code{stencil-offset}, expecting a number pair, the stencil" |
422 " is moved along the X@tie{}axis according to the first value," | 421 " is moved along the X@tie{}axis according to the first value," |
423 " the second value moves the stencil along the Y@tie{}axis.\n" | 422 " the second value moves the stencil along the Y@tie{}axis.\n" |
424 "@item arrow\n" | 423 "@item arrow\n" |
425 "Produces an arrowhead at the end-points of the line.\n" | 424 "Produces an arrowhead at the end-points of the line.\n" |
426 "@item padding\n" | 425 "@item padding\n" |
427 "Controls the space between the specified end point of the" | 426 "Controls the space between the specified end point of the" |
428 " line and the actual end. Without padding, a glissando would" | 427 " line and the actual end. Without padding, a glissando would" |
429 " start and end in the center of each note head.\n" | 428 " start and end in the center of each note head.\n" |
430 "@end table\n", | 429 "@end table\n", |
431 | 430 |
432 /* properties */ | 431 /* properties */ |
433 "bound-details " | 432 "bound-details " |
434 "extra-dy " | 433 "extra-dy " |
435 "gap " | 434 "gap " |
436 "left-bound-info " | 435 "left-bound-info " |
437 "note-columns " | 436 "note-columns " |
438 "right-bound-info " | 437 "right-bound-info " |
439 "simple-Y " | 438 "simple-Y " |
440 "thickness " | 439 "thickness " |
441 "to-barline " | 440 "to-barline " |
442 ); | 441 ); |
OLD | NEW |