Re: Lilypond-book-preamble introducing page break after custom header

2023-03-15 Thread Jean Abou Samra
Le mercredi 15 mars 2023 à 22:49 +0100, Jean Abou Samra a écrit :
> - 
> use `-dseparate-page-formats=pdf` if you want to get one output file per page 
> (or per system if also using lilypond-book-preamble.ly),
> 
> 
> - 
> use `-dtall-page-formats=pdf` if you want to get squashed pages.

P.S. Can also be done in the .ly file itself with `#(ly:set-option 
'separate-page-formats 'pdf)` or `#(ly:set-option 'tall-page-formats 'pdf)`.


signature.asc
Description: This is a digitally signed message part


Re: Lilypond-book-preamble introducing page break after custom header

2023-03-15 Thread Jean Abou Samra
Le mercredi 15 mars 2023 à 17:32 -0400, Fr. Samuel Springuel a écrit :
> The attached file compiles differently under 2.22 and 2.24: 2.24 introduces a 
> page break that isn’t present in 2.22.  This is causing some havoc in my 
> lyluatex tool chain.  Any idea what’s causing the problem and how to fix it?

This change was on purpose.

lilypond-book-preamble.ly arranges so that LilyPond's notion of pages is 
changed to make each system or markup a page of its own (except explicit 
`\book`s).

In 2.22, lilypond-book sets the EPS backend to be used, and the EPS backend 
caused two things:

* Separate-page output: one file "document-pagenumber.pdf" per page. Since 
lilypond-book-preamble.ly also turns systems into pages, that effectively means 
one page per system.

* Tall-page output: the main "document.pdf" output file is just all pages 
squashed together.

In 2.24, it doesn't do that anymore. It mostly makes the “system as page” 
setting. Furthermore, the EPS backend has been removed in favor of separate 
options:

- use `-dseparate-page-formats=pdf` if you want to get one output file per page 
(or per system if also using lilypond-book-preamble.ly),

- use `-dtall-page-formats=pdf` if you want to get squashed pages.


signature.asc
Description: This is a digitally signed message part


Lilypond-book-preamble introducing page break after custom header

2023-03-15 Thread Fr. Samuel Springuel
The attached file compiles differently under 2.22 and 2.24: 2.24 introduces a 
page break that isn’t present in 2.22.  This is causing some havoc in my 
lyluatex tool chain.  Any idea what’s causing the problem and how to fix it?

convert-ly doesn’t change anything in the file when upgrading the version.

✝✝
Fr. Samuel, OSB
(R. Padraic Springuel)
St. Anselm’s Abbey
4501 South Dakota Ave, NE
Washington, DC, 20017
202-269-2300
(c) 202-853-7036

PAX ☧ ΧΡΙΣΤΟΣ


Alan-Rees-OSB.ly
Description: Binary data


Re: lilypond-book -> latex

2022-12-02 Thread Carlos Knauer
Thanks a lot!

Em sex., 2 de dez. de 2022 02:03, Werner LEMBERG  escreveu:

>
> > I need package "lilypond-book->latex". How can I download it ?
>
> If you have downloaded or installed LilyPond, you should already have
> the `lilypond-book` script.  On the command line, say
>
> ```
> lilypond-book --help
> ```
>
> for a first overview of the available options; you need to add
> `--format=latex` to make the script handle LaTeX input files.
>
> Assuming that you are using the latest stable release (2.22.2), the
> complete documentation of `lilypond-book` is available online as
>
>   https://lilypond.org/doc/v2.22/Documentation/usage/lilypond_002dbook
>
>
> Werner
>


Re: lilypond-book -> latex

2022-12-01 Thread Werner LEMBERG


> I need package "lilypond-book->latex". How can I download it ?

If you have downloaded or installed LilyPond, you should already have
the `lilypond-book` script.  On the command line, say

```
lilypond-book --help
```

for a first overview of the available options; you need to add
`--format=latex` to make the script handle LaTeX input files.

Assuming that you are using the latest stable release (2.22.2), the
complete documentation of `lilypond-book` is available online as

  https://lilypond.org/doc/v2.22/Documentation/usage/lilypond_002dbook


Werner



lilypond-book -> latex

2022-12-01 Thread Carlos Knauer
Hi.
Carlos, from Brazil.
I need package "lilypond-book->latex". How can I download it ?
Thanks


lilypond-book latex input duplicating

2022-11-29 Thread Jason Addison
If I \input{something} twice in a lytex file, it gets duplicated by
lilypond-book. How do I keep this from happening?

I'm using lilypond 2.22.2, from brew.

For example:

inp.lytex:
>>>>
\documentclass[]{book}
\begin{document}
Hey!
\input{you}
Hey!
\input{you}
\end{document}
<<<<

you.tex:
>>>>
You!
<<<<

command:
$ lilypond-book --output=out --pdf inp.lytex

now see out/you.tex:
$ cat out/you.tex
You!
You!

There are 2 "You!" strings, and the pdf file, from running "pdflatex
inp.tex" in out/, looks like:

Hey! You! You! Hey! You! You!

What I expect is:

Hey! You! Hey! You!

By the way, if I input it three times it gets triplicated. If I do it
once, it is normal.

Thanks,
Jason



Re: lilypond-book and html

2022-10-28 Thread Jean Abou Samra

