ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* Strange Behaviour for toc
@ 2009-10-12 19:05 Martin Scholz
  2009-10-12 19:58 ` Martin Scholz
  0 siblings, 1 reply; 3+ messages in thread
From: Martin Scholz @ 2009-10-12 19:05 UTC (permalink / raw)
  To: ntg-context

Hallo list,

I just started to work with conTeXt, now that I seted up an project 
environment as follows with the following content:

file project_oc.tex:
--------------------

\startproject project_oc
\environment env_oc

\startfrontmatter
\setuppagenumbering[conversion=romannumerals]
\completecontent
\stopfrontmatter

\startbodymatter
\setuppagenumbering[conversion=]
\product prd_oc_0

\stopbodymatter

\startappendices

\stopappendices

\stopproject

file env_oc.tex:
----------------

\startenvironment env_oc

\enableregime [utf]
\setuplanguage [de]
[leftquote=\upperleftsinglesixquote,rightquote=
\upperrightsinglesixquote,leftquotation=\leftguillemot,rightquotation=
\rightguillemot]
\mainlanguage [de]

\setupbodyfontenvironment[default][em=italic]

\usemodule[greek]
\usemodule[units]

\setupcolors[state=start]
\setupcolor[rgb]
\definecolor[lightred][r=1,g=0.85,b=0.85]

\definefont[BigFontOne][Regular sa 3]
\definefont[BigFontTwo][RegularBold sa 2]
\definecolor[BigColorOne][r=.86,g=.850,b=.54]
\definecolor[BigColorTwo][r=.43,g=.425,b=.27]

\setuplayout[location=middle,
	topspace=1.3cm,
	width=middle,
	cutspace=4.5cm,
	rightmargindistance=0.4cm,
	leftmargindistance=0.2cm,
	backspace=1.2cm,
	height=fit,
	rightmargin=2.5cm,
	leftmargin=1cm,
	bottomspace=2cm,
	footer=0.8cm,
	setup=strict]

% \showgrid
 \showframe
% \showsetups
% \showlayout

\setuppagenumbering[alternative=doublesided,location=footer]
\setupheader[state=none]

\setuptolerance[tolerant, stretch]

\setupwhitespace[medium]

\setupfootnotes[way=bypage, conversion=set 2]

\definepagebreak[chapter][yes,footer,right]

\setuphead[chapter][textcommand=\MyChapterText,color=BigColorTwo,style=
\BigFontTwo]

\def\MyChapterText#1{\rlap{\BigFontOne\BigColorOne#1}\kern15pt#1}

\setuphead[section][numbercolor=red]

\setuphead[subsection][number=no,style=\ss]

\setuphead[subsubsection][style=slanted,number=no,before={\blank
[big]},before={\testpage[1]},after=\nowhitespace]

\setupfloats[spaceafter=3*medium]

\setuptables[bodyfont=small]
\setupcaption[table][style={\ssx\setupinterlinespace
[line=2.5ex]},align=left]

\setupfloat[table][criterium=0.5\textwidth,default=inner]

\setupcaption[figure][style={\ssx\setupinterlinespace
[line=2.5ex]},align=left]

\definefloat[Bigfigure][Bigfigures][figure]
\setupfloat[Bigfigure][location=inner]

\definefloat[Bigtable][Bigtables][table]
\setupfloat[Bigtable][location=inner]

\definefloat[vignette][figure]
\setupfloat[vignette][leftmargindistance=-
\outermargintotal,rightmargindistance=-\outermargintotal,default=
{outer,none,low}]
% \setup[vignette][number=no]

\definestartstop[Story][before={\setupbackground[style=
\tfx,background=color,backgroundcolor=white,frame=on,framecorner=rectangular,framecolor=black,rulethickness=0.5pt,topoffset=0.25cm,bottomoffset=0.25cm,leftoffset=0.25cm,rightoffset=0.25cm,before=
{\blank[big]}]\startbackground\switchtobodyfont[10pt]},after=
\stopbackground]

\definestartstop[MySummary][before={\setupbackground
[background=color,backgroundcolor=lightgray,backgroundcorner=rectangular,frame=off,topoffset=0.3cm,bottomoffset=0.3cm,leftoffset=0.5cm,rightoffset=0.5cm,before=
{\blank[big]}]\startbackground\Zus},after=\stopbackground]

\defineframedtext[Oddity][width=0.75
\textwidth,background=color,backgroundcolor=lightred,frame=off,framecorner=round,frameradius=0.5cm,backgroundcorner=round,style=
\tfx]

\setupinmargin[align=right,style=\ss\tfx\setupinterlinespace]

\setupitemize[align=right]

\startsectionblockenvironment[appendix]
\setuptabulate[align=right,split=yes]

\definepagebreak[chapter][yes,footer,right]
\setuphead[chapter][bodypartconversion=Character,page=chapter]
\setuphead[subsection][command=\SectionCommand,number=yes,numbercolor,red]
\setuphead[subsubsection][number=yes]
\definefloat[BigFramedFigure][BigFramedFigures][figure]
\setupfloat[BigFramedFigure][location=inner,frame=on,offset=2pt]
\definefloat[FramedFigure][FramedFigures][figure]
\setupfloat[FramedFigure][frame=on,offset=2pt]

\stopsectionblockenvironment

\setupregister[index][imp][pagestyle=bold]

\setupcombinedlist[content][level=2,alternative=c]
\setuplist[chapter][style=bold]

\stopenvironment

file prd_oc_0.tex:
------------------

\startproduct prd_oc_0
\project project_oc

\component c_oc0_1

\stopproduct

file c_oc0_1.tex:
-----------------
\startcomponent c_oc0_1
\product prd_oc_0
\project project_oc

\starttext
\title{Titel}
\chapter[chap:ques]{Question}
\chapter[chap:answ]{Answer}
\chapter[chap:rema]{Remarque}
\stoptext

\stopcomponent

Now Im getting doubled entries in the \completecontent part, it lists 
everything as

1 Question	5
1 Question	5
2 Answer	7
2 Answer	7

so as this is not the wished behaviour, can someone help me to solve thsi 
problem. please be patient with me to get it done right, as I'm a newbe...

Greetings

Martin

___________________________________________________________________________________
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  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Strange Behaviour for toc
  2009-10-12 19:05 Strange Behaviour for toc Martin Scholz
@ 2009-10-12 19:58 ` Martin Scholz
  2009-10-17 16:44   ` Wolfgang Schuster
  0 siblings, 1 reply; 3+ messages in thread
From: Martin Scholz @ 2009-10-12 19:58 UTC (permalink / raw)
  To: ntg-context

One thing I found out with the IRC up to know is that the error is in 
that part:

\setuphead[chapter][textcommand=\MyChapterText,color=BigColorTwo,style=
\BigFontTwo]

\def\MyChapterText#1{\rlap{\BigFontOne\BigColorOne#1}\kern15pt#1}

perhaps someone knows how one could solve it

Greetigns Martin

___________________________________________________________________________________
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  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Strange Behaviour for toc
  2009-10-12 19:58 ` Martin Scholz
@ 2009-10-17 16:44   ` Wolfgang Schuster
  0 siblings, 0 replies; 3+ messages in thread
From: Wolfgang Schuster @ 2009-10-17 16:44 UTC (permalink / raw)
  To: mailing list for ConTeXt users


Am 12.10.2009 um 21:58 schrieb Martin Scholz:

> One thing I found out with the IRC up to know is that the error is in
> that part:
>
> \setuphead[chapter][textcommand= 
> \MyChapterText,color=BigColorTwo,style=
> \BigFontTwo]
>
> \def\MyChapterText#1{\rlap{\BigFontOne\BigColorOne#1}\kern15pt#1}
>
> perhaps someone knows how one could solve it

http://www.ntg.nl/pipermail/ntg-context/2007/027083.html

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  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2009-10-17 16:44 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-10-12 19:05 Strange Behaviour for toc Martin Scholz
2009-10-12 19:58 ` Martin Scholz
2009-10-17 16:44   ` 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).