[LyX/master] New attempt on #9906: allow following hyperlinks via context menu.

Richard Kimberly Heck rikiheck at lyx.org
Mon Aug 17 16:19:35 UTC 2020


On 8/16/20 6:10 PM, Pavel Sanda wrote:
> On Sun, Aug 16, 2020 at 02:21:35PM -0400, Scott Kostyshak wrote:
>> On Sun, Aug 16, 2020 at 04:34:36PM +0200, Pavel Sanda wrote:
>>> On Sun, Aug 16, 2020 at 10:01:22AM -0400, Scott Kostyshak wrote:
>>>> I like that idea a lot and would personally find it helpful. Here is a
>>>> related request, although not many extra details:
>>>>
>>>>   https://www.mail-archive.com/search?l=mid&q=CAO7dr0jWBgOY8_ozNBQo4FuQpyFZACr1oQ8xzCs%2BnMNS-1Qt8Q%40mail.gmail.com
>>> This seems asking pretty much what is proposed in the first bullet point.
>>> Does your bibtex database contain full paths or they are relative to the document?
>>> Are the filename unique enough that using 'locate filename' would not return
>>> many false-positives (this is the way of my shell script).
>> My current workflow is that I use a cite key like lastname_year, and the
>> PDF file is lastname_year.pdf. The path, relative to the .bib file, is
>> currently ./pdfs/lastname_year.pdf. I currently use the following
>> directory structure:
>>
>>   paper.lyx
>>   lit/paper.bib
>>   lit/pdfs
>>
>> Scott
> Attached is updated patch.
> For a given citation it does:
> 1. check for existence of file= field in bib file, if found launch pdf viewer.
> 2. else check for existence of DOI/URL in bib file. If found launch browser with DOI/URL
> 3. else trigger external scirpt while giving author's name + year.
>
>
> There are several issues:
> a) file= field is not standard bibtex, as I understood it's specific for jabref,
>    which I do not use. Currenly it will work if full path is given but I have
>    no clue what to expect from jabref.

I see things like:

  file     =
{:/home/me/files/other_people/Antony/Antony-BeWhatISay.pdf:PDF},

but also

  file     = {:Antony-BeWhatISay.pdf:PDF},

if I put the file into the same directory as the bib file. So absolute
and relative paths are both possible. And you can also get something like:

  file     =
{:Antony-BeWhatISay.pdf:PDF;:/home/me/files/pdf/published/BirthOfSemantics-JHAP.pdf:PDF},

Here there are two options, separated by a semi-colon.

kbibtex uses a localfile field and allows you to choose between relative
and absolute paths. It also produces a semi-colon separated list of
files, such as:

localfile =
{/home/me/files/porn_studies/Rubin,Gayle/Rubin-ThinkingSex-Orig.djvu;
/home/me/files/porn_studies/Rubin,Gayle/Rubin-ThinkingSex.djvu},

I suspect there may be other options, as well, out there.

Riki




More information about the lyx-devel mailing list