Re: [NTG-context] context mkiv bug + related feature request + related question

2009-07-19 Thread Hans Hagen

Mohamed Bana wrote:


i'd like to ask what sort of regression testing you guys are doing.  it's
very clear that things are constantly breaking, and even trivial ones but
aren't being spotted.


we have a couple of test docs but no regression suits .. there have been 
several attempts to set this up but no one is following up on that 
consistently and it's not something that taco and i are going to 
maintain (too much to do already)


anyhow, most reports about bugs refer to mkiv and esp structure related 
things; keep in mind that most counter, number conversion, multipass 
info, etc has been completely rewritten from scratch so there are 
definitely bugs esp in gray areas and since some of the control model 
has changed, we even will have differnces in configuration between mkii 
and mkiv (topic for the context meeting)


this will sort itself out as more is tested

Hans


-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
 tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com
 | www.pragma-pod.nl
-
___
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
___


Re: [NTG-context] context mkiv bug + related feature request + related question

2009-07-19 Thread Hans Hagen

Yue Wang wrote:

This bug is still not solved in the current context mkiv version.

On Mon, Jun 22, 2009 at 11:36 AM, Yue Wangyuleo...@gmail.com wrote:

Hi, Hans:


bug report :
here is the test file. (old version of mkiv produce right result.
current mkii result is also right)
It is a bug introduced in this/last month.
The code is a stripped down version of
http://wiki.contextgarden.net/Horizontal_Table_of_Contents (altough it
doesn't show toc horizontally)

\newcount\chapcounter \chapcounter=0
\def\tocchap#1#2#3{\advance\chapcounter by 1 #1 #2%
   \placelist[section][criterium=chapter,number=\chapcounter]}
\starttext
\placelist[chapter][alternative=command,command=\tocchap]
\chapter{hello} \section{hello} \section{hello}
\chapter{good} \section{good} \section{good}
\chapter{bad} \section{bad} \section{bad}
\stoptext


add \number in front of \listparameter\c!number in strc-lst.mkiv or just 
in front of your \chapcounter


\number\listparameter\c!number

(info passed to lua has to be expanded)

actually, there is in mkii:

\starttext

\placelist[chapter][after={\placelist[section][criterium=local]}]

\chapter{hello} \section{hello} \section{hello}
\chapter{good} \section{good} \section{good}
\chapter{bad} \section{bad} \section{bad}

\stoptext

but that does not yet work in mkiv


feature request:

btw, Hans, context should give an option to iterate through all the
chapters/sections to do something tricky.
using \chaptercounter is a really bad idea (the materials should
follow strict rules, like cannot jump from chap 1 to chap 3).
I think with mkiv it is able to achieve that.


sure, but that's for later; the mkiv structure code has much more 
possibilities but first i want to have the standard features complete 
and debugged



question:

I want to show toc before each chapter, and the toc only shows the
following chapter name in red.
How can I do that?
e.g. show the following before chapter 3

% A Page
Chap1
sec 1 sec 2 sec 3
Chap2
sec 1 sec 2 sec 3
Chap 3  %in red
sec 1 sec 2 sec 3 %in Red
Chap4
sec 1 sec 2 sec 3
% Next Page
Chapter 3 % title
a lot of materials


Yue Wang


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



--

-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
 tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com
 | www.pragma-pod.nl
-
___
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
___


[NTG-context] figure can not be found error

2009-07-19 Thread Tom
I am attempting for the first time to import a figure into a ConTeXt
document and am getting figure 0481c can not be found. I am using TexLive
on a Windows Vista system. I thought I was following the manual but
apparently am doing something wrong. Here is the relevant code:
 
%file 0481c.tif is located in c:\BookLayouts\Wisconsin\photos
 
\setupexternalfigures[directory={c:/BookLayouts/Wisconsin/photos}]
 
\useexternalfigure[ladies][0481c][width=3.127in]
 
%after \starttext
 
\placefigure[left]{none}{\externalfigure[ladies]}
 
 
Tom Benjey
Tuxedo Press
717-258-9733 voice
717-243-0074 fax
Twitter: @TomBenjey
 
 
 
___
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
___


Re: [NTG-context] figure can not be found error

2009-07-19 Thread Hans Hagen

Tom wrote:

I am attempting for the first time to import a figure into a ConTeXt
document and am getting figure 0481c can not be found. I am using TexLive
on a Windows Vista system. I thought I was following the manual but
apparently am doing something wrong. Here is the relevant code:
 
