Re: [NTG-context] Is this a bug in header marking?

2017-10-17 Thread Rik

I have resolved the issue in a practical, but unsatisfactory, manner.

I have resorted to creating an interlude, a new heading derived from 
title, setting it for left pages with no displayed head:


   \definehead[ChapterEpigraph][title]
   \setuphead [ChapterEpigraph][
  page={yes,left},
  insidesection=\vfill,
  aftersection={\vfill\vfill},
  header=empty,
  placehead=no,
 ]

Thus, \startChapterEpigraph can safely be placed before each 
\startchapter (and between the last \stopchapter of a part and the start 
of the next part) when that last chapter ends on a recto). This clears 
the chapter marking in the headings of the new verso. When there is an 
epigraph to set, it is placed in the ChapterEpigraph section.


This is unsatisfactory because it implements an inaccurate semantic 
model of the document – the epigraphs belong to the following chapter, 
not the numberless, nameless interlude.


And there is almost certainly a bug lurking here. I had considered 
adding the marking of the next chapter to the interlude to better tie 
the interlude to the place it belongs. When I made ChapterEpigraph 
derivative of chapter:


   \definehead[ChapterEpigraph][chapter]
   \setuphead [ChapterEpigraph][
  page={yes,left},
  insidesection=\vfill,
  aftersection={\vfill\vfill},
  header=yes,
  number=no,
  placehead=no,
 ]

and provided a marking:

   \startChapterEpigraph[marking={Same as next chapter marking}]

The resulting page displayed the marking of the previous chapter, not 
the marking provided. This appears to be the same behavior as in the 
example below in my first note, although I can provide another working 
example using this apparatus if anyone wants it.


Can we please have a \setuphead or \setupheads option to clear markings 
at the end of the level, and not simply override them when the next 
equivalent level starts? (Although perhaps, based on the observed issue 
described just above, there is some other logic at work here.)


--
Rik

On 2017-10-15 23:54, Rik Kabel wrote:


As a followup to my query on suppressing header marking, I have 
prepared an example which clearly shows odd, if not buggy behavior.


The book places chapter openings on recto pages which follow a verso 
that may have an epigraph. When there is no epigraph, the blank verso 
is properly unmarked by a header, but when there is an epigraph, the 
header from the previous chapter appears on the page. How can I 
eliminate this orphan header?


\setuppagenumbering [alternative=doublesided,location=]
\setupheadertexts   [][{\it\getmarking[section]}]
    [{\it\getmarking[chapter]}][]

\starttexdefinition unexpanded startSectionEpigraph
    \dostartbuffer  [SectionEpigraph]
[startSectionEpigraph][stopSectionEpigraph]
\stoptexdefinition

\setuphead  [chapter][
beforesection=\setups{chapter:epigraph}]

\startsetups chapter:epigraph
    \page[yes,left]% same result with yes,header,footer,left
    \doifelsebuffer{SectionEpigraph}
    {\getbuffer[SectionEpigraph]
 \resetbuffer[SectionEpigraph]}
    {\donothing}
    \page[yes,header,footer,right]
\stopsetups

\starttext

    \completecontent

    \startfrontmatter
    \startchapter[title=Preface]
    \startparagraph
    \input ward
    \stopparagraph
    \stopchapter

    \stopfrontmatter
    \startbodymatter

    \startchapter[title=Chapter First]
    \startparagraph
    \input ward
    \stopparagraph
    \stopchapter

    \startSectionEpigraph
    Why does this page have the heading
    from the previous chapter?
    \stopSectionEpigraph

    \startchapter[title=Chapter Second]
    \startparagraph
    \input ward
    \stopparagraph
    \stopchapter

    \startSectionEpigraph
  Look up!
    \stopSectionEpigraph

    \startchapter[title=Chapter Third]
    \startparagraph
    \input ward
    \stopparagraph
    \stopchapter

    \startchapter[title=Chapter Final]
    \startparagraph
    \input ward
    \stopparagraph
    \stopchapter

    \stopbodymatter

