lilypond-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Lilypond PDF links in TexShop (Mac OS)


From: Michael Seifert
Subject: Re: Lilypond PDF links in TexShop (Mac OS)
Date: Tue, 4 Aug 2020 20:49:00 -0400

        Hello everyone,

        I can confirm that once I removed the spaces from the directory path, 
the point-and-click instructions included with the TeXShop LilyPond engine did 
in fact work.  Just wanted to include that information in the mailing list 
archives for posterity.

        Thanks to all of you for your assistance!

        Mike

> On Aug 3, 2020, at 1:50 PM, Michael Seifert <mseifert@gmail.com> wrote:
> 
> So I’ve made progress here, mainly because Jacques asked me how to get the 
> LilyPond Engine installed in TeXShop, which prompted me to go back and 
> RTFreadme.
> 
> Inside the TeXShop Package (Contents>Resources>TeXShop>Engines) there is an 
> “Inactive” directory.  If you look inside there, you’ll see a 
> LilyPondEngines-2.1.0b directory, with LilyPond.engine and 
> LilyPond-Book.engine inside.  Move those from the Inactive directory up to 
> the Engines directory, restart TeXShop, and you’ll have LilyPond and 
> LilyPond-Book alongside all of your other engines in TeXShop (LaTeX, XeTeX, 
> BibTeX, etc.)
> 
> Also inside that LilyPond engines directory is a README.txt file, which 
> actually has instructions on how to enable point-and-click!  (Federico, take 
> note.)  I’ll just copy and paste the instructions here:
> 
> 1. Install the SwiftDefaultApps pref pane from 
> https://github.com/Lord-Kamina/SwiftDefaultApps
> 2. Open GotoTeXShop.applescript in Script Editor. [also included in the 
> LilyPond engines directory] 
> 3. Go to File > Export…
> 4. Choose Application as the File Format.
> 5. Save GotoTeXShop.app.
> 6. Go to the SwiftDefaultApps pref pane and choose GotoTeXShop.app as the
>   handler for textedit URI Schemes.
> 
> I did all of this, and now at least a signal is being sent to TeXShop, 
> because TeXShop responds with
> 
>       "The document “Test_code.ly” could not be opened. The file doesn’t 
> exist.”
> 
> I suspect this is because I have a space in my username (unintentionally, 
> long story) and in the directory path.  These are rendered as %20 in the 
> textedit URIs, but which TeXShop/AppleScript expects to be escaped spaces.  
> I’ll try changing my username & renaming the problematic directories later 
> this evening, and I'll see if that makes a difference.
> 
>       (Also, if I’m reading the provided AppleScript correctly, it looks like 
> TeXShop will go to the correct line, but not the correct character.  That’s 
> still fairly helpful, though.)
> 
>       Mike
> 
> 
>> On Aug 3, 2020, at 12:57 PM, Jacques Menu <imj-muzhic@bluewin.ch> wrote:
>> 
>> Mike,
>> 
>> How do compile the .ly file from TeXShop? I’ve never done that, always using 
>> Frescobaldi.
>> 
>> JM
>> 
>> 
>> 
>>> Le 3 août 2020 à 14:35, Michael Seifert <mseifert@gmail.com> a écrit :
>>> 
>>>     Dear Jacques,
>>> 
>>>     The attached .ly file produces the attached PDF when typeset on my 
>>> machine.  Clicking on any one of the note heads then opens the Lilypond 
>>> editor with the appropriate string highlighted;  I want it to open the file 
>>> in TeXShop instead.
>>> 
>>>     I’ve included the PDF that my system generated in case you or someone 
>>> might spot a malformed link or something like that.  The links in the 
>>> attached PDF probably won’t work for you (or anyone else), since they 
>>> contain explicit reference to my user directory on my local machine.  
>>> You’ll have to re-typeset the file on your machine to get the links to 
>>> point to the appropriate filename.  
>>> 
>>>     Thanks for your assistance,
>>> 
>>>     Mike
>>> 
>>> <Test_code.ly>
>>> <Test_code.pdf>
>>>> On Aug 3, 2020, at 4:08 AM, Jacques Menu <imj-muzhic@bluewin.ch> wrote:
>>>> 
>>>> Hello Mike,
>>>> 
>>>> I’d need a sample file to check the PDF links.
>>>> 
>>>> JM
>>>> 
>>>>> Le 2 août 2020 à 22:57, Michael Seifert <mseifert@gmail.com> a écrit :
>>>>> 
>>>>>   Dear Jacques,
>>>>> 
>>>>>   TeXShop is already the default application for .ly files on my system.  
>>>>> Double-clicking on an .ly file in the finder opens it in TeXShop;  but 
>>>>> clicking on the link in the PDF within TeXShop opens up LilyPond.  
>>>>>   Are you saying that the PDF links open TexShop on your system?  If so, 
>>>>> that gives me hope that this is possible after all.
>>>>> 
>>>>>   Take care,
>>>>> 
>>>>>   Mike
>>>>> 
>>>>> 
>>>>> 
>>>>>> On Aug 2, 2020, at 4:52 PM, Jacques Menu <imj-muzhic@bluewin.ch> wrote:
>>>>>> 
>>>>>> Hello Michaël,
>>>>>> 
>>>>>> How about selecting a .ly file in the Finder, Cmd-I to access the file 
>>>>>> info, and change to TeXShop to open it, as well as all the .ly files?
>>>>>> 
>>>>>> Works here.
>>>>>> 
>>>>>> JM
>>>>>> 
>>>>>>> Le 2 août 2020 à 17:24, Michael Seifert <mseifert@gmail.com> a écrit :
>>>>>>> 
>>>>>>>         This is more of a LilyPond-adjacent question, but I figured I’d 
>>>>>>> see if anyone had any ideas:
>>>>>>> 
>>>>>>>         I’m currently using TeXShop 4.44 under Mac OS Catalina to edit 
>>>>>>> & compile my LilyPond code.  The resulting PDFs contain links of the 
>>>>>>> form “textedit:///Users/...” which direct back to the appropriate spots 
>>>>>>> in the source code.  However, clicking on these links opens the source 
>>>>>>> code in the stand-alone LilyPond app, rather than staying in TeXShop.  
>>>>>>> 
>>>>>>>         Is there a way to get these links to open within TeXShop, 
>>>>>>> rather than in the LilyPond editor app?
>>>>>>> 
>>>>>>>         Mike Seifert
>>>>>>>         Quaker Hill, CT, USA
>>>>>> 
>>>>> 
>>>> 
>>> 
>> 
> 




reply via email to

[Prev in Thread] Current Thread [Next in Thread]