Re: [NTG-context] Hanging punctuation

2014-06-24 Thread Tomas Hala

I tried it, but unfortunately it does not work, either before, or after.
Is there any other way how to enable it?

Tomas


Mon, Jun 23, 2014 ve 10:39:49AM +0200 Wolfgang Schuster napsal(a):
# 
# Am 22.06.2014 um 20:51 schrieb Tomas Hala tomas.h...@mendelu.cz:
# 
#  Hello,
#  
#  I tried hanging punctuation with Trebuchet font but without any success
#  whereas for Latin Modern or Libertine (without simplefonts) it works OK.
#  
#  Is the \setupalign feature for hanging punctuation available for 
#  simplefonts module? Or did I forget some option?
#  
#  Minimal example:
#  
#  % CTX from TeXlive 2013
#  \usemodule[simplefonts]   
#  \setmainfont[Trebuchet MS]
#  \setupalign[hz,hyphenated,justified,hanging]
#  \starttext 
#  \input knuth
#  \stoptext
# 
# You have to enable the feature for the font before you can use it, to do this 
add
# 
# \definefontfeature[default][default][expansion=quality,protrusion=quality]
# 
# before \setmainfont.
# 
# 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  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] Text around figure

2014-06-24 Thread Wolfgang Schuster

Am 24.06.2014 um 10:01 schrieb MANUEL GONZALEZ SUAREZ 
gonzalezsman...@uniovi.es:

 Hi!
 I would like to know how I have to do to make a figure appear surrounded by 
 text. In LaTeX this is accomplished with packages picins and picinpar but 
 I think that in ConTeXt we only can use the \startfiguretext ... 
 \stopfiguretext environment, although the effect is not the same.
 I send an example.

\setupfloats
  [sidespacebefore=none,
   sidespaceafter=none]

\starttext 

\placefigure[left,none]{}{\blackrule[width=3cm,height=4cm]}
\input knuth

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

Re: [NTG-context] Text around figure

2014-06-24 Thread MANUEL GONZALEZ SUAREZ
Thanks very much, Wolfgang.


De: ntg-context-boun...@ntg.nl ntg-context-boun...@ntg.nl en nombre de 
Wolfgang Schuster schuster.wolfg...@gmail.com
Enviado: martes, 24 de junio de 2014 9:23
Para: mailing list for ConTeXt users
Asunto: Re: [NTG-context] Text around figure


Am 24.06.2014 um 10:01 schrieb MANUEL GONZALEZ SUAREZ 
gonzalezsman...@uniovi.esmailto:gonzalezsman...@uniovi.es:

Hi!
I would like to know how I have to do to make a figure appear surrounded by 
text. In LaTeX this is accomplished with packages picins and picinpar but I 
think that in ConTeXt we only can use the \startfiguretext ... \stopfiguretext 
environment, although the effect is not the same.
I send an example.

\setupfloats
  [sidespacebefore=none,
   sidespaceafter=none]

\starttext

\placefigure[left,none]{}{\blackrule[width=3cm,height=4cm]}
\input knuth

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

Re: [NTG-context] Problem in natural tables with nc= and alignmentcharacter

2014-06-24 Thread Hans Hagen

On 6/23/2014 10:50 PM, Peter Münster wrote:

On Mon, Jun 23 2014, Peter Münster wrote:


No solution, just a smaller MWE:


Yet smaller, but I don't know, if it's still the same problem:

\starttext
\bTABLE
\bTR \bTD A x \eTD \bTD[nc=2] A \eTD \eTR
\eTABLE
\stoptext


after lots of experiments (adapting the width guesser) i decided to 
stick to a simple check and warning; the first column will be ok but the 
second one to wide (btw, one solution was to set maxwidth to a large value)


catching all possible errors in coding a table is undoable (plus 
unpredictable)


(xtables work ok btw)

Hans

-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
tel: 038 477 53 69 | voip: 087 875 68 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  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

[NTG-context] Character alignment in math mode

2014-06-24 Thread Maggyero
How can one use character alignment in math mode? (I am using the last
stable ConTeXt version — 2014.05.21.)


\starttext
\setupTABLE[column][first][alignmentcharacter={,}, aligncharacter=yes,
align=middle]

Figures in text mode get aligned:

