ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* useexternaldocument with custom file type
@ 2020-04-23  9:54 Jan U. Hasecke
  2020-04-23 10:06 ` Wolfgang Schuster
  0 siblings, 1 reply; 9+ messages in thread
From: Jan U. Hasecke @ 2020-04-23  9:54 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Hi,

can I link to a file with custom file type eg. OpenDocument with
\useexternaldocument?

This does not work.

\useexternaldocument[test][test.ods][A test document]

As the PDF viewer is opened first, it does not recognize the file type.

juh
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki     : http://contextgarden.net
___________________________________________________________________________________

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: useexternaldocument with custom file type
  2020-04-23  9:54 useexternaldocument with custom file type Jan U. Hasecke
@ 2020-04-23 10:06 ` Wolfgang Schuster
  2020-04-23 10:21   ` Jan U. Hasecke
  0 siblings, 1 reply; 9+ messages in thread
From: Wolfgang Schuster @ 2020-04-23 10:06 UTC (permalink / raw)
  To: mailing list for ConTeXt users, Jan U. Hasecke

Jan U. Hasecke schrieb am 23.04.2020 um 11:54:
> Hi,
> 
> can I link to a file with custom file type eg. OpenDocument with
> \useexternaldocument?
> 
> This does not work.
> 
> \useexternaldocument[test][test.ods][A test document]
> 
> As the PDF viewer is opened first, it does not recognize the file type.

The \useexternaldocument is used to access referecens from other ConTeXt 
documents.

https://mailman.ntg.nl/pipermail/ntg-context/2019/095564.html

Wolfgang
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki     : http://contextgarden.net
___________________________________________________________________________________

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: useexternaldocument with custom file type
  2020-04-23 10:06 ` Wolfgang Schuster
@ 2020-04-23 10:21   ` Jan U. Hasecke
  2020-04-23 12:22     ` Vladimir Lomov
  0 siblings, 1 reply; 9+ messages in thread
From: Jan U. Hasecke @ 2020-04-23 10:21 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Hi Wolfgang,

thanks for the fast reply.

Am 23.04.20 um 12:06 schrieb Wolfgang Schuster:
> Jan U. Hasecke schrieb am 23.04.2020 um 11:54:
>> Hi,
>>
>> can I link to a file with custom file type eg. OpenDocument with
>> \useexternaldocument?
>>
>> This does not work.
>>
>> \useexternaldocument[test][test.ods][A test document]
>>
>> As the PDF viewer is opened first, it does not recognize the file type.
> 
> The \useexternaldocument is used to access referecens from other ConTeXt
> documents.

Ok. No way to link to other file types from the pdf?

> https://mailman.ntg.nl/pipermail/ntg-context/2019/095564.html

I must confess that I don't understand this utilitydata-Thread.


juh
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki     : http://contextgarden.net
___________________________________________________________________________________

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: useexternaldocument with custom file type
  2020-04-23 10:21   ` Jan U. Hasecke
@ 2020-04-23 12:22     ` Vladimir Lomov
  2020-04-23 13:35       ` Jan U. Hasecke
  0 siblings, 1 reply; 9+ messages in thread
From: Vladimir Lomov @ 2020-04-23 12:22 UTC (permalink / raw)
  To: mailing list for ConTeXt users


[-- Attachment #1.1: Type: text/plain, Size: 1102 bytes --]

Hello,
** Jan U. Hasecke <juh+ntg-context@mailbox.org> [2020-04-23 12:21:27 +0200]:

> Hi Wolfgang,

> thanks for the fast reply.

> Am 23.04.20 um 12:06 schrieb Wolfgang Schuster:
>> Jan U. Hasecke schrieb am 23.04.2020 um 11:54:
>>> Hi,
>>>
>>> can I link to a file with custom file type eg. OpenDocument with
>>> \useexternaldocument?
>>>
>>> This does not work.
>>>
>>> \useexternaldocument[test][test.ods][A test document]
>>>
>>> As the PDF viewer is opened first, it does not recognize the file type.
>> 
>> The \useexternaldocument is used to access referecens from other ConTeXt
>> documents.

> Ok. No way to link to other file types from the pdf?

May be you after this one 
https://wiki.contextgarden.net/Command/goto
?

Otherwise could you describe what exactly you want to achive?

>> https://mailman.ntg.nl/pipermail/ntg-context/2019/095564.html

> I must confess that I don't understand this utilitydata-Thread.


> juh

---
WBR, Vladimir Lomov

-- 
He asked me if I knew what time it was -- I said yes, but not right now.
		-- Steven Wright

[-- Attachment #1.2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]

[-- Attachment #2: Type: text/plain, Size: 493 bytes --]

___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki     : http://contextgarden.net
___________________________________________________________________________________

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: useexternaldocument with custom file type
  2020-04-23 12:22     ` Vladimir Lomov
