editor-lilypond quick parse

classic Classic list List threaded Threaded
11 messages Options
Reply | Threaded
Open this post in threaded view
|

editor-lilypond quick parse

Aaron Mehl
Hi all,

Is there a way to not have to reparse a file each time
I want to view changes?

Something where only the newest changes are parsed or
the pdf is updated in almost realtime?

I am using vim.

Thanks
Aaron


               
____________________________________________________
Start your day with Yahoo! - make it your home page
http://www.yahoo.com/r/hs 
 


_______________________________________________
lilypond-user mailing list
[hidden email]
http://lists.gnu.org/mailman/listinfo/lilypond-user
Reply | Threaded
Open this post in threaded view
|

Re: editor-lilypond quick parse

Erik Sandberg
On Monday 22 August 2005 23.47, Aaron Mehl wrote:
> Hi all,
>
> Is there a way to not have to reparse a file each time
> I want to view changes?
>
> Something where only the newest changes are parsed or
> the pdf is updated in almost realtime?
>
> I am using vim.

If you're using 2.7, there is a command that helps this. From the announcement
of v2.7.2:

    * If `skipLastLength' is set, only the last few measures of a piece
      are rendered, which speeds up correcting scores. For example,
      setting


      showLastLength = R1*5
      \score { ... }

      will render only the last five measures (assuming 4/4 time
      signature) of a piece.

--
Erik


_______________________________________________
lilypond-user mailing list
[hidden email]
http://lists.gnu.org/mailman/listinfo/lilypond-user
Reply | Threaded
Open this post in threaded view
|

Re: editor-lilypond quick parse

Aaron Mehl
Hi again,

The problem  is that I am not entering new music but
correcting existing notation, so that there are
already 50 measures written and I just corrected
measure 4.
but maybe it will help, I will give it a try I guess
if I just pretend that there is no music after measure
5 whats the difference.

HOWever this isn't what I meant by realtime updates.
there should be a way to do this...

Aaron

--- Erik Sandberg <[hidden email]>
wrote:

> On Monday 22 August 2005 23.47, Aaron Mehl wrote:
> > Hi all,
> >
> > Is there a way to not have to reparse a file each
> time
> > I want to view changes?
> >
> > Something where only the newest changes are parsed
> or
> > the pdf is updated in almost realtime?
> >
> > I am using vim.
>
> If you're using 2.7, there is a command that helps
> this. From the announcement
> of v2.7.2:
>
> ? ? * If `skipLastLength' is set, only the last few
> measures of a piece
> ? ? ? are rendered, which speeds up correcting
> scores. For example,
> ? ? ? setting
>
>
> ? ? ? showLastLength = R1*5
> ? ? ? \score { ... }
>
> ? ? ? will render only the last five measures
> (assuming 4/4 time
> ? ? ? signature) of a piece.
>
> --
> Erik
>


__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around
http://mail.yahoo.com 


_______________________________________________
lilypond-user mailing list
[hidden email]
http://lists.gnu.org/mailman/listinfo/lilypond-user
Reply | Threaded
Open this post in threaded view
|

Re: editor-lilypond quick parse

Erik Sandberg
On Tuesday 23 August 2005 05.41, Aaron Mehl wrote:

> Hi again,
>
> The problem  is that I am not entering new music but
> correcting existing notation, so that there are
> already 50 measures written and I just corrected
> measure 4.
> but maybe it will help, I will give it a try I guess
> if I just pretend that there is no music after measure
> 5 whats the difference.
>
> HOWever this isn't what I meant by realtime updates.
> there should be a way to do this...

The problem is that lily is too slow, and that the formatter only can typeset
full scores. Han-Wen is aware of the problem, and sometimes work is done in
the direction of solving it.

--
Erik


_______________________________________________
lilypond-user mailing list
[hidden email]
http://lists.gnu.org/mailman/listinfo/lilypond-user
Reply | Threaded
Open this post in threaded view
|

Re: editor-lilypond quick parse

Bertalan Fodor
One good thing would be if the parser were separated: if I call
'lilypond --parse-only', it writes the parsing errors to the standard
output. Then it could be used to parse in the editor after some idle
time, underlining errors and warnings.

Bert

>The problem is that lily is too slow, and that the formatter only can typeset
>full scores. Han-Wen is aware of the problem, and sometimes work is done in
>the direction of solving it.
>
>  
>



_______________________________________________
lilypond-user mailing list
[hidden email]
http://lists.gnu.org/mailman/listinfo/lilypond-user
Reply | Threaded
Open this post in threaded view
|

