Re: [Denemo-devel] (Justified) text between title and staff and text before movement.
On Tue, 27 Aug 2019 at 18:54, Richard Shann wrote: > > On Tue, 2019-08-27 at 09:58 +0100, Richard Shann wrote: > > I've long thought it would be nice to create a pure LilyPond markup > > interactive generator for Denemo, just by cutting down that > > command... > > Well, intriguingly this is possible (with one wrinkle): > In the Scheme window paste this script: > > 8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8>< > > (let ((tag "ScoreMarkup")(user-input "")) > (set! user-input (d-DirectiveGet-score-data tag)) > (if (not user-input) > (set! user-input "Insert LilyPond markup syntax here - delete any > paragraph markers ¶ as they will display wrongly\n")) > (set! user-input (d-GetUserInputWithSnippets #f #f user-input #f)) > (disp "user-input " user-input "\n\n") > (if user-input > (let ((syntax (string-append "\\markup {\n" (string-delete #\¶ (car > user-input)) "\n}"))) > (d-SetSaved #f) > (d-DirectivePut-score-data tag (car user-input)) > (d-DirectivePut-score-prefix tag syntax) > (d-DirectivePut-score-display tag syntax)) > (d-WarningDialog (_ "Score Markup unchanged" > > 8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8>< > > When you execute this it lets you type in LilyPond markup syntax and > displays how it will look in the top pane as you type. > When you are done it puts it at the top of your score (by wrapping it > with \markup {}) > The wrinkle is that the paragraph markers ¶ are still inserted and need > to be deleted, otherwise the preview shows them as new lines. > There are commands under the Selection button for putting a selection > of your text into a line (and the lines, when selected, into a column). > > This script can be made into a palette button, new command etc as > usual. > > HTH > > Richard > Thank you so much for this, and also for the detailed explanation! I'll test it today and report. Cheers, Lib ___ Denemo-devel mailing list Denemo-devel@gnu.org https://lists.gnu.org/mailman/listinfo/denemo-devel
Re: [Denemo-devel] (Justified) text between title and staff and text before movement.
On Tue, 27 Aug 2019 at 10:04, Richard Shann wrote: > > On Tue, 2019-08-27 at 09:07 +0200, Lib Lists wrote: > > Hi, > > for the manual I'm writing I'd need to write some text between a > > movement title and a staff. At the moment I'm using the 'Piece' > > field, > > but I'm wondering if there's a better way to do it. > That's a quick way to do it without looking to deeply into LilyPond's > markup syntax - but see below (*). > > > > Also, I'd need to write an introductory text before the first > > movement. I'm using Text after Movement quite often and it's very > > handy so I'm wondering how to type some Text before the first > > Movement. > > Do you mean between the Score Title and the Movement Title or before > everything? Hi Richard, before the Score Title and the Movement Title. > > > > > Finally, the texts should be justified, as in the 'Markup lines' > > example here: > > http://lilypond.org/doc/v2.18/Documentation/snippets/text > > You can use any markup commands in the various fields that built-in for > titling - e.g. using the Movements->Titles->Simple Titles->Set Titles > =>"piece" field I pasted in the text > > \justify { > Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed > do eiusmod tempor incididunt ut labore et dolore magna aliqua. > Ut enim ad minim veniam, quis nostrud exercitation ullamco > laboris nisi ut aliquip ex ea commodo consequat. > } Ah, interesting! I was a bit confused about which lilypond markup commands work in the titling fields, now it's clear, thanks. > which came from that page and it arranged it justified between the > margins below the movement title. > > (*) Perhaps you would be better off not using the built-in titling at > all, since you are writing more and more markup commands - the built-in > titling is just layering a few markup commands around the text that you > give so you may better off with a clean sheet. > > If you use the command > Command: LilyPond Score Prolog > Inserts LilyPond syntax for include files etc at head of score. > Location: Object Menu ▶ Score > Internal Name: ScoreProlog > > to insert some markup this will appear at the top of the score > (actually, if you *do* have simple titles it will appear between the > Score title and the first Movement title). > What you could do is to interactively design your markup syntax that > you want to use by invoking the command > > Command: Multi-line Text and Music > Inserts multi-line text object which can include music snippets, Fret > Diagrams and Note Names/Chord Symbols. LilyPond Markup can be used and > a preview button is available to check the syntax. > Location: Object Menu ▶ Directives ▶ Markings ▶ Text/Symbol > Internal Name: MultiLineTextAnnotation > > This command let's you see how your markup will look as you write it. > Once you are happy with it you would copy the markup text and paste it > into the ScoreProlog command above. > (after cancelling the creation of the multi-line text object of > course). You could create your entire title and text system in LilyPond > markup syntax, giving you the maximum flexibility. > > It's a trade off between entering only small bits of the syntax and > having complete control. > > HTH > > Richard > > > > > ___ Denemo-devel mailing list Denemo-devel@gnu.org https://lists.gnu.org/mailman/listinfo/denemo-devel
Re: [Denemo-devel] (Justified) text between title and staff and text before movement.
On Tue, 2019-08-27 at 09:58 +0100, Richard Shann wrote: > I've long thought it would be nice to create a pure LilyPond markup > interactive generator for Denemo, just by cutting down that > command... Well, intriguingly this is possible (with one wrinkle): In the Scheme window paste this script: 8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8>< (let ((tag "ScoreMarkup")(user-input "")) (set! user-input (d-DirectiveGet-score-data tag)) (if (not user-input) (set! user-input "Insert LilyPond markup syntax here - delete any paragraph markers ¶ as they will display wrongly\n")) (set! user-input (d-GetUserInputWithSnippets #f #f user-input #f)) (disp "user-input " user-input "\n\n") (if user-input (let ((syntax (string-append "\\markup {\n" (string-delete #\¶ (car user-input)) "\n}"))) (d-SetSaved #f) (d-DirectivePut-score-data tag (car user-input)) (d-DirectivePut-score-prefix tag syntax) (d-DirectivePut-score-display tag syntax)) (d-WarningDialog (_ "Score Markup unchanged" 8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8>< When you execute this it lets you type in LilyPond markup syntax and displays how it will look in the top pane as you type. When you are done it puts it at the top of your score (by wrapping it with \markup {}) The wrinkle is that the paragraph markers ¶ are still inserted and need to be deleted, otherwise the preview shows them as new lines. There are commands under the Selection button for putting a selection of your text into a line (and the lines, when selected, into a column). This script can be made into a palette button, new command etc as usual. HTH Richard ___ Denemo-devel mailing list Denemo-devel@gnu.org https://lists.gnu.org/mailman/listinfo/denemo-devel
Re: [Denemo-devel] (Justified) text between title and staff and text before movement.
On Tue, 2019-08-27 at 09:04 +0100, Richard Shann wrote: > What you could do is to interactively design your markup syntax that > you want to use by invoking the command > > Command: Multi-line Text and Music > Inserts multi-line text object which can include music snippets, Fret > Diagrams and Note Names/Chord Symbols. LilyPond Markup can be used > and > a preview button is available to check the syntax. > Location: Object Menu ▶ Directives ▶ Markings ▶ Text/Symbol > Internal Name: MultiLineTextAnnotation > > This command let's you see how your markup will look as you write it. > Once you are happy with it you would copy the markup text and paste > it > into the ScoreProlog command above. > (after cancelling the creation of the multi-line text object of > course). You could create your entire title and text system in > LilyPond > markup syntax, giving you the maximum flexibility. I should have mentioned - this command isn't ideally suited to the task of visualizing what your markup will look like because it inserts a paragraph marker every time you press Enter, forcing you to immediately press Backspace to delete it, leaving just the newline you wanted. Of course, you don't technically need new lines inside markup, but they make it easier to read. Also, you need to surround your whole syntax with \markup { ... } even though the visualisation works without it. These wrinkles are due to the fact that the MultiLineTextAnnotation command is going to munge the syntax you give up after you have finished, adding the surrounding \markup{...} and splitting the lines at the paragraph markers. I've long thought it would be nice to create a pure LilyPond markup interactive generator for Denemo, just by cutting down that command... Richard ___ Denemo-devel mailing list Denemo-devel@gnu.org https://lists.gnu.org/mailman/listinfo/denemo-devel
Re: [Denemo-devel] (Justified) text between title and staff and text before movement.
On Tue, 2019-08-27 at 09:07 +0200, Lib Lists wrote: > Hi, > for the manual I'm writing I'd need to write some text between a > movement title and a staff. At the moment I'm using the 'Piece' > field, > but I'm wondering if there's a better way to do it. That's a quick way to do it without looking to deeply into LilyPond's markup syntax - but see below (*). > > Also, I'd need to write an introductory text before the first > movement. I'm using Text after Movement quite often and it's very > handy so I'm wondering how to type some Text before the first > Movement. Do you mean between the Score Title and the Movement Title or before everything? > > Finally, the texts should be justified, as in the 'Markup lines' > example here: > http://lilypond.org/doc/v2.18/Documentation/snippets/text You can use any markup commands in the various fields that built-in for titling - e.g. using the Movements->Titles->Simple Titles->Set Titles =>"piece" field I pasted in the text \justify { Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. } which came from that page and it arranged it justified between the margins below the movement title. (*) Perhaps you would be better off not using the built-in titling at all, since you are writing more and more markup commands - the built-in titling is just layering a few markup commands around the text that you give so you may better off with a clean sheet. If you use the command Command: LilyPond Score Prolog Inserts LilyPond syntax for include files etc at head of score. Location: Object Menu ▶ Score Internal Name: ScoreProlog to insert some markup this will appear at the top of the score (actually, if you *do* have simple titles it will appear between the Score title and the first Movement title). What you could do is to interactively design your markup syntax that you want to use by invoking the command Command: Multi-line Text and Music Inserts multi-line text object which can include music snippets, Fret Diagrams and Note Names/Chord Symbols. LilyPond Markup can be used and a preview button is available to check the syntax. Location: Object Menu ▶ Directives ▶ Markings ▶ Text/Symbol Internal Name: MultiLineTextAnnotation This command let's you see how your markup will look as you write it. Once you are happy with it you would copy the markup text and paste it into the ScoreProlog command above. (after cancelling the creation of the multi-line text object of course). You could create your entire title and text system in LilyPond markup syntax, giving you the maximum flexibility. It's a trade off between entering only small bits of the syntax and having complete control. HTH Richard ___ Denemo-devel mailing list Denemo-devel@gnu.org https://lists.gnu.org/mailman/listinfo/denemo-devel
[Denemo-devel] (Justified) text between title and staff and text before movement.
Hi, for the manual I'm writing I'd need to write some text between a movement title and a staff. At the moment I'm using the 'Piece' field, but I'm wondering if there's a better way to do it. Also, I'd need to write an introductory text before the first movement. I'm using Text after Movement quite often and it's very handy so I'm wondering how to type some Text before the first Movement. Finally, the texts should be justified, as in the 'Markup lines' example here: http://lilypond.org/doc/v2.18/Documentation/snippets/text Thank you for your help, Lib ___ Denemo-devel mailing list Denemo-devel@gnu.org https://lists.gnu.org/mailman/listinfo/denemo-devel