\startTABLE
\NC 0,0 \NC \NR
\NC 0,00\NC \NR
\NC 0,000   \NC \NR
\stopTABLE

But figures in math mode do not get aligned:

\startTABLE
\NC $0,0$   \NC \NR
\NC $0,00$  \NC \NR
\NC $0,000$ \NC \NR
\stopTABLE
\stoptext


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

[NTG-context] win2k and context

2014-06-24 Thread Wolfgang Werners-Lucchini
Can you please tell me the latest context version (mkiv) working with 
win2k and the download position?
___
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  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] win2k and context

2014-06-24 Thread Mojca Miklavec
On Tue, Jun 24, 2014 at 4:40 PM, Wolfgang Werners-Lucchini wrote:
 Can you please tell me the latest context version (mkiv) working with
 win2k and the download position?

http://www.ntg.nl/pipermail/ntg-context/2013/070994.html
http://www.ntg.nl/pipermail/ntg-context/2013/071049.html

Mojca
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] Character alignment in math mode

2014-06-24 Thread Hans Hagen

On 6/24/2014 4:35 PM, Maggyero wrote:

How can one use character alignment in math mode? (I am using the last
stable ConTeXt version — 2014.05.21.)


\starttext
\setupTABLE[column][first][alignmentcharacter={,}, aligncharacter=yes,
align=middle]

Figures in text mode get aligned:

\startTABLE
 \NC 0,0 \NC \NR
 \NC 0,00\NC \NR
 \NC 0,000   \NC \NR
\stopTABLE

But figures in math mode do not get aligned:

\startTABLE
 \NC $0,0$   \NC \NR
 \NC $0,00$  \NC \NR
 \NC $0,000$ \NC \NR
\stopTABLE
\stoptext


indeed, as math node lists have a completely different structure ... why 
use math here?


-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
tel: 038 477 53 69 | voip: 087 875 68 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  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] Hanging punctuation

2014-06-24 Thread Pablo Rodriguez
On 06/24/2014 09:42 AM, Tomas Hala wrote:
 
 I tried it, but unfortunately it does not work, either before, or after.
 Is there any other way how to enable it?

Tomas,

the following works (but not for ConTeXt from TeXLive 2013):

\showframe
\definefontfeature[default][default]
[expansion=quality,protrusion=quality]
\definefontfamily[mainface][serif][Trebuchet MS]
\setupbodyfont[mainface]
\setupalign[hz,hanging]
\starttext
\input knuth
\stoptext

Output available at http://www.ousia.tk/protrusion.pdf.

I suggest that you install the ConTeXt Suite (instructions available at
http://wiki.contextgarden.net/ConTeXt_Standalone). You don’t need to
uninstall anything. It is always worth having the latest beta version.

I hope it helps,


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


[NTG-context] Character alignment in math mode

2014-06-24 Thread Maggyero
 why  use math here?

It was to avoid oldstyle figures that I use by default. But finally it's
better to use oldstyle figures even in tables.

Another question about fonts. Is there a way to define a conditional
mathcommand based on the current alternative style? For instance, in the
following example I would like to keep the bold effect but with adaptation
to the local alternative style (in text mode, when the local alternative
style is \tf I would like the mathcommand to be \bf, when it is \it I would
like \bi, when it is \bf I would like \bf and when it is \bi I would like
still \bi):

\starttext
\definemathcommand[cool]{{\bfmath cool}}
text mode normal: \cool\crlf
text mode italic: {\it \cool}\crlf
text mode bold: {\bf \cool}\crlf
text mode bolditalic: {\bi \cool}\crlf
\stoptext
___
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  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] Problem in natural tables with nc= and alignmentcharacter

2014-06-24 Thread Rik Kabel

On 2014-06-24 08:03, Hans Hagen wrote:

On 6/23/2014 10:50 PM, Peter Münster wrote:

On Mon, Jun 23 2014, Peter Münster wrote:


No solution, just a smaller MWE:


Yet smaller, but I don't know, if it's still the same problem:

\starttext
\bTABLE
\bTR \bTD A x \eTD \bTD[nc=2] A \eTD \eTR
\eTABLE
\stoptext


after lots of experiments (adapting the width guesser) i decided to 
stick to a simple check and warning; the first column will be ok but 
the second one to wide (btw, one solution was to set maxwidth to a 
large value)


