David Kastrup [Thu, 12 Sep 2013 20:05:07 +0000 (22:05 +0200)]
Issue 3553/2: When creating a hierarchy above Bottom, all intermediate levels are named "\new"
Previously, get_default_interpreter gave all intermediate levels the
same id as that of the new Bottom level.
However, since issue 3225, there can be more than one Bottom in one
hierarchy since a Bottom context (defined by not having a
\defaultchild) can still have children contexts (of any type it
\accepts even while it would not create them implicitly).
So it is a bad idea to give implicitly created contexts the same id as
any explicitly named context.
David Kastrup [Sun, 15 Sep 2013 13:53:51 +0000 (15:53 +0200)]
Issue 3555: Parse context definitions and context modifications in \notemode
Since context modifications and context definitions are somewhat more
concerned with musical content, it makes sense to parse them in a mode
where note names are recognized and can be used in music and scheme
function arguments.
The main argument for a separate INITIAL lexer mode is for being able
to specify REAL number values in a lenient syntax, such as .5\cm.
However, dimensions are almost never used in context definitions
or modifications but rather in output definitions like layout, midi,
paper and header blocks.
Build: Disallow metapost versions 1.600 <= x < 1.803.
Add a check in ./configure to avoid buggy versions of metapost
starting with the rewrite that occured in the 1.600 series and
finally fixed in version 1.803 and later.
Fixes issue 3539: Configure should forbid mpost 1.802 from TexLive 2013
http://code.google.com/p/lilypond/issues/detail?id=3539
Build: Dependencies for metafont files (issue 779).
Write .dep files containing make dependency rules for .mf files,
allowing to simply type `make' to process the fonts after changing
an input'ed file and have the fonts updated with the minimum amount
of processing.
These .dep files are generated by recursively scanning for lines
of the form "input X;" in the .mf files, and looking up these
input'ed files within the mf source directory. The .dep files are
included into the build by stepmake/generic-targets.make.
Fixes issue 779: fonts should be rebuilt upon modifications to mf/
http://code.google.com/p/lilypond/issues/detail?id=779
David Kastrup [Sat, 14 Sep 2013 09:09:18 +0000 (11:09 +0200)]
Issue 3552: Don't modify lists returned by markup list functions in interpret-markup-list
This requires either
a) copying any list manually
b) interpreting markup lists right-to-left
c) more complicated and/or non-O(n) algorithms
This patch chooses b). Modifying the lists is not really appropriate
since the lists may be created by user-written markup commands and any
problems resulting from not expecting modifications of the return
value might be quite hard to debug.
David Kastrup [Sun, 15 Sep 2013 09:01:06 +0000 (11:01 +0200)]
Issue 3554: Avoid empty grammar rules using @$ for getting a source location
Several rules use @$ for getting the source position from an empty
rule, but Bison does not even provide a source position for empty
rules.
This patch fixes most cases by letting different non-empty rules
assign the respective source positions. The case of #{ #} cannot be
fixed in that manner since there is not a single token providing a
source position in the whole production. Fixing this particular case
would require a different technique.
David Kastrup [Sun, 8 Sep 2013 21:50:16 +0000 (23:50 +0200)]
Issue 3297: Make lexer more robust against unexpected EOF in main input
This approach works by letting Lily_lexer::pop_state not cross the
maininput threshold. Since Lily_lexer::pop_state is the "cooked" form
of yy_pop_state (also hiding the extratoken machinery), this keeps the
"maininput" state firmly under the lexer's control and avoids exiting
it prematurely.
Use a single rule to build header and source files from
the syntax file, thus avoiding any possibility to have
`make' rebuild one but not the other, which might happen
if the syntax and target files have almost the same but
slightly differing timestamps.
See http://www.mail-archive.com/bug-lilypond@gnu.org/msg37081.html
Fixes issue 3528: Keep bison-generated files in sync.
http://code.google.com/p/lilypond/issues/detail?id=3528
Frédéric Bron [Fri, 23 Aug 2013 15:30:34 +0000 (17:30 +0200)]
Issue 3531: replaced function argument 'string' by 'const string&' where it makes sense to avoid unnecessary copying of 'string' objects.
Measurements on x86_64 (i7-2760QM, 2.40GHz) Fedora 19 with g++ 4.8.1, with
configure --enable-optimising --disable-debugging; tests run 10 times, average
elapsed time compared (/usr/bin/time)
* Bach, Concerto in E major or violin and strings, BWV 1042 (Mutopia source),
38 pages:
$ lilypond score.ly -> master: 15.4s, with patch: -0.1%
* lilypond regression tests (1153 .ly files):
$ lilypond *.ly -> master: 276.6s, with patch: -2.5%
Keith OHara [Thu, 29 Aug 2013 17:43:40 +0000 (10:43 -0700)]
markup: some skylines should not follow printed shapes; issue 3522
Implement the stencil tag 'transparent to support proper skylining of
stencils with extents different from their printed shapes, such as those
created by \transparent and \with-dimensions, or where the printed shape
is not yet known during layout, such as \page-ref.
Janek Warchol [Sun, 12 Jun 2011 22:34:45 +0000 (00:34 +0200)]
make sure that AmbitusLine is visible for small ambits
Until now, the gap between ambitus heads and ambitus line
was constant, so either the gap had to be very small or
the line wasn't visible in case of smaller ambits (like
4th or 5th). With this patch ambitus gap will be calculated
dynamically, depending on the distance between ambitus heads.
Also, the default gap for bigger ambits is changed so that
ambitus line will end precisely in the staffline or in the
middle of staffspace.
David Kastrup [Sat, 31 Aug 2013 16:57:09 +0000 (18:57 +0200)]
Issue 3527: parser.yy: allow "scalar" to be a negative literal number
This makes the syntax of the value for \override (a hardwired syntax
construct which accepts a "scalar") and \tweak (which is a music
function accepting an expression of type "scheme?" possibly ending up
as a negative number) more comparable.
David Kastrup [Tue, 16 Jul 2013 16:12:06 +0000 (18:12 +0200)]
Add some comments to lily/dispatcher.cc
Also change "bubblesort" moniker to "insertion sort". While it's
widespread malpractice to call any O(n^2) sorting algorithm comparing
and conditionally exchanging adjacent elements "bubblesort", something
as rare and precious as a comment in LilyPond code deserves getting
done right.
David Kastrup [Sat, 17 Aug 2013 15:34:00 +0000 (17:34 +0200)]
Issue 3505: Let add-grace-property and remove-grace-property work from current context
This basically sets the grace settings in the current context unless
the context specification is for a parent context in which case it is
directed there lest it become ineffective.
Thomas Morley [Sun, 18 Aug 2013 15:34:28 +0000 (17:34 +0200)]
Some clean up about grace-settings in music-functions.scm
- Stores a list,general-grace-settings, used by make-voice-props-set and make-voice-props-override.
- Settings to be used by the Score-context are appended to general-grace-settings and stored in score-grace-settings, used in engraver-init.ly
David Kastrup [Wed, 21 Aug 2013 02:09:29 +0000 (04:09 +0200)]
Issue 3489: Let \cue... use quoted-context-type of CueVoice consistently
Previously Voice was used and this relied on a a CueVoice purportedly
being created by cue-substitute itself and providing a Voice alias.
There is a regtest input/regression/quote-tuplet-end.ly which relied
on an explicit Voice = "cue" serving as a substite catch for the cue
notes, effectively turning \cueDuring into \quoteDuring. This kind of
usage is rather bizarre, and since it diverts the \voiceOne/\voiceTwo
settings for the cue voice into a CueVoice context anyway (which is
otherwise empty), the cue voice is still missing proper directional
information. This was not worth supporting.
Regularizing the usage in this manner will reliably stop \quoteDuring
from introducing surprise CueVoice contexts.
David Kastrup [Wed, 21 Aug 2013 02:04:02 +0000 (04:04 +0200)]
Issue 3489: Let \quoteDuring descend to bottom context for its output
Also regularizes interpretation of quoted-context-id. This patch by
itself does not resolve the issue since a CueContext is created in
any case, serving as Bottom and Voice context. A followup patch
fixes that.
Grobs that are not cross-staff are placed before staff-spacing,
so they may not force placement of cross-staff grobs.
When cross-staff items are placed around the spaced staves, let
them side-position using the final, not 'pure', information.