* Weird things...
@ 2005-12-27 17:07 Fabio Mancinelli
2005-12-27 17:45 ` Taco Hoekwater
2005-12-27 19:19 ` Hans Hagen
0 siblings, 2 replies; 5+ messages in thread
From: Fabio Mancinelli @ 2005-12-27 17:07 UTC (permalink / raw)
[-- Attachment #1: Type: text/plain, Size: 1629 bytes --]
Hi all...
I would like to report a weird behavior when compiling the attached tex
file...
If I put the background layer definitions before the columnset
definitions everything works well.
\useexternalfigure[test][buttons][frame=true]
\definelayer[graphics][x=0.5cm,y=2cm,width=\paperwidth,height=\paperheight]
\setupbackgrounds[page][background=graphics]
\definelayerpreset[lefttop][corner={left,top},location={right,bottom}]
\setlayer[graphics][preset=lefttop]{\externalfigure[test]}
\definecolumnset[threecolumns][n=3,distance=12pt]
\definecolumnsetspan[spantwo][n=2]
\definecolumnsetspan[spanthree][n=3]
\definecolumnsethsize{threecolumns}{1}{1}\OneColumn
\definecolumnsethsize{threecolumns}{1}{2}\TwoColumns
\definecolumnsethsize{threecolumns}{1}{3}\ThreeColumns
If I put them after then I get an "ERROR: Bad character code (648)"
\definecolumnset[threecolumns][n=3,distance=12pt]
\definecolumnsetspan[spantwo][n=2]
\definecolumnsetspan[spanthree][n=3]
\definecolumnsethsize{threecolumns}{1}{1}\OneColumn
\definecolumnsethsize{threecolumns}{1}{2}\TwoColumns
\definecolumnsethsize{threecolumns}{1}{3}\ThreeColumns
\useexternalfigure[test][buttons][frame=true]
\definelayer[graphics][x=0.5cm,y=2cm,width=\paperwidth,height=\paperheight]
\setupbackgrounds[page][background=graphics]
\definelayerpreset[lefttop][corner={left,top},location={right,bottom}]
\setlayer[graphics][preset=lefttop]{\externalfigure[test]}
I have spent one hour trying to figure out what was wrong with my file
and only by hasard, after having done some experiments, I put the things
in the "working" order.
Why this happens?
See you,
Fabio
[-- Attachment #2: style.tex --]
[-- Type: text/x-tex, Size: 2382 bytes --]
\setupoutput[pdftex]
\usetypescriptfile[type-zapfhumanist]
\usetypescript[map][zapfhumanist][\defaultencoding]
\usetypescript[zapfhumanist][\defaultencoding]
\setupbodyfont[zapfhumanist,sans, 10pt]
\definefont[SectionHeaderFont][ZapfHumanist-Bold at 14pt]
\definefont[SubSectionHeaderFont][ZapfHumanist-Bold at 12pt]
\definefont[SubSubSectionHeaderFont][ZapfHumanist-Bold at 10pt]
\setuplayout[
width=middle,
height=middle,
grid=yes,
topspace=1cm,
bottomspace=1cm,
header=1cm,
footer=1cm,
backspace=1cm,
]
\setuphead[section][
style=\SectionHeaderFont,
grid={line,4pt},
before=\blank,
after=\blank,
]
\setuphead[subsection][
style=\SubSectionHeaderFont,
grid={line,-4pt},
before=\blank,
after=,
]
\def\runin#1#2{#2.}
\setuphead[subsubsection][
style=\SubSubSectionHeaderFont,
command=\runin,
alternative=text,
]
\setuptolerance[strict]
\setupheadertexts[{\sl XNemesis.org Research and Development}][{\sl The vault}]
\setuppagenumbering[location=bottom]
\useexternalfigure[test][buttons][frame=true]
\definelayer[graphics][x=0.5cm,y=2cm,width=\paperwidth,height=\paperheight]
\setupbackgrounds[page][background=graphics]
\definelayerpreset[lefttop][corner={left,top},location={right,bottom}]
\setlayer[graphics][preset=lefttop]{\externalfigure[test]}
\definecolumnset[threecolumns][n=3,distance=12pt]
\definecolumnsetspan[spantwo][n=2]
\definecolumnsetspan[spanthree][n=3]
\definecolumnsethsize{threecolumns}{1}{1}\OneColumn
\definecolumnsethsize{threecolumns}{1}{2}\TwoColumns
\definecolumnsethsize{threecolumns}{1}{3}\ThreeColumns
\starttext
\startcolumnset[threecolumns]
\startcolumnsetspan[spantwo]
\bgroup
\switchtobodyfont[32pt]
{\par\noindent\bf Title very long spanning two lines}
\switchtobodyfont[20pt]
{\par\noindent\bi Subtitle}
\blank[small]
\switchtobodyfont[10pt]
{\par\noindent\bi Fabio Mancinelli $<$fm@fabiomancinelli.org$>$}
\blank[2*big]
\egroup
\stopcolumnsetspan
{\bf Abstract}\par
AbstractHere fdshfjdskf hjdskf hskjd fhskjd fhskjd fhkjdsf hkjds hfkjds fhksjd
fhskjd fhkjds fhkjdsf hk
\blank
{\bf Keywords:}
Keywords here
\dorecurse{5}{
\section{Section}
\input text
\subsection{Section}
\input text
\placefigure{Simple figure}{\externalfigure[test][width=\OneColumn]}
\subsubsection{Section}
\input text
}
\stopcolumnset
\stoptext
%%% Local Variables:
%%% mode: latex
%%% TeX-master: t
%%% End:
[-- Attachment #3: Type: text/plain, Size: 139 bytes --]
_______________________________________________
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Weird things...
2005-12-27 17:07 Weird things Fabio Mancinelli
@ 2005-12-27 17:45 ` Taco Hoekwater
2005-12-27 19:21 ` Hans Hagen
2005-12-27 19:27 ` Hans Hagen
2005-12-27 19:19 ` Hans Hagen
1 sibling, 2 replies; 5+ messages in thread
From: Taco Hoekwater @ 2005-12-27 17:45 UTC (permalink / raw)
Fabio Mancinelli wrote:
> Why this happens?
Because an interal ConTeXt macro (\dododosetlayer) is calling
a TeX primitive (\chardef) with a number that is higher than 256.
That number has become so high because of the columnset
definitions, which is why changing the ordering fixed it.
A full fix of the bug requires some work, simply changing that
one \chardef didn't cut it (the 'bad character code' moves
elsewhere).
Cheers,
Taco
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Weird things...
2005-12-27 17:07 Weird things Fabio Mancinelli
2005-12-27 17:45 ` Taco Hoekwater
@ 2005-12-27 19:19 ` Hans Hagen
1 sibling, 0 replies; 5+ messages in thread
From: Hans Hagen @ 2005-12-27 19:19 UTC (permalink / raw)
Fabio Mancinelli wrote:
> Hi all...
>
> I would like to report a weird behavior when compiling the attached
> tex file...
ah. that one took me a while .. in page-lyr.tex,
\chardef\layerpagebox\csname\@@layerbox#2\currentlayer\layerpage\endcsname
\chardef\layerbox\csname\@@layerbox#3\endcsname
should be:
\mathchardef\layerpagebox\csname\@@layerbox#2\currentlayer\layerpage\endcsname
\mathchardef\layerbox\csname\@@layerbox#3\endcsname
(column sets need lots of boxes in etex mode and then the layer box ends
up > 255 and using a chardef here is not working any more)
[you need to remake the format]
Hans
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Weird things...
2005-12-27 17:45 ` Taco Hoekwater
@ 2005-12-27 19:21 ` Hans Hagen
2005-12-27 19:27 ` Hans Hagen
1 sibling, 0 replies; 5+ messages in thread
From: Hans Hagen @ 2005-12-27 19:21 UTC (permalink / raw)
Taco Hoekwater wrote:
> Fabio Mancinelli wrote:
>
>> Why this happens?
>
>
> Because an interal ConTeXt macro (\dododosetlayer) is calling
> a TeX primitive (\chardef) with a number that is higher than 256.
> That number has become so high because of the columnset
> definitions, which is why changing the ordering fixed it.
>
> A full fix of the bug requires some work, simply changing that
> one \chardef didn't cut it (the 'bad character code' moves
> elsewhere).
it's in the \layerbox and \pagelayerbox ... (speedups and convenience)
(i wonder if i have more of such errors)
Hans
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Weird things...
2005-12-27 17:45 ` Taco Hoekwater
2005-12-27 19:21 ` Hans Hagen
@ 2005-12-27 19:27 ` Hans Hagen
1 sibling, 0 replies; 5+ messages in thread
From: Hans Hagen @ 2005-12-27 19:27 UTC (permalink / raw)
Taco Hoekwater wrote:
> Fabio Mancinelli wrote:
>
>> Why this happens?
>
>
> Because an interal ConTeXt macro (\dododosetlayer) is calling
> a TeX primitive (\chardef) with a number that is higher than 256.
> That number has become so high because of the columnset
> definitions, which is why changing the ordering fixed it.
>
> A full fix of the bug requires some work, simply changing that
> one \chardef didn't cut it (the 'bad character code' moves
> elsewhere).
another one:
\mathchardef\collectorbox\csname\@@collectorbox#1\endcsname
two times in core-box
Hans
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2005-12-27 19:27 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-12-27 17:07 Weird things Fabio Mancinelli
2005-12-27 17:45 ` Taco Hoekwater
2005-12-27 19:21 ` Hans Hagen
2005-12-27 19:27 ` Hans Hagen
2005-12-27 19:19 ` Hans Hagen
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).