Re: [NTG-context] table making ugly column sizes, how to fix?

2018-10-02 Thread David Walther

On Tue, Oct 02, 2018 at 12:28:44AM -0400, Aditya Mahajan wrote:

ConTeXt MkIV 2018.09.30

What version are you using?


My version is from 2017.  Thank you for the confirmation; now I will file a bug
report with Debian.

David
___
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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] table making ugly column sizes, how to fix?

2018-10-01 Thread David Walther

I looked at your example.  I ran your example, and on my installation, it has
the same problem as I described.  I have included a PDF file of my original
sample file, and also the PDF generated from your example.   What version of
ConTeXt are you using?

On my installation of context, columns are still coming out "ugly" as you will
see in the PDF t1.pdf.  In t2.pdf you'll see the problem shows up in the table
labelled "Good".  The "Good" refers to the row in bold, not to the row above
it.

David

On Sun, Sep 30, 2018 at 07:44:12PM -0400, Aditya Mahajan wrote:

On Sat, 29 Sep 2018, David Walther wrote:


Full example at the bottom.

I'm making a table.  So far so good.

Every so often I want to make something like a section header.

Regular table rows are like this:

\bTR\bTC \eTC\bTC NightShift \eTC\bTC Tension Lines 146 - 150 \eTC\eTR

For the section headers, I do this, and they look the way I want:

\bTR\bTC 30. \eTC \bTC[nc=2,align=center,style=] \bf{Foo Bar} \eTC\eTR


You can also use

\bTC[nc=2, align=middle, style=bold]

But then the regular lines have ugly line breaks and suddenly the 
column size of column 3 is squeezed.  This shouldn't be, we have the 
whole page to work with.


I don't really see the difference in column sizes between the two 
cases. See attached (I simplified and cleaned the example a little)


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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___




t1.tex
Description: TeX document


t2.pdf
Description: Adobe PDF document


t1.pdf
Description: Adobe PDF document
___
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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

[NTG-context] align is reversed inside a table

2018-09-29 Thread David Walther

Using this table as an example, when I do align=left, the column aligns right,
and when I do align=right, it aligns left.  align=center works as expected.  Am
I doing something wrong or is this a bug?

I am using the version of context distributed with Debian unstable:

mtx-context | ConTeXt Process Management 1.01
mtx-context |
mtx-context | main context file: 
/usr/share/texmf/tex/context/base/mkiv/context.mkiv
mtx-context | current version: 2017.05.15 21:48

Minimal example here:

\setuppagenumbering[alternative=doublesided,location=none,page=no]
\setupfootertexts[\sans{Source: http://mywebsite}]
\setupheadertexts[test column text wrapping]
\setupheadertexts
 [] [Page \userpagenumber\ of \lastuserpagenumber]
 [Page \userpagenumber\ of \lastuserpagenumber] []
\setuppapersize[letter, portrait]
\setuplayout[topspace=0.5in, backspace=1in, height=10in, width=7in,
header=0.5in, footer=0.5in, headerdistance=0in, footerdistance=0in]
\switchtobodyfont[12pt]
\starttext
\setupTABLE[split=repeat]
\setupTABLE[r][each][toffset=3pt, boffset=3pt, loffset=3pt, roffset=3pt]
\setupTABLE[c][each][leftframe=off,rightframe=off,align=right]
\setupTABLE[c][first][frame=off,align=left]
\setupTABLE[c][2][style=\tfx\it,align=left]
\bTABLE
\bTABLEhead
\bTR\bTH Col1 \eTH\bTH Col2 \eTH\bTH Col3 \eTH\eTR
\eTABLEhead
\bTABLEnext
\bTR\bTH Col1 \eTH\bTH Col2 \eTH\bTH Col3 \eTH\eTR
\eTABLEnext
\bTABLEbody
\bTR\bTC \eTC\bTC NightShift \eTC\bTC Tension Lines 146 - 150 \eTC\eTR
\bTR\bTC 30. \eTC \bTC[nc=2,align=center,style=] \bf{Foo Bar} \eTC\eTR
%\bTR\bTC 30. \eTC \bTC\eTC \bTC[align=center] \bf{Foo Bar} \eTC\eTR
\eTABLEbody
\eTABLE
\stoptext
___
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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

[NTG-context] table making ugly column sizes, how to fix?

2018-09-29 Thread David Walther

Full example at the bottom.

I'm making a table.  So far so good.

Every so often I want to make something like a section header.

Regular table rows are like this:

\bTR\bTC \eTC\bTC NightShift \eTC\bTC Tension Lines 146 - 150 \eTC\eTR

For the section headers, I do this, and they look the way I want:

\bTR\bTC 30. \eTC \bTC[nc=2,align=center,style=] \bf{Foo Bar} \eTC\eTR

But then the regular lines have ugly line breaks and suddenly the column size 
of column 3 is squeezed.  This shouldn't be, we have the whole page to work 
with.

So, when I do my section headers this way, the columns come out sized nicely, 
but the section header isn't styled the way I want it:

\bTR\bTC 30. \eTC \bTC\eTC \bTC[align=center] \bf{Foo Bar} \eTC\eTR

Below is my minimal example you can cut and paste.  How do I do the section
headers without messing up the column sizing?


\setuppagenumbering[alternative=doublesided,location=none,page=no]
\setupfootertexts[\sans{Source: http://mywebsite}]
\setupheadertexts[test column text wrapping]
\setupheadertexts
 [] [Page \userpagenumber\ of \lastuserpagenumber]
 [Page \userpagenumber\ of \lastuserpagenumber] []
\setuppapersize[letter, portrait]
\setuplayout[topspace=0.5in, backspace=1in, height=10in, width=7in,
header=0.5in, footer=0.5in, headerdistance=0in, footerdistance=0in]
\switchtobodyfont[12pt]
\starttext
\setupTABLE[split=repeat]
\setupTABLE[r][each][toffset=3pt, boffset=3pt, loffset=3pt, roffset=3pt]
\setupTABLE[c][each][leftframe=off,rightframe=off,align=right]
\setupTABLE[c][first][frame=off,align=left]
\setupTABLE[c][2][style=\tfx\it,align=left]
\bTABLE
\bTABLEhead
\bTR\bTH Col1 \eTH\bTH Col2 \eTH\bTH Col3 \eTH\eTR
\eTABLEhead
\bTABLEnext
\bTR\bTH Col1 \eTH\bTH Col2 \eTH\bTH Col3 \eTH\eTR
\eTABLEnext
\bTABLEbody
\bTR\bTC \eTC\bTC NightShift \eTC\bTC Tension Lines 146 - 150 \eTC\eTR

% This displays the way I want, but breaks the regular rows.
\bTR\bTC 30. \eTC \bTC[nc=2,align=center,style=] \bf{Foo Bar} \eTC\eTR

% This works with the regular rows, but doesn't look how I want.
%\bTR\bTC 30. \eTC \bTC\eTC \bTC[align=center] \bf{Foo Bar} \eTC\eTR
\eTABLEbody
\eTABLE
\stoptext
___
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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] how to put page X of N in header or top space?

2018-08-14 Thread David Walther

On Wed, Aug 15, 2018 at 05:41:33AM +0200, Wolfgang Schuster wrote:

\setuppagenumbering
 [alternative=doublesided,
  location=none,
  page=no]


Thanks Wolfgang, that works like a champ.  Now I've found the documentation for
ConTeXt in Debian, it is tucked away in
/usr/share/texmf/doc/context/documents/general/manuals directory as a pile of
PDFs.  I have some reading to do now.  Thank you everyone for your help.

David




Wolfgang


David Walther schrieb am 14.08.18 um 22:44:
Thank you Wolfgang, that worked nicely.  Two artifacts I'm not sure 
how to address:


I did page Page X of N, but in the output, it displays like
Page 2of 3, Page 1of 3, etc.  It ignores the space between the 
number and the word of.


Secondly, when I use the doublesided and the {singlesided,doublesided}
alternative page numbering, it rounds up to an even number of pages, even
though the last page is blank.  When I just use the singlesided 
option I get 3
pages as expected, but it doesn't do the nice interior margins and 
switching
sides of page numbers.  Even context doesn't view the blank page at 
the end as

a page, because it doesn't print the header or footer on it.

David


On Tue, Aug 14, 2018 at 09:32:29PM +0200, Wolfgang Schuster wrote:

\setuppagenumbering
[alternative=doublesided,   % doublesided layout
%alternative={singlesided,doublesided}, % singlesided layout with 
left/right pages

 location=none]

\setupheadertexts [My Spreadsheet]

\setupheadertexts
[] [Page \userpagenumber\ of \lastuserpagenumber]
[Page \userpagenumber\ of \lastuserpagenumber] []

\starttext
\dorecurse{10}{\page[dummy]}
\stoptext


Wolfgang


David Walther schrieb am 14.08.18 um 18:28:
Hi, I am slowly learning ConTeXt.  I am generating tables and 
spreadsheets, and

transforming them into ConTeXt, finally got it working after a lot of
mysterious errors about missing } as macro arguments.

I have read this page carefully: http://wiki.contextgarden.net/Layout

How can I alter the page number?  Is it in the header, or is it in the
topspace?

I want this to be at the top of each page of my spreadsheet:

My Spreadsheet (centered) Page 1 of 3 (right justified)

And on even pages, the other way around:

Page 2 of 3 (left justified) My Spreadsheet (centered)

What is the right way to do this?  Is there an override and a 
blob of code I need to put into one of the boxes in the Layout?


David
___


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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___




___

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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___



___
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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] how to put page X of N in header or top space?

2018-08-14 Thread David Walther

On Tue, Aug 14, 2018 at 02:58:58PM -0600, Alan Braslau wrote:

On Tue, 14 Aug 2018 13:44:43 -0700
David Walther  wrote:


I did page Page X of N, but in the output, it displays like
Page 2of 3, Page 1of 3, etc.  It ignores the space between the number and the 
word of.


You must have forgotten the trailing "\ " of "\userpagenumber\ ".


Thank you Alan.  That worked.  I didn't forget it; I never knew it.  I'm
starting to run into the area where the Wiki isn't enough, but I don't know
enough TeX to read the Context source for the macros.  What is recommended to
get up to speed on Context?  Should I go back and re-read Knuth's book on TeX
then try reading ConTeXt source?  Last time I read it was 20 years ago, and
only got half way through; that was enough for my needs back then.  I guess a
week or two reading everything on this page would help too:

 http://www.luatex.org/documentation.html

Now just need an answer for the blank page issue and I can start shipping these
spreadsheets to clients.

David
___
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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] how to put page X of N in header or top space?

