[icon]

GNU LilyPond

Welcome to the home of the GNU Music Typesetter

What is LilyPond
General information
Simple examples
Complex examples
Download
GNU/Linux binaries
Windows
Source code
Documentation
Tutorial
Manual
Glossary
other ...

Support
Mailing lists
Search
WikiWiki
FAQs

External sites
lilypond.org/development
lilypond.org/stable
ftp.lilypond.org
Mutopia
Other music online

Node:Point and click, Previous:Bar check, Up:Music entry



Point and click

Point and click lets you find notes in the input by clicking on them in the Xdvi window. This makes it very easy to find input that causes some error in the sheet music.

To use it, you need the following software

Installation

  • plain Xdvi version 22.36 or newer.

    Note that most TeX distributions ship with xdvik, which is a different and less well maintained program. To find out which xdvi you are running, try xdvi --version or xdvi.bin --version.

  • emacs

Xdvi must be configured to find the TeX fonts and music fonts. Refer to the Xdvi documentation for more information.

Using it

Add one of these lines to the top of your .ly file. The first one is for line location only. The second one is more convenient, but requires patching emacsclient and server.el.

#(set! point-and-click line-location)

In the emacs startup file (usually ~/.emacs), add the following

(server-start)

Make sure that the environment variable XEDITOR is set to

emacsclient --no-wait +%l %f
The second one, that also specifies the column, only works if you have patched your emacsclient and server, and have compiled your .ly file using the line-column-location setting.

When viewing, control-mousebutton 1 will take you to the originating spot in the .ly file. Control-mousebutton 2 will show all clickable boxes.

Column location

If you want emacs to jump to the exact spot (and not just the line) on a click, you must enable column positioning. To do so, you need to patch emacsclient. Apply emacsclient.patch (included with the source package) to emacsclient.c and server.el from the emacs source code. Recompile and stick the recompiled emacsclient into a bin directory, and put server.el into a elisp directory (e.g. ~/usr/share/emacs/). Add the following to your .emacs init file, before invoking server-start.

 (setq load-path (cons "~/usr/share/emacs" load-path))

Set XEDITOR to emacsclient --no-wait +%l:%c %f

At the top of the ly file, replace the set! line with the following line

#(set! point-and-click line-column-location)

BUGS

When you convert the TeX file to PostScript using dvips, it will complain about not finding src:X:Y files. Those complaints are harmless, and can be ignored.

When using line-column-location, the cursor will be one off; it will not jump to the exact note that you clicked, but to the next one.

[FIXME]

Go back to index of LilyPond.

Please send GNU LilyPond questions and comments to lilypond-user@gnu.org.

Please send comments on these web pages to lilypond@packages.debian.org

Copyright (c) 1997--2001 Han-Wen Nienhuys and Jan Nieuwenhuizen.

Verbatim copying and distribution of this entire article is permitted in any medium, provided this notice is preserved.


This page was built from LilyPond-1.4.12 (stable-branch) by

Anthony Fok <lilypond@packages.debian.org>, Tue Mar 12 01:35:39 2002 HKT.