Re: [NTG-context] two newbie questions (about conditional processing)

2009-05-25 Thread Zhichu Chen
On Sun, May 24, 2009 at 6:36 PM, Hans Hagen pra...@wxs.nl wrote:

 something like state=once would be handy but i'm not going to touch that
 code till i'm redoing some page-* code in mkiv
I don't get it, the once made me confused. Should that just be
affectedpage=current or range={1,2,15} which will make more
sense to me. I don't know the range for once

Anyway, hi Yue, this small test file may be useful:

% \tracingmacros=2

\def\Reverse
  {\global\negateprintboxtrue
   \appendtoks\global\negateprintboxfalse\to\afterpage}

\setuphead
  [chapter]
  [before=\Reverse]

\setupcolors[state=start]

\starttext

\dorecurse{10}{\input zapf\par}

\chapter{hello}
\dorecurse{10}{\input zapf\par}

\chapter{hello}
\dorecurse{10}{\input zapf\par}

\chapter{hello}
\dorecurse{10}{\input zapf\par}

\stoptext


 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
 ___




-- 
Best Regards
Chen


  Zhi-chu Chen | Shanghai Synchrotron Radiation Facility
 No. 2019 | Jialuo Rd. | Jiading | Shanghai | P.R. China
 tel: 086 21 5955 3405 | zhichu.chen.googlepages.com
   | www.sinap.ac.cn

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

2009-05-25 Thread Taco Hoekwater


Hi Hraban,

Your questions are more about luatex than about context, I think
(you _are_ talking about mkiv, yes?)

Henning Hraban Ramm wrote:

Ahoi,
(1)
there's an ongoing thread on the German mailing list (TeX-D-L), if it 
would be possible to implement weighted(?) hyphenation, i.e. that some 
breaks are better than other, e.g.

Do-nau---dampf--schiff---fahrt
Wa-ren---wirt--schaft
Eu-ro-pa---par-la--ment
(In InDesign I can suggest such priorities if I add words to the user 
dictionary.)


There is a tracker item to that effect:

  http://tracker.luatex.org/view.php?id=168

but it has no planned deadline yet.


(2)
Uses ConTeXt the same hyphenation algorithm as LaTeX? Or one of the 
newer projects? (perhaps SiSiSi?)


At the moment, the functionality of \patterns in luatex is the same as
in pdf(tex) except that the hyphenation patterns are fully UTF-8.


(3)
Further, I wonder why \hyphenation{} is case dependend - in my last 
project Secretary General was wrongly hyphenated, but 
\hyphenation{se-cre-ta-ry} didn't fix it, I needed 
\hyphenation{Se-cre-ta-ry}. Does that make sense?


Not so much. At first sight, this looks like a luatex bug. I will 
investigate.


Best wishes,
Taco

___
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] two newbie questions (about conditional processing)

2009-05-25 Thread Hans Hagen

Zhichu Chen wrote:

On Sun, May 24, 2009 at 6:36 PM, Hans Hagen pra...@wxs.nl wrote:

something like state=once would be handy but i'm not going to touch that
code till i'm redoing some page-* code in mkiv

I don't get it, the once made me confused. Should that just be
affectedpage=current or range={1,2,15} which will make more
sense to me. I don't know the range for once


well, we have already

state=repeat: same background each upcoming page
state=start : enable background (calculate each time)
state=stop  : disable backgrond

so we would have

state=once  : enable background and after this page disable it

in this case 'once' is kind of start before and stop after \page

a range makes not much sense as one seldom knows the page in advance so 
that would then be named pages; however, as we have 25 page areas it 
would involve more testing then i currently want to do (the otr is 
already not that fast)




-
  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] two newbie questions (about conditional processing)

2009-05-25 Thread Wolfgang Schuster


Am 25.05.2009 um 08:55 schrieb Zhichu Chen:


On Sun, May 24, 2009 at 6:36 PM, Hans Hagen pra...@wxs.nl wrote:


something like state=once would be handy but i'm not going to touch  
that

code till i'm redoing some page-* code in mkiv


I don't get it, the once made me confused. Should that just be
affectedpage=current or range={1,2,15} which will make more
sense to me. I don't know the range for once

Anyway, hi Yue, this small test file may be useful:


Very nice but it shows only up in Adobe Reader and you can't select
the color for the background.

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


Re: [NTG-context] two newbie questions (about conditional processing)

2009-05-25 Thread Zhichu Chen
On Mon, May 25, 2009 at 3:12 PM, Hans Hagen pra...@wxs.nl wrote:

 well, we have already

 state=repeat: same background each upcoming page
 state=start : enable background (calculate each time)
 state=stop  : disable backgrond

 so we would have

 state=once  : enable background and after this page disable it

 in this case 'once' is kind of start before and stop after \page
Cool, I'm looking forward to that.

 a range makes not much sense as one seldom knows the page in advance so that
 would then be named pages; however, as we have 25 page areas it would
 involve more testing then i currently want to do (the otr is already not
 that fast)
No we won't know the page numbers so forget mine.

There's just one other thing: since we are changing background colors,
we probably need the text colors to be changed as well. But by searching
the sources, I only get the negative color scheme which is some sort of
pdf specials or gs specials. I mean can we just customize such configurations
ourselves? Like colorscheme={inverse+0.1} will inverse the color and reduce
the RGB value to 10%. Then my little test file could make more useful.





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




-- 
Best Regards
Chen


  Zhi-chu Chen | Shanghai Synchrotron Radiation Facility
 No. 2019 | Jialuo Rd. | Jiading | Shanghai | P.R. China
 tel: 086 21 5955 3405 | zhichu.chen.googlepages.com
   | www.sinap.ac.cn

___
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] two newbie questions (about conditional processing)

2009-05-25 Thread Zhichu Chen
On Mon, May 25, 2009 at 3:30 PM, Wolfgang Schuster
schuster.wolfg...@googlemail.com wrote:

 Am 25.05.2009 um 08:55 schrieb Zhichu Chen:

 On Sun, May 24, 2009 at 6:36 PM, Hans Hagen pra...@wxs.nl wrote:

 something like state=once would be handy but i'm not going to touch that
 code till i'm redoing some page-* code in mkiv

 I don't get it, the once made me confused. Should that just be
 affectedpage=current or range={1,2,15} which will make more
 sense to me. I don't know the range for once

 Anyway, hi Yue, this small test file may be useful:

 Very nice
