From 4cd46cb026744f6e37461918ce6a8f525563e519 Mon Sep 17 00:00:00 2001 From: Trevor Daniels Date: Mon, 28 Dec 2009 17:36:24 +0000 Subject: [PATCH] Docs: add snippet to illustrate use of whiteout --- .../editorial-annotations.snippet-list | 1 + .../snippets/expressive-marks.snippet-list | 1 + .../new/using-the-whiteout-property.ly | 30 ++++++++++++++++ Documentation/snippets/simple-lead-sheet.ly | 8 +++++ .../snippets/using-the-whiteout-property.ly | 35 +++++++++++++++++++ 5 files changed, 75 insertions(+) create mode 100644 Documentation/snippets/new/using-the-whiteout-property.ly create mode 100644 Documentation/snippets/using-the-whiteout-property.ly diff --git a/Documentation/snippets/editorial-annotations.snippet-list b/Documentation/snippets/editorial-annotations.snippet-list index ab07d9cd37..de40435fbb 100644 --- a/Documentation/snippets/editorial-annotations.snippet-list +++ b/Documentation/snippets/editorial-annotations.snippet-list @@ -24,3 +24,4 @@ positioning-text-markups-inside-slurs.ly printing-text-from-right-to-left.ly string-number-extender-lines.ly using-postscript-to-generate-special-note-head-shapes.ly +using-the-whiteout-property.ly diff --git a/Documentation/snippets/expressive-marks.snippet-list b/Documentation/snippets/expressive-marks.snippet-list index 83e6631a78..b56614aedc 100644 --- a/Documentation/snippets/expressive-marks.snippet-list +++ b/Documentation/snippets/expressive-marks.snippet-list @@ -40,5 +40,6 @@ setting-the-minimum-length-of-hairpins.ly showing-the-same-articulation-above-and-below-a-note-or-chord.ly snap-pizzicato-bartok-pizzicato.ly using-double-slurs-for-legato-chords.ly +using-the-whiteout-property.ly vertical-line-as-a-baroque-articulation-mark.ly vertically-aligning-dynamics-across-multiple-notes.ly diff --git a/Documentation/snippets/new/using-the-whiteout-property.ly b/Documentation/snippets/new/using-the-whiteout-property.ly new file mode 100644 index 0000000000..46a5d57a51 --- /dev/null +++ b/Documentation/snippets/new/using-the-whiteout-property.ly @@ -0,0 +1,30 @@ +\version "2.13.10" + +\header { + lsrtags = "expressive-marks, editorial-annotations" + texidoc = " +Any graphical object can be printed over a white backgound to +mask parts of objects that lie beneath. This can be useful to +improve the appearance of collisions in complex situations when +repositioning objects is impractical. It is necessary to explicitly +set the @code{layer} property to control which objects are masked +by the white background. + +In this example the collision of the tie with the time signature is +improved by masking out the part of the tie that crosses the time +signature by setting the @code{whiteout} property of @code{TimeSignature}. +To do this @code{TimeSignature} is moved to a layer above @code{Tie}, which +is left in the default layer of 1, and @code{StaffSymbol} is moved to a +layer above @code{TimeSignature} so it is not masked. +" + doctitle = "Using the whiteout property" +} + +{ + \override Score.StaffSymbol #'layer = #4 + \override Staff.TimeSignature #'layer = #3 + b'2 b'~ + \once \override Staff.TimeSignature #'whiteout = ##t + \time 3/4 + b' r4 +} diff --git a/Documentation/snippets/simple-lead-sheet.ly b/Documentation/snippets/simple-lead-sheet.ly index c6fc7affb3..912d1f94d4 100644 --- a/Documentation/snippets/simple-lead-sheet.ly +++ b/Documentation/snippets/simple-lead-sheet.ly @@ -4,6 +4,14 @@ \version "2.13.10" \header { +%% Translation of GIT committish: + texidocfr = " +Pour obtenir la partition d'un chanson, il suffit d'assembler +des noms d'accords, une mélodie et des paroles : + +" + doctitlefr = "Chanson simple" + lsrtags = "chords" %% Translation of GIT committish: b2d4318d6c53df8469dfa4da09b27c15a374d0ca diff --git a/Documentation/snippets/using-the-whiteout-property.ly b/Documentation/snippets/using-the-whiteout-property.ly new file mode 100644 index 0000000000..8109189507 --- /dev/null +++ b/Documentation/snippets/using-the-whiteout-property.ly @@ -0,0 +1,35 @@ +% Do not edit this file; it is automatically +% generated from Documentation/snippets/new +% This file is in the public domain. +%% Note: this file works from version 2.13.10 +\version "2.13.10" + +\header { + lsrtags = "expressive-marks, editorial-annotations" + texidoc = " +Any graphical object can be printed over a white backgound to +mask parts of objects that lie beneath. This can be useful to +improve the appearance of collisions in complex situations when +repositioning objects is impractical. It is necessary to explicitly +set the @code{layer} property to control which objects are masked +by the white background. + +In this example the collision of the tie with the time signature is +improved by masking out the part of the tie that crosses the time +signature by setting the @code{whiteout} property of @code{TimeSignature}. +To do this @code{TimeSignature} is moved to a layer above @code{Tie}, which +is left in the default layer of 1, and @code{StaffSymbol} is moved to a +layer above @code{TimeSignature} so it is not masked. +" + doctitle = "Using the whiteout property" +} % begin verbatim + + +{ + \override Score.StaffSymbol #'layer = #4 + \override Staff.TimeSignature #'layer = #3 + b'2 b'~ + \once \override Staff.TimeSignature #'whiteout = ##t + \time 3/4 + b' r4 +} -- 2.39.2