\stoptext

--
Rik


___
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  : 

[NTG-context] web certificaat verlopen ...

2017-10-17 Thread Floris van Manen

modules.contextgarden.net

uses an invalid security certificate.
The certificate expired on 16 September 2017, 01:59.
The current time is 17 October 2017, 22:15.
Error code: SEC_ERROR_EXPIRED_CERTIFICATE

(something might need to get fixed)

.F


signature.asc
Description: Message signed with OpenPGP using GPGMail
___
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] Remove header after ToC

2017-10-17 Thread N. Raghavendra
At 2017-10-17T16:58:22+02:00, Tomas Hala wrote:

> Add the following \if command:
>
> \startfrontmatter
>   \completecontent
>   \ifodd\pageno\page[empty]\else\setupheadertexts[chapter][pagenumber]\fi
> \stopfrontmatter

Thanks, that should work.  However, searching through setup-en.pdf, I
found the conditional `\doifelseoddpage {CMD} {CMD}', which is precisely
what I needed.  Enclosed below is an example which is formatted as I
wanted.

1. I use `header=empty' in \setuphead [chapter], for otherwise I get a
   header on the pages where a chapter begins.

2. I use \setupheadertexts twice, first before the beginning of the
   front matter, and then before the beginning of the body matter, with
   settings appropriate for the respective block.

3. I use `\marking [chapter] {Contents}' before \completecontent, for
   otherwise I get no chapter name in the header for the ToC.

4. I use `\doifelseoddpage {\page [empty]} {}' after \completecontent,
   to do what you had suggested.

Thanks again for the help.

Regards,
Raghu.

--
\starttext

\setuphead
  [chapter]
  [page={yes,header,footer,right},
   header=empty]

\setupheadertexts
  []

\setupfootertexts
  []

\setupheadertexts
  [{\getmarking [chapter]}]
  [\pagenumber]
  [\pagenumber]
  [{\getmarking [chapter]}]

\startfrontmatter
  \marking [chapter] {Contents}
  \completecontent
  \doifelseoddpage {\page [empty]} {}
\stopfrontmatter

\setupheadertexts
  [{\getmarking [sectionnumber].\ \getmarking [section]}]
  [\pagenumber]
  [\pagenumber]
  [{Chapter \getmarking [chapternumber].\ \getmarking [chapter]}]

\startbodymatter
  \dorecurse
{20}
{
  \startchapter
[title=A chapter]

\startsection
  [title=A section]
  Some text
\stopsection

\page

\startsection
  [title=A section]
  Some text
\stopsection

\page

\startsection
  [title=A section]
  Some text
\stopsection

  \stopchapter
}
  \stopbodymatter

\stoptext

--
N. Raghavendra , http://www.retrotexts.net/
Harish-Chandra Research Institute, http://www.hri.res.in/
___
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] Remove header after ToC

2017-10-17 Thread Tomas Hala

Add the following \if command:

\startfrontmatter
  \completecontent
\ifodd\pageno\page[empty]\else\setupheadertexts[chapter][pagenumber]\fi
\stopfrontmatter

Best wishes,

Tomas