Thank you:)

 but it shows only up in Adobe Reader
I don't know what's that mean.

 and you can't select
 the color for the background.
No, I can't. I'm trying to figure out how to make a more interesting
test file.


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




-- 
Best Regards
Chen


  Zhi-chu Chen | Shanghai Synchrotron Radiation Facility
 No. 2019 | Jialuo Rd. | Jiading | Shanghai | P.R. China
 tel: 086 21 5955 3405 | zhichu.chen.googlepages.com
   | www.sinap.ac.cn

___
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] two newbie questions (about conditional processing)

2009-05-25 Thread Wolfgang Schuster


Am 25.05.2009 um 09:42 schrieb Zhichu Chen:


but it shows only up in Adobe Reader

I don't know what's that mean.


You have to view the PDF view Adobe Reader to see effect for
the chapter page, when I open the file with Preview App the chapter
page has black text on a white background.

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


Re: [NTG-context] two newbie questions (about conditional processing)

2009-05-25 Thread Wolfgang Schuster


Am 25.05.2009 um 09:12 schrieb Hans Hagen:


well, we have already

state=repeat: same background each upcoming page
state=start : enable background (calculate each time)
state=stop  : disable backgrond


These settings have no effect on the background color, you can control
with them only the background layer (overlays) :(

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


Re: [NTG-context] two newbie questions (about conditional processing)

2009-05-25 Thread Hans Hagen

Wolfgang Schuster wrote:


Am 25.05.2009 um 09:12 schrieb Hans Hagen:


well, we have already

state=repeat: same background each upcoming page
state=start : enable background (calculate each time)
state=stop  : disable backgrond


These settings have no effect on the background color, you can control
with them only the background layer (overlays) :(


ok

well, i mostly use overlays for background colors anyway -)

-
  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] indices

2009-05-25 Thread Charles Doherty

Dear Taco,

You are a genius. Works a treat!

Thank you very much.

Charlie
On 24 May 2009, at 17:05, Taco Hoekwater wrote:


Remember this:

\unprotect
\def\insertkeywords#1#2#3%
 {\bibdoifelse{\@@p...@keywords}
{%
 #1\@@p...@keywords #2%
 \processcommacommand[\@@p...@keywords]\index
}
{#3}%
 }
\protect

Drop the #1 .. #2 line and it will no longer typeset anything:


___
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] defineremapper as default (in style file)

2009-05-25 Thread luigi scarso
On Fri, May 22, 2009 at 8:11 PM, Hans Hagen pra...@wxs.nl wrote:

 Peter Münster wrote:

 Hello,

 I would like to activate a remapper in a style or module file. How could
 this be done?

 I tried this without success:

 \defineremapper[filterItem]
 \remapcharacter[filterItem][`•]{\item}
 \appendtoks \startfilterItem \to \everystarttext
 \prependtoks \stopfilterItem  \to \everystoptext




 kep in mind that the remapper is just a hack and will not be extended etc
 etc; i'm not going to handle interferences with other mechanisms


 Hans



I think the point is this :
in some situations one find useful to convert things like • in macros like
\item .
Of course, it can be done with  preprocessing , or with some ad-hoc macros
in lua code , etc
So, apart \remapcharacter, are there  any other safe ways to remap
character ?


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


Re: [NTG-context] defineremapper as default (in style file)

2009-05-25 Thread Hans Hagen

luigi scarso wrote:

On Fri, May 22, 2009 at 8:11 PM, Hans Hagen pra...@wxs.nl wrote:


Peter Münster wrote:


Hello,

I would like to activate a remapper in a style or module file. How could
this be done?

I tried this without success:

\defineremapper[filterItem]
\remapcharacter[filterItem][`•]{\item}
\appendtoks \startfilterItem \to \everystarttext
\prependtoks \stopfilterItem  \to \everystoptext




kep in mind that the remapper is just a hack and will not be extended etc
etc; i'm not going to handle interferences with other mechanisms




Hans




I think the point is this :
in some situations one find useful to convert things like • in macros like
\item .
Of course, it can be done with  preprocessing , or with some ad-hoc macros
in lua code , etc
So, apart \remapcharacter, are there  any other safe ways to remap
character ?


one solution mentioned was making that character active and then do an 
unexpanded def which makes it roundtrip safe;  of course we should leave 
characters like : untouched


the remapper works on all input and it might result in unwanted side 
effects .. imagine that someone defines symbol 1 as • and gets \item 
instead


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] defineremapper as default (in style file)

2009-05-25 Thread Peter Münster
On Mon, 25 May 2009, luigi scarso wrote:

 I think the point is this :
 in some situations one find useful to convert things like • in macros like
 \item .
 Of course, it can be done with  preprocessing , or with some ad-hoc macros in
 lua code , etc
 So, apart \remapcharacter, are there  any other safe ways to remap character
 ?

Wolfgang mentioned the method with active character.
And there is also this one:

\startluacode
function my_replace(line)
return line:gsub('• ', '\\item ')
end
callback.register('process_input_buffer', my_replace)
\stopluacode
\starttext
\startitemize
• bla
• bla
• bla
\stopitemize
\stoptext

I like the latter one, because it permits also replacing whole words and
much more. But you need to be careful, see also:
http://archive.contextgarden.net/message/20080404.200709.454e4740.en.html
;)

Cheers, Peter

-- 
Contact information: http://pmrb.free.fr/contact/

___
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] defineremapper as default (in style file)