catching all possible errors in coding a table is undoable (plus 
unpredictable)


(xtables work ok btw)

Hans


Hans,

While xtable works fine for Peter's reduced MWE, it does not handle the 
problem first presented, which includes an alignment character for 
columns of mark-separated numbers. By my understanding of how xtable 
works, I suspect that it will not be able to handle this requirement.


In this case I can get by with explicitly setting column widths as 
needed to prevent the error. I have been using the following code to get 
the width of what appears to be the widest element in a column:


   %% This gets the width of simple things; from Hans on the mailing
   %%   list http://www.ntg.nl/pipermail/ntg-context/2007/024390.html
   %%   example usage: \SetWidthOf{\ColContent}\to\ColContentWidth\relax
   %%   or: \SetWidthOf{Column Content}\to\ContentWidth\relax
   \def\SetWidthOf#1\to#2%
 {\bgroup
  \setbox\scratchbox\hbox{#1}%
  \expanded{\egroup\def\noexpand#2{\the\wd\scratchbox}}}

Is TABLE with explicit column widths the best solution for now on tables 
that require number alignment, or do you recommend another table mechanism?


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

Re: [NTG-context] Hanging punctuation

2014-06-24 Thread Wolfgang Schuster

Am 24.06.2014 um 20:56 schrieb Pablo Rodriguez oi...@gmx.es:

 On 06/24/2014 09:42 AM, Tomas Hala wrote:
 
 I tried it, but unfortunately it does not work, either before, or after.
 Is there any other way how to enable it?
 
 Tomas,
 
 the following works (but not for ConTeXt from TeXLive 2013):
 
\showframe
\definefontfeature[default][default]
   [expansion=quality,protrusion=quality]
\definefontfamily[mainface][serif][Trebuchet MS]

You don’t need the \definefontfeature command when you write

\definefontfamily[mainface][serif][Trebuchet MS][features={default,quality}]

\setupbodyfont[mainface]
\setupalign[hz,hanging]
\starttext
\input knuth
\stoptext
 
 Output available at http://www.ousia.tk/protrusion.pdf.
 
 I suggest that you install the ConTeXt Suite (instructions available at
 http://wiki.contextgarden.net/ConTeXt_Standalone). You don’t need to
 uninstall anything. It is always worth having the latest beta version.

The \definefontfamily command works also with Texlive 2014.

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


Re: [NTG-context] Character alignment in math mode

2014-06-24 Thread Wolfgang Schuster

Am 24.06.2014 um 21:46 schrieb Maggyero maggy...@gmail.com:

  why  use math here?
 
 It was to avoid oldstyle figures that I use by default. But finally it's 
 better to use oldstyle figures even in tables.

You can enable lining (and tabular) figures in the table when you don’t want 
oldstyle figures.

 Another question about fonts. Is there a way to define a conditional 
 mathcommand based on the current alternative style? For instance, in the 
 following example I would like to keep the bold effect but with adaptation to 
 the local alternative style (in text mode, when the local alternative style 
 is \tf I would like the mathcommand to be \bf, when it is \it I would like 
 \bi, when it is \bf I would like \bf and when it is \bi I would like still 
 \bi):

You can access the current font alternative with the \fontalternative command 
(below is a old example I wrote a few months ago).

\def\Test
  {\processaction
 [\fontalternative]
 [ tf=Upright,
   it=Italic,
   sl=Slanted,
   bf=Bold,
   bi=Bolditalic,
   bs=Boldslanted,
  unknown=Unknown fontalternative]}
  
\starttext
“\Test” {\it “\Test”} {\bs “\Test”} {\sc “\Test”}
\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  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


[NTG-context] letter-module: the first letter is lost

2014-06-24 Thread Peter Münster
Hi,

With latest context, the T is lost:

\usemodule[letter]
\starttext
\startletter
This is a letter.
\stopletter
\startletter
TThis is a workaround.
\stopletter
\stoptext

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


[NTG-context] Character alignment in math mode

2014-06-24 Thread Maggyero
 You can access the current font alternative with the \fontalternative
command

Thanks Wolfgang, that was exactly the command I was looking for!

A last question: how can one get italic greek in TEXT MODE? The following
code displays upright greek.

\starttext
\mathgreekitalic \alpha
\stoptext
___
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  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___