Re: lay out
Aaron Mehl wrote: continued from preious email that yahoo sent accidently before I finished :( If a structural wish list was allowed however here is what I would want. 1. A real separation of content and formatting. This means that a lilypond file would have no formatting in it at all. A seperate style sheet would be the place for this. The advantage is that if you have style tweaks for multiple docs only one file is needed to apply these tweaks to all files. This might require the addition of attributes to permit lower level styles in and external file... I would claim that this idea clearly has influenced the design of LilyPond from the first version. You can set parameters to determine the layout in the \layout{...} block. However, there will always be special cases where the automatic layout decisions taken by the program will not be good enough, so therefore we can never get rid of the need to tweak certain parameters at a specific place in the score. This means that it will be impossible to get a 100% separation of content and layout. 2. A fixed and clearly defined structure which takes into account the possible structural pieces that different scores can contain. \piece \movement \phrase \motiv \chorus etc. This I know is a fundamental change in the structure of lilypond and possibly(probably) hard to impose on the already existing structure. The support for titling in LilyPond has always been a bit primitive, just providing a basic support to add titles to a piece. So, the structural elements you propose are really out of scope in todays LilyPond. Up til version 2.2, the titling layout was really hard coded and it was very seldom that you could have more than a single \score{...} in a .ly file and get a useful output. However, from version 2.4 you can actually redefine how the titling is done, so there are much better possibilities to actually typeset a full piece with several movements in a single .ly file. Still, going from that to what you have in mind is a very long step and I'm not convinced that it should be top priority. For me it's much more important that the typesetting withing each movement is top quality. Truthfully \score etc doesn't say much about the structure of a composition but are rather containers for data types to be parsed. Think of it as one movement of a piece. This thread was started to understand and I hope document the file structure. I would like to see actually a diagram of how and in what order each block ("container of data") is parsed in lilypond as well as what block is processed first second etc. Parsing is from top to bottom, replacing macro definitions along the way, so nothing fancy is going on here. /Mats ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: lay out
Aaron Mehl wrote: Ok I am now getting both unconfused and confused. But both paper and layout deal with layout. Up to version 2.2, page layout and score layout was all lumped together into \paper{...}. Now, there's more structure to it. The intuitive notion is that \paper{...} only deals with the page sizes, margins, and other page layout issues that apply to the full book, whereas \layout{...} deals with the layout within each \score{...}. I see that structure in lilypond is not a documentation structure. ie a programmers structure. If I were to build a document I would have formatting for the page or the entire document and formatting for the section. My confusion is that lilypond leave the creation of sections etc to the user in a way. The logic is not one of nesting I gather but how things are processed, as in python where each part is processed going down the page and inner brackets are done in a certain order. I could then have I gather layout anywhere in a document. I would hate to hazard a guess that paper could also appear anywhere? What happens is that the terms become unclear and the usage blurry. I agree completely that this is unclear and have requested clarifications a number of times. /Mats ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: lay out
On 6-Jun-05, at 11:08 PM, Aaron Mehl wrote: 1. A real separation of content and formatting. This means that a lilypond file would have no formatting in it at all. A seperate style sheet would be the place for this. The advantage is that if you have style tweaks for multiple docs only one file is needed to apply these tweaks to all files. This is already possible and in use. See the Mutopia examples. - Graham ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: lay out
Also, to get a nice overview of the changes from version 2.2 to 2.4, please read the NEWS file for version 2.4: http://lilypond.org/doc/v2.4/Documentation/topdocs/out-www/NEWS.html Also, it may be worth to look at the printouts from convert-ly -s /Mats Mats Bengtsson wrote: On Sat, 4 Jun 2005, Graham Percival wrote: On 4-Jun-05, at 4:31 PM, Aaron Mehl wrote: So am I able to generalize from this that layout replaces paper (you said not and the docs still say that paper is still in?) There is currently a \paper{} and \layout{}. I really don't want to talk about anything that happened before 2.4, because I really don't know what the relationship is. See http://lists.gnu.org/archive/html/bug-lilypond/2005-04/msg00147.html with follow-ups for some input. /Mats ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user -- = Mats Bengtsson Signal Processing Signals, Sensors and Systems Royal Institute of Technology SE-100 44 STOCKHOLM Sweden Phone: (+46) 8 790 8463 Fax: (+46) 8 790 7260 Email: [EMAIL PROTECTED] WWW: http://www.s3.kth.se/~mabe = ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: lay out
continued from preious email that yahoo sent accidently before I finished :( > If a structural wish list was allowed however here > is > what I would want. > > 1. A real separation of content and formatting. This means that a lilypond file would have no formatting in it at all. A seperate style sheet would be the place for this. The advantage is that if you have style tweaks for multiple docs only one file is needed to apply these tweaks to all files. This might require the addition of attributes to permit lower level styles in and external file... 2. A fixed and clearly defined structure which takes into account the possible structural pieces that different scores can contain. \piece \movement \phrase \motiv \chorus etc. This I know is a fundamental change in the structure of lilypond and possibly(probably) hard to impose on the already existing structure. Truthfully \score etc doesn't say much about the structure of a composition but are rather containers for data types to be parsed. This thread was started to understand and I hope document the file structure. I would like to see actually a diagram of how and in what order each block ("container of data") is parsed in lilypond as well as what block is processed first second etc. Aaron ( __ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: lay out
Well, I did some testing and lilypond doesn't like nesting but it produces output in some instances. What I get from this and the more pictures thread is that some rules and I mean rules would help the beginner. ie this is how you build a vocal score, a piano score etc. would ease the entry to beginners. When all is said and done it is still not trivial to create a score from scratch. What about an abstraction level where lilypond --level-beginner would read a new type of structed lilypond for beginners where only a fixed structure is allowed. \version \layout \header \score \midi and make the structure as clear and easy as possible. then there could be abstraction levels for intermediate which will allow more freedom etc. -- If a structural wish list was allowed however here is what I would want. 1. A real separation of content and formatting. __ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: lay out
Ok I am now getting both unconfused and confused. But both paper and layout deal with layout. I see that structure in lilypond is not a documentation structure. ie a programmers structure. If I were to build a document I would have formatting for the page or the entire document and formatting for the section. My confusion is that lilypond leave the creation of sections etc to the user in a way. The logic is not one of nesting I gather but how things are processed, as in python where each part is processed going down the page and inner brackets are done in a certain order. I could then have I gather layout anywhere in a document. I would hate to hazard a guess that paper could also appear anywhere? What happens is that the terms become unclear and the usage blurry. I would love to see lilypond seperate presentation from content, the truth is with includes it is possible now, I guess. That said \layout {} \score { \layout {} \score{ \layout {} } } would format each subscore. Now for different movements of one piece would I use multple \score blocks or are there real structural block in lilypond? Pesonally I find the structure and usage of \paper and \layout a but confusing but now that I look at it from a programmers perspective I at least understand the logic. however some rules such an not allowing \score {\paper{} \score { \paper {} }} would help to unconfuse, unless it already works that way. I will experiment and get back to the list soon. Aaron --- Mats Bengtsson <[EMAIL PROTECTED]> wrote: > On Sat, 4 Jun 2005, Graham Percival wrote: > > > > > On 4-Jun-05, at 4:31 PM, Aaron Mehl wrote: > > > > > So am I able to generalize from this that layout > > > replaces paper (you said not and the docs still > say > > > that paper is still in?) > > > > There is currently a \paper{} and \layout{}. I > really don't > > want to talk about anything that happened before > 2.4, because > > I really don't know what the relationship is. > > See > http://lists.gnu.org/archive/html/bug-lilypond/2005-04/msg00147.html > > with follow-ups for some input. > >/Mats > > __ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: lay out
On Sat, 4 Jun 2005, Graham Percival wrote: > > On 4-Jun-05, at 4:31 PM, Aaron Mehl wrote: > > > So am I able to generalize from this that layout > > replaces paper (you said not and the docs still say > > that paper is still in?) > > There is currently a \paper{} and \layout{}. I really don't > want to talk about anything that happened before 2.4, because > I really don't know what the relationship is. See http://lists.gnu.org/archive/html/bug-lilypond/2005-04/msg00147.html with follow-ups for some input. /Mats ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: lay out
> I don't know. I don't write music with lyrics. > Let's look at the > docs... Instrument-specific notation -> Vocal music. Why not look a lyrics which is what I did and I got the following: And I couldn't figure out where to put it because I go an x =y situation again. Remember you know where to look in the docs and a newbie doesn't. I also remember reading that \lyricsto is needed to line up lyrics to the text, but I gather the \addlyrics is good enough... Sorry I got confused but I did read the docs. Thanks Aaron http://lilypond.org/doc/v2.5/Documentation/user/out-www/lilypond/Single-staff.html#Single-staff The next example demonstrates a simple melody with lyrics. Cut and paste, add notes, then words for the lyrics. This example turns off automatic beaming, which is common for vocal parts. If you want to use automatic beaming, you'll have to change or comment out the relevant line. \version "2.4.0" melody = \relative c' { \clef treble \key c \major \time 4/4 a4 b c d } text = \lyricmode { Aaa Bee Cee Dee } \score{ << \context Voice = one { \autoBeamOff \melody } \lyricsto "one" \new Lyrics \text >> \layout { } \midi { \tempo 4=60 } } > Setting-simple-songs.html > > Hmm, it says that for simple stuff, just add > \addlyrics under the notes. > Let's see if that works. Hey, it does! > > insert > > \addlyrics{ > type lyrics here > } > > into your example, right after your notes. Here's > some context: > -- > %15 > d''8. c''16 b'8 a' gis' e' c'' b' | > a'2 \bar "|." > } > \addlyrics{ > type lyrics here > } > > > > \layout { > } > - > > > PLEASE, please read the docs! We've spent hours and > hours writing > and editing the docs. This question required ten > seconds of reading > the first section about vocal music! How could we > make this easier to > find? > > - Graham > > __ Discover Yahoo! Get on-the-go sports scores, stock quotes, news and more. Check it out! http://discover.yahoo.com/mobile.html ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: lay out
On 4-Jun-05, at 4:31 PM, Aaron Mehl wrote: So am I able to generalize from this that layout replaces paper (you said not and the docs still say that paper is still in?) There is currently a \paper{} and \layout{}. I really don't want to talk about anything that happened before 2.4, because I really don't know what the relationship is. I'm looking into what \paper{} and \layout{} do. Stay tuned. Also is the second set of brackets under the score block just a shortcut for \note {}? There's no \note{} anymore. {} is like the old \note{}, and \relative c' { } is like the old \note{\relative c'{ }}. I need to acheive a template with lyrics in it where in this template would I put lyrics? I don't know. I don't write music with lyrics. Let's look at the docs... Instrument-specific notation -> Vocal music. http://lilypond.org/doc/v2.5/Documentation/user/out-www/lilypond/ Setting-simple-songs.html Hmm, it says that for simple stuff, just add \addlyrics under the notes. Let's see if that works. Hey, it does! insert \addlyrics{ type lyrics here } into your example, right after your notes. Here's some context: -- %15 d''8. c''16 b'8 a' gis' e' c'' b' | a'2 \bar "|." } \addlyrics{ type lyrics here } \layout { } - PLEASE, please read the docs! We've spent hours and hours writing and editing the docs. This question required ten seconds of reading the first section about vocal music! How could we make this easier to find? - Graham ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: lay out
Hi Graham and list, I did as you said and did a convert-ly on the file. it basically replaced paper with layout and removed the notes block but I see a second set of brackets. -- \version "2.2.0" \header{ title = "Zachrenu" poet = "Machzor Yom Kippur" composer = "Yechiel Halpern" meter = "Andante" } #(set-global-staff-size 18) \score { \notes { \set Staff.midiInstrument = "acoustic grand" \time 4/4 \key a \minor \clef treble e'4 e''8 c'' b' a' b' c'' | a'4 a' a' a' | gis'8 a' b' c'' b' gis' a' f' | e'4 gis'8. gis'16 gis'4 gis'8. e'16 | %5 a'8 gis' a' f' e' d' f' a' | d'4 d' d' d'8. d''16 | d'' c'' b' a' b' a' gis' f' gis' f' e' d' gis' a' gis' f' | e'2. r8 e'16 e' | a'8. gis'16 a'8 b' c''8. b'16 c''8 a' | %10 b'4 b' b' b'8 e' | b'8. ais'16 b'8 c'' d''8. c''16 d''8 b' | c''4 c'' c'' c'' | f''8. e''16 d''8 c'' b'16 c'' b' c'' d''4 | e''8. d''16 c''8 b' a'16 b' a' b' c''4 | %15 d''8. c''16 b'8 a' gis' e' c'' b' | a'2 \bar "|." } \paper { } \midi { \tempo 4 = 72 } } - \version "2.5.12" \header{ title = "Zachrenu" poet = "Machzor Yom Kippur" composer = "Yechiel Halpern" meter = "Andante" } #(set-global-staff-size 18) \score { { \set Staff.midiInstrument = "acoustic grand" \time 4/4 \key a \minor \clef treble e'4 e''8 c'' b' a' b' c'' | a'4 a' a' a' | gis'8 a' b' c'' b' gis' a' f' | e'4 gis'8. gis'16 gis'4 gis'8. e'16 | %5 a'8 gis' a' f' e' d' f' a' | d'4 d' d' d'8. d''16 | d'' c'' b' a' b' a' gis' f' gis' f' e' d' gis' a' gis' f' | e'2. r8 e'16 e' | a'8. gis'16 a'8 b' c''8. b'16 c''8 a' | %10 b'4 b' b' b'8 e' | b'8. ais'16 b'8 c'' d''8. c''16 d''8 b' | c''4 c'' c'' c'' | f''8. e''16 d''8 c'' b'16 c'' b' c'' d''4 | e''8. d''16 c''8 b' a'16 b' a' b' c''4 | %15 d''8. c''16 b'8 a' gis' e' c'' b' | a'2 \bar "|." } \layout { } \midi { \tempo 4 = 72 } } - So am I able to generalize from this that layout replaces paper (you said not and the docs still say that paper is still in?) Also is the second set of brackets under the score block just a shortcut for \note {}? I need to acheive a template with lyrics in it where in this template would I put lyrics? Again it is nice to get a working template for my personal project but even nicer would be to have some structural rules I can share with others. What I mean is that a lilypond file must have these blocks and optionally can have these blocks. It could be that nothing really has changed in the versions and I just never bothered to pin down what is the basic structure before. But infact one of the stumbling blocks with lilyxml was defining what was the lilypond structure. And I see that it is very different than xml so this discussion is most enlightening for me. Aaron __ Do you Yahoo!? Read only the mail you want - Yahoo! Mail SpamGuard. http://promotions.yahoo.com/new_mail ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: lay out
On 4-Jun-05, at 12:47 PM, Aaron Mehl wrote: So in the 2.4 series lilypond I was eventually able to create my own template. Still I was never exactly sure why it worked and others I tried didn't... Why can't you use your 2.4 scores in 2.5? You might need to update them with convert-ly, but the basic ideas are the same. I think we really need an example of what you're trying to do. I don't understand what the difficulty is. Please send an example. - Graham ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: lay out
Well this seems to imply: "forget being able to build a lilypond file from scratch, you must start from a template or all is lost." Infact for the majority of my Lilypond experience I relied on templates for creating scores. What this did was limit my ability to make a score do exactly what I wanted. So in the 2.4 series lilypond I was eventually able to create my own template. Still I was never exactly sure why it worked and others I tried didn't... An abstraction layer would be nice with a clearly defined structure and it would also be nice to be able to seperate content from formatting Although I don't care so much how Lilypond is structured so long as I understand it and can reproduce it, which I currently can't do consistantly. I also haven't seen templates without the x=y structure although I think I am close to getting it working in the development version. Aaron > > %{The best way to proceed IMO is to comment the > templates much more > and then to grow the section from that. Some of the > examples in the > docs could use more commenting too, especially > labeling to show what > in the text is referring to what in the example.%} > daveA > > -- > The only technical exercises for all guitarists > worth a lifetime > of practice: "Dynamic Guitar Technique". Nothing > else is close. > Free download: > http://www.openguitar.com/instruction.html > daveA David Raleigh Arnold > dra..at..openguitar.com > > > > ___ > lilypond-user mailing list > lilypond-user@gnu.org > http://lists.gnu.org/mailman/listinfo/lilypond-user > __ Discover Yahoo! Get on-the-go sports scores, stock quotes, news and more. Check it out! http://discover.yahoo.com/mobile.html ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: lay out
On Thursday 02 June 2005 05:56 pm, Erik Ronström wrote: > | I see what you are saying but I still say a clearly defined > | and enforced structure would make the entry into lilypond > | much and mean much easier to the newbie. > > I agree completely! IMHO, this is the single most annoying thing about > lilypond: the lack of a (obvious-to-the-user) uniform structure of the > input files. Since lilypond is defined by a grammar, it must of course > have a clearly defined structure, but where is it documented? > > | > Part of an answer to your question can be found in the > | > sections "Changing context default settings" > | > | but this should be in file structure and in a section > | called layout. > > Exactly! The template section is a good start, but the problem is that > is doesn't explain *why* the different templates are written the way > they are. There should definitely be a section explaining and giving > examples of the different parts of a lilypond source file! %{The best way to proceed IMO is to comment the templates much more and then to grow the section from that. Some of the examples in the docs could use more commenting too, especially labeling to show what in the text is referring to what in the example.%} daveA -- The only technical exercises for all guitarists worth a lifetime of practice: "Dynamic Guitar Technique". Nothing else is close. Free download: http://www.openguitar.com/instruction.html daveA David Raleigh Arnold dra..at..openguitar.com ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: lay out
BTW, for those late to this thread, my intention is not to bash either lilypond or the docs. Rather I am taking upon myself to write the section file structure. I however need to understand it. By that I mean not from a programmers standpoint but the end user. So that once I can setup from scratch any number of valid structures for a lilypond file, it will be a piece of cake to explain this to others. Aaron __ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: lay out
| I see what you are saying but I still say a clearly defined | and enforced structure would make the entry into lilypond | much and mean much easier to the newbie. I agree completely! IMHO, this is the single most annoying thing about lilypond: the lack of a (obvious-to-the-user) uniform structure of the input files. Since lilypond is defined by a grammar, it must of course have a clearly defined structure, but where is it documented? | > Part of an answer to your question can be found in the | > sections "Changing context default settings" | | but this should be in file structure and in a section | called layout. Exactly! The template section is a good start, but the problem is that is doesn't explain *why* the different templates are written the way they are. There should definitely be a section explaining and giving examples of the different parts of a lilypond source file! Regards Erik Ronström ___ Yahoo! Messenger - NEW crystal clear PC to PC calling worldwide with voicemail http://uk.messenger.yahoo.com ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: lay out
| I see what you are saying but I still say a clearly defined | and enforced structure would make the entry into lilypond | much and mean much easier to the newbie. I agree completely! IMHO, this is the single most annoying thing about lilypond: the lack of a (obvious-to-the-user) uniform structure of the input files. Since lilypond is defined by a grammar, it must of course have a clearly defined structure, but where is it documented? | > Part of an answer to your question can be found in the | > sections "Changing context default settings" | | but this should be in file structure and in a section | called layout. Exactly! The template section is a good start, but the problem is that is doesn't explain *why* the different templates are written the way they are. There should definitely be a section explaining and giving examples of the different parts of a lilypond source file! Regards Erik Ronström ___ How much free photo storage do you get? Store your holiday snaps for FREE with Yahoo! Photos http://uk.photos.yahoo.com ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: lay out
--- Mats Bengtsson <[EMAIL PROTECTED]> wrote: > For me it's the opposite. I find it much harder to > see > the structure if you only have a long \score{...} > where > I have to scroll several pages from beginning to > end. Well if I take docbook as an example a book can have multiple sections no problem. The score block would in your case be confusing because there aren't so many structureal elements in lilypond. I created an xml wrapper for lilypond and proposed a phrase element do do that. The idea is that a fixed structure permits the engraver/composer to forget about structure an concentrate on notating. The tools force the correct structure and the person concentrates on the grammar of the language. > > One thing that may confuse you is that some of the > structural > elements are optional. For example, > \book{ >\score{ > {c d e f} >} > } > can be abbreviated into > {c d e f} > yes that is confusing and why make it confusing? Does this give more power? Does this make things easier to notate? a tool can be trained to laydown the structural elements in a file correctly and automatically. This is done in docbook and it lets the author concentrate on writing. > Probably, you wouldn't have that much problems with > the basic structure > if you had a background in programming languages > like Pascal or C or > Scheme than with the very strictly specified grammar > of XML. True but I know a bit of python. I see what you are saying but I still say a clearly defined and enforced structure would make the entry into lilypond much and I mean much easier to the newbie. > To cite Han-Wen, the strict formal definition of the > input grammar > can be found in the source code file parser.yy. > hmn part of the problem is that the base for lilypond is a fullfleged programing language, which is what gives it its power but also its confusion. If you have time look at lilyxml.sourceforge.net > >>Part of an answer to your question can be found in > >>the > >>sections "Changing context default settings" but this should be in file structure and in a section called layout. and > >>"Defining new contexts" in the manual. There's > also > >>some > >>information in "Line length", but there doesn't I will read these sections again. Aaron __ Discover Yahoo! Stay in touch with email, IM, photo sharing and more. Check it out! http://discover.yahoo.com/stayintouch.html ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: lay out
Aaron Mehl wrote: Ok here is where I am confused. There is a structure for files which makes a file valid. Then there is a grammar which must also be followed for the lanuguage of lilypond. I get the feeling after reading the docs that the structure of lilypond is loose. What I mean is that it appear (if I am not wrong) that there are elements that can appear a number of places in a document and others that can appear only in certain places. I want to be able to generalize and also limit the structure of a basic lilypond file: lets say a file with a melody only. If I ask the question what elements must a lilypond file have or it won't be valid structuraly will I get an answer? If I ask for a valid parent child relationship of elements will I find such a thing? This issue is compounded for me by most lilypond examples which use includes or variables x = y so that it is often hard to see what the structure is. For me it's the opposite. I find it much harder to see the structure if you only have a long \score{...} where I have to scroll several pages from beginning to end. One thing that may confuse you is that some of the structural elements are optional. For example, \book{ \score{ {c d e f} } } can be abbreviated into {c d e f} Probably, you wouldn't have that much problems with the basic structure if you had a background in programming languages like Pascal or C or Scheme than with the very strictly specified grammar of XML. To cite Han-Wen, the strict formal definition of the input grammar can be found in the source code file parser.yy. However, I agree completely with you that we should have a basic description not only of the syntax but also of the semantics of the basic building blocks. Even though I've been using LilyPond since version 0.0.xx, I'm still confused by some aspects, especially when it comes to \book{...} and what happens if you have several \layout{...} blocks at the top level. The basic ideas, though, are not that hard. At the top level of the file, you can have "macro definitions" = ..., you can have \header{...} blocks, \paper{...} blocks, \layout{...} blocks and, of course, \score{...} blocks (I've probably forgot some others as well). The \header and \layout can also be moved inside the \score{...} if you wish and in that case the only apply to the current score, otherwise they apply to all scores. /Mats I am not complaining rather I am trying to understand. I realize part of my problem comes from my experience with xml/html where there are strict rules for nesting and validity and wellformedbness... A documentation page titled file structure should lay down some rules for file structure instead of listing a few of the top level elements. I for my part find it confusing when an element is not nested. Although I realize that with lilypond there is less worry about missing brackets that way. I will read some more and experiment some more and see what I come up with. Aaron --- Mats Bengtsson <[EMAIL PROTECTED]> wrote: (Graham, or someone else, we should really try to make sure that all commands and reserved words available in LilyPond are listed in the Index. \layout is one of those missing. Doing such an exercise would also help identifying what information is missing from the manual today.) Part of an answer to your question can be found in the sections "Changing context default settings" and "Defining new contexts" in the manual. There's also some information in "Line length", but there doesn't seem to be any introduction to the concept anywhere. For example, I couldn't find any information on that you can put a \layout{...} block on the top level of the file to make it apply to all scores in the file (or at least within the \book) whereas it will only apply to the current score if you put the declaration inside \score{...}. /Mats Aaron Mehl wrote: Hi all, In a previous email I asked if layout replaced paper. I was told to look at outputs, which I did. The paper output section details \paper{} but I see no mention of \layout {} where in the docs is \layout discussed? Thanks Aaron __ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user -- = Mats Bengtsson Signal Processing Signals, Sensors and Systems Royal Institute of Technology SE-100 44 STOCKHOLM Sweden Phone: (+46) 8 790 8463 Fax: (+46) 8 790 7260 Email: [EMAIL PROTECTED] WWW: http://www.s3.kth.se/~mabe = __ Discover Yahoo! Find restaurants, movies, travel an
Re: lay out
Ok here is where I am confused. There is a structure for files which makes a file valid. Then there is a grammar which must also be followed for the lanuguage of lilypond. I get the feeling after reading the docs that the structure of lilypond is loose. What I mean is that it appear (if I am not wrong) that there are elements that can appear a number of places in a document and others that can appear only in certain places. I want to be able to generalize and also limit the structure of a basic lilypond file: lets say a file with a melody only. If I ask the question what elements must a lilypond file have or it won't be valid structuraly will I get an answer? If I ask for a valid parent child relationship of elements will I find such a thing? This issue is compounded for me by most lilypond examples which use includes or variables x = y so that it is often hard to see what the structure is. I am not complaining rather I am trying to understand. I realize part of my problem comes from my experience with xml/html where there are strict rules for nesting and validity and wellformedbness... A documentation page titled file structure should lay down some rules for file structure instead of listing a few of the top level elements. I for my part find it confusing when an element is not nested. Although I realize that with lilypond there is less worry about missing brackets that way. I will read some more and experiment some more and see what I come up with. Aaron --- Mats Bengtsson <[EMAIL PROTECTED]> wrote: > (Graham, or someone else, we should really try to > make sure that > all commands and reserved words available in > LilyPond are listed > in the Index. \layout is one of those missing. Doing > such an exercise > would also help identifying what information is > missing from the manual > today.) > > Part of an answer to your question can be found in > the > sections "Changing context default settings" and > "Defining new contexts" in the manual. There's also > some > information in "Line length", but there doesn't seem > to be > any introduction to the concept anywhere. For > example, I couldn't > find any information on that you can put a > \layout{...} block > on the top level of the file to make it apply to all > scores in the > file (or at least within the \book) whereas it will > only apply to > the current score if you put the declaration inside > \score{...}. > > /Mats > > > Aaron Mehl wrote: > > Hi all, > > > > In a previous email I asked if layout replaced > paper. > > I was told to look at outputs, which I did. The > paper > > output section details \paper{} > > > > but I see no mention of \layout {} > > > > where in the docs is \layout discussed? > > > > Thanks > > Aaron > > > > __ > > Do You Yahoo!? > > Tired of spam? Yahoo! Mail has the best spam > protection around > > http://mail.yahoo.com > > > > > > ___ > > lilypond-user mailing list > > lilypond-user@gnu.org > > > http://lists.gnu.org/mailman/listinfo/lilypond-user > > -- > = > Mats Bengtsson > Signal Processing > Signals, Sensors and Systems > Royal Institute of Technology > SE-100 44 STOCKHOLM > Sweden > Phone: (+46) 8 790 8463 > Fax: (+46) 8 790 7260 > Email: [EMAIL PROTECTED] > WWW: http://www.s3.kth.se/~mabe > = > __ Discover Yahoo! Find restaurants, movies, travel and more fun for the weekend. Check it out! http://discover.yahoo.com/weekend.html ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: lay out
(Graham, or someone else, we should really try to make sure that all commands and reserved words available in LilyPond are listed in the Index. \layout is one of those missing. Doing such an exercise would also help identifying what information is missing from the manual today.) Part of an answer to your question can be found in the sections "Changing context default settings" and "Defining new contexts" in the manual. There's also some information in "Line length", but there doesn't seem to be any introduction to the concept anywhere. For example, I couldn't find any information on that you can put a \layout{...} block on the top level of the file to make it apply to all scores in the file (or at least within the \book) whereas it will only apply to the current score if you put the declaration inside \score{...}. /Mats Aaron Mehl wrote: Hi all, In a previous email I asked if layout replaced paper. I was told to look at outputs, which I did. The paper output section details \paper{} but I see no mention of \layout {} where in the docs is \layout discussed? Thanks Aaron __ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user -- = Mats Bengtsson Signal Processing Signals, Sensors and Systems Royal Institute of Technology SE-100 44 STOCKHOLM Sweden Phone: (+46) 8 790 8463 Fax: (+46) 8 790 7260 Email: [EMAIL PROTECTED] WWW: http://www.s3.kth.se/~mabe = ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user