Re: [NTG-context] Font Question: Specific font sizes not working.

2006-08-10 Thread Taco Hoekwater
David Wooten wrote:
> Hmm, well I seem to have figured something out:
> 
> the line
> 
> \switchtobodyfont[jenson,12pt]
> 
> used to work. When replaced with
> 
> \switchtotypeface[jenson][12pt]
> 
> it now once again does the trick.

Is the problem specific to the jenson typeface?

Taco

___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] Font Question: Specific font sizes not working.

2006-08-10 Thread David Wooten
Hmm, well I seem to have figured something out:

the line

\switchtobodyfont[jenson,12pt]

used to work. When replaced with

\switchtotypeface[jenson][12pt]

it now once again does the trick.

dw



David Wooten wrote:
 > Greetings all,
 >
 > In the last week or so I started having a problem with fonts: what once
 > worked stopped doing so, giving me the default font rather than my
 > chosen fonts. I finally figured out that it is only certain sizes that
 > are not working. For example, with:
 >
 > \usetypescriptfile[jensonpro]
 > \usetypescript[jenson]
 > \switchtobodyfont[jenson,11pt]
 >
 > \starttext
 >
 > Testing.
 >
 > \stoptext
 >

 ...bodyfont", naturally ;)
 > "\switchtododyfont" sizes 8pt, 10pt, 11pt, 13pt all still work, while
 > 9pt and 12pt no longer do so...
 >
 > I recently updated ConTeXt and it remains the same. No change was made
 > to my typescript files, and indeed in \definebodyfont those sizes are
 > definitely listed:
 >
 > \starttypescript [serif] [Opticals] [size]
 > \definebodyfont
 >   [13pt,12pt,11pt,10pt,9pt,8pt][rm]
 > ...
 > \stoptypescript

___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] doifmode[paging]

2006-08-10 Thread Peter Rolf
David Arnold wrote:
> Hans et al,
> 
> I have:
> 
> 
> \def\startquestions{\exercises{Exercises}\doifmode{copyright} 
> {\footnotetext{Copyrighted material. See: http://msenux.redwoods.edu/ 
> IntAlgText/}
> }\startcolumnset[exercises]}
> 
> \def\stopquestions{\stopcolumnset}
> 
> Then in document, I have:
> 
> \startquestions
> \doifmode[paging]{\setnumber[page]{\pagenumberExercisesSevenEight}}
> 
\doifmode{paging}

should work

> 
> When I:
> 
> texmfstart texexec --mode=short,copyright,paging section8exercises
> 
> All is OK with the world, except the first line (other than headers  
> and heads which are ok) in the output is:
> 
>   aging]
> 
> 
> I tried:
> 
> \startquestions\relax
> \doifmode[paging]{\setnumber[page]{\pagenumberExercisesSevenEight}}
> 
> To no avail.
> 
> Suggestions?
> 
> ___
> ntg-context mailing list
> ntg-context@ntg.nl
> http://www.ntg.nl/mailman/listinfo/ntg-context
> 
> 

___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


[NTG-context] doifmode[paging]

2006-08-10 Thread David Arnold
Hans et al,

I have:


\def\startquestions{\exercises{Exercises}\doifmode{copyright} 
{\footnotetext{Copyrighted material. See: http://msenux.redwoods.edu/ 
IntAlgText/}
}\startcolumnset[exercises]}

\def\stopquestions{\stopcolumnset}

Then in document, I have:

\startquestions
\doifmode[paging]{\setnumber[page]{\pagenumberExercisesSevenEight}}


When I:

texmfstart texexec --mode=short,copyright,paging section8exercises

All is OK with the world, except the first line (other than headers  
and heads which are ok) in the output is:

  aging]


I tried:

\startquestions\relax
\doifmode[paging]{\setnumber[page]{\pagenumberExercisesSevenEight}}

To no avail.

Suggestions?

___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] multiple modes

2006-08-10 Thread Taco Hoekwater
David Arnold wrote:
> All,
> 
> Is this sort of thing ok?
> 
> texexec --mode=short,copyright,paging chapter1

I think so ...

Taco

___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


[NTG-context] multiple modes

2006-08-10 Thread David Arnold
All,

Is this sort of thing ok?

texexec --mode=short,copyright,paging chapter1
___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] section headnumber at texexec

2006-08-10 Thread Hans Hagen
David Arnold wrote:
> All,
>
> If I compile a section with:
>
> texmfstart texexec section1
>
> is there a texexec switch that I can use to pass the section number  
> at the command line?
>   
well, i guess that you bet there is a way to do it -) 

 d.tex  

