Re: [NTG-context] interaction kills hyperlinks

2012-03-23 Thread Steffen Wolfrum

Am 22.03.2012 um 22:37 schrieb Hans Hagen:

 On 22-3-2012 16:09, Steffen Wolfrum wrote:
 [as the first posting was labeled spam, I try it once more:]
 
 
 Hi,
 
 it's probably a rare case: URL with comma.
 
 Just by chance I found that these URL kill hyperlinks when interaction is 
 active:
 
 \setupinteraction
   [state=start]
 
 \starttext
 
 \goto{\hyphenatedurl{www.spiegel.de/spiegel/0,1518,288433,00.html}}[url(http://www.spiegel.de/spiegel/0,1518,288433,00.html)]
 
 \goto{\hyphenatedurl{www.ftd.de/politik/deutschland/1058704515970.html}}[url(http://www.ftd.de/politik/deutschland/1058704515970.html)]
 
 \stoptext
 
 Strange, isn't?
 
 not at all, as between [] there can be a list of actions to be done, in your 
 case only one; so put {} around it:
 
 1: 
 \goto{\hyphenatedurl{www.spiegel.de/spiegel/0,1518,288433,00.html}}[{url(http://www.spiegel.de/spiegel/0,1518,288433,00.html)}]
 
 2: 
 \goto{\hyphenatedurl{www.ftd.de/politik/deutschland/1058704515970.html}}[{url(http://www.ftd.de/politik/deutschland/1058704515970.html)}]



ah that's the reason, of course.

thanks a lot for your reply!
st.
___
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] interaction kills hyperlinks

2012-03-23 Thread Steffen Wolfrum

Am 23.03.2012 um 08:49 schrieb Steffen Wolfrum:

 
 Am 22.03.2012 um 22:37 schrieb Hans Hagen:
 
 On 22-3-2012 16:09, Steffen Wolfrum wrote:
 [as the first posting was labeled spam, I try it once more:]
 
 
 Hi,
 
 it's probably a rare case: URL with comma.
 
 Just by chance I found that these URL kill hyperlinks when interaction is 
 active:
 
 \setupinteraction
  [state=start]
 
 \starttext
 
 \goto{\hyphenatedurl{www.spiegel.de/spiegel/0,1518,288433,00.html}}[url(http://www.spiegel.de/spiegel/0,1518,288433,00.html)]
 
 \goto{\hyphenatedurl{www.ftd.de/politik/deutschland/1058704515970.html}}[url(http://www.ftd.de/politik/deutschland/1058704515970.html)]
 
 \stoptext
 
 Strange, isn't?
 
 not at all, as between [] there can be a list of actions to be done, in your 
 case only one; so put {} around it:
 
 1: 
 \goto{\hyphenatedurl{www.spiegel.de/spiegel/0,1518,288433,00.html}}[{url(http://www.spiegel.de/spiegel/0,1518,288433,00.html)}]
 
 2: 
 \goto{\hyphenatedurl{www.ftd.de/politik/deutschland/1058704515970.html}}[{url(http://www.ftd.de/politik/deutschland/1058704515970.html)}]



your example (1) does not work:


\setupinteraction
   [state=start]

\starttext

text 
\goto{\hyphenatedurl{www.spiegel.de/spiegel/0,1518,288433,00.html}}[{url(http://www.spiegel.de/spiegel/0,1518,288433,00.html)}]

test\footnote{\goto{\hyphenatedurl{www.spiegel.de/spiegel/0,1518,288433,00.html}}[{url(http://www.spiegel.de/spiegel/0,1518,288433,00.html)}]}

\stoptext


Steffen 
(vers. 2012.03.13)

___
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] [***SPAM***] \about without quotes

2012-03-23 Thread Steffen Wolfrum
Hi,

how can I get rid of the quotes around about's output (see below)?


\starttext

\chapter[
reference={ref123},
title={Titel},
  marking={Titel},
 list={Titel},
 bookmark={Titel}]


see in \at[ref123] \about[ref123]

(should be “1 Titel”)

\stoptext



Steffen
___
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] Lettrine misbehaving in beta

2012-03-23 Thread Hans Hagen

On 23-3-2012 01:15, Alan Braslau wrote:

On Thu, 22 Mar 2012 22:47:13 +0100
Hans Hagenpra...@wxs.nl  wrote:



(dropping caps is something that can interfere with anything else
that synchronizes at the start of a paragraph)



Like \definetextbackground [Highlight] [location=paragraph] ?


yes, because that will put some positional info in front (you can try to 
say: \tracepositions)


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] [***NOSPAM***] \about without quotes

2012-03-23 Thread Steffen Wolfrum

Am 23.03.2012 um 09:59 schrieb Steffen Wolfrum:

 Hi,
 
 how can I get rid of the quotes around about's output (see below)?
 
 
 \starttext
 
 \chapter[
 reference={ref123},
title={Titel},
  marking={Titel},
 list={Titel},
 bookmark={Titel}]
 
 
 see in \at[ref123] \about[ref123]
 
 (should be “1 Titel”)
 
 \stoptext



\setupreferencing[left=,right=]

This woks, ie. changes \about output too.
But how can I be sure I changed *only* \about output?

Steffen
___
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] Formatting Indexed Words Within the Text

2012-03-23 Thread Malte Stien
Hi all,

Is it possible to format indexed words in a particular style within the text 
more or less automatically. For example, if I write

  There are some \index[ducks] in the zoo.

...I would like the term ducks to appear in small-capitals to indicate the 
that term can be found in the index. Ideally, I'd like to do that without 
explicit manual formatting. Is that possible?

Thank you,
Malte.

___
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] Floating figures – text wrapping and captions alignment

2012-03-23 Thread Honza Hejzl
Hello ConTeXists,

I wrote my questions maybe in a confusing way.

It seems two things with floating figures (especially with placing
pictures) are maybe broken.

1) It is impossible to achieve proper text wrapping around figure when the
GRID is ON. I have tried more suggestions.
2) The second thing is there is no way how to change alignment in captions.


\enableregime[utf]
\mainlanguage[en]
\setuppapersize[A5][A5]
\definefloat[figure][figures]
\setuplayout[grid=yes]
\setupcaption[figure][%
align=left,
%align=right,
style=\ss, distance=2pt,before={\noindent}]
\showgrid

\starttext
\input tufte

%\movesidefloat[x=10pt,y=-40pt]
%\movesidefloat[3*line]
%\hangsidefloat[3]

\placefigure[left]{sdf}{\externalfigure[none][height=3cm]}
\input tufte
 \stoptext

Any help appreciated.

Honza Hejzl
___
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] Formatting Indexed Words Within the Text

2012-03-23 Thread Rogers, Michael K
On Mar 23, 2012, at 6:57 AM, Malte Stien wrote:

 Is it possible to format indexed words in a particular style within the text 
 more or less automatically. For example, if I write

  There are some \index[ducks] in the zoo.

 ...I would like the term ducks to appear in small-capitals to indicate the 
 that term can be found in the index. Ideally, I'd like to do that without 
 explicit manual formatting. Is that possible?

 Thank you,
 Malte.

One way is to use your own macro:

\def\MyIndex#1{\index{#1}{\sc #1}}
\starttext
There are some \MyIndex{ducks} in the zoo.
\stoptext

By the way, your \index[ducks] didn't work for me the way I thought you wanted; 
I changed the [] to {} and added the word to the text body.  As far as I can 
tell, \index only adds entries to the index register and not to the text.



This e-mail message (including any attachments) is for the sole use of
the intended recipient(s) and may contain confidential and privileged
information. If the reader of this message is not the intended
recipient, you are hereby notified that any dissemination, distribution
or copying of this message (including any attachments) is strictly
prohibited.

If you have received this message in error, please contact
the sender by reply e-mail message and destroy all copies of the
original message (including attachments).
___
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] Widgets getting check marks instead of colors when the next one is clicked.

2012-03-23 Thread Mikael P. Sundqvist
Dear list,

1) Look at the output of this simple document (attached as test.pdf).
If I click the first one I get a green square as I want. But when I
click the second one the first one loses its color and get a check
mark instead (tested on linux and windows). Is there anything I can do
to keep the green square when the red is clicked?

%%% BEGINNING OF FILE
\setupinteraction[state=start,color=darkblue]

\setupfield[setup 3]
[width=1.2ex, height=1.2ex,
rulethickness=1pt, framecolor=darkblue,offset=overlay]

\definesymbol [ryes]
[{\framed[frame=off,width=2em,height=2em,background=color,backgroundcolor=darkgreen]{
}}]
\definesymbol [rno] []
\definesymbol [wyes]
[{\framed[frame=off,width=2em,height=2em,background=color,backgroundcolor=darkred]{
}}]
\definesymbol [wno] []

\definefield [rcheckme][check] [setup 3] [ryes,rno] [rno]
\definefield [wcheckme][check] [setup 3] [wyes,wno] [wno]


\starttext
\field[rcheckme] Germany is a country in Europe.

\field[wcheckme] All germans are men.

\goto{Reset}[ResetForm]
\stoptext
%%% END OF FILE

2) In the example file above I also use ResetForm to clear all the
checks. Is there a way to get a button/link such that when I click it
all squares are checked (in my case colored red or green)?

Best regards, Mikael

PS If this method is outdated and there is a better one, please do not
hesitate to tell me.


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

Re: [NTG-context] Formatting Indexed Words Within the Text

2012-03-23 Thread Alan BRASLAU
On Fri, 23 Mar 2012 21:57:04 +1100
Malte Stien ma...@stien.de wrote:

 Hi all,
 
 Is it possible to format indexed words in a particular style within
 the text more or less automatically. For example, if I write
 
   There are some \index[ducks] in the zoo.
 
 ...I would like the term ducks to appear in small-capitals to
 indicate the that term can be found in the index. Ideally, I'd like
 to do that without explicit manual formatting. Is that possible?
 
 Thank you,
 Malte.

Your example above would not print the word ducks at all.


I commonly use:
\def\Index#1{\index{#1}#1}

There are some \Index{ducks} in the zoo.


In ConTeXt, text to be typeset typically appears within {}.
Of course, you can then modify the definition to format the text as you
wish:
\def\Index#1{\index{#1}\sc #1}

I'm sure that there is a more clever way.

Note that the \index{} command appears *before* the word, not after.
Otherwise, the word might get placed at the end of a page and the index
point to the following page. I believe that the \index{} command takes
care to avoid the opposite case.

Alan
___
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] References broken when using more than one component?

2012-03-23 Thread Steffen Fritzsche
Does anybody know when this will be fixed?

Thanks!
Steffen


Am 21.03.2012 um 15:09 schrieb Steffen Wolfrum:

 
 I consider it a bug.
 
 Steffen W.
 
 
 Am 21.03.2012 um 13:54 schrieb Steffen Fritzsche:
 
 Hi,
 
 I've got a deep hierarchy of components, while everything builds fine I have 
 a problem using references. Have a look at the following sample files:
 
 reftest.tex:
 \setuphead[chapter][referenceprefix=+]
 
 \starttext
 
 \chapter[one]{Chapter One}
 
 \section[bla]{Blablabla}
 See \in{Section}[three:foobar]
 
 \chapter[two]{Chapter Two}
 
 \section[blubb]{BlubbBlubbBlubb}
 
 \subsection{BlubberBlubber}
 See \in{Section}[one:bla]
 
 \component refcomp
 
 \stoptext
 
 refcomp.tex:
 \startcomponent refcomp
 \chapter[three]{Chapter Three}
 \component refcompsec
 \stopcomponent
 
 refcompsec.tex:
 \section[foobar]{Foobar Section}
 See \in{Section}[two:blubb] for more details!
 \stopcomponent
 
 
 If I move the second component refcompsec.tex into the refcomp.tex 
 component the reference in chapter one is found. If I translate it as shown 
 using two components the reference in the first chapter is lost.
 
 Is this a bug or am I doing something wrong?
 
 Cheers,
 Steffen___
 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
 ___
 
 ___
 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
 ___
 



smime.p7s
Description: S/MIME cryptographic 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  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

[NTG-context] reference \about shall not be shortened

2012-03-23 Thread Steffen Wolfrum
Hi,

how can I avoid shortening of referenced titles?


\setupreferencing[left=,right=]

\starttext

\chapter[
reference={ref123},
title={This is a long titel -- every word is meaningful and shall not be 
omitted},
  marking={Titel},
 list={Titel},
 bookmark={Titel}]

see in “\at[ref123] \about[ref123]”.

\stoptext



Steffen
___
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] reference \about shall not be shortened

2012-03-23 Thread Wolfgang Schuster

Am 23.03.2012 um 16:33 schrieb Steffen Wolfrum:

 Hi,
 
 how can I avoid shortening of referenced titles?
 
 \setupreferencing[left=,right=]

Add “width=” to \setupreferencing or use \getreference[title][ref123] to print 
the title of the heading.

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] References broken when using more than one component?

2012-03-23 Thread Hans Hagen

On 23-3-2012 14:05, Steffen Fritzsche wrote:

Does anybody know when this will be fixed?


I'll look into it when I have time.

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] Formatting Indexed Words Within the Text

2012-03-23 Thread Hans Hagen

On 23-3-2012 11:57, Malte Stien wrote:

s it possible to format indexed words in a particular style within the text 
more or less automatically. For example, if I write

   There are some \index[ducks] in the zoo.

I would like the term ducks to appear in small-capitals to indicate the 
that term can be found in the index. Ideally, I'd like to do that without explicit manual 
formatting. Is that possible?


in the test suite: registers/processors-001.tex

\defineprocessor[bf][style=bold]
\defineprocessor[it][style=italic]

\starttext

\index{it-italic}\index{normal}
This is a \index[bf-bold]{test with bold number}test.
This is a less important \index{test}test.

\placeindex

\stoptext

so the magic word is 'processors'

-
  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] Widgets getting check marks instead of colors when the next one is clicked.

2012-03-23 Thread Hans Hagen

On 23-3-2012 13:33, Mikael P. Sundqvist wrote:

Dear list,

1) Look at the output of this simple document (attached as test.pdf).
If I click the first one I get a green square as I want. But when I
click the second one the first one loses its color and get a check
mark instead (tested on linux and windows). Is there anything I can do
to keep the green square when the red is clicked?


There are some examples in the test suite.

In the latest acrobat check (and radio) rendering is a mess. The 
standard permits specific rendering and that has always worked ok. 
However, in currently interferes with acrobat pushing its own 
visualization on top. Some time ago took me days to figure out how / 
what went wrong and as a consequence I've removed some functionality 
simply because it is not rendered okay anyway. (It all has to do with 
generated appearance streams in the viewer, and I get the strong 
impression that there are no other apps out there that provide custom 
rendering.)


One way out is to disable the (by default enabled) highlighting of 
fields in the viewer (which I found out by coincidence). That can also 
be done by a javascript by loading the rhh file.


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] Widgets getting check marks instead of colors when the next one is clicked.

2012-03-23 Thread Mikael P. Sundqvist
On Fri, Mar 23, 2012 at 1:33 PM, Mikael P. Sundqvist mic...@gmail.com wrote:
 Dear list,

 1) Look at the output of this simple document (attached as test.pdf).
 If I click the first one I get a green square as I want. But when I
 click the second one the first one loses its color and get a check
 mark instead (tested on linux and windows). Is there anything I can do
 to keep the green square when the red is clicked?

 %%% BEGINNING OF FILE
 \setupinteraction[state=start,color=darkblue]

 \setupfield[setup 3]
        [width=1.2ex, height=1.2ex,
        rulethickness=1pt, framecolor=darkblue,offset=overlay]

 \definesymbol [ryes]
 [{\framed[frame=off,width=2em,height=2em,background=color,backgroundcolor=darkgreen]{
 }}]
 \definesymbol [rno] []
 \definesymbol [wyes]
 [{\framed[frame=off,width=2em,height=2em,background=color,backgroundcolor=darkred]{
 }}]
 \definesymbol [wno] []

 \definefield [rcheckme][check] [setup 3] [ryes,rno] [rno]
 \definefield [wcheckme][check] [setup 3] [wyes,wno] [wno]


 \starttext
 \field[rcheckme] Germany is a country in Europe.

 \field[wcheckme] All germans are men.

 \goto{Reset}[ResetForm]
 \stoptext
 %%% END OF FILE

 2) In the example file above I also use ResetForm to clear all the
 checks. Is there a way to get a button/link such that when I click it
 all squares are checked (in my case colored red or green)?

 Best regards, Mikael

 PS If this method is outdated and there is a better one, please do not
 hesitate to tell me.

Hm, I now tried the file and the first problem is gone in acrobat
reader at home (linux, acrobat reader version 9.1.2). In other words,
the colors do stay here after checking other boxes. If I remember
correctly I had ver 9.2 at the linux machine at work. About the
version for Windows I do not remember.

Ah, I read Hans' (thanks!) reply as I type this and so it seems to be
a problem with later versions of Acrobat reader, which explains why it
works at home but not at work. Maybe I should simply come up with
another solutions to do these small tests for the students, as I
cannot be sure what version they are using...

Best regards, Mikael
___
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] how can I use framewidth in calculations

2012-03-23 Thread Thomas A. Schmitz

Hi all,

maybe I'm overlooking something obvious, but...: when I have a figure, I 
can calculate its width dependent on the page width, and it will adapt:


\starttext

\externalfigure[cow][width=0.6\textwidth]

\stoptext

But is there a method for similar calculations inside a frame? Here's 
what I tried, but it doesn't give the expected result (the image is much 
smaller than expected):


\starttext

\framed[width=7cm]{\externalfigure[cow][width=\the\dimexpr0.9\framedparameter{width}\relax]}

\stoptext

Thanks for any pointers!

Thomas
___
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] new lucida font

2012-03-23 Thread Renaud AUBIN
Le 19/03/2012 11:36, Wolfgang Schuster a écrit :
 Can you try to attached typescript file, I replaced the files for italic and 
 bolditalic fonts for the sans style with the names from the latex example 
 document. The slanted and boldslanted alternatives for the sans style are 
 also 
 fixed.

 Wolfgang

+Small Caps support:
38,42d37
 \starttypescript [\s!serif] [lucidanova,lucidaot,otlucida]
 \definefontsynonym [\s!SerifCaps][\s!Serif]
[\s!features=smallcaps]
 %definefontsynonym [\s!SerifBoldCaps][\s!SerifBold]
[\s!features=smallcaps]
 \stoptypescript


The SerifBoldCaps line is commented out since I get an error at
processing… and can't figure why…

Renaud
___
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] how can I use framewidth in calculations

2012-03-23 Thread Rogers, Michael K

On Mar 23, 2012, at 6:55 PM, Thomas A. Schmitz wrote:

But is there a method for similar calculations inside a frame? Here's what I 
tried, but it doesn't give the expected result (the image is much smaller than 
expected):

\starttext

\framed[width=7cm]{\externalfigure[cow][width=\the\dimexpr0.9\framedparameter{width}\relax]}

\stoptext

Thanks for any pointers!

Thomas

Try

\framed[width=7cm]{\externalfigure[cow][width=\dimexpr\framedparameter{width}*9/10]}

[I don't understand \dimexpr.   For instance 7cm = ~198pt, 0.9 * 7 cm = ~179pt, 
but \dimexpr0.9\framedparameter{width} yields 27.5992pt.  It doesn't seem to 
work well with decimals.  No wiki page for it, that I can find.]



This e-mail message (including any attachments) is for the sole use of
the intended recipient(s) and may contain confidential and privileged
information. If the reader of this message is not the intended
recipient, you are hereby notified that any dissemination, distribution
or copying of this message (including any attachments) is strictly
prohibited.

If you have received this message in error, please contact
the sender by reply e-mail message and destroy all copies of the
original message (including attachments).
___
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] Formatting Indexed Words Within the Text

