From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/52351 Path: news.gmane.org!not-for-mail From: Aditya Mahajan Newsgroups: gmane.comp.tex.context Subject: Re: hdotsfor replacement Date: Sun, 16 Aug 2009 22:49:05 -0400 (EDT) Message-ID: References: Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; Format="flowed" Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1250477388 11857 80.91.229.12 (17 Aug 2009 02:49:48 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 17 Aug 2009 02:49:48 +0000 (UTC) To: mailing list for ConTeXt users Original-X-From: ntg-context-bounces@ntg.nl Mon Aug 17 04:49:40 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 1McsI0-0007Kh-J7 for gctc-ntg-context-518@m.gmane.org; Mon, 17 Aug 2009 04:49:40 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 78E18C9AE3; Mon, 17 Aug 2009 04:49:39 +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 73zVFvVc1ED8; Mon, 17 Aug 2009 04:49:34 +0200 (CEST) Original-Received: from balder.ntg.nl (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id E15F4C9AAD; Mon, 17 Aug 2009 04:49:34 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 6561EC9AAD for ; Mon, 17 Aug 2009 04:49:34 +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 iWh5BE+Iwbp8 for ; Mon, 17 Aug 2009 04:49:23 +0200 (CEST) Original-Received: from tombraider.mr.itd.umich.edu (smtp.mail.umich.edu [141.211.93.161]) by balder.ntg.nl (Postfix) with ESMTP id BDF3FC9A92 for ; Mon, 17 Aug 2009 04:49:22 +0200 (CEST) Original-Received: FROM [192.168.2.8] (c-76-28-88-45.hsd1.ct.comcast.net [76.28.88.45]) By tombraider.mr.itd.umich.edu ID 4A88C530.CEDC8.14746 ; Authuser adityam; 16 Aug 2009 22:49:20 EDT In-Reply-To: User-Agent: Alpine 2.00 (LNX 1167 2008-08-23) 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:52351 Archived-At: On Mon, 17 Aug 2009, Michail Vidiassov wrote: > Dear All, > > is there a replacement of "hdotsfor" from LaTeX to fill > several cells in a matrix row with one long series of dots? Not that I know of. Currently, you can manually do this using TeX primitives. \starttext \startformula \startmathmatrix \NC a \NC b \NC c \NR \NC \spanomit\spanomit{\dotfill} \NR \NC e \NC d \NC adlsadjsak \NR \stopmathmatrix \startmathmatrix \NC a \NC b \NC c \NR \NC 45 \NC \omit\spanomit{\dotfill} \NR \NC e \NC d \NC adlsadjsak \NR \stopmathmatrix \stopformula \stoptext Hans, can we have a command to do this? Basically, \hdotsfor does two things. Span a specific number of columns and fill them with dots. The spacing between the dots should be configurable. This is how amsmath defines it. \newcommand{\hdotsfor}[1]{% \ifx[#1\@xp\shdots@for\else\hdots@for\@ne{#1}\fi} \newmuskip\dotsspace@ \def\shdots@for#1]{\hdots@for{#1}} \def\hdots@for#1#2{\multicolumn{#2}c% {\m@th\dotsspace@1.5mu\mkern-#1\dotsspace@ \xleaders\hbox{$\m@th\mkern#1\dotsspace@.\mkern#1\dotsspace@$}% \hfill \mkern-#1\dotsspace@}% } I think that in Context, we can have the following. \definemathmatrix[matrix][dotspaces=...] and then in a matrix environment, \DC[3] (dot columns 3) expands to the correct number of \omit and \spanomits. What do you think? Aditya ___________________________________________________________________________________ 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 ___________________________________________________________________________________