From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/61484 Path: news.gmane.org!not-for-mail From: Wolfgang Schuster Newsgroups: gmane.comp.tex.context Subject: Re: Making checkboxes Date: Mon, 6 Sep 2010 20:29:51 +0200 Message-ID: References: <87vd6js07a.fsf@linux-lqcw.site> <87iq2jrszy.fsf@linux-lqcw.site> <203FFD4F-E46A-42A2-85C2-FA2550685B31@gmail.com> <87mxrvq9ma.fsf@linux-lqcw.site> <87aanurc06.fsf@linux-lqcw.site> Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 (Apple Message framework v1081) Content-Type: multipart/mixed; boundary="===============0000680396==" X-Trace: dough.gmane.org 1283797809 839 80.91.229.12 (6 Sep 2010 18:30:09 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Mon, 6 Sep 2010 18:30:09 +0000 (UTC) To: mailing list for ConTeXt users Original-X-From: ntg-context-bounces@ntg.nl Mon Sep 06 20:30:05 2010 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from balder.ntg.nl ([195.12.62.10]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1OsgSD-00061p-2n for gctc-ntg-context-518@m.gmane.org; Mon, 06 Sep 2010 20:30:05 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 72A2BCA682; Mon, 6 Sep 2010 20:30:03 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (balder.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id mz5uRyOO9t49; Mon, 6 Sep 2010 20:30:00 +0200 (CEST) Original-Received: from balder.ntg.nl (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 37B36CA640; Mon, 6 Sep 2010 20:30:00 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id A3FC4CA640 for ; Mon, 6 Sep 2010 20:29:58 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (balder.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id bfoMhEkJ4fjb for ; Mon, 6 Sep 2010 20:29:56 +0200 (CEST) Original-Received: from filter1-nij.mf.surf.net (filter1-nij.mf.surf.net [195.169.124.152]) by balder.ntg.nl (Postfix) with ESMTP id 2472FCA626 for ; Mon, 6 Sep 2010 20:29:56 +0200 (CEST) Original-Received: from mail-fx0-f41.google.com (mail-fx0-f41.google.com [209.85.161.41]) by filter1-nij.mf.surf.net (8.14.3/8.14.3/Debian-5+lenny1) with ESMTP id o86ITtWh015223 for ; Mon, 6 Sep 2010 20:29:55 +0200 Original-Received: by fxm3 with SMTP id 3so3231702fxm.14 for ; Mon, 06 Sep 2010 11:29:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=gamma; h=domainkey-signature:received:received:from:mime-version :content-type:subject:date:in-reply-to:to:references:message-id :x-mailer; bh=tafqhphRhGo2GDEYSxY1xfw6gafwEMRNTS/hd8xxbx8=; b=Wo+PAKcwUSH2sxNVTowHXueUiXJRCWQ/9H2sD//Z6X5GIOauw0LWdyBh7P+uxh2c8f daG+NpOZKh+JuK7pR6XozpLNEJgfDd6XYVlMm62RUA+HvY8FEMINie25gEaZ0OZenvb7 3oACDS/M1dIe/t2JdbgezAQyLOZwHUtllFVqI= DomainKey-Signature: a=rsa-sha1; c=nofws; d=googlemail.com; s=gamma; h=from:mime-version:content-type:subject:date:in-reply-to:to :references:message-id:x-mailer; b=BuBPV2awnhFgWT8jg8TZqznZ72JvntRmGAlmrUp26fsvybBjgXeM5wppEn2FKzRwuD 28oDHiwFTN6/TFrciv95l5H5IxKWC/S/hURf+A5OqmxcH7XbEKb2d871l4y6OG1kO9Vd XwJCxaVnJn7YYdhr8K68fql8vh99uixPsb9jA= Original-Received: by 10.223.108.71 with SMTP id e7mr404203fap.13.1283797794866; Mon, 06 Sep 2010 11:29:54 -0700 (PDT) Original-Received: from [192.168.2.23] (p5B2952C9.dip.t-dialin.net [91.41.82.201]) by mx.google.com with ESMTPS id b9sm2448869faq.7.2010.09.06.11.29.52 (version=TLSv1/SSLv3 cipher=RC4-MD5); Mon, 06 Sep 2010 11:29:53 -0700 (PDT) In-Reply-To: <87aanurc06.fsf@linux-lqcw.site> X-Mailer: Apple Mail (2.1081) X-Bayes-Prob: 0.0001 (Score 0, tokens from: @@RPTN) X-CanIt-Geo: ip=209.85.161.41; country=US; region=CA; city=Mountain View; postalcode=94043; latitude=37.4192; longitude=-122.0574; metrocode=807; areacode=650; http://maps.google.com/maps?q=37.4192,-122.0574&z=6 X-CanItPRO-Stream: uu:ntg-context@ntg.nl (inherits from uu:default, base:default) X-Canit-Stats-ID: 07D3utTEv - d000b0484a30 - 20100906 X-Scanned-By: CanIt (www . roaringpenguin . com) on 195.169.124.152 X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.12 Precedence: list List-Id: mailing list for ConTeXt users List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: ntg-context-bounces@ntg.nl Errors-To: ntg-context-bounces@ntg.nl Xref: news.gmane.org gmane.comp.tex.context:61484 Archived-At: --===============0000680396== Content-Type: multipart/alternative; boundary=Apple-Mail-1-547913442 --Apple-Mail-1-547913442 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=us-ascii Am 06.09.2010 um 19:57 schrieb Cecil Westerhof: > I start to understand it. Thanks. >=20 > I changed it a little. I implemented 'title'. And with startitemize I > got empty space between my 'title' and the checkboxes. The blank line comes from itemize, you can get rid of it with = \startitemize[joinedup]. > So I coded it > like: > \def\CheckBoxes[#1,#2]% > {#1\par > \processcommalist[#2]\doCheckBoxes > } >=20 > [...] >=20 > Is there a way that I do not need al the '\blank' lines. After a > checkbox list, I always want an empty line. Add \blank at the begin and end of your macro: \def\CheckBoxes[#1][#2]% {\blank #1\par \processcommalist[#2]\... \blank} I wonder why need this command when can get the same result with normal = context commands: \definesymbol[checkbox][{[~~~]}] \defineitemgroup[checkbox] = \setupitemgroup[checkbox][each][packed][margin=3D2.5em,symbol=3Dcheckbox,w= idth=3D1.5em,distance=3D.5em] \starttext \startcheckbox \nop title \item Yes \item No \item A little bit \stopcheckbox \stoptext Wolfgang --Apple-Mail-1-547913442 Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset=us-ascii
I = start to understand it. Thanks.

I changed it a little. I = implemented 'title'. And with startitemize I
got empty space between = my 'title' and the checkboxes.

The = blank line comes from itemize, you can get rid of it with = \startitemize[joinedup].

So I = coded it
like:
   \def\CheckBoxes[#1,#2]%
=     {#1\par
=      \processcommalist[#2]\doCheckBoxes
=     }

[...]

Is there a way that I do not need al the '\blank' = lines. After a
checkbox list, I always want an empty = line.

Add \blank at the begin and = end of your = macro:

\def\CheckBoxes[#1][#2]%
 &= nbsp;{\blank
   #1\par
   = \processcommalist[#2]\...
   = \blank}

I wonder why need this command when can = get the same result with normal context = commands:

\definesymbol[checkbox][{[~~~]}]
\defineitemgroup[checkbox]
\setupitemgroup[checkbox][ea= ch][packed][margin=3D2.5em,symbol=3Dcheckbox,width=3D1.5em,distance=3D.5em= ]

\starttext

\startcheck= box
\nop title
\item Yes
\item = No
\item A little = bit
\stopcheckbox

\stoptext
=

Wolfgang

= --Apple-Mail-1-547913442-- --===============0000680396== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline ___________________________________________________________________________________ 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://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________ --===============0000680396==--