Re: [NTG-context] Hanging punctuation misalignment in footnotes

2014-02-22 Thread Hans Hagen

On 2/22/2014 1:25 AM, Jan Tosovsky wrote:

On 2014-02-22 Jan Tosovsky wrote:


when hanging in footnotes is enabled and the starting character is a
punctuation, it is not protruded. However, the same character in the
footnote body works fine. When both cases are close each other, it
looks weird, see the screenshot:

http://drifted.in/other/footnote_alignment.png

Would it be possible make this behaviour uniform - either do not
protrude it
on the starting (left) edge or protrude it everywhere?



A minimal example is available at
http://drifted.in/other/sample.tex

(those guillemets would be lost here in the mailing list)

Tested in the current beta on Windows (it requires Palatino Linotype font).


Hard to solve that one fast .. basically all that gets bound to a next 
characters makes that next character not protrude. This is not something 
the engine can solve as it doesn't know what it deals with (so the 
current behaviour is as it should be).


Maybe in a future version of context I can deal with it (as I know how 
to do it, but that doesn't help much now).


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
___


Re: [NTG-context] Hanging punctuation misalignment in footnotes

2014-02-22 Thread Jan Tosovsky
On 2014-02-22 Hans Hagen wrote:
 On 2/22/2014 1:25 AM, Jan Tosovsky wrote:
  On 2014-02-22 Jan Tosovsky wrote:
 
  when hanging in footnotes is enabled and the starting character is a
  punctuation, it is not protruded. However, the same character in the
  footnote body works fine. When both cases are close each other, it
  looks weird, see the screenshot:
 
  http://drifted.in/other/footnote_alignment.png
 
  Would it be possible make this behaviour uniform - either do not
  protrude it
  on the starting (left) edge or protrude it everywhere?
 
 
  A minimal example is available at
  http://drifted.in/other/sample.tex
 
  (those guillemets would be lost here in the mailing list)
 
  Tested in the current beta on Windows (it requires Palatino Linotype
 font).
 
 Hard to solve that one fast .. basically all that gets bound to 
 a next characters makes that next character not protrude. This is 
 not something the engine can solve as it doesn't know what it deals 
 with (so the current behaviour is as it should be).

:-/

 Maybe in a future version of context I can deal with it (as I know how
 to do it, but that doesn't help much now).

I am looking forward to it. 

While I can intervene manualy now {\hskip -0.7mm}Fel..., it is of no use
for dynamic publishing.

Thanks, Jan

___
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] Obscure math/color bug (namespace clash)

2014-02-22 Thread Hans Hagen

On 2/19/2014 9:53 AM, Alan BRASLAU wrote:

Hello,

I came across the following obscure math/color namespace clash:



\definecolor [tan] [h=d2b48c] % Taken from \setupcolor [x11]

\starttext
$\tan θ$
\stoptext



One solution would be to give precedence in math mode to the standard 
mathematical tokens (here \tan).

Another solution would be simply to avoid the use of tan (as a color). In colo-imp-x11.mkiv it 
could be renamed tan0 (there is already tan1, tan2, tan3). This is somewhat unfortunate as 
tan is a standard X11 color name. On the other hand, one would like to be able to use colors in 
math mode as well...

So I propose the following patch:

121c121
 \definecolor [tan0] [h=d2b48c] % ! namespace clash with $\tan$
---

\definecolor [tan]  [h=d2b48c]


\definecolor [tan] [h=d2b48c] % Taken from \setupcolor [x11]

\starttext
$\mathcommand{tan} θ$

\let\tan\relax

\color[tan]{Alan}
\stoptext


-
  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] Paragraph - the last line handling

2014-02-22 Thread Jan Tosovsky
On 2014-02-19 Jan Tosovsky wrote:
 On 2013-11-23 Hans Hagen wrote:
  On 11/23/2013 2:43 PM, Jan Tosovsky wrote:
   On 2013-11-23 Hans Hagen wrote:
   On 11/22/2013 11:07 PM, Jan Tosovsky wrote:
  
   in my document there are lot of cases when the last line in the
   paragraph has a very narrow gap on the right.
  
   \hsize 15.4cm
  
   \input tufte
  
   \parfillskip30pt plus 1 fill  \input tufte
  
   Wow, exactly! Thanks a lot.
  
   Sorry for a dumb question, but is there any way how to use it
   globally for all paragraphs in my document?
 
  no, as i need to think of a decent interface to that (so remind me in
  a few months)
 
 When this gap (parfillskip) is set in the beginning of the document, it
 is shared for all paragraphs within the document. I was not aware of that.


I've found while this setting in the beginning of the document is applied to
all paragraphs, it is not shared in footnotes.

I am fixing it by repeating this command at the beginning of every footnote,
but I am curious why footnotes are handled differently. 

Is it possible to set this behavïour for footnotes globally only once?

Thanks, Jan


___
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] Protrusion cancellation by index term

2014-02-22 Thread Jan Tosovsky
On 2014-02-22 Jan Tosovsky wrote:

 when a punctuated phrase appears at the beginning of the line, it is
 not protruded correctly when preceded by an index term.
 
 ... \index{foo}Bar ...
 
 A minimal example is available at
 http://drifted.in/other/sample.tex
 
 I cannot place the space character between these two parts (which
 helps) as I sometimes need to join this and the previous phrase with 
 the non-breaking space.
 