@ 2020-04-23 13:35       ` Jan U. Hasecke
  2020-04-23 14:10         ` Vladimir Lomov
  0 siblings, 1 reply; 9+ messages in thread
From: Jan U. Hasecke @ 2020-04-23 13:35 UTC (permalink / raw)
  To: ntg-context

Am 23.04.20 um 14:22 schrieb Vladimir Lomov:
> Otherwise could you describe what exactly you want to achive?

This works:

\setupinteraction[state=start]
\setupcolors[state=start]
\starttext
\goto{linkname}[file(target.pdf)]
\stoptext

This does not work:

\setupinteraction[state=start]
\setupcolors[state=start]
\starttext
\goto{linkname}[file(target.doc)]
\stoptext

The PDF Viewer does not support the file type.

TIA
juh
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki     : http://contextgarden.net
___________________________________________________________________________________

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: useexternaldocument with custom file type
  2020-04-23 13:35       ` Jan U. Hasecke
@ 2020-04-23 14:10         ` Vladimir Lomov
  2020-04-23 14:36           ` Jan U. Hasecke
  0 siblings, 1 reply; 9+ messages in thread
From: Vladimir Lomov @ 2020-04-23 14:10 UTC (permalink / raw)
  To: mailing list for ConTeXt users


[-- Attachment #1.1: Type: text/plain, Size: 1330 bytes --]

Hello,
** Jan U. Hasecke <juh+ntg-context@mailbox.org> [2020-04-23 15:35:54 +0200]:

> Am 23.04.20 um 14:22 schrieb Vladimir Lomov:

>> Otherwise could you describe what exactly you want to achive?

> This works:

> \setupinteraction[state=start]
> \setupcolors[state=start]
> \starttext
> \goto{linkname}[file(target.pdf)]
> \stoptext

> This does not work:

> \setupinteraction[state=start]
> \setupcolors[state=start]
> \starttext
> \goto{linkname}[file(target.doc)]
> \stoptext

What do you mean "work" and "not work"?

Do you what to open a file by clicking on text in viewer? What application
should be used to open a file? Take a look on page I linked in previous
message.

> The PDF Viewer does not support the file type.

What "PDF Viewer"?

For example, I use different viewers: mupdf, zathura-pdf-mupdf (zathura with
mupdf pdf backend), okular, pdf-tools (emacs major mode). Some of application
(okular, for example) could preview many file types (ps, pdf, odt), while
other can't do that. It is up to application what to do (or actually, PDF
backend) on link.

Please see the page about '\goto' command, it was written for a reason!

> TIA
> juh

---
WBR, Vladimir Lomov

-- 
Virtue is not left to stand alone.  He who practices it will have neighbors.
		-- Confucius

[-- Attachment #1.2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]

[-- Attachment #2: Type: text/plain, Size: 493 bytes --]

___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki     : http://contextgarden.net
___________________________________________________________________________________

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: useexternaldocument with custom file type
  2020-04-23 14:10         ` Vladimir Lomov