%file 0481c.tif is located in c:\BookLayouts\Wisconsin\photos
 
\setupexternalfigures[directory={c:/BookLayouts/Wisconsin/photos}]
 
\useexternalfigure[ladies][0481c][width=3.127in]
 
%after \starttext
 
\placefigure[left]{none}{\externalfigure[ladies]}


tiff is not supported directly (the format is simply too open ended) so 
use png instead of convert them them to pdf beforehand


Hans


-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
 tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com
 | www.pragma-pod.nl
-
___
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
___


Re: [NTG-context] figure can not be found error

2009-07-19 Thread luigi scarso
On Sun, Jul 19, 2009 at 3:43 PM, Tom t...@tuxedo-press.com wrote:

  I am attempting for the first time to import a figure into a ConTeXt
 document and am getting “figure 0481c can not be found.” I am using TexLive
 on a Windows Vista system. I thought I was following the manual but
 apparently am doing something wrong. Here is the relevant code:



 %file 0481c.tif is located in c:\BookLayouts\Wisconsin\photos



A good option is to convert a tiff file in pdf; see
http://gnuwin32.sourceforge.net/packages/tiff.htm

 (untested, I'm under Linux)
-- 
luigi
___
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
___


[NTG-context] join references with extra argument

2009-07-19 Thread Xan

Hi,
I have \cite[extras={, Proposició~6.6}][grillet] \cite[extras={, 
Proposició~1.6}][cgt] and it shows me:


[1, Proposició 6.6] [2, Proposició 1.6]

It's possible to write code for displaying something like:

[1, Proposició 6.6; 2, Proposició 1,6]


Thanks,
Xan.
___
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
___


Re: [NTG-context] alpha release

2009-07-19 Thread Alan BRASLAU
Hi experts,

Would someone please provide a basic recipe to correctly install the new alpha 
release locally.  I would like to test the new alpha code but am a bit 
confused as to what exactly to install and how.


1. on the website, is this indeed
http://www.pragma-ade.com/context/current/cont-tmf.zip
as
http://www.pragma-ade.com/download-3.htm
currently lists as (not available)?

Should this be unzipped under /usr/local/context.alpha/tex/texmf-context
for example?


2. no beta as mkiv needs the trunk version of luatex
Does this mean
http://foundry.supelec.fr/gf/download/frsrelease/350/1332/luatex-
snapshot-0.42.0.tar.bz2
to be compiled and then somehow installed into the local tree.

From luatex-snapshot-0.42.0/INSTALL

 Post-compilation installation should be a simple matter
 of copying the executable to a normal place for web2c
 binaries and generating the desired formats.
 
 You may want to install the executable under the names
 'texlua' and 'texluac' as well (create a copy or symlink)

I currently work with the contextgarden minimals.
Under the minimals, these are located at
tex/texmf-linux-64/bin/texlua
tex/texmf-linux-64/bin/texluac
on my machine.


Sorry for such basic questions.

Thanks

Alan




On Tuesday 14 July 2009 19:39:09 Hans Hagen wrote:
 Hi

 I've put an alpha release on the website

 - no beta as mkiv needs the trunk version of luatex
 - a close to complete split in mkii/mkiv
 - cleaned up mkiv code
 - cleaned up mkiv backend (some pending issues)
 - some speedups in mkiv
 - a few fixes in mkii
 - updated mkiv typescripts (more to come)
 - fixes in mkiv structure

 this version is not replicated on the context garden as we run older
 luatex binaries there (0.45 release by the end of this month)

 you can unzip this file on your locla tree but best first rename the
 tex/context/base directory and make a fresh one as otherwise you end up
 with a weird mixture (due to the definitive split in .mkii/.mkiv there
 are not that many shared .tex files any more)

 on the upcoming tex live there will be an updated mkii (either this one
 or the current beta which is basically a current for mkii) and an old
 mkiv (maybe the beta) or a new one but that one will not run then with
 the luatex on texlive as it is too old; this is no big deal as you can
 either use the minimals or use the new updater in the upcoming tex live
 to fetch newer binaries (norbert and mojca showed that trickery at
 bachotek 2009)

 next on the mkiv agenda is an upgrade/rework of everything related to
 page building but it might as well be postponed till we have a bit more
 access (which will happen sometime after eurotex); the first priority is
 to get the new structure related code right but as idris is already
 publising books made by mkiv it's not that bad as it sounds.

 Hans

 -
Hans Hagen | PRAGMA ADE
Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
   tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com

   | www.pragma-pod.nl

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


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


Re: [NTG-context] alpha release

2009-07-19 Thread Aditya Mahajan

On Sun, 19 Jul 2009, Alan BRASLAU wrote:


Would someone please provide a basic recipe to correctly install the new alpha
release locally.  I would like to test the new alpha code but am a bit
confused as to what exactly to install and how.


The alpha has now been merged with the beta and  so, ...


I currently work with the contextgarden minimals.
Under the minimals, these are located at
tex/texmf-linux-64/bin/texlua
tex/texmf-linux-64/bin/texluac
on my machine.



just run first-setup.sh again.

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
___


Re: [NTG-context] alpha release

2009-07-19 Thread Mojca Miklavec
On Sun, Jul 19, 2009 at 20:58, Aditya Mahajan wrote:
 On Sun, 19 Jul 2009, Alan BRASLAU wrote:

 Would someone please provide a basic recipe to correctly install the new
 alpha
 release locally.  I would like to test the new alpha code but am a bit
 confused as to what exactly to install and how.

 The alpha has now been merged with the beta and  so, ...

True. Now you can either use beta or current and it should give you
the latest functionality for both ConTeXt and LuaTeX (2009.07.17,
0.42.0).

Alpha has disappeared in the meantime.

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


Re: [NTG-context] alpha release

2009-07-19 Thread Alan BRASLAU
On Sunday 19 July 2009 20:58:19 Aditya Mahajan wrote:

 The alpha has now been merged with the beta and  so, ...

 just run first-setup.sh again.

 Aditya

Thanks.
I can do that!

- ConTeXt  ver: 2009.06.14 21:01 MKIV  fmt: 2009.7.19  int: english/english
- this is luatex, version beta-0.42.0-2009071807

OK

However, I was expecting

\usetypescript[postscript]
\starttext
default: $A = \pi r^2$
\switchtobodyfont[postscript]
postscript: $A = \pi r^2$
\stoptext

at least to be fixed. Not yet...

I'll continue other tests (and keep reading the mailing list).

Alan

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


Re: [NTG-context] alpha release

2009-07-19 Thread Mojca Miklavec
On Sun, Jul 19, 2009 at 21:19, Alan BRASLAU wrote:
 On Sunday 19 July 2009 20:58:19 Aditya Mahajan wrote:

 The alpha has now been merged with the beta and  so, ...

 just run first-setup.sh again.

 Aditya

 Thanks.
 I can do that!

 - ConTeXt  ver: 2009.06.14 21:01 MKIV  fmt: 2009.7.19  int: english/english
 - this is luatex, version beta-0.42.0-2009071807

I'm sorry, I forgot to uncomment a line, so there's actually a newer
version. By the time when you replied this has been fixed, but you
have probably synced earlier.

 However, I was expecting

 \usetypescript[postscript]
 \starttext
 default: $A = \pi r^2$
 \switchtobodyfont[postscript]
 postscript: $A = \pi r^2$
 \stoptext

 at least to be fixed. Not yet...

But it's not fixed in 2009.07.17 either, so updating won't help too much.

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


[NTG-context] First page of chapter layout

2009-07-19 Thread Tom
The assistance for my last question came quickly and was so helpful that I
will go back to the well.
 
How does one go about changing the layout for the first pages of a chapter?
By default, I get the chapter number and title in large print at the top of
the page but want to make it something more interesting. My experiments with
\setuphead haven't been fruitful.
 
Tom Benjey
Tuxedo Press
 
___
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
___


[NTG-context] PDF Keywords in current beta

2009-07-19 Thread Andreas Schneider
Hello,

in the current beta the usage of the Keyword argument in the
\setupinteraction command causes lua to fail in line 136 of
lpdf-mis.lua:

code snippet
local keywords = specification.keywords or  if keywords ~=  then
keywords = string.gsub([%s,]+,  )
lpdf.addtoinfo(Keywords,pdfunicode(keywords))
end
/code snippet


error
! LuaTeX
error ...text/tex/texmf-context/tex/context/base/lpdf-mis.lua:136: bad
argument #3 to 'gsub' (string/function/table expected)
/error


I don't know what is expected there since I don't know the PDF specs,
but I guess it's easily fixable ;-)

Best Regards,
Andreas.

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