[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
with and set
From: |
Noeck |
Subject: |
with and set |
Date: |
Sun, 5 Feb 2017 23:21:54 +0100 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.7.0 |
Hi,
I read on the dev list and in the issues [1] that setting some
properties in the \with block is advisable, instead of setting them
somewhere in the music. So
\new Staff \with { instrumentName = "Flute" } { a }
is better than
{ \set Staff.instrumentName = "Flute" a }
even though the output is identical.
>From a logical point of view I understand that. It is a staff property.
But I always used \set, because:
1. For simple scores, I don't need a \new Staff, I just start a music
expression and get it for free. So I would have to add \new Staff just
because of the instrumentName (less verbose).
2. If I have an explicit score setup, the instrumentName is usually the
same in the parts and the complete score. That means writing it once
using \set does what I want. Using \with means I have to set it for
every score setup.
So my question:
What is the reason to recommend using \with for such properties?
What are cases in which that makes a difference? I always thought they
were equivalent.
TIA,
Joram
[1]: https://sourceforge.net/p/testlilyissues/issues/5039/