Tue, Oct 17, 2017 ve 07:17:34PM +0530 N. Raghavendra napsal(a):
# At 2017-10-17T12:34:06+02:00, Tomas Hala wrote:
# 
# > I did two changes in your code:
# >
# > 1. Disabling of header=empty.
# > 2. Adding of \page[empty].
# >
# > Probably, there is better and system solution,
# > but this might help you, I guess.
# 
# Dear Tomas,
# 
# Thank you for your kind help.
# 
# The change you made works when the ToC ends on an odd page, as in this
# case when it ends on page 1.  However, if the ToC ends on an even page,
# say on page 2, the modification you have suggested produces an empty
# page with no headers on page 3, and then an empty page with
# headers "4 ... Chapter." on page 4; the first chapter starts on page 5.
# Enclosed below is an example of such a file.
# 
# I don't want the empty pages 3 (without headers) and 4 (with headers),
# and I want the first chapter to start on page 3, which is the first
# right hand, i.e., odd numbered, page after the end of the ToC.
# 
# I think what is required is a command \foo which implements the
# following pseudocode:
# 
# if the current page is even numbered ; then
#   \page [empty]
# else
#   do nothing
# endif
# 
# Then, I can use
# 
# \startfrontmatter
#   \completecontent
#   \foo
# \stopfrontmatter
# 
# Regards,
# Raghu.
# 
# --
# \starttext
# 
# \setuppagenumbering
#   [alternative=doublesided]
# 
# \setupheadertexts
#   []
# 
# \setupfootertexts
#   []
# 
# \setupheadertexts
#   [{\getmarking[section]}]
#   [\pagenumber]
#   [\pagenumber]
#   [{Chapter \getmarking[chapternumber].\ \getmarking[chapter]}]
# 
# \setuphead
#   [chapter]
#   [page={yes,header,footer,right}]
# 
# \startfrontmatter
#   \completecontent
#   \page [empty]
# \stopfrontmatter
# 
# \startbodymatter
#   \dorecurse
# {20}
# {
#   \startchapter
# [title=A chapter]
# 
# \startsection
#   [title=A section]
#   Some text
# \stopsection
# 
# \page
# 
# \startsection
#   [title=Another section]
#   Some text
# \stopsection
# 
#   \stopchapter
# }
# \stopbodymatter
# 
# \stoptext
# --
# 
# --
# N. Raghavendra , http://www.retrotexts.net/
# Harish-Chandra Research Institute, http://www.hri.res.in/
# 
___
# 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
# 
___

 Tomáš Hála

Mendelova univerzita, Provozně ekonomická fakulta, ústav informatiky
Zemědělská 1, CZ-613 00 Brno,  tel. +420 545 13 22 28

http://akela.mendelu.cz/~thala
___
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] Remove header after ToC

2017-10-17 Thread N. Raghavendra
At 2017-10-17T19:17:34+05:30, N. Raghavendra wrote:

 
> if the current page is even numbered ; then
>   \page [empty]
> else
>   do nothing
> endif

Read "odd" instead of "even" in the place marked .

Raghu.

-- 
N. Raghavendra , http://www.retrotexts.net/
Harish-Chandra Research Institute, http://www.hri.res.in/
___
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] Remove header after ToC

2017-10-17 Thread N. Raghavendra
At 2017-10-17T12:34:06+02:00, Tomas Hala wrote:

> I did two changes in your code:
>
> 1. Disabling of header=empty.
> 2. Adding of \page[empty].
>
> Probably, there is better and system solution,
> but this might help you, I guess.

Dear Tomas,

Thank you for your kind help.

The change you made works when the ToC ends on an odd page, as in this
case when it ends on page 1.  However, if the ToC ends on an even page,
say on page 2, the modification you have suggested produces an empty
page with no headers on page 3, and then an empty page with
headers "4 ... Chapter." on page 4; the first chapter starts on page 5.
Enclosed below is an example of such a file.

I don't want the empty pages 3 (without headers) and 4 (with headers),
and I want the first chapter to start on page 3, which is the first
right hand, i.e., odd numbered, page after the end of the ToC.

I think what is required is a command \foo which implements the
following pseudocode:

if the current page is even numbered ; then
  \page [empty]
else
  do nothing
endif

Then, I can use

\startfrontmatter
  \completecontent
  \foo
\stopfrontmatter

Regards,
Raghu.

--
\starttext

\setuppagenumbering
  [alternative=doublesided]

\setupheadertexts
  []

\setupfootertexts
  []

\setupheadertexts
  [{\getmarking[section]}]
  [\pagenumber]
  [\pagenumber]
  [{Chapter \getmarking[chapternumber].\ \getmarking[chapter]}]

