Re: Another Figured Bass problem

2018-05-02 Thread Lukas-Fabian Moser


Am 30.04.2018 um 12:28 schrieb David Kastrup:

 which can be achieved by using ‘_’ instead of a number.

That's what I wanted to propose, but it didn't produce what I hoped for:

\figures { < 5 4 > < _ 3+> }

Oh.  Ok.  Sorry for the noise.

I made this work for me by inserting at line 206 of 
scm/translation-functions.scm (current master):


    (if (and (not fig-markup) (not alt-markup))
    (begin
  (set! fig-markup (markup #:transparent #:number "0"))
  ))

But I expect this is way too hacky and could never be considered as a 
viable way of introducing this feature?


Best
Lukas

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Another Figured Bass problem

2018-05-02 Thread Lukas-Fabian Moser


Am 30.04.2018 um 12:28 schrieb David Kastrup:

 which can be achieved by using ‘_’ instead of a number.

That's what I wanted to propose, but it didn't produce what I hoped for:

\figures { < 5 4 > < _ 3+> }

Oh.  Ok.  Sorry for the noise.

I made this work for me by inserting at line 206 of 
scm/translation-functions.scm (current master):


    (if (and (not fig-markup) (not alt-markup))
    (begin
  (set! fig-markup (markup #:transparent #:number "0"))
  ))

But I expect this is way too hacky and could never be considered as a 
viable way of introducing this feature?


Best
Lukas

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Another Figured Bass problem

2018-05-01 Thread Robert Blackstone
Hi Harm,

Thank you for this enormous collection of possibilities and code for displaying 
BC-figures.
I may not live long enough to put all of it in practice but for my present 
purpose it is more than sufficient.
On the topic of Figured Bass in LilyPond I still have some other desires, to be 
formulated in a new thread (after I have convinced myself that I won't find it 
somewhere in the documentation) 

Thanks again,

Best regards,

Robert


On 30 Apr 2018, at 23:09 , Thomas Morley  wrote:

> 2018-04-30 12:51 GMT+02:00 Torsten Hämmerle :
>> Hi Robert,
>> 
>> How about simply flipping the stacking direction?
>> 
>>   \override BassFigureAlignment.stacking-dir = #UP
>> 
>> That way, the bass figures will be piled up from bottom to top.
>> Caveat: the first figure entered will be the lowest.
>> 
>> 
>> <<
>>  { 4 4 4 4 4 4 }
>>  \figures {
>>\override BassFigureAlignment.stacking-dir = #UP
>><_!> <3+ 6> <4> <4 5> <3+> <_+>
>>  }
 
>> 
>> 
>> HTH,
>> Torsten
> 
> 
> I looked for a way not to change the input order, but still benefit
> from upwards stacking-dir.
> 
> Coming up with the code below.
> For test-cases I used some of our reg-tests in a modified manner.
> 
> figured-bass-continuation-center.ly looks even better, imho.
> figured-bass.ly is surely not meant to demonstrate real live input,
> though, I add it as well, demonstrating bracketing still works.
> 
> \version "2.19.81"
> 
> reverseEventChordsElements =
> #(define-music-function (mus)(ly:music?)
>  (music-map
>(lambda (m)
>  (if (music-is-of-type? m 'event-chord)
>  (let ((ev-chrd-elts (ly:music-property m 'elements)))
>(ly:music-set-property! m 'elements
>  (reverse
>(map
>  (lambda (e)
>(cond ((and (eq? #t (ly:music-property e 'bracket-start))
>(eq? #t (ly:music-property e 'bracket-stop)))
>   '())
>  ((eq? #t (ly:music-property e 'bracket-start))
>   (begin
> (ly:music-set-property! e 'bracket-start '())
> (ly:music-set-property! e 'bracket-stop #t)))
>  ((eq? #t (ly:music-property e 'bracket-stop))
>   (begin
> (ly:music-set-property! e 'bracket-stop '())
> (ly:music-set-property! e 'bracket-start #t
>e)
>  ev-chrd-elts)))
>m)
>  m))
>mus))
> 
> %%%
> %% EXAMPLES
> %%%
> 
> \paper { indent = 30 }
> 
> \layout {
>  \context {
>\FiguredBass
>\override BassFigureAlignment.stacking-dir = #UP
>  }
> }
> 
> %%%
> %% figured-bass-continuation-center.ly
> %%%
> 
> mI =
> \relative {
>  c'8 c  b b  a a  b b
>  c c  b b
> }
> 
> figI =
> \figuremode {
>  \set useBassFigureExtenders = ##t
>  \set figuredBassCenterContinuations = ##t
>  <6+ 4 3>4 <6 4 3> r
>  <6+ 4 3>4 <6 4 3> <4 3+> r
> }
> 
> <<
>  \new Staff
>\with { instrumentName = "default figures" }
>\mI
> 
>  \new FiguredBass
>\with { \revert BassFigureAlignment.stacking-dir }
>\figI
> 
>  \new Staff
>\with { instrumentName = "tweaked figures" }
>\mI
> 
>  \new FiguredBass
>\reverseEventChordsElements
>\figI
>>> 
> 
> %%%
> %% figured-bass.ly
> %%%
> 
> mII = {
>  \clef bass
>  c 4 c c c
>  c 4 c c c
> }
> 
> figII =
> \figuremode {
><3 [5 7]>
><3\+ [5/] 7/ [9 11]>
><3+ 5- 7!>
><3 _! 5 _- 7>
><3 _ 5 _ 7>
><3 6/ >
><3 6\\ >
><"V7" ["bla" 6] \markup{ \musicglyph "rests.2"} >
>  }
> 
> <<
>  \new Staff
>   \with { instrumentName = "default figures" }
>\mII
> 
>  \new FiguredBass
>\with { \revert BassFigureAlignment.stacking-dir }
>\figII
> 
>  \new Staff
>\with { instrumentName = "tweaked figures" }
>\mII
> 
>  \new FiguredBass
>\reverseEventChordsElements
>\figII
>>> 
> 
> Cheers,
>  Harm
> 
> ___
> lilypond-user mailing list
> lilypond-user@gnu.org
> https://lists.gnu.org/mailman/listinfo/lilypond-user


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Another Figured Bass problem

2018-04-30 Thread Thomas Morley
2018-04-30 12:51 GMT+02:00 Torsten Hämmerle :
> Hi Robert,
>
> How about simply flipping the stacking direction?
>
>\override BassFigureAlignment.stacking-dir = #UP
>
> That way, the bass figures will be piled up from bottom to top.
> Caveat: the first figure entered will be the lowest.
>
> 
>  <<
>   { 4 4 4 4 4 4 }
>   \figures {
> \override BassFigureAlignment.stacking-dir = #UP
> <_!> <3+ 6> <4> <4 5> <3+> <_+>
>   }
>  >>
> 
>
> HTH,
> Torsten


I looked for a way not to change the input order, but still benefit
from upwards stacking-dir.

Coming up with the code below.
For test-cases I used some of our reg-tests in a modified manner.

figured-bass-continuation-center.ly looks even better, imho.
figured-bass.ly is surely not meant to demonstrate real live input,
though, I add it as well, demonstrating bracketing still works.

\version "2.19.81"

reverseEventChordsElements =
#(define-music-function (mus)(ly:music?)
  (music-map
(lambda (m)
  (if (music-is-of-type? m 'event-chord)
  (let ((ev-chrd-elts (ly:music-property m 'elements)))
(ly:music-set-property! m 'elements
  (reverse
(map
  (lambda (e)
(cond ((and (eq? #t (ly:music-property e 'bracket-start))
(eq? #t (ly:music-property e 'bracket-stop)))
   '())
  ((eq? #t (ly:music-property e 'bracket-start))
   (begin
 (ly:music-set-property! e 'bracket-start '())
 (ly:music-set-property! e 'bracket-stop #t)))
  ((eq? #t (ly:music-property e 'bracket-stop))
   (begin
 (ly:music-set-property! e 'bracket-stop '())
 (ly:music-set-property! e 'bracket-start #t
e)
  ev-chrd-elts)))
m)
  m))
mus))

%%%
%% EXAMPLES
%%%

\paper { indent = 30 }

\layout {
  \context {
\FiguredBass
\override BassFigureAlignment.stacking-dir = #UP
  }
}

%%%
%% figured-bass-continuation-center.ly
%%%

mI =
\relative {
  c'8 c  b b  a a  b b
  c c  b b
}

figI =
\figuremode {
  \set useBassFigureExtenders = ##t
  \set figuredBassCenterContinuations = ##t
  <6+ 4 3>4 <6 4 3> r
  <6+ 4 3>4 <6 4 3> <4 3+> r
}

<<
  \new Staff
\with { instrumentName = "default figures" }
\mI

  \new FiguredBass
\with { \revert BassFigureAlignment.stacking-dir }
\figI

  \new Staff
\with { instrumentName = "tweaked figures" }
\mI

  \new FiguredBass
\reverseEventChordsElements
\figI
>>

%%%
%% figured-bass.ly
%%%

mII = {
  \clef bass
  c 4 c c c
  c 4 c c c
}

figII =
\figuremode {
<3 [5 7]>
<3\+ [5/] 7/ [9 11]>
<3+ 5- 7!>
<3 _! 5 _- 7>
<3 _ 5 _ 7>
<3 6/ >
<3 6\\ >
<"V7" ["bla" 6] \markup{ \musicglyph "rests.2"} >
  }

<<
  \new Staff
   \with { instrumentName = "default figures" }
\mII

  \new FiguredBass
\with { \revert BassFigureAlignment.stacking-dir }
\figII

  \new Staff
\with { instrumentName = "tweaked figures" }
\mII

  \new FiguredBass
\reverseEventChordsElements
\figII
>>

Cheers,
  Harm

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Another Figured Bass problem

2018-04-30 Thread Robert Blackstone
Hi Torsten,

A nice alternative method, one that requires some extra concentration but works 
well.
Thank you very much.

Best regards,
Robert

On 30 Apr 2018, at 12:51 , Torsten Hämmerle  wrote:

> Hi Robert,
> 
> How about simply flipping the stacking direction?
> 
>   \override BassFigureAlignment.stacking-dir = #UP
> 
> That way, the bass figures will be piled up from bottom to top.
> Caveat: the first figure entered will be the lowest.
> 
> 
> <<
>  { 4 4 4 4 4 4 }
>  \figures {
>\override BassFigureAlignment.stacking-dir = #UP
><_!> <3+ 6> <4> <4 5> <3+> <_+>
>  }
>>> 
> 
> 
> HTH,
> Torsten
> 
> 
> 
> --
> Sent from: http://lilypond.1069038.n5.nabble.com/User-f3.html
> 
> ___
> lilypond-user mailing list
> lilypond-user@gnu.org
> https://lists.gnu.org/mailman/listinfo/lilypond-user


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Another Figured Bass problem

2018-04-30 Thread Torsten Hämmerle
Hi Robert,

How about simply flipping the stacking direction?

   \override BassFigureAlignment.stacking-dir = #UP

That way, the bass figures will be piled up from bottom to top.
Caveat: the first figure entered will be the lowest.


 <<
  { 4 4 4 4 4 4 }
  \figures {
\override BassFigureAlignment.stacking-dir = #UP
<_!> <3+ 6> <4> <4 5> <3+> <_+>
  }
 >>


HTH,
Torsten



--
Sent from: http://lilypond.1069038.n5.nabble.com/User-f3.html

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Another Figured Bass problem

2018-04-30 Thread David Kastrup
Noeck  writes:

>> which can be achieved by using ‘_’ instead of a number.
>
> That's what I wanted to propose, but it didn't produce what I hoped for:
>
> \figures { < 5 4 > < _ 3+> }

Oh.  Ok.  Sorry for the noise.

-- 
David Kastrup

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Another Figured Bass problem

2018-04-30 Thread Noeck
> which can be achieved by using ‘_’ instead of a number.

That's what I wanted to propose, but it didn't produce what I hoped for:

\figures { < 5 4 > < _ 3+> }

Cheers,
Joram

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Another Figured Bass problem

2018-04-30 Thread Robert Blackstone
Hi David,
Thanks for your reaction. 

You write "So blanking entries is done by entering _ instead of a number." 
I'm not sure I fully understand this.
I have tried to get a number, for instance #3 on the second row by entering < _ 
3+ >,  but that didn't change anything; the #3 stayed on the top line.

I used the method just given by Malte Meyn.

Best regards,

Robert Blackstone 


On 30 Apr 2018, at 11:36 , David Kastrup  wrote:

> Robert Blackstone  writes:
> 
>> Dear all, 
>> 
>> In the Lilypond documentation it is shown how to stack BC figures, but I 
>> have not
>> been able to find how to put a figure in the second row with nothing above 
>> it.
>> In my score I get:
>> *
>> but what I need is:
>> 
>> *
>> 
>> I got this result by entering \  before the number, like < \  3+ >, and 
>> erasing the \ in
>> the pdf.
>> Doable but maybe not worthy of LilyPond.
>> 
>> Is there a better method?
> 
> From "Entering figured bass":
> 
>Accidentals (including naturals) may be used for modifying scale
>steps.  These are entered by appending ‘+’ (for sharps), ‘-’ (for
>flats) or ‘!’ (for naturals) after the number.  For double
>accidentals the modifier is applied twice.  For the modification of
>the third step the number is often omitted, which can be achieved by
>using ‘_’ instead of a number.
> 
> So blanking entries is done by entering _ instead of a number.
> 
> -- 
> David Kastrup


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Another Figured Bass problem

2018-04-30 Thread Robert Blackstone
Hi Malte,

Many thanks. It is what I needed.

(I think it should be in the Snippet-collection.)

Best regards, 

Robert
On 30 Apr 2018, at 11:03 , Malte Meyn  wrote:

> 
> 
> Am 30.04.2018 um 10:42 schrieb Robert Blackstone:
>> Dear all,
>> In the Lilypond documentation it is shown how to stack BC figures, but I 
>> have not been able to find how to put a figure in the second row with 
>> nothing above it.
>> In my score I get:
>> but what I need is:
>> I got this result by entering \  before the number, like < \  3+ >, and 
>> erasing the \ in the pdf.
>> Doable but maybe not worthy of LilyPond.
>> Is there a better method?
> 
> You could use a transparent number:
> 
> \version "2.19.81"
> 
> space = \markup \tiny \number \transparent 5
> 
> <<
>  { 4 4 4 4 4 4 }
>  \figures {
><5 4>
><5 3>
><\markup \tiny \number 5 3>
><\markup \tiny \number \transparent 5 3>
><5 4>
><\space 3>
>  }
> >>
> 
> ___
> lilypond-user mailing list
> lilypond-user@gnu.org
> https://lists.gnu.org/mailman/listinfo/lilypond-user


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Another Figured Bass problem

2018-04-30 Thread David Kastrup
Robert Blackstone  writes:

> Dear all, 
>
> In the Lilypond documentation it is shown how to stack BC figures, but I have 
> not
> been able to find how to put a figure in the second row with nothing above it.
> In my score I get:
> *
> but what I need is:
>
> *
>
> I got this result by entering \  before the number, like < \  3+ >, and 
> erasing the \ in
> the pdf.
> Doable but maybe not worthy of LilyPond.
>
> Is there a better method?

From "Entering figured bass":

Accidentals (including naturals) may be used for modifying scale
steps.  These are entered by appending ‘+’ (for sharps), ‘-’ (for
flats) or ‘!’ (for naturals) after the number.  For double
accidentals the modifier is applied twice.  For the modification of
the third step the number is often omitted, which can be achieved by
using ‘_’ instead of a number.

So blanking entries is done by entering _ instead of a number.

-- 
David Kastrup

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Another Figured Bass problem

2018-04-30 Thread Malte Meyn



Am 30.04.2018 um 10:42 schrieb Robert Blackstone:

Dear all,

In the Lilypond documentation it is shown how to stack BC figures, but I 
have not been able to find how to put a figure in the second row with 
nothing above it.

In my score I get:
but what I need is:


I got this result by entering \  before the number, like < \  3+ >, and 
erasing the \ in the pdf.

Doable but maybe not worthy of LilyPond.

Is there a better method?


You could use a transparent number:

\version "2.19.81"

space = \markup \tiny \number \transparent 5

<<
  { 4 4 4 4 4 4 }
  \figures {
<5 4>
<5 3>
<\markup \tiny \number 5 3>
<\markup \tiny \number \transparent 5 3>
<5 4>
<\space 3>
  }
>>

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Another Figured Bass problem

2018-04-30 Thread Robert Blackstone
Dear all, 

In the Lilypond documentation it is shown how to stack BC figures, but I have 
not been able to find how to put a figure in the second row with nothing above 
it.
In my score I get:

but what I need is:



I got this result by entering \  before the number, like < \  3+ >, and erasing 
the \ in the pdf.
Doable but maybe not worthy of LilyPond.

Is there a better method?

Thanks in advance for any advice.

Best regards,

Robert Blackstone
  

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user