@ 2020-04-23 14:36           ` Jan U. Hasecke
  2020-04-23 17:25             ` Henning Hraban Ramm
  0 siblings, 1 reply; 9+ messages in thread
From: Jan U. Hasecke @ 2020-04-23 14:36 UTC (permalink / raw)
  To: ntg-context

Am 23.04.20 um 16:10 schrieb Vladimir Lomov:
> Please see the page about '\goto' command, it was written for a reason!

Ok, with \goto{linkname}[program(target.doc)] it works.

"works" means some PDF Viewers opens the right program.


juh
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki     : http://contextgarden.net
___________________________________________________________________________________

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: useexternaldocument with custom file type
  2020-04-23 14:36           ` Jan U. Hasecke
@ 2020-04-23 17:25             ` Henning Hraban Ramm
  2020-04-23 17:48               ` Jan U. Hasecke
  0 siblings, 1 reply; 9+ messages in thread
From: Henning Hraban Ramm @ 2020-04-23 17:25 UTC (permalink / raw)
  To: mailing list for ConTeXt users


> Am 23.04.2020 um 16:36 schrieb Jan U. Hasecke <juh+ntg-context@mailbox.org>:
> 
> Am 23.04.20 um 16:10 schrieb Vladimir Lomov:
>> Please see the page about '\goto' command, it was written for a reason!
> 
> Ok, with \goto{linkname}[program(target.doc)] it works.
> 
> "works" means some PDF Viewers opens the right program.


In the beginning, you could even start programs with program(...), but Adobe recognized soon this might be a security problem.

Nowadays, the “best” behaviour is when the viewer asks you if you really want to open such a link but then hands control to the OS.

Last time I checked, Adobe Reader even let you open hidden files from arbitrary paths.

Several other viewers just do nothing.

Best, Hraban
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki     : http://contextgarden.net
___________________________________________________________________________________

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: useexternaldocument with custom file type
  2020-04-23 17:25             ` Henning Hraban Ramm
@ 2020-04-23 17:48               ` Jan U. Hasecke
  0 siblings, 0 replies; 9+ messages in thread
From: Jan U. Hasecke @ 2020-04-23 17:48 UTC (permalink / raw)
  To: ntg-context

Am 23.04.20 um 19:25 schrieb Henning Hraban Ramm:
> 
>> Am 23.04.2020 um 16:36 schrieb Jan U. Hasecke <juh+ntg-context@mailbox.org>:
>>
>> Am 23.04.20 um 16:10 schrieb Vladimir Lomov:
>>> Please see the page about '\goto' command, it was written for a reason!
>>
>> Ok, with \goto{linkname}[program(target.doc)] it works.
>>
>> "works" means some PDF Viewers opens the right program.
> 
> 
> In the beginning, you could even start programs with program(...), but Adobe recognized soon this might be a security problem.
> 
> Nowadays, the “best” behaviour is when the viewer asks you if you really want to open such a link but then hands control to the OS.
> 
> Last time I checked, Adobe Reader even let you open hidden files from arbitrary paths.
> 
> Several other viewers just do nothing.

Yes this is not bullet proofed but I need it for internal usage. I think
we'll have many okular users.

juh

___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki     : http://contextgarden.net
___________________________________________________________________________________

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2020-04-23 17:48 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-04-23  9:54 useexternaldocument with custom file type Jan U. Hasecke
2020-04-23 10:06 ` Wolfgang Schuster
2020-04-23 10:21   ` Jan U. Hasecke
2020-04-23 12:22     ` Vladimir Lomov
2020-04-23 13:35       ` Jan U. Hasecke
2020-04-23 14:10         ` Vladimir Lomov
2020-04-23 14:36           ` Jan U. Hasecke
2020-04-23 17:25             ` Henning Hraban Ramm
2020-04-23 17:48               ` Jan U. Hasecke

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).