]> git.donarmstrong.com Git - lilypond.git/blob - input/new/making-an-object-invisible-with-the-transparent-property.ly
Merge branch 'master' of ssh://jomand@git.sv.gnu.org/srv/git/lilypond
[lilypond.git] / input / new / making-an-object-invisible-with-the-transparent-property.ly
1 \version "2.11.23"\r
2 \layout { ragged-right = ##t }\r
3 \header {\r
4   doctitle = "Making an object invisible with the transparent property"\r
5   lsrtags = "rhythms,tweaks-and-overrides"\r
6   texidoc = "\r
7 Setting the @code{transparent} property will cause an object to be\r
8 printed in \"invisible ink\": the object is not printed, but all its\r
9 other behavior is retained.  The object still takes up space, it takes\r
10 part in collisions, and slurs, ties and beams can be attached to it.\r
11 \r
12 \r
13 The snippet demonstrates how to connect different voices using ties. \r
14 Normally, ties only connect two notes in the same voice.  By\r
15 introducing a tie in a different voice, and blanking the first up-stem\r
16 in that voice, the tie appears to cross voices.  To prevent the blanked stem's\r
17 flag from interfering with tie positioning, the stem is extended.\r
18 " }\r
19 \r
20 \relative c'' {\r
21   \time 2/4\r
22   << {\r
23     \once \override Stem #'transparent = ##t\r
24     \once \override Stem #'length = #8\r
25     b8 ~ b\noBeam\r
26     \once \override Stem #'transparent = ##t\r
27     \once \override Stem #'length = #8\r
28     g ~ g\noBeam\r
29   } \\ {\r
30     b g g e\r
31   } >>\r
32 }\r