\setuphead
  [chapter]
  [page={yes,header,footer,right}]

\startfrontmatter
  \completecontent
  \page [empty]
\stopfrontmatter

\startbodymatter
  \dorecurse
{20}
{
  \startchapter
[title=A chapter]

\startsection
  [title=A section]
  Some text
\stopsection

\page

\startsection
  [title=Another section]
  Some text
\stopsection

  \stopchapter
}
\stopbodymatter

\stoptext
--

--
N. Raghavendra , http://www.retrotexts.net/
Harish-Chandra Research Institute, http://www.hri.res.in/
___
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] Quotation with method=font produces error

2017-10-17 Thread Christoph Reller
Hi,

In previous versions of ConTeXt the following MWE worked:

\setupquotation[method=font]
\starttext
\quotation{A}
\stoptext

In more recent versions, the above produces an error:

! Extra }, or forgotten \endgroup
l.3 \quotation{A}

Is this a bug?

Regards,
Christoph
___
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] Remove header after ToC

2017-10-17 Thread Tomas Hala
Hi Raghu,

I did two changes in your code:

1. Disabling of header=empty.
2. Adding of \page[empty].

Probably, there is better and system solution, 
but this might help you, I guess.

Best wishes,

Tomas

%%
...
\setuphead
  [chapter]
  [page={yes,header,footer,right},
%   header=empty
]

\startfrontmatter
  \completecontent
\page[empty]
\stopfrontmatter

\startbodymatter
  \startchapter
[title=A chapter]
...
%%


Tue, Oct 17, 2017 ve 03:37:21PM +0530 N. Raghavendra napsal(a):
# Any help is appreciated!  Do let me know if some more information is
# needed.
# 
# Thanks and regards,
# Raghu.
# 
# --
# 
# At 2017-10-16T08:33:13+05:30, N. Raghavendra wrote:
# 
# > I am a ConTeXt beginner.  I am having trouble getting rid of the header
# > after the ToC in a document that I am preparing.  The following is a
# > simplified version of the document.  I get a header with "2" on the left
# > edge, and "Chapter ."  on the right edge, on page 2, which is an empty
# > page after the ToC.  How do I remove the header on this page?
# >
# > Thanks,
# > Raghu.
# >
# > --
# > \starttext
# >
# > \setuppagenumbering
# >   [alternative=doublesided]
# >
# > \setupheadertexts
# >   []
# >
# > \setupfootertexts
# >   []
# >
# > \setupheadertexts
# >   [{\getmarking[section]}]
# >   [\pagenumber]
# >   [\pagenumber]
# >   [{Chapter \getmarking[chapternumber].\ \getmarking[chapter]}]
# >
# > \setuphead
# >   [chapter]
# >   [page={yes,header,footer,right},
# >header=empty]
# >
# > \startfrontmatter
# >   \completecontent
# > \stopfrontmatter
# >
# > \startbodymatter
# >   \startchapter
# > [title=A chapter]
# >
# > \startsection
# >   [title=A section]
# >   Some text
# > \stopsection
# >
# > \page
# >
# > \startsection
# >   [title=Another section]
# >   Some text
# > \stopsection
# >
# >   \stopchapter
# > \stopbodymatter
# >
# > \stoptext
# > --
# >
# > --
# > N. Raghavendra , http://www.retrotexts.net/
# > Harish-Chandra Research Institute, http://www.hri.res.in/
# 
# -- 
# N. Raghavendra , http://www.retrotexts.net/
# Harish-Chandra Research Institute, http://www.hri.res.in/
# 
___
# 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
# 
___

 Tomáš Hála

Mendelova univerzita, Provozně ekonomická fakulta, ústav informatiky
Zemědělská 1, CZ-613 00 Brno,  tel. +420 545 13 22 28

http://akela.mendelu.cz/~thala
___
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] Remove header after ToC

2017-10-17 Thread N. Raghavendra
Any help is appreciated!  Do let me know if some more information is
needed.