Le 28/10/2022 à 21:31, Tristan Latchford a écrit :
warning: `(gs -q -dNODISPLAY -dNOSAFER -dNOPAUSE -dBATCH -dEPSCrop 
-dAutoRotatePages=/None -dPrinted=false 
/var/folders/29/4w1k0cl94mngf7t5hbc7ht2rgn/T//lilypond-tmp-986077)' 
failed (256)


fatal error: failed files: "d4/lily-5f5a117f.ly 64/lily-933bb9de.ly"
Command '/usr/local/bin/lilypond --formats=ps,png -dbackend=eps -I  
"./"  -I  "../" -deps-box-padding=3.00  -dread-file-list 
-dno-strip-output-dir 
".../Desktop/quick-access/snippet-names-090095318efd5fabb1fd2304c2b0d3cb.ly"' 
returned non-zero exit status 1.


Can anybody help me with this, so I can get my lovely .html output?




For me, that works.

- Maybe you kept the output open in some application? Under Windows, if 
the file is open somewhere, it can't be overwritten. You need to close 
it before re-running lilypond-book.


- Does LilyPond work well outside of lilypond-book?

- If none of the above helps, can you run lilypond-book with --verbose 
and send the log?


Best,
Jean




lilypond-book and html

2022-10-28 Thread Tristan Latchford

Dear fellow 'ponderers,

I hope you are well. I have been attempting to use lilypond-book via the 
command line to create some snippets for my webpage to use as examples 
for the videos i'm currently working on.


So far, I have this:






The creation of any sound unveils its overtone series -- the series 
forms a basis upon which we form our reactions to sounds put together. 
The closest thing to this series in written notes is the simple major 
scale, see below:



    \clef bass
    c  c' g'  c
    \clef treble
    e  g  b  c  d  e  f  g  a  b c^\markup { \italic "etc..." }


While it's not entirely the same (some notes are shifted back and 
forth), I think it makes good fodder for storytelling in the harmonic 
language of the Opera. In composing the opera, the scale itself came to 
encapsulate the concept of enlightenment, and the steps upon it to 
various related concepts:





...however, when I go to invoke lilypond-book on this file, I get the 
following output from the command line:


xxx@xxx-MBP desktop % lilypond-book -o quick-access test.html
lilypond-book (GNU LilyPond) 2.22.2
Reading `.../Desktop/test.html'
Dissecting...
Writing snippets...
Processing...
Running lilypond...
GNU LilyPond 2.22.2 (running Guile 2.2)
Processing `./snippet-map-090095318efd5fabb1fd2304c2b0d3cb.ly'
Parsing...
Processing `./64/lily-933bb9de.ly'
Parsing...
Interpreting music...
Preprocessing graphical objects...
Calculating line breaks...
Drawing systems...
Layout output to `./64/lily-933bb9de.eps'...
Converting to PNG...
warning: `(gs -q -dNODISPLAY -dNOSAFER -dNOPAUSE -dBATCH -dEPSCrop 
-dAutoRotatePages=/None -dPrinted=false 
/var/folders/29/4w1k0cl94mngf7t5hbc7ht2rgn/T//lilypond-tmp-327412)' 
failed (256)


Processing `./d4/lily-5f5a117f.ly'
Parsing...
Interpreting music...
Preprocessing graphical objects...
Calculating line breaks...
Drawing systems...
Layout output to `./d4/lily-5f5a117f.eps'...
Converting to PNG...
warning: `(gs -q -dNODISPLAY -dNOSAFER -dNOPAUSE -dBATCH -dEPSCrop 
-dAutoRotatePages=/None -dPrinted=false 
/var/folders/29/4w1k0cl94mngf7t5hbc7ht2rgn/T//lilypond-tmp-986077)' 
failed (256)


fatal error: failed files: "d4/lily-5f5a117f.ly 64/lily-933bb9de.ly"
Command '/usr/local/bin/lilypond --formats=ps,png -dbackend=eps -I  
"./"  -I  "../" -deps-box-padding=3.00  -dread-file-list 
-dno-strip-output-dir 
".../Desktop/quick-access/snippet-names-090095318efd5fabb1fd2304c2b0d3cb.ly"' 
returned non-zero exit status 1.


Can anybody help me with this, so I can get my lovely .html output?

I look forward to our ongoing correspondence,

With the highest regards,

--Tristan




Re: line-width in lilypond book

2022-10-25 Thread Werner LEMBERG
>> Actually,
>>
>> ```
>> \begin[line-width=394\pt]{lilypond}
>> ```
>>
>> is also correct.
> 
> Nope.  It is backward compatibility but should not be used anywhere.
> 
> git grep '\\begin\['
> 
> unfortunately shows that this isn't consistently done yet.  The
> problem with the old form is that it is not the optional LaTeX
> option syntax and could not possibly be implemented in a
> LaTeX-internal verbatim-like environment.

OK.  David, could you prepare a documentation patch, please?


Werner



Re: line-width in lilypond book

2022-10-25 Thread David Kastrup
Werner LEMBERG  writes:

>> The correct syntax is
>> 
>> \begin{lilypond}[line-width=394\pt]
>
> Actually,
>
> ```
> \begin[line-width=394\pt]{lilypond}
> ```
>
> is also correct.

Nope.  It is backward compatibility but should not be used anywhere.

git grep '\\begin\['

unfortunately shows that this isn't consistently done yet.  The problem
with the old form is that it is not the optional LaTeX option syntax and
could not possibly be implemented in a LaTeX-internal verbatim-like
environment.

-- 
David Kastrup



Re: line-width in lilypond book

2022-10-25 Thread Jean Abou Samra




Le 25/10/2022 à 15:56, Werner LEMBERG a écrit :

The correct syntax is

\begin{lilypond}[line-width=394\pt]

Actually,

```
\begin[line-width=394\pt]{lilypond}
```

is also correct.


Ah, OK, I didn't know that. Then we need more info from the OP to 
understand what the problem actually is.




Re: line-width in lilypond book

2022-10-25 Thread Werner LEMBERG


> The correct syntax is
> 
> \begin{lilypond}[line-width=394\pt]

Actually,

```
\begin[line-width=394\pt]{lilypond}
```

is also correct.


Werner



Re: line-width in lilypond book

2022-10-25 Thread Jean Abou Samra

Le 25/10/2022 à 10:31, Stefan Thomas a écrit :

Community,
I just noticed that it doesn't seem to make any difference whether I 
write

 \begin[line-width=394\pt]{lilypond}
or
 \begin[line-width=394\pt]{lilypond}
in a latex file, that I process with lilypond-book.
The lines don't fit the page margins.
Does anyone know what to do here?



The correct syntax is

\begin{lilypond}[line-width=394\pt]

Best,
Jean




line-width in lilypond book

2022-10-25 Thread Stefan Thomas
Community,
I just noticed that it doesn't seem to make any difference whether I write
 \begin[line-width=394\pt]{lilypond}
or
 \begin[line-width=394\pt]{lilypond}
in a latex file, that I process with lilypond-book.
The lines don't fit the page margins.
Does anyone know what to do here?
Thanks,
Stefan


Re: Lilypond-book problem

2022-09-07 Thread Rip _Mus
@David : Yeah, I'm sorry, I meant ".py". Anyway, a very good analysis of
the situation!

@Knute Snortum  : Thank you for your suggestions! I'm
thinking about reporting this issue.

Il giorno mar 6 set 2022 alle ore 19:25 Knute Snortum 
ha scritto:

> On Tue, Sep 6, 2022 at 8:09 AM David Wright 
> wrote:
> >
> > On Tue 06 Sep 2022 at 11:19:28 (+0200), Rip _Mus wrote:
> > > Il giorno lun 5 set 2022 alle ore 19:06 Knute Snortum ha scritto:
> > > > On Sun, Sep 4, 2022 at 10:26 PM Rip _Mus wrote:
> > > > >> On Sun, Sep 4, 2022 at 9:06 AM Rip _Mus wrote:
> >
> > > > >> > I have installed the version 2.22.1, wich I used for a lot of
> big
> > > > project.
> > > > >> > A lot of times I tried to open terminal and run "lilypond-book"
> but
> > > > without success. I already add the folder "...\usr\bin" to the
> > > > environmental variabile path, in fact the command "lilypond" runs.
> > > > >> > Someone could help me?
> >
> > > > > thanks for the reply!  You're right, I could have added a few more
> > > > details.
> > > > > The operating system is Windows 10. For using Lilypond on command
> line,
> > > > I followed the instructions on the site.
> > > > > I added the folder "C:Program Files (x86)\LilyPond\usr\bin" to the
> > > > environmental variable “Path”.
> > > > >  I think I followed them well, as the "ilypond" command works.  The
> > > > other commands "lilypond-book" and "convert-ly" instead give me the
> > > > following message:
> > > > >
> > > > > 'lilypond-book' is not recognized as an internal or external
> command
> > > > >
> > > > > What I notice is that in the folder in question there are
> lilypond-book
> > > > and convert-ly scripts, but they are without extension (for example
> * .py)
> > > > >
> > > > > What do you think about?
> >
> > > > Well, I had the same experience as you.  One solution is to type:
> > > >
> > > > python3 "C:Program Files (x86)\LilyPond\usr\bin\lilypond-book"
> > > >
> > > > You could put that in a batch file somewhere in your PATH.  There may
> > > > be other solutions too.
> >
> > > Ok!
> > > I tried and it works very well!
> > > Another solution is to add the extension ".ly" to the file name and
> then
> > > the command runs.
> >
> > More likely you added .py ?
>
> Just adding ".py" to lilypond-book didn't work for me.  At the command
> line I got a message that "lilypond-book" was not an executable.  From
> the Windows file folder a command screen popped up for a split second,
> then vanished.
>
> But here's another way to do this: create a file called
> lilypond-book.bat somewhere in your PATH, then paste this into it:
>
> @python3 "C:\Program Files
> (x86)\LilyPond-2.22.2\usr\bin\lilypond-book" %*
>
> You should be able to type "lilypond.book" anywhere you cd to.
>
> --
> Knute Snortum
>


Re: Lilypond-book problem

2022-09-06 Thread Knute Snortum
On Tue, Sep 6, 2022 at 8:09 AM David Wright  wrote:
>
> On Tue 06 Sep 2022 at 11:19:28 (+0200), Rip _Mus wrote:
> > Il giorno lun 5 set 2022 alle ore 19:06 Knute Snortum ha scritto:
> > > On Sun, Sep 4, 2022 at 10:26 PM Rip _Mus wrote:
> > > >> On Sun, Sep 4, 2022 at 9:06 AM Rip _Mus wrote:
>
> > > >> > I have installed the version 2.22.1, wich I used for a lot of big
> > > project.
> > > >> > A lot of times I tried to open terminal and run "lilypond-book" but
> > > without success. I already add the folder "...\usr\bin" to the
> > > environmental variabile path, in fact the command "lilypond" runs.
> > > >> > Someone could help me?
>
> > > > thanks for the reply!  You're right, I could have added a few more
> > > details.
> > > > The operating system is Windows 10. For using Lilypond on command line,
> > > I followed the instructions on the site.
> > > > I added the folder "C:Program Files (x86)\LilyPond\usr\bin" to the
> > > environmental variable “Path”.
> > > >  I think I followed them well, as the "ilypond" command works.  The
> > > other commands "lilypond-book" and "convert-ly" instead give me the
> > > following message:
> > > >
> > > > 'lilypond-book' is not recognized as an internal or external command
> > > >
> > > > What I notice is that in the folder in question there are lilypond-book
> > > and convert-ly scripts, but they are without extension (for example * .py)
> > > >
> > > > What do you think about?
>
> > > Well, I had the same experience as you.  One solution is to type:
> > >
> > > python3 "C:Program Files (x86)\LilyPond\usr\bin\lilypond-book"
> > >
> > > You could put that in a batch file somewhere in your PATH.  There may
> > > be other solutions too.
>
> > Ok!
> > I tried and it works very well!
> > Another solution is to add the extension ".ly" to the file name and then
> > the command runs.
>
> More likely you added .py ?

Just adding ".py" to lilypond-book didn't work for me.  At the command
line I got a message that "lilypond-book" was not an executable.  From
the Windows file folder a command screen popped up for a split second,
then vanished.

But here's another way to do this: create a file called
lilypond-book.bat somewhere in your PATH, then paste this into it:

@python3 "C:\Program Files (x86)\LilyPond-2.22.2\usr\bin\lilypond-book" %*

You should be able to type "lilypond.book" anywhere you cd to.

--
Knute Snortum



Re: Lilypond-book problem

2022-09-06 Thread David Wright
On Tue 06 Sep 2022 at 11:19:28 (+0200), Rip _Mus wrote:
> Il giorno lun 5 set 2022 alle ore 19:06 Knute Snortum ha scritto:
> > On Sun, Sep 4, 2022 at 10:26 PM Rip _Mus wrote:
> > >> On Sun, Sep 4, 2022 at 9:06 AM Rip _Mus wrote:

> > >> > I have installed the version 2.22.1, wich I used for a lot of big
> > project.
> > >> > A lot of times I tried to open terminal and run "lilypond-book" but
> > without success. I already add the folder "...\usr\bin" to the
> > environmental variabile path, in fact the command "lilypond" runs.
> > >> > Someone could help me?

> > > thanks for the reply!  You're right, I could have added a few more
> > details.
> > > The operating system is Windows 10. For using Lilypond on command line,
> > I followed the instructions on the site.
> > > I added the folder "C:Program Files (x86)\LilyPond\usr\bin" to the
> > environmental variable “Path”.
> > >  I think I followed them well, as the "ilypond" command works.  The
> > other commands "lilypond-book" and "convert-ly" instead give me the
> > following message:
> > >
> > > 'lilypond-book' is not recognized as an internal or external command
> > >
> > > What I notice is that in the folder in question there are lilypond-book
> > and convert-ly scripts, but they are without extension (for example * .py)
> > >
> > > What do you think about?

> > Well, I had the same experience as you.  One solution is to type:
> >
> > python3 "C:Program Files (x86)\LilyPond\usr\bin\lilypond-book"
> >
> > You could put that in a batch file somewhere in your PATH.  There may
> > be other solutions too.

> Ok!
> I tried and it works very well!
> Another solution is to add the extension ".ly" to the file name and then
> the command runs.

More likely you added .py ?

> I don't understand why it is not the way described in Lilypond manuals.
> Anyway, thank you so much for your help!

The archetypal system for Lilypond is un*x/linux, so the documentation
reflects that. Where Windows differs, that's often pointed out. See,
for example, Usage §2.2 Invoking convert-ly.

Unfortunately, the principal reference for Windows on the Command Line
doesn't mention this difference or give an example (lilypond itself is
a real EXE file, whereas all the support programs are Python scripts):

https://lilypond.org/windows.html

web.pdf page number 44, physical page 46.

Perhaps the reason is that the documentation writer(s) had set their
environment variable PATHEXT to include .py (or should it be .PY ?)
long ago, and have forgotten about it:

https://www.nextofwindows.com/what-is-pathext-environment-variable-in-windows

But sometimes that appears not to be the answer either:

https://superuser.com/questions/1619580/pathext-environment-variable-not-working

--

In researching this, I noticed that, on the web, the target of
https://lilypond.org/doc/v2.23/Documentation/web-big-page.html#windows
appears to be Nicolas Sceaux's use of LP, whereas the 2.23.12 version
on my system points to the correct place in the page, corresponding to:

https://lilypond.org/windows.html

Disclaimer: I don't use Windows, so all is hypothetical.

Cheers,
David.



Re: Lilypond-book problem

2022-09-06 Thread Knute Snortum
On Tue, Sep 6, 2022 at 2:19 AM Rip _Mus  wrote:
>
> Ok!
> I tried and it works very well!
> Another solution is to add the extension ".ly" to the file name and then the 
> command runs.

Huh.  I'm surprised that works.  I guess LilyPond is smart enough to
execute Python code.

> I don't understand why it is not the way described in Lilypond manuals.

Well, you can report it as a bug at https://lilypond.org/bug-reports.html

Or you can even change it by contributing!
https://lilypond.org/doc/v2.23/Documentation/contributor/documentation-work

--
Knute Snortum



Re: Lilypond-book problem

2022-09-06 Thread Rip _Mus
Ok!
I tried and it works very well!
Another solution is to add the extension ".ly" to the file name and then
the command runs.
I don't understand why it is not the way described in Lilypond manuals.
Anyway, thank you so much for your help!

Il giorno lun 5 set 2022 alle ore 19:06 Knute Snortum 
ha scritto:

> Well, I had the same experience as you.  One solution is to type:
>
> python3 "C:Program Files (x86)\LilyPond\usr\bin\lilypond-book"
>
> You could put that in a batch file somewhere in your PATH.  There may
> be other solutions too.
>
> --
> Knute Snortum
>
>
> On Sun, Sep 4, 2022 at 10:26 PM Rip _Mus 
> wrote:
> >
> > Good morning,
> > thanks for the reply!  You're right, I could have added a few more
> details.
> > The operating system is Windows 10. For using Lilypond on command line,
> I followed the instructions on the site.
> > I added the folder "C:Program Files (x86)\LilyPond\usr\bin" to the
> environmental variable “Path”.
> >  I think I followed them well, as the "ilypond" command works.  The
> other commands "lilypond-book" and "convert-ly" instead give me the
> following message:
> >
> > 'lilypond-book' is not recognized as an internal or external command
> >
> > What I notice is that in the folder in question there are lilypond-book
> and convert-ly scripts, but they are without extension (for example * .py)
> >
> > What do you think about?
> >
> >
> > Il lun 5 set 2022, 02:13 Knute Snortum  ha scritto:
> >>
> >> On Sun, Sep 4, 2022 at 9:06 AM Rip _Mus 
> wrote:
> >> >
> >> > Good morning,
> >> > I have installed the version 2.22.1, wich I used for a lot of big
> project.
> >> > A lot of times I tried to open terminal and run "lilypond-book" but
> without success. I already add the folder "...\usr\bin" to the
> environmental variabile path, in fact the command "lilypond" runs.
> >> > Someone could help me?
> >>
> >> It would be helpful to know exactly what is going wrong.  Do you get
> >> error messages?  Post them.  Not doing what you think it should?  Tell
> >> us what it's doing and what you think it should be doing.  Also, tell
> >> us the OS, is it linux?
> >>
> >> --
> >> Knute Snortum
>


Re: Lilypond-book problem

2022-09-05 Thread Knute Snortum
Well, I had the same experience as you.  One solution is to type:

python3 "C:Program Files (x86)\LilyPond\usr\bin\lilypond-book"

You could put that in a batch file somewhere in your PATH.  There may
be other solutions too.

--
Knute Snortum


On Sun, Sep 4, 2022 at 10:26 PM Rip _Mus  wrote:
>
> Good morning,
> thanks for the reply!  You're right, I could have added a few more details.
> The operating system is Windows 10. For using Lilypond on command line, I 
> followed the instructions on the site.
> I added the folder "C:Program Files (x86)\LilyPond\usr\bin" to the 
> environmental variable “Path”.
>  I think I followed them well, as the "ilypond" command works.  The other 
> commands "lilypond-book" and "convert-ly" instead give me the following 
> message:
>
> 'lilypond-book' is not recognized as an internal or external command
>
> What I notice is that in the folder in question there are lilypond-book and 
> convert-ly scripts, but they are without extension (for example * .py)
>
> What do you think about?
>
>
> Il lun 5 set 2022, 02:13 Knute Snortum  ha scritto:
>>
>> On Sun, Sep 4, 2022 at 9:06 AM Rip _Mus  wrote:
>> >
>> > Good morning,
>> > I have installed the version 2.22.1, wich I used for a lot of big project.
>> > A lot of times I tried to open terminal and run "lilypond-book" but 
>> > without success. I already add the folder "...\usr\bin" to the 
>> > environmental variabile path, in fact the command "lilypond" runs.
>> > Someone could help me?
>>
>> It would be helpful to know exactly what is going wrong.  Do you get
>> error messages?  Post them.  Not doing what you think it should?  Tell
>> us what it's doing and what you think it should be doing.  Also, tell
>> us the OS, is it linux?
>>
>> --
>> Knute Snortum



Re: Lilypond-book problem

2022-09-04 Thread Rip _Mus
Good morning,
thanks for the reply!  You're right, I could have added a few more details.
The operating system is Windows 10. For using Lilypond on command line, I
followed the instructions on the site.
I added the folder "C:Program Files (x86)\LilyPond\usr\bin" to the
environmental variable “Path”.
 I think I followed them well, as the "ilypond" command works.  The other
commands "lilypond-book" and "convert-ly" instead give me the following
message:

'lilypond-book' is not recognized as an internal or external command

What I notice is that in the folder in question there are lilypond-book and
convert-ly scripts, but they are without extension (for example * .py)

What do you think about?


Il lun 5 set 2022, 02:13 Knute Snortum  ha scritto:

> On Sun, Sep 4, 2022 at 9:06 AM Rip _Mus 
> wrote:
> >
> > Good morning,
> > I have installed the version 2.22.1, wich I used for a lot of big
> project.
> > A lot of times I tried to open terminal and run "lilypond-book" but
> without success. I already add the folder "...\usr\bin" to the
> environmental variabile path, in fact the command "lilypond" runs.
> > Someone could help me?
>
> It would be helpful to know exactly what is going wrong.  Do you get
> error messages?  Post them.  Not doing what you think it should?  Tell
> us what it's doing and what you think it should be doing.  Also, tell
> us the OS, is it linux?
>
> --
> Knute Snortum
>


Re: Lilypond-book problem

2022-09-04 Thread Knute Snortum
On Sun, Sep 4, 2022 at 9:06 AM Rip _Mus  wrote:
>
> Good morning,
> I have installed the version 2.22.1, wich I used for a lot of big project.
> A lot of times I tried to open terminal and run "lilypond-book" but without 
> success. I already add the folder "...\usr\bin" to the environmental 
> variabile path, in fact the command "lilypond" runs.
> Someone could help me?

It would be helpful to know exactly what is going wrong.  Do you get
error messages?  Post them.  Not doing what you think it should?  Tell
us what it's doing and what you think it should be doing.  Also, tell
us the OS, is it linux?

--
Knute Snortum



Lilypond-book problem

2022-09-04 Thread Rip _Mus
Good morning,
I have installed the version 2.22.1, wich I used for a lot of big project.
A lot of times I tried to open terminal and run "lilypond-book" but without
success. I already add the folder "...\usr\bin" to the environmental
variabile path, in fact the command "lilypond" runs.
Someone could help me?

Thank you

Rip_mus


Re: lilypond-book texinfo and a two-book-ly-file

2022-07-17 Thread Thomas Morley
Am Sa., 9. Juli 2022 um 13:41 Uhr schrieb Thomas Morley
:

> (2) One of the books is in portrait the other in landscape format
> Is there any texinfo option to get the landscape one rotated?
> That landscape thingy is needed and I can't change it, it may be an
> option to drop the portrait-book, though.
> Even dropping that one I'd need to get the landscape output rotated, though.

I found a way to support portrait _and_ landscape, at least this
problem is solved.



Re: lilypond-book texinfo and a two-book-ly-file

2022-07-09 Thread Thomas Morley
Am Sa., 9. Juli 2022 um 16:44 Uhr schrieb Jean Abou Samra :
>
>
>
> Le 09/07/2022 à 13:41, Thomas Morley a écrit :
> > Hi,
> >
> > for some huge custom code I'm going to write some documentation using 
> > texinfo.
> > I started to set up the file manual.tely.
> > In terminal then:
> >  lilypond-book manual.tely
> >  texi2html manual.texi
> >
> > At some point I have:
> > @lilypondfile[quote]{../doc-snippets/haenschen-klein.ly}
> >
> > Two questions about it:
> > (1) This ly-file ouputs two books and I see several images after
> > running lilypond-book for it:
> > lily-6333cb39-1-1.eps
> > lily-6333cb39-1.eps
> > lily-6333cb39.eps
> > lily-6333cb39-1.png
> > lily-6333cb39.png
> > Alas only the output of the first book is finally printed (i.e. after 
> > texi2html)
> > Is it possible get both books printed?
>
>
> A low-tech solution is to put your music variables in an
> include file and do two ly snippets, each with one of the
> two books.

Ok, I'll continue to try out things :)

> > (2) One of the books is in portrait the other in landscape format
> > Is there any texinfo option to get the landscape one rotated?
> > That landscape thingy is needed and I can't change it, it may be an
> > option to drop the portrait-book, though.
> > Even dropping that one I'd need to get the landscape output rotated, though.
>
> I don't think Texinfo has an easy way to rotate an image when
> inserting it.
>
> If I were to do this, I would probably just write the documentation
> in a .ly file using \markup. Alternatively, I might use Sphinx,
> which unlike Texinfo is extensible, and modify
> https://github.com/sphinx-notes/lilypond
> to add support for rotating the output.
>
> Jean
>

I'll really love the texinfo/lilypond-book/html combination.
Most the feature to click on an image and get the source-code.

Thus \markup in ly-file is no option.
I once tried for another project, it was a nightmare...

I had a quick glance over the sphinx docu
https://sphinx.silverrainz.me/lilypond/
But couldn't figure whether it's possible with sphinx?

Thanks,
  Harm



Re: lilypond-book texinfo and a two-book-ly-file

2022-07-09 Thread Jean Abou Samra




Le 09/07/2022 à 13:41, Thomas Morley a écrit :

Hi,

for some huge custom code I'm going to write some documentation using texinfo.
I started to set up the file manual.tely.
In terminal then:
 lilypond-book manual.tely
 texi2html manual.texi

At some point I have:
@lilypondfile[quote]{../doc-snippets/haenschen-klein.ly}

Two questions about it:
(1) This ly-file ouputs two books and I see several images after
running lilypond-book for it:
lily-6333cb39-1-1.eps
lily-6333cb39-1.eps
lily-6333cb39.eps
lily-6333cb39-1.png
lily-6333cb39.png
Alas only the output of the first book is finally printed (i.e. after texi2html)
Is it possible get both books printed?



A low-tech solution is to put your music variables in an
include file and do two ly snippets, each with one of the
two books.



(2) One of the books is in portrait the other in landscape format
Is there any texinfo option to get the landscape one rotated?
That landscape thingy is needed and I can't change it, it may be an
option to drop the portrait-book, though.
Even dropping that one I'd need to get the landscape output rotated, though.


I don't think Texinfo has an easy way to rotate an image when
inserting it.

If I were to do this, I would probably just write the documentation
in a .ly file using \markup. Alternatively, I might use Sphinx,
which unlike Texinfo is extensible, and modify
https://github.com/sphinx-notes/lilypond
to add support for rotating the output.

Jean




lilypond-book texinfo and a two-book-ly-file

2022-07-09 Thread Thomas Morley
Hi,

for some huge custom code I'm going to write some documentation using texinfo.
I started to set up the file manual.tely.
In terminal then:
lilypond-book manual.tely
texi2html manual.texi

At some point I have:
@lilypondfile[quote]{../doc-snippets/haenschen-klein.ly}

Two questions about it:
(1) This ly-file ouputs two books and I see several images after
running lilypond-book for it:
lily-6333cb39-1-1.eps
lily-6333cb39-1.eps
lily-6333cb39.eps
lily-6333cb39-1.png
lily-6333cb39.png
Alas only the output of the first book is finally printed (i.e. after texi2html)
Is it possible get both books printed?

(2) One of the books is in portrait the other in landscape format
Is there any texinfo option to get the landscape one rotated?
That landscape thingy is needed and I can't change it, it may be an
option to drop the portrait-book, though.
Even dropping that one I'd need to get the landscape output rotated, though.

Thanks,
  Harm



Re: Any LyX users? Missing prerequisites: lilypond-book->latex

2022-05-31 Thread Andrew Bernard
No I mean it would be good if you submitted this module to OLL when I 
get it back up and running soonish.


Andrew


Henning Hraban Ramm wrote on 1/06/2022 1:13 AM:

That’s good to hear – but do you mean with OLL?





Re: Any LyX users? Missing prerequisites: lilypond-book->latex

2022-05-31 Thread Jacques Peron
Sorry, I forgot saying that the code between backticks should be saved to a
"test.tex" file.

Le mar. 31 mai 2022 à 17:19, Jacques Peron  a écrit :

> Le mar. 31 mai 2022 à 16:18, Kevin Cole  a écrit :
>
>> On Tue, May 31, 2022 at 10:02 AM Damian leGassick
>>  wrote:
>>
>> > My sense is also that for smaller documents, learning Lyx is actually
>> more work than just learning lilypond-book as tweaks outside of what Lyx
>> provides (and there could be many) require you to know your way around
>> normal ()TeX.
>>
>> Uh-oh. That's a bit worrisome, since I was stymied by lilypond-book
>> alone... Since you're the only person so far who seems to have spent
>> time with LyX, I'll take that under serious advisement...
>>
>> Depending on your needs, you could probably try with [lyluatex](
> https://github.com/jperon/lyluatex). For simple docs, it can be as simple
> as (backticks excluded):
>
> ```
> \documentclass{article}
> \usepackage{libertine}
> \usepackage{lyluatex}
>
> \begin{document}
>
> \lilypond{a b c}
>
> % To include external test.ly, uncomment next line
> %\lilypondfile{test.ly}
>
> \end{document}
> ```
>
> Then, assuming you have a proper installation of LilyPond and TeXLive (the
> simple way: apt install lilypond texlive-full):
> lualatex --shell-escape test
>
> Good luck!
>
>
>


Re: Any LyX users? Missing prerequisites: lilypond-book->latex

2022-05-31 Thread Jacques Peron
Le mar. 31 mai 2022 à 16:18, Kevin Cole  a écrit :

> On Tue, May 31, 2022 at 10:02 AM Damian leGassick
>  wrote:
>
> > My sense is also that for smaller documents, learning Lyx is actually
> more work than just learning lilypond-book as tweaks outside of what Lyx
> provides (and there could be many) require you to know your way around
> normal ()TeX.
>
> Uh-oh. That's a bit worrisome, since I was stymied by lilypond-book
> alone... Since you're the only person so far who seems to have spent
> time with LyX, I'll take that under serious advisement...
>
> Depending on your needs, you could probably try with [lyluatex](
https://github.com/jperon/lyluatex). For simple docs, it can be as simple
as (backticks excluded):

```
\documentclass{article}
\usepackage{libertine}
\usepackage{lyluatex}

\begin{document}

\lilypond{a b c}

% To include external test.ly, uncomment next line
%\lilypondfile{test.ly}

\end{document}
```

Then, assuming you have a proper installation of LilyPond and TeXLive (the
simple way: apt install lilypond texlive-full):
lualatex --shell-escape test

Good luck!


Re: Any LyX users? Missing prerequisites: lilypond-book->latex

2022-05-31 Thread Henning Hraban Ramm

Am 31.05.22 um 17:01 schrieb Andrew Bernard:
The OLL repo will be ready again in a few days. An excellent candidate 
for that.


I used ConTeXt with great success in the past.


That’s good to hear – but do you mean with OLL?

AFAIR Urs provided just LaTeX support for his critical edition stuff.

But everything that works within LilyPond of course also works with 
ConTeXt, since “we” include only the resulting PDFs.


Hraban



Re: Any LyX users? Missing prerequisites: lilypond-book->latex

2022-05-31 Thread Andrew Bernard

Hello Hraban.

The OLL repo will be ready again in a few days. An excellent candidate 
for that.


I used ConTeXt with great success in the past.

Andrew


Henning Hraban Ramm wrote on 1/06/2022 12:49 AM:
I actually don’t use LaTeX but ConTeXt where I wrote the LilyPond 
bridge myself (https://wiki.contextgarden.net/LilyPond; I should adapt 
it to a current LP version). It’s not as sophisticated as the 
collaboration between LaTeX and LilyPond, esp. if you look at Urs 
Liska’s work, but it was always enough for my songbooks. 




Re: Any LyX users? Missing prerequisites: lilypond-book->latex

2022-05-31 Thread Henning Hraban Ramm

Am 31.05.22 um 16:02 schrieb Damian leGassick:

That said, it is a good environment for embedding multiple Lilypond generated 
pdf/eps in a structured text document, because any changes in those pdf/eps 
files are picked up automatically without having to reimport them (cf MS Word) 
or even refresh Lyx - they just change.


Of course, since TeX takes what’s there in every run. Layout apps 
warning you that something has changed is sometimes helpful (but 
annoying in most cases).



be aware that multi-page lilypond scores need to be imported into Lyx one page 
at a time - it will not ‘flow’ a score between multiple boxes.


I don’t know how LyX does it, but you can select pages from multipage 
PDFs with the \includepdf command from the pdfpages package.



My sense is also that for smaller documents, learning Lyx is actually more work 
than just learning lilypond-book as tweaks outside of what Lyx provides (and 
there could be many) require you to know your way around normal ()TeX.


I never liked LyX and its way to hide TeX behind a GUI, since you will 
get in trouble as soon as something happens or as you need something extra.


I’m also quite sure the usual way to include LilyPond scores is system 
by system, since lilypond-book produces them.


I actually don’t use LaTeX but ConTeXt where I wrote the LilyPond bridge 
myself (https://wiki.contextgarden.net/LilyPond; I should adapt it to a 
current LP version). It’s not as sophisticated as the collaboration 
between LaTeX and LilyPond, esp. if you look at Urs Liska’s work, but it 
was always enough for my songbooks.


Hraban



Re: Any LyX users? Missing prerequisites: lilypond-book->latex

2022-05-31 Thread Damian leGassick


> 
> Uh-oh. That's a bit worrisome, since I was stymied by lilypond-book
> alone... Since you're the only person so far who seems to have spent
> time with LyX, I'll take that under serious advisement...

For simple stuff Lyx is much simpler. I’d certainly recommend you try it.


Re: Any LyX users? Missing prerequisites: lilypond-book->latex

2022-05-31 Thread Kevin Cole
On Tue, May 31, 2022 at 10:02 AM Damian leGassick
 wrote:

> fwiw I was never able to get Lyx’s native Lilypond mode working reliably. The 
> manual was, and remains completely unhelpful.

Thanks! Knowing that the manual is unhelpful is really helpful. ;-)
Not to mention knowing that LyX's native LilyPond mode is sketchy.

> That said, it is a good environment for embedding multiple Lilypond generated 
> pdf/eps in a structured text document, because any changes in those pdf/eps 
> files are picked up automatically without having to reimport them (cf MS 
> Word) or even refresh Lyx - they just change.

Okay. I can [he says prematurely and optimistically] work with that.

> I’ve typeset a long complex analytical doctoral thesis and several 
> harmony/analysis workbooks like this and it works really well.

As a rank amateur (sometimes very rank) merely attempting to replicate
what I see on paper with a less-than-complete understanding of what
I'm looking at, my needs are, I think, considerably more modest. (I'm
doing it more for preservation, and the benefit of my friends who
actually do read music. They'll be able to either put it on the
electronic device of their choice, or print out better-looking copies.
Then, I then follow them, playing by ear.)

> be aware that multi-page lilypond scores need to be imported into Lyx one 
> page at a time - it will not ‘flow’ a score between multiple boxes.

Also an "important safety tip" that I can work with. (I've got Linux
applications that burst multiple pages into individual files.)

> My sense is also that for smaller documents, learning Lyx is actually more 
> work than just learning lilypond-book as tweaks outside of what Lyx provides 
> (and there could be many) require you to know your way around normal ()TeX.

Uh-oh. That's a bit worrisome, since I was stymied by lilypond-book
alone... Since you're the only person so far who seems to have spent
time with LyX, I'll take that under serious advisement...



Re: Any LyX users? Missing prerequisites: lilypond-book->latex

2022-05-31 Thread Damian leGassick
fwiw I was never able to get Lyx’s native Lilypond mode working reliably. The 
manual was, and remains completely unhelpful.

That said, it is a good environment for embedding multiple Lilypond generated 
pdf/eps in a structured text document, because any changes in those pdf/eps 
files are picked up automatically without having to reimport them (cf MS Word) 
or even refresh Lyx - they just change.

I’ve typeset a long complex analytical doctoral thesis and several 
harmony/analysis workbooks like this and it works really well.

be aware that multi-page lilypond scores need to be imported into Lyx one page 
at a time - it will not ‘flow’ a score between multiple boxes.

My sense is also that for smaller documents, learning Lyx is actually more work 
than just learning lilypond-book as tweaks outside of what Lyx provides (and 
there could be many) require you to know your way around normal ()TeX.

D

> On 30 May 2022, at 19:08, David Wright  wrote:
> 
> On Sun 29 May 2022 at 20:30:34 (-0400), Kevin Cole wrote:
>> [Asked on the lyx mailing list but, so far, no response.]
>> 
>> I'm running the latest -- and greatest(?)  -- release of Pop!_OS,
>> which is effectively Ubuntu. Specifically, 22.04 LTS ("Jammy").
>> 
>> I'm finding myself having a hard enough time with LilyPond alone,
>> without the added burden of learning everything about LaTeX, XeTeX,
>> LuaTeX, etc, (just to get the font I want) along with LilyPond-Book.
>> So, I'm hoping, for what I want to do, that LyX -- which I also don't
>> know, will be less of a climb.
> 
> It seems a slightly odd choice to me, as it's designed AIUI to give
> a more wysiwyg experience, which would seem to be the opposite of
> the lilypond-book workflow. Perhaps I'm wrong.
> 
>> I've just installed LyX and have not adjusted any preferences /
>> options / configurations. When I try Help -> Specific Manuals ->
>> LilyPond I get a pop-up:
> 
> Very appropriate!
> 
>> __
>> The module lilypond requires a package that is not
>> available in your LaTeX installation, or a converter that
>> you have not installed. LaTeX output may not be possible.
>> Missing prerequisites:
>>lilypond-book->latex
>> See section 3.1.2.3 (Modules) of the User's Guide for more information.
>> __



Re: Any LyX users? Missing prerequisites: lilypond-book->latex

2022-05-30 Thread David Wright
On Sun 29 May 2022 at 20:30:34 (-0400), Kevin Cole wrote:
> [Asked on the lyx mailing list but, so far, no response.]
> 
> I'm running the latest -- and greatest(?)  -- release of Pop!_OS,
> which is effectively Ubuntu. Specifically, 22.04 LTS ("Jammy").
> 
> I'm finding myself having a hard enough time with LilyPond alone,
> without the added burden of learning everything about LaTeX, XeTeX,
> LuaTeX, etc, (just to get the font I want) along with LilyPond-Book.
> So, I'm hoping, for what I want to do, that LyX -- which I also don't
> know, will be less of a climb.

It seems a slightly odd choice to me, as it's designed AIUI to give
a more wysiwyg experience, which would seem to be the opposite of
the lilypond-book workflow. Perhaps I'm wrong.

> I've just installed LyX and have not adjusted any preferences /
> options / configurations. When I try Help -> Specific Manuals ->
> LilyPond I get a pop-up:

Very appropriate!

> __
> The module lilypond requires a package that is not
> available in your LaTeX installation, or a converter that
> you have not installed. LaTeX output may not be possible.
> Missing prerequisites:
> lilypond-book->latex
> See section 3.1.2.3 (Modules) of the User's Guide for more information.
> __
> 
> I've read elsewhere that it should just work "out of the box" on
> Ubuntu systems. I ran the Tools->Reconfigure (though
> from everything I read it wasn't necessary). No change. It still
> didn't find what it's looking for. Anyone know what I'm missing?

Well, if § 3.1.2.3 (Modules) of the User's Guide doesn't help (what
does it say), I would look through the .log file from an attempt at
running LP-book, and see if it tells you what it's specifically
failing to find.

Running under strace might tell you more, by showing which files it
looks for and attempts to open, but it's voluminous and may be
difficult to interpret.

Cheers,
David.



Any LyX users? Missing prerequisites: lilypond-book->latex

2022-05-29 Thread Kevin Cole
[Asked on the lyx mailing list but, so far, no response.]

Hi,

I'm running the latest -- and greatest(?)  -- release of Pop!_OS,
which is effectively Ubuntu. Specifically, 22.04 LTS ("Jammy").

I'm finding myself having a hard enough time with LilyPond alone,
without the added burden of learning everything about LaTeX, XeTeX,
LuaTeX, etc, (just to get the font I want) along with LilyPond-Book.
So, I'm hoping, for what I want to do, that LyX -- which I also don't
know, will be less of a climb.

I've just installed LyX and have not adjusted any preferences /
options / configurations. When I try Help -> Specific Manuals ->
LilyPond I get a pop-up:
__
The module lilypond requires a package that is not
available in your LaTeX installation, or a converter that
you have not installed. LaTeX output may not be possible.
Missing prerequisites:
    lilypond-book->latex
See section 3.1.2.3 (Modules) of the User's Guide for more information.
__

I've read elsewhere that it should just work "out of the box" on
Ubuntu systems. I ran the Tools->Reconfigure (though
from everything I read it wasn't necessary). No change. It still
didn't find what it's looking for. Anyone know what I'm missing?

P.S. For the record, I have:

$ lyx --version
LyX 2.3.6 (2020-11-27)
Configuration
  Host type:   x86_64-pc-linux-gnu
...

$ lilypond --version
GNU LilyPond 2.22.1

$ lilypond-book --version
2.22.1

$ latex --version
pdfTeX 3.141592653-2.6-1.40.22 (TeX Live 2022/dev/Debian)
kpathsea version 6.3.4/dev
Copyright 2021 Han The Thanh (pdfTeX) et al.

Just to be sure:

$ dpkg -l | \
> tr -s "\t " " " | \
> cut -d " " -f 2-3 | \
> egrep "(lyx|tex|lilypond)" | \
> egrep -v "tex(t|port)"
fonts-lyx 2.3.6-1
fonts-texgyre 20180621-3.1
geany-plugin-latex 1.38+dfsg-1
latexmk 1:4.76-1
libptexenc1:amd64 2021.20210626.59705-1build1
libsynctex2:amd64 2021.20210626.59705-1build1
libtexlua53:amd64 2021.20210626.59705-1build1
libtexluajit2:amd64 2021.20210626.59705-1build1
lilypond 2.22.1-2
lilypond-data 2.22.1-2
lilypond-doc 2.22.1-2
lilypond-doc-html 2.22.1-2
lilypond-doc-pdf 2.22.1-2
lilypond-fonts 2.22.1-2
lyx 2.3.6-1
lyx-common 2.3.6-1
pd-motex 1.1.4-4
preview-latex-style 12.2-1ubuntu1
tex-common 6.17
tex-gyre 20180621-3.1
texinfo 6.8-4build1
texlive 2021.20220204-1
texlive-base 2021.20220204-1
texlive-binaries 2021.20210626.59705-1build1
texlive-extra-utils 2021.20220204-1
texlive-font-utils 2021.20220204-1
texlive-fonts-recommended 2021.20220204-1
texlive-fonts-recommended-doc 2021.20220204-1
texlive-lang-english 2021.20220204-1
texlive-lang-greek 2021.20220204-1
texlive-latex-base 2021.20220204-1
texlive-latex-base-doc 2021.20220204-1
texlive-latex-extra 2021.20220204-1
texlive-latex-extra-doc 2021.20220204-1
texlive-latex-recommended 2021.20220204-1
texlive-latex-recommended-doc 2021.20220204-1
texlive-luatex 2021.20220204-1
texlive-metapost 2021.20220204-1
texlive-metapost-doc 2021.20220204-1
texlive-pictures 2021.20220204-1
texlive-pictures-doc 2021.20220204-1
texlive-plain-generic 2021.20220204-1
texlive-science 2021.20220204-1
texlive-xetex 2021.20220204-1


-- 
Physical
Kevin Cole, RHCE
("ubuntourist")
Brain-Washington,
Disenfranchised City
Virtual
Git:
https://codeberg.org/ubuntourist/
CV:
https://stackoverflow.com/cv/ubuntourist/
LinkedIn:
https://linkedin.com/in/ubuntourist/
GPG Key ID: 0x3E696927



Re: new behavior of lilypond-book-preamble.ly?

2022-04-01 Thread Martin Tarenskeen
Op vrijdag 1 april 2022 om 19:05:42 +0200 schreef K. Blum 
:

Problem solved!
 Many thanks to Jean, Carl and Han-Wen for providing the solution.
 There is a new OOoLilyPond release: 

 Only for LilyPond versions 2.23.5 and later, the new options are 
inserted into the command line call.

 Nothing else has to be changed. I'm happy again. ;-)

 Cheers,
 Klaus


Thanks for the new release! Seems to work out-of-the-box here :-)

MT



Re: new behavior of lilypond-book-preamble.ly?

2022-04-01 Thread K. Blum



Am 30.03.2022 um 18:32 schrieb Carl Sorensen:


But the problem identified in the issue is related to adding a new
lilypond option (-dlilypondbookoutput), which I assume lilypond-book
calls but OOoLilyPond does not.  If I were trying to solve this
problem, that's where I would look to start.  I suspect that the new
option should be included when calling lilypond.



Han-Wen said that the scheme code needed for compatibility with
previous versions was two ly:set-option calls.  And ly:set-option
calls are available from the command line: (See the Usage Manual)
<https://lilypond.org/doc/v2.22/Documentation/usage/command_002dline-usage#advanced-command-line-options-for-lilypond>.



Problem solved!
Many thanks to Jean, Carl and Han-Wen for providing the solution.
There is a new OOoLilyPond release:
https://github.com/OOoLilyPond/OOoLilyPond/releases/tag/v1.1.5
Only for LilyPond versions 2.23.5 and later, the new options are
inserted into the command line call.
Nothing else has to be changed. I'm happy again. ;-)

Cheers,
Klaus


Re: new behavior of lilypond-book-preamble.ly?

2022-03-30 Thread K. Blum



Am 30.03.2022 um 18:32 schrieb Carl Sorensen:


I think that is not true.  Han-Wen said that the scheme code needed
for compatibility with previous versions was two ly:set-option calls. 
And ly:set-option calls are available from the command line: (See the
Usage Manual)
.

HTH,

Carl


Yes!!! That does the trick.
With   -dtall-page-formats=eps,png,pdf   and
-dseparate-page-formats=eps,png,pdf    I will be able to modify the
command line call as needed.

Thanks a million to Carl and Han-Wen!

Cheers,
Klaus


Re: new behavior of lilypond-book-preamble.ly?

2022-03-30 Thread K. Blum


Am 30.03.2022 um 18:32 schrieb Carl Sorensen:



On Wed, Mar 30, 2022 at 10:09 AM K. Blum  wrote:


Am 30.03.2022 um 17:59 schrieb Carl Sorensen:


But when I look at the code in OOoLilyPond/LilyPond.xba

<https://github.com/OOoLilyPond/OOoLilyPond/blob/master/extension/OOoLilyPond/LilyPond.xba>
I see that

 1. There is a way to check the LilyPond version
 2. The code already modifies include statements to add an
appropriate path
 3. The code builds the command used to call lilypond


Yes, that's true.

As long as a modification of *how LilyPond is called on the
command line* is sufficient, there is no problem at all.
Would that be possible?


I don't know.  But the problem identified in the issue is related to
adding a new lilypond option (-dlilypondbookoutput), which I assume
lilypond-book calls but OOoLilyPond does not.  If I were trying to
solve this problem, that's where I would look to start.  I suspect
that the new option should be included when calling lilypond.

But I have no experience with using OOoLilyPond, so I don't know this
for sure.


From what I read in Jean's response and on the GitLab issue page,
I get the impression that it would be necessary to change the
content of the *.ly files themselves. Is that correct?


I think that is not true.  Han-Wen said that the scheme code needed
for compatibility with previous versions was two ly:set-option calls. 
And ly:set-option calls are available from the command line: (See the
Usage Manual)
<https://lilypond.org/doc/v2.22/Documentation/usage/command_002dline-usage#advanced-command-line-options-for-lilypond>.

HTH,

Carl



Hi Carl,

thanks a lot, that sounds like really good news.
I'm short in time right now, but I'll check that out and report back here.

Cheers,
Klaus




Re: new behavior of lilypond-book-preamble.ly?

2022-03-30 Thread Carl Sorensen
On Wed, Mar 30, 2022 at 10:09 AM K. Blum  wrote:

>
> Am 30.03.2022 um 17:59 schrieb Carl Sorensen:
>
>
> But when I look at the code in OOoLilyPond/LilyPond.xba
> <https://github.com/OOoLilyPond/OOoLilyPond/blob/master/extension/OOoLilyPond/LilyPond.xba>
> I see that
>
>1. There is a way to check the LilyPond version
>2. The code already modifies include statements to add an appropriate
>path
>3. The code builds the command used to call lilypond
>
> Yes, that's true.
>
> As long as a modification of *how LilyPond is called on the command line*
> is sufficient, there is no problem at all.
> Would that be possible?
>

I don't know.  But the problem identified in the issue is related to adding
a new lilypond option (-dlilypondbookoutput), which I assume lilypond-book
calls but OOoLilyPond does not.  If I were trying to solve this problem,
that's where I would look to start.  I suspect that the new option should
be included when calling lilypond.

But I have no experience with using OOoLilyPond, so I don't know this for
sure.


>
> From what I read in Jean's response and on the GitLab issue page, I get
> the impression that it would be necessary to change the content of the *.ly
> files themselves. Is that correct?
>

I think that is not true.  Han-Wen said that the scheme code needed for
compatibility with previous versions was two ly:set-option calls.  And
ly:set-option calls are available from the command line: (See the Usage
Manual)
<https://lilypond.org/doc/v2.22/Documentation/usage/command_002dline-usage#advanced-command-line-options-for-lilypond>
.

HTH,

Carl


Re: new behavior of lilypond-book-preamble.ly?

2022-03-30 Thread K. Blum


Am 30.03.2022 um 17:59 schrieb Carl Sorensen:


But when I look at the code in OOoLilyPond/LilyPond.xba

I see that

 1. There is a way to check the LilyPond version
 2. The code already modifies include statements to add an appropriate
path
 3. The code builds the command used to call lilypond


Yes, that's true.

As long as a modification of *how LilyPond is called on the command
line* is sufficient, there is no problem at all.
Would that be possible?

From what I read in Jean's response and on the GitLab issue page, I get
the impression that it would be necessary to change the content of the
*.ly files themselves. Is that correct?
This is where I would run into trouble.

Cheers,
Klaus


Re: new behavior of lilypond-book-preamble.ly?

2022-03-30 Thread Carl Sorensen
On Wed, Mar 30, 2022 at 9:25 AM K. Blum  wrote:

>
> Am 30.03.2022 um 17:15 schrieb Carl Sorensen:
>
>
> Is it not possible to make OOoLilyPond check for the LilyPond version and
> respond differently based on the LilyPond version?
>
> No, unfortunatly not:
> The use of lilypond-book-preamble.ly takes place in templates.
> These are dedicated *.ly files that can be modified by the user. Many
> people might build their own from scratch.
> Having OOoLilyPond responding differently would imply that users would
> have to modify all of their templates manually. I hope that there is a way
> to avoid that.
>

But when I look at the code in OOoLilyPond/LilyPond.xba
<https://github.com/OOoLilyPond/OOoLilyPond/blob/master/extension/OOoLilyPond/LilyPond.xba>
I see that

   1. There is a way to check the LilyPond version
   2. The code already modifies include statements to add an appropriate
   path
   3. The code builds the command used to call lilypond

Given these three things it seems that OOoLilyPond can modify its treatment
of both include files and the lilypond command to account for different
versions of LilyPond.  Whether it should have to or not is open for
discussion.

Thanks,

Carl

>
>


Re: new behavior of lilypond-book-preamble.ly?

2022-03-30 Thread K. Blum




Am 30.03.2022 um 17:42 schrieb Jean Abou Samra:



We provide convert-ly to do syntax changes more freely with less pain
for users. Could that not apply here?

Jean


If everything else fails, this could be some kind of last resort. ;-)
But it would still require that users do manual changes to their files
batch-wise.
And OOoLilyPond would have to deliver different templates according to
the user's Ly version. In addition, if a user updates his Ly version
across the 2.23.4 border, the above batch job still would apply.

I will follow your advice and post my thoughts on the GitLab issue page.

Cheers,
Klaus



Re: new behavior of lilypond-book-preamble.ly?

2022-03-30 Thread Jean Abou Samra




Le 30/03/2022 à 17:25, K. Blum a écrit :


Am 30.03.2022 um 17:15 schrieb Carl Sorensen:


Is it not possible to make OOoLilyPond check for the LilyPond version 
and respond differently based on the LilyPond version?



No, unfortunatly not:
The use of lilypond-book-preamble.ly takes place in templates.
These are dedicated *.ly files that can be modified by the user. Many 
people might build their own from scratch.
Having OOoLilyPond responding differently would imply that users would 
have to modify all of their templates manually. I hope that there is a 
way to avoid that.



We provide convert-ly to do syntax changes more freely with less pain 
for users. Could that not apply here?


Jean



Re: new behavior of lilypond-book-preamble.ly?

2022-03-30 Thread K. Blum


Am 30.03.2022 um 17:15 schrieb Carl Sorensen:


Is it not possible to make OOoLilyPond check for the LilyPond version
and respond differently based on the LilyPond version?


No, unfortunatly not:
The use of lilypond-book-preamble.ly takes place in templates.
These are dedicated *.ly files that can be modified by the user. Many
people might build their own from scratch.
Having OOoLilyPond responding differently would imply that users would
have to modify all of their templates manually. I hope that there is a
way to avoid that.

Cheers,
Klaus


Re: new behavior of lilypond-book-preamble.ly?

2022-03-30 Thread Carl Sorensen
On Wed, Mar 30, 2022 at 8:41 AM K. Blum  wrote:

>
> Am 30.03.2022 um 00:53 schrieb Jean Abou Samra:
> >
> > This is
> >
> > https://gitlab.com/lilypond/lilypond/-/issues/6235
> >
> > You can get cropping with -dcrop in the command line or
> > #(ly:set-option 'crop) in your .ly file, but it is different in that
> > it generates a separate .cropped.xxx file in addition to a non-cropped
> > main .xxx file (with xxx = pdf most of the time).
> >
> > Jean
> >
> Merci, Jean.
>
> May I hope that someday we will get back the original behavior?
> I'm asking because the OOoLilyPond extension for LibreOffice and
> OpenOffice heavily relies on lilypond-book-preamble.ly (and has done
> that ever since).
> For the sake of backward compatibility, it is absolutely desirable to
> continue in the same way. Changing the workflow inside OOoLilyPond could
> make it unusable for LilyPond versions prior to 2.23.5.
> See https://github.com/OOoLilyPond


Is it not possible to make OOoLilyPond check for the LilyPond version and
respond differently based on the LilyPond version?

Forcing strict backwards compatibility can prevent necessary improvements
in software.  LilyPond is currently wrestling with this issue in Guile.  We
would love to have Guile 2 (and 3) work just like 1.8, but that's not the
case, so we need to adjust LilyPond.

Perhaps the same is true of OOoLilyPond.  I don't know if that's the case
or not, but that discussion should be entered into, IMO, with people from
both development communities.

THanks,

Carl


Re: new behavior of lilypond-book-preamble.ly?

2022-03-30 Thread Jean Abou Samra

Le 30/03/2022 à 16:40, K. Blum a écrit :


Am 30.03.2022 um 00:53 schrieb Jean Abou Samra:


This is

https://gitlab.com/lilypond/lilypond/-/issues/6235

You can get cropping with -dcrop in the command line or
#(ly:set-option 'crop) in your .ly file, but it is different in that
it generates a separate .cropped.xxx file in addition to a non-cropped
main .xxx file (with xxx = pdf most of the time).

Jean


Merci, Jean.

May I hope that someday we will get back the original behavior?
I'm asking because the OOoLilyPond extension for LibreOffice and
OpenOffice heavily relies on lilypond-book-preamble.ly (and has done
that ever since).
For the sake of backward compatibility, it is absolutely desirable to
continue in the same way. Changing the workflow inside OOoLilyPond could
make it unusable for LilyPond versions prior to 2.23.5.
See https://github.com/OOoLilyPond




At this point I'm not sure it will stay the same, but I did
already request in the issue that we got back *some way*
to obtain the same.

Feel free to add your comments on the issue.

Thanks,
Jean




Re: new behavior of lilypond-book-preamble.ly?

2022-03-30 Thread K. Blum



Am 30.03.2022 um 00:53 schrieb Jean Abou Samra:


This is

https://gitlab.com/lilypond/lilypond/-/issues/6235

You can get cropping with -dcrop in the command line or
#(ly:set-option 'crop) in your .ly file, but it is different in that
it generates a separate .cropped.xxx file in addition to a non-cropped
main .xxx file (with xxx = pdf most of the time).

Jean


Merci, Jean.

May I hope that someday we will get back the original behavior?
I'm asking because the OOoLilyPond extension for LibreOffice and
OpenOffice heavily relies on lilypond-book-preamble.ly (and has done
that ever since).
For the sake of backward compatibility, it is absolutely desirable to
continue in the same way. Changing the workflow inside OOoLilyPond could
make it unusable for LilyPond versions prior to 2.23.5.
See https://github.com/OOoLilyPond

Cheers,
Klaus



Re: new behavior of lilypond-book-preamble.ly?

2022-03-29 Thread Jean Abou Samra




Le 29/03/2022 à 19:41, K. Blum a écrit :

Dear LilyPond community,

up to Ly 2.23.4, the use of
    \include "lilypond-book-preamble.ly"
removed any whitespace around the score.

As of Ly 2.23.5, the music is moved to the upper left corner, but the
paper size remains unchanged.

Is this a new (intended) behavior? Or have I just been missing something
important?
What do I need to do to get an entirely cropped image again? Thanks for
any hint.



This is

https://gitlab.com/lilypond/lilypond/-/issues/6235

You can get cropping with -dcrop in the command line or #(ly:set-option 
'crop) in your .ly file, but it is different in that it generates a 
separate .cropped.xxx file in addition to a non-cropped main .xxx file 
(with xxx = pdf most of the time).


Jean




new behavior of lilypond-book-preamble.ly?

2022-03-29 Thread K. Blum

Dear LilyPond community,

up to Ly 2.23.4, the use of
    \include "lilypond-book-preamble.ly"
removed any whitespace around the score.

As of Ly 2.23.5, the music is moved to the upper left corner, but the
paper size remains unchanged.

Is this a new (intended) behavior? Or have I just been missing something
important?
What do I need to do to get an entirely cropped image again? Thanks for
any hint.

Cheers,
Klaus

P.S.: Here is my MWE to test and demonstrate:
% --
\include "lilypond-book-preamble.ly"
% \paper {indent = 0}
{c'}
% --



Re: Lilypond-book

2022-03-21 Thread Jonas Hahnfeld via LilyPond user discussion
Am Sonntag, dem 20.03.2022 um 21:33 +0100 schrieb Jean Abou Samra:
> Le 20/03/2022 à 20:34, Martín Rincón Botero a écrit :
> > Hi Jean,
> > 
> > I'm on Ubuntu 20.04. It seems the printing code that we added to 
> > book_latex.py is returning an empty string. Here's the new logging 
> > output of lilypond-book:
> > 
> > lilypond-book (GNU LilyPond) 2.22.1
> > Reading `/home/martin/Escritorio/newfile1.tex'
> > Running `pdflatex' on file `/tmp/tmp0i00kf9b.tex' to detect default 
> > page settings.
> > 
> > lilypond-book: warning: Unable to auto-detect default settings:
> > pdflatex: /home/martin/lilypond/usr/lib/libstdc++.so.6: version 
> > `CXXABI_1.3.9' not found (required by pdflatex)
> > pdflatex: /home/martin/lilypond/usr/lib/libz.so.1: no version 
> > information available (required by /lib/x86_64-linux-gnu/libpng16.so.16)
> > pdflatex: /home/martin/lilypond/usr/lib/libz.so.1: no version 
> > information available (required by /lib/x86_64-linux-gnu/libpng16.so.16)
> 
> 
> 
> Aaah, *that* is the interesting piece of information from the
> start. But -- OMG, I can reproduce it on my own installation.
> I hadn't even imaged it would be broken for me. Is lilypond-book
> actually working for anyone on Linux??

To be fair, only the official binaries and only since the libraries
require version information (not sure when that is). It could be that
many lilypond-book users actually rely on the distro-provided LilyPond.
Also it should only affect PDF-related formats, so for example not
HTML, and I don't understand what the actual implication is (probably
because I don't use lilypond-book myself.)

> At any rate, it seems like it's an issue with the way the
> lilypond-book shell wrapper created by GUB sets LD_LIBRARY_PATH.
> I have no time to investigate what it should do, but the problem
> should go away by installing LilyPond 2.23.6 from
> https://gitlab.com/lilypond/lilypond/-/releases/release%252F2.23.6-1
> since the new infrastructure creating binaries no longer
> does that. For me, that works.

Yes, this is one of the problems about LD_LIBRARY_PATH and why we will
go for full static builds.


signature.asc
Description: This is a digitally signed message part


Re: Lilypond-book

2022-03-20 Thread Martín Rincón Botero
Dear Jean,

thank you very much for your time and patience! If that's the only solution, 
I'll try installing the/this last "unstable" version in the near future.
Regards,
Martín.

On mar. 20 2022, at 9:33 pm, Jean Abou Samra  wrote:
> Le 20/03/2022 à 20:34, Martín Rincón Botero a écrit :
> > Hi Jean,
> >
> > I'm on Ubuntu 20.04. It seems the printing code that we added to
> > book_latex.py is returning an empty string. Here's the new logging
> > output of lilypond-book:
> >
> > lilypond-book (GNU LilyPond) 2.22.1
> > Reading `/home/martin/Escritorio/newfile1.tex'
> > Running `pdflatex' on file `/tmp/tmp0i00kf9b.tex' to detect default
> > page settings.
> >
> > lilypond-book: warning: Unable to auto-detect default settings:
> > pdflatex: /home/martin/lilypond/usr/lib/libstdc++.so.6: version
> > `CXXABI_1.3.9' not found (required by pdflatex)
> > pdflatex: /home/martin/lilypond/usr/lib/libz.so.1: no version
> > information available (required by /lib/x86_64-linux-gnu/libpng16.so.16)
> > pdflatex: /home/martin/lilypond/usr/lib/libz.so.1: no version
> > information available (required by /lib/x86_64-linux-gnu/libpng16.so.16)
>
>
>
> Aaah, *that* is the interesting piece of information from the
> start. But -- OMG, I can reproduce it on my own installation.
> I hadn't even imaged it would be broken for me. Is lilypond-book
> actually working for anyone on Linux??
>
> At any rate, it seems like it's an issue with the way the
> lilypond-book shell wrapper created by GUB sets LD_LIBRARY_PATH.
> I have no time to investigate what it should do, but the problem
> should go away by installing LilyPond 2.23.6 from
> https://gitlab.com/lilypond/lilypond/-/releases/release%252F2.23.6-1
> since the new infrastructure creating binaries no longer
> does that. For me, that works.
>
> Jean

Re: Lilypond-book

2022-03-20 Thread Jean Abou Samra

Le 20/03/2022 à 20:34, Martín Rincón Botero a écrit :

Hi Jean,

I'm on Ubuntu 20.04. It seems the printing code that we added to 
book_latex.py is returning an empty string. Here's the new logging 
output of lilypond-book:


lilypond-book (GNU LilyPond) 2.22.1
Reading `/home/martin/Escritorio/newfile1.tex'
Running `pdflatex' on file `/tmp/tmp0i00kf9b.tex' to detect default 
page settings.


lilypond-book: warning: Unable to auto-detect default settings:
pdflatex: /home/martin/lilypond/usr/lib/libstdc++.so.6: version 
`CXXABI_1.3.9' not found (required by pdflatex)
pdflatex: /home/martin/lilypond/usr/lib/libz.so.1: no version 
information available (required by /lib/x86_64-linux-gnu/libpng16.so.16)
pdflatex: /home/martin/lilypond/usr/lib/libz.so.1: no version 
information available (required by /lib/x86_64-linux-gnu/libpng16.so.16)




Aaah, *that* is the interesting piece of information from the
start. But -- OMG, I can reproduce it on my own installation.
I hadn't even imaged it would be broken for me. Is lilypond-book
actually working for anyone on Linux??

At any rate, it seems like it's an issue with the way the
lilypond-book shell wrapper created by GUB sets LD_LIBRARY_PATH.
I have no time to investigate what it should do, but the problem
should go away by installing LilyPond 2.23.6 from
https://gitlab.com/lilypond/lilypond/-/releases/release%252F2.23.6-1
since the new infrastructure creating binaries no longer
does that. For me, that works.

Jean




Re: Lilypond-book

2022-03-20 Thread Martín Rincón Botero
Hi Jean,

I'm on Ubuntu 20.04. It seems the printing code that we added to book_latex.py 
is returning an empty string. Here's the new logging output of lilypond-book:
lilypond-book (GNU LilyPond) 2.22.1
Reading `/home/martin/Escritorio/newfile1.tex'
Running `pdflatex' on file `/tmp/tmp0i00kf9b.tex' to detect default page 
settings.

lilypond-book: warning: Unable to auto-detect default settings:
pdflatex: /home/martin/lilypond/usr/lib/libstdc++.so.6: version `CXXABI_1.3.9' 
not found (required by pdflatex)
pdflatex: /home/martin/lilypond/usr/lib/libz.so.1: no version information 
available (required by /lib/x86_64-linux-gnu/libpng16.so.16)
pdflatex: /home/martin/lilypond/usr/lib/libz.so.1: no version information 
available (required by /lib/x86_64-linux-gnu/libpng16.so.16)

lilypond-book: warning: cannot detect textwidth from LaTeX
Dissecting...
All snippets are up to date...
Linking files...
Compiling `newfile1.tex'...
Writing `/home/martin/Escritorio/out/newfile1.tex'...
''

On mar. 20 2022, at 8:18 pm, Jean Abou Samra  wrote:
> Le 20/03/2022 à 19:49, Martín Rincón Botero a écrit :
> > Hi Jean,
> >
> > thank you very much for wanting to take a look at it. Attached is the
> > .log file.
>
>
> Pheew. It looks correct, so something is wrong in the way lilypond-book
> gets it from the system. OK, can you locate the file book_latex.py in
> your LilyPond installation and apply the following diff?
>
>
> diff --git a/python/book_latex.py b/python/book_latex.py
> index ab8b2c7d3e..1c0f7bff50 100644
> --- a/python/book_latex.py
> +++ b/python/book_latex.py
> @@ -256,7 +256,9 @@ def get_latex_textwidth(source, global_options):
> os.unlink(tmpfile)
> if os.path.exists(auxfile):
> os.unlink(auxfile)
> + print(repr(parameter_string))
> if os.path.exists(logfile):
> + print(repr(parameter_string))
> parameter_string = open(logfile, encoding="utf8").read()
> os.unlink(logfile)
>
>
> Then re-run and paste the lilypond-book logging output. Also, what OS
> are you running? Is it Windows?
>



Re: Lilypond-book

2022-03-20 Thread Jean Abou Samra

Le 20/03/2022 à 19:49, Martín Rincón Botero a écrit :

Hi Jean,

thank you very much for wanting to take a look at it. Attached is the 
.log file.



Pheew. It looks correct, so something is wrong in the way lilypond-book 
gets it from the system. OK, can you locate the file book_latex.py in 
your LilyPond installation and apply the following diff?



diff --git a/python/book_latex.py b/python/book_latex.py
index ab8b2c7d3e..1c0f7bff50 100644
--- a/python/book_latex.py
+++ b/python/book_latex.py
@@ -256,7 +256,9 @@ def get_latex_textwidth(source, global_options):
 os.unlink(tmpfile)
 if os.path.exists(auxfile):
 os.unlink(auxfile)
+    print(repr(parameter_string))
 if os.path.exists(logfile):
+    print(repr(parameter_string))
 parameter_string = open(logfile, encoding="utf8").read()
 os.unlink(logfile)


Then re-run and paste the lilypond-book logging output. Also, what OS 
are you running? Is it Windows?





Re: Lilypond-book

2022-03-20 Thread Martín Rincón Botero
Hi Jean,

thank you very much for wanting to take a look at it. Attached is the .log file.
Regards,
Martín.

On mar. 16 2022, at 8:42 pm, Jean Abou Samra  wrote:
>
>
> Le 16/03/2022 à 11:18, Martín Rincón Botero a écrit :
> > Dear community,
> >
> > so that I have any idea on where to look and maybe give more useful
> > information, I got this warning (that should be an error, because the
> > pdf output is useless) when using lilypond-book after upgrading to
> > Lilypond 2.22.1 (it used to work perfectly before) on Ubuntu
> > 20.04: lilypond-book: warning: cannot detect textwidth from LaTeX.
> > After googling I've seen some people who run into this problem when
> > using Xetex, but I'm using PdfLatex, so their solutions obviously
> > don't work in my case. What could be causing this problem?
>
>
>
> Can you compile a file made of your LaTeX preamble to which you append
> \begin{document}
> \typeout{textwidth=\the\textwidth}
> \typeout{columnsep=\the\columnsep}
> \makeatletter\if@twocolumn\typeout{columns=2}\fi\makeatother
> \end{document}
>
>
> and attach the .log file?
> Jean

newfile1.log
Description: Binary data


Re: Lilypond-book

2022-03-16 Thread Jean Abou Samra




Le 16/03/2022 à 11:18, Martín Rincón Botero a écrit :

Dear community,

so that I have any idea on where to look and maybe give more useful 
information, I got this warning (that should be an error, because the 
pdf output is useless) when using lilypond-book after upgrading to 
Lilypond 2.22.1 (it used to work perfectly before) on Ubuntu 
20.04: lilypond-book: warning: cannot detect textwidth from LaTeX. 
After googling I've seen some people who run into this problem when 
using Xetex, but I'm using PdfLatex, so their solutions obviously 
don't work in my case. What could be causing this problem?




Can you compile a file made of your LaTeX preamble to which you append

\begin{document}
\typeout{textwidth=\the\textwidth}
\typeout{columnsep=\the\columnsep}
\makeatletter\if@twocolumn\typeout{columns=2}\fi\makeatother
\end{document}


and attach the .log file?

Jean




Lilypond-book

2022-03-16 Thread Martín Rincón Botero
Dear community,

so that I have any idea on where to look and maybe give more useful 
information, I got this warning (that should be an error, because the pdf 
output is useless) when using lilypond-book after upgrading to Lilypond 2.22.1 
(it used to work perfectly before) on Ubuntu 20.04: lilypond-book: warning: 
cannot detect textwidth from LaTeX. After googling I've seen some people who 
run into this problem when using Xetex, but I'm using PdfLatex, so their 
solutions obviously don't work in my case. What could be causing this problem?
Regards,
Martín.


Re: lilypond book

2021-09-21 Thread Carlos Martinez
Woah! I think this is above my head!

I would be perhaps interested in learning laTex but I do have questions, 

Does it disrupts the layout on the lilypond files?

There has to be an easy way to use the book function. I cannot find a sample I 
saw and would like to use to add the 13 pieces under one file easier on 
lilypond. Perhaps is easier in Latex I don’t know. I would have to try …

> On Sep 21, 2021, at 17:33, Karlin High  wrote:
> 
> On 9/21/2021 5:17 PM, Richard Chonak wrote:
>> If you're familiar with LaTeX, you can create a document that invokes 
>> Lilypond scores:
> 
> In that case, there is also lyluatex:
> 
> 
> -- 
> Karlin High
> Missouri, USA
> 




Re: lilypond book

2021-09-21 Thread Karlin High

On 9/21/2021 5:17 PM, Richard Chonak wrote:
If you're familiar with LaTeX, you can create a document that invokes 
Lilypond scores:


In that case, there is also lyluatex:


--
Karlin High
Missouri, USA



Re: lilypond book

2021-09-21 Thread Richard Chonak
If you're familiar with LaTeX, you can create a document that invokes 
Lilypond scores:


main.lytex:

\documentclass[12pt]{book}
\usepackage[paperheight=10in,paperwidth=7in,margin=0.5in,twoside]{geometry} 


\usepackage[latin,main=english]{babel}
\usepackage{fontspec}
\usepackage{fancyhdr}
\pagestyle{empty}

\lilypondfile[noindent,staffsize=18,line-width=6\in]{Score1.ly}
\newpage
\lilypondfile[noindent,staffsize=18,line-width=6\in]{Score2.ly}



and process it with the command:

lilypond-book main.lytex




Re: lilypond book

2021-09-21 Thread Carlos Martinez
Hi, this could work! I will try it. But what I would like to do is to use the 
same independent file of the pieces, 

So for example the include piece1.ly 


Then I can just update one file…

And then include the piece1.ly  and piece2.ly 
 into the book..?




> On Sep 21, 2021, at 16:27, Knute Snortum  wrote:
> 
> On Tue, Sep 21, 2021 at 11:13 AM Carlos Martinez
>  wrote:
>> 
>> Hi,
>> 
>> I am trying to put together a book. A collection  of 13 pieces with lilypond.
> ...
>> I want each piece to show its own
>> 
>> - Title and composer
>> - each piece start in its own page.
>> 
>> I am trying to setting it up but I cannot do it!
>> 
>> I have already engraved each piece… and would love to have the include. But 
>> somehow it is not working..
> ...
> 
> If I understand your question, would this work?  I don't know what's
> in your includes, so I can't help you there.
> 
> %%%
> \version "2.20.0"
> 
> music = { c'4 4 4 4 }
> 
> \bookpart {
>  \header {
>title = "Title 1"
>composer = "Composer 1"
>  }
>  \score {
>\new Staff \music
>  }
> }
> 
> \bookpart {
>  \header {
>title = "Title 2"
>composer = "Composer 2"
>  }
>  \score {
>\new Staff \music
>  }
> }
> %%%
> 
> --
> Knute Snortum
> 



Re: lilypond book

2021-09-21 Thread Knute Snortum
On Tue, Sep 21, 2021 at 11:13 AM Carlos Martinez
 wrote:
>
> Hi,
>
> I am trying to put together a book. A collection  of 13 pieces with lilypond.
...
> I want each piece to show its own
>
> - Title and composer
> - each piece start in its own page.
>
> I am trying to setting it up but I cannot do it!
>
> I have already engraved each piece… and would love to have the include. But 
> somehow it is not working..
...

If I understand your question, would this work?  I don't know what's
in your includes, so I can't help you there.

%%%
\version "2.20.0"

music = { c'4 4 4 4 }

\bookpart {
  \header {
title = "Title 1"
composer = "Composer 1"
  }
  \score {
\new Staff \music
  }
}

\bookpart {
  \header {
title = "Title 2"
composer = "Composer 2"
  }
  \score {
\new Staff \music
  }
}
%%%

--
Knute Snortum



lilypond book

2021-09-21 Thread Carlos Martinez
Hi, 

I am trying to put together a book. A collection  of 13 pieces with lilypond. 

I would like the book to be setup in this way 

#(set-global-staff-size 20)

\version "2.20.0"

\paper {
  
  #(set-paper-size "letter")
  top-margin = .50\in
   right-margin = .50\in
   left-margin = .50\in
   bottom-margin =  .50\in
 
   \include "../footer001.ily"
  evenFooterMarkup = \oddFooterMarkup  
  
}




I want each piece to show its own 

- Title and composer
- each piece start in its own page. 

I am trying to setting it up but I cannot do it!

I have already engraved each piece… and would love to have the include. But 
somehow it is not working..

Thanks!

For the 

\bookpart {

  \header { maintainer = "Carlos R Martinez" }
  
  \header {
  
  
  title = ##f
composer = ##f
  }

  \markup { \fill-line { \center-column 
 
 {
   
\null \null \null \null
\null \null 
   
   


\epsfile #X #20 #"./emologo.eps"

\null \null \null \null \null \null
\line {\abs-fontsize #20 "Essential Music  "}
\null\null\null
\line {\abs-fontsize #36 \bold "Piano Foundations"}
\null\null\null
\line {\abs-fontsize #20 "Vol. I"}
\null\null\null\null

\fill-line { \abs-fontsize #20 "" }


\fill-line { \abs-fontsize #14 " "}
\null
\fill-line { \abs-fontsize #14 "by"}
\null
\fill-line { \abs-fontsize #14 "Carlos R Martinez"}
} } }
}


success with lilypond-book

2021-08-07 Thread Archer Endrich

To David, Knute and Carl,

I am happy to report success with running lilypond-book on Windows 10.  
For users' info, these are the steps I took, as guided by David, Knute 
and Carl.  It is hard to tell at this point whether it would have worked 
if one or the other of these steps had been omitted.


a) downloaded and installed Python version 3.9 (although 3.6 seemed to 
be on the system already)
b) downloaded and installed MiKTeX  (i.e., pdflatex now on my Windows 10 
computer)
c) rearranged the LilyPond files to be inside a folder named LilyPond;  
thus the file arrangement became: C:\Lilypond2221\LilyPond\user\bin;  
then edited the system path accordingly.  My full system path now looks 
like this:


C:\P3L\lpbk>path
PATH=C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Windows\System32\OpenSSH\;C:\Lilypond2221\LilyPond\usr\bin;C:\cdpr71ae\_cdp\_cdprogs;C:\Users\Archer\AppData\Local\Microsoft\WindowsApps;C:\MiKTeX\miktex\bin\x64\

d) associated Python with lilypond-book.py - The link Knute sent about 
this was very helpful: 
https://www.digitaltrends.com/computing/how-to-change-file-associations/



I first ran lilypond-book manually direct from the command line like this:
>python C:\Lilypond2221\LilyPond\user\bin\lilypond-book.py --output=out 
-- pdf ALMdurasnumber.lytex

[msg:  compiling ALMdurasnumber.lytex ... writing ALMdurasnumber.tex]
>cd out
>pdflatex ALMdurasnumber.tex
[msg:  output written on ALMdurasnumber.pdf]

I then tried running from a batch file in various ways:
Trial 1:
C:\Lilypond2221\LilyPond\user\bin\lilypond-book.py --output=out -- pdf 
ALMdurasnumber.lytex

cd out
pdflatex ALMdurasnumber.tex
cd ..\
This was successful.

Trial 2: the same, but without the .py extension on lilypond-book
This was successful.

Trial 3: the same, but without the explicit path to lilypond-book
This was also successful.

So I'm up and running with lilypond-book (with my batchfile as I had 
been writing it on Windows 7) thanks to all the various help/clues that 
were contributed.  The final batch file is:


C:\lilypond-book --output=out --pdf ALMdurasnumber.lytex
cd out
pdflatex ALMdurasnumber.tex
cd ..\


I hope this information helps others who might find themselves in a 
situation similar to mine.


Huge thanks!
Archer




Re: run error Lilypond-book on Windows 10

2021-08-06 Thread Archer Endrich

Dear David, Carl and Knute,

Thank you for all your replies and information.  I'll work on the 
file-association suggestion tomorrow and let you know if the problem is 
solved.


Thanks again,

Archer





Re: run error Lilypond-book on Windows 10

2021-08-06 Thread David Wright
On Fri 06 Aug 2021 at 18:55:13 (+0100), Archer Endrich wrote:
> 
> However, there was an earlier version in my 2.18.2 Lilypond, so I
> renamed that to disable it and added a full path to my 2.22.1
> lilypond-book in my batch file.
> 
[ … ]
> 
> When I run the batch files, Windows keeps asking me "How do you want
> to open this py file?" but does not give be a Browse option. Notice
> the "access is denied" message in the command line display after
> running.  (I haven't actually been able to specify that I want
> LilyPond to run it.
> 
[ … ]
> 
> C:\P3L\lpbk>C:\Lilypond2221\usr\bin\lilypond-book --output=out --pdf
> ALMdurasnumber.lytex
> Access is denied.

That might well be a consequence of your action above, which would
support the notion of picking up an old python2 version. (Linux's
2.18.2 from the LP website appears to use 2.4.5, whereas Debian
buster's system version is 2.7.16).

> Maybe David Wright's suggestion was correct, namely that "Something
> looks odd about C:\Lilypond2221\usr\bin\lilypond-book.py
> in that I would expect either C:\Lilypond2221\bin\lilypond-book
> or C:\Lilypond2221\LILYPOND\usr\bin\lilypond-book where LILYPOND
> is either lowercase or camelcase (I have seen both). "
> 
> Perhaps lilypond-book needs that path -- but my normal LilyPond
> notation works OK with my 'odd' path.

Bear in mind I don't know what the top of the LP installation
directory structure looks like on windows, only on linux.
I have no way of checking, either, because the windows download
(I assume it's "mingw") is a inscrutable exe file, as opposed to
a shell script followed by a standard compressed tar archive.

All I can say is that if you're running lilypond-book, juggling
calls to LP, Python and TeX, it's probably important to get all
the PATHs and file associations sorted out. You may need the
help of someone who runs a more similar system.

Cheers,
David.



Re: run error Lilypond-book on Windows 10

2021-08-06 Thread Knute Snortum
On Fri, Aug 6, 2021 at 10:55 AM Archer Endrich  wrote:

> When I run the batch files, Windows keeps asking me "How do you want to
> open this py file?" but does not give be a Browse option. Notice the
> "access is denied" message in the command line display after running.
> (I haven't actually been able to specify that I want LilyPond to run it.

You need to associate an application with the py file type. There are
lots of web pages that will show you how to do that.  Here's one:

https://www.digitaltrends.com/computing/how-to-change-file-associations/

--
Knute Snortum



Re: run error Lilypond-book on Windows 10

2021-08-06 Thread Archer Endrich

On 06/08/2021 18:32, Knute Snortum wrote:

On Fri, Aug 6, 2021 at 9:35 AM Carl Sorensen  wrote:

You might check the following:

Is there a python.exe that is somewhere in the path ahead of Lilypond's python?

This can be checked using the Windows "where" command:

C:\> where python

--
Knute Snortum



Thanks.  I did this:
C:\>where python
C:\Lilypond2221\usr\bin\python.exe
C:\Users\Archer\AppData\Local\Microsoft\WindowsApps\python.exe
(I ran this this Python from the command line and it said it was version 
3.6)


I also downloaded and installed Python3.9.  This time when I ran my 
batch file, Windows asked if I wanted to open the .ly file with 
Python3.9.  I said OK.  I wonder if it tried to run Python directly.  
Anyway, something happened, and then I was back to:


C:\P3L\lpbk>C:\Lilypond2221\usr\bin\lilypond-book --output=out --pdf 
ALMdurasnumber.lytex


C:\P3L\lpbk>cd out

C:\P3L\lpbk\out>pdflatex ALMdurasnumber.tex
This is pdfTeX, Version 3.141592653-2.6-1.40.23 (MiKTeX 21.7)
entering extended mode
! I can't find file `ALMdurasnumber.tex'.
<*> ALMdurasnumber.tex

Please type another input file name:
! Emergency stop.
<*> ALMdurasnumber.tex

!  ==> Fatal error occurred, no output PDF file produced!
Transcript written on texput.log.
Terminate batch job (Y/N)? y

with no complaint about "can't access".  Maybe my OK re opening with 
Python was incorrect.


Still struggling, but very grateful for your help.
Archer




Re: run error Lilypond-book on Windows 10

2021-08-06 Thread Archer Endrich

Hello Carl,

That was a good idea.  When I enter 'python' on the top level of my C:\ 
drive, it says that the version is 3.7.4.


However, there was an earlier version in my 2.18.2 Lilypond, so I 
renamed that to disable it and added a full path to my 2.22.1 
lilypond-book in my batch file.


I can't find any other PYTHON on my system (e.g., in Program Files).  I 
haven't reinstalled any other Python since moving to Windows 10, which 
involved a completely new hard drive.


The error message about line 376 no longer appears, but the .tex file is 
not created, so pdflatex has nothing to work on.


When I run the batch files, Windows keeps asking me "How do you want to 
open this py file?" but does not give be a Browse option. Notice the 
"access is denied" message in the command line display after running.  
(I haven't actually been able to specify that I want LilyPond to run it.


This is the display:

C:\P3L\lpbk>ALMdurasnumber.bat

C:\P3L\lpbk>C:\Lilypond2221\usr\bin\lilypond-book --output=out --pdf 
ALMdurasnumber.lytex

Access is denied.

C:\P3L\lpbk>cd out

C:\P3L\lpbk\out>pdflatex ALMdurasnumber.tex
This is pdfTeX, Version 3.141592653-2.6-1.40.23 (MiKTeX 21.7)
entering extended mode
! I can't find file `ALMdurasnumber.tex'.
<*> ALMdurasnumber.tex

Please type another input file name:
! Emergency stop.
<*> ALMdurasnumber.tex

!  ==> Fatal error occurred, no output PDF file produced!
Transcript written on texput.log.
Terminate batch job (Y/N)? y

C:\P3L\lpbk\out>cd ..

Maybe David Wright's suggestion was correct, namely that "Something 
looks odd about C:\Lilypond2221\usr\bin\lilypond-book.py

in that I would expect either C:\Lilypond2221\bin\lilypond-book
or C:\Lilypond2221\LILYPOND\usr\bin\lilypond-book where LILYPOND
is either lowercase or camelcase (I have seen both). "

Perhaps lilypond-book needs that path -- but my normal LilyPond notation 
works OK with my 'odd' path.


So I'm still puzzled.
Archer

On 06/08/2021 17:34, Carl Sorensen wrote:

You might check the following:

Is there a python.exe that is somewhere in the path ahead of Lilypond's python?

What is your system python version?

The method you used to run lilypond-book does not include an explicit call to 
the lilypond's python; IIUC you're just using the .py extension to allow 
Windows to choose the application for that extenstion, and it may be another 
python somewhere in your system.

HTH,

Carl


On 8/6/21, 10:22 AM, "lilypond-user on behalf of Archer Endrich" 
 wrote:

 Hello Aaron,
 
 Thank you for your reply.  I've checked the version of python.exe in my

 Lilyond usr\bin and it's 3.7.4, so it is puzzling that it is flagging an
 error about something not valid prior to 2.6.  I can't think where to go
 from here.
 
 Thanks.

 Archer
 P.S. I hope I've replied properly to yourself and to the user-group.
 
 On 06/08/2021 16:55, Aaron Hill wrote:

 > On 2021-08-06 8:46 am, Archer Endrich wrote:
 >> [ . . . ]
 >> C:\P3L\lpbk>lilypond-book --output=out --pdf ALMdurasnumber.lytex
 >>   File "C:\Lilypond2221\usr\bin\lilypond-book.py", line 376
 >> except subprocess.CalledProcessError as e:
 >>   ^
 >> SyntaxError: invalid syntax
 >> [ . . . ]
 >> Perhaps someone could check out line 376 for me.  Thanks again.
 >
 > The error message clearly indicates this is invalid syntax for the
 > version of Python you are running.  In particular, "as" is not valid
 > prior to 2.6 according to [1].
 >
 > [1]:
 > 
https://stackoverflow.com/questions/2535760/python-try-except-comma-vs-as-in-except#2535770
 >
 >
 > -- Aaron Hill
 
 





Re: run error Lilypond-book on Windows 10

2021-08-06 Thread Knute Snortum
On Fri, Aug 6, 2021 at 9:35 AM Carl Sorensen  wrote:
>
> You might check the following:
>
> Is there a python.exe that is somewhere in the path ahead of Lilypond's 
> python?

This can be checked using the Windows "where" command:

C:\> where python

--
Knute Snortum



Re: run error Lilypond-book on Windows 10

2021-08-06 Thread Carl Sorensen
You might check the following:

Is there a python.exe that is somewhere in the path ahead of Lilypond's python?

What is your system python version?

The method you used to run lilypond-book does not include an explicit call to 
the lilypond's python; IIUC you're just using the .py extension to allow 
Windows to choose the application for that extenstion, and it may be another 
python somewhere in your system.

HTH,

Carl


On 8/6/21, 10:22 AM, "lilypond-user on behalf of Archer Endrich" 
 wrote:

Hello Aaron,

Thank you for your reply.  I've checked the version of python.exe in my 
Lilyond usr\bin and it's 3.7.4, so it is puzzling that it is flagging an 
error about something not valid prior to 2.6.  I can't think where to go 
from here.

Thanks.
Archer
P.S. I hope I've replied properly to yourself and to the user-group.

On 06/08/2021 16:55, Aaron Hill wrote:
> On 2021-08-06 8:46 am, Archer Endrich wrote:
>> [ . . . ]
>> C:\P3L\lpbk>lilypond-book --output=out --pdf ALMdurasnumber.lytex
>>   File "C:\Lilypond2221\usr\bin\lilypond-book.py", line 376
>> except subprocess.CalledProcessError as e:
>>   ^
>> SyntaxError: invalid syntax
>> [ . . . ]
>> Perhaps someone could check out line 376 for me.  Thanks again.
>
> The error message clearly indicates this is invalid syntax for the 
> version of Python you are running.  In particular, "as" is not valid 
> prior to 2.6 according to [1].
>
> [1]: 
> 
https://stackoverflow.com/questions/2535760/python-try-except-comma-vs-as-in-except#2535770
>
>
> -- Aaron Hill





Re: run error Lilypond-book on Windows 10

2021-08-06 Thread Archer Endrich

Hello Aaron,

Thank you for your reply.  I've checked the version of python.exe in my 
Lilyond usr\bin and it's 3.7.4, so it is puzzling that it is flagging an 
error about something not valid prior to 2.6.  I can't think where to go 
from here.


Thanks.
Archer
P.S. I hope I've replied properly to yourself and to the user-group.

On 06/08/2021 16:55, Aaron Hill wrote:

On 2021-08-06 8:46 am, Archer Endrich wrote:

[ . . . ]
C:\P3L\lpbk>lilypond-book --output=out --pdf ALMdurasnumber.lytex
  File "C:\Lilypond2221\usr\bin\lilypond-book.py", line 376
    except subprocess.CalledProcessError as e:
  ^
SyntaxError: invalid syntax
[ . . . ]
Perhaps someone could check out line 376 for me.  Thanks again.


The error message clearly indicates this is invalid syntax for the 
version of Python you are running.  In particular, "as" is not valid 
prior to 2.6 according to [1].


[1]: 
https://stackoverflow.com/questions/2535760/python-try-except-comma-vs-as-in-except#2535770



-- Aaron Hill




Re: run error Lilypond-book on Windows 10

2021-08-06 Thread Aaron Hill

On 2021-08-06 8:46 am, Archer Endrich wrote:

[ . . . ]
C:\P3L\lpbk>lilypond-book --output=out --pdf ALMdurasnumber.lytex
  File "C:\Lilypond2221\usr\bin\lilypond-book.py", line 376
    except subprocess.CalledProcessError as e:
  ^
SyntaxError: invalid syntax
[ . . . ]
Perhaps someone could check out line 376 for me.  Thanks again.


The error message clearly indicates this is invalid syntax for the 
version of Python you are running.  In particular, "as" is not valid 
prior to 2.6 according to [1].


[1]: 
https://stackoverflow.com/questions/2535760/python-try-except-comma-vs-as-in-except#2535770



-- Aaron Hill



Re: run error Lilypond-book on Windows 10

2021-08-06 Thread Archer Endrich
Thank you Knute and David!  I have downloaded and installed MiKTeX and 
rerun my batch file (without the .py added to lilypond-book).


It appears to have called lilypond-book successfully and also pdflatex.  
However, it still reports an error in lilypond-book.ly which is 
preventing compilation.


Here is the output:

C:\P3L\lpbk>ALMdurasnumber.bat

C:\P3L\lpbk>lilypond-book --output=out --pdf ALMdurasnumber.lytex
  File "C:\Lilypond2221\usr\bin\lilypond-book.py", line 376
    except subprocess.CalledProcessError as e:
  ^
SyntaxError: invalid syntax

C:\P3L\lpbk>cd out

C:\P3L\lpbk\out>pdflatex ALMdurasnumber.tex
This is pdfTeX, Version 3.141592653-2.6-1.40.22 (MiKTeX 21.6)
entering extended mode
! I can't find file `ALMdurasnumber.tex'.
<*> ALMdurasnumber.tex

Please type another input file name:

So it all seems to be working except for the reported error.

Regarding paths, I had renamed my lilypond directory with a version 
number, and updated my Windows path accordingly,  Lilypond itself has 
been running fine, so, as far as I can tell, the paths are OK (and it 
was happy without the .py extension in the batch file).


Perhaps someone could check out line 376 for me.  Thanks again.
Archer




Re: run error Lilypond-book on Windows 10

2021-08-06 Thread David Wright
On Fri 06 Aug 2021 at 12:31:06 (+0100), Archer Endrich wrote:
> 
> I have been using Lilypond for a long time and am in awe of those who
> have created Lilypond and who maintain it.  It is the most wonderful
> and flexible package, with super high-quality results. I have not
> written to the Users Group before, but will have certain specialised
> notation queries in the future.
> 
> One of the key parts of Lilypond for me is Lilypond Book, and I am
> working on a major project with it.  I have used it extensively with
> Lilypond 2.18.2.
> 
> Since moving to Windows 10, I have not been able to get it to run,
> although David Wright's message to the User Group about adding the .py
> extension when invoking it got me further than I was at first. 

I saw my name. I'm not sure whether my comment would be a help or
a hindrance. I don't know how the windows versions are invoked,
but only that windows sometimes needs help with deciding which
interpreter to run when handed a script with a shebang at the top.

> I have
> Lilypond 2.22.1 installed.  My batch file is:
> 
> lilypond-book.py --output=out --pdf ALMdurasnumber.lytex
> cd out
> pdflatex ALMdurasnumber.tex
> cd ..\
> 
> which is what has always worked for me in the past.
> 
> 
> The error message I get is as follows:
> 
> C:\P3L\lpbk>ALMdurasnumber.bat
> 
> C:\P3L\lpbk>lilypond-book.py --output=out --pdf ALMdurasnumber.lytex
>   File "C:\Lilypond2221\usr\bin\lilypond-book.py", line 376
>     except subprocess.CalledProcessError as e:
>   ^
> SyntaxError: invalid syntax

Again, non-windows user disclaimer.

Something looks odd about C:\Lilypond2221\usr\bin\lilypond-book.py
in that I would expect either C:\Lilypond2221\bin\lilypond-book
or C:\Lilypond2221\LILYPOND\usr\bin\lilypond-book where LILYPOND
is either lowercase or camelcase (I have seen both). (I'm leaving
aside any consideration of a .py suffix.)

On linux, the former is a (shell) script that sets up the correct
environment for the latter (python script) to execute in. A versioned
directory, like Lilypond2221/, would normally contain just bin/
and lilypond/. The scripts in Lilypond2221/bin/ run the programs and
scripts in Lilypond2221/lilypond/usr/bin/.

> C:\P3L\lpbk>cd out
> 
> C:\P3L\lpbk\out>pdflatex ALMdurasnumber.tex
> 'pdflatex' is not recognized as an internal or external command,
> operable program or batch file.
> 
> C:\P3L\lpbk\out>cd ..\
> 
> C:\P3L\lpbk>
> 
> The message about pdflatex is a conundrum.  It has always worked
> before, but I cannot find a 'pdflatex' file in the \user\bin of
> version 2.18.2 or 2.22.1.  It does not appear to be complaining about
> anything in my lytex file -- which I had previously compiled
> successfully with 2.18.2.

That suggests a messed-up PATH, as presumably you haven't removed
pdflatex from your system. It could be related to the first problem.

Again, non-windows user disclaimer. You probably need a windows
user to help go over your 2.22.1 installation. Do you still have
2.18.2 installed? AFAICT the two versions are installed in exactly
the same manner, if both have been downloaded from the LP website.
(Obviously not for those on linux who might be comparing LP website
versions with a distribution's own version.)

Cheers,
David.



Re: run error Lilypond-book on Windows 10

2021-08-06 Thread Knute Snortum
On Fri, Aug 6, 2021 at 6:06 AM Archer Endrich  wrote:
...
>
> C:\P3L\lpbk\out>pdflatex ALMdurasnumber.tex
> 'pdflatex' is not recognized as an internal or external command,
> operable program or batch file.
>
> C:\P3L\lpbk\out>cd ..\
>
> C:\P3L\lpbk>
>
> The message about pdflatex is a conundrum.  It has always worked before,
> but I cannot find a 'pdflatex' file in the \user\bin of version 2.18.2
> or 2.22.1.  It does not appear to be complaining about anything in my
> lytex file -- which I had previously compiled successfully with 2.18.2.

pdflatex is not part of lilyPond, but part of the TeX Distribution:

https://tex.stackexchange.com/questions/49569/where-to-download-pdflatex-exe



run error Lilypond-book on Windows 10

2021-08-06 Thread Archer Endrich

Dear Lilypond Users,

I have been using Lilypond for a long time and am in awe of those who 
have created Lilypond and who maintain it.  It is the most wonderful and 
flexible package, with super high-quality results. I have not written to 
the Users Group before, but will have certain specialised notation 
queries in the future.


One of the key parts of Lilypond for me is Lilypond Book, and I am 
working on a major project with it.  I have used it extensively with 
Lilypond 2.18.2.


Since moving to Windows 10, I have not been able to get it to run, 
although David Wright's message to the User Group about adding the .py 
extension when invoking it got me further than I was at first.  I have 
Lilypond 2.22.1 installed.  My batch file is:


lilypond-book.py --output=out --pdf ALMdurasnumber.lytex
cd out
pdflatex ALMdurasnumber.tex
cd ..\

which is what has always worked for me in the past.


The error message I get is as follows:

C:\P3L\lpbk>ALMdurasnumber.bat

C:\P3L\lpbk>lilypond-book.py --output=out --pdf ALMdurasnumber.lytex
  File "C:\Lilypond2221\usr\bin\lilypond-book.py", line 376
    except subprocess.CalledProcessError as e:
  ^
SyntaxError: invalid syntax

C:\P3L\lpbk>cd out

C:\P3L\lpbk\out>pdflatex ALMdurasnumber.tex
'pdflatex' is not recognized as an internal or external command,
operable program or batch file.

C:\P3L\lpbk\out>cd ..\

C:\P3L\lpbk>

The message about pdflatex is a conundrum.  It has always worked before, 
but I cannot find a 'pdflatex' file in the \user\bin of version 2.18.2 
or 2.22.1.  It does not appear to be complaining about anything in my 
lytex file -- which I had previously compiled successfully with 2.18.2.


Any help will be greatly appreciated.

Archer Endrich
archer...@gmail.com




Re: lilypond-book executable

2021-02-12 Thread Daniel Connors
Thank you for pointing out my typo.  I apologize for that.  In some of the
previous versions of lilypond, the python scripts in the /bin directory did
not have the .py extension and Windows wouldn't run those python scripts.
(That didn't wasn't a problem for Linux users.)

Dan

On Fri, Feb 12, 2021 at 9:44 AM Phil Holmes  wrote:

> Not sure if the missing "d" is a typo - I assume it is.  In that case,
> there's no need to rename it because it is called lilypond-book.py as
> installed.  Windows, of course "helpfully" hides extensions by default, so
> it may not appear as that in Windows Explorer.
>
> On 12/02/2021 14:02, Daniel Connors wrote:
> > If you want to run lilypond-book on Windows, you'll need to rename it to
> lilypon-book.py
> >
> > Dan
>
> --
> Phil Holmes
>
>


Re: lilypond-book executable

2021-02-12 Thread Phil Holmes

Not sure if the missing "d" is a typo - I assume it is.  In that case, there's no need to 
rename it because it is called lilypond-book.py as installed.  Windows, of course 
"helpfully" hides extensions by default, so it may not appear as that in Windows Explorer.

On 12/02/2021 14:02, Daniel Connors wrote:

If you want to run lilypond-book on Windows, you'll need to rename it to 
lilypon-book.py

Dan


--
Phil Holmes




Re: lilypond-book executable

2021-02-12 Thread Daniel Connors
If you want to run lilypond-book on Windows, you'll need to rename it to
lilypon-book.py

Dan


Re: lilypond-book executable

2021-02-12 Thread Phil Holmes

It is a python file, not an executable (as in not a .exe).

On 11/02/2021 23:00, Luke Bang wrote:

Hi,
I just installed lilypond and according to the website I see that there's a 
lilypond-book executable I can run in the Windows version.
I don't see this in the /usr/bin directory, but I do see some other file by the 
name lilypond-book which is not an executable. Am I missing something?

Thanks,
Luke


--
Phil Holmes




Re: lilypond-book executable

2021-02-12 Thread David Menéndez Hurtado
How did you install it? Here is what I get on my system:

 [david@Hopper ~]$ ll /usr/bin/lilypond-book
-rwxr-xr-x. 1 root root 27690 Jan 20 19:01 /usr/bin/lilypond-book

As you can see, it is executable.


/David.

On Fri, 12 Feb 2021 at 00:29, Luke Bang  wrote:

> Hi,
> I just installed lilypond and according to the website I see that there's
> a lilypond-book executable I can run in the Windows version.
> I don't see this in the /usr/bin directory, but I do see some other file
> by the name lilypond-book which is not an executable. Am I missing
> something?
>
> Thanks,
> Luke
>


Re: lilypond-book executable

2021-02-11 Thread David Wright
On Thu 11 Feb 2021 at 17:00:33 (-0600), Luke Bang wrote:
> I just installed lilypond and according to the website I see that there's a
> lilypond-book executable I can run in the Windows version.
> I don't see this in the /usr/bin directory, but I do see some other file by
> the name lilypond-book which is not an executable. Am I missing something?

A listing of the directory might help. For linux, that looks like:

$ ls … lilypond-2.22.0-1.linux-64/bin/
lrwxrwxrwx  67 abc2ly -> 
/…/lilypond-2.22.0-1.linux-64/bin/lilypond-wrapper.python3
lrwxrwxrwx  67 convert-ly -> 
/…/lilypond-2.22.0-1.linux-64/bin/lilypond-wrapper.python3
lrwxrwxrwx  67 etf2ly -> 
/…/lilypond-2.22.0-1.linux-64/bin/lilypond-wrapper.python3
-rwxr-x--- 180 lilypond
lrwxrwxrwx  67 lilypond-book -> 
/…/lilypond-2.22.0-1.linux-64/bin/lilypond-wrapper.python3
lrwxrwxrwx  65 lilypond-invoke-editor -> 
/…/lilypond-2.22.0-1.linux-64/bin/lilypond-wrapper.guile
-rwxr-x--- 555 lilypond-wrapper.guile
-rwxr-x--- 557 lilypond-wrapper.python3
lrwxrwxrwx  67 midi2ly -> 
/…/lilypond-2.22.0-1.linux-64/bin/lilypond-wrapper.python3
lrwxrwxrwx  67 mup2ly -> 
/…/lilypond-2.22.0-1.linux-64/bin/lilypond-wrapper.python3
lrwxrwxrwx  67 musicxml2ly -> 
/…/lilypond-2.22.0-1.linux-64/bin/lilypond-wrapper.python3
-rwxr-x--- 874 uninstall-lilypond
$ 

So almost all the programs that one commands are symlinks to
wrapper scripts that ensure the correct library versions are used.
(The number are "file" sizes.)

Cheers,
David.



lilypond-book executable

2021-02-11 Thread Luke Bang
Hi,
I just installed lilypond and according to the website I see that there's a
lilypond-book executable I can run in the Windows version.
I don't see this in the /usr/bin directory, but I do see some other file by
the name lilypond-book which is not an executable. Am I missing something?

Thanks,
Luke


Re: lilypond-book V2.22.0 hanging on Windows 10

2021-01-13 Thread Daniel Connors
David,

Yes, I am running on Windows.  I made sure that no PDF viewer was running
and tried running the lilypond-book script and it still hangs.  I even
closed emacs to make sure that some file in my emacs buffers wasn't the
culprit.  The script is hanging on Windows 10.

Thank you for your suggestion.

Dan

On Wed, Jan 13, 2021 at 12:09 AM David Wright 
wrote:

> On Tue 12 Jan 2021 at 11:21:40 (-0500), Daniel Connors wrote:
> > I am trying to embed a music engraving in a LaTeX document and am
> following
> > the example given at
> >
> https://lilypond.org/doc/v2.19/Documentation/usage/an-example-of-a-musicological-document
> .
> > My example is a bit simpler than what is given in the documentation.  I
> > have named this file lilylatexly.lytex
> > ---
> >
> > \documentclass[a4paper]{article}
> >
> > \begin{document}
> >
> > Documents for \verb+lilypond-book+ may freely mix music and text.
> > For example,
> >
> > \begin{lilypond}
> > \relative c' {
> >   c2 e2 \tuplet 3/2 { f8 a b } a2 e4
> > }
> > \end{lilypond}
> >
> > Options are put in brackets.
> >
> > \begin{lilypond}[fragment,quote,staffsize=26,verbatim]
> >   c'4 f16
> > \end{lilypond}
> >
> > \end{document}
> >
> > -
> >
> > When I run the lilypond-book python script to process the .lytex file,
> the
> > process starts, then hands and I get this python error traceback when I
> > kill the process with Ctrl-C:
> >
> > c:\Labs>lilypond-book --output=out --pdf lilylatexly.lytex
> > lilypond-book.py (GNU LilyPond) 2.22.0
> > Reading `c:\Labs\lilylatexly.lytex'
> > Running `pdflatex' on file
> > `C:\Users\X~1\AppData\Local\Temp\tmphrkt8nkt.tex' to detect default
> > page settings.
> >
> > Traceback (most recent call last):
> >   File "C:\Program Files (x86)\LilyPond\usr\bin\lilypond-book.py", line
> > 820, in 
> > main()
> >   File "C:\Program Files (x86)\LilyPond\usr\bin\lilypond-book.py", line
> > 798, in main
> > chunks = do_file(files[0])
> >   File "C:\Program Files (x86)\LilyPond\usr\bin\lilypond-book.py", line
> > 600, in do_file
> > global_options.formatter.init_default_snippet_options(source)
> >   File "C:\Program Files
> > (x86)\LilyPond\usr\share\lilypond\current\python\book_base.py", line 173,
> > in init_default_snippet_options
> > line_width = self.get_line_width(source)
> >   File "C:\Program Files
> > (x86)\LilyPond\usr\share\lilypond\current\python\book_latex.py", line
> 314,
> > in get_line_width
> > textwidth = get_latex_textwidth(source, self.global_options)
> >   File "C:\Program Files
> > (x86)\LilyPond\usr\share\lilypond\current\python\book_latex.py", line
> 247,
> > in get_latex_textwidth
> > (parameter_string, error_string) = proc.communicate()
> >   File
> >
> "C:\Users\X\AppData\Local\Programs\Python\Python37\lib\subprocess.py",
> > line 920, in communicate
> > stdout, stderr = self._communicate(input, endtime, timeout)
> >   File
> >
> "C:\Users\X\AppData\Local\Programs\Python\Python37\lib\subprocess.py",
> > line 1244, in _communicate
> > self.stdout_thread.join(self._remaining_time(endtime))
> >   File
> > "C:\Users\\AppData\Local\Programs\Python\Python37\lib\threading.py",
> > line 1032, in join
> > self._wait_for_tstate_lock()
> >   File
> > "C:\Users\X\AppData\Local\Programs\Python\Python37\lib\threading.py",
> > line 1048, in _wait_for_tstate_lock
> > elif lock.acquire(block, timeout):
> > KeyboardInterrupt
> > ---
> > NOTES:
> > (1) I am running python 3.7;  I don't have any versions of python 2.X on
> my
> > PC.  I had seen in discussion threads that I needed to have a newer
> version
> > of lilypond so that python 3 would work with the lilypond-book python
> > scripts.  I removed my older version of lilypond and now have V2.22.0
> > installed.
> >
> > (2) I had to rename lilypond-book to lilypond-book.py so that Windows 10
> > recognized it as a python script.
> >
> > (3) This example works fine with my linux installation of lilypond
> 2.22.0.
> >
> > (4) From the python traceback there is some locking going on.  I don't
> know
> > if this is some problem with write access to files?  Do I need to invoke
> > the script with ADMIN privileges?
>
> You appear to be running on Windows. A common problem is that Windows
> doesn't let you write to a file that another application has open.
> So make sure you close out.pdf before you run lilypond-book.
> (I don't *think* you have to delete it as well.)
>
> Cheers,
> David.
>


Re: lilypond-book V2.22.0 hanging on Windows 10

2021-01-12 Thread David Wright
On Tue 12 Jan 2021 at 11:21:40 (-0500), Daniel Connors wrote:
> I am trying to embed a music engraving in a LaTeX document and am following
> the example given at
> https://lilypond.org/doc/v2.19/Documentation/usage/an-example-of-a-musicological-document.
> My example is a bit simpler than what is given in the documentation.  I
> have named this file lilylatexly.lytex
> ---
> 
> \documentclass[a4paper]{article}
> 
> \begin{document}
> 
> Documents for \verb+lilypond-book+ may freely mix music and text.
> For example,
> 
> \begin{lilypond}
> \relative c' {
>   c2 e2 \tuplet 3/2 { f8 a b } a2 e4
> }
> \end{lilypond}
> 
> Options are put in brackets.
> 
> \begin{lilypond}[fragment,quote,staffsize=26,verbatim]
>   c'4 f16
> \end{lilypond}
> 
> \end{document}
> 
> -
> 
> When I run the lilypond-book python script to process the .lytex file, the
> process starts, then hands and I get this python error traceback when I
> kill the process with Ctrl-C:
> 
> c:\Labs>lilypond-book --output=out --pdf lilylatexly.lytex
> lilypond-book.py (GNU LilyPond) 2.22.0
> Reading `c:\Labs\lilylatexly.lytex'
> Running `pdflatex' on file
> `C:\Users\X~1\AppData\Local\Temp\tmphrkt8nkt.tex' to detect default
> page settings.
> 
> Traceback (most recent call last):
>   File "C:\Program Files (x86)\LilyPond\usr\bin\lilypond-book.py", line
> 820, in 
> main()
>   File "C:\Program Files (x86)\LilyPond\usr\bin\lilypond-book.py", line
> 798, in main
> chunks = do_file(files[0])
>   File "C:\Program Files (x86)\LilyPond\usr\bin\lilypond-book.py", line
> 600, in do_file
> global_options.formatter.init_default_snippet_options(source)
>   File "C:\Program Files
> (x86)\LilyPond\usr\share\lilypond\current\python\book_base.py", line 173,
> in init_default_snippet_options
> line_width = self.get_line_width(source)
>   File "C:\Program Files
> (x86)\LilyPond\usr\share\lilypond\current\python\book_latex.py", line 314,
> in get_line_width
> textwidth = get_latex_textwidth(source, self.global_options)
>   File "C:\Program Files
> (x86)\LilyPond\usr\share\lilypond\current\python\book_latex.py", line 247,
> in get_latex_textwidth
> (parameter_string, error_string) = proc.communicate()
>   File
> "C:\Users\X\AppData\Local\Programs\Python\Python37\lib\subprocess.py",
> line 920, in communicate
> stdout, stderr = self._communicate(input, endtime, timeout)
>   File
> "C:\Users\X\AppData\Local\Programs\Python\Python37\lib\subprocess.py",
> line 1244, in _communicate
> self.stdout_thread.join(self._remaining_time(endtime))
>   File
> "C:\Users\\AppData\Local\Programs\Python\Python37\lib\threading.py",
> line 1032, in join
> self._wait_for_tstate_lock()
>   File
> "C:\Users\X\AppData\Local\Programs\Python\Python37\lib\threading.py",
> line 1048, in _wait_for_tstate_lock
> elif lock.acquire(block, timeout):
> KeyboardInterrupt
> ---
> NOTES:
> (1) I am running python 3.7;  I don't have any versions of python 2.X on my
> PC.  I had seen in discussion threads that I needed to have a newer version
> of lilypond so that python 3 would work with the lilypond-book python
> scripts.  I removed my older version of lilypond and now have V2.22.0
> installed.
> 
> (2) I had to rename lilypond-book to lilypond-book.py so that Windows 10
> recognized it as a python script.
> 
> (3) This example works fine with my linux installation of lilypond 2.22.0.
> 
> (4) From the python traceback there is some locking going on.  I don't know
> if this is some problem with write access to files?  Do I need to invoke
> the script with ADMIN privileges?

You appear to be running on Windows. A common problem is that Windows
doesn't let you write to a file that another application has open.
So make sure you close out.pdf before you run lilypond-book.
(I don't *think* you have to delete it as well.)

Cheers,
David.



lilypond-book V2.22.0 hanging on Windows 10

2021-01-12 Thread Daniel Connors
I am trying to embed a music engraving in a LaTeX document and am following
the example given at
https://lilypond.org/doc/v2.19/Documentation/usage/an-example-of-a-musicological-document.
My example is a bit simpler than what is given in the documentation.  I
have named this file lilylatexly.lytex
---

\documentclass[a4paper]{article}

\begin{document}

Documents for \verb+lilypond-book+ may freely mix music and text.
For example,

\begin{lilypond}
\relative c' {
  c2 e2 \tuplet 3/2 { f8 a b } a2 e4
}
\end{lilypond}

Options are put in brackets.

\begin{lilypond}[fragment,quote,staffsize=26,verbatim]
  c'4 f16
\end{lilypond}

\end{document}

-

When I run the lilypond-book python script to process the .lytex file, the
process starts, then hands and I get this python error traceback when I
kill the process with Ctrl-C:

c:\Labs>lilypond-book --output=out --pdf lilylatexly.lytex
lilypond-book.py (GNU LilyPond) 2.22.0
Reading `c:\Labs\lilylatexly.lytex'
Running `pdflatex' on file
`C:\Users\X~1\AppData\Local\Temp\tmphrkt8nkt.tex' to detect default
page settings.

Traceback (most recent call last):
  File "C:\Program Files (x86)\LilyPond\usr\bin\lilypond-book.py", line
820, in 
main()
  File "C:\Program Files (x86)\LilyPond\usr\bin\lilypond-book.py", line
798, in main
chunks = do_file(files[0])
  File "C:\Program Files (x86)\LilyPond\usr\bin\lilypond-book.py", line
600, in do_file
global_options.formatter.init_default_snippet_options(source)
  File "C:\Program Files
(x86)\LilyPond\usr\share\lilypond\current\python\book_base.py", line 173,
in init_default_snippet_options
line_width = self.get_line_width(source)
  File "C:\Program Files
(x86)\LilyPond\usr\share\lilypond\current\python\book_latex.py", line 314,
in get_line_width
textwidth = get_latex_textwidth(source, self.global_options)
  File "C:\Program Files
(x86)\LilyPond\usr\share\lilypond\current\python\book_latex.py", line 247,
in get_latex_textwidth
(parameter_string, error_string) = proc.communicate()
  File
"C:\Users\X\AppData\Local\Programs\Python\Python37\lib\subprocess.py",
line 920, in communicate
stdout, stderr = self._communicate(input, endtime, timeout)
  File
"C:\Users\X\AppData\Local\Programs\Python\Python37\lib\subprocess.py",
line 1244, in _communicate
self.stdout_thread.join(self._remaining_time(endtime))
  File
"C:\Users\\AppData\Local\Programs\Python\Python37\lib\threading.py",
line 1032, in join
self._wait_for_tstate_lock()
  File
"C:\Users\X\AppData\Local\Programs\Python\Python37\lib\threading.py",
line 1048, in _wait_for_tstate_lock
elif lock.acquire(block, timeout):
KeyboardInterrupt
---
NOTES:
(1) I am running python 3.7;  I don't have any versions of python 2.X on my
PC.  I had seen in discussion threads that I needed to have a newer version
of lilypond so that python 3 would work with the lilypond-book python
scripts.  I removed my older version of lilypond and now have V2.22.0
installed.

(2) I had to rename lilypond-book to lilypond-book.py so that Windows 10
recognized it as a python script.

(3) This example works fine with my linux installation of lilypond 2.22.0.

(4) From the python traceback there is some locking going on.  I don't know
if this is some problem with write access to files?  Do I need to invoke
the script with ADMIN privileges?

Thank you for your help in resolving this problem.


Re: Texinfo / lilypond-book - include paths

2020-06-29 Thread Michael Käppler

Am 29.06.2020 um 10:36 schrieb Michael Käppler:



The file 'lily-21179cd9-1.eps' is there, indeed. How is this supposed to
work?
Do I have to specify manual includes somewhere?

Sorry for the noise, I found out that I have to specify --pdf when invoking
lilypond-book, because
texi2pdf uses 'pdflatex' by default. Will add a note to the Usage manual.




Cheers,
Michael









Texinfo / lilypond-book - include paths

2020-06-29 Thread Michael Käppler

Hi all,
I'm trying to integrate Lilypond snippets into Texinfo files.
Consider the 'Texinfo' example from the 'Usage' manual, which you can find
here:
http://lilypond.org/doc/v2.21/Documentation/usage/lilypond_002dbook-templates

With this example in lybook-texinfo.tely, I do

lilypond-book --output=out lybook-texinfo.tely
cd out
texi2pdf lybook-texinfo.texi

TeX complains that it does not find the image file
'./7a/lily-21179cd9-1' which is included in
out/7a/lily-21179cd9-systems.texi.

The file 'lily-21179cd9-1.eps' is there, indeed. How is this supposed to
work?
Do I have to specify manual includes somewhere?

Cheers,
Michael






Re: Very inconsistent vertical spacing from lilypond book and LaTeX

2020-05-23 Thread David Wright
On Thu 21 May 2020 at 21:02:25 (+0100), Robert Hickman wrote:
> On Thu, 21 May 2020 at 19:56, David Wright  wrote:
> > On Thu 21 May 2020 at 18:40:53 (+0100), Robert Hickman wrote:
> > >
> > > I'm helping my partner create a book of interval exercises, and I'm
> > > getting very inconsistent vertical spacing coming from lilypond-book,
> > > here is an example:
> > >
> > > https://files.robehickman.com/problem.pdf
> > >
> > > Weird thing is that this is very inconsistent between pages, and I
> > > have verified there is no excess space in the music images. LaTeX
> > > seems to be stretching white space erratically.
> >
> > No idea what's in your .tex file. Perhaps the larger spaces are where
> > LaTeX thinks a new paragraph starts. The mere presence or absence of
> > blank lines between the figures can affect/control that.
> 
> The .tex file contains the following (a snippet of), The idea about it
> being where a new paragraph or line starts seems to make sense as the
> added space seems to be about 1em.

To check this out, you could increase \parskip substantially and see
if the result is consistent with that.

If it is, then the alternatives would appear to be either to scour the
individual \input files for differences in paragraph control, like
blank lines, or to capitulate and add blank lines to this file, making
every score into a new paragraph. (Multiple blank lines only cause a
single \parskip.)

If the problem lies in lilypondbook, I'm afraid I'm out of my depth.

> \vspace{-0em}\Ssubsection{Scale}\vspace{-0em}
> {%
> \parindent 0pt
> \noindent
> \ifx\preLilyPondExample \undefined
> \else
>   \expandafter\preLilyPondExample
> \fi
> \def\lilypondbook{}%
> \input{ce/lily-6d98c8ee-systems.tex}
> \ifx\postLilyPondExample \undefined
> \else
>   \expandafter\postLilyPondExample
> \fi
> }
> 
> \vspace{-0.8em}\Ssubsection{Thirds}\vspace{-0em}
> {%
> \parindent 0pt
> \noindent
> \ifx\preLilyPondExample \undefined
> \else
>   \expandafter\preLilyPondExample
> \fi
> \def\lilypondbook{}%
> \input{ec/lily-01f558b3-systems.tex}
> \ifx\postLilyPondExample \undefined
> \else
>   \expandafter\postLilyPondExample
> \fi
> }
> 
> \vspace{-0.8em}\Ssubsection{Fourths}\vspace{-0em}
> {%
> \parindent 0pt
> \noindent
> \ifx\preLilyPondExample \undefined
> \else
>   \expandafter\preLilyPondExample
> \fi
> \def\lilypondbook{}%
> \input{75/lily-95458ceb-systems.tex}
> \ifx\postLilyPondExample \undefined
> \else
>   \expandafter\postLilyPondExample
> \fi
> }
> 
> \vspace{-0.8em}\Ssubsection{Fifths}\vspace{-0em}
> {%
> \parindent 0pt
> \noindent
> \ifx\preLilyPondExample \undefined
> \else
>   \expandafter\preLilyPondExample
> \fi
> \def\lilypondbook{}%
> \input{2f/lily-cee1d442-systems.tex}
> \ifx\postLilyPondExample \undefined
> \else
>   \expandafter\postLilyPondExample
> \fi
> }
> 
> \vspace{-0.8em}\Ssubsection{Sixths}\vspace{-0em}
> {%
> \parindent 0pt
> \noindent
> \ifx\preLilyPondExample \undefined
> \else
>   \expandafter\preLilyPondExample
> \fi
> \def\lilypondbook{}%
> \input{05/lily-bdd1bc6c-systems.tex}
> \ifx\postLilyPondExample \undefined
> \else
>   \expandafter\postLilyPondExample
> \fi
> }

Cheers,
David.



Re: Very inconsistent vertical spacing from lilypond book and LaTeX

2020-05-21 Thread Robert Hickman
Hi David,

The .tex file contains the following (a snippet of), The idea about it
being where a new paragraph or line starts seems to make sense as the
added space seems to be about 1em.

\vspace{-0em}\Ssubsection{Scale}\vspace{-0em}
{%
\parindent 0pt
\noindent
\ifx\preLilyPondExample \undefined
\else
  \expandafter\preLilyPondExample
\fi
\def\lilypondbook{}%
\input{ce/lily-6d98c8ee-systems.tex}
\ifx\postLilyPondExample \undefined
\else
  \expandafter\postLilyPondExample
\fi
}

\vspace{-0.8em}\Ssubsection{Thirds}\vspace{-0em}
{%
\parindent 0pt
\noindent
\ifx\preLilyPondExample \undefined
\else
  \expandafter\preLilyPondExample
\fi
\def\lilypondbook{}%
\input{ec/lily-01f558b3-systems.tex}
\ifx\postLilyPondExample \undefined
\else
  \expandafter\postLilyPondExample
\fi
}

\vspace{-0.8em}\Ssubsection{Fourths}\vspace{-0em}
{%
\parindent 0pt
\noindent
\ifx\preLilyPondExample \undefined
\else
  \expandafter\preLilyPondExample
\fi
\def\lilypondbook{}%
\input{75/lily-95458ceb-systems.tex}
\ifx\postLilyPondExample \undefined
\else
  \expandafter\postLilyPondExample
\fi
}

\vspace{-0.8em}\Ssubsection{Fifths}\vspace{-0em}
{%
\parindent 0pt
\noindent
\ifx\preLilyPondExample \undefined
\else
  \expandafter\preLilyPondExample
\fi
\def\lilypondbook{}%
\input{2f/lily-cee1d442-systems.tex}
\ifx\postLilyPondExample \undefined
\else
  \expandafter\postLilyPondExample
\fi
}

\vspace{-0.8em}\Ssubsection{Sixths}\vspace{-0em}
{%
\parindent 0pt
\noindent
\ifx\preLilyPondExample \undefined
\else
  \expandafter\preLilyPondExample
\fi
\def\lilypondbook{}%
\input{05/lily-bdd1bc6c-systems.tex}
\ifx\postLilyPondExample \undefined
\else
  \expandafter\postLilyPondExample
\fi
}

On Thu, 21 May 2020 at 19:56, David Wright  wrote:
>
> On Thu 21 May 2020 at 18:40:53 (+0100), Robert Hickman wrote:
> >
> > I'm helping my partner create a book of interval exercises, and I'm
> > getting very inconsistent vertical spacing coming from lilypond-book,
> > here is an example:
> >
> > https://files.robehickman.com/problem.pdf
> >
> > Weird thing is that this is very inconsistent between pages, and I
> > have verified there is no excess space in the music images. LaTeX
> > seems to be stretching white space erratically.
>
> No idea what's in your .tex file. Perhaps the larger spaces are where
> LaTeX thinks a new paragraph starts. The mere presence or absence of
> blank lines between the figures can affect/control that.
>
> Cheers,
> David.
>



Re: Very inconsistent vertical spacing from lilypond book and LaTeX

2020-05-21 Thread David Wright
On Thu 21 May 2020 at 18:40:53 (+0100), Robert Hickman wrote:
> 
> I'm helping my partner create a book of interval exercises, and I'm
> getting very inconsistent vertical spacing coming from lilypond-book,
> here is an example:
> 
> https://files.robehickman.com/problem.pdf
> 
> Weird thing is that this is very inconsistent between pages, and I
> have verified there is no excess space in the music images. LaTeX
> seems to be stretching white space erratically.

No idea what's in your .tex file. Perhaps the larger spaces are where
LaTeX thinks a new paragraph starts. The mere presence or absence of
blank lines between the figures can affect/control that.

Cheers,
David.



Re: Very inconsistent vertical spacing from lilypond book and LaTeX

2020-05-21 Thread Valentin Petzel
Most likely the scores are for some obscure reason cropped to different 
heights. For a quick workaround, you can try putting the images in a parbox 
with a specified height.

signature.asc
Description: This is a digitally signed message part.


Very inconsistent vertical spacing from lilypond book and LaTeX

2020-05-21 Thread Robert Hickman
Hi,

I'm helping my partner create a book of interval exercises, and I'm
getting very inconsistent vertical spacing coming from lilypond-book,
here is an example:

https://files.robehickman.com/problem.pdf

Weird thing is that this is very inconsistent between pages, and I
have verified there is no excess space in the music images. LaTeX
seems to be stretching white space erratically.



Re: Help: can't invoke lilypond-book (python exception)

2020-02-12 Thread David Kastrup
Alon Sho'er  writes:

> I downloaded python to be able to run lilypond-book, but it doesn't seem to 
> work.
>
> Upon invoking lilypond-book I get the following error:
>
>  
>
> File "C:\Program Files (x86)\LilyPond\usr\bin\lilypond-book.py", line 590
> os.mkdir (global_options.output_dir, 0777)
> ^
> SyntaxError: leading zeros in decimal integer literals are not permitted; use 
> an 0o prefix for
> octal integers
>
> Has anyone experienced this? I would like to use lilypond-book on html files.
>
> I have lilypond version 2.18.2 and python version 3.8.1

LilyPond 2.18 uses Python 2.  So will LilyPond 2.20 (to appear really
soon now).  LilyPond 2.21 will be working with Python 3.

-- 
David Kastrup
My replies have a tendency to cause friction.  To help mitigating
damage, feel free to forward problematic posts to me adding a subject
like "timeout 1d" (for a suggested timeout of 1 day) or "offensive".



  1   2   3   4   5   6   7   8   9   10   >