Jump to content

Partcombine and \autoBeamOff: Difference between revisions

From LilyPond wiki
m Replace version="2.24.0" with version="2.24" now that the LilyWiki extension supports auto-selecting the latest release in a stable series
mNo edit summary
 
(3 intermediate revisions by the same user not shown)
Line 1: Line 1:
The function of <code>\autoBeamOff</code> when used with <code>\partCombine</code> can be difficult to understand. It may be preferable to use
The function of <code>\autoBeamOff</code> when used with <code>\partCombine</code> can be difficult to understand. It may be preferable to use


<code>\set Staff.autoBeaming = ##f</code>
\set Staff.autoBeaming = ##f


instead to ensure that auto-beaming is turned off for the entire staff. Use this at a spot in your score where no beam generated by the auto-beamer is still active.
instead to ensure that auto-beaming is turned off for the entire staff. Use this at a spot in your score where no beam generated by the auto-beamer is still active.


Internally, <code>\partCombine</code> works with four voices – stem up single, stem down single, combined, and solo. In order to use <code>\autoBeamOff</code> to stop all auto-beaming when used with <code>\partCombine</code>, it is necessary to use ''four'' calls to <code>\autoBeamOff</code>.
Internally, <code>\partCombine</code> works with four voices – up-stem single, down-stem single, combined, and solo. In order to use <code>\autoBeamOff</code> to stop all auto-beaming when used with <code>\partCombine</code>, it is necessary to use ''four'' calls to <code>\autoBeamOff</code>.


<lilypond version="2.24">
<lilypond version="2.24">
Line 32: Line 32:
[[Category:Included in the official documentation]]
[[Category:Included in the official documentation]]
[[Category:Rhythms]]
[[Category:Rhythms]]
[[Category:Snippet]]

Latest revision as of 07:12, 3 December 2025

The function of \autoBeamOff when used with \partCombine can be difficult to understand. It may be preferable to use

\set Staff.autoBeaming = ##f

instead to ensure that auto-beaming is turned off for the entire staff. Use this at a spot in your score where no beam generated by the auto-beamer is still active.

Internally, \partCombine works with four voices – up-stem single, down-stem single, combined, and solo. In order to use \autoBeamOff to stop all auto-beaming when used with \partCombine, it is necessary to use four calls to \autoBeamOff.

\version "2.24"

{
  % \set Staff.autoBeaming = ##f % turns off all auto-beaming

  \partCombine {
    \autoBeamOff   % applies to split up-stems
    \repeat unfold 4 a'16
    % \autoBeamOff % applies to combined stems
    \repeat unfold 4 a'8
    \repeat unfold 4 a'16
    % \autoBeamOff % applies to solo
    \repeat unfold 4 a'16
    r4
  } {
    % \autoBeamOff % applies to split down-stems
    \repeat unfold 4 f'8
    \repeat unfold 8 f'16 |
    r4
    \repeat unfold 4 a'16
  }
}