Re: [NTG-context] texmfstart problem

2006-05-21 Thread Richard Gabriel




Yes,
texexec --format=cont-cz test.tex also works for me, buttexmfstart texexec --format=cont-cz test.texdoesn't! In such a case, the format cont-en gets always used.texmfstart texexec --interface=cz test.texworks well and the format cont-cz is used.Got TeXLive 2005 on Windows XP and ConTeXt 2006-05-17.-RichardFrom: Hans Hagen [mailto:[EMAIL PROTECTED]To: mailing list for ConTeXt users [mailto:[EMAIL PROTECTED]Sent: Fri, 19 May 2006 15:26:00 +0200Subject: Re: [NTG-context] texmfstart problemRichard Gabriel wrote:
> Thanks Hans,
>
> this way it works!
here 

texexec --interface=cz   test.tex
texexec --format=cz  test.tex
texexec --format=cont-cz test.tex

all work ok 

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] slithering captions

2006-05-21 Thread Sanjoy Mahajan
From: Hans Hagen <[EMAIL PROTECTED]>, Mon, 17 Apr 2006 10:48:29 +0200
>> [question about placing figures differently according to their widths]
> best use closed floats and set their characteristics (see details.pdf)

I haven't found closed floats in details.pdf, though it's teaching me
much useful stuff about floats meanwhile.  Are closed floats the ones
attached to text (e.g. \placefigure[inmargin]), rather than ones that
can move up and down?  Though that's the opposite of floating.

Mixing mixing inmargin and margin locations produces lots of collisions,
I've found (an example is below).  If TeX had a decent programming
language, it might be possible to implement lots more float-position
optimizations.  The user could write:

  \placefigure[inmargin][someref]{}{\externalfigure[somefig.pdf]}

  In the diagram \attachto[someref] the long arrows mean blah and the
  short arrows mean blahblah...

Then the optimizer would favor placing each margin figure with its top
aligned to the top of the attachment point, but if it couldn't do that,
it would move them up and down to minimize (say) the sum of the squared
vertical offsets (using a larger penalty if the figure had to be
postponed to the next page, and insert "(p. 27)" where
\attachto[someref] is).  The first pass can do greedy optimization on
the fly, and subsequent runs could analyze the figure locations and
their attachment points to find the best solution for a whole chapter.
But it would be miserable to do all of that in a macro language (which
are ghastly).

Here is the collision example.  As the doctor says when you say "It
hurts when I do X": "So don't do that!"

\starttext
\dorecurse{6}{
We thrive in information-thick worlds because of our
marvelous and everyday capacity to select, edit,
single out, structure, highlight, group, pair, merge,
harmonize, synthesize, focus, organize, condense,
reduce, boil down, choose, categorize, catalog, classify,

\placefigure[inmargin]{A caption goes here}
{\framed[height=1in,width=1.5in]{!}}

list, abstract, scan, look into, idealize, isolate,
discriminate, distinguish, screen, pigeonhole, pick over,
sort, integrate, blend, inspect, filter, lump, skip,
smooth, chunk, average, approximate, cluster, aggregate,

\placefigure[margin]{float}
{\framed[height=1in,width=1.5in]{!}}

outline, summarize, itemize, review, dip into,
flip through, browse, glance into, leaf through, skim,
refine, enumerate, glean, synopsize, winnow the wheat
from the chaff and separate the sheep from the goats.
}
___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] Math encoding in XeTeX

