ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: "Wolfgang Schuster" <schuster.wolfgang@googlemail.com>
To: "mailing list for ConTeXt users" <ntg-context@ntg.nl>
Subject: Re: Grid-keeping list (again)
Date: Thu, 12 Apr 2007 13:46:44 +0200	[thread overview]
Message-ID: <115224fb0704120446n380e1439n180baec31f8768bd@mail.gmail.com> (raw)
In-Reply-To: <461DFA1D.9020706@typoma.com>


[-- Attachment #1.1: Type: text/plain, Size: 2309 bytes --]

2007/4/12, Johannes Kuester <jk@typoma.com>:
>
> Hello,
>
> I'm still trying to typeset a "grid-keeping" list (or table).
> Wolfgang Schuster supplied me off-list with the attached module.
> This works fine except for one problem:
>
> Only the first few lines are placed on the grid, then the grid is lost.
>
> After the next pass (i.e. after the next "texmfstart texexec testfile"),
> some more lines are placed on the grid.
> (So I need many passes to typeset the complete list correctly).
>
> Why? Any idea?
>
> (I fiddled around with \synchronizegrid, \placeongrid, \moveongrid, and
> \startlinecorrection \stoplinecorrection, but none of these seems to
> work.)
>
> You could try the effect with the following example:
>
> %%%%%%%%%%
>
> \setuplayout[grid=yes, columns=2]
> \showgrid
> %\showstruts
>
> \usemodule[gridlist]
>
> \starttext
>
> \startcolumns[n=2, balance=no]
> %% (columns are not necessary to show the effect)
>
> \dorecurse{20}{
>   \zeichen{0001}{a}{first letter}{}%
>   \zeichen{0002}{b}{second letter}{}%
>   \zeichen{0002}{c}{third letter, this one has a longer entry
>                     which needs more than one line}{}%
> }
>
> \stopcolumns
>
> \stoptext


Hi Johannes,

replace the current definition of \zeichenzelle with the following:

\def\zeichenzelle#1%
  {\advance\zeichencolumn\plusone
   \hbox
     {\vtop
        {\hsize\zeichenparameter\c!width
         \normalbaselines
         \zeichenparameter\c!before
         \begstrut
           \dostartattributes{\????ze\number\zeichencolumn}\c!style\c!color
           \zeichenparameter\c!left
             #1
           \zeichenparameter\c!right
           \dostopattributes
         \endstrut
         \zeichenparameter\c!after}}}

\synchronizegrid in \setupzeichen is not neccessary

\setupzeichen
  [\c!textwidth=63.8833mm,
   \c!before=\noindenting, %\synchronizegrid,
   \c!after=, %\synchronizegrid
  ]

add the next two commands to your module

\def\startzeichen{\begingroup\offinterlineskip}
\def\stopzeichen{\endgroup}

a alternative version

%\def\startzeichen{\offinterlineskip}
%\def\stopzeichen{\oninterlineskip}

and put \startzeichen and \stopzeichen before and after your lines
with all \zeichen commands

\startzeichen
\zeichen
...
\zeichen
\stopzeichen

and everything should work as expected

Wolfgang

[-- Attachment #1.2: Type: text/html, Size: 3486 bytes --]

[-- Attachment #2: Type: text/plain, Size: 139 bytes --]

_______________________________________________
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context

  parent reply	other threads:[~2007-04-12 11:46 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-04-12  9:21 Johannes Kuester
2007-04-12 10:10 ` luigi scarso
2007-04-12 11:53   ` Johannes Kuester
2007-04-12 12:25     ` Hans Hagen
2007-04-12 12:50       ` luigi scarso
2007-04-12 11:46 ` Wolfgang Schuster [this message]
2007-04-12 12:44   ` Johannes Kuester
2007-04-12 22:06 ` luigi scarso
2007-04-13  9:13   ` Johannes Kuester
2007-04-13  9:33     ` luigi scarso
2007-04-13 10:04       ` luigi scarso
2007-04-13 14:12       ` Johannes Kuester
2007-04-13 11:25     ` Hans Hagen
2007-04-13 14:04       ` Johannes Kuester

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=115224fb0704120446n380e1439n180baec31f8768bd@mail.gmail.com \
    --to=schuster.wolfgang@googlemail.com \
    --cc=ntg-context@ntg.nl \
    /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).