\doifenvelse{sectionnumber}
  {\setupheadnumber[section][\numexpr\env{sectionnumber}-1\relax]}
  {}

\starttext

\section{test}

\stoptext

=== end of d === 

texexec --arg=sectionnumber=4 d

if needed you can do in an environment file 

\startsetups check-section

  \doifenvelse{sectionnumber}
{\setupheadnumber[section][\numexpr\env{sectionnumber}-1\relax]}
{}

\stopsetups 

and then 

 d.tex  

\environment ... 

\setups{check-section}

\starttext

\section{test}

\stoptext

=== end of d === 


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

___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


[NTG-context] section headnumber at texexec

2006-08-10 Thread David Arnold
All,

If I compile a section with:

texmfstart texexec section1

is there a texexec switch that I can use to pass the section number  
at the command line?
___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] the closing bracket (structuring syntax)

2006-08-10 Thread Steffen Wolfrum
Thank you.

\footnote
\index
\chapter\section ...
\it \bf \sc \mr \cap
\language[...]

That would be quite a good start.

Steffen




Am 10.08.2006 um 22:44 schrieb Hans Hagen:

> Steffen Wolfrum wrote:
>> Hi,
>>
>> in XML and alike there is a concept of dedicated start/stop in
>> formatting:
>>
>>  ... 
>>  ... 
>>  ... 
>>
>> But in ConTeXt/TeX we have always the same closing syntax "}". That
>> makes reading the code not easier.
>>
>> Is there a workaround to define the closing more precisely (like the
>> examples above),
>> so that finding a "}" in a ConTeXt source lets me distinguish what
>> it's about?
>>
>> But in such a way that the file still can be processed as a regular
>> ConTeXt file?
>>
> its' no problem to define most commands as start/stop, however keep in
> mind that some start/stop constructs (like tables) pick up pieces in
> order to store them
>
> so, if some commands need start/stop variants ... just make me a list
> and we'll see what we can do about it
>
> 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
> -
>
> ___
> ntg-context mailing list
> ntg-context@ntg.nl
> http://www.ntg.nl/mailman/listinfo/ntg-context
>

___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] the closing bracket (structuring syntax)

2006-08-10 Thread Aditya Mahajan
On Thu, 10 Aug 2006, Steffen Wolfrum wrote:

> Hi,
>
> in XML and alike there is a concept of dedicated start/stop in
> formatting:
>
>  ... 
>  ... 
>  ... 
>
> But in ConTeXt/TeX we have always the same closing syntax "}". That
> makes reading the code not easier.


You can always define your own startstop.

\definestartstop[italic][before={\bgroup \it},after={\egroup}]

and then do

\startitalic
  This is italic
\stopitalic

When a command takes an optional agrument, you can do use something like 
this

\def\startfootnote%
{\unskip\dosingleempty\dostartfootnote}

