[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bizarre behaviour of `output-filename`
From: |
Werner LEMBERG |
Subject: |
bizarre behaviour of `output-filename` |
Date: |
Fri, 20 Oct 2023 08:22:09 +0000 (UTC) |
Consider this input file called `c.ly`:
```
output-filename = "foo"
output-suffix = "bar"
\book {
\paper {
output-suffix = "baz"
}
{ c' }
}
\book {
{ c' }
}
\book {
{ c' }
}
```
The created output files are
foo-baz.pdf
c-bar.pdf
c-bar-1.pdf
I consider it bizarre that the top-level variable `output-filename` is
only considered in a `\book` block where the paper variable
`output-suffix` is also set, contrary to `output-suffix`. Why is
`output-filename` considered at all? Where in the code is this read?
AFAIK, top-level variables are read with `ly:parser-lookup`, and I
can't find this for `output-filename`.
Or is this an inheritance thing? Does a `\book` block inherit all
top-level expressions and convert them to paper variables?
Werner
- bizarre behaviour of `output-filename`,
Werner LEMBERG <=