Jump to content

Manually controlling beam positions: Difference between revisions

From LilyPond wiki
Import snippet from LSR
 
m New category
 
(2 intermediate revisions by 2 users not shown)
Line 1: Line 1:
Beam positions may be controlled manually, by overriding the <code>positions</code> setting of the <code>Beam</code> grob.
Beam positions may be controlled manually, by overriding the <code>positions</code> setting of the <code>Beam</code> grob.


<lilypond version="2.24.0">
<lilypond version="2.24">
\relative c' {
\relative c' {
   \time 2/4
   \time 2/4
Line 18: Line 18:
[[Category:Tweaks and overrides]]
[[Category:Tweaks and overrides]]
[[Category:Included in the official documentation]]
[[Category:Included in the official documentation]]
[[Category:Snippet]]

Latest revision as of 23:23, 21 November 2025

Beam positions may be controlled manually, by overriding the positions setting of the Beam grob.

\version "2.24"

\relative c' {
  \time 2/4
  % from upper staff-line (position 2) to center (position 0)
  \override Beam.positions = #'(2 . 0)
  c8 c
  % from center to one above center (position 1)
  \override Beam.positions = #'(0 . 1)
  c8 c
}