[TeX-Music] Vertical distribution of systems.
I have a piano score with only 4 systems. I do not like the vertical distribution I obtain because the first and last systems are stuck to the vertical boundaries of the page. Instead, I would like the space above the first system and below the last system to be half the space between systems. How can I do this without putting two ugly \vspace's in my source? \input musixtex \instrumentnumber1\setstaffs12\setclef1{\bass\treble} %\vskip2cm \startpiece \NOtes\qa{HKNH}|\qa{hjec}\en\bar\NOtes\qa{HKNH}|\qa{hjgc}\en\bar% \NOtes\qa{HKNH}|\qa{hjlc}\en\bar\NOtes\qa{HKNH}|\qa{hjoc}\en\bar% \NOtes\qa{HKNH}|\qa{hmjc}\en\bar\NOtes\qa{HKNH}|\qa{hcec}\en\bar% \NOtes\qa{HKNH}|\qa{hmjc}\en\bar\NOtes\qa{HKNH}|\qa{hjec}\en\bar% \NOtes\qa{HKNH}|\qa{hjhc}\en\bar\NOtes\qa{HKNH}|\qa{hjjc}\en\bar% \NOtes\qa{HKNH}|\qa{hjkc}\en\bar\NOtes\qa{HKNH}|\qa{hjgc}\en\bar% \NOtes\qa{HKNH}|\qa{hjec}\en \linegoal4% \Stoppiece %\vskip2cm \eject \end Incidentally the first \vskip does not do its job. Regards, Jean-Pierre Coulon cou...@obs-nice.fr ___ tex-mu...@icking-music-archive.org mailing list If you want to unsubscribe or look at the archives, go to http://mailman.nfit.au.dk/mailman/listinfo/icking-music-archive.org-tex-music
Re: [TeX-Music] Vertical distribution of systems.
Jean-Pierre Coulon wrote: I have a piano score with only 4 systems. I do not like the vertical distribution I obtain because the first and last systems are stuck to the vertical boundaries of the page. Instead, I would like the space above the first system and below the last system to be half the space between systems. Your example below just includes 2cm for the \vskip's. Shouldn't it be .5\somemusixtexparameter? (it's early - I can't remember what the \dimen or \skip for that is called). How can I do this without putting two ugly \vspace's in my source? I may be corrected with a very clever alternate solution, but I think you're hitting one of TeX's few brick walls - while it's very clever at making paragraphs (and MusixTeX is very clever at making staves) neither is as clever when it comes to making pages. The reason is a combination of the fact that in the eighties and nineties it wasn't possible to use the same of level of algorithm over entire documents as it was over paragraphs because of memory constraints on the computer and also because pagination often just has to be tweaked by a human anyway in order to look really nice (for example, TeX's paragraphing algorithm produces the actual optimal result but its pagination algorithm does not). I find this often that means that TeX's facilities for doing something automatic with pagination are therefore a bit limited compared with some other areas of TeX. You could possibly come up with a very hairy \output routine to do this. \input musixtex \instrumentnumber1\setstaffs12\setclef1{\bass\treble} %\vskip2cm \startpiece \NOtes\qa{HKNH}|\qa{hjec}\en\bar\NOtes\qa{HKNH}|\qa{hjgc}\en\bar% \NOtes\qa{HKNH}|\qa{hjlc}\en\bar\NOtes\qa{HKNH}|\qa{hjoc}\en\bar% \NOtes\qa{HKNH}|\qa{hmjc}\en\bar\NOtes\qa{HKNH}|\qa{hcec}\en\bar% \NOtes\qa{HKNH}|\qa{hmjc}\en\bar\NOtes\qa{HKNH}|\qa{hjec}\en\bar% \NOtes\qa{HKNH}|\qa{hjhc}\en\bar\NOtes\qa{HKNH}|\qa{hjjc}\en\bar% \NOtes\qa{HKNH}|\qa{hjkc}\en\bar\NOtes\qa{HKNH}|\qa{hjgc}\en\bar% \NOtes\qa{HKNH}|\qa{hjec}\en \linegoal4% \Stoppiece %\vskip2cm \eject \end Incidentally the first \vskip does not do its job. At the moment your sample ends unusually - if you look at the definition of \bye then you'll see that it has a \vfill in it. There is some glue at the end of the score (probably a stray \parskip as that by default has 1pt of stretchability) which has been over-stretched to the bottom of the page because you omitted the \vfill. If I change the top \vskip to \leavevmode\vskip2cm and the last one to \vskip 2cm plus 1fill then I get something closer to what you intended. See Chapter 15 of the TeX book (but don't do that first thing in the morning - it's a very hairy chapter!) - TeX removes glue at page break boundaries and the start of the document is considered a page boundary. You need to insert a \leavevmode before the \vskip (the \leavevmode instruction temporarily forces TeX into paragraphing mode which means that it doesn't delete the \vskip). HTH, David ___ tex-mu...@icking-music-archive.org mailing list If you want to unsubscribe or look at the archives, go to http://mailman.nfit.au.dk/mailman/listinfo/icking-music-archive.org-tex-music
Re: [TeX-Music] Vertical distribution of systems.
Jean-Pierre Coulon cou...@obs-nice.fr wrote: I have a piano score with only 4 systems. I do not like the vertical distribution I obtain because the first and last systems are stuck to the vertical boundaries of the page. Instead, I would like the space above the first system and below the last system to be half the space between systems. How can I do this without putting two ugly \vspace's in my source? what's the concept of ugly in a tex source? \input musixtex \instrumentnumber1\setstaffs12\setclef1{\bass\treble} %\vskip2cm instead: \leavevmode\vskip0pt plus2fill \lineskip0pt plus1fill \startpiece \NOtes\qa{HKNH}|\qa{hjec}\en\bar\NOtes\qa{HKNH}|\qa{hjgc}\en\bar% \NOtes\qa{HKNH}|\qa{hjlc}\en\bar\NOtes\qa{HKNH}|\qa{hjoc}\en\bar% \NOtes\qa{HKNH}|\qa{hmjc}\en\bar\NOtes\qa{HKNH}|\qa{hcec}\en\bar% \NOtes\qa{HKNH}|\qa{hmjc}\en\bar\NOtes\qa{HKNH}|\qa{hjec}\en\bar% \NOtes\qa{HKNH}|\qa{hjhc}\en\bar\NOtes\qa{HKNH}|\qa{hjjc}\en\bar% \NOtes\qa{HKNH}|\qa{hjkc}\en\bar\NOtes\qa{HKNH}|\qa{hjgc}\en\bar% \NOtes\qa{HKNH}|\qa{hjec}\en \linegoal4% \Stoppiece %\vskip2cm instead: \vskip0pt plus2fill \eject \end Incidentally the first \vskip does not do its job. that's what the \leavevmode is for. (it's not the *right* thing to do, but since my brain is only just waking up, it'll do.) \hskip at the start of a line doesn't work either... robin ___ tex-mu...@icking-music-archive.org mailing list If you want to unsubscribe or look at the archives, go to http://mailman.nfit.au.dk/mailman/listinfo/icking-music-archive.org-tex-music
Re: [TeX-Music] Vertical distribution of systems.
On Thu, 14 Oct 2010, Robin Fairbairns wrote: what's the concept of ugly in a tex source? Simply the need for my calculating the half of the distance between systems before I know this distance! IMO trial-and-error is even uglier! instead: \leavevmode\vskip0pt plus2fill \lineskip0pt plus1fill [...] This gives too big a top space. Could you please explain how I can adjust the spaces? Incidentally the first \vskip does not do its job. I can work around by saying \centerline{~} before this \vskip. Bye, Jean-Pierre Coulon cou...@obs-nice.fr ___ tex-mu...@icking-music-archive.org mailing list If you want to unsubscribe or look at the archives, go to http://mailman.nfit.au.dk/mailman/listinfo/icking-music-archive.org-tex-music
Re: [TeX-Music] Vertical distribution of systems.
Jean-Pierre Coulon cou...@obs-nice.fr wrote: On Thu, 14 Oct 2010, Robin Fairbairns wrote: what's the concept of ugly in a tex source? Simply the need for my calculating the half of the distance between systems before I know this distance! IMO trial-and-error is even uglier! instead: \leavevmode\vskip0pt plus2fill perhaps: \null\vskip0pt plus1fill (\null was what i was trying to remember, before) \lineskip0pt plus1fill [...] This gives too big a top space. Could you please explain how I can adjust the spaces? Incidentally the first \vskip does not do its job. I can work around by saying \centerline{~} before this \vskip. the same thing (in effect) as \null does: an invisible hbox on the main vertical list. \leavevmode actually starts a line, though it doesn't seem to matter here. ___ tex-mu...@icking-music-archive.org mailing list If you want to unsubscribe or look at the archives, go to http://mailman.nfit.au.dk/mailman/listinfo/icking-music-archive.org-tex-music
Re: [TeX-Music] Vertical distribution of systems.
On Thu, 14 Oct 2010, David Allsopp wrote: Robin Fairbairns wrote: Jean-Pierre Coulon cou...@obs-nice.fr wrote: On Thu, 14 Oct 2010, Robin Fairbairns wrote: what's the concept of ugly in a tex source? Simply the need for my calculating the half of the distance between systems before I know this distance! IMO trial-and-error is even uglier! That's what I was referring to! A hairy \output routine would break \box255 up and find the \skip's but analysing the \output of \vsplit is not fun. But TeX hacking to one side, I'm still not entirely clear what you're after in layout terms - doesn't MusiXTeX already insert a *known* amount of space between systems already (\staffbotmarg and \stafftopmarg - the computed value \systemheight may be useful in calculations too)? \staffbotmarg and \stafftopmarg need an argument (cm, in, \Interligne or other). Like \vskip, they won't calculate this argument for me! AFAIK MusiXTeX puts between systems the space it thinks is clever. If a system has a high, high symbol it adapts these spaces. Replace a \qa somewhere in the middle of my example with \qa{hce''z} and you will see what I mean. Jean-Pierre Coulon cou...@obs-nice.fr ___ tex-mu...@icking-music-archive.org mailing list If you want to unsubscribe or look at the archives, go to http://mailman.nfit.au.dk/mailman/listinfo/icking-music-archive.org-tex-music
Re: [TeX-Music] Vertical distribution of systems.
Jean-Pierre Coulon wrote: On Thu, 14 Oct 2010, David Allsopp wrote: Robin Fairbairns wrote: Jean-Pierre Coulon cou...@obs-nice.fr wrote: On Thu, 14 Oct 2010, Robin Fairbairns wrote: what's the concept of ugly in a tex source? Simply the need for my calculating the half of the distance between systems before I know this distance! IMO trial-and-error is even uglier! That's what I was referring to! A hairy \output routine would break \box255 up and find the \skip's but analysing the \output of \vsplit is not fun. But TeX hacking to one side, I'm still not entirely clear what you're after in layout terms - doesn't MusiXTeX already insert a *known* amount of space between systems already (\staffbotmarg and \stafftopmarg - the computed value \systemheight may be useful in calculations too)? \staffbotmarg and \stafftopmarg need an argument (cm, in, \Interligne or other). Like \vskip, they won't calculate this argument for me! No, \staffbotmarg and \stafftopmarg are both \dimen's... you can read them. Try saying \showthe\staffbotmarg in your source file. \Interligne is also a \dimen (but one you aren't supposed to touch). When you say \staffbotmarg2cm you are simply setting the value of the \dimen (same with 3\Interligne - TeX offers free multiplication when assigning to a \dimen so \staffbotmarg3\Interligne means multiply \Interligne by 3 and assign the result to \staffbotmarg). It would be clearer if, as I do in my sources, people actually included the optional equals sign. \staffbotmarg3\Interligne can also be written \staffbotmarg=3\Interligne which would stop people thinking it was a macro... one of the (few) mistakes of TeX's grammar (and an artefact of a time when 100Kb and less was actually a user's storage quota!) \staffbotmarg and \stafftopmarg are certainly correctly defined (at 15pt) just before \startpiece. AFAIK MusiXTeX puts between systems the space it thinks is clever. If a system has a high, high symbol it adapts these spaces. Replace a \qa somewhere in the middle of my example with \qa{hce''z} and you will see what I mean. And you want to take that into account?? That would create variable top-line spacing in your score which sounds like an odd idea. Those parameters are also available, line-by-line (see the MusiXTeX manual) but you would have to code macros to capture them yourself. Incidentally, why do you want fixed spacing at the bottom of the score? David ___ tex-mu...@icking-music-archive.org mailing list If you want to unsubscribe or look at the archives, go to http://mailman.nfit.au.dk/mailman/listinfo/icking-music-archive.org-tex-music
Re: [TeX-Music] Vertical distribution of systems.
On Thu, 14 Oct 2010, David Allsopp wrote: Incidentally, why do you want fixed spacing at the bottom of the score? I want - in the vertical direction - half_space/system/space/system/space/system/space/system/half_space At present this fixed spacing is my ugly way to work around the lack of such an automated spacing. Jean-Pierre Coulon cou...@obs-nice.fr ___ tex-mu...@icking-music-archive.org mailing list If you want to unsubscribe or look at the archives, go to http://mailman.nfit.au.dk/mailman/listinfo/icking-music-archive.org-tex-music
Re: [TeX-Music] Vertical distribution of systems.
Jean-Pierre Coulon wrote: On Thu, 14 Oct 2010, David Allsopp wrote: Incidentally, why do you want fixed spacing at the bottom of the score? I want - in the vertical direction - half_space/system/space/system/space/system/space/system/half_space At present this fixed spacing is my ugly way to work around the lack of such an automated spacing. Aha - I finally understand the problem (sorry - being slow). What's actually going on is an underfull \vbox which I'd failed to notice before in the transcript before. TeX expands stretchable glue infinitely in an underfull box (rantit is the single most annoying thing I find about TeX and have had to work-around that illogical decision on many occasions.../rant) How does putting \musicparskip before \startpiece and \vskip\parskip before \eject (and no other \vskip's) look to you? David ___ tex-mu...@icking-music-archive.org mailing list If you want to unsubscribe or look at the archives, go to http://mailman.nfit.au.dk/mailman/listinfo/icking-music-archive.org-tex-music
Re: [TeX-Music] Vertical distribution of systems.
Incidentally the first \vskip does not do its job. I think the space is eaten up by earlyer space generated by the system, use \vglue2cm instead ___ tex-mu...@icking-music-archive.org mailing list If you want to unsubscribe or look at the archives, go to http://mailman.nfit.au.dk/mailman/listinfo/icking-music-archive.org-tex-music
Re: [TeX-Music] Vertical distribution of systems.
On Thu, 14 Oct 2010, David Allsopp wrote: How does putting \musicparskip before \startpiece and \vskip\parskip before \eject (and no other \vskip's) look to you? The bottom is acceptable, but I see no addtional space on the top. But perharps you're pointing out the right direction. Does MusiXTeX modify \parskip and \musicparskip when it shares the spacing? Could another ordering of \musicparskip, \startpiece, \stoppiece, \parskip be the solution? Can I divide \parskip ou \musicparskip by 2? In this thread http://www.mail-archive.com/icking-music-archive.org-tex-music@mailman.nfit.au.dk/msg01906.html there was no reply to my question about the usefulness of \musicparskip. It would be nice if \musicparskip was useful sometimes! Jean-Pierre Coulon cou...@obs-nice.fr ___ tex-mu...@icking-music-archive.org mailing list If you want to unsubscribe or look at the archives, go to http://mailman.nfit.au.dk/mailman/listinfo/icking-music-archive.org-tex-music
[TeX-Music] Space between pagenumber and the first stave
May be my question is related to what just is discussed. I use M-Tx for my typesetting. If the last page consists of fewer staves than possible the space between the pagenumber and the first staff is smaller than on full pages. Any suggestion? Hermann ___ tex-mu...@icking-music-archive.org mailing list If you want to unsubscribe or look at the archives, go to http://mailman.nfit.au.dk/mailman/listinfo/icking-music-archive.org-tex-music