16 Sep
2024
16 Sep
'24
10:30 a.m.
Am 16.09.24 um 11:41 schrieb Hans van der Meer via ntg-context:
\button is defined to jump to a given reference. However, I would like to place a button that can execute a macro to be defined by myself. Thus for example pushing the button \executebutton{text}{macro} will execute that macro.
Is this available somewhere in ConTeXT? If not, can it be provided in a future update?
Did you try \button[Options]{Something}[YourJSFunction] ? I don’t know it that’s limited to a few predefined functions. see https://wiki.contextgarden.net/Widgets#JavaScript and https://source.contextgarden.net/scrn-but.mkvi Just to be sure: You understand that this works via JavaScript in the viewer, only supported by Acrobat and PDF Studio? Hraban