2012-03-23 Thread Malte Stien
Hi,

I got a few responses for this. Thank you to all of you. I ended up using the 
code below. Works a treat. And yes, apologies. The square brackets were a typo; 
of course they should have been curly.

Thank you again.
Malte.


On 24/03/2012, at 0:01, ntg-context-requ...@ntg.nl wrote:

 One way is to use your own macro:
 
 \def\MyIndex#1{\index{#1}{\sc #1}}
 \starttext
 There are some \MyIndex{ducks} in the zoo.
 \stoptext
 
 By the way, your \index[ducks] didn't work for me the way I thought you 
 wanted; I changed the [] to {} and added the word to the text body.  As far 
 as I can tell, \index only adds entries to the index register and not to the 
 text.

___
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] Problem Nesting defineitemgroups

2012-03-23 Thread Malte Stien
I have the following two definitions for bullet point lists...

  % Setup bullet point lists
  \defineitemgroup[blist][before={\blank[1ex]}]
  \setupitemgroup[blist][1][packed][symbol=1]
  \setupitemgroup[blist][2][packed][symbol=2]

... and numbered lists

  % Setup numbered lists
  \defineitemgroup[nlist][before={\blank[1ex]}]
  \setupitemgroup[nlist][1][packed][symbol=n, headstyle=bold]
  \setupitemgroup[nlist][2][packed][symbol=a, headstyle=bold]

