@node Point and click @appendix Point and click @cindex point and click Point and click lets you find notes in the input by clicking on them in the PDF viewer. This makes it easier to find input that causes some error in the sheet music. When this functionality is active, LilyPond adds hyperlinks to the PDF file. These hyperlinks are sent to the web-browser, which opens a text-editor with the cursor in the right place. To make this chain work, the following should done: @itemize @bullet @item The PDF viewer must be configured for following hyperlinks, preferably using Mozilla Firefox. For Xpdf on Unix, the following should be present in @file{xpdfrc}@footnote{On unix, this file is found either in @file{/etc/xpdfrc} or as @file{.xpdfrc} in your home directory.} @example urlCommand "firefox -remote 'OpenURL(%s)'" @end example @item Your web-browser must be configured for the @code{textedit} protocol, For Mozilla and Mozilla Firefox, this is done by adding following lines to the @file{user.js}@footnote{On a typical unix system, this file exists or must be created in your home-directory as @file{.mozilla/firefox/default.trn/user.js} or @file{.firefox/default/xxxxxxxx.xxx/user.js}, see @uref{http://@/www@/.mozilla@/.org@/support@/firefox@/edit#user,location} and @uref{http://@/www@/.mozilla@/.org@/support@/firefox@/edit#profile,profile}.} @ignore mozilla wants us do store this in user.js: location on different systems: @end ignore @example user_pref("network.protocol-handler.app.textedit", "lilypond-invoke-editor"); user_pref("network.protocol-handler.warn-external.textedit", false); @end example @end itemize The program @file{lilypond-invoke-editor} is a small helper program. It tests the environment variable @code{EDITOR} for the following patterns, @table @code @item emacs this will invoke @example emacsclient --no-wait +@var{line}:@var{column} @var{file} @end example @item vim this will invoke @example gvim --remote +:@var{line}:norm@var{char} @var{file} @end example @item nedit this will invoke @example nc -noask +@var{line} @var{file}' @end example @end table The environment variable @code{LYEDITOR} is used to override this. It contains the command line to start the editor, where @code{%(file)s}, @code{%(column)s}, @code{%(line)s} is replaced with the file, column and line respectively. The setting @example emacsclient --no-wait +%(line)s:%(column)s %(file)s @end example @noindent for @code{LYEDITOR} is equivalent to the standard emacsclient invocation. @cindex file size, output The point and click links enlarge the output files significantly. For reducing the size of PDF and PS files, point and click may be switched off by issuing @example #(ly:set-option 'point-and-click #f) @end example @noindent in a @file{.ly} file. Alternately, you may pass this as an command-line option @example lilypond -dno-point-and-click file.ly @end example