2018-08-14 Thread David Walther

Thank you Wolfgang, that worked nicely.  Two artifacts I'm not sure how to 
address:

I did page Page X of N, but in the output, it displays like
Page 2of 3, Page 1of 3, etc.  It ignores the space between the number and the 
word of.

Secondly, when I use the doublesided and the {singlesided,doublesided}
alternative page numbering, it rounds up to an even number of pages, even
though the last page is blank.  When I just use the singlesided option I get 3
pages as expected, but it doesn't do the nice interior margins and switching
sides of page numbers.  Even context doesn't view the blank page at the end as
a page, because it doesn't print the header or footer on it.

David


On Tue, Aug 14, 2018 at 09:32:29PM +0200, Wolfgang Schuster wrote:

\setuppagenumbering
 [alternative=doublesided,   % doublesided layout
 %alternative={singlesided,doublesided}, % singlesided layout with 
left/right pages

  location=none]

\setupheadertexts [My Spreadsheet]

\setupheadertexts
 [] [Page \userpagenumber\ of \lastuserpagenumber]
 [Page \userpagenumber\ of \lastuserpagenumber] []

\starttext
\dorecurse{10}{\page[dummy]}
\stoptext


Wolfgang


David Walther schrieb am 14.08.18 um 18:28:
Hi, I am slowly learning ConTeXt.  I am generating tables and 
spreadsheets, and

transforming them into ConTeXt, finally got it working after a lot of
mysterious errors about missing } as macro arguments.

I have read this page carefully:  http://wiki.contextgarden.net/Layout

How can I alter the page number?  Is it in the header, or is it in the
topspace?

I want this to be at the top of each page of my spreadsheet:

My Spreadsheet (centered) Page 1 of 3 (right justified)

And on even pages, the other way around:

Page 2 of 3 (left justified) My Spreadsheet (centered)

What is the right way to do this?  Is there an override and a blob 
of code I need to put into one of the boxes in the Layout?


David
___

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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___



___
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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

[NTG-context] how to put page X of N in header or top space?

2018-08-14 Thread David Walther

Hi, I am slowly learning ConTeXt.  I am generating tables and spreadsheets, and
transforming them into ConTeXt, finally got it working after a lot of
mysterious errors about missing } as macro arguments.

I have read this page carefully:  http://wiki.contextgarden.net/Layout

How can I alter the page number?  Is it in the header, or is it in the
topspace?

I want this to be at the top of each page of my spreadsheet:

My Spreadsheet (centered) Page 1 of 3 (right justified)

And on even pages, the other way around:

Page 2 of 3 (left justified) My Spreadsheet (centered)

What is the right way to do this?  Is there an override and a blob of code I 
need to put into one of the boxes in the Layout?

David
___
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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___