They generally seem to work well, but when I try to nest one within the other, 
like so

  \startnlist
  \item Foo
  \startblist
  \item Some bullet item 1,
  \item Some bullet item 2,
  \item Some bullet item 3.
  \item Assign an appropriate criticality.
  \stopblist
  \item Baz
  \startnlist

...I get unexpected behaviour as follows:

  1. Foo
 a. Some bullet item 1,
 b. Some bullet item 2,
 c. Some bullet item 3.
  2. Baz

I was expecting this instead

  1. Foo
 + Some bullet item 1,
 + Some bullet item 2,
 + Some bullet item 3.
  2. Baz

...(where + denotes the round bullet point). Is this a defect or am I doing 
something wrong?

Regards,
Malte.

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

2012-03-23 Thread Malte Stien
Hi again,

I just noticed that the last line of my code was

  \startnlist

when it should have been

  \stopnlist

It was correct in my code, but too much fiddling and trying things made it 
wrong when I copied it across to the email. Even with the correct line in 
there, my problem still exists.

Regards,
Malte.


On 24/03/2012, at 15:25, Malte Stien wrote:

 I have the following two definitions for bullet point lists...
 
  % Setup bullet point lists
  \defineitemgroup[blist][before={\blank[1ex]}]
  \setupitemgroup[blist][1][packed][symbol=1]
  \setupitemgroup[blist][2][packed][symbol=2]
 
 ... and numbered lists
 
  % Setup numbered lists
  \defineitemgroup[nlist][before={\blank[1ex]}]
  \setupitemgroup[nlist][1][packed][symbol=n, headstyle=bold]
  \setupitemgroup[nlist][2][packed][symbol=a, headstyle=bold]
 
 They generally seem to work well, but when I try to nest one within the 
 other, like so
 
  \startnlist
  \item Foo
  \startblist
  \item Some bullet item 1,
  \item Some bullet item 2,
  \item Some bullet item 3.
  \item Assign an appropriate criticality.
  \stopblist
  \item Baz
  \startnlist
 
 ...I get unexpected behaviour as follows:
 
  1. Foo
 a. Some bullet item 1,
 b. Some bullet item 2,
 c. Some bullet item 3.
  2. Baz
 
 I was expecting this instead
 
  1. Foo
 + Some bullet item 1,
 + Some bullet item 2,
 + Some bullet item 3.
  2. Baz
 
 ...(where + denotes the round bullet point). Is this a defect or am I doing 
 something wrong?
 
 Regards,
 Malte.
 

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