It is more serious issue than expected. Consider next two variants:

(1) sentence, \index{primary}Primary 
(2) sentence,\index{primary} Primary

When the line is broken after a comma:
ad 1) starting guillemet is not protruded
ad 2) ending comma is not protruded

When \index is surrounded by spaces from both sides, the space is rendered
at the beginning of the next line (resulting in 'indenting').

:-S

I'd be grateful for ignoring any non document content preceding punctuation
to avoid its influence on protrusion.

Thanks, Jan

___
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] solutions and problems

2014-02-22 Thread Xan
No, it does not work.

I have this:

% Questions
\defineenumeration
  [exercici]
  
[alternative=serried,text={\startcolor[darkblue]Exercici\stopcolor},stopper={.\space},left={\bgroup},right={\egroup},width=fit,headstyle=\ss,distance=0.25em,width=fit,before={\incrementcounter[resposta]}]

% Answers
\defineenumeration[resposta][headstyle=\ss,text={Solucions de l'exercici 
\getnumber[exercici]},width=fit,alternative=serried,before={\decrementcounter[resposta]},number=no]

\defineblock[resposta]
\hideblocks[resposta]


% Exercises

\startexercici Bla...
\beginresposta
\resposta (Solucions: \startitemize[a,text] \item D, \item I, \item D, \item No 
té relació, \item D, \item D, \item No té relació, \item No té relació, \item 
D.\stopitemize) \par
\endresposta
\stopexercici

\startexercici Bla 2
\stopexercici

\startexercici Bla 3
\beginresposta
\resposta (Solucions: \startitemize[a,text] \item D, \item I, \item D, \item No 
té relació, \item D, \item D, \item No té relació, \item No té relació, \item 
D.\stopitemize) \par
\endresposta
\stopexercici

\subject{Answers}

\selectblocks[resposta][criterium=section]


I get \getnumber[exercici] as the last, not the counter of 'exercici' in which 
I have the answer. How can I do thaT?

Thanks,
___
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] solutions and problems

2014-02-22 Thread Wolfgang Schuster

Am 22.02.2014 um 18:45 schrieb Xan dxpubl...@telefonica.net:

 No, it does not work.
 
 I have this:
 
 % Questions
 \defineenumeration
  [exercici]
  
 [alternative=serried,text={\startcolor[darkblue]Exercici\stopcolor},stopper={.\space},left={\bgroup},right={\egroup},width=fit,headstyle=\ss,distance=0.25em,width=fit,before={\incrementcounter[resposta]}]
 
 % Answers
 \defineenumeration[resposta][headstyle=\ss,text={Solucions de l'exercici 
 \getnumber[exercici]},width=fit,alternative=serried,before={\decrementcounter[resposta]},number=no]
 
 \defineblock[resposta]
 \hideblocks[resposta]
 
 
 % Exercises
 
 \startexercici Bla...
 \beginresposta
 \resposta (Solucions: \startitemize[a,text] \item D, \item I, \item D, \item 
 No té relació, \item D, \item D, \item No té relació, \item No té relació, 
 \item D.\stopitemize) \par
 \endresposta
 \stopexercici
 
 \startexercici Bla 2
 \stopexercici
 
 \startexercici Bla 3
 \beginresposta
 \resposta (Solucions: \startitemize[a,text] \item D, \item I, \item D, \item 
 No té relació, \item D, \item D, \item No té relació, \item No té relació, 
 \item D.\stopitemize) \par
 \endresposta
 \stopexercici
 
 \subject{Answers}
 
 \selectblocks[resposta][criterium=section]
 
 
 I get \getnumber[exercici] as the last, not the counter of 'exercici' in 
 which I have the answer. How can I do thaT?

Make a complete minimal example.

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] Font affects columnar list layout

2014-02-22 Thread Thangalin
I've posted the same question (with a bit more information on the
fixes I've attempted) on SE:

http://tex.stackexchange.com/questions/161711/context-font-change-shifts-column-content
___
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] \doifemptyelse

2014-02-22 Thread Pablo Rodriguez
On 02/20/2014 11:23 PM, Wolfgang Schuster wrote:
 Am 20.02.2014 um 23:09 schrieb Pablo Rodriguez oi...@gmx.es:
 [...]
 Only a minor detail: is there a more proper way to center both headings?
 
 You can use the simple version of \setupheadertexts and use \doifoddpageelse
 to check whether you’re on a left or right page. When you make a test for 
 content
 of a \getmarking command you have to use \doiftext because the \doifempty etc.
 checks don’t work in this case.

Many thanks for your reply, Wolfgang.

This was exactly what I needed. I must admit that I didn’t understood
what the simple version of \setupheadertexts was about. And \doiftext
(as well as \doifsomething) were totally unknown to me.

Many thanks again for your help,


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
___


Re: [NTG-context] \doifemptyelse

2014-02-22 Thread Pablo Rodriguez
On 02/20/2014 11:32 PM, Thangalin wrote:
 Have you looked at:
 
 http://wiki.contextgarden.net/Headers_and_Footers#Marginal_headings_and_centered_headings
 
 ?

Many thanks for your reply, Thagalin.

I even compiled the sample code, but I hadn’t understood how the
\setupheadertexts worked with a single argument and changing headers for
double-sided pages.


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
___