Re: editor-lilypond quick parse

Erik Sandberg
On Tuesday 23 August 2005 10.08, Bertalan Fodor wrote:
> One good thing would be if the parser were separated: if I call
> 'lilypond --parse-only', it writes the parsing errors to the standard
> output. Then it could be used to parse in the editor after some idle
> time, underlining errors and warnings.

I'm working on it.

BTW, you could achieve the same effect by either
- using MIDI output (it's just about as fast)
or (more experimentally):
- \include a tweaked version of engraver-init.ly, where you replace all
occurences of \consists "..." with \consists "Swallow_engraver".

--
Erik


_______________________________________________
lilypond-user mailing list
[hidden email]
http://lists.gnu.org/mailman/listinfo/lilypond-user
Reply | Threaded
Open this post in threaded view
|

Re: editor-lilypond quick parse

Han-Wen Nienhuys
In reply to this post by Bertalan Fodor
Bertalan Fodor wrote:
> One good thing would be if the parser were separated: if I call
> 'lilypond --parse-only', it writes the parsing errors to the standard
> output. Then it could be used to parse in the editor after some idle
> time, underlining errors and warnings.
>

this functionality is already present. Just set the
toplevel-{music,book,text,score}-handler to nop-functions.

--
  Han-Wen Nienhuys - [hidden email] - http://www.xs4all.nl/~hanwen


_______________________________________________
lilypond-user mailing list
[hidden email]
http://lists.gnu.org/mailman/listinfo/lilypond-user
Reply | Threaded
Open this post in threaded view
|

Re: editor-lilypond quick parse

Bertalan Fodor

>
> this functionality is already present. Just set the
> toplevel-{music,book,text,score}-handler to nop-functions.
>
Well, I see I must be more exact. I need a way to find
not-layout-related problems. So bar check fails, clashing voices,
unfinished beams also should count. As Erik pointed out, leaving the
layout and the paper block out does what I need.

Bert


_______________________________________________
lilypond-user mailing list
[hidden email]
http://lists.gnu.org/mailman/listinfo/lilypond-user
Reply | Threaded
Open this post in threaded view
|

Re: editor-lilypond quick parse

Aaron Mehl
In reply to this post by Han-Wen Nienhuys


> this functionality is already present. Just set the
> toplevel-{music,book,text,score}-handler to
> nop-functions.

I don't understand. What does this do? and where and
how exactly do I set this?

Thanks
Aaron

__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around
http://mail.yahoo.com 


_______________________________________________
lilypond-user mailing list
[hidden email]
http://lists.gnu.org/mailman/listinfo/lilypond-user
Reply | Threaded
Open this post in threaded view
|

Re: editor-lilypond quick parse

Aaron Mehl
In reply to this post by Bertalan Fodor
Hi
could you send an example of how to do this?

thanks
Aaron

--- Bertalan Fodor <[hidden email]> wrote:

>
> >
> > this functionality is already present. Just set
> the
> > toplevel-{music,book,text,score}-handler to
> nop-functions.
> >
> Well, I see I must be more exact. I need a way to
> find
> not-layout-related problems. So bar check fails,
> clashing voices,
> unfinished beams also should count. As Erik pointed
> out, leaving the
> layout and the paper block out does what I need.
>
> Bert
>
>
> _______________________________________________
> lilypond-user mailing list
> [hidden email]
> http://lists.gnu.org/mailman/listinfo/lilypond-user
>


__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around
http://mail.yahoo.com 


_______________________________________________
lilypond-user mailing list
[hidden email]
http://lists.gnu.org/mailman/listinfo/lilypond-user
Reply | Threaded
Open this post in threaded view
|

Re: editor-lilypond quick parse

Bertalan Fodor
We could make the process much faster, if we could skip FontConfig
initalization.

What Han-Wen proposed was to write something like:

#(set! toplevel-score-handler (lambda p 0))

That way lilypond will only parse. Its backdraw is that it won't find
many typical typing errors (like unclosed beams/slurs, bar check failures).

The other way, using only midi output is achieved by commenting the
\paper {} and \layout {} blocks. So we get something like:

\score {

    ...my score comes here...

    \midi { }  

    % \layout { ...layout tweaks here... } % I commented this

}

% \paper {
%   ...paper settings come here...
% }

For the latter, I will extend the LilyPondTool for jEdit plugin, to
provide it.

Bert


_______________________________________________
lilypond-user mailing list
[hidden email]
http://lists.gnu.org/mailman/listinfo/lilypond-user