\def\dostartfootnote[#1]#2\stopfootnote%
   {\footnote[#1]{#2}}


You can make such definitions of all your frequently used environments 
(or, if you prefer, write in XML and let ConTeXt handle XML).

> Is there a workaround to define the closing more precisely (like the
> examples above),
> so that finding a "}" in a ConTeXt source lets me distinguish what
> it's about?

There are \bgroup...\egroup which is same as {...} for all practical 
purposes.

Aditya
___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] the closing bracket (structuring syntax)

2006-08-10 Thread Hans Hagen
Steffen Wolfrum wrote:
> Hi,
>
> in XML and alike there is a concept of dedicated start/stop in  
> formatting:
>
>  ... 
>  ... 
>  ... 
>
> But in ConTeXt/TeX we have always the same closing syntax "}". That  
> makes reading the code not easier.
>
> Is there a workaround to define the closing more precisely (like the  
> examples above),
> so that finding a "}" in a ConTeXt source lets me distinguish what  
> it's about?
>
> But in such a way that the file still can be processed as a regular  
> ConTeXt file?
>   
its' no problem to define most commands as start/stop, however keep in 
mind that some start/stop constructs (like tables) pick up pieces in 
order to store them

so, if some commands need start/stop variants ... just make me a list 
and we'll see what we can do about it

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
-

___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


[NTG-context] the closing bracket (structuring syntax)

2006-08-10 Thread Steffen Wolfrum
Hi,

in XML and alike there is a concept of dedicated start/stop in  
formatting:

 ... 
 ... 
 ... 

But in ConTeXt/TeX we have always the same closing syntax "}". That  
makes reading the code not easier.

Is there a workaround to define the closing more precisely (like the  
examples above),
so that finding a "}" in a ConTeXt source lets me distinguish what  
it's about?

But in such a way that the file still can be processed as a regular  
ConTeXt file?

Steffen
___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] how to figure out the number of elements inside \defineconversion?

2006-08-10 Thread Mojca Miklavec
On 8/10/06, Hans Hagen wrote:
> Mojca Miklavec wrote:
> > Hello,
> >
> > I would like to \defineconversion and the use that set of symbols
> > inside a metapost graphic. But I need to know the number of symbols,
> > so that I can define enough "metapost images with symbols" in advance.
> > I realise that there might be a problem since conversion can sometimes
> > take an arbitrary number (using a command defined elsewhere), but if I
> > could have a reasonable guess for conversions defined explicitely,
> > that would already help a lot. (As a workaround and/or if there is no
> > easy method to figure that out I can still hardcode "25" and wait
> > until someone complains that that is not enough to satisfy his/her
> > needs.)

> \unprotect
>
> \def\doifelseconversionnumber#1#2%
>   {\doifdefinedelse{\??cv#1#2}}
>
> \protect
>
> \defineconversion[abc][$\star$,$\bullet$,$\ast$]
> \defineconversion[def][m,o,j,c,a]
>
> \doloop
>   {\doifelseconversionnumber{abc}{\recurselevel}
>  {[abc \recurselevel\space defined]}
>  {\exitloop}}
>
> \doloop
>   {\doifelseconversionnumber{def}{\recurselevel}
>  {[def \recurselevel\space defined]}
>  {\exitloop}}

Perfect. That's exactly what I needed. I only have to keep my fingers
crossed now (I haven't tested the executable for a while) ...

Mojca
___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] Cow-font (was Context 2006.08.08 released}

2006-08-10 Thread Willi Egger
Hi Mojca,

thanks, that makes the difference!

Willi

Mojca Miklavec wrote:
> On 8/9/06, Willi Egger wrote:
>   
>> Hi Hans,
>>
>> Thanks for the hint!
>>
>> Now I am able to display the symbolsets with \showsymbolset. However I
>> can't get eg. \symbol[CowConTeXtComplete]
>> I tried also the Marvosyms. I can display the a set e.g.
>> \showsymbolset[atronomic], but can't get \symbol[astronomic:Mars]
>>
>> Is the \symbol command broken?
>>
>> Willi
>> 
>
> \usesymbols[cow]
>
> \starttext
> \symbol[cownormal][CowConTeXtComplete]
> \stoptext
>
> There's also a command to "preaload cownormal", so that you may leave
> the [cownormal] out:
>
> \setupsymbolset[cownormal]
> \symbol[CowConTeXtComplete]
>
> Mojca
> ___
> ntg-context mailing list
> ntg-context@ntg.nl
> http://www.ntg.nl/mailman/listinfo/ntg-context
>   
___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


[NTG-context] Another editor for (La)TeX

2006-08-10 Thread Renaud AUBIN





Hi all,

A friend of mine pointed out TeXmaker:
http://www.xm1math.net/texmaker/index.html
Since I have not tried it, I can't say if one could use it with
ConTeXt... For those who liked graphical editor: give it a try

Cheers,

Renaud





___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] how to figure out the number of elements inside \defineconversion?

2006-08-10 Thread Hans Hagen
Mojca Miklavec wrote:
> Hello,
>
> I would like to \defineconversion and the use that set of symbols
> inside a metapost graphic. But I need to know the number of symbols,
> so that I can define enough "metapost images with symbols" in advance.
> I realise that there might be a problem since conversion can sometimes
> take an arbitrary number (using a command defined elsewhere), but if I
> could have a reasonable guess for conversions defined explicitely,
> that would already help a lot. (As a workaround and/or if there is no
> easy method to figure that out I can still hardcode "25" and wait
> until someone complains that that is not enough to satisfy his/her
> needs.)
>
> Thanks a lot,
> Mojca
>
>
> \startMPextensions
>   numeric variant; variant = 1;
>   vardef gp_the_symbol(expr n) =
> picture pict;
> % using metapost
> if variant=1:
>   pict := image( fill fullcircle scaled 4pt; ); % TODO
> % using TeX, variant = 2
> else: % TODO: limit the number first
>   pict := sometxt(n);
> fi;
> pict shifted -center pict
>   enddef ;
>
>   def gp_point(expr x, y, n) =
> draw (gp_the_symbol(n) scaled 1 shifted (x,y));
>   enddef ;
> \stopMPextensions
>
> \starttext
>
> \defineconversion[abc][$\star$,$\bullet$,$\ast$]
>
> \startTeXtexts
> % TODO: 6 is only a guess: I need a better guess (3 in this case)
> \dostepwiserecurse{1}{6}{1}{\TeXtext{\recurselevel}{{\convertnumber{abc}{\recurselevel
> \stopTeXtexts
>
> \startMPcode
>   variant := 1;
>   gp_point(1cm,0cm,1);
>   gp_point(2cm,0cm,2);
>   variant := 2;
>   gp_point(1cm,1cm,1);
>   gp_point(2cm,1cm,2);
>   gp_point(3cm,1cm,3);
>   gp_point(4cm,1cm,4);
>   gp_point(5cm,1cm,8);
> \stopMPcode
>
> \stoptext
>   
\unprotect

\def\doifelseconversionnumber#1#2%
  {\doifdefinedelse{\??cv#1#2}}

\protect

\defineconversion[abc][$\star$,$\bullet$,$\ast$]
\defineconversion[def][m,o,j,c,a]

\doloop
  {\doifelseconversionnumber{abc}{\recurselevel}
 {[abc \recurselevel\space defined]}
 {\exitloop}}

\doloop
  {\doifelseconversionnumber{def}{\recurselevel}
 {[def \recurselevel\space defined]}
 {\exitloop}}

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

___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


[NTG-context] how to figure out the number of elements inside \defineconversion?

2006-08-10 Thread Mojca Miklavec
Hello,

I would like to \defineconversion and the use that set of symbols
inside a metapost graphic. But I need to know the number of symbols,
so that I can define enough "metapost images with symbols" in advance.
I realise that there might be a problem since conversion can sometimes
take an arbitrary number (using a command defined elsewhere), but if I
could have a reasonable guess for conversions defined explicitely,
that would already help a lot. (As a workaround and/or if there is no
easy method to figure that out I can still hardcode "25" and wait
until someone complains that that is not enough to satisfy his/her
needs.)

Thanks a lot,
Mojca


\startMPextensions
  numeric variant; variant = 1;
  vardef gp_the_symbol(expr n) =
picture pict;
% using metapost
if variant=1:
  pict := image( fill fullcircle scaled 4pt; ); % TODO
% using TeX, variant = 2
else: % TODO: limit the number first
  pict := sometxt(n);
fi;
pict shifted -center pict
  enddef ;

  def gp_point(expr x, y, n) =
draw (gp_the_symbol(n) scaled 1 shifted (x,y));
  enddef ;
\stopMPextensions

\starttext

\defineconversion[abc][$\star$,$\bullet$,$\ast$]

\startTeXtexts
% TODO: 6 is only a guess: I need a better guess (3 in this case)
\dostepwiserecurse{1}{6}{1}{\TeXtext{\recurselevel}{{\convertnumber{abc}{\recurselevel
\stopTeXtexts

\startMPcode
  variant := 1;
  gp_point(1cm,0cm,1);
  gp_point(2cm,0cm,2);
  variant := 2;
  gp_point(1cm,1cm,1);
  gp_point(2cm,1cm,2);
  gp_point(3cm,1cm,3);
  gp_point(4cm,1cm,4);
  gp_point(5cm,1cm,8);
\stopMPcode

\stoptext
___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] modules

2006-08-10 Thread Patrick Gundlach
Hello Nikolai,

> I don't have a login, that I know about, so I created a new one.  My
> username is "now", so if you could give the user "now" ownership of
> the BNF grammar module, that'd be great.

Done. If you have any more questions, just ask me. Sorry for the
delay: I was offline for a few days.

Patrick

-- 
ConTeXt wiki and more: http://contextgarden.net
___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] doifempty

2006-08-10 Thread Bernd Militzer
Hans Hagen schrieb:
> the empty test is kind of special, use \doifelsenothing cum suis
>   
perfect, thanks a lot

Bernd
___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] doifempty

2006-08-10 Thread Hans Hagen
Bernd Militzer wrote:
> Hi all,
>
> after I defined
>
> \def\VariA{}
> \def\VariB{with Text}
>
> \doifemptyelse{\VariA}{empty}{not empty}\crlf
> \doifemptyelse{\VariB}{empty}{not empty}
>
> both results are "not empty"!
>   

the empty test is kind of special, use \doifelsenothing cum suis

> what do I wrong?
>
> thanks for help
>
> Bernd
>
> ___
> ntg-context mailing list
> ntg-context@ntg.nl
> http://www.ntg.nl/mailman/listinfo/ntg-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
-

___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context