* Re: itemize and math
[not found] <mailman.3198.1193699581.2346.ntg-context@ntg.nl>
@ 2007-10-30 11:11 ` Wolfgang Werners-Lucchini
2007-10-30 14:19 ` Wolfgang Schuster
0 siblings, 1 reply; 6+ messages in thread
From: Wolfgang Werners-Lucchini @ 2007-10-30 11:11 UTC (permalink / raw)
To: ntg-context
Sorry, I don't understand what the problem is!
> > I have a problem with
> >
> > \startitemize[columns,a]
> > \item $a_n=2+\frac{1}{n+1}$
> > \item $a_n=\frac{(-1)^n}{\sqrt{n}}-3$
> > \stopitemize
> >
> Hi,
>
> this did not wotk because the second formula is than the first and
-------------------------------------------------^ (what?)
> the multicolumn OTR tries to put half or less of the text into the
> second column, you can now force a second column with the \column
> command after the first line or you switch both
> formulas and the OTR can make two columns.
>
> \starttext
>
> \startitemize[columns,a]
> \item $a_n=\frac{(-1)^n}{\sqrt{n}}-3$
> \item $a_n=2+\frac{1}{n+1}$
> \stopitemize
Why is this working? Here the first column is as big as the second
above (same formula), so the same problem should arise with the first
column as above with the second?
> \startitemize[columns,a]
> \item $a_n=2+\frac{1}{n+1}$ \column
> \item $a_n=\frac{(-1)^n}{\sqrt{n}}-3$
> \stopitemize
Why does the \column help with the first formula?
No, I don't understand this at all.
Wolfgang
___________________________________________________________________________________
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
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: itemize and math
2007-10-30 11:11 ` itemize and math Wolfgang Werners-Lucchini
@ 2007-10-30 14:19 ` Wolfgang Schuster
0 siblings, 0 replies; 6+ messages in thread
From: Wolfgang Schuster @ 2007-10-30 14:19 UTC (permalink / raw)
To: mailing list for ConTeXt users
[-- Attachment #1.1: Type: text/plain, Size: 2172 bytes --]
2007/10/30, Wolfgang Werners-Lucchini <wwl@musensturm.de>:
>
> Sorry, I don't understand what the problem is!
It is related to ConTeXt's multicolumn Output Routine.
> > I have a problem with
> > >
> > > \startitemize[columns,a]
> > > \item $a_n=2+\frac{1}{n+1}$
> > > \item $a_n=\frac{(-1)^n}{\sqrt{n}}-3$
> > > \stopitemize
> > >
>
> > Hi,
> >
> > this did not wotk because the second formula is than the first and
> -------------------------------------------------^ (what?)
>
> > the multicolumn OTR tries to put half or less of the text into the
> > second column, you can now force a second column with the \column
> > command after the first line or you switch both
> > formulas and the OTR can make two columns.
> >
> > \starttext
> >
> > \startitemize[columns,a]
> > \item $a_n=\frac{(-1)^n}{\sqrt{n}}-3$
> > \item $a_n=2+\frac{1}{n+1}$
> > \stopitemize
>
> Why is this working? Here the first column is as big as the second
> above (same formula), so the same problem should arise with the first
> column as above with the second?
No, they are not, the first row (column) is 1 points taller than the second
one, you can test this with TeX.
\starttext
\setbox\scratchbox\hbox{$a_n=\frac{(-1)^n}{\sqrt{n}}-3$}
Formula 1: \copy\scratchbox
Height of formula 1: \the\ht\scratchbox
\setbox\scratchbox\hbox{$a_n=2+\frac{1}{n+1}$}
Formula 2: \copy\scratchbox
Height of formula 2: \the\ht\scratchbox
\stoptext
> \startitemize[columns,a]
> > \item $a_n=2+\frac{1}{n+1}$ \column
> > \item $a_n=\frac{(-1)^n}{\sqrt{n}}-3$
> > \stopitemize
>
> Why does the \column help with the first formula?
Because itemize use for the columns key the multicolumns envrionment
where you can force a new column with the \column command.
The internal work for this case is something like in the following example:
\starttext
\startcolumns
$a_n=\frac{(-1)^n}{\sqrt{n}}-3$
$a_n=2+\frac{1}{n+1}$
\stopcolumns
\startcolumns
$a_n=2+\frac{1}{n+1}$ \column
$a_n=\frac{(-1)^n}{\sqrt{n}}-3$
\stopcolumns
\stoptext
No, I don't understand this at all.
I hope my examples helped you a little bit to understand the problems
in your example and why my methods worked.
Wolfgang
[-- Attachment #1.2: Type: text/html, Size: 3190 bytes --]
[-- Attachment #2: Type: text/plain, Size: 487 bytes --]
___________________________________________________________________________________
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
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: itemize and math
2007-10-30 21:20 ` Wolfgang Werners-Lucchini
@ 2007-10-30 21:56 ` Aditya Mahajan
0 siblings, 0 replies; 6+ messages in thread
From: Aditya Mahajan @ 2007-10-30 21:56 UTC (permalink / raw)
To: mailing list for ConTeXt users
On Tue, 30 Oct 2007, Wolfgang Werners-Lucchini wrote:
> Is there something like an \mathstrut macro? (I know, that there
> exists a macro with this name, but that uses ')' as height.)
For single line math, the height of ) is sufficient. If you want larger
heights you can do
\def\bigmathstrut{\vphantom{\big)}} (replace \big by \bigg, \Big, to suit
your need). If you really want something big you can try
\def\bigmathstrut{\vphantom{\frac{\displaystyle\sum_{(}^{)}}{\displaystyle\sum_{)}^{(}}}
Usually things do not grow bigger than this.
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
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: itemize and math
[not found] <mailman.3218.1193768985.2346.ntg-context@ntg.nl>
@ 2007-10-30 21:20 ` Wolfgang Werners-Lucchini
2007-10-30 21:56 ` Aditya Mahajan
0 siblings, 1 reply; 6+ messages in thread
From: Wolfgang Werners-Lucchini @ 2007-10-30 21:20 UTC (permalink / raw)
To: ntg-context
> > > I have a problem with
> > > >
> > > > \startitemize[columns,a]
> > > > \item $a_n=2+\frac{1}{n+1}$
> > > > \item $a_n=\frac{(-1)^n}{\sqrt{n}}-3$
> > > > \stopitemize
> > > >
> >
> > > Hi,
> > >
> > > this did not wotk because the second formula is than the first
> and
> > -------------------------------------------------^ (what?)
> >
> > > the multicolumn OTR tries to put half or less of the text into
> the
> > > second column, you can now force a second column with the
> \column
> > > command after the first line or you switch both
> > > formulas and the OTR can make two columns.
> > >
> > > \starttext
> > >
> > > \startitemize[columns,a]
> > > \item $a_n=\frac{(-1)^n}{\sqrt{n}}-3$
> > > \item $a_n=2+\frac{1}{n+1}$
> > > \stopitemize
> >
> > Why is this working? Here the first column is as big as the
> second
> > above (same formula), so the same problem should arise with the
> first
> > column as above with the second?
>
>
> No, they are not, the first row (column) is 1 points taller than the
> second
> one, you can test this with TeX.
>
> \starttext
>
> \setbox\scratchbox\hbox{$a_n=\frac{(-1)^n}{\sqrt{n}}-3$}
>
> Formula 1: \copy\scratchbox
>
> Height of formula 1: \the\ht\scratchbox
>
> \setbox\scratchbox\hbox{$a_n=2+\frac{1}{n+1}$}
>
> Formula 2: \copy\scratchbox
>
> Height of formula 2: \the\ht\scratchbox
Ahhh! The HEIGHT (not the width) ist the problem!?
So:
\startcolumns
\dontleavehmode
\vphantom{$a_n=\frac{(-1)^n}{\sqrt{n}}-3$}$a_n=2+\frac{1}{n+1}$%
$a_n=\frac{(-1)^n}{\sqrt{n}}-3$
\stopcolumns
works too.
Is there something like an \mathstrut macro? (I know, that there
exists a macro with this name, but that uses ')' as height.)
> I hope my examples helped you a little bit to understand the
> problems in your example and why my methods worked.
>
> Wolfgang
Hope, I have it!
Thank you,
Wolfgang
___________________________________________________________________________________
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
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: itemize and math
2007-10-29 10:43 Wolfgang Werners-Lucchini
@ 2007-10-29 11:52 ` Wolfgang Schuster
0 siblings, 0 replies; 6+ messages in thread
From: Wolfgang Schuster @ 2007-10-29 11:52 UTC (permalink / raw)
To: mailing list for ConTeXt users
[-- Attachment #1.1: Type: text/plain, Size: 906 bytes --]
2007/10/29, Wolfgang Werners-Lucchini <wwl@musensturm.de>:
>
> Hallo,
>
> I have a problem with
>
> \startitemize[columns,a]
> \item $a_n=2+\frac{1}{n+1}$
> \item $a_n=\frac{(-1)^n}{\sqrt{n}}-3$
> \stopitemize
>
> which is NOT in columns.
>
> \startitemize[columns,a]
> \item one
> \item two
> \stopitemize
>
> works!
>
> How can I solve this?
>
> Wolfgang
Hi,
this did not wotk because the second formula is than the first and the
multicolumn
OTR tries to put half or less of the text into the second column, you can
now force
a second column with the \column command after the first line or you switch
both
formulas and the OTR can make two columns.
\starttext
\startitemize[columns,a]
\item $a_n=\frac{(-1)^n}{\sqrt{n}}-3$
\item $a_n=2+\frac{1}{n+1}$
\stopitemize
\startitemize[columns,a]
\item $a_n=2+\frac{1}{n+1}$ \column
\item $a_n=\frac{(-1)^n}{\sqrt{n}}-3$
\stopitemize
\stoptext
Wolfgang
[-- Attachment #1.2: Type: text/html, Size: 1259 bytes --]
[-- Attachment #2: Type: text/plain, Size: 487 bytes --]
___________________________________________________________________________________
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
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 6+ messages in thread
* itemize and math
@ 2007-10-29 10:43 Wolfgang Werners-Lucchini
2007-10-29 11:52 ` Wolfgang Schuster
0 siblings, 1 reply; 6+ messages in thread
From: Wolfgang Werners-Lucchini @ 2007-10-29 10:43 UTC (permalink / raw)
To: ntg-context
Hallo,
I have a problem with
\startitemize[columns,a]
\item $a_n=2+\frac{1}{n+1}$
\item $a_n=\frac{(-1)^n}{\sqrt{n}}-3$
\stopitemize
which is NOT in columns.
\startitemize[columns,a]
\item one
\item two
\stopitemize
works!
How can I solve this?
Wolfgang
___________________________________________________________________________________
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
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2007-10-30 21:56 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <mailman.3198.1193699581.2346.ntg-context@ntg.nl>
2007-10-30 11:11 ` itemize and math Wolfgang Werners-Lucchini
2007-10-30 14:19 ` Wolfgang Schuster
[not found] <mailman.3218.1193768985.2346.ntg-context@ntg.nl>
2007-10-30 21:20 ` Wolfgang Werners-Lucchini
2007-10-30 21:56 ` Aditya Mahajan
2007-10-29 10:43 Wolfgang Werners-Lucchini
2007-10-29 11:52 ` Wolfgang Schuster
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).