[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Denemo-devel] Scheme script for score directive
From: |
Richard Shann |
Subject: |
Re: [Denemo-devel] Scheme script for score directive |
Date: |
Mon, 01 Apr 2013 17:37:18 +0100 |
On Sun, 2013-03-31 at 09:52 +0200, Andreas Schneider wrote:
>
> I took some time browsing through the commands and some corresponding
> scripts, particularly looking at the titles, but I couldn't locate the
> script that creates the button (is it built-in?).
>
I just had a look at the details of this, this code puts a directive in
the scoreheader (with nothing in the LilyPond, ie no prefix or postfix
fields set) and displays itself as a button (that is what the
DENEMO_OVERRIDE_GRAPHIC does) with the text from the display field.
(let ((tag "test"))
(d-DirectivePut-scoreheader-override tag DENEMO_OVERRIDE_GRAPHIC)
(d-DirectivePut-scoreheader-display tag "something"))
the tag used, in this case "test", does not match any action (there is
no command d-test), so clicking on it just gives the advanced edit.
another example:
(let ((tag "test"))
(d-DirectivePut-movementcontrol-override tag
DENEMO_OVERRIDE_GRAPHIC)
(d-DirectivePut-movementcontrol-display tag "something"))
this puts the button on the movement titles button bar. If you used a
real command for the tag, the button would execute that command. For
example
(let ((tag "NewScore"))
(d-DirectivePut-movementcontrol-override tag DENEMO_OVERRIDE_GRAPHIC)
(d-DirectivePut-movementcontrol-display tag "start new"))
creates a button that runs the NewScore command ...
HTH
Richard
- Re: [Denemo-devel] Scheme script for score directive,
Richard Shann <=