From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/36679 Path: news.gmane.org!not-for-mail From: Vit Zyka Newsgroups: gmane.comp.tex.context Subject: register: spurious space & one more entry level ask Date: Wed, 19 Sep 2007 20:44:36 +0200 Message-ID: <46F16E14.8010107@seznam.cz> Reply-To: vit.zyka@seznam.cz, mailing list for ConTeXt users NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1190228668 22504 80.91.229.12 (19 Sep 2007 19:04:28 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Wed, 19 Sep 2007 19:04:28 +0000 (UTC) To: ConTeXt Original-X-From: ntg-context-bounces@ntg.nl Wed Sep 19 21:03:52 2007 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from ronja.vet.uu.nl ([131.211.172.88] helo=ronja.ntg.nl) by lo.gmane.org with esmtp (Exim 4.50) id 1IY4XQ-0008G3-82 for gctc-ntg-context-518@m.gmane.org; Wed, 19 Sep 2007 20:44:40 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id B107320118; Wed, 19 Sep 2007 20:44:38 +0200 (CEST) Original-Received: from ronja.ntg.nl ([127.0.0.1]) by localhost (smtp.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 27446-03-6; Wed, 19 Sep 2007 20:44:24 +0200 (CEST) Original-Received: from ronja.vet.uu.nl (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 5EA5D200DE; Wed, 19 Sep 2007 20:44:24 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 0345B1FE69 for ; Wed, 19 Sep 2007 20:44:21 +0200 (CEST) Original-Received: from ronja.ntg.nl ([127.0.0.1]) by localhost (smtp.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 27446-03-5 for ; Wed, 19 Sep 2007 20:44:14 +0200 (CEST) Original-Received: from ug-out-1314.google.com (ug-out-1314.google.com [66.249.92.169]) by ronja.ntg.nl (Postfix) with ESMTP id 50456200DE for ; Wed, 19 Sep 2007 20:44:14 +0200 (CEST) Original-Received: by ug-out-1314.google.com with SMTP id h2so293661ugf for ; Wed, 19 Sep 2007 11:44:14 -0700 (PDT) Original-Received: by 10.78.142.14 with SMTP id p14mr657610hud.1190227453424; Wed, 19 Sep 2007 11:44:13 -0700 (PDT) Original-Received: from ?192.168.1.24? ( [82.208.57.182]) by mx.google.com with ESMTPS id v27sm490792hub.2007.09.19.11.44.12 (version=TLSv1/SSLv3 cipher=RC4-MD5); Wed, 19 Sep 2007 11:44:12 -0700 (PDT) User-Agent: Thunderbird 2.0.0.6 (Windows/20070728) X-Virus-Scanned: amavisd-new at ntg.nl X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.9 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 X-Virus-Scanned: amavisd-new at ntg.nl Xref: news.gmane.org gmane.comp.tex.context:36679 Archived-At: Dear ConTeXters, there are 3 topics dealing with register (index): 1. [Spurious space] There are entries like \registerpage{index}{,}{5}{2--1-1-0-1-0-0-0--1}{2} in a *.tuo file. Since the definition (core-reg.tex) \def\dosetpageregisterpage#1#2#3#4#5#6% {\doifreglevelelse[#5]% {\dodosetpageregisterpage{#1}{#2}{#3}{#4}{#5}{#6}}% {}} there will be a spurious space between page number like Entry 23 , 67 instead of Entry 23, 67 Solution: \def\dosetpageregisterpage#1#2#3#4#5#6% {\doifreglevelelse[#5]% {\dodosetpageregisterpage{#1}{#2}{#3}{#4}{#5}{#6}}% {}\ignorespaces} Test file: -------------- \starttext Text\index{test}. \page[yes] Paragraph\index{test}. \placeindex \stoptext -------------- 2. [feature request] Current register implementation enable upto three entry level (\index{level 1+level 2+level 3}). My custommer require 4 levels. Please could the entry number be extended? 3. [not important, just for info] Formating of the register entries is not much user friendly. See \hangindent1em in a following definition: \def\dosetpageregisterentrya#1#2% {\flushseenregisterpage \edef\currententrylevel{1}% \global\let\c!entryb\relax \global\let\c!entryc\relax \gdef\c!entrya {\iffirstregisterentry\else\endgraf\fi % new \global\firstregisterpagetrue \hangindent1em\noindent\c!entryreference \dohandlepageregisterentry{#1}{#2}% \global\firstregisterentryfalse \global\firstsubentrytrue \global\firstsubsubentrytrue}} So, when one want the change formating he has to redefine this definition. It is against a ConTeXt spirit. Best Vit ___________________________________________________________________________________ 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 : https://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________