2009-05-25 Thread luigi scarso
On Mon, May 25, 2009 at 12:17 PM, Hans Hagen pra...@wxs.nl wrote:

 luigi scarso wrote:

 On Fri, May 22, 2009 at 8:11 PM, Hans Hagen pra...@wxs.nl wrote:

  Peter Münster wrote:

  Hello,

 I would like to activate a remapper in a style or module file. How could
 this be done?

 I tried this without success:

 \defineremapper[filterItem]
 \remapcharacter[filterItem][`•]{\item}
 \appendtoks \startfilterItem \to \everystarttext
 \prependtoks \stopfilterItem  \to \everystoptext


  kep in mind that the remapper is just a hack and will not be extended etc
 etc; i'm not going to handle interferences with other mechanisms


  Hans



 I think the point is this :
 in some situations one find useful to convert things like • in macros like
 \item .
 Of course, it can be done with  preprocessing , or with some ad-hoc macros
 in lua code , etc
 So, apart \remapcharacter, are there  any other safe ways to remap
 character ?


 one solution mentioned was making that character active and then do an
 unexpanded def which makes it roundtrip safe;  of course we should leave
 characters like : untouched


there was an article many years ago something like Active characters -- No
thank you


 the remapper works on all input and it might result in unwanted side
 effects .. imagine that someone defines symbol 1 as • and gets \item instead

this is true -- it's not a general solution it's a trick , it if you abuse
then



 Hans


Maybe I'm not able to express what I mean .
-- 
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
___


Re: [NTG-context] defineremapper as default (in style file)

2009-05-25 Thread luigi scarso
On Mon, May 25, 2009 at 12:18 PM, Peter Münster pmli...@free.fr wrote:

 On Mon, 25 May 2009, luigi scarso wrote:

  I think the point is this :
  in some situations one find useful to convert things like • in macros
 like
  \item .
  Of course, it can be done with  preprocessing , or with some ad-hoc
 macros in
  lua code , etc
  So, apart \remapcharacter, are there  any other safe ways to remap
 character
  ?

 Wolfgang mentioned the method with active character.
 And there is also this one:

 \startluacode
 function my_replace(line)
return line:gsub('• ', '\\item ')
 end
 callback.register('process_input_buffer', my_replace)
 \stopluacode
 \starttext
 \startitemize
 • bla
 • bla
 • bla
 \stopitemize
 \stoptext

 I like the latter one, because it permits also replacing whole words and
 much more. But you need to be careful, see also:
 http://archive.contextgarden.net/message/20080404.200709.454e4740.en.html
 ;)


This is what I mean .

-- 
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] Problem with bibl-aps style?

2009-05-25 Thread Charles Doherty

Dear Taco,

When I use bibl-aps  [9] below is incollection and [10] is book. As  
you can see the title is missing in [9]. I did a fresh download of  
Minimals this morning in case my bibl-aps was corrupt but the result  
is as below.


Any advice? And apologies for bothering you so soon again.

Very best wishes,
Charlie





Snippet.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://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] Problem with bibl-aps style?

2009-05-25 Thread Taco Hoekwater

Charles Doherty wrote:

Dear Taco,

When I use bibl-aps  [9] below is incollection and [10] is book. As you 
can see the title is missing in [9]. I did a fresh download of Minimals 
this morning in case my bibl-aps was corrupt but the result is as below.


Any advice? And apologies for bothering you so soon again.


In bibl-aps.tex, the \insertarttitle is commented out (line 288). I
have no idea whether that is 'officially' correct or not, but you could
remove the comment sign and see if the result pleases you.

Best wishes,
Taco

___
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] Seeking a Deeper ConTeXt: Questions for Initializing

2009-05-25 Thread John Haltiwanger
On Sun, May 24, 2009 at 2:35 PM, Henning Hraban Ramm hra...@fiee.netwrote:

 Am 2009-05-24 um 19:17 schrieb John Haltiwanger:

  1) Can environment files be used across documents, or is it generally
 understood that every ConTeXt document requires its own environment
 formatting? (The latter is the view of someone on c.t.t, who said his
 perception of ConTeXt was that it was for typesetting individual documents
 and had less application beyond that domain.)


 Normally you use environment files for coherent projects (magazines, books)
 or sets of similar documents (letters, presentations).

 The difference in usage between a LaTeX document class and a ConTeXt
 environment is neglectable IMO. The real difference is that most LaTeX users
 just *use* some document class unchanged, because LaTeX doesn't encourage
 defining your own, while there are nearly no ready-to-use ConTeXt
 environments available and most ConTeXt users want write their own anyway.

 For one-off documents I put everything in one file (and perhaps copy setup
 bits from other one-off files or environments).

 If *I* require a special layout for a single document, I normally use
 InDesign. The effort of programming a setup or an environment pays off
 only if you use it more often IMO.



These paragraphs seems to contradict. ConTeXt is useful if you use an
environment more than once, but there are no ready-to-use ConTeXt
environments.

I am not averse to rolling my own, I am just confused why, if environments
are so powerful and flexible (flexible meaning one can easily change things,
unlike document classes), there are no pre-rolled environments available. I
am thinking here of standardized thesis environments for universities, or a
nice letter environment to demonstrate the beauty of TeX.


 2) What is the state of XML output for ConTeXt files? I have to say I will
 find it hard to justify using TeX for documents if it means they are not
 translatable to XML easily. I'm also interested in any RDF support ConTeXt
 might have.


XML is no target format for any TeX implementation.
 XML is a source format, and a good one if you want to process (typeset) it
 with ConTeXt (and perhaps make HTML from the same source).

 What do you mean with RDF? This one?: http://www.w3.org/RDF/
 Or did you mean RTF?


Yes, I meant RDF. XML is a very important format. I find it odd that TeX can
generate PDF but cannot output simple XML. So in order to have a semantical
document I must write it in XML and then process it with ConTeXt? Is the
capacity there (through LuaTeX perhaps) to write an XML generator?

While I would expect the reasons for wanting XML output would be obvious, a
concrete example is that at least one journal is deprecating LaTeX because
it wants to archive all of its articles in XML.

Regards,
John C. Haltiwanger
___
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] Seeking a Deeper ConTeXt: Questions for Initializing

2009-05-25 Thread Hans Hagen

John Haltiwanger wrote:

On Sun, May 24, 2009 at 2:35 PM, Henning Hraban Ramm hra...@fiee.netwrote:


Am 2009-05-24 um 19:17 schrieb John Haltiwanger:

 1) Can environment files be used across documents, or is it generally

understood that every ConTeXt document requires its own environment
formatting? (The latter is the view of someone on c.t.t, who said his
perception of ConTeXt was that it was for typesetting individual documents
and had less application beyond that domain.)


Normally you use environment files for coherent projects (magazines, books)
or sets of similar documents (letters, presentations).

The difference in usage between a LaTeX document class and a ConTeXt
environment is neglectable IMO. The real difference is that most LaTeX users
just *use* some document class unchanged, because LaTeX doesn't encourage
defining your own, while there are nearly no ready-to-use ConTeXt
environments available and most ConTeXt users want write their own anyway.

For one-off documents I put everything in one file (and perhaps copy setup
bits from other one-off files or environments).

If *I* require a special layout for a single document, I normally use
InDesign. The effort of programming a setup or an environment pays off
only if you use it more often IMO.




These paragraphs seems to contradict. ConTeXt is useful if you use an
environment more than once, but there are no ready-to-use ConTeXt
environments.


setting up a style for a paper takes a few commands: \setuplayout, 
\setuphead, \setupheadertexts ... and then structure in your document 
can do the rest; however, if we have styles of (say) 40 lines of code, 
users want a different font, diferen theaders etc and patch those 40 
lines which then gives 80 lines most of which are redundant


i've seen that happen a lot: copy an old style, then patch 50%, copy 
that file, patch again, and eventually one gets a big style that is 90% 
code that does more harm than good


as context does need a style to start with, you can just start working 
and then every time you wonder if it should look different, you add a 
few lines to the preamble or style (more fun that way too)



I am not averse to rolling my own, I am just confused why, if environments
are so powerful and flexible (flexible meaning one can easily change things,
unlike document classes), there are no pre-rolled environments available. I
am thinking here of standardized thesis environments for universities, or a
nice letter environment to demonstrate the beauty of TeX.


sure, but all organizations want it slightly different


 2) What is the state of XML output for ConTeXt files? I have to say I will

find it hard to justify using TeX for documents if it means they are not
translatable to XML easily. I'm also interested in any RDF support ConTeXt
might have.



XML is no target format for any TeX implementation.

XML is a source format, and a good one if you want to process (typeset) it
with ConTeXt (and perhaps make HTML from the same source).

What do you mean with RDF? This one?: http://www.w3.org/RDF/
Or did you mean RTF?



Yes, I meant RDF. XML is a very important format. I find it odd that TeX can
generate PDF but cannot output simple XML. So in order to have a semantical
document I must write it in XML and then process it with ConTeXt? Is the
capacity there (through LuaTeX perhaps) to write an XML generator?


sure, but how useful is it to have a representation of (e.g.) a node 
list that makes up a paragraph in xml format? no app can do something 
with it


maybe at some point the adobe and microsoft xml output formats become an 
option (which then involves resources like fonts and graphics as well so 
 it's pretty bulky and one might wonder what gain there is)



While I would expect the reasons for wanting XML output would be obvious, a
concrete example is that at least one journal is deprecating LaTeX because
it wants to archive all of its articles in XML.


in which case it keeps the input in xml and converts to other formats 
(coule be tex in the case of rendering print)



-
  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] Seeking a Deeper ConTeXt: Questions for Initializing

2009-05-25 Thread Wolfgang Schuster


Am 25.05.2009 um 18:30 schrieb John Haltiwanger:

I am not averse to rolling my own, I am just confused why, if  
environments
are so powerful and flexible (flexible meaning one can easily change  
things,
unlike document classes), there are no pre-rolled environments  
available. I
am thinking here of standardized thesis environments for  
universities, or a

nice letter environment to demonstrate the beauty of TeX.



There are a lot of letter styles are available for ConTeXt, what's  
wrong with them?


• http://wiki.contextgarden.net/Letter_style
• http://wiki.contextgarden.net/Letter

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


Re: [NTG-context] Seeking a Deeper ConTeXt: Questions for Initializing

2009-05-25 Thread John Haltiwanger

  I am not averse to rolling my own, I am just confused why, if environments
 are so powerful and flexible (flexible meaning one can easily change
 things,
 unlike document classes), there are no pre-rolled environments available.
 I
 am thinking here of standardized thesis environments for universities, or
 a
 nice letter environment to demonstrate the beauty of TeX.


 sure, but all organizations want it slightly different


Okay, but that does imply that an organization can set up an environment and
expect its members to use it.



 Yes, I meant RDF. XML is a very important format. I find it odd that TeX
 can
 generate PDF but cannot output simple XML. So in order to have a
 semantical
 document I must write it in XML and then process it with ConTeXt? Is the
 capacity there (through LuaTeX perhaps) to write an XML generator?


 sure, but how useful is it to have a representation of (e.g.) a node list
 that makes up a paragraph in xml format? no app can do something with it


I'm not sure what you mean by a representation of a node list for a
paragraph (I am new to TeX, remember), but I am thinking more along the
lines of extracting Title, Author, and the content. Typesetting is not the
goal, as XML is for computers not people.


 maybe at some point the adobe and microsoft xml output formats become an
 option (which then involves resources like fonts and graphics as well so
  it's pretty bulky and one might wonder what gain there is)


The gain of XML is participation in the semantic web and concordance with
many new data keeping rules in governments and organizations.

 While I would expect the reasons for wanting XML output would be obvious, a
 concrete example is that at least one journal is deprecating LaTeX because
 it wants to archive all of its articles in XML.


in which case it keeps the input in xml and converts to other formats (coule
 be tex in the case of rendering print)


 The input is actually a specific version of Word. This is converted to XML.
In the case of LaTeX, the LaTeX is converted to Word and then to XML.
___
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] Seeking a Deeper ConTeXt: Questions for Initializing

2009-05-25 Thread Hans Hagen

John Haltiwanger wrote:


Okay, but that does imply that an organization can set up an environment and
expect its members to use it.


indeed, of seek help in doing so (not much different from setting up a 
housestyle for word ro whatever)



I'm not sure what you mean by a representation of a node list for a
paragraph (I am new to TeX, remember), but I am thinking more along the
lines of extracting Title, Author, and the content. Typesetting is not the
goal, as XML is for computers not people.


glyph font='1' char='123'kern width='1pt'glyph font='1' char='456'

etc .. the result of typeseting (kind of application xml which actually 
much of the xml around is)



The gain of XML is participation in the semantic web and concordance with
many new data keeping rules in governments and organizations.


that should happen with the source, ot the typeset result

- structured document in xml format
- rendering to the web using xslt and xhtml and css
- rendering for paper using tex
- analysing for whatever purpose using xml toolkits


 The input is actually a specific version of Word. This is converted to XML.
In the case of LaTeX, the LaTeX is converted to Word and then to XML.


i'd then go from latex directly to xml (given enough structure) but even 
workflows like word - xml - context are quite doable


Hans

ps most of our work here involves making styles and going from word/xml 
- pdf (either or not reassembled) using context


-
  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] Seeking a Deeper ConTeXt: Questions for Initializing

2009-05-25 Thread Mohamed Bana
my personal favourite 
http://thread.gmane.org/gmane.comp.tex.context/44368/focus=46254, beware 
you might have trouble getting that to compile with a new version of LuaTeX.


John Haltiwanger wrote:



On Mon, May 25, 2009 at 12:50 PM, Wolfgang Schuster 
schuster.wolfg...@googlemail.com 
mailto:schuster.wolfg...@googlemail.com wrote:



Am 25.05.2009 um 18:30 schrieb John Haltiwanger:


I am not averse to rolling my own, I am just confused why, if
environments
are so powerful and flexible (flexible meaning one can easily
change things,
unlike document classes), there are no pre-rolled environments
available. I
am thinking here of standardized thesis environments for
universities, or a
nice letter environment to demonstrate the beauty of TeX.



There are a lot of letter styles are available for ConTeXt, what's
wrong with them?

• http://wiki.contextgarden.net/Letter_style
• http://wiki.contextgarden.net/Letter

Wolfgang


Thank you for those! I had not come across them yet. I was responding to 
Henning's statement that there are nearly no ready-to-use ConTeXt 
environments available. In fact I realize I had misread that until 
right now, having missed the 'nearly' that qualifies the statement. 
Sorry for the confusion.



Also, I don't want it to seem like I don't enjoy rolling my own 
documents. While I'm new at it, I quite like interfacing with documents 
in this 'programming' way.


Thank you,
John C. Haltiwanger




___
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] Seeking a Deeper ConTeXt: Questions for Initializing

2009-05-25 Thread Arthur Reutenauer
 These paragraphs seems to contradict. ConTeXt is useful if you use an
 environment more than once, but there are no ready-to-use ConTeXt
 environments.

  You're probably confused by the term environment.  It means
something very specific in ConTeXt, see for example section 2.3 of
http://www.pragma-ade.com/general/manuals/cont-eni.pdf

  If by environment you mean some less down-to-earth, general document
layout, e.g. for articles, books, presentation slides or letters, then
yes, there are such ready-to-use layouts.  Not always in the ConTeXt
core, but they're there; for example, for letters you would use Wolfgang
Schuster's letter module; for presentation, one of the solutions is
Thomas Schmitz' and Aditya Mahajan's simple-presentation module, etc.

 Yes, I meant RDF. XML is a very important format. I find it odd that TeX can
 generate PDF but cannot output simple XML.

  Generating a document with a logical structure is really the opposite
of what TeX does, at least in my view: in today's trend, you write a TeX
document with a logical structure, and you generate PDF, a highly
specialized format for describing the layout of a printed or on-screen
page; it has rather few means of specifying logical structure (it's
coming, but rather poorly supported by PDF producer applications at the
moment).  The same is of course even more true of DVI.  Hence, what TeX
does is to take a logically structured document, and to make it into a
visually structured one.

  Note that I am not always convinced by the whole separation of
content and layout creed which is heard very often as a selling point
for LaTeX vs. MS Word etc., but there is some truth to it, and,
generally speaking, you're still going from semantic markup to visual
appearance, not the other way round.

So in order to have a semantical
 document I must write it in XML and then process it with ConTeXt?

  Pretty much.  ConTeXt is rather good at it.  You have a lot of tools
to process XML in the base code.  There is also a module to deal with
DocBook, but I think its development has stalled.

   Is the
 capacity there (through LuaTeX perhaps) to write an XML generator?

  The goal is that at some point, you will be able to redefine LuaTeX's
backend, the same way you can act on the TeX engine at the moment.  This
will allow to control the output format entirely.

 While I would expect the reasons for wanting XML output would be obvious

  If I may, your statement might be biased by your own expectations.
There are thousand people out there who use some form of TeX without
even knowing about XML.  But I know why you want it.

  As far as LaTeX is concerned, there are quite a number of toolchains
that produce XML from some sort of restricted LaTeX markup.  I'm not
aware of anything similar for ConTeXt.

Arthur
___
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] Seeking a Deeper ConTeXt: Questions for Initializing

2009-05-25 Thread Hans Hagen

John Haltiwanger wrote:

On Mon, May 25, 2009 at 12:50 PM, Wolfgang Schuster 
schuster.wolfg...@googlemail.com wrote:


Am 25.05.2009 um 18:30 schrieb John Haltiwanger:

 I am not averse to rolling my own, I am just confused why, if environments

are so powerful and flexible (flexible meaning one can easily change
things,
unlike document classes), there are no pre-rolled environments available..
I
am thinking here of standardized thesis environments for universities, or
a
nice letter environment to demonstrate the beauty of TeX.



There are a lot of letter styles are available for ConTeXt, what's wrong
with them?

• http://wiki.contextgarden.net/Letter_style
• http://wiki.contextgarden.net/Letter

Wolfgang



Thank you for those! I had not come across them yet. I was responding to
Henning's statement that there are nearly no ready-to-use ConTeXt
environments available. In fact I realize I had misread that until right
now, having missed the 'nearly' that qualifies the statement. Sorry for the
confusion.


Also, I don't want it to seem like I don't enjoy rolling my own documents.
While I'm new at it, I quite like interfacing with documents in this
'programming' way.


in tex/context/[base|third], take a look at:

m-* : specialized  modules
s-* : styles
x-* : xml relatex modules
t-* : third party modules



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] Seeking a Deeper ConTeXt: Questions for Initializing

2009-05-25 Thread Arthur Reutenauer
Since Arthur implies that an XML output might one day be
 feasible,

  Note that the final estimate for the stable release of LuaTeX is 2012,
but the backend features may be available sooner.  Many people are looking
forward to using LuaTeX for producing XML-based and other formats :-)
See http://luatex.org/roadmap.html for the roadmap.

Arthur
___
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] Seeking a Deeper ConTeXt: Questions for Initializing

2009-05-25 Thread John Haltiwanger
On Mon, May 25, 2009 at 2:00 PM, Arthur Reutenauer 
arthur.reutena...@normalesup.org wrote:

 Since Arthur implies that an XML output might one day be
  feasible,

   Note that the final estimate for the stable release of LuaTeX is 2012,
 but the backend features may be available sooner.  Many people are looking
 forward to using LuaTeX for producing XML-based and other formats :-)
 See http://luatex.org/roadmap.html for the roadmap.


Nice, glad to hear it. Also of interest are new semantic tagging facilities
for PDF in the newest proposal for ISO 32000, mentioned by an Adobe engineer
in the comments of this blog entry
http://digitalcuration.blogspot.com/2009/04/semantically-richer-pdf.html

Hopefully there can be found a way to incorporate these facilities in
ConTeXt and/or LuaTeX when they emerge.
___
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] Seeking a Deeper ConTeXt: Questions for Initializing

2009-05-25 Thread Arthur Reutenauer
 Nice, glad to hear it. Also of interest are new semantic tagging facilities
 for PDF in the newest proposal for ISO 32000, mentioned by an Adobe engineer
 in the comments of this blog entry
 http://digitalcuration.blogspot.com/2009/04/semantically-richer-pdf.html

  If you mean Leonard Rosenthol's comment at
http://digitalcuration.blogspot.com/2009/04/semantically-richer-pdf.html?showComment=123911280#c5624378574116031944
the general issue is Tagged PDF.  It's not really supported yet in any
variant of TeX, but there is an active group working on it at River Valley
Technologies (http://lists.river-valley.com/cgi-bin/mailman/listinfo/tex).
I haven't been following closely, but there's definitely progress.

Arthur
___
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] Seeking a Deeper ConTeXt: Questions for Initializing

2009-05-25 Thread John Haltiwanger
Yes, that is the comment. Thank you for the heads up :)

On Mon, May 25, 2009 at 2:21 PM, Arthur Reutenauer 
arthur.reutena...@normalesup.org wrote:

  Nice, glad to hear it. Also of interest are new semantic tagging
 facilities
  for PDF in the newest proposal for ISO 32000, mentioned by an Adobe
 engineer
  in the comments of this blog entry
  http://digitalcuration.blogspot.com/2009/04/semantically-richer-pdf.html

   If you mean Leonard Rosenthol's comment at

 http://digitalcuration.blogspot.com/2009/04/semantically-richer-pdf.html?showComment=123911280#c5624378574116031944
 the general issue is Tagged PDF.  It's not really supported yet in any
 variant of TeX, but there is an active group working on it at River Valley
 Technologies (http://lists.river-valley.com/cgi-bin/mailman/listinfo/tex).
 I haven't been following closely, but there's definitely progress.

Arthur

 ___
 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] Seeking a Deeper ConTeXt: Questions for Initializing

2009-05-25 Thread Aditya Mahajan

On Mon, 25 May 2009, John Haltiwanger wrote:


unlike document classes), there are no pre-rolled environments available. I
am thinking here of standardized thesis environments for universities, or a


There are no standardized thesis styles for universities mainly because 
there are no consistent specs. Most univs want you to use times, double 
spaced lines, wide margins, and some formatting guidelines regarding the 
chapter headings, table of content, page headers and footers. Setting 
these are easy in ConTeXt (and also LaTeX if you know the relevant 
packages). Universities do not provide an official thesis style (either in 
LaTeX or ConTeXt) because in most cases they do not have the resources to 
maintain them. Students figure something out, and then pass along their 
styles to the next generation. If the formatting guidelines change, the 
burden is on the students to correct the style, rather than on the 
university.


When I was writing my thesis, it took me about a few hours to understand 
the formatting guidelines, which were a jigjaw puzzle. Statements like: 
Always use Times New Roman at 12pt as the main font. ... two pages down 
... The abstract can be in 10pt or 12pt ... a few pages later, use any of 
the standard fonts. It also used vague terminology. Statements like leave 
two blank lines after the title (blank lines, er... for what fontsize, the 
bodyfont or the title font?).


ConTeXt makes it really easy to make the formatting changes. Once I 
understood the formatting guidelines, writing the main style was very easy 
(with a few trips to the manual, and a few questions here on the mailing 
list). Making sure that the resultant style looked visually appealing 
while not violating the formatting guidelines too a lot of experimentation.


As Hans said, you can think of ConTeXt as the standard thesis 
style. Setup a few commands, and you meet your formatting requirements. 
Write it in an environment or a module, and you can reuse it.


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] Seeking a Deeper ConTeXt: Questions for Initializing

2009-05-25 Thread John Haltiwanger
Thank you Aditya. All that makes sense to me. It is quite clear from
everyone's responses that the person on c.t.t who claimed ConTeXt is only
for one-offs was not correct.

On Mon, May 25, 2009 at 2:26 PM, Aditya Mahajan adit...@umich.edu wrote:

 On Mon, 25 May 2009, John Haltiwanger wrote:

  unlike document classes), there are no pre-rolled environments available.
 I
 am thinking here of standardized thesis environments for universities, or
 a


 There are no standardized thesis styles for universities mainly because
 there are no consistent specs. Most univs want you to use times, double
 spaced lines, wide margins, and some formatting guidelines regarding the
 chapter headings, table of content, page headers and footers. Setting these
 are easy in ConTeXt (and also LaTeX if you know the relevant packages).
 Universities do not provide an official thesis style (either in LaTeX or
 ConTeXt) because in most cases they do not have the resources to maintain
 them. Students figure something out, and then pass along their styles to the
 next generation. If the formatting guidelines change, the burden is on the
 students to correct the style, rather than on the university.

 When I was writing my thesis, it took me about a few hours to understand
 the formatting guidelines, which were a jigjaw puzzle. Statements like:
 Always use Times New Roman at 12pt as the main font. ... two pages down ...
 The abstract can be in 10pt or 12pt ... a few pages later, use any of the
 standard fonts. It also used vague terminology. Statements like leave two
 blank lines after the title (blank lines, er... for what fontsize, the
 bodyfont or the title font?).

 ConTeXt makes it really easy to make the formatting changes. Once I
 understood the formatting guidelines, writing the main style was very easy
 (with a few trips to the manual, and a few questions here on the mailing
 list). Making sure that the resultant style looked visually appealing while
 not violating the formatting guidelines too a lot of experimentation.

 As Hans said, you can think of ConTeXt as the standard thesis style.
 Setup a few commands, and you meet your formatting requirements. Write it in
 an environment or a module, and you can reuse it.

 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

 ___

___
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] Seeking a Deeper ConTeXt: Questions for Initializing

2009-05-25 Thread Hans Hagen

John Haltiwanger wrote:

On Mon, May 25, 2009 at 2:00 PM, Arthur Reutenauer 
arthur.reutena...@normalesup.org wrote:


   Since Arthur implies that an XML output might one day be
feasible,

  Note that the final estimate for the stable release of LuaTeX is 2012,
but the backend features may be available sooner.  Many people are looking
forward to using LuaTeX for producing XML-based and other formats :-)
See http://luatex.org/roadmap.html for the roadmap.



Nice, glad to hear it. Also of interest are new semantic tagging facilities
for PDF in the newest proposal for ISO 32000, mentioned by an Adobe engineer
in the comments of this blog entry
http://digitalcuration.blogspot.com/2009/04/semantically-richer-pdf.html

Hopefully there can be found a way to incorporate these facilities in
ConTeXt and/or LuaTeX when they emerge.


as it takes a bit of work i'll only look into it when i need it (in a 
project) or when i'm extremely bored; it's rather doable


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
___


[NTG-context] Applying effects to figures

2009-05-25 Thread Vyatcheslav Yatskovsky

Hello,

I just thinkig... Is there a way to apply an effect to inserted images? 
Say, I need to make a shadow around all of screenshots included, and it 
is too laborous to apply the shadow to them in an editor just in order 
to have screenshots changed in next document version. Is think there is 
a lot of circumstances when some automatic effect can be needed.


Best,
Vyatcheslav
___
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] Applying effects to figures

2009-05-25 Thread Peter Rolf
Vyatcheslav Yatskovsky schrieb:
 Hello,
 
 I just thinkig... Is there a way to apply an effect to inserted images?

sure, but...

 Say, I need to make a shadow around all of screenshots included, and it
 is too laborous to apply the shadow to them in an editor just in order
 to have screenshots changed in next document version. Is think there is
 a lot of circumstances when some automatic effect can be needed.
 

you should ask yourself, if there is not a simpler way to do so. see

http://www.imagemagick.org/Usage/convolve/#shadow_montage


best wishes, peter


 Best,
 Vyatcheslav
 ___
 
 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] Applying effects to figures

2009-05-25 Thread Henning Hraban Ramm

Am 2009-05-25 um 21:05 schrieb Vyatcheslav Yatskovsky:

I just thinkig... Is there a way to apply an effect to inserted  
images? Say, I need to make a shadow around all of screenshots  
included, and it is too laborous to apply the shadow to them in an  
editor just in order to have screenshots changed in next document  
version. Is think there is a lot of circumstances when some  
automatic effect can be needed.


ImageMagick does support such effects; probably you could update and  
enhance or at least get inspiration from the degrade module:

http://modules.contextgarden.net/t-degrade


Greetlings from Lake Constance!
Hraban
---
http://www.fiee.net/texnique/
http://wiki.contextgarden.net
https://www.cacert.org (I'm an assurer)

___
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] Seeking a Deeper ConTeXt: Questions for Initializing

2009-05-25 Thread Mohamed Bana
i tend to write in Markdown, as the syntax is very light weight, then 
compile with pandoc (http://johnmacfarlane.net/pandoc/).


$ pandoc --toc --smart --number-sections --standalone -H header.tex -w 
context file.pdc -o file.tex

$ texexec file.tex

i think Aditya has some documents floating around somewhere.

John Haltiwanger wrote:
Thank you Arthur, Mohamed, and Hans for pointing me towards the 
available modules.


As far as working towards semantical documents in TeX, I'll just have to 
settle for writing external RDF descriptors for the documents. I'll take 
a look at using XML as the source and feeding it into ConTeXt, but since 
I rather like conTeXt's markup over XML, I'm not sure how likely I will 
be to go that route. Since Arthur implies that an XML output might one 
day be feasible,


Thanks everyone for being so helpful, speaks volumes about the community 
you have here.


Regards,
John C. Haltiwanger




___
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] Applying effects to figures

2009-05-25 Thread Peter Münster
On Mon, 25 May 2009, Henning Hraban Ramm wrote:

 ImageMagick does support such effects; probably you could update and enhance
 or at least get inspiration from the degrade module:
 http://modules.contextgarden.net/t-degrade

And of course, today you should use rather lua than bash scripting!
To use ImageMagick, there is always os.execute(...).
Cheers, Peter

-- 
Contact information: http://pmrb.free.fr/contact/

___
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] Seeking a Deeper ConTeXt: Questions for Initializing

2009-05-25 Thread John Haltiwanger
Wow, that is handy! Thanks for the tip Modamed.

On Mon, May 25, 2009 at 4:25 PM, Mohamed Bana mbana.li...@googlemail.comwrote:

 i tend to write in Markdown, as the syntax is very light weight, then
 compile with pandoc (http://johnmacfarlane.net/pandoc/).

 $ pandoc --toc --smart --number-sections --standalone -H header.tex -w
 context file.pdc -o file.tex
 $ texexec file.tex

 i think Aditya has some documents floating around somewhere.

 John Haltiwanger wrote:

 Thank you Arthur, Mohamed, and Hans for pointing me towards the available
 modules.

 As far as working towards semantical documents in TeX, I'll just have to
 settle for writing external RDF descriptors for the documents. I'll take a
 look at using XML as the source and feeding it into ConTeXt, but since I
 rather like conTeXt's markup over XML, I'm not sure how likely I will be to
 go that route. Since Arthur implies that an XML output might one day be
 feasible,

 Thanks everyone for being so helpful, speaks volumes about the community
 you have here.

 Regards,
 John C. Haltiwanger


 


 ___
 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

 ___

___
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] Seeking a Deeper ConTeXt: Questions for Initializing

2009-05-25 Thread luigi scarso
On Mon, May 25, 2009 at 8:55 PM, Hans Hagen pra...@wxs.nl wrote:

 John Haltiwanger wrote:

 On Mon, May 25, 2009 at 2:00 PM, Arthur Reutenauer 
 arthur.reutena...@normalesup.org wrote:

Since Arthur implies that an XML output might one day be
 feasible,

  Note that the final estimate for the stable release of LuaTeX is 2012,
 but the backend features may be available sooner.  Many people are
 looking
 forward to using LuaTeX for producing XML-based and other formats :-)
 See http://luatex.org/roadmap.html for the roadmap.


 Nice, glad to hear it. Also of interest are new semantic tagging
 facilities
 for PDF in the newest proposal for ISO 32000, mentioned by an Adobe
 engineer
 in the comments of this blog entry
 http://digitalcuration.blogspot.com/2009/04/semantically-richer-pdf.html

 Hopefully there can be found a way to incorporate these facilities in
 ConTeXt and/or LuaTeX when they emerge.


 as it takes a bit of work i'll only look into it when i need it (in a
 project) or when i'm extremely bored; it's rather doable

well , if you give us some hints maybe
someone will present an article at next context meeting ...
-- 
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
___


Re: [NTG-context] Applying effects to figures

2009-05-25 Thread Wolfgang Schuster


Am 25.05.2009 um 21:05 schrieb Vyatcheslav Yatskovsky:


Hello,

I just thinkig... Is there a way to apply an effect to inserted  
images? Say, I need to make a shadow around all of screenshots  
included, and it is too laborous to apply the shadow to them in an  
editor just in order to have screenshots changed in next document  
version. Is think there is a lot of circumstances when some  
automatic effect can be needed.


\startuseMPgraphic{shadow}
fill OverlayBox shifted (5pt,-5pt) withcolor .7white ;
setbounds currentpicture to OverlayBox ;
\stopuseMPgraphic

\defineoverlay[shadow][\useMPgraphic{shadow}]

\starttext

\externalfigure[mill][background=shadow]

\blank

\setupexternalfigures[background=shadow]

\externalfigure[hacker]

\stoptext

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


Re: [NTG-context] Seeking a Deeper ConTeXt: Questions for Initializing

2009-05-25 Thread Hans Hagen

luigi scarso wrote:


well , if you give us some hints maybe
someone will present an article at next context meeting ...


(1) wait for the rewritten backend (next year)
(2) wait till structure in mkiv is stable

but indeed we can discuss these things at the upcoming context meeting

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] Seeking a Deeper ConTeXt: Questions for Initializing

2009-05-25 Thread Arthur Reutenauer
 well , if you give us some hints maybe
 someone will present an article at next context meeting ...

  If you're interested in Tagged PDF, you should really look into what
the River Valley guys are doing on the mailing-list I mentioned, and
contact Ross Moore, Han The Thanh, etc.

http://lists.river-valley.com/cgi-bin/mailman/listinfo/tex

Arthur
___
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] How to disable page numbers in empty pages

2009-05-25 Thread Khaled Hosny
On Fri, May 22, 2009 at 12:04:08PM +0200, Alan Stone wrote:
 On Fri, May 22, 2009 at 11:42 AM, Khaled Hosny khaledho...@eglug.org wrote:
 
 How can I disable page numbers (or header/footer) in empty pages, as
 page 2 in the following example:
 
 \setuppagenumbering[alternative=doublesided]
 \starttext
 \chapter{one}
 \input tufte
 \chapter{two}
 \input tufte
 \stoptext
 
 Regards,
  Khaled
 
 
 http://www.ntg.nl/pipermail/ntg-context/2008/030594.html
 
  Alan

Thanks for the tip, but I've a slightly more complex layout and it might
need a more generalized solution, see:

\definepagebreak
   [mychapterpagebreak]
[yes,header,footer,right]

\setuphead
  [chapter]
  [page=mychapterpagebreak]


\setuppagenumbering[alternative=doublesided,location={header,margin}]
\setupheadertexts[{My special headertext}]
\setupfootertexts[This is a text in the footer]

\starttext
\chapter {testA} \dorecurse{10}{\input tufte }
\startstandardmakeup \dorecurse{4}{\input tufte }
\stopstandardmakeup
\chapter {testB} \dorecurse{10}{\input tufte }
\stoptext

The page after first chapter and before the markup is empty and thus
shouldn't have any headers/footers, but it isn't.

Regards,
 Khaled


-- 
 Khaled Hosny
 Arabic localiser and member of Arabeyes.org team
 Free font developer


signature.asc
Description: Digital signature
___
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] Error with \placefootnotes

2009-05-25 Thread Khaled Hosny
With the following sample and MkIV

\starttext
\setupfootnotes[location=text]
This\footnote{Or that, if you prefer.} is a sentence with a footnote.
\placefootnotes
\stoptext

I get:

! Undefined control sequence.
\doplacenotes ... \endgroup \the \everysetupnotes 
  
to be read again 
   \fi 
to be read again 
   \stoptext 
l.5 \stoptext

I think \everysetupnotes in strc-not.tex, line 913 should be
\everysetupnote, but after fixing it the output isn't correct, any
ideas?

Regards,
 Khaled


-- 
 Khaled Hosny
 Arabic localiser and member of Arabeyes.org team
 Free font developer


signature.asc
Description: Digital signature
___
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
___