From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/54331 Path: news.gmane.org!not-for-mail From: Wolfgang Schuster Newsgroups: gmane.comp.tex.context Subject: itemize / text indent Date: Sun, 15 Nov 2009 10:46:32 +0100 Message-ID: Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 (Apple Message framework v1077) Content-Type: multipart/mixed; boundary=Apple-Mail-3-798318323 X-Trace: ger.gmane.org 1258278417 24570 80.91.229.12 (15 Nov 2009 09:46:57 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 15 Nov 2009 09:46:57 +0000 (UTC) To: mailing list for ConTeXt users Original-X-From: ntg-context-bounces@ntg.nl Sun Nov 15 10:46:50 2009 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.50) id 1N9bh2-0004n3-NW for gctc-ntg-context-518@m.gmane.org; Sun, 15 Nov 2009 10:46:48 +0100 Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id D1020C9AE3; Sun, 15 Nov 2009 10:44:32 +0100 (CET) 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 wq8L7Q0i6w9J; Sun, 15 Nov 2009 10:44:29 +0100 (CET) Original-Received: from balder.ntg.nl (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id B365AC9A9C; Sun, 15 Nov 2009 10:44:29 +0100 (CET) Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 64C07C9AB7 for ; Sun, 15 Nov 2009 10:44:26 +0100 (CET) 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 CsFOSk3TVilT for ; Sun, 15 Nov 2009 10:44:22 +0100 (CET) Original-Received: from mail-bw0-f220.google.com (mail-bw0-f220.google.com [209.85.218.220]) by balder.ntg.nl (Postfix) with ESMTP id 49AEEC9A70 for ; Sun, 15 Nov 2009 10:44:22 +0100 (CET) Original-Received: by bwz20 with SMTP id 20so4745884bwz.34 for ; Sun, 15 Nov 2009 01:46:35 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=gamma; h=domainkey-signature:received:received:from:content-type:subject :date:message-id:to:mime-version:x-mailer; bh=DmEjaAkrPQ5D5CaKDPLWHHe0jvNK5SowVw8eSwIGu3k=; b=ithHBJjFGDNc1Xs8vpWtgQc6hI1NqiUhLw3yAmg9Z7xSkAJ9NGxKwzPES4s0VJfGgk ZcRZcBsxNXYhbXCq3/TJq1bVtcaQ9uozv7jsZSQqtuW7zX1WaOcIudxZi64cTBpLtXJO wDX9jy/3E3FEayK55ZZMUYFi5Nwbu/bYTnBNs= DomainKey-Signature: a=rsa-sha1; c=nofws; d=googlemail.com; s=gamma; h=from:content-type:subject:date:message-id:to:mime-version:x-mailer; b=wVrXgTXwW0fRtWDJooFDwS9JwVegFDlfX74N8PGDy44ELdky8kX2p7JrKttVnroQy6 IyuVpG4SL85DtxtnapmCsklcPkbDqBhYDavODL3vlyQWhlBSJIPPGgyGQq/r4ZEwuidJ 9S8jkwPRWFxUXjqOy+KpuZRpYHVvR9/jV5k94= Original-Received: by 10.204.32.209 with SMTP id e17mr4394697bkd.84.1258278395447; Sun, 15 Nov 2009 01:46:35 -0800 (PST) Original-Received: from ?192.168.2.23? (p5B297F41.dip.t-dialin.net [91.41.127.65]) by mx.google.com with ESMTPS id 14sm402676fxm.3.2009.11.15.01.46.33 (version=TLSv1/SSLv3 cipher=RC4-MD5); Sun, 15 Nov 2009 01:46:34 -0800 (PST) X-Mailer: Apple Mail (2.1077) 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:54331 Archived-At: --Apple-Mail-3-798318323 Content-Disposition: attachment; filename=1.tex Content-Type: application/octet-stream; name="1.tex" Content-Transfer-Encoding: 7bit \unprotected\def\complexdoitemgroupitem[#1]% {\def\currentitemreference{#1}% \ifconditional\textlistitem % begin of item \else \par \fi \ifconditional\concatnextitem % new, concat \noitembreak % new, concat \fi % new, concat \doadvanceitem \ifconditional\firstlistitem \setfalse\firstlistitem \begingroup \ifcase\currentitemlevel \or % 1 \ifcase\itemcolumndepth \ifconditional\introlistitem\noitembreak\fi \itembeforecommand \ifconditional\introlistitem\noitembreak\fi \fi \else % 2 en hoger \ifconditional\paragraphlistitem \else \edef\previtemlevel{\the\numexpr\currentitemlevel-1}% \ifcase\autoitemgroupspacing\relax % nieuw \itembeforecommand \or \doifelsenothing\itembeforecommand\itembeforecommand{\getitemparameter\previtemlevel\c!inbetween}% \else \getitemparameter\previtemlevel\c!inbetween \fi \fi \fi \else \ifconditional\textlistitem % was bugged: \inlinelistitem \ifhmode \removeunwantedspaces\hskip\emwidth\!!plus\interwordstretch\!!minus\interwordshrink\relax \fi % new per 2006/10/20 \else \iteminbetweencommand \fi \fi \ifconditional\concatnextitem \vskip-\dimexpr\lastskip+\lineheight\relax \nobreak \fi \dolistitem \relax \ifconditional\packlistitem \setupwhitespace[\v!none]% \fi \getitemparameter\currentitemlevel\c!inner \marsymbol \let\marsymbol\relax \strut % added 11-08-99 \setfalse\concatnextitem % new, concat \nobreak % else problems with intext items \hskip\itemsignal % new, concat \getitemparameter\currentitemlevel\c!command} % \defaultitemcommand \unprotected\def\dolistitem % evt aantal items opslaan per niveau, scheelt zoeken {\ifconditional\textlistitem % begin of item \else \par \fi \advance\noflistelements\plusone \optimizelistitemsbreak \checkindentation\ifindentation\indent\else\noindent\fi %\noindent \setbox\itemgroupitembox\hbox {\ifconditional\headlistitem \ifconditional\symbollistitem \dosetitemattributes\currentitemlevel\c!symstyle\c!symcolor{\symsymbol}% \else \dosetitemattributes\currentitemlevel\c!headstyle\c!headcolor{\listitem}% \fi \else \ifconditional\symbollistitem \dosetitemattributes\currentitemlevel\c!symstyle\c!symcolor{\symsymbol}% \else \dosetitemattributes\currentitemlevel\c!style\c!color{\listitem}% \fi \fi}% \ifconditional\fittinglistitems \ifdim\wd\itemgroupitembox>\getitemparameter\currentitemlevel\c!maxwidth sp\relax \xsetitemparameter\currentitemlevel\c!maxwidth{\number\wd\itemgroupitembox}% \fi \ifdim\currentitemmaxwidth>\zeropoint \setbox\itemgroupitembox\simplealignedbox{\getitemparameter\currentitemlevel\c!itemalign}{\currentitemmaxwidth}{\box\itemgroupitembox}% \fi \fi \doifsomething\doitemdestination {\setbox\itemgroupitembox\hbox{\directgotobox{\box\itemgroupitembox}[\doitemdestination]}}% \globallet\doitemdestination\empty \itemgroupaskedwidth\getitemparameter\currentitemlevel\c!width\relax % new, prevents loops when symbol is (not yet found) graphic \ht\itemgroupitembox\strutheight \dp\itemgroupitembox\strutdepth % so that content differs per run (esp mp graphics afterwards) \checkforrepeatedlistitem \ifdim\itemgroupaskedwidth<\zeropoint\relax \llap{\ifconditional\sublistitem\llap{+\enspace}\fi\box\itemgroupitembox\hskip\leftmargindistance}% \else \ifdim\itemgroupaskedwidth=\zeropoint\relax \calculatelistwidth1% \else \calculatelistwidth\currentitemlevel \fi \ifconditional\textlistitem \hbox{\ifconditional\sublistitem+\enspace\fi\box\itemgroupitembox\hskip\interwordspace}\nobreak \else\ifconditional\inlinelistitem \hbox to \itemgrouplistwidth{\ifconditional\sublistitem\llap{+\enspace}\fi\box\itemgroupitembox\hss}% was: \hfill \else\ifconditional\txtlistitem \dodotxtitem \else % todo: align+marge binnen de hbox \llap{\hbox to \itemgrouplistwidth{\ifconditional\sublistitem\llap{+\enspace}\fi \symalignleft \box\itemgroupitembox\hfil \hskip\getitemparameter\currentitemlevel\c!distance% T h }}% \fi\fi\fi \fi \forceunexpanded % needed for m conversion (\os) / i need to look into this \setevalue{\@@currentitemsymbol\currentitemlevel}% {\getvalue{\@@localitemsymbol\currentitemlevel}}% still problems with \uchar ? %{\noexpand\getvalue{\@@localitemsymbol\currentitemlevel}}% no, spoils subrefs \resetunexpanded \setfalse\headlistitem \setfalse\sublistitem \setfalse\symbollistitem \EveryPar{\ignorespaces}% needed ? \ignorespaces} \setupindenting[yes,big] \starttext text text text text text text text text text text text text text text text text text text text text text text text text \startitemize[text]\indentationfalse \item text text text text text text text text text text text text text text text text text text text text text text text text \item text text text text text text text text text text text text text text text text text text text text text text text text \stopitemize text text text text text text text text text text text text text text text text text text text text text text text text \startitemize[joinedup,intext][indenting={yes,first,big}]\indentationfalse \item text text text text text text text text text text text text text text text text text text text text text text text text \item text text text text text text text text text text text text text text text text text text text text text text text text \stopitemize text text text text text text text text text text text text text text text text text text text text text text text text \stoptext --Apple-Mail-3-798318323 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=windows-1252 Hi, there had been a question on the list from Vyatcheslav Yatskovsky how to = get indented text inside of itemize and after i spent a few hours on this problem the = answer is it's not possible. His example (simplified from me) was: \setupindenting[yes,big] \starttext text text text text text text text text text text text text text text = text text text text text text text text text text \startitemize[text][indenting=3D{yes,first,big}] \item text text text text text text text text text text text text text = text text text text text text text text text text text \item text text text text text text text text text text text text text = text text text text text text text text text text text \item text text text text text text text text text text text text text = text text text text text text text text text text text \stopitemize text text text text text text text text text text text text text text = text text text text text text text text text text \stoptext and as you can see the second and all following items are indented but = this has nothing to do with indenting and is a side effect of the 'text' option which is meant for = inline items where no blank line is expected between the '\item'=92s because the should be all in = the same paragraph as in: \setupindenting[yes,big] \starttext text text text text text text text text text text text text text text = text text text text text text text text text text \startitemize[text] \item text text text text text text text text text text text text text = text text text text text text text text text text text \item text text text text text text text text text text text text text = text text text text text text text text text text text \item text text text text text text text text text text text text text = text text text text text text text text text text text \stopitemize text text text text text text text text text text text text text text = text text text text text text text text text text \stoptext Even tough the 'text' option is wrong here (because 'joinedup' gives the = same output but without indentation) we should take care of this and insert the distance between the items only in = horizontal mode. To do so change in the definition for \complexdoitemgroupitem the = following line: \else \ifconditional\textlistitem % was bugged: \inlinelistitem = \removeunwantedspaces\hskip\emwidth\!!plus\interwordstretch\!!minus\interw= ordshrink\relax % new per 2006/10/20 \else \iteminbetweencommand \fi \fi to \else \ifconditional\textlistitem % was bugged: \inlinelistitem \ifhmode = \removeunwantedspaces\hskip\emwidth\!!plus\interwordstretch\!!minus\interw= ordshrink\relax % new per 2006/10/20 \fi \else \iteminbetweencommand \fi \fi and while we already change this make the space between the items = changeable, e.g. with (old feature request in the list archive) \else \ifconditional\textlistitem % was bugged: \inlinelistitem \ifhmode \processaction [\getitemparameter\currentitemlevel\c!space] [ \v!none=3D>\let\textitemdistance\zeropoint, = \s!unknown=3D>\assignvalue\commalistelement\textitemdistance{.5\interwords= pace\!!plus.5\emwidth}{\interwordspace\!!plus\emwidth}{\emwidth\!!plus\int= erwordstretch\!!minus\interwordshrink}]% \removeunwantedspaces\hskip\textitemdistance\relax \fi % new per 2006/10/20 \else \iteminbetweencommand \fi \fi The next point is to enable the indenting parameter which isn't = functioning at all because at the start of each item command (\dolistitem) a \noindent command prevents it from working. = One way to fix is to replace \noitem with \checkindentation\ifindentation\indent\else\noindent\fi and = \indentationfalse to startitemgroup. When these changes are done one could indent the text in itemize with: \setupindenting[yes,big] \starttext text text text text text text text text text text text text text text = text text text text text text text text text text \startitemize[joinedup,intext][indenting=3D{yes,first,big}] \item text text text text text text text text text text text text text = text text text text text text text text text text text \item text text text text text text text text text text text text text = text text text text text text text text text text text \stopitemize text text text text text text text text text text text text text text = text text text text text text text text text text \stoptext Wolfgang --Apple-Mail-3-798318323 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 ___________________________________________________________________________________ --Apple-Mail-3-798318323--