Thanks and regards,
Raghu.

--

At 2017-10-16T08:33:13+05:30, N. Raghavendra wrote:

> I am a ConTeXt beginner.  I am having trouble getting rid of the header
> after the ToC in a document that I am preparing.  The following is a
> simplified version of the document.  I get a header with "2" on the left
> edge, and "Chapter ."  on the right edge, on page 2, which is an empty
> page after the ToC.  How do I remove the header on this page?
>
> Thanks,
> Raghu.
>
> --
> \starttext
>
> \setuppagenumbering
>   [alternative=doublesided]
>
> \setupheadertexts
>   []
>
> \setupfootertexts
>   []
>
> \setupheadertexts
>   [{\getmarking[section]}]
>   [\pagenumber]
>   [\pagenumber]
>   [{Chapter \getmarking[chapternumber].\ \getmarking[chapter]}]
>
> \setuphead
>   [chapter]
>   [page={yes,header,footer,right},
>header=empty]
>
> \startfrontmatter
>   \completecontent
> \stopfrontmatter
>
> \startbodymatter
>   \startchapter
> [title=A chapter]
>
> \startsection
>   [title=A section]
>   Some text
> \stopsection
>
> \page
>
> \startsection
>   [title=Another section]
>   Some text
> \stopsection
>
>   \stopchapter
> \stopbodymatter
>
> \stoptext
> --
>
> --
> N. Raghavendra , http://www.retrotexts.net/
> Harish-Chandra Research Institute, http://www.hri.res.in/

-- 
N. Raghavendra , http://www.retrotexts.net/
Harish-Chandra Research Institute, http://www.hri.res.in/
___
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] Caption location in floatcombination

2017-10-17 Thread Christoph Reller
On Mon, Sep 18, 2017 at 7:19 AM Christoph Reller 
wrote:

> On Sun, Sep 17, 2017 at 6:03 PM Hans Hagen  wrote:
>
>> On 9/13/2017 8:30 AM, Christoph Reller wrote:
>> > It seems to me that the location given to \setupcaptions is not honored
>> > correctly in floatcombinations anymore. Consider the following MWE:
>> >
>> > \setupcaptions[location=top, number=no]
>> > \starttext
>> > \placetable[][]{One}{
>> >\bTABLE \bTR \bTD First \eTD \eTR \eTABLE}
>> > \placefloat[][]{}{
>> >\startfloatcombination
>> >  \placetable[][]{Two}{
>> >\bTABLE \bTR \bTD Second \eTD \eTR \eTABLE}
>> >\stopfloatcombination}
>> > \stoptext
>> >
>> > In earlier versions of ConTeXt, both captions "One" and "Two" of both
>> > tables are rendered above the respective table. In the currently latest
>> > version, the caption "Two" is rendered below the table. Is this a bug or
>> > do I have to setup caption location separately for floatcombinations?
>> >
>> > Any feedback is welcome.\setupcaptions[location=top,number=no]
>>
>> \starttext
>>
>> \placetable{TABLE}{\bTABLE \bTR \bTD First \eTD \eTR \eTABLE}
>>
>> \placefloat{FLOAT}{%
>>\startfloatcombination
>>  \placetable{Two}{\bTABLE \bTR \bTD Second \eTD \eTR \eTABLE}
>>  \placetable{Two}{\bTABLE \bTR \bTD Second \eTD \eTR \eTABLE}
>>\stopfloatcombination}
>> \stoptext
>
>
> Thank you for your input, Hans!
>
> I see that the captions "TABLE" and "FLOAT" are placed on top while the
> captions "Two" and "Two" are placed on the bottom. Is there a way to setup
> the locations of the captions of floats within a floatcombination? In this
> particular example, the goal is, that the captions "Two" and "Two" are
> placed on top of the respective tables.
>

 Does anybody know a way to control the caption location in
floatcombinations? Any hint would be greatly appreciated.

Regards,
Christoph
___
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
___