2006-05-21 Thread Hans Hagen
Mojca Miklavec wrote:
> On 5/21/06, Ricard Roca wrote:
>   
>> Hi,
>>
>> With ConTeXt and pdfTeX you can use \enableregime[utf] (utf8 encoding) with
>> normal mode and math mode (no need to write \pm, \alpha or \times). But with
>> ConTeXt and XeTeX you don't have to specify utf8 regime, because XeTeX can
>> read utf8 directly. However, math mode in XeTeX is a different story ( 256
>> character tfm's are needed and so, and the encoding has to be ascii, so you
>> have to write \pm, and � doesn't work).
>>
>> It would be nice if utf8 regime (using uni-xxx files) could be enabled only
>> for math mode when using XeTeX, and so you would be able to input unicode
>> characters in all modes (normal and math).
>> 
>
> According to one of the recent threads you can most probably do
> something like this (I have to reboot first to try it out):
> \catcode�=\active
> \def�{\pm}
>
> There are actually two possibilities:
>
> 1. define a whole lot of active characters in the spirit of the above
> definition, then ConTeXt will render them OK (a matter of a slight
> redefinition of \enableregime macro or perhaps an additional macro to
> switch this option on or off)
>
> 2. better support for non-OpenType fonts in XeTeX.
> XeTeX currently does a very good job with OpenType. I guess that it
> would be doable that someone would tell to XeTeX which glyphs are
> present in a certain font/encoding (partially it could guess that
> alone) and then things could happen automatically even without
> defining active characters.
>
> (or a mixture of both)
>
> Also, ConTeXt can fake many characters if they are not present in the
> font. Without defining active characters this isn't possible since
> ConTeXt never sees them.
>   
i think that using \enableregime[utf] should work ok xetex (but in loading 
patterns) 

You can play with 

\startregime[none]
  \dostepwiserecurse{128}{255}{1}
{\expanded{\defineactivecharacter 
   {\recurselevel} 
   {\rawcharacter{\recurselevel
\stopregime

\enableregime[none]

\appendtoks
  \enableregime[utf]%
%   \everyhbox\expandafter{\the\everyhbox\enableregime[none]}% fails 
\to \everymathematics

\starttext

text : ç ß

math : $ç ß [\text{\bf\enableregime[none]ç ß}] ç ß$

\stoptext

Taco may know why active chars behave a bit strange in math (may hav eto do 
with the multiple passes in math and info getting lost 

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


Re: [NTG-context] Text style in bookmarks

2006-05-21 Thread Hans Hagen
Aditya Mahajan wrote:
> On Sun, 21 May 2006, Hans Hagen wrote:
>
>   
>> nico wrote:
>> 
>>> Hello,
>>>
>>> Is there a trick so that I can put styles like {\bf ...} or {\tt ...} in
>>> the headings without having any weird text in the bookmarks?
>>>
>>> Adding \bf or \tt as empty macros to the simplifiedcommands doesn't avoid
>>> the curly braces to appear (which is normal). Do I need to use something
>>> like \def\textbf#1{\def\textbf#1{\bgroup\bf #1\egroup} to have this
>>> working?
>>>
>>>   
>> \setupinteraction[state=start]
>>
>> \appendtoks
>>  \let\groupedcommand\thirdofthreearguments
>> \to \simplifiedcommands
>>
>> % no command for monospaced yet
>>
>> \unprotected \definealternativestyle [\v!mono] [\tt]  []
>> 
>
> Isn't this same as type? In font-ini.tex you have
>
> \definealternativestyle [\v!type]  [\tt]  []
>
>   
thit will not turn into a command since \type is already a defined 
command, but type is recognizes as keyword in 
style=whateverisdefinedasalternativestyle

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


Re: [NTG-context] Text style in bookmarks

2006-05-21 Thread Aditya Mahajan
On Sun, 21 May 2006, Hans Hagen wrote:

> nico wrote:
>> Hello,
>>
>> Is there a trick so that I can put styles like {\bf ...} or {\tt ...} in
>> the headings without having any weird text in the bookmarks?
>>
>> Adding \bf or \tt as empty macros to the simplifiedcommands doesn't avoid
>> the curly braces to appear (which is normal). Do I need to use something
>> like \def\textbf#1{\def\textbf#1{\bgroup\bf #1\egroup} to have this
>> working?
>>
> \setupinteraction[state=start]
>
> \appendtoks
>  \let\groupedcommand\thirdofthreearguments
> \to \simplifiedcommands
>
> % no command for monospaced yet
>
> \unprotected \definealternativestyle [\v!mono] [\tt]  []

Isn't this same as type? In font-ini.tex you have

\definealternativestyle [\v!type]  [\tt]  []

> (i will add the extra definitions to the core)

Can you also add something for \em.


Aditya

-- 
Aditya Mahajan, EECS Systems, University of Michigan
http://www.eecs.umich.edu/~adityam || Ph: 7342624008
___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


[NTG-context] texmfstart?

2006-05-21 Thread Hans van der Meer
Since installing the last ConTeXt update I am aware of the message from texexec:      warning : use 'texmfstart texexec' insteadGood, I call:      "texmfstart texexec --version" instead of "texexec --version"Result:      -bash: texmfstart: command not foundIs my system suddenly incomplete?I am using Mac OS X 10.4.6, the most recent development I would think.What happened and how can I get to the level of system support ConTeXt seems to expect of me? Hans van der Meer ___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] open math

2006-05-21 Thread Hans Hagen
nico wrote:
> On Fri, 19 May 2006 22:30:20 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote:
>
>   
>> nico wrote:
>> 
>>> On Thu, 18 May 2006 22:02:03 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote:
>>>
>>>   
 Hi,

 For those interested in mathml/openmath ... i've added some support for
 openmath -> mathml conversion to the distribution (there is some stuff
 in the manual svn repos as well). I dunno how many of you actually have
 used openmath. Anyhow, it makes a nice demo of applying ctx job
 description files (used for automatic preprocessing of the xml files to
 content mathml and such).
 
>>> Just a question about the ctx file as described in the doc: does it mean
>>> that every XML file is processed first by 'openmath' and then  
>>> 'mathadore'?
>>>
>>> If so, why not using the xsltproc piping, avoiding the intermediate .om
>>> files?
>>>
>>>   
>> i'm not aware of piping ... how does the command look then?
>> 
>
> Provided that it's possible to pipe commands via ctx and/or texexec:
>
> xsltproc x-sm2om.xsl foo.xml | xsltproc -o foo.prep x-openmath.xsl -
>   
ah, that way; i thought that you meant that xsltproc had a sequencing 
option

the piping could indeed be a problem so it needs some testing

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


Re: [NTG-context] Text style in bookmarks

2006-05-21 Thread Hans Hagen
nico wrote:
> Hello,
>
> Is there a trick so that I can put styles like {\bf ...} or {\tt ...} in  
> the headings without having any weird text in the bookmarks?
>
> Adding \bf or \tt as empty macros to the simplifiedcommands doesn't avoid  
> the curly braces to appear (which is normal). Do I need to use something  
> like \def\textbf#1{\def\textbf#1{\bgroup\bf #1\egroup} to have this  
> working?
>   
\setupinteraction[state=start]

\appendtoks
  \let\groupedcommand\thirdofthreearguments
\to \simplifiedcommands

% no command for monospaced yet

\unprotected \definealternativestyle [\v!mono] [\tt]  []

\placebookmarks

\starttext

\chapter{test \mono{test} \bold{test}}

\stoptext

(i will add the extra definitions to the core) 


-
  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


Re: [NTG-context] Text style in bookmarks

2006-05-21 Thread Hans Hagen
� wrote:
> On Sat, 20 May 2006, nico wrote:
>
>   
>> Is there a trick so that I can put styles like {\bf ...} or {\tt ...} in  
>> the headings without having any weird text in the bookmarks?
>> 
>
> This works well with LaTeX and hyperref. Perhaps the same mechanism could
> be adopted to ConTeXt?
>   
a small test file showing the problem is needed

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


Re: [NTG-context] Math encoding in XeTeX

2006-05-21 Thread Ricard Roca

> I'm sorry for not being precise enough, the thread was on the XeTeX
> mailing list, not here. (How to use EC font encoding in XeTeX?)

Don't worry. I am subscribed to that list too :)

Thanks a lot

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


[NTG-context] Problems when using columnset and certain fonts

2006-05-21 Thread ME
Hi all,

I'm currently playing with context columns / columnsets and several 
fonts. I've come across a strange problem with columnsets when using 
certain fonts.

I first noticed it when I tried to use one of the Windows TTF fonts, 
Times New Roman. That's the one I've mainly used in the past with Latex.
I've been through all the steps described in the wiki, the practex 
2005/2 issue or Bill McClain's context/pdftex beginner's page to embed 
TTF into context.

The problem I encountered was that typesetting with some fonts goes 
terribly berserk when switching between \tf and \it and back.
I thought this was just 'me' because I don't know much about context 
yet, and integrating ttf is complicated.

So I looked at
http://www.fiee.net/texnique/?menu=0-1-4
(it was mentioned in January in the 'Problems installing Gentium TTF' 
thread) which has some font definitions for context. I tested all of 
them and guess what, one of them shows the same problem.
It's the phosphorus font, which I used to cook up a minimal example, 
just that anybody can test it without my own local font definitions, 
which may be wrong anyway.

So here's my questions regarding this phenomenon.

1) Is it a problem with the font being used?
(In this case there's probably no workaround and certain fonts simply 
can't be used).

2) Is it a problem with the font/typescript definition files? If so, how 
can it be fixed?
(This would be my favourite, it would mean it can be fixed locally, 
althogh this also means I made a mistake somewhere :-))

3) Is it a problem within the context columnset?
(This I wouldn't like much since I couldn't fix it myself...)

It would be nice if one of the wizards could look into this, because it 
puzzles me no end...

I'm using miktex on windows xp sp2. For version information, the log 
file says:

TeXExec 5.4.3 - ConTeXt / PRAGMA ADE 1997-2005
ConTeXt  ver: 2006.04.24 23:37  fmt: 2006.5.16
TeXUtil 9.0.1 - ConTeXt / PRAGMA ADE 1992-2006


Find the minimal example below.


Thanks...

Michael



% start of example
% interface=en output=pdftex
\mainlanguage[en]

% to test, download&install the phosphorus font from
% http://www.fiee.net/texnique/?menu=0-1-4
% without these five lines all three chapters
% work with the default font setup
\setupencoding[default=qx]
\usetypescriptfile[type-apostrophe-phosphorus]
\usetypescript[fiee][apostrophe-phosphorus]
\setupbodyfont[apostrophe-phosphorus, rm, 12pt]
\setupbodyfontenvironment[default][em=italic]

\setuptolerance[verytolerant]
\pretolerance
\tolerance

\setuplayout[width=17cm]
\setuplayout[margin=0cm]
\setuplayout[backspace=2.4cm]
\setuplayout[headerdistance=5pt]
\setuplayout[header=17pt]
\setuplayout[footerdistance=5pt]
\setuplayout[footer=17pt]
\setuplayout[location=doublesided]

\definecolumnset[test][n=3,distance=15pt,balance=yes]

\starttext

\showgrid

%typesetting ok when using columns, \it and \tf
\moveongrid[both]
\startlinecorrection
\chapter{test}
\stoplinecorrection

\startcolumns[n=3,distance=15pt,balance=no]
\dorecurse{10}{\tf \input knuth \par \it \input tufte \par}
\stopcolumns
\page


%typesetting ok when using columnset and not \it + \tf
\moveongrid[both]
\startlinecorrection
\chapter{test}
\stoplinecorrection

\startcolumnset[test]
\dorecurse{10}{\tf \input knuth \par \input tufte \par}
\stopcolumnset\page


%typesetting terribly wrong when using columnset, \it and \tf
\moveongrid[both]
\startlinecorrection
\chapter{test}
\stoplinecorrection

\startcolumnset[test]
\dorecurse{10}{\tf \input knuth \par \it \input tufte \par}
\stopcolumnset

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