ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: "Jan-Erik Hägglöf via ntg-context" <ntg-context@ntg.nl>
To: mailing list for ConTeXt users <ntg-context@ntg.nl>
Cc: "Jan-Erik Hägglöf" <skrantajanneman@gmail.com>
Subject: Re: Interactive checkbox in ConTeXt
Date: Sun, 22 May 2022 10:47:19 +0200	[thread overview]
Message-ID: <58C1857A-AB26-41F1-A93F-A00C56443981@gmail.com> (raw)
In-Reply-To: <149f0dcb-1545-255b-7785-4cdc67eac1a2@fiee.net>

Thank you for the useful tip.

I’ve tested the example given below but ran into missing figure, maybe I need to reconstruct the MetaPost file as mentioned in setup. Se attached example:

Thanks in advance!

/Jan-Erik

\setupinteraction[state=start]
\setupexternalfigures[location=global]

\definesymbol [yes] [{\externalfigure[mp-cont.502]}]
\definesymbol [no] []


\setupfield
[setup 3]
[width=2cm, height=2cm,
rulethickness=3pt, corner=round, framecolor=red]

\definefield [check-me] [check] [setup 3] [yes,no] [no]

\starttext
\field[check-me]
\stoptext

> 20 maj 2022 kl. 12:28 skrev Henning Hraban Ramm via ntg-context <ntg-context@ntg.nl>:
> 
> Am 20.05.22 um 12:01 schrieb Jan-Erik Hägglöf via ntg-context:
>> How do I accomplish a similar funktion like this, that is written in latex, but in context instead?
>> LATEXCODE
>> |\documentclass{article} \usepackage{hyperref} \begin{document} \begin{Form} \CheckBox[name=mycheckbox,checkboxsymbol=\ding{53}]{This is a check box:} \end{Form} \end{document}|
> 
> Have a look at https://wiki.contextgarden.net/Widgets and the "mwidget" manual.
> 
> Custom symbols work unreliably, depending of the viewer.
> 
> 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
> ___________________________________________________________________________________

___________________________________________________________________________________
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
___________________________________________________________________________________

  reply	other threads:[~2022-05-22  8:47 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-05-20 10:01 Jan-Erik Hägglöf via ntg-context
2022-05-20 10:28 ` Henning Hraban Ramm via ntg-context
2022-05-22  8:47   ` Jan-Erik Hägglöf via ntg-context [this message]
2022-05-22 10:27     ` Jan-Erik Hägglöf via ntg-context

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=58C1857A-AB26-41F1-A93F-A00C56443981@gmail.com \
    --to=ntg-context@ntg.nl \
    --cc=skrantajanneman@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).