David Kastrup <d...@gnu.org> writes: > Jean Abou Samra <j...@abou-samra.fr> writes: > >> Apparently, top-level markups are interpreted with \paper, although >> grob-interpret-markup interprets with a real \layout? >> >> >> \version "2.24.0" >> >> #(define-markup-command (whats-layout layout props) () >> (interpret-markup layout props (symbol->string >> (ly:output-def-lookup layout 'output-def-kind)))) >> >> \markup \whats-layout >> >> { >> c'^\markup \whats-layout >> } >> >> >> >> Le 08/01/2023 à 17:06, David Kastrup a écrit : >>> Frankly, I don't get the "layout" parameter in markup. >> >> >> Me neither. The whole output def setup is quite messy. > > A Paper_book does not preserve \layout so at the point where text > markups are interpreted, the \layout is not available. This seems more > like a fudge than anything else. > > I have no idea what the original idea here was, but given that the > parameter name "layout" to markup commands is rather unambiguous and > that it seems very desirable to be able to write > > (define-markup-command ... (layout props) ... > #{ \markup \score { \layout { $layout ... > > I lean towards maintaining "layout" and not passing paper blocks into > interpret-markup at all. > > We may break some things while figuring this out. But the current way > appears too weird to make for a useful interface.
Frankly, the level of bull**** here is unbelievable. git grep book_rendering ... lily/book.cc: SCM outputs = score->book_rendering (output_paper_book->paper (), layout); lily/include/score.hh: SCM book_rendering (Output_def *, Output_def *); lily/score.cc:Score::book_rendering (Output_def *layoutbook, Output_def *default_def) So what is it already?!?!? Paper or layout? I guess this nonsense is also behind some book layout variables not making it into scores. -- David Kastrup