Re: [NTG-context] Change whitespace before item?

2009-08-11 Thread Wolfgang Schuster


Am 11.08.2009 um 20:29 schrieb U Avalos:


Like I said, I tried "margin" and it does NOT work. "Margin" has no
effect on sub-lists.


You *never* wrote anything about sublevels before, who do you expect
we should know what do you mean without enough information?

The value for 'margin' as added to the left margin for each level,
sub levels are controlled with the 'width' parameter. You can then
align the number/symbol/... with 'itemalign' or with  
'left=hskip'.


\showframe

\starttext

\startitemize[n]
\item Item 1
\item Item 2
\startitemize[a][left=\hskip1cm,width=2cm]
\item Item 1
\item Item 2
\stopitemize
\stopitemize

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


Re: [NTG-context] Bold letters in math and does tikz work

2009-08-14 Thread Curiouslearn
> You can get bold upright symbol in math fonts. There was a bug in
> math-vfu.lua, for which I gave a patch in my previous email. If you apply
> that patch to math-vfu and then regenerate formats, ${\bf A}$ will give
> upright bold math. If you do not want to patch math-vfu on your own, wait
> for the next beta by Hans.
>
> This will not work with bold greek letters or bold operators.
>
>
> Aditya
>

Thanks Aditya. I have no clue how to use the patch. I think I will wait for
the next Beta from Hans.
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] Dash missed in Windows' Times

2009-10-27 Thread Vyatcheslav Yatskovsky
Thanks for reply. Who is "mkiv-math-team" and when it is going to fix 
it? (I mean days or monthes or years..) If it's gonna take too long, I 
would preferably fill the gaps by myself, just tell me where to dig ;)
>  
>  In the latest mkiv beta, dash (--) is not replaced by proper symbol if I

>  use standard Windows' Times New Roman. I get two hyphens instead.
>  
>  Actually, ConTeXt complains a lot about missed unicode "points". Please,

>  see log attached.
>  
>  How to fix it?
 

the mkiv-math-team simply had no time yet to fill in some of the gaps in
the vector for tx / px
   

Regards,
Vyatcheslav
___
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] Re: Dense Encoding - Comments wanted

2005-08-19 Thread Vit Zyka

Patrick Gundlach wrote:

Hi Adam,



On Hans's suggestion, I've been working on a "dense" character encoding
that does away with combining accents and extraneous symbol-like
characters in favor of fully accented characters.




<http://homepage.mac.com/atl/tex/dense.pdf>



do you have an enc file to play with?



So with those goals in mind, does anyone notice their favorite *letter*
missing? Is there essential punctuation missing?




OK for Czech chars too.

Only tcaron char is not searchable (if in my AR7 search for any letter, 
say 'a' I got all accented a variant; if for 't' 'ť' is not find), but I 
do not know if the problem is in a) AR, b) CMAP, c) encoding (enco in 
the font presented in the PDF has mostly tcaron but tquoteright is 
presented too). But tt is not a big problem.


vit

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


[NTG-context] Re: MathML: Please ignore ⁡

2005-10-13 Thread Duncan Hothersall
> Salvete,
> 
>  I just started to think about using ConTeXt on XML input files, so I've
> got a question which should be easy to answer:  My MathML source
> generates presentation code which includes ⁡ between a
> function symbol and its arguments.  I get a black rectangle for that;
> I'd like ConTeXt to ignore this character, where do I define it as
> “nothing”?

This is the hex unicode reference for the entity ⁡ which is already
defined in xtag-mml.tex as nothing ({}) via its expansion into
⁡.

So the problem seems to be in arriving at ⁡ from ⁡. I'm not
sure how to do that, but in the meantime you can define ⁡
explicitly using:

\defineXMLentity [x02061] {}

I think there is a mapping mechanism though, since a lot of Unicode is
supported natively; perhaps the vector to which ⁡ belongs hasn't been
completed yet.

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


Re: [NTG-context] Insufficient symbol fonts error

2005-10-31 Thread Hans Hagen

Thomas A. Schmitz wrote:


Alan,

I know next to nothing about math, but I know that the Greek  
typescripts do not define a math font. So you will get errors doing  
math when the body font is Greek. I wish I could help, but defining a  
math font is beyond my abilities. If anyone is interested in doing  
it, however, I will be happy to provide the specs for the Greek fonts.


because math is also used for text (some symbols) you need a math font 
(when using typefaces); the best is to define greek as part of a 
typeface and define a proper math with it); it depends a bit on what 
trickery you use;


(normally such problems should not happen so i'm a bit puzzled)

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


Re: [NTG-context] About 'repeat' option of \startitemize

2005-12-22 Thread Hans Hagen

Radhelorn wrote:


Hans Hagen wrote:


Radhelorn wrote:

1. item
1.1item
   1.2.1  item
  1.2.1.1.item
  1.2.2.1em

for that you can best set up a dedicated instance of itemize 
(defineitemgroup) and assign the right widths to the levels


I'm sorry to disturb you with my endless requests but it seems that 
options of itemgroups is not interact properly.


I've tried as you suggested this way:

\defineitemgroup[myitemize]
\setupitemgroup[myitemize][n,width=4em]


\setupitemgroup[myitemize][each][width=4em]
\setupitemgroup[myitemize][each][n]




\startmyitemize
\item item 1
\item item 2
\stopmyitemize

It gives many "missing or ungrouped '=' after 'n'" messages and 
changes item symbol to default dot. I've also tried n=1 or n=2 (seen 
in the sources). This gives same result, but without error message.


Thanks for your patience.



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


[NTG-context] Struggling with ttf on Windows XP

2006-01-11 Thread Frederic Donckels
Hello,

I recently upgraded my 3-year old installation of MikTex to the latest version.
I had a document which contained glyphs from the windings.tff font. Once I 
upgraded,
this didn't work anymore.

So I tried to read around to find out how it works, and so on, but couldn't 
find anything...

I have generated an afm and tfm files from the ttf font.
I created a map file which references this.
My tex file apparently loads the map file without problem (at least pdftex 
doesn't complain).

But, when I call \showfont, the generated table is empty, it doesn't contain 
any symbol.

(I'm at work right now, so I can't post any code snippet)

Does anyone have any clue or could anyone point me to any resource to guide me?

Thanks,

Best regards,

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


Re: [NTG-context] setuptabulate

2006-01-19 Thread Taco Hoekwater



Henning Hraban Ramm wrote:

Am 2006-01-19 um 11:53 schrieb Hans van der Meer:

What is with tabulation? I use it because I find it handy, but  the 
setuptabulate seems not working.

This gives NO alignment and NO rule. Is something wrong?


I'm surprised that tabulates should have align and rule at all,  but 
texshow states so.

Why don't you use some sort of table?


The answer is simple: because I like the tabulation construct.



If you need rules, you must use some kind of table. It's no big change:

\setuptables[rulethickness=1pt]
\starttable[|c|c|]
\NC abc \VL xyz \NC\AR
\NC def \VL uvw \NC\AR
\stoptable

And you must use \VL for a vertical line instead of \NC


To put this another way, the | symbol only separates the column
templates, it does not imply a vertical line.

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


[NTG-context] Unicode Character Problem

2007-01-08 Thread Johannes Graumann
Hello,

I'm having trouble defining a new unicode character:

'versuch.tex' reads:
  \defineXMLentity    [\#9633]  {\symbol[8]}

'versuch.xml' reads:
  □

Trying to compile this like so:
  texmfstart texexec --environment=versuch.tex versuch.xml

Yields the error below. What am I doing wrong (this works for other things like
'\defineXMLentity[\#8211]{--}')?

Thanks for your insights!

Joh

kpathsea: Running mktexmf UnicodeRegular25
! I can't find file `UnicodeRegular25'.
<*> ...mag:=1; nonstopmode; input UnicodeRegular25

Please type another input file name
! Emergency stop.
<*> ...mag:=1; nonstopmode; input UnicodeRegular25

Transcript written on mfput.log.
grep: UnicodeRegular25.log: No such file or directory
mktextfm: `mf-nowin -progname=mf \mode:=ljfour; mag:=1; nonstopmode; input
UnicodeRegular25' failed to make UnicodeRegular25.tfm.
kpathsea: Appending font creation commands to missfont.log.

! Font \unicodefont=UnicodeRegular25 at 12.0pt not loadable: Metric (TFM) file
not found.
 \bodyfontsize

\unicodeglyph ... \currentfontscale \bodyfontsize
  \unicodestrut \unicodefont...

\uchar ...+\unicodetwo \relax \handleunicodeglyph
  \endgroup
l.1 □

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


Re: [NTG-context] font size > 12pt

2007-08-20 Thread Hans Hagen
zs wrote:
> Hi,
> 
> I would like to have font bigger than 12pt.
> When I try following, commented line causes error message "Math formula
> deleted: Insufficient symbol fonts." while compiled with luatex.
> Could you tell me why and how to fix it?
> 
> Thanks
> 
> ZS
> 
> \starttext
> \setupbodyfont[rm,13pt]
> 
> Some reaction O\low{2} $\rightarrow$ O\low{3}.
> %Some reaction\footnote{ O\low{2} $\rightarrow$ O\low{3} }.

you need to define a bodyfotn environment (probably explained somewhere 
on the wiki)

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


Re: [NTG-context] nesting \startitemize

2007-10-07 Thread Aditya Mahajan
On Sun, 7 Oct 2007, frantisek holop wrote:

> hmm, on Sun, Oct 07, 2007 at 09:02:34PM +0200, Mojca Miklavec said that
>> \setupitemize[1][n]
>> \setupitemize[2][a][left=(,right=),stopper=]
>> \setupitemize[3][i]
>> \setupitemize[4][1] % symbol nr. 1
>
> ok, i would like to create 2 types of itemizations like in latex.
> \begin{enumarate} vs \begin{itemize}  (or in html  vs )
>
> \begin{itemize} is basically \startitemize
>
> how would i go about defining \startenumarate ?
> i thought of something like this, but it's not working:

\defineitemgroup [enum] [levels=6]

\setupitemgroup[enum][1][n]
\setupitemgroup[enum][2][a][left=(,right=),stopper=]
% etc..

\starttext

\startenum
\item one
\startenum
\item two
\stopenum
\stopenum

\stoptext

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


Re: [NTG-context] TeX ligatures in XeTeX/LuaTeX: ``who needs them''?

2007-12-10 Thread Mojca Miklavec
On Dec 10, 2007 1:24 PM, Maurí­cio wrote:
>
> What about math mode? I've not used it that
> much, does it also have such kind of
> 'pseudo-ligatures'? I read that what I use in
> my keyboard to type minus (-) is actually
> just ascii minus/hyphen, but in Unicode
> there's an actual minus symbol (U+2212). Does
> that needs special handling?

Yes, and it has been taken care for that since the beginning of TeX
existance (you don't need to worry about it).

Another side of the truth is that there are no TeX math OpenType fonts
yet (but they're on their way).

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


Re: [NTG-context] UnicodeRegular

2004-01-17 Thread Christopher G D Tipper
>At 17:46 16/01/2004, you wrote:
>>I am trying to find a euro symbol for my work.
>>
>>MikTeX has a comprehensive package manager,  and I have tried installing 
>>packages "uni" [billed as "The Universal Font"] and "universa" but no joy. 
>>Does anyone know where to get this font? Please don't tell me from Y&Y :-)
>
>do you need unicode?
>
>   \usesymbols[eur]
>
>hans

Actually this just requires another font I don't have (eurose). If anyone has any 
exeprience with Unicode I would like the flexibility this provides, as the euro is 
just a sample case. btw I have searched CTAN for UnicodeRegular and eurose, and no 
hits. If anyone happens to know which package bundles either of these two fonts I'd 
appreciate it. Especially if you have it working in MiKTeX 2.4.

Thanks all.
Christopher

___
ntg-context mailing list
[EMAIL PROTECTED]
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] How to rotate a single character on a line?

2004-03-24 Thread Hans Hagen
At 16:22 23/03/2004, you wrote:
Hi all.

I want to use some arrows of the ZapfDingbats fonts. Most of the arrows 
included in this font are directed from left to right. I tried to use 
\rotate to produce arrows directed to different directions. Yet, rotate 
produces new lines.

Example:

\definefontsynonym[ZapfDingbats][zd]
\definefont[Zapf][ZapfDingbats at 24pt]
\rotate[rotation=180]{\Zapf\char234} {\Zapf\char234}

The example is intended to produce an arrow directed to the left followed 
by an arrow directed to the right. The result however is an arrow directed 
to the left followed by a new line with an arrow directed to the right.

intended:
<- ->
result:
<-
->
Does someone know how the new line can be suppressed?
(untested)

\definesymbol[whatever][\dontleavehmode\rotate[rotation=180]{\getglyph{ZapfDingbats}{234}]

\symbol[whatever]

___
ntg-context mailing list
[EMAIL PROTECTED]
http://www.ntg.nl/mailman/listinfo/ntg-context


[NTG-context] ConTeXt 31 jan 2005

2005-02-01 Thread Taco Hoekwater
Hi,
There are (new (new (new))) context release note pages at the wiki,
For this:
Context 2005.01.31:
* Unicode support for Cyrillic and Greek updates
* Hebrew support
* a few bugfixes
Context 2005.01.26
* lots of extra functionality added to CtxTools (v 1.2.0 now):
  --purgefiles, --documentation, --filterpages (all from texutil
  originally); and better commandline help
* a few bugfixes
Context 2005.01.24
* TeXExec version 5.2.4 supports --pdftrim
* Per-description setting of variables
* Switch to latin modern fonts instead of cmr + various local
  versions
* Support for the qx encoding
* The base35 postscript fonts are now avialable by default
* An extension for symbols that allows fetching one symbol in a
  collection directly.
* A hook in the list setups to make use of that change
* bugfixes
Further details at the wiki:
  http://contextgarden.net/Release_Notes
Greetings, Taco
___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] undefined guillemots

2005-04-11 Thread Hans Hagen
Steve Peter wrote:
On Apr 11, 2005, at 2:37 PM, Henning Hraban Ramm wrote:
Hi there!
AFAIK this should work:
\setuplanguage[de][
  leftquote=\guilsinglleft,
  rightquote=\guilsinglright,
  leftquotation=\guillemotleft,
  rightquotation=\guillemotright
]

setuplanguage[de][
  leftquote=\guilsingleleft,
  rightquote=\guilsingleright,
  leftquotation=\leftguillemot,
  rightquotation=\rightguillemot
]
However, this brings up a more general issue (for Hans, especially). The 
symbol is called a guillemet, a diminutive of Guillaume (Le Be), the 
typographer. It has nothing to do with the French word for word, mot. :-)
we already have (in enco-def):
\ifx\greeklamda\undefined \def\greeklamda{\greeklambda} \fi
\ifx\greekLamda\undefined \def\greekLamda{\greekLambda} \fi
and i've added:
\ifx\leftguillemet \undefined \def\leftguillemet {\leftguillemot } \fi
\ifx\rightguillemet\undefined \def\rightguillemet{\rightguillemot} \fi
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] Latest version + itemize

2005-06-06 Thread Lutz Haseloff

Hi Taco, Hi all,


Taco Hoekwater schrieb:


On my system,

\definetypeface [palatino] [rm] [serif] [palatino] [default] 
[encoding=ec]
\definetypeface [palatino] [mm] [math]  [palatino] [default] 
[encoding=ec]

\setupbodyfont  [palatino, 12pt, rm]



This fails because I do not have ec-pplXXX metrics installed,


\usetypescript [lucida] [texnansi]
\setupbodyfont [lucida, 12pt, rm]



and this works because it is basically a no-op (cmsy10 is used)

So perhaps not a map file, but a typescript loading error.  Can you
check your log for the loading of type-exa?



I found an error. Texexec complains about font lbms not found.
(not cmsy)
When i add a line "lbms LucidaNewMath-Symbol < LBMS.pfb" to
texnansi-bh-lucida.map the error is gone.
Are my *.map-files out of date?


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



Thank you for your help

Greetings

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


Re: [NTG-context] Skrinking distance between bullet and text in itemize

2005-06-12 Thread Adam Lindsay
Nikolai Weibull said this at Sun, 12 Jun 2005 21:02:45 +0200:

>> \startitemize[1 (or whatever symbol you want), 2*serried]
>
>I tried that, but the problem is that when one uses inmargin, this
>doesn’t seem to work.  It seems that the interplay between width and
>distance isn’t working as I would expect.  Anyway, thanks,

If it's in the margin, then you want to vary the margindistance. Of
course, that'll interact with other items you might have in the margin.
I'm not seeing another way to do it, at the moment.

\setuplayout[margindistance=.5em]
\showframe
\startitemize[inmargin] 
\item test \item test \item test
\stopitemize

-- 
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
 Adam T. Lindsay, Computing Dept. [EMAIL PROTECTED]
 Lancaster University, InfoLab21+44(0)1524/510.514
 Lancaster, LA1 4WA, UK Fax:+44(0)1524/510.492
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] Something smells rotten in the state of luametatex...

2021-10-08 Thread Hans Hagen via ntg-context

On 10/8/2021 6:09 PM, Thomas A. Schmitz via ntg-context wrote:


Hi all,

I have a document here for one of my classes: xml processed via context, 
some layers, some two column paragraphs, a bibliography, nothing out of 
the ordinary. With mkiv, it compiles cleanly:


mkiv lua stats  > used engine: luatex version: 1.13, functionality 
level: 7420, banner: this is luatex, version 1.13.0 (tex live 2021)

mkiv lua stats  > used hash slots: 48846 of 65536 + 25
mkiv lua stats  > lua properties: engine: lua 5.3, used memory: 212 MB, 
ctx: 210 MB, max: unknown MB, hash chars: min(64,40), symbol mask: utf 
(τεχ)
mkiv lua stats  > runtime: 2.775 seconds, 119 processed pages, 119 
shipped pages, 42.883 pages/second

system  | total runtime: 5.996 seconds

When I compile the same document with luametatex, things slow down to a 
crawl:


mkiv lua stats  > used engine: luametatex version: 2.0921, functionality 
level: 20210903, format id: 594, compiler: gcc
mkiv lua stats  > tex properties: 740039 hash slots used of 2097152, 
48372 control sequences, approximate memory usage: 36 MB
mkiv lua stats  > lua properties: engine: lua 5.4, used memory: 100 MB, 
ctx: 93 MB, max: 138 MB, symbol mask: utf (τεχ)
mkiv lua stats  > runtime: 27.509 seconds, 119 processed pages, 119 
shipped pages, 4.326 pages/second

system  | total runtime: 139.458 seconds of 139.493 seconds

So, it takes more than 20 times as long... The CPU of my computer goes 
up to 100 %, and the entire machine sometimes becomes unresponsive 
during the run. Obviously, I can't provide a MWE, but this seems 
bizarre. One thing I see on my terminal: there are hundreds of lines 
like this


Overfull \hbox (0.8pt too wide) in paragraph at lines 18--18
6:17:  [glue][glue][glue][boundary][hlist][penalty][glue][hlist][penalty] >[glue][glue]


It's almost like some debug setting has been triggered. But that may be 
a red herring. Anyway, I just wanted to report this; maybe some bigger 
problem (with the binary or the format?) is lurking somewhere.
no, that's just a more verbose 'overfull box' message ... does adding 
\dontcomplain help? (After all you can live with .8pt which smells like 
2 * .4pt which is the default rule width so maybe some frame stricks out)


Hans

-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
   tel: 038 477 53 69 | www.pragma-ade.nl | 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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


[NTG-context] All Equations

2021-12-10 Thread Henning Hraban Ramm via ntg-context
Since I never used math with ConTeXt, I tried to replicate XKCD 2034 as 
an exercise (see below and attached). I’d like to put it on the wiki and 
in my book.


I know this is nonsense, but I’d like to do it right.

In some cases I’m unsure which symbol the author meant, e.g. p or \rho, 
0 or O, 1 or I or | ...

Yes, I could have used proper Unicode characters (ρ, π etc.).

Can you answer my questions (%? in the source)? (Partly TeX related, 
partly math/physics related.)



"""
\setupinteraction[state=start]

\starttext
\subject{All equations\footnote{according to 
\goto{XKCD}[url(https://xkcd.com/2034/)]}...}


... of Kinematics:
\startformula E = K_0t + \frac{1}{2}\rho vt^2 \stopformula
% ? Should it be v or \nu?

... of Number Theory:
\startformula K_\Lambda = 
\sum^\infty_{i=0}\sum^\infty_{\pi=0}(n-\pi)(i+e^{\pi-\infty})\stopformula


... of Fluid Dynamics:
\startformula \frac{\delta}{\delta_t}\nabla\cdot\rho = 
\frac{8}{23}\oiint\rho d_s 
d_t\cdot\rho\frac{\delta}{\delta_\nabla}\stopformula

% ? Would ds dt be better than d_s d_t?

... of Quantum Mechanics:
\startformula I\Psi_{x,y}>=A(\Psi)A(I\times>\oplus Iy>)\stopformula
% ? Should those be I, 1 or |, > or some angle bracket?

... of Chemistry:
\startformula CH_4 + OH + HEAT \rightarrow H_2O + CH_2 + H_2EAT\stopformula
% ? Should we something different for chem. formulae?

... of Quantum Gravity:
\startformula SU(2)U(I) \times SU(U(2))\stopformula
% It’s not even an equation...

... of Gauge Theory:
\startformula
S_g =
\frac{-I}{2\bar{\epsilon}} i \delta
\left(
\xi_{\delta_0} \mathring{+} \rho_\epsilon \rho_v^{abc}\cdot\eta_0
\right)
f_a^0 a\lambda(\rotate[rotation=180,location=high]{\xi})\Psi(O_a)
\stopformula
% ? I guess the first \delta should be crossed somehow?
% ? Is it possible to get \hat accents over the brackets? \hat{\left(} 
doesn’t work.
% ? What’s that symbol after \right) ? (f with two bars, maybe kind of 
integral?)


... of Cosmology:
\startformula h(t) + \Omega + G \cdot \Lambda ...
\startmathcases
\NC ... > 0 \TC (Hubble Model) \NR
\NC ... = 0 \TC (Flat Squere Model) \NR
\NC ... < 0 \TC (Bright Dark Matter Model) \NR
\stopmathcases
\stopformula

... of Truly Deep Physics: \startformula \hat{H} - \c{u}_0 = O\stopformula
% ? How can I get a cedilla under the u? \c{u} is wrong.

\page
\subject{Original}
\externalfigure[https://imgs.xkcd.com/comics/equations.png][width=\textwidth]
\stoptext
"""

Hraban

allformula.tex
Description: TeX document


allformula.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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


[NTG-context] Re: XML: Correct usage of hash symbol in url / new upload

2023-08-27 Thread Hans Hagen via ntg-context

Hi Denis,


I need to process URLs in XML documents differently depending on the target. 
Thanks to Hans and Thomas I can now deal with the attributes.
Now I need to prefix certain kind of targets with a certain URL (a web viewer 
for IIIF images in this particular case). The prefix contains a #, which, as a 
special character seems to cause an error. Adding a double hash seems to work, 
but those ## will end up in the link URL. How can I properly escape a single #? 
I've already tried using \Ux{23}, but that won't work either.

The duplication of hashes is kind of special. Consider this:

\def\foo#1{#1 test ##}

\def\foo#1{#1 test\def\more##1{(##1)}}

the internal representation of #1 is a reference to parameter 1 while 
the ## becomes one # (cc parameter) in the second exmaple followed by a 
character 1 (cc other)


then, when tex serializes e.g. in tracing it duplicates the hash (with 
cc parameter) so that the user is not confused (an alternative could 
have been to indicate a parameter reference differently but changing 
that now is no real option - what symbol to use anyway?)


with lua(meta)tex opening up matters this duplication becomes a bit 
annoying so i decided to see if it could be avoided in some cases


first i decided to provide an escape, possible because we already have 
such mechanism using # (not advertised because it is still experimental)


then i decided to just not duplicate unless we trace

in the lowlevel macro manual there is a section added that goes in more 
detail


to come back to the escaping: here is a list:

#I  loop iteraor
#P  parent loop iterator
#G  grandparent loop iterator

#H  hash
#S  space (ascii 32)
#T  tab \t
#L  newline \n
#R  return \r
#X  backslash

considering

#N nbsp

and some more. Keep in mind that #1-#9 #A-#E are in use as parameter 
references


but in the case of your url's escaping should not be needed (hopefully)

Hans

ps. all kind of expereimental because it's a bit hairy and we don't want 
to loose compatibility (hashes get interpreted in the macro preamble, 
macro body, running text, serialization etc)


-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
   tel: 038 477 53 69 | www.pragma-ade.nl | 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 / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


[NTG-context] How to draw this picture?

2015-01-17 Thread Rob Heusdens
I am working on an economic book, which I convert from a paper edition
into a digital edition, which contains some figures I want to recreate
using context or other tool.

In logical terms, the picture represents some economic figures and
visualizes how some figure (e.g. "National income" and the amount) is the
sum of some other figures, in which it can be split up.

In logic terms the figure then explains that:

A can be split up into B and C. B can be split up into D and E. D is F. E
can be split into G,H,I and K.

Graphically this is depicted like a table containing 4 columns and 5 rows,
and the "split into" is drawn as two diagonal lines (one right-up and
another righ down) which shows how the element on the left column is split
up into the elements on the right column using the diagonal lines that
center in the left element, drawn to the right top and right bottom
element.

I worked this out into context as a simple table, and used instead of the
diagonal lines only vertical lines. Which is less expressive, but still
visualizes the splitting sufficiently I hope.

But I would like to rework this picture, using a brace instead of a
vertical line, similar to how in a formula one uses mathcases.

I tried to use mathcases, but it seems mathcases can't be nested??

I was thinking of other solutions, like replacing the vertical line with a
small column in which to put a vertical stretched brace symbol, at the
appriopriate lowered cell, but don't know how the vertical stretch a
glyph.

What is the best way to code this in ConText? (preferred is to use the
symbol left brace.)

Greetings,

Rob

---

context code now used:

\starttable[s0|cp(.2\textwidth)|cp(.2\textwidth)|cp(.2\textwidth)|cp(.25\textwidth)|]
\NC \NC \VL Variabel\\ kapitaal\\ 10 \VL Arbeidsloon v/d\\
productie-arbeiders\\ 10 \NC \AR
\NC \NC \VL  \NC \NC \AR
\NC \NC \VL  \NC \NC \AR
\NC \VL Nationaal\\ inkomen\\ 30 \VL \VL Winst van de\\ industriële
kapitalist\\ 10 \NC \AR
\NC \VL \VL  \VL \NC \AR
\NC \VL \VL \VL Commerciële\\ winst\\ 3 \NC \AR
\NC Totaal\\ maatschappelijk\\ product\\ 90 \VL \VL Meerwaarde\\ 20 \VL 
Rente\\ 2 \NC \AR
\NC \VL \VL  \VL Grondrente\\ 5 \NC \AR
\NC \VL \NC  \NC  \NC \AR
\NC \VL Vervanging \\ v/h verbruikte \\ constante\\ kapitaal\\ 60 \NC \NC 
\NC \AR
\stoptable

___
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] Issues of Export

2015-08-21 Thread Hans Hagen

On 8/15/2015 1:20 PM, Henning Hraban Ramm wrote:

Hi, finally coming back...

Am 2015-08-10 um 23:21 schrieb Hans Hagen :


On 8/10/2015 10:30 AM, Henning Hraban Ramm wrote:

As listed on http://wiki.contextgarden.net/Export

Open Export issues as of 2014-01-20, still valid 2015-08-08
• Structure bug: Metadata ends up within the first section instead of 
in front of everything


ok, fixed for document level ... keep in mind that setting metadata always 
relates to the next element


Thanks, for me it’s good now.


• Names of metavariables are missing in div.xhtml

ok, i've added something


Works. Not that important anyway.


• Notes (footnotes): Only visual formatting, no semantical markup and 
no reference/ID

boring, so todo


Hey, I thought TeX would be about semantical markup? At the moment the markup 
for footnotes is purely graphical - a marker in the text, and the footnote 
somewhere later (where it appears on the printed page). E.g.

Bla bla1 bla bla ba ...1 This is the footnote 
text

That makes no sense and is very hard to process, even using xsl.
I would suggest to stay with the source flow instead of the output, if 
possible. E.g. markup like

Bla blaFootnote text

The id would be some internal id (I guess there is one?), the tag the footnote 
marker (as of \setupnotes).
Is that not possible and even simpler than the current version?


the code is there but its use got lost when updating something else (an 
id 'insert' that links the note and symbol)


btw, if you want them someplace else in the stream using end nodes makes 
sense



• Delimited: Quotations have tagging *and* quotation marks, even in 
raw.xml

i added symbol and content element


Less would be enough, but works this way.


• Firstpage/Lastpage is ignored in project structure

fuzzy, so todo


The keywords are defined in setup, I don’t understand where they get forgotten.


• Minimal example doesn’t create a cover at all

no beta yet


? Is this intentional, or what triggers the creation of cover.xhtml?

Greetlings, Hraban
---
http://www.fiee.net
http://wiki.contextgarden.net
https://www.cacert.org (I'm an assurer)

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




--

-
  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] integral symbol

2016-12-28 Thread Hans Hagen

On 12/28/2016 2:02 PM, Fabrice Couvreur wrote:

Hi Henri,
Thank you for your suggestion.


The problem with integrals is that they don't adapt because they are not 
wrapped as delimiters (like left/right stuff). If \int were a command 
taking an argument it would be easier. As in:



\starttext

\setupmathextensible[integral][rightoffset=-3mu,exact=yes,factor=2]

\startlines
\ruledhbox{$\integral   f\frac{1}{2}$}
\ruledhbox{$\integral[factor=1] f\frac{1}{2}$}
\ruledhbox{$\integral[factor=3] f\frac{1}{2}$}
\stoplines

\startformula
a =
\autointegral{t}{b}1 +
\autointegral{t}{b}{\frac{\frac{3}{4}}{\frac{1}{2}}} +
\autointegral{t}{b}{\frac{\frac{\frac{\frac{1}{2}}{2}}{2}}{2}}
\stopformula

\stoptext




Fabrice

2016-12-28 12:19 GMT+01:00 Henri Menke mailto:henrime...@gmail.com>>:

On 12/28/2016 11:39 AM, Fabrice Couvreur wrote:
> Hello,
> The integral symbol is little in inline math mode. Is it possible to have 
it bigger ?
> thank you,
> Fabrice
>
> \definetypeface [mainface] [rm]
>[serif] [palatino][default]   [encoding=texnansi]
>
> \definetypeface [mainface] [ss]
>[sans]  [helvetica]   [default]   [encoding=texnansi]
>
> \definetypeface [mainface] [tt]
>[mono]  [palatino][default]   [encoding=texnansi]
>
> \definetypeface [mainface] [mm]
>[math]  [palatino][default]   [encoding=texnansi]
>
> \setupbodyfont[mainface,11pt]
>
> \starttext
>
> L'aire hachurée se note \math{\int_1^3 k(x)\mathop{dx}}.

\math{\displaystyle\int_1^3 k(x)\diff x}

>
> L'aire hachurée se note :
>
> \startformula
>   \int_1^3 k(x)\mathop{dx}.
> \stopformula
>
> \stoptext
>
>
>

___
> If your question is of interest to others as well, please add an
entry to the Wiki!
>
> maillist : ntg-context@ntg.nl <mailto:ntg-context@ntg.nl> /
http://www.ntg.nl/mailman/listinfo/ntg-context
<http://www.ntg.nl/mailman/listinfo/ntg-context>
> webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
> archive  : https://bitbucket.org/phg/context-mirror/commits/
<https://bitbucket.org/phg/context-mirror/commits/>
> 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 <mailto:ntg-context@ntg.nl> /
http://www.ntg.nl/mailman/listinfo/ntg-context
<http://www.ntg.nl/mailman/listinfo/ntg-context>
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
<https://bitbucket.org/phg/context-mirror/commits/>
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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___




--

-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
   tel: 038 477 53 69 | www.pragma-ade.nl | 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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] referencing and stoppers

2018-06-30 Thread Idris Samawi Hamid ادريس سماوي حامد
On Sat, 30 Jun 2018 04:20:57 -0600, Wolfgang Schuster  
 wrote:



You can use the \setupreferencestructureprefix command set a different
value for
the stopper but you have to ensure the key takes a value because a empty
argument is ignored. Instead of the argument I used in my example
(\symbol[none])
you can also use a unicode character without width, e.g. \zerowidthspace.


\setupreferencestructureprefix [section] [default]
[prefixstopper={\symbol[none]}]
%\setupreferencestructureprefix [section] [default]
[prefixstopper=\zerowidthspace]

   1. Argument: section name -> section == \section / \startsection
   2. Argument: reference type -> default == \in
   3. Argument: settings which differ from \setuphead


Many thanks, this is exactly what was needed!

Your replies and pointers are appreciated and not taken for granted.

Best wishes
Idris


Idris Samawi Hamid ادريس سماوي حامد <mailto:idris.ha...@colostate.edu>
29. Juni 2018 um 16:22
Dear gang,

For, e.g., \setuphead[...][alternative=text], one often wants the
stopper to appear in the main text sectioning but not in the
references to those sections. For example (attached and below):

===
\setuphead[chapter]   [alternative=normal]
\setuphead[subsection][alternative=text]
\setuphead[subsection][distance=0em,
   textdistance=0.7em,
   sectionstopper=.,
   criterium=local]
\setupwhitespace[big]
\starttext

\startchapter[title={First},reference={}]
\startsubsection[title={},reference={reference1}]
\input ward

See \in{Sections}[reference3] and \in{Section}[reference4].
\stopsubsection
\startsubsection[title={},reference={reference2}]
\input ward
\stopsubsection
\stopchapter

\startchapter[title={Second}]
\startsubsection[title={},reference={reference3}]
\input ward
\stopsubsection
\startsubsection[title={},reference={reference4}]
\input ward

See \in{Sections}[reference1] and \in{Section}[reference2].
\stopsubsection
\stopchapter
\stoptext
===

See Sections 2.1. and Section 2.2..
See Sections 1.1. and Section 1.2..

SHOULD BE

See Sections 2.1 and Section 2.2.
See Sections 1.1 and Section 1.2.

Is there a straightforward way to remove the stopper from the \in
reference while maintaining it in the main sectioning but removing it
in the referencing?

If there is no straightforward way, what is the best workaround?

As mentioned at the outset, this is not an uncommon scenario. If there
is no straightforward way, would like to make it a feature request.

Thank you in advance for your help.

Idris
___
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://context.aanhet.net
archive : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___





--
Idris Samawi Hamid, Professor
Department of Philosophy
Colorado State University
Fort Collins, CO 80512
___
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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] Itemization formatting

2019-05-29 Thread Wolfgang Schuster

Taco Hoekwater schrieb am 29.05.2019 um 16:15:

Hi all,

I must be getting old :(

It used to be that I could get ConTeXt to do what I wanted, but that is 
increasingly getting harder.

Current problem: I would like to have itemizations that behave like in this 
dummy
ascii formatting:

   *   Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec dapibus 
turpis et
   nulla venenatis tincidunt. Curabitur sit amet vehicula nisi, sit amet

and so far it has been impossible for me to set up \setupitemize to do what I 
want.

In descriptive text, what I want is:

1. some global indentation to the left and/or right. That is what the margin= 
key does
2. the symbol (or number) typeset in a specific width. That is the width= key
3. some distance between the number box and the following text. That is the 
distance= key
4. on line 2 and forward to the end of the item, I want a *different* 
indentation from the first item line.

In this particular case, I want no extra indentation except for ‘margin’, but 
in other
cases I may like either more or less indentation than on line 1 of the first 
para of the item.

The desired effect is simple achieve with primitive operations, but I would 
like the input
to look nice (not to mention that I do not want to loose options for 
cross-referencing etc).

   \setupitemize[option=intext]

is nearly right for this case (with indentation equal to the left margin), so I 
assumed I would
be able to tweak that. But the problem there is that while it does 2-4, it 
ignores the extra
indentation required for nested itemizations (it even ignores explicit margin= 
settings for the
nested level). After fighting with this for hours, I am nearly ready to give up.

Anybody have any idea how to get itemizations to do what I want?

MWE attached.

Best wishes,
Taco
PS It seems that “indentnext=no” does not work for nested itemizations?


You can use the "text" option and add \par at the end of each item but 
your requirements (hanging text, different margin and before/after 
ssettings) are easier to solve with a description or enumeration.


\definesymbol
  [taco]
  [{\inframed[frame=off,width=2em,align=flushleft]{\textbullet}}]

\starttext

\samplefile{zapf}

\startitemize[text][symbol=taco]
  \item \samplefile{weisman}\par
  \startitemize
    \item \samplefile{ward}\par
  \stopitemize
\stopitemize

\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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] Converting normal font into bold

2013-11-25 Thread Khaled Hosny
On Sun, Nov 24, 2013 at 10:18:47PM +0100, "H. Özoguz" wrote:
> >It is my believe that Unicode has the wrong properties for Arabic
> >standalone Hamza; in short you should just type a regular Hamza in the
> >middle of the word and it will get positioned correctly. Placing a
> >combining Hamza over a Tatweel to “fake” it is wrong IMO. So in Amiri
> >you just type “بِءَايَٰتِ” and voilà, every thing is rendered correctly (the
> >same is true for the small Alef).
> 
> Yes, that works. But the direct way works with Uhtmanic1HafsVer9:
> 
> \definefont[arabicamiri][file:amiri-regular.ttf*arabic at 15pt]
> \definefont[arabicuth][file:UthmanicHafs1Ver09.ttf*arabic at 17pt]
> \starttext
> \setupalign[r2l]
> \arabicamiri بِـَٔايَـٰتِ
> \blank
> \arabicuth بِـَٔايَـٰتِ
> \stoptext

I consider this wrong input so it is not supported by Amiri; the Hamza
in بءايت is exactly the same Hamza in ءايت prefixed with ب, so the same
Unicode character should be used in both, and Amiri goes to a great
length to support this. Using a combing Hamza (which is a different
Hamza) over a Tatweel is just a hack to emulate the same effect that you
get “natively” with Amiri, I may support it in the future, but it is not
a priority. If you read Arabic, the Amiri manual describes the proper
Unicode sequences to input some of the Quranic marks that people get
confused about because of the messiness of this area in Unicode (I
should translate the manual to English, but time is always an issue).

> 
> To be honest, in Corel Draw UthmanicHafs is the perfect font for my purpose
> - at least in CorelDraw - e.g.: The ayat-numbers are printed as a
> unicode-symbol, not as numbers (perfect, because ConTeXt has problems with
> the direction with arabic numbers, they are mirrored in ConTeXt).
> 
> But it is only perfect in CorelDraw, in ConTeXt some things are not
> recognized correctly, as I mentioned. E.g. this one:
> 
> \definefont[arabicamiri][file:amiri-regular.ttf*arabic at 15pt]
> \definefont[arabicuth][file:UthmanicHafs1Ver09.ttf*arabic at 17pt]
> \starttext
> \setupalign[r2l]
> \arabicuth لِّلْمُتَّقِينَ ﴿٢﴾
> \stoptext
> 
> If I put the same arabic into CorelDraw, it prints a nice Unicode-Symbol for
> the number - see the JPG I have attached here, screenshot from CorelDraw,
> but ConTeXt ignores the brackets and prints just a verys small number. There
> are some problems like this. Are they easy to fix, or is this problem deeply
> involved?

This seems like a font hack, the proper way to input the Aya mark is
what Ondřej describes in his reply.

Regards,
Khaled
___
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] Two levels of itemization with the 'intext' option

2014-06-02 Thread Maggyero
Hello,

How can I get the output given by the following code with the itemize
environment?

\starttext
\quad---~Sed ut perspiciatis, unde omnis iste natus error sit voluptatem
accusantium doloremque laudantium, totam rem aperiam eaque ipsa, quae ab
illo inventore veritatis et quasi architecto beatae vitae dicta sunt,
explicabo.\par
\quad---~Sed ut perspiciatis, unde omnis iste natus error sit voluptatem
accusantium doloremque laudantium, totam rem aperiam eaque ipsa, quae ab
illo inventore veritatis et quasi architecto beatae vitae dicta sunt,
explicabo.\par
\quad\quad~---~Sed ut perspiciatis, unde omnis iste natus error sit
voluptatem accusantium doloremque laudantium, totam rem aperiam eaque ipsa,
quae ab illo inventore veritatis et quasi architecto beatae vitae dicta
sunt, explicabo.\par
\quad\quad~---~Sed ut perspiciatis, unde omnis iste natus error sit
voluptatem accusantium doloremque laudantium, totam rem aperiam eaque ipsa,
quae ab illo inventore veritatis et quasi architecto beatae vitae dicta
sunt, explicabo.\par
\quad---~Sed ut perspiciatis, unde omnis iste natus error sit voluptatem
accusantium doloremque laudantium, totam rem aperiam eaque ipsa, quae ab
illo inventore veritatis et quasi architecto beatae vitae dicta sunt,
explicabo.
\stoptext

I have tried this, but without success (it works only when there is one
level of itemization):

\definesymbol[emdashone][\quad---~]
\definesymbol[emdashtwo][\quad\quad~---~]
\setupitemize[1][packed, fit, intext][symbol=emdashone]
\setupitemize[2][packed, fit, intext][symbol=emdashtwo]
\starttext
\startitemize
\item Sed ut perspiciatis, unde omnis iste natus error sit voluptatem
accusantium doloremque laudantium, totam rem aperiam eaque ipsa, quae ab
illo inventore veritatis et quasi architecto beatae vitae dicta sunt,
explicabo.
\item Sed ut perspiciatis, unde omnis iste natus error sit voluptatem
accusantium doloremque laudantium, totam rem aperiam eaque ipsa, quae ab
illo inventore veritatis et quasi architecto beatae vitae dicta sunt,
explicabo.
\startitemize
\item Sed ut perspiciatis, unde omnis iste natus error sit
voluptatem accusantium doloremque laudantium, totam rem aperiam eaque ipsa,
quae ab illo inventore veritatis et quasi architecto beatae vitae dicta
sunt, explicabo.
\item Sed ut perspiciatis, unde omnis iste natus error sit
voluptatem accusantium doloremque laudantium, totam rem aperiam eaque ipsa,
quae ab illo inventore veritatis et quasi architecto beatae vitae dicta
sunt, explicabo.
\stopitemize
\item Sed ut perspiciatis, unde omnis iste natus error sit voluptatem
accusantium doloremque laudantium, totam rem aperiam eaque ipsa, quae ab
illo inventore veritatis et quasi architecto beatae vitae dicta sunt,
explicabo.
\stopitemize
\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
___

Re: [NTG-context] Splitting natural tables

2011-11-30 Thread Christian
> > >>>>> Hello,
> > >>>>>
> > >>>>> is it still not possible to split a table so that it covers one
> > >>>>> half page an then
> > >>>> another half page?
> > >>>>>
> > >>>>> It is my understanding that splitting moves the table to the
> > >>>>> next page and
> > >>>> then splits it to the following if it gets too long for one entire 
> > >>>> page.
> > >>>>> Would a "manual split" be possible?
> > >>>>>
> > >>>>> Examle (table is not split, but could be):
> > >>>>>
> > >>>>> \starttext
> > >>>>> \dorecurse{2}{\input knuth }
> > >>>>> \startplacetable[title={My Table}]
> > >>>>
> > >>>> \startplacetable[location=split,title={My table}] …
> > >>>> \stopplacetable
> > >>>
> > >>> Thank you Wolfgang!
> > >>> For some reason I thought the option split=yes would trigger
> > >>> splitting…
> > >>
> > >> The “split=yes” option works only for table which aren’t aren't
> > >> placed as float because this mechanism has to know that it has to
> > >> break the table into parts but then you don’t need the split key
> > >> for
> > \bTABLE.
> > >>
> > >>> Now in the sample document I get table 1a and table 1b.
> > >>> In my "real" document I get table 3.2 and table 3.3. Is there a
> > >>> way to influence this? (btw. captions are above the table, if that
> > >>> matters)
> > >>
> > >> The location of the caption doesn’t matter. The number of the
> > >> suffix for the subtables can be changed but without a example I
> > >> can’t tell why you get different results in your example and in the real
> document.
> > >
> > > My guess: It's because fo thecustom suffix. Example:
> > >
> > > \setupcaption[table][location=top]
> > > \setupcaptions[minwidth=\textwidth,width=fit,align=center,headstyle=
> > > {\
> > > ss \tfx},style={\ss \tfx
> > > \setupinterlinespace[line=1.4em]},suffix={:},distance=.5em]
> >
> > Remove the setting for “suffix” because it hold the number for the
> > subtable, the number itself can be changed with
> >
> >   \setupfloatsplitting[conversion=…]
> >
> > and a separator between the float number and the suffix can be added
> > with
> >
> >   \setupcaption[suffixseparator=…].
> >
> > To add a stopper behind the suffix a different method is needed
> > because although there is a “numberstopper” key for \setupcaption the
> > symbol is added before the suffix, what you can do is to put he symbol
> > in the label text with
> >
> >   \setuplabeltext[table={Table ,:}]
> >
> > but a extra key “suffixstopper” but we useful in this case.
> >
> > @Hans: Can you make this change in strc-flt.mkvi?
> >
> > \unexpanded\def\thecurrentfloatnumbersuffix
> >   {\doifsomething{\floatcaptionparameter\c!suffix}
> >  {\floatcaptionparameter\c!suffixseparator
> > % \floatcaptionparameter\c!suffix}}
> >   \floatcaptionparameter\c!suffix
> >   \floatcaptionparameter\c!suffixstopper}}
> >
> 
> Works like a charm :)
> Thanks, Wolfgang!

Just noticed:
In my example posted above, when I remove the suffix and add the  
\setuplabeltext[table={Table ,:}] I get the a and b. BUT:
It's Table 1.1a and 1.2b  ...so the second number is incremented, should stay 
the same, though (1.1a & 1.1b).


___
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] Symbol Footnote Command

2019-12-23 Thread Hans Hagen

On 12/23/2019 2:21 PM, Aykut Aykutt wrote:

Hi,

I can change the mark of the second footnote from "2" to asterix by 
defining a conversion like so:


%-- Working example, but it is not what I need --
\setupindenting[yes,small]
\defineconversion[mymix][1,\m{*},2]

\setupnotation[footnote][align={hz,hanging},indenting={yes,small,next},numberconversion=mymix]

\startdocument
This is the first sentence with a footnote.\footnote{This is the
first footnote and its mark is "1".}
This is the second sentence with a footnote.\footnote{This is the
second footnote and its mark is "*". }
This is the third sentence with a footnote.\footnote{This is the
third footnote and its mark is "2". }
\stopdocument

Clearly this conversion repeats the marks "1", "*" and "2" repeatedly. 
Is there a way to define a new/special footnote command (say, 
"\symfootnote") which blends with normal footnotes, but prints footnotes 
with symbol marks (say, Set 2) and not with numbers. In other words, is 
it possible to achieve the same result as the working example above with 
something like the (pseudo) example below?


%--  Pseudo example --

\setupindenting[yes,small]
\def\symfootenote ??
\setupnotation[symfootnote][align={hz,hanging},indenting={yes,small,next}]
\setupnotation[footnote][align={hz,hanging},indenting={yes,small,next}]

\startdocument
This is the first sentence with a footnote.\footnote{This is the
first footnote and its mark is "1".}
This is the second sentence with a footnote.\symfootnote{This is the
second footnote and its mark is "*". }
This is the third sentence with a footnote.\footnote{This is the
third footnote and its mark is "2". }
\stopdocument

Thank you.

\setupindenting
  [yes,small]

\defineconversion
  [mymix]
  [a,b,c]

\definenotation
  [symfootnote]
  [footnote]
  [counter=]

\setupnotation
  [footnote]
  [align={hz,hanging},
   indenting={yes,small,next}]

\setupnotation
  [symfootnote]
  [align={hz,hanging},
   indenting={yes,small,next},
   numberconversion=mymix]

\startdocument
This is the first sentence with a footnote.\footnote{This is the 
first footnote and its mark is "1".}
This is the second sentence with a footnote.\symfootnote{This is 
the second footnote and its mark is "a". }
This is the third sentence with a footnote.\footnote{This is the 
third footnote and its mark is "2". }
This is the second sentence with a footnote.\symfootnote{This is 
the fourth footnote and its mark is "b". }

\stopdocument


-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
   tel: 038 477 53 69 | www.pragma-ade.nl | 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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] Symbol Footnote Command

2019-12-23 Thread Aykut Aykutt
Thank you very much!

Hans Hagen , 23 Ara 2019 Pzt, 17:12 tarihinde şunu yazdı:

> On 12/23/2019 2:21 PM, Aykut Aykutt wrote:
> > Hi,
> >
> > I can change the mark of the second footnote from "2" to asterix by
> > defining a conversion like so:
> >
> > %-- Working example, but it is not what I need --
> > \setupindenting[yes,small]
> > \defineconversion[mymix][1,\m{*},2]
> >
>  
> \setupnotation[footnote][align={hz,hanging},indenting={yes,small,next},numberconversion=mymix]
> >
> > \startdocument
> > This is the first sentence with a footnote.\footnote{This is the
> > first footnote and its mark is "1".}
> > This is the second sentence with a footnote.\footnote{This is the
> > second footnote and its mark is "*". }
> > This is the third sentence with a footnote.\footnote{This is the
> > third footnote and its mark is "2". }
> > \stopdocument
> >
> > Clearly this conversion repeats the marks "1", "*" and "2" repeatedly.
> > Is there a way to define a new/special footnote command (say,
> > "\symfootnote") which blends with normal footnotes, but prints footnotes
> > with symbol marks (say, Set 2) and not with numbers. In other words, is
> > it possible to achieve the same result as the working example above with
> > something like the (pseudo) example below?
> >
> > %--  Pseudo example --
> >
> > \setupindenting[yes,small]
> > \def\symfootenote ??
> >
>  \setupnotation[symfootnote][align={hz,hanging},indenting={yes,small,next}]
> >
>  \setupnotation[footnote][align={hz,hanging},indenting={yes,small,next}]
> >
> > \startdocument
> > This is the first sentence with a footnote.\footnote{This is the
> > first footnote and its mark is "1".}
> > This is the second sentence with a footnote.\symfootnote{This is the
> > second footnote and its mark is "*". }
> > This is the third sentence with a footnote.\footnote{This is the
> > third footnote and its mark is "2". }
> > \stopdocument
> >
> > Thank you.
> \setupindenting
>[yes,small]
>
> \defineconversion
>[mymix]
>[a,b,c]
>
> \definenotation
>[symfootnote]
>[footnote]
>[counter=]
>
> \setupnotation
>[footnote]
>[align={hz,hanging},
> indenting={yes,small,next}]
>
> \setupnotation
>[symfootnote]
>[align={hz,hanging},
> indenting={yes,small,next},
> numberconversion=mymix]
>
> \startdocument
>  This is the first sentence with a footnote.\footnote{This is the
> first footnote and its mark is "1".}
>  This is the second sentence with a footnote.\symfootnote{This is
> the second footnote and its mark is "a". }
>  This is the third sentence with a footnote.\footnote{This is the
> third footnote and its mark is "2". }
>  This is the second sentence with a footnote.\symfootnote{This is
> the fourth footnote and its mark is "b". }
> \stopdocument
>
>
> -
>Hans Hagen | PRAGMA ADE
>Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
> tel: 038 477 53 69 | www.pragma-ade.nl | 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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] A bug in latin modern fonts?

2012-02-04 Thread Aditya Mahajan

On Sat, 4 Feb 2012, Janne Junnila wrote:


On Sun, Jan 29, 2012 at 12:42 PM, Janne Junnila  wrote:

Hi!

The following example seems to have some troubles with the latin modern fonts:

\starttext

The function $f \colon \reals \to \reals$ is given by $x \mapsto x - 3$.

\stoptext

The colon is printed fine, but the blackboard bold Rs don't look
correct. The \mapsto symbol is missing and there's a hyphen instead of
minus.

Are others having the same issue? I tried to do a fresh install, but
the problem persisted. There were some messages like

fonts           > otf loading > skipping cyclic reference U+00028 in
math variant U+00028

during compiling. I don't know if they are related to the problem.



Hi,

I would like to my previous message that also Asana-Math seems to have problems.

\setupbodyfont[asana]
\starttext

The function $f \colon \reals \to \reals$ is given by $x \mapsto x -
3$. Its derivative is
$f'(x) = 1$.

\stoptext

In the above the ' in f'(x) looks wrong and there's hyphen instead of
minus at x - 3.
The problems arise in the current standalone, the latest stable one
worked OK at least
for the latin modern fonts.


The reference implementatation for math handling is cambria. With cambria
$f'(x)$ and $\mapsto$ work fine. But $a-b$ gives text minus, and $a 
\colonequals b$ gives an error.


@Hans and Khaled: Any idea why this is happening?

\starttext
\setupbodyfont[cambria]
$a-b$ % text minus
$a \colonequals b$ % error
\stoptext

$f'(x)$ works fine with cambria and xits, but is placed low with asana. My 
guess is that this is the font's fault; with asana $f^{'}$ works fine. 
The same "bug" is also present with LMmath.


The symbol \mapsto appears to be missing from asana and lmmath. ConTeXt 
currently does not use fall backs for missing math glyphs.


Finally, $\reals$ works correctly with cambria, asana, lmmath, and xtis. 
It does not work with euler, but that is because euler is missing 
blackboard gylphs.


So, to summarize:

1. - (minus), is clearly a bug in ConTeXt.

2. \colonequals is a bug in ConTeXt's definition. We should be using the 
glyph from the font anyways and falling back only if the glyph is missing.


3. \mapsto glyph is missing from lmmath and asana. We need to fall back to 
composed glyphs.


4. \reals is working fine. The shape of the glyph in lmmath is unusual, 
but that should be a font issue rather than a context issue.


Aditya


___
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] Luatex error in latest beta (standalone)

2012-08-03 Thread Alan Bowen
Hi, Keith—

the relevant lines in strc-not.lua are:
notes.getsymbolpage = getsymbolpage
notes.getnumberpage = getnumberpage
notes.getdeltapage  = getdeltapage

function commands.notesymbolpage(tag,n) context(getsymbolpage(tag,n)) end
function commands.notenumberpage(tag,n) context(getnumberpage(tag,n)) end
function commands.notedeltapage (tag,n) context(getdeltapage (tag,n)) end

In strc-not.mkiv, the lines are:

\def\strc_notes_set_style_color_special

  {\iftrialtypesetting

  % keep

   \else\ifx\currentcolorparameter\empty


\scratchcounter\ctxcommand{notedeltapage("\currentnote",\currentnotenumber)}\relax
% todo calculate once

 \setlocationcolorspecified\scratchcounter

   \fi\fi}



\unexpanded\def\strc_notes_inject_pointer % todo calculate once


{\ifcase\ctxcommand{notedeltapage("\currentnote",\currentnotenumber)}\relax

 % unknown

   \or

 % same page

   \or

 \noteparameter\c!symbolcommand{\symbol[\v!note:\v!nextpage]}%

   \or

 \noteparameter\c!symbolcommand{\symbol[\v!note:\v!previouspage]}%

   \fi}

But I have no idea what to make of this.

Alan

On Fri, Aug 3, 2012 at 10:04 AM, Keith J. Schultz wrote:

> Hi Alan,
>
> I do not know if this helps. As I do not have the source, but I assume
> that should be notegetdeltapage.
> There are other possiblities.
>
> If that does not help. start looking for getdeltapage. Maybe, it was not
> hook in correct. at one point,
> or somebody for to use a dummy function.
>
> regards
> Keith.
>
>
> Am 03.08.2012 um 15:04 schrieb Alan Bowen :
>
> Files that used to process are now getting this error message:
>
> ! LuaTeX error
> ...TeXt/tex/texmf-context/tex/context/base/strc-not.lua:351: attempt to
> call global 'getdeltapage' (a nil value)
> stack traceback:
> ...TeXt/tex/texmf-context/tex/context/base/strc-not.lua:351: in function
> 'notedeltapage'
> :1: in main chunk.
>
> system  > tex > error on line 24 in file c_2012-01_Johnson.tex:
> LuaTeX error
> …
>
> ctxcommand ...\directlua \zerocount {commands.#1}
>
>
> \strc_notes_set_style_color_special ...tenumber )}
>   \relax
> \setlocationcolorsp...
> \strc_notes_set_style_color_inline ...lor_special
>   \fi
> \strc_notes_inject_symbol ...xtstyle \c!textcolor
>   \hbox
> \strc_notes_get_refe...
> \195>notation:note ...l \strc_notes_inject_symbol
>   \else \unskip \unskip
> \glo...
> \strc_notations_command_nop ...handler \endcsname
>
> \strc_constructions_finali...
>
> I am running ConTeXt  ver: 2012.08.02 10:55 MKIV  fmt: 2012.8.2  int:
> english/english (standalone)
>
> Is there  fix for this?
>
> Many thanks.
>
> 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
>
> ___
>
>
>
>
> ___
> 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
___

Re: [NTG-context] Halfway between itemizations and descriptions

2005-11-24 Thread Hans Hagen

Giuseppe Bilotta wrote:


Thursday, November 24, 2005 Taco Hoekwater wrote:

 


Giuseppe Bilotta wrote:
   


However, I find it really 'funny' that there are n different
methods to create items in an enumeration ... should these
be rather enumeration options, so that you can use the same
source code and just chang the stuff in \setup/\staritemize
to achieve the different effects?

This is why I was thinking of using \head, still, for
example.
 


this is a variant of taco's posted solution:

\unprotect

\def\complexdoitemgroupitem[#1]% too many historical \ignorespaces
 {\ifconditional\textlistitem
% begin of item
  \else
\par
  \fi
  \ignorespaces
  \ifconditional\concatnextitem % new, concat
\doitembreak\nobreak% new, concat
  \fi   % new, concat
  \doadvanceitem
  \ifnum\itemcolumndepth=0\relax\ifnum\noflistelements>0\relax
\doitembreak\nobreak
  \fi\fi
  \ifconditional\firstlistitem
\setfalse\firstlistitem
\begingroup
\ifcase\itemlevel
\or % 1
  \ifnum\itemcolumndepth=0\relax
\ifconditional\introlistitem\doitembreak\nobreak\fi
\getitemparameter1\c!before
\ifconditional\introlistitem\doitembreak\nobreak\fi
  \fi
\else % 2 en hoger
  \ifconditional\paragraphlistitem \else
\let\previtemlevel\itemlevel
\decrement\previtemlevel
\ifcase\autoitemgroupspacing\relax % nieuw
  \getitemparameter\itemlevel\c!before
\or
   \doifelsenothing{\getitemparameter\itemlevel\c!before}
 {\getitemparameter\itemlevel\c!before}
 {\getitemparameter\previtemlevel\c!inbetween}%
\else
  \getitemparameter\previtemlevel\c!inbetween % == itemlevel-1
\fi
  \fi
\fi
  \else
\getitemparameter\itemlevel\c!inbetween
  \fi
  \ifconditional\concatnextitem % new, concat
\vskip-\lastskip% new, concat
\vskip-\lineheight  % new, concat
\nobreak% new, concat
  \fi   % new, concat
  \ignorespaces
  \dolistitem
  \ifconditional\packlistitem
\setupwhitespace[\v!none]%
  \fi
  \getitemparameter\itemlevel\c!inner
  \marsymbol
  \let\marsymbol\relax
  \doifsomething{#1}
{\doifnot\itemreference\unknownitemreference
   {\bgroup
\protectconversion
\rawreference\s!lst{#1}\itemreference
\egroup}}%
  \strut % added 11-08-99
  \setfalse\concatnextitem % new, concat
  \hskip\itemsignal% new, concat
  \getitemparameter\itemlevel\c!command}

\def\defaultitemcommand
 {\EveryPar{\ignorespaces}%
  \ignorespaces}

\def\doinitializeitemgrouplevel#1%
 {\copyparameters
[\??op\currentitemgroup#1][\??oo]
[\c!width,\c!factor,\c!distance,\c!align,\c!option,
 \c!style,\c!marstyle,\c!symstyle,\c!headstyle,
 \c!color,\c!marcolor,\c!symcolor,\c!headcolor,
 \c!beforehead,\c!afterhead,\c!before,\c!inbetween,\c!after,
 \c!stopper,\c!placestopper,\c!indenting,
 \c!n,\c!inner,\c!symbol,\c!margin,\c!items,
 \c!leftmargin,\c!rightmargin,\c!indentnext,
 \c!command,
 \c!start,\c!lefttext,\c!righttext]}

% test this: saves hash entries and is also faster
%
% \let\doinitializeitemgrouplevel\gobbleoneargument

\def\getitemparameter#1#2%
 {\executeifdefined{\??op\currentitemgroup#1#2}%
 {\executeifdefined{\??op\currentitemgroup  #2}%
 {\executeifdefined{\??oo   #2

\setupitemgroups[\c!command=\defaultitemcommand]

\starttext

\def\MyItemCommand#1{{\bf#1}\quad}

\setupitemgroup[itemize][command=\MyItemCommand]

\startitemize
\item {test} is this okay?
\item {test} is this okay?
\item {test} is this okay?
\stopitemize

\stoptext

so, this way you can hook in a command that is executed after the symbol 
placement


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


[NTG-context] Re: Toggling the symbol for the zero-width joiner and related Unicode control characters

2023-09-22 Thread Hans Hagen via ntg-context

On 9/22/2023 6:16 AM, Hamid,Idris wrote:



-- Original Message --
 From "Hans Hagen" mailto:j.ha...@xs4all.nl>>
To "Hamid,Idris" mailto:idris.ha...@colostate.edu>>; "mailing list 
for ConTeXt users" mailto:ntg-context@ntg.nl>>
Date 9/21/2023 3:29:22 PM
Subject Re: [NTG-context] Re: Toggling the symbol for the zero-width joiner and 
related Unicode control characters
   Many thanks, Hans. The method appears to work only for nbsp, not zwj etc. 
Here is the updated MWE:

===
\startTEXpage[offset=1em]
\disabletrackers[typesetters.directions]
\disabletrackers[typesetters.zwj]
\disabletrackers[typesetters.zwnj]
\disabletrackers[typesetters.nbsp]
\definedfont[almfixed at 14pt]
ZWJ: ‌
ZWNJ: ‍
NBSP:
\stopTEXpage
===

See attached, please advise.
joiners are part of replacement etc and can come and go ... they are
characters (we could visualize them but one never knows for sure if one
sees them)

nbsp are spaces and become glue that we can trace reliable in the node list

Many thanks. Ok, here is another MWE featuring a workaround using fallbacks:

==
\definefontfallback[nosymbols] [file:lmmono10-regular] [200C,200D] [force=yes]
\starttypescript [serif] [alm] [name]
 \definefontsynonym [Serif] [ArabicLatinSerif]
\stoptypescript
\starttypescript [mono] [alm] [name]
 \definefontsynonym [Mono]  [ArabicLatinMono]
\stoptypescript
\starttypescript [serif] [alm]
 \definefontsynonym [ArabicLatinSerif] [file:almfixed] % 
[fallbacks=nosymbols]
\stoptypescript
\starttypescript [mono] [alm]
 \definefontsynonym [ArabicLatinMono] [file:almfixed] [fallbacks=nosymbols]
\stoptypescript
\starttypescript [almfixed-nosymbols]
\definetypeface [\typescriptone] [rm] [serif] [alm] [default]
\definetypeface [\typescriptone] [tt] [mono] [alm] [default]
\stoptypescript
\usetypescript[almfixed-nosymbols]
\setupbodyfont[almfixed-nosymbols,12pt]
\startTEXpage[offset=1em]
\rm
ZWJ: ‌
ZWNJ: ‍
NBSP:
\tt
ZWJ: ‌
ZWNJ: ‍
NBSP:
\stopTEXpage
==

Under \rm we get the symbols, and under \tt they are suppressed. Of course it 
doesn't matter what fallback font one uses, as long as it has no 
control-character symbols.

1. Can this approach be generalized to get what we want, viz., a way to toggle 
the symbols?


given the inconsistency in what is or is not in a font the only way out 
is to have our own visualization (consistent across fonts) and even then 
it would add some mess because we're talking of a mix of characters that 
can have gone (as part of rendering) or are not characters at all but 
spacing


so, in that case only 'verbatim' is a candidate for visualization, not 
so much typeset text



2. \enabletrackers[typesetters.nbsp] gives a colored box, which is at least 
something.. But how can we get the NBSP symbol that's alerady in the font?


it's gone by that time ... the line break mmechanism uses glue, not 
characters



3. Ideally:
a. we want all Unicode control symbols to show up in verbatim or in \typebuffer 
(as in a text editor);


only there (with some non interfering rendering i guess) and even then 
it's probably an additonal pass over the node list



b. we want all Unicode control symbols to be suppressed in final pdf output 
(for, e.g., printing).


they basically are unless some font features keeps them around which is 
out of our control



But some fonts meant for printing have symbols for Unicode control chars -- 
that poses a challenge.


so an inconsistent mess not worth wasting time on (as this is hobbyism 
only fun can be a motivational factir)



And some fonts meant for verbatim/editing do not have symbols for the control 
chars -- that also poses a challenge.  AlmFixed, of course, has them.

Most minimally decent Arabic fonts have symbols for the Unicode control chars 
as default, including Scheherazade, Amiri, Uthmanic, and Noto Naskh Arabic -- 
all free fonts.

Industry workhorses like Linotype Lotus (Arabic) also have them.


i'm not interested in those .. can't afford them for playing around
purposes .. we only look into commercial fonts if we get a dozen 
unresticted copies for context developers



Uniscribe applications like Notepad/Word allow for toggling in a WYSIWYG 
context -- can't speak for HarfBuzz -- so there is no harm in having explicit 
symbols in the font.


sure, as long as there is no rendering ... they show the input


The upshot is that, for non-Latin scripts, some toggling capability in ConTeXt 
is important to have -- even inescapable for Arabic-script piblishing.


a bit subjectiev arguing -)


Perhaps others who use Arabic-script or Indic, etc., can chime in.. Am hopeful 
that we can figure something out!

sore, but not with 'instant priority' (unless it is some project)

Hans

-
  Hans Hagen | PRAGMA ADE
  Ridderstr

Re: [NTG-context] how to insert symbols into document?

2015-04-13 Thread Csikos Bela
Otared Kavian  írta:

>> On 13 Apr 2015, at 01:29, Csikos Bela  wrote:
>> 
>> Hello context users:
>> 
>> I would like to insert symbols into my document, especially black-diamond 
>> and losenge
>> symbols. I read symbols page at contextgarden but still don't know how to do 
>> it.
>> 
>> I also tried \showsymbolset[was] etc but the symbols but I did not find 
>> these (and many
>> other symbols either) in the output pages.
>> 
>> I found that symb-imp-mis.mkiv file defines this symbol (line 49) but I 
>> don't know how to
>> make it show. Do I have to load specific symbol fonts? If yes how can I find 
>> out which font has the given symbols? 
>> 
>> What I tried so far included:
>> 
>> % begin code
>> \usesymbols[imp-mis]
>> \starttext
>> 
>> ◆
>> 
>> \blackdiamond
>> 
>> \symbol [blackdiamond]
>> % end code
>> 
>> None of these show anything.

>Hi,
>
>You can use the mathmode to access those characters, as in the following 
>example:
>
>\starttext
>This is \type{$\blacklozenge$} $\blacklozenge$
>
>This is \type{$\lozenge$} $\lozenge$
>\stoptext

Hi,

The above example works.
But if I try it with \blackdiamond, I get error and context stops:

This is the tex file:

% begin code
\starttext
This is \type{$\blackdiamond$} $\blackdiamond$

This is \type{$\diamond$} $\diamond$
\stoptext
% end code

And the compilation:

> context symbols.tex

mtx-context | run 1: luatex 
--fmt="/usr/local/context/tex/texmf-cache/luatex-cache/context/5fe67e0bfe781ce0dde776fb1556f32e/formats/luatex/cont-en"
 --jobname="symbols" 
--lua="/usr/local/context/tex/texmf-cache/luatex-cache/context/5fe67e0bfe781ce0dde776fb1556f32e/formats/luatex/cont-en.lui"
 --no-parse-first-line --c:currentrun=1 --c:fulljobname="./symbols.tex" 
--c:input="./symbols.tex" --c:kindofrun=1 --c:maxnofruns=8 "cont-yes.mkiv"
This is LuaTeX, Version beta-0.80.0 (TeX Live 2015/dev) (rev 5195)
 \write18 enabled.
(/usr/local/context/tex/texmf-context/tex/context/base/cont-yes.mkiv

ConTeXt  ver: 2014.01.03 00:40 MKIV current  fmt: 2015.3.31  int: 
english/english

system  > 'cont-new.mkiv' loaded
(/usr/local/context/tex/texmf-context/tex/context/base/cont-new.mkiv)
system  > files > jobname 'symbols', input './symbols', result 'symbols'
fonts   > latin modern fonts are not preloaded
languages   > language 'en' is active
(/symbols.tex{/usr/local/context/tex/texmf-context/fonts/map/pdftex/context/mkiv-base.map}
fonts   > preloading latin modern fonts (second stage)
fonts   > typescripts > unknown library 'loc'
{/usr/local/context/tex/texmf/fonts/map/dvips/lm/lm-math.map}{/usr/local/context/tex/texmf/fonts/map/dvips/lm/lm-rm.map}
fonts   > 'fallback modern rm 12pt' is loaded
fonts   > treatment > fixing some wrong widths
! Undefined control sequence

system  > tex > error on line 4 in file .../symbols.tex: Undefined 
control sequence ...

1
2
3 \starttext
4 >>  This is \type{$\blackdiamond$} $\blackdiamond$
5
6 This is \type{$\diamond$} $\diamond$
7 \stoptext
8
9


?
backend > xmp > using file 
'/usr/local/context/tex/texmf-context/tex/context/base/lpdf-pdx.xml'
pages   > flushing realpage 1, userpage 1
))

mkiv lua stats  > used config file: selfautoparent:/texmf/web2c/texmfcnf.lua
mkiv lua stats  > used cache path: readable: 
'/usr/local/context/tex/texmf-cache/luatex-cache/context/5fe67e0bfe781ce0dde776fb1556f32e'
 | readable+writable: 
'/tmp/luatex-cache/context/5fe67e0bfe781ce0dde776fb1556f32e'
mkiv lua stats  > resource resolver: loadtime 0.019 seconds, 1 scans with 
scantime 0.002 seconds, 5 shared scans, 14 found files, scanned paths: 
/texmf
mkiv lua stats  > stored bytecode data: 338 modules (0.450 sec), 69 tables 
(0.010 sec), 407 chunks (0.460 sec)
mkiv lua stats  > cleaned up reserved nodes: 42 nodes, 9 lists of 442
mkiv lua stats  > node memory usage: 2 glue, 2 penalty, 9 attribute, 28 
glue_spec, 3 attribute_list
mkiv lua stats  > node list callback tasks: 6 unique task lists, 6 instances 
(re)created, 45 calls
mkiv lua stats  > used backend: pdf (backend for directly generating pdf output)
mkiv lua stats  > loaded patterns: en::2, load time: 0.000
mkiv lua stats  > jobdata time: 0.000 seconds saving, 0.000 seconds loading
mkiv lua stats  > callbacks: 145 direct, 174 indirect, 319 total
mkiv lua stats  > result saved in file: symbols.pdf, compresslevel 3, 
objectcompreslevel 3
mkiv lua stats  > loaded fonts: 3 files: latinmodern-math.otf, 
lmmono12-regul

Re: [NTG-context] What do you miss in ConTeXt?

2010-02-09 Thread Peter Münster
On Tue, Feb 09 2010, Sebastien Mengin wrote:

> Thanks for the link, I failed to use it, as I have a ConTeXt/luaTeX
> versions distributed by ubuntu/jaunty, which seems to be too old. I
> should update and give it a try -- later.

Hello Sebastien,

Anyway, it was not the latest version.

In the current version of MKIV, there is no support for language-specifics,
so there is actually no support for switching back from French to another
language.


> Did you have a look at the doc I posted yesterday?

Yes. I attach a recent t-french.tex file, that supports most of frenchb.


In detail:

> 1. the 1. paragraph of each section is indented (LATEX only);

Done.


> 2. the default items in itemize environment

Done.


> 3. vertical spacing in general LATEX lists is shortened;

Done in itemize list.


> 4. footnotes are displayed "à la française".

What is this?


> 1. French hyphenation patterns are made active;

Done.


> 2. `double punctuation' (: ; ! ?) is made active

Done.


> 3. \today prints the date in French;

The command is "\date".


> 4. the caption names are translated into French (LATEX only);

Done.


> 5. the space after \dots is removed in French.

There is no space.


> 1. French quotation marks

\quotation{...}


> 2. A command \up is provided

M\high{me}


> provided for ordinals: \ier, \iere, \iers, \ieres, \ieme, \iemes

Done.


> the macro \bsc (boxed small caps) does this, e.g., Leslie~\bsc{Lamport}

\Bsc{...}


> 4. Commands \primo, \secundo, \tertio and \quarto print 1o, 2o, 3o, 4o.
> \FrenchEnumerate{6} prints 6o.

No.


> obtained via the commands \No, \Nos, \no, \nos.

No.


> 6. Two commands are provided to typeset the symbol for \degre

No.


> the TEXbook p. 134). The command \DecimalMathComma makes the comma

\enablemathpunctuation
\disablemathpunctuation


> 8. A command \nombre was provided in 1.x versions to easily format numbers

\dorecurse6{
\setdigitmode \recurselevel\relax
\recurselevel: \digits{12.345,90} \digits{12.345.000} \digits{1,23}\par}


> 9. frenchb has been designed to take advantage of the xspace package

No.


Here a test file:

\usemodule[french]
\starttext
\section{test}
\Bsc{Test} \Bsc{Test}
\startitemize
\item 1\ier\ item
\item «bla»
\item bla
\stopitemize
\quotation{bla} hello: hello; hello? hello! \date
\stoptext

Cheers, Peter

-- 
Contact information: http://pmrb.free.fr/contact/
%D \module
%D   [  file=t-french,
%Dversion=2010.02.09,
%D  title=\CONTEXT\ User Module,
%D   subtitle=For French documents,
%D author=Peter Münster,
%D   date=\currentdate,
%D  copyright={Peter Münster}]
%C This module is copyrighted by Peter Münster.
%C Please send any comments to pmrb at free.fr.
%C You can find the latest version of this module on
%C http://modules.contextgarden.net/

% This program is free software; you can redistribute it and/or
% modify it under the terms of the GNU General Public License
% as published by the Free Software Foundation; either version 2
% of the License, or (at your option) any later version.

% This program is distributed in the hope that it will be useful,
% but without any warranty; without even the implied warranty of
% merchantability or fitness for a particular purpose.  See the
% GNU General Public License for more details.

%D This module tries to do similar things as the frenchb.ldf in LaTeX:
%D \startitemize
%D \item automatic space before » and after «, :, ?, ; and ! 
%D \item changing symbol for itemize environment
%D \item itemize environment packed
%D \item first paragraph of section indented
%D \item \type{\Bsc{}} macro
%D \stopitemize

\writestatus{loading}{Typesetting French documents}
\doifnotmode{mkiv}{\writestatus{error}{needs MKIV}\wait\end}

\setcharacterspacing[frenchpunctuation]
\setupitemize[symbol=2]
\setupitemize[packed]
\setupheads[indentnext=yes]
\setupindenting[yes, medium]
\lccode`\'=`\'

\mainlanguage[fr]

\ifx \ieme  \undefined \def\ieme  {\highordinalstr{e}}   \fi
\ifx \iemes \undefined \def\iemes {\highordinalstr{es}}  \fi
\ifx \ier   \undefined \def\ier   {\highordinalstr{er}}  \fi
\ifx \iere  \undefined \def\iere  {\highordinalstr{re}}  \fi
\ifx \iers  \undefined \def\iers  {\highordinalstr{ers}} \fi
\ifx \ieres \undefined \def\ieres {\highordinalstr{res}} \fi

\def\Bsc#1{\dontleavehmode\hbox{\sc#1}}

\doifnotmode{demo}{\endinput}

%D Usage example:
\def\myItems{%
  \startitemize
  \item test
  \item test
\startitemize
\item test
\item test
  \startitemize
  \item test
  \item test
  \stopitemize
\stopitemize
  \stopitemize}

\usemodule[french]

\starttext
Voilà: Voilà? Voilà! Voilà;
{\en some english text: «English» or \quotation{French}, ok?}
«voilà» \quote{voilà} \quotation{voilà}
\myItems
\en
\myItems
\stoptext
___
If your questio

Re: [NTG-context] cv templates

2007-09-14 Thread Bert Trüger
Hi frantisek,

this Context-CV-Example was send over this mailing list a year or so ago..

Kind regards,

Chris





%% Ein Context-Skript als Vorlage für einen Lebenslauf

%D \module

\setuppapersize[letter][letter]

\setuplayout[backspace=1.5in,width=5.5in,margin=2.5em]

\setuppagenumbering[location=footer]

\setupinmargin[align=right]

\setupitemize[1][paragraph,atmargin,unpacked][symbol=n,indentnext=no,]
\setupitemize[2][symbol=a][indentnext=no]
%\setupitemize[3][symbol=a][indentnext=no]

\definehead[CVHEAD][subject]
\setuphead[subject][style=\bfa,after={\blank[medium]}]

\definehead[SUBCVHEAD][subsubject]
\setuphead[subsubject][style=\bf,after={\blank[small]},before={\blank[small]}]

\defineparagraphs[ContactColumns][n=2]
\setupparagraphs[ContactColumns][each][rule=off,distance=0pt]

\define[2]\CVTITLE{\midaligned{\framed[frame=off,align=middle]
{{\bfa
#1}\blank[medium]{\tfb#2}}}\blank[small]}

\define[1]\CVEMAIL{{\bf Email:}{ \type{#1}}\blank}

% \framed is good for testing or fine-tuning \CONTACT
\define[2]\CONTACT{%\framed[frame=off,width=broad,align=right,strut=no,
 %offset=none,height=fit]
 %{%
\startalignment[middle]
\startContactColumns
 {\bf Office:}\crlf
 {#1}
 \ContactColumns
 {\bf Home:}\crlf
 {#2}
\stopContactColumns
\stopalignment}
%}

% \framed is used to prevent pagebreaks within an \<>ITEM<>

\define[5]\EDUITEM{\framed[frame=off,align=right,width=broad]
 {{\bf #1}\inmargin{\it #2}\ (#3).\crlf
 {\bf #4}, #5.\blank[small]}}
\define[6]\EDUITEMMA{\framed[frame=off,align=right,width=broad]
 {{\bf #1}\inmargin{\it #2}\ (#3).\crlf
 {\bf #4}, #5.\crlf
 {\bf Thesis:} {\em #6}.
 \blank[small]}}
\define[7]\EDUITEMPHD{\framed[frame=off,align=right,width=broad]
 {{\bf #1}\inmargin{\it #2}\ (#3).\crlf
 {\bf #4}, #5.\crlf
 {\bf Dissertation:} {\em #6}.\crlf
 {\bf Advisor:} #7.
 \blank[small]}}

\define[4]\ACADITEM{\framed[frame=off,align=right,width=broad]
 {{\bf Location:}\inmargin{\it #1}\ #2.\crlf
 {\bf Position:} #3.\crlf
 {\bf Responsibilities:} #4.
 \blank[small]}}

\define[2]\GRANTITEM{\framed[frame=off,align=right,width=broad]
 {\inmargin{\it #1} #2.}}

\setupbodyfont[11pt] % 11pt seems pretty standard for cv's

\endinput
=

===cv-resume.tex=
\usemodule[resume]

\starttext

\CVTITLE{Curriculum Vitae}{Idris Samawi Hamid}

\CONTACT{Department of \TeX\ Studies\crlf
  % 221 Eddy Hall\crlf
  \TeX\ State University\crlf
  Fort Collins, CO 80523 \crlf USA\crlf
  (970) 491-2406/6315
 }
 {1234 \TeX\ Road\crlf
  \TeX{}ville, CO 80555 \crlf USA\crlf
  (800) TEX-\crlf}

[EMAIL PROTECTED]

\CVHEAD{Education}

\EDUITEMPHD
 {PhD}
 {2007}
 {\TeX\ Studies}
 {\TeX\ University}
 {Amherst, NY}
 {Arabic Critical Editions}
 {\TeX\ Distinguished Professor Hans Hagen}

\EDUITEMMA
 {MA}
 {1996}
 {Physics}
 {University at Buffalo, State University of New York}
 {Amherst, NY}
 {G\"{o}del's Universe, the Mach Principle, and the Cosmological
Principle:
 Considerations for the Philosophy of Physics}

\EDUITEM{BSc}{1990}{Physics; minor, Mathematics}{Georgia State
University}{Atlanta, GA}


%% positions
% academic positions
\CVHEAD{Academic Positions}

\ACADITEM
 {2001--2007}
 {\TeX\ State University, \TeX{}ville, CO}
 {Associate Professor}
 {Instruction and research, especially
 the development of upper-level courses in \TeX\ and \Context}

\CVHEAD{Areas of Specialization}

Metaphysics of \TeX, Islamic Philosophy, Philosophy of Mysticism,
Philosophy of Science.

\CVHEAD{Philosophic Interests}

\TeX\ Logic, Category Theory, Chinese Philosophy.

% other skills

\CVHEAD{Languages and Technical Skills}

Arabic, French, and the professional computer typesetting language
\TeX, including the major dialects \LaTeX, \Context, as well as
the minor dialects Arab\TeX (for typesetting in Arabic script) and
EDMAC (for critical edition typesetting). I am also developing a
new Arabic-script system for scholarly typesetting, {\sc Oriental
\TeX}, based upon \TeX\ and \Context.

% patents

\CVHEAD{Publications}

\SUBCVHEAD{Books Authored}

\startitemize

\item Idris Samawi Hamid, 2006, {\it The Cosmology of \TeX}, \TeX\
University Press, 240 pp.

\stopitemize

\SUBCVHEAD{Articles}

\startitemize

\item Idris Samawi Hamid,  2

Re: [NTG-context] How to align numerals in lists on the dot or paranthesis that follows the numeral?

2007-06-24 Thread Wolfgang Schuster
On Sat, 23 Jun 2007 23:13:22 -0400
"Hamid Kamrani" <[EMAIL PROTECTED]> wrote:

> At least in the U.S., it is the rule and a strict requirement to
> typeset vertical lists in such a way that the numerals align on the
> dot or parenthesis following the numeral.
> 
> (even the daily violation of the rule by some of the most widely used
> word processors such as MS Word has not changed this old-aged
> convention.)
> 
> I feel it must be possible in ConTeXt to do this because it is such a
> basic requirement and ConTeXt is used professionally. However, it's
> not the default behavior and I don't know which options will achieve
> it.
> 
> (And if by any chance, this is not yet possible in ConTeXt, can anyone
> suggest a workaround for this, in ConTeXt of course.
> 
> It is the default behavior in both LaTeX and eplain.

Hi Hamid,

I corrected my last patch and integrated a itemalign key. You can test
it with the following example.

\input core-itm-patch

\starttext

\startframedtext[width=\textwidth]
\startitemize[n][style=bold]
\item As a college student, how do you rate yourself?
  \startitemize[5,columns,two]
  \item Excellent student
  \item Good student
  \item Mediocre student
  \item Poor student
  \stopitemize
\stopitemize
\stopframedtext

\startitemize[n][style=bold]
\item As a college student, how do you rate yourself?
  \startitemize[5, columns, two]
  \item Excellent student
  \item Good student
  \item Mediocre student
  \item Poor student
  \stopitemize
\stopitemize

\startitemize[n,packed,broad][itemalign=left]
\dorecurse{10}{\item Item \recurselevel.}
\stopitemize

\startitemize[n,packed,broad]
\dorecurse{10}{\item Item \recurselevel.}
\stopitemize

\stoptext

Wolfgang
\unprotect

\def\c!itemalign{itemalign}

\def\doinitializeitemgrouplevel#1%
  {\copyparameters
 [\??op\currentitemgroup#1][\??oo]
 [\c!width,\c!factor,\c!distance,\c!align,\c!option,
  \c!style,\c!marstyle,\c!symstyle,\c!headstyle,
  \c!color,\c!marcolor,\c!symcolor,\c!headcolor,
  \c!beforehead,\c!afterhead,\c!before,\c!inbetween,\c!after,
  \c!stopper,\c!placestopper,\c!indenting,
  \c!n,\c!inner,\c!symbol,\c!margin,\c!items,
  \c!leftmargin,\c!rightmargin,\c!indentnext,
  \c!command,\c!itemalign,
  \c!start,\c!lefttext,\c!righttext]}

\def\redostartitemgroup[#1][#2]%
  {\setfalse\inlinelistitem % new, no indent (leftskip)
   \setfalse\concatnextitem % new, concat
   \setfalse\txtlistitem
   \ifhmode
 \ifconditional\autoconcatnextitem % new, concat
   \ifdim\lastskip=\itemsignal % new, concat
 \settrue\concatnextitem   % new, concat
   \fi % new, concat
 \fi   % new, concat
 \ifconditional\textlistitem\else\doifnotinset\v!text{#1}\par\fi % suboptimal
   \fi
   \begingroup
% new where, ok or not / we should integrate random, intro, continue here
\setfalse\reverselistitem
\setfalse\introlistitem
\setfalse\autointrolistitem
\setfalse\beforelistitem
\setfalse\afterlistitem
\setfalse\nowhitelistitem
\setfalse\randomizeitems
%
   \doifinsetelse\v!intro   {#1}{\settrue\introlistitem}{\setfalse\introlistitem}%
   \doifinsetelse\v!random  {#1}{\settrue\randomizeitems   }{\setfalse\randomizeitems   }%
   \doifinsetelse\v!continue{#1}{\settrue\continuelistitems}{\setfalse\continuelistitems}%
   % == \doifinsetelse\v!intro{#1}\settrue\setfalse\introlistitem
   \doglobal\increment\noflists
   \let\currentlist\noflists
   \newcounter\noflistelements
   \setfalse\headlistitem
   \setfalse\sublistitem
   \setfalse\symbollistitem
   \let\marsymbol\relax
   \globallet\somdestination\empty
   \let\symsymbol\empty
   \the\itemgroupcommands
\checkcurrentnofitems
   % \getitemparameter\itemlevel\empty
   \let\listitem\empty % ** start value
   \doifelsenothing{#1} % iffirstargument
 {\edef\@@opsymbol{\getitemparameter\itemlevel\c!symbol}%
  \letgvalueempty{\@@globalitemsymbol\itemlevel}%
  \global\letitemparameter\itemlevel\v!continue\empty
% \setitemmark\@@opsymbol % ** default value
  \dosetupitemgroupvariable[\itemlevel][#2]}
 {\dosetupitemgroupconstant[\itemlevel][#1]%
  \dosetupitemgroupvariable[\itemlevel][#2]%
  \doifinsetelse\v!continue{#1}% \noexpand, else problems in non-etex with chinese
{\edef\@@opsymbol{\noexpand\getvalue{\@@globalitemsymbol\itemlevel}}%
 \getitemparameter\itemlevel\v!continue}
{\edef\@@opsymbol{\noexpand\getitemparameter{\itemlevel}{\c!symbol}}%
 \global\setitemparameter\itemlevel\v!continue
   {\dosetupitemgroupconstant[\itemlevel][#1]%
\dosetupitemgroupvariable[\itemlevel][#2]}}%
  \def\docommand##1% \setitemmark resets \docommand
{\doifnot{##1}{0}{\setitemmark{##1}}}%
% \processcommalist[#1,\@@opsymbol]\docommand
  \processcommalist[#1]\docommand}% ** preset sequence or provided seq

Re: [NTG-context] \prime is too high

2021-05-10 Thread Otared Kavian
Hi Jairo,

Indeed \prime seems a littl ebit too high, but using the apostrophe sign for 
derivation gives the expected result:


\starttext
$s''$ or $s’$ is fine but not $s^{\prime}$.
\stoptext

(Using LMTX version 2021.05.09 17:14).

Best regards: Otared


> On 9 May 2021, at 02:46, Jairo A. del Rio  wrote:
> 
> The following:
> 
> \starttext
> $s''$ %or $s^{\prime}$
> \stoptext
> 
> gives a too high symbol in ConTeXt LMTX 2021.05.06 23:35. ConTeXt MkIV isn't 
> affected for such an issue.
> 
> Jairo
> ___
> 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://context.aanhet.net
> archive  : https://bitbucket.org/phg/context-mirror/commits/
> 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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] mathcolor attribute in MathML (mkiv)

2021-05-27 Thread Duncan Hothersall
Apologies Hans.

MWE:

\usemodule[newmml]
\starttext
\xmlprocessdata{}{
 
  E
  
π
  
 
}{}
\stoptext

The π symbol does not show in red.

Duncan


On Thu, 27 May 2021 at 17:18, Hans Hagen  wrote:

> On 5/27/2021 5:47 PM, Duncan Hothersall wrote:
> > Hello list.
> >
> > I'm trying to use colour in some MathML formulae using the mathcolor
> > attribute. It seems to have no effect on the output. I can
> > see \applymmlmathcolor in the x-mathml.mkiv source but I can't see how
> > to make it work. Does anyone have any pointers?
> >
> > (Does lmtx support this?)
> MWE needed
>
> -
>Hans Hagen | PRAGMA ADE
>Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
> tel: 038 477 53 69 | www.pragma-ade.nl | 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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] All Equations

2021-12-10 Thread Wolfgang Schuster via ntg-context

Henning Hraban Ramm via ntg-context schrieb am 10.12.2021 um 17:59:
Since I never used math with ConTeXt, I tried to replicate XKCD 2034 
as an exercise (see below and attached). I’d like to put it on the 
wiki and in my book.


I know this is nonsense, but I’d like to do it right.

In some cases I’m unsure which symbol the author meant, e.g. p or 
\rho, 0 or O, 1 or I or | ...

Yes, I could have used proper Unicode characters (ρ, π etc.).

Can you answer my questions (%? in the source)? (Partly TeX related, 
partly math/physics related.)


https://www.explainxkcd.com/wiki/index.php/2034:_Equations

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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] \nolimits no effect in LMTX

2022-08-16 Thread Stefan Haller via ntg-context
On Tue, Aug 16, 2022 at 05:47:06PM +0200, Hans Hagen via ntg-context wrote:
> \definemathoperator[nosum][sum][method=nolimits]
> 
> \startformula
>   \sum [method=nolimits]_{i=1}^{n} a_i +
>   \sum _{i=1}^{n} a_i +
>   \sum [bottom={n},top={i=1},topcolor=red] a_i +
>   \nosum _{i=1}^{n} a_i
>   \nosum[method=auto] _{i=1}^{n} a_i
> \stopformula
> 
> \stoptext

Thanks for the response and also for your efforts creating and
maintaining ConTeXt! The proposed alternative work well. This also
solves the confusion due to never being able to to remember that I have to
put the \limits / \nolimits directive *after* the symbol I want to
modify.

If somebody else stumbled across this: The code for the *mathoperators
macros sits in `mkxl/math-lop.mkxl`.

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

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] problem with Segoe Ui Symbol as fallback font

2023-01-04 Thread Hans Hagen via ntg-context

On 1/4/2023 2:29 PM, Jacob Kauffmann via ntg-context wrote:
The problem is that now that \bf, \it and so on stopped working outside 
math mode.

A workaround is to add \rm after \starttext.

Maybe the developers can shed some light :)

\definefontfeature[mathextra][moderntocalligraphic=yes]

you can peek inti pagella-math.lfg and common-math.lfg

fallbacks in math are sort of gone in lmtx as it's only asking for 
troubles but we can overlay from other fonts in lfg files


Hans


-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
   tel: 038 477 53 69 | www.pragma-ade.nl | 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 / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


[NTG-context] Re: old style factorial symbol and theorems

2023-12-27 Thread Mikael Sundqvist
Hi!

Not by computer, and I'm sure Hans (or Wolfgang) has already shown a way to
do the old factorial with the actuarian mechanism when I'm back to the
computer...

/Mikael

Den ons 27 dec. 2023 13:49Shiv Shankar Dayal 
skrev:

>
>
> A simple alternative to tikz is the usage of \framed.
>>
>> \define[1]\oldfact
>>   {\inmframed[frame=off,strut=no,leftframe=on,bottomframe=on]{#1}}
>>
>> \starttext
>>
>> \m{\oldfact{n}}
>>
>> \stoptext
>>
>> Wolfgang
>>
>> Thanks a lot. It should work nicely.
>
> --
> Respect,
> Shiv Shankar Dayal
>
> ___
> If your question is of interest to others as well, please add an entry to
> the Wiki!
>
> maillist : ntg-context@ntg.nl /
> https://mailman.ntg.nl/mailman3/lists/ntg-context.ntg.nl
> webpage  : https://www.pragma-ade.nl / https://context.aanhet.net (mirror)
> archive  : https://github.com/contextgarden/context
> wiki : https://wiki.contextgarden.net
>
> ___
>
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / 
https://mailman.ntg.nl/mailman3/lists/ntg-context.ntg.nl
webpage  : https://www.pragma-ade.nl / https://context.aanhet.net (mirror)
archive  : https://github.com/contextgarden/context
wiki : https://wiki.contextgarden.net
___


[NTG-context] Re: FreeBSD 13.2

2024-02-24 Thread Mojca Miklavec
Dear Roger,

On Sat, 24 Feb 2024 at 15:34, Roger Mason wrote:
>
> After unpacking, running the install scripts results in:
>
> ld-elf.so.1: /home/rmason/Software/Context/bin/mtxrun: Undefined symbol
> "__libc_start1@FBSD_1.7"
>
> I assume this is because mtxrun is compiled for FreeBSD 14.0.

There were some troubles with our infrastructure which led Hans to
build the binaries himself without paying extra attention to
compatibility with older systems.

You can find the binaries here:
https://build.contextgarden.net/dl/luametatex/

but I hope that Hans will rebuild the installer in order to make the
older systems functional again.

Other than that, building luametatex is relatively straightforward with CMake.
The sources can be found either inside ConTeXt or separately inside
https://github.com/contextgarden/luametatex

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

maillist : ntg-context@ntg.nl / 
https://mailman.ntg.nl/mailman3/lists/ntg-context.ntg.nl
webpage  : https://www.pragma-ade.nl / https://context.aanhet.net (mirror)
archive  : https://github.com/contextgarden/context
wiki : https://wiki.contextgarden.net
___


[NTG-context] Scale content to height of the font, measure font height

2024-06-10 Thread Gerion Entrup
Hi,

I'd like to scale something (actually a symbol drawn in TikZ) to the exact 
high of the char 'M'. I found the scale environment for it but struggle to 
measure the correct font height. I found the "definemeasure/measure/measured" 
commands but they define a dimension and are not for doing measurements on 
rendered text. Is there a simple way to get the height a char as a dimension?

MWE:
```
\starttext
% Is it possible to replace 1cm with a common expression?
This is the letter M. \scale[height=1cm]{a} should have the exact same size as 
M.

This should also be true {\tfc with a bigger M. \scale[height=1cm]{a}}.
\stoptext
```

Best
Gerion



signature.asc
Description: This is a digitally signed message part.
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / 
https://mailman.ntg.nl/mailman3/lists/ntg-context.ntg.nl
webpage  : https://www.pragma-ade.nl / https://context.aanhet.net (mirror)
archive  : https://github.com/contextgarden/context
wiki : https://wiki.contextgarden.net
___


[NTG-context] Re: Arranging bullets within tabulate and itemize

2024-06-19 Thread Wolfgang Schuster

Lukas via ntg-context schrieb am 19.06.2024 um 17:19:

Hello,

here is a simple code:


[...]

I cannot find out how to arrange the tabulate bullets straight above 
those of itemize, so how to supress the left indeting, to get:


Foo
• Aaa Aa
• Bbb Bb

Foo
• Ttt
Tt
• Uuu
Uu

How do I achieve this?


You have to set the width for the item symbol/counter to 0pt to get rid 
of the space before the table.


 begin example
\showframe[text][text]

\starttext

\startitemize
\starttabulate[|||]
\NI First item  \NC\NR
\NI Second item \NC\NR
\stoptabulate
\stopitemize

\startitemize[width=0pt]
\starttabulate[|||]
\NI First item  \NC\NR
\NI Second item \NC\NR
\stoptabulate
\stopitemize

\stoptext
 end example

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

maillist : ntg-context@ntg.nl / 
https://mailman.ntg.nl/mailman3/lists/ntg-context.ntg.nl
webpage  : https://www.pragma-ade.nl / https://context.aanhet.net (mirror)
archive  : https://github.com/contextgarden/context
wiki : https://wiki.contextgarden.net
___


Re: [NTG-context] siunitx feature in unit module

2015-03-03 Thread Hans Hagen

On 3/3/2015 6:47 PM, Andrea De Michele wrote:

Romain Diss  writes:


Hi,


with siunitx LaTeX package its possible to obtain physics units like m/s
printed in different way changing one option:
e.g.
\si{\metre\per\second} produce ms^{-1}

\unit{10 meter inverse second}


Thank you.



\si[per-mode=symbol]{\metre\per\second} produce m/s

\unit{10 meter per second}


\si[per-mode=fraction]{\metre\per\second} produce \frac{m}{s}

I think it is not possible with \unit{}


Do you know if there is the project to implement this feature?


currently not on the agenda

-
  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] Change the dots of the macro \periods[n]

2015-03-06 Thread Wolfgang Schuster

> Am 06.03.2015 um 20:02 schrieb Hans Hagen :
> 
> On 3/6/2015 6:42 PM, Fabrice Couvreur wrote:
>> 
>> Hi,
>> Is it possible to change the shape of the dots of macro \periods[n] to
>> be like the dots of macro \definefiller[dots][left=\dontleavehmode,
>> right=\hskip\ZeroPoint\par] ?
> 
> % in cont-new.mkiv :
> 
> \unprotect
> 
> \def\periodsymbol  {.}
> 
> \unexpanded\def\enco_periods[#1]%
>  {\dontleavehmode
>   \hbox\bgroup
>   \enco_periods_indeed[#1,\periodsymbol,]}
> 
> \unexpanded\def\enco_periods_indeed[#1,#2,#3]%
>  {\setbox\scratchbox\hbox to \periodswidth{\hss#2\hss}%
>   \dorecurse{\iffirstargument#1\else\periodsdefault\fi}{\copy\scratchbox}%
>   \egroup}
> 
> \protect
> 
> test:
> 
> \starttext
>\startlines
>x\periods x
>x\periods[10]x
>x\periods[10,{,}]x
>x\periods[10,{!}]x
>\stoplines
> \stoptext

Why the weird syntax, something like \periods[n=10,symbol=!] would fit better.

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] tex error in curent beta

2015-10-15 Thread Jan Tosovsky
Hi Wolfgang, thanks,

On 2015-10-15 Wolfgang Schuster wrote:
> On 2015-10-15 Jan Tosovsky wrote:
> >
> > I am getting tex error > tex error on line 22 in file D:/source.tex: !
> > Missing { inserted
> >
> > 
> > \edef
> > \currentlistsymbol ->\edef
> > \p_symbol {\listparameter \c!symbol
> > }\doifelseins...
> > \14>:113>:abc ...numbercommand \currentlistsymbol
> 
>
> What I can take from the error message is that you have a problem with
> the list mechanism.

you are right, I've created this MWE (but not sure if it still makes sense).


\setupcombinedlist[chapter][
   before=,
   distance=0.5cm,
   width=-0.5cm,
   margin=2cm,   
   numbercommand={\simplealignedbox{\listparameter{width}}{flushright}},
   pageconversionset=pagenumber,
]

\starttext
\startfrontmatter
\title{TOC}
\placecontent
\chapter{Preface}
\stopfrontmatter
\stoptext

That list definition creates right aligned roman chapter numbers in the ToC,
see
http://www.ntg.nl/pipermail/ntg-context/2013/076154.html

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] Smaller bullet points

2015-11-29 Thread Hans Hagen

On 11/29/2015 5:55 PM, Kate F wrote:

Hi,

I'm defining a slightly smaller bullet point symbol:

  \definesymbol[smallbullet][\small\bullet]
  \setupitemize[1][smallbullet]

This aligns the smaller bullet point to the baseline of text, which is
too low. I'd like to have it vertically centered, such that it aligns
in the middle of where the regular-sized \bullet would be. I tried
using \inframed[height=\lineheight], but I couldn't find a way to make
that end up in the right place.


\definesymbol
  [smallbullet]
  [\raise.1ex\hbox{\mathematics{\scriptstyle\bullet}}]

-
  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] Smaller bullet points

2015-11-29 Thread Kate F
On 29 November 2015 at 17:51, Hans Hagen  wrote:
> On 11/29/2015 5:55 PM, Kate F wrote:
>>
>> Hi,
>>
>> I'm defining a slightly smaller bullet point symbol:
>>
>>   \definesymbol[smallbullet][\small\bullet]
>>   \setupitemize[1][smallbullet]
>>
>> This aligns the smaller bullet point to the baseline of text, which is
>> too low. I'd like to have it vertically centered, such that it aligns
>> in the middle of where the regular-sized \bullet would be. I tried
>> using \inframed[height=\lineheight], but I couldn't find a way to make
>> that end up in the right place.
>
>
> \definesymbol
>   [smallbullet]
>   [\raise.1ex\hbox{\mathematics{\scriptstyle\bullet}}]
>

Thanks! Where does the .1ex come from? Is that value derived from some
measurement, or does it just look about right?

-- 
Kate
___
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] Deprecated $…$ for inline math?

2016-02-17 Thread Pablo Rodriguez
On 02/17/2016 11:18 PM, Alan BRASLAU wrote:
> On Wed, 17 Feb 2016 20:08:31 +0100 Hans Hagen wrote:
> 
>> you're an american citizen who likes $x^2$ but to call if
>> beautiful ... €x^2€ nor £x^2£ (in 8 bit encodings / local keyboards
>> times) all look bad ... 
> 
> Hans, you forgot: ¥x^2¥, ₽x^2₽, ₱x^2₱, ₹x^2₹, ...
> Besides, U+0024 comes from ASCII and all programmers know that it is a
> perfectly valid and useful character. 

Of course, and even ₧x²₧ or even ₯x²₯...

>> we need a proper begin/end symbol .. 
> 
> Too bad Knuth did not choose ¡x^2! 

Excuse me, Alan, this is exclamation in Spanish (and only in Spanish).

Just out of curiosity, why do you think he should have chosen that?

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] Help with t-vim module and math

2016-04-13 Thread Hans Hagen

On 4/13/2016 11:19 AM, Nicola wrote:

Hi,
I am using the Vim module to typeset code, and I've found a situation
where I'd like to use some math symbols, but not in comments. I am not sure
whether it can be done. This is what I have tried:

\usemodule[vim]
\definefontfamily[slidesfont][mono][Latin Modern Mono Light]
\definefallbackfamily[slidesfont][mono][Xits][range={"0222A}]
\definevimtyping[pascal][syntax=pascal]
\starttext
\startpascal
X := Y ∪ Z;
\stoppascal
\stoptext

The ∪ symbol does not appear in the output. Am I completely off-track?


use dejavu mono instead of lm mono


-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
  tel: 038 477 53 69 | 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] Help with t-vim module and math

2016-04-13 Thread Nicola

On 2016-04-13 12:47:56 +, Wolfgang Schuster said:

Nicola 13. April 2016 um 14:17 
On 2016-04-13 11:53:51 +, Hans Hagen said: 



Thanks, that works. Unfortunately, DejaVu Sans Mono looks too heavy in 
my document: 
is there a light variant? 

Also, can't the fallback mechanism be used? 
Yes it can but you have to enable your custom typeface with 
\setupbodyfont which

wasn’t done in your example.


You're right, but I have done it in my original document.
Even with that, the fallback symbol does not show up:

\usemodule[vim]
\definefontfamily[slidesfont][mono][Latin Modern Mono Light]
\definefallbackfamily[slidesfont][mono][DejaVu Sans Mono][range={"0222A}]
\definevimtyping[pascal][syntax=pascal]
\setupbodyfont[slidesfont]
\starttext
\startpascal
X := Y ∪ Z;
\stoppascal
\stoptext

Nicola___
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] Latin setupmathematics

2016-06-17 Thread Hans Åberg

> On 17 Jun 2016, at 06:20, Alan BRASLAU  wrote:
> 
> On Fri, 17 Jun 2016 01:02:48 +0200
> Hans Åberg  wrote:
> 
>> The idea is avoiding clashes between variables and constants, like
>> this:
>> 
>> \starttext
>> 
>> \setupmathematics[default=normal]
>> 
>> $𝑒 = ∑_{𝑖=1}^∞ e^{i-𝑖}$
>> 
>> \setupmathematics[default=italic]
>> 
>> $𝑒 = ∑_{𝑖=1}^∞ e^{i-𝑖}$
> 
> Very, very poor mathematical style...
> 
> If you really want to use a variable "e", this would call for the use
> of the function \exp() to be readable.

Unicode has added characters to enable such writing. Also, \exp is already 
defined to “exp”, for example for the exponential map in differential geometry:
\startformula
  \exp_x: M_x → M
\stopformula

Here, the “:” expands in original TeX as a ratio operator, but Unicode has a 
special symbol for that, ∶ RATIO U+2236.


___
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] MKIV caption separator, revisited

2016-10-10 Thread Wolfgang Schuster

Wolfgang Schuster <mailto:schuster.wolfg...@gmail.com>
10. Oktober 2016 um 10:39
prefixconnector is the separator between the section number (=prefix) 
and the float number (=figure number), the symbol at the end of the 
float number is called numberstopper. In your example you don’t have a 
section which can act as prefix number no did you change which 
prefixes should be shown (by default only chapters are used as prefix).


The suffix key you use (together with suffixconnector and 
suffixstopper) is used to show the number for subfigures, e.g. figure 3.a.

Here is a working example for the use of the prefixconnector key.

\starttext

\section{This is a section}

\setupcaptions[prefixsegments=section,prefixconnector=-]

\startplacefigure[title=\tex{setupcaptions[prefixconnector=-]}]
\externalfigure[dummy][width=.5\textwidth]
\stopplacefigure

\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] "\" in text from "\comment"

2016-12-21 Thread Pablo Rodriguez
Dear Hans,

I’m afraid I might have hit a bug (with beta from 2016.12.21 18:51):

\startbuffer[demo]

pandoc
\ConTeXt\ is great

\stopbuffer

\startxmlsetups xml:initialize
 %~ \xmlsetsetup{#1}{doc|p|pre|code}{xml:*}
 \xmlsetsetup{#1}{doc|p|code}{xml:*}
 \xmlsetsetup{#1}{pre/code}{xml:pre:code}
\stopxmlsetups

\xmlregistersetup{xml:initialize}

\startxmlsetups xml:doc
 \xmlflush{#1}
\stopxmlsetups

\startxmlsetups xml:pre:code
\comment[symbol=Key, location=inmargin,
 color=yellow]{\xmlflush{#1}}\xmlprettyprint{#1}{tex}
\stopxmlsetups

\setuppapersize[A6]
\setupinteraction[state=start]

\starttext
 \xmlprocessbuffer{main}{demo}{}
\stoptext

Text from comment reads "\Ux {5C}ConTeXt\Ux {5C} is great". It should
read "\ConTeXt\ is great".

Am I missing something or is this a real bug?

Many thanks 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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

[NTG-context] nested itemgroups sometimes not working

2017-02-01 Thread Lawrence Bell
I'm having some difficulties with nested itemgroups. I've produced a
minimal working example as follows.

\defineitemgroup
  [test] [symbol=n]

\starttext

% \startitemgroup
%   \startitem
% \startitemgroup[test]
%   \startitem
% ...
%   \stopitem
% \stopitemgroup
%   \stopitem
% \stopitemgroup

\startitemgroup
  \startitem
\startitemgroup
  \startitem
Lorem ipsum
\startitemgroup[test]
  \startitem
dolor sit amet,
  \stopitem
  \startitem
consectetur adipisicing elit.
  \stopitem
\stopitemgroup
  \stopitem
\stopitemgroup
  \stopitem
\stopitemgroup

\stoptext

I would expect items in the [test] itemgroup to be numbered 1, 2 but
instead they are both 0. I have also found out that, bizarrely,
uncommenting the first itemgroup fixes the issue. This is the behaviour I
get on the TeXLive 2016 version of ConTeXt, I don't have the latest
minimals installed to test.

Thanks in advance for any help with this matter!
___
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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

[NTG-context] Hyphens missing (again) with setupbackend[export

2017-07-23 Thread Rik Kabel
Aditya came across this in 2011 ([NTG-context] export kills hyphen 
symbol 
<https://www.mail-archive.com/ntg-context@ntg.nl/msg58460.html>)[1] with 
the Fontin font. It wasn’t answered then. It is back if it ever left.


Here is an example:

   \definefontfamily
[TestFont]
[rm]
[Antykwa Torunska Cond]
   \setupbodyfont
[TestFont]
   \setupbackend
[export=maybe]% or yes, or no, or ...
   \setuppapersize
[A7]
   \starttext
   \input ward
   \stoptext

If the \setupbackend statement is removed, or an invalid key is used, 
all is well. It fails with a valid key and any value for that key.


I am experiencing the problem of missing hyphens with this font even 
without \setupbackend, but cannot yet construct a working example.


--
Rik

[1] https://www.mail-archive.com/ntg-context@ntg.nl/msg58460.html

___
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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] handling an external sag file as a text character

2018-10-02 Thread Wolfgang Schuster

\setupexternalfigure[location=default]

\definefiguresymbol [textmill] [mill] [height=1.7ex]

\starttext

A \externalfigure[mill][height=1.7ex]
B \figuresymbol[mill]
C \figuresymbol[mill][height=1.7ex]
D \symbol[textmill]
E

\stoptext

Wolfgang


Floris van Manen schrieb am 02.10.18 um 20:07:

When it is possible to handle an external svg file as a singe character with 
text,
i assume there is someone on the list who could point me to the instructions as 
how to do that.

Thanks
Floris



___
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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] problem with \sym?

2019-02-03 Thread Wolfgang Schuster

Alan Bowen schrieb am 03.02.19 um 15:33:
Processing a table of contents with the latest standalone (ConTeXt 
 ver: 2019.01.28 16:58 MKIV beta  fmt: 2019.2.3) fails with the 
following message:


luatex warning  > hpack filter: error: 
...eXt/tex/texmf-context/tex/context/base/mkiv/typo-dua.lua:422: 
attempt to compare number with nil



tex error       > tex error on line 18 in file c_Contents.tex: ?



\strc_itemgroups_make_symbol_box ...mbol \fi \fi }

                                                \let 
\strc_itemgroups_extr...


\strc_itemgroups_insert_item ...s_make_symbol_box

\strc_itemgroups_make_dest...

\strc_itemgroups_start_item ...groups_insert_item

                                                \dostoptagged 
\ifcondition...




\dotagsetitem

\sym ..._symbol \startitemgroupitem \dotagsetitem

                                                \s!symbol

l.18 \sym{0.}

          Prolegomena to the Study of Hellenistic Astronomy


This worked with the previous standalone.


Can you provide a example because the error message shows
a problem with itemize while you mention the table of contents.

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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] Filling the diamond in enumeration

2019-04-20 Thread Otared Kavian
Hi Fabrice,

You can define your own symbol, as in the following:

\starttext
  \definesymbol[mysymbol][{$\red\blacklozenge$}]
  \definesymbol[redtriangle][{$\red\blacktriangleright$}]
  
  \startitemize[mysymbol]
  \item foo
  \item bar
  \item baz
  \stopitemize

  \startitemize[redtriangle]
  \item foo
  \item bar
  \item baz
  \stopitemize
  
\stoptext

Best regards: OK

> On 20 Apr 2019, at 12:24, Fabrice Couvreur  
> wrote:
> 
> Hi,
> Is it possible to fill the diamond ?
> Thank you.
> Fabrice
> 
> \starttext
> \startitemize[4][color=red]
> \item One
> \item Two
> \stopitemize
> \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://context.aanhet.net
> archive  : https://bitbucket.org/phg/context-mirror/commits/
> 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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] \setupbreakpoint[compound] not working

2013-04-18 Thread Aditya Mahajan

On 2013-04-19, at 12:34 AM, Wolfgang Schuster  
wrote:

> 
> Am 19.04.2013 um 01:53 schrieb Aditya Mahajan :
> 
>> Hi,
>> 
>> I do not get a line-break after a dash if I set
>> 
>> \setupbreakpoint[compound]
>> 
>> Minimal example (tested with 2013.04.14 MkIV)
>> 
>>   \setbreakpoints[compound]
>> 
>>   \setuppapersize[S3]
>> 
>>   \showframe
>>   \starttext
>> 
>>   ABCD
>>   node-to-node
>>   node-to-node
>>   node-to-node
>>   node-to-node
>> 
>>   \stoptext
>> 
>> See the attached file for output. Is it a bug, or am I missing something.
> 
> The breakpoint command expects a certain number of characters at
> the left and right side of the symbol before it performs a line break.
> 
> See also:
> 
> - http://www.ntg.nl/pipermail/ntg-context/2012/070340.html
> - http://www.ntg.nl/pipermail/ntg-context/2012/070344.html

Thanks.

Aditya
___
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] Automatic replacement?

2013-05-03 Thread luigi scarso
On Fri, May 3, 2013 at 3:24 PM, "H. Özoguz"  wrote:

> Is it possible to define an automatic replacement?
>
> I want to replace every
>
> اللَّـه
> by
> اللهِ
>
> First is a combination of letters, second is the correct arabic one-symbol
> for the name "Allah". I know, I can do this in the editor, but would
> helpful, if it is possible in the compiling.
>
> Huseyin
>
>
\directlua{ local function replace_txt (buffer)
buffer=string.gsub(buffer,"A","BB") return buffer end
callback.register("process_input_buffer",replace_txt)
}

\starttext my text A \stoptext

copied & pasted in real time at 16:04 on friday May 3 from the Hans's talk
at bachotek 2013 about luatex and plain tex.
Please test with your characters.

--
luigi
___
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] [***SPAM***] Wrong °C symbol with \unit and dejavu font

2013-05-17 Thread Hans Hagen

On 5/17/2013 11:18 AM, Alan BRASLAU wrote:

On Fri, 17 May 2013 09:53:48 +0200
Hans Hagen  wrote:


mupdf uses SIGHUP under linux -- does windows offer a similar way ?


we only want to close a file, not the whole session


"Sending a SIGHUP signal to the mupdf process will also cause the viewed
file to be reloaded automatically, for use in e.g. build scripts."

Alan

(Also, zathura is another lightweight PDF viewer.)


sumatrapdf seems quite ok now, so i'll test that one for a while

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] Missing °C symbol in math mode with dejavu font

2013-05-20 Thread Khaled Hosny
On Mon, May 20, 2013 at 11:22:41PM +0200, Khaled Hosny wrote:
>
> My suggestion is to just use \phys_units_text_* always, since the
> decomposed, two characters is the preferred form for those two units.

“In normal use, it is better to represent degrees Celsius ‘°C’ with a
 sequence of U+00B0 DEGREE SIGN + U+0043 LATIN CAPITAL LETTER C, rather
 than U+2103 DEGREE CELSIUS. For searching, treat these two sequences as
 identical. Similarly, the sequence U+00B0 DEGREE SIGN + U+0046 LATIN
 CAPITAL LETTER F is preferred over U+2109 DEGREE FAHRENHEIT, and those
 two sequences should be treated as identical for searching.”
 
 http://www.unicode.org/versions/Unicode6.2.0/ch15.pdf#G20445

Regards,
Khaled
___
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] (mathematics) Stretching Unicode big operator

2013-06-24 Thread Hans Hagen

On 6/22/2013 10:45 PM, Sander Maijers wrote:

If I decide to use, for instance, "Σ" instead of "\sum", this operator
is no longer stretched/scaling regardless of the sub/superscripts
specified tot it. Is it possible to keep stretching/scaling while using
Inicode characters for such operators?


This is because it's a greek sigma and I'm pretty sure that e.g. Thomas 
would be surprised to see a math symbol showing up in his greek.


You need to use another one:

$$\sum\frac{1}{\frac{1}{\frac{1}{\frac{1}{2$$

$$∑\frac{1}{\frac{1}{\frac{1}{\frac{1}{2$$

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] suggestion: setups for \startitem

2013-07-06 Thread Hans Hagen

On 7/6/2013 12:10 PM, Wolfgang Schuster wrote:


To do this one could write

   \startitem[alternative=head,text=…]

one could use it as synonym for \starthead or with

   \startitem[alternative=symbol,text=…]

as alternative for \sym. Since references are lost with this method you can 
write “reference=…” in the argument.


Currently I'm a bit careful with changes as I'm using a 'copy' of 
context mkiv that has been adapted to a potential upcoming Lua related 
speedup that Luigi and I are working on. We will present most of that at 
the context conference (among other things).


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] \triangledown placed too low in Palatino

2014-04-10 Thread Jannik Voges
I think you are using the wrong symbol. Or at least I would prefer \nabla as 
gradient operator.


Jannik


Am 10.04.2014 um 23:49 schrieb Sanjoy Mahajan :

> I just noticed that the gradient operator (\triangledown) ends up too
> low when using Palatino:
> 
> \setupbodyfont[palatino]
> \starttext
> $\triangledown T$
> \stoptext
> 
> It seems about 3pt too low.  Without the \setupbodyfont[palatino], the
> placement is fine.
> 
> (tested with 2013.05.28 and 2014.03.27 betas)
> 
> -Sanjoy
> ___
> 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
___


[NTG-context] \pm set too low in MkIV?

2014-05-06 Thread Sanjoy Mahajan
Continuing my recent theme of finding glyphs too low or too high:

The \pm symbol looks like it is set too low, in MkIV.

\setuppagenumbering[location=]
\starttext
$\pm2$
\stoptext

The minus part of the sign lies below the baseline, which looks odd
relative to the horizontal stroke of the "2."

In MkII it is fine, as is the equivalent latex or plain tex (using
LatinModern).

I don't know whether the problem lis in the font metrics or in the
positioning by MkIV, because I haven't yet been able to convince tex,
latex, lualatex, or luatex to use the same font (LM math).

In MkIV, the font is  (from pdffonts):

  NSOXNN+LatinModernMath-Regular   CID Type 0C   Identity-H

Can anyone confirm the problem?

-Sanjoy
___
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] upright lowercase Greek letters in math formulas

2014-05-26 Thread Johannes Kuester

Hi Mojca,

it seems font switches do not work here.

You must define your own commands for upright Greek letters, e.g.

   \def\muup {\Umathchar  "0"0"B5 }

At least this works, maybe there is a better way to do it.


Johannes


Am 26.05.14 14:12, schrieb Mojca Miklavec:

Hi,

How could I get upright lowercase Greek letters in math formulas
(provided that such a symbol exists, of course)?

Here's a minimal example:

\setupbodyfont[times]
\starttext
$15{\rm\frac{μm}{μs}}$ 15 μs
\stoptext

Thank you,
 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
___


___
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] \head: broken?

2014-07-16 Thread Wolfgang Schuster

Am 16.07.2014 um 13:07 schrieb Rob Heusdens :

> Hello All,
> 
> Still having problem with \head in \setupitemize.
> 
> - When I set the headstyle in \setupitemize, the numbering disappears and
> the symbol appear (like when I used '1' instead of 'n'). (ex. 1: MNWE)
> 
> - If I comment the headstyle out, numbers do appear. (ex. 2: MWE).
> 
> Why is that?

You can’t mix keywords and assignment in the same argument of a setup-command, 
e.g.

\staritemize[packed,headstyle=bold]

but some commands have multiple arguments which you use for both types, e.g.

\startitemize[packed][headstyle=bold]

BTW: A minimal example should be compilable (i.e. you need \starttext and 
\stoptext) which isn’t the case with your 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] Strange Behaviour of \mathop

2014-07-28 Thread Tobias Columbus
On Fri, Jul 25, 2014 at 11:08:17AM -0400, Aditya Mahajan wrote:
> On Fri, 25 Jul 2014, Tobias Columbus wrote:
> 
> >Dear list,
> >
> >I stumpled upon a very strange effect that \mathop has on the vertical
> >positioning of characters.
> >
> >\mathop applied to a single character results in the character's baseline 
> >being
> >lower than the baseline of all other characters. This does neither depend on 
> >the
> >font (checked with Lucida OT, Pagella and LatinModern) nor on the specific
> >character.
> >
> >A minimal example for LatinModern and Pagella is attached.
> 
> This is a feature of \mathop: for one letter arguments, \mathop centers the
> symbol on the math-axis. If you don't want this, use:
> 
>   \mathop{P\kern\zeropoint}
> 
> etc.
> 
> Aditya

Thank you.

Tobias
___
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] math \prime with subscripts

2014-09-22 Thread Aditya Mahajan

On Sun, 21 Sep 2014, Yuri Teixeira wrote:


Hi
is there a way for \prime not get smaller when used with sub/superscripts?
Or realigned somehow? Without font changes would be nice.

\starttext

\startformula
\frac13T\prime_{rs}T\prime_{st}T\prime_{tr}
\stopformula

\startformula
\frac13T_{rs}\prime T_{st}\prime T_{tr}\prime
\stopformula

\stoptext


I always thought that one was supposed to use either

   T' or T^{\prime}

So, if you want a bigger prime symbol, that is really a font design issue.

Having said that, I believe that it should be possible to control the 
scaling of the prime using a font goodies file, but I do not know the 
details.


Aditya
___
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] Create an item marker with a counter with Metapost

2014-11-10 Thread Alan BRASLAU
On Mon, 10 Nov 2014 19:18:20 +0100
Fabrice Couvreur  wrote:

> Hi,
> With the book Metafun I created a marker with metapost. How to add a counter ?
> Best regards,
> Fabrice

The puzzler is for you to understand why I only increment by 1/2 ;-)
Perhaps someone else can suggest a better solution?

Alan

\startMPdefinitions
numeric counter; counter := 1;
\stopMPdefinitions

\startuseMPgraphic{itemize:fuzzy}
numeric u; u:=0.5cm;
save p; path p; p := fullcircle xyscaled (u,u) randomized 2pt;
pickup pencircle scaled 1pt;
fill p withcolor green;
draw p withcolor blue;
draw textext(decimal counter) withcolor red;
counter := counter + .5;
\stopuseMPgraphic

\definesymbol[itemize:fuzzy][\useMPgraphic{itemize:fuzzy}]
\setupitemize[1][symbol=itemize:fuzzy]

\starttext
\startitemize
\startitem \input knuth \stopitem
\startitem \input knuth \stopitem
\stopitemize
\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] Create an item marker with a counter with Metapost

2014-11-10 Thread Wolfgang Schuster

> Am 10.11.2014 um 19:18 schrieb Fabrice Couvreur :
> 
> Hi,
> With the book Metafun I created a marker with metapost. How to add a counter ?
> Best regards,
> Fabrice
> 
> \startuseMPgraphic{itemize:fuzzy}
> numeric u;
> u:=0.5cm;
> save p; path p;
> p := fullcircle xyscaled (u,u) randomized 2pt;
> pickup pencircle scaled 1pt;
> fill p withcolor green;
> draw p withcolor blue;
> \stopuseMPgraphic
> \definesymbol[itemize:fuzzy][\useMPgraphic{itemize:fuzzy}]
> \setupitemize[1][symbol=itemize:fuzzy]
> \starttext
> \startitemize
> \item \input knuth
> \item \input knuth
> \stopitemize
> \stoptext

You can use the visualcounter module, the documentation is included in the 
package
or you download it from the github [1] page.

[1] https://github.com/adityam/visualcounter 
<https://github.com/adityam/visualcounter>

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] [LUATEX] uname() volunteers needed

2008-05-21 Thread Thomas A. Schmitz

On May 21, 2008, at 2:11 PM, Taco Hoekwater wrote:

> Because I do not want to alter the lua return values, that
> means I will have to interpret the contents of the returned
> structure a bit. To do that, I would appreciate it if the people
> on a non-linux32intel platform would compile and run the
> attached minimalistic C file.
>
> Thanks in advance,
> Taco

Hi Taco,

on i386-darwin, the file doesn't compile (I saved the file as "mini"):

ld: warning in mini, file is not of required architecture
Undefined symbols:
   "_main", referenced from:
   start in crt1.10.5.o
ld: symbol(s) not found
collect2: ld returned 1 exit status

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


Re: [NTG-context] Differences between \setupfootnotedefinition and \setupfootnotes

2008-08-18 Thread Holzminister
Ah, I see. Thanks!


Am Sun, 17 Aug 2008 22:14:07 +0200
schrieb Hans Hagen <[EMAIL PROTECTED]>:

> Holzminister wrote:
> > Hi!
> > 
> > Can anyone explain the differences between the mentioned commands?
> 
> the first one can be used to tune the rendering of footnotes (cf. 
> descriptions), while the second influences the footnote handling and 
> inline symbol
> 
> 
> -
>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
> -
> ___
> 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  :
> https://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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] symb-uni.tex

2008-09-04 Thread Alan Stone
>this system is ...
>a kind of obsolete mechanism now that we have mkiv

Excuse me my ignorance...

What mkiv feature/mechanism replaces the obsolete one ?

Best,
Alan

On Thu, Sep 4, 2008 at 5:36 PM, Hans Hagen <[EMAIL PROTECTED]> wrote:

> Alan Stone wrote:
> > Hi,
> >
> > re: http://source.contextgarden.net/symb-uni.tex
> >
> > What does, for example,
> >
> > "0x2000: Requires UnicodeRegular20" mean in
> > \startsymbolset[Unicode Additional Punctuation] % 0x2000: Requires
> > UnicodeRegular20
> >
> > in the context of
> >
> > \usesymbols[uni]
> > \def\mySymbol{\symbol[Unicode Additional Punctuation][*symbolname*]}
>
> this system is based on big ttf files split into pfb ranges where 20
> indicates a range (so, the font with symbolicname UnicodeRegular might
> have many split fonts)
>
> a kind of obsolete mechanism now that we have mkiv
>
> Hans
>
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


[NTG-context] Font sizes, vertical spacing, footnote symbols

2010-12-06 Thread Nicola
Hi,
I have a set of specifications for a document and I am having some 
problems implementing it. I am using MKIV from TeX Live 2010. I have 
some difficulty with these requirements in particular:

1) title: 17pt, boldface, capital letters; 12pt spacing before and 3pt 
spacing after the title;

Now I use

\setuphead[title][align=middle,style={\bfd\cap},before={},after={}]

How can I ensure that the font size is exactly 17pt?
How to I specify precise vertical spacing?

3) All § must be indented 1.25cm;

\setupindenting[1.25cm,yes,first]

But the first § of each Section is not indented.

4) footnote symbol: *

I use

\setupnote[footnote][numberconversion=set 3]

but I get stars instead of asterisks.

Can you please help me with these?
Nicola

___
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] customized item list symbol/graphic [solved]

2010-12-11 Thread Jan-Erik Hägglöf

On 2010-12-11 18:24, Wolfgang Schuster wrote:

Am 11.12.2010 um 17:14 schrieb Jan-Erik Hägglöf:


None of the above setting worked for me. Even tried

\startitemize[columns,2*broad][inbetween={\blank[1cm]}]

With the „columns“ keyword you get also packed items, to unset this
setting add „unpacked“ to your setup:

\startitemize[columns,unpacked,2*broad][inbetween={\blank[1cm]}]

Please make complete examples next time which can be used without
adding extra lines, e.g. this is what i used for your problem:

\starttext
\startitemize[columns,unpacked][inbetween={\blank[2*big]}]
\dorecurse{4}{\item text}
\stopitemize
\stoptext

Wolfgang


It worked! I will follow your advice next time!

Thanks a lot!

Jannema

___
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] math spacing

2011-03-14 Thread Wolfgang Schuster

Am 14.03.2011 um 12:14 schrieb Otared Kavian:

> Hi Hans VdM and Wolfgang,
> 
> It is true that naming a variable PYR, even in plain TeX, as shown below, 
> gives rise to an ugly mathematical symbol since there is a certain distance 
> between the « Y » and the « R » with math italic:
> 
>   http://dl.dropbox.com/u/4316076/spacing-plain.pdf
> 
> The problem may be the bounding box of « Y ».

Wasn’t this what i showed in my example?

> However, I think that in the example given by Hans VdM in mkiv, there is 
> another, more important, issue which is the way the commas are treated 
> between the variables Q, Y, N, P, Y, Z in math italic.

\setupmathematics[autopunctuation=no]

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] Google Chart URL

2011-04-16 Thread Aditya Mahajan

On Sat, 16 Apr 2011, Wolfgang Schuster wrote:



Am 16.04.2011 um 20:31 schrieb Reviczky, Adam:


Hi

I have problems with special characters in URL's.
What I wanted at first place, is embedding a google chart image, so I've tried 
this:

\starttext
\externalfigure[{https://chart.googleapis.com/chart?cht=p3&chs=250x100&chd=t:60,40&chl=Hello|World}]
\stoptext

which fails with:
! Undefined control sequence.
system  > tex > error on line 3 in file test.tex: Undefined control 
sequence ...

as far as I can tell it's the "|" symbol where it has problems.


\starttext
\externalfigure[https://chart.googleapis.com/chart?cht=p3&chs=250x100&chd=t:60,40&chl=Hello\letterbar
 World][method=png,scale=4000]
\stoptext


Or better

\asciimode
\starttext
\externalfigure[https://chart.googleapis.com/chart?cht=p3&chs=250x100&chd=t:60,40&chl=Hello|World][method=png]
\stoptext

Aditya
___
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] beta

2011-06-08 Thread Hans Hagen

On 9-6-2011 3:38, Li Yanrui (李延瑞) wrote:

2011/6/9 Hans Hagen:

Hi,

I uploaded a beta.



The luatex-plain format has been broken. I use the following file to
generate format.

\input plain
\directlua {tex.enableprimitives('', tex.extraprimitives())}
\pdfoutput=1
\everyjob \expandafter {%
 \the\everyjob
 \input luatex-basics\relax
 \input luatex-fonts\relax
 \input luatex-mplib\relax
}
\edef\fmtversion{\fmtversion+luatex}
\dump

During luatex run I get an error:

! LuaTeX error 
...pt/context/tex/texmf-context/tex/generic/context/luatex-fonts-merged.lua:2655:
unexpected symbol near '.


you should take luatex-plain.tex as example

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

2011-06-09 Thread 李延瑞
2011/6/9 Hans Hagen :
> On 9-6-2011 3:38, Li Yanrui (李延瑞) wrote:
>>
>> 2011/6/9 Hans Hagen:
>>>
>>> Hi,
>>>
>>> I uploaded a beta.
>>>
>>
>> The luatex-plain format has been broken. I use the following file to
>> generate format.
>>
>> \input plain
>> \directlua {tex.enableprimitives('', tex.extraprimitives())}
>> \pdfoutput=1
>> \everyjob \expandafter {%
>>     \the\everyjob
>>     \input luatex-basics\relax
>>     \input luatex-fonts\relax
>>     \input luatex-mplib\relax
>> }
>> \edef\fmtversion{\fmtversion+luatex}
>> \dump
>>
>> During luatex run I get an error:
>>
>> ! LuaTeX error
>> ...pt/context/tex/texmf-context/tex/generic/context/luatex-fonts-merged.lua:2655:
>> unexpected symbol near '.
>
> you should take luatex-plain.tex as example
>

It seems that luatex-plain.tex has been not exist in minimals for a long time.

-- 
Best regards,

Li Yanrui
___
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] \unit and Hertz, lux, and degrees/minutes/seconds

2011-11-17 Thread Pontus Lurcock
On Fri 18 Nov 2011, Robin Kirkham wrote:

> > Conventions for setting the degrees of temperature symbol vary; see
> > http://en.wikipedia.org/wiki/Degree_symbol#Typography and references
> > therein. In most professionally published works that I've seen, there
> > is no space between the number and the °, or between the ° and the C.
> 
> I agree they vary, and no space before the °C is quite common (and
> frequently my own practice too). However in setting default
> behaviour for Context I am inclined to favour conforming to
> international standards, where they exist (but a \setupunits
> override it probably called for).

I have no opinion as to what the default behaviour should be, but it
would certainly be useful to have spacing for ° temperature
configurable separately from that for other units.

Pont
___
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] ∫ and $\intop$ is not displayed correctly compared to $\int$.

2011-12-11 Thread Aditya Mahajan

On Sun, 11 Dec 2011, Philipp A. wrote:


apart from this IMHO very useful change (mapping  to \int), maybe we should
create a unicode-math module which replaces some commands with symbols. i
find myself always using this for chemical and mathematical documents:

\catcode`→=\active
\def→{\xrightarrow}
\catcode`↔=\active
\def↔{\xleftrightarrow}
\catcode`√=\active
\def√{\sqrt}


Have a look at char-def.lua. All the symbol mappings are defined there. 
Please feel free to complete the table (it is a boring and time consuming 
process, and I have only managed to cover about half of the table).


Regarding your mappings, IIRC -> etc are mapped to \rightarrow etc, (not 
\xrightarrow). We can talk about including style variants for the 
mappings.


Aditya___
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] Fontawesome in lmtx

2020-04-11 Thread Aditya Mahajan

On Fri, 10 Apr 2020, kaddour kardio wrote:


Hi, if there any changes in the interface for using symbols?
I tried today the example from Aditya's Blog but it shows no symbols:

\definetypeface[mainfont][rm][specserif][Linux Libertine O][default]
\definetypeface[mainfont][mm][math] [TeX Gyre Pagella Math][default]
\definetypeface[mainfont][tt][mono] [Dejavu Mono][default] [rscale=0.8,
features=none]
\setupbodyfont[mainfont,11pt]
\usesymbols[fontawesome]

\define\FA{\dosingleargument\doFA}
\def\doFA[#1]{\inlinedbox
   {\scale[height=1em]{\symbol[fontawesome][#1]}}}

\starttext
Checked box \FA[check-square-o]
Unchecked box \FA[square-o]
\stoptext
i use luamtetex for archlinux with all luatex modules linked to lmtx folder


The names of the symbols have changed in fontaweson 5.0. Try:

\FA[check] \FA[check_empty]

Aditya
___
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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] Dangerous bend metafont/post code?

2020-05-27 Thread Taco Hoekwater
Sure, it is a character in manfnt.mf (and there is a pfb version of that as 
well)

Taco

> On 27 May 2020, at 21:20, Gerben Wierda  wrote:
> 
> To honour Donald Knuth, I’ve use his ‘dangerous bend’ (with attribution of 
> course) in one of my publications. But I only had a low res image. Is the 
> code of this symbol available somewhere so I can do it proper justice in a 
> next edition?
> 
> G
> ___
> 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://context.aanhet.net
> archive  : https://bitbucket.org/phg/context-mirror/commits/
> 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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] Dangerous bend metafont/post code?

2020-05-27 Thread Lutz Haseloff
You can find the code in The Metafontbook, page 106f.

Greetings Lutz

Am 27. Mai 2020 21:19:26 MESZ schrieb Gerben Wierda :
>To honour Donald Knuth, I’ve use his ‘dangerous bend’ (with attribution
>of course) in one of my publications. But I only had a low res image.
>Is the code of this symbol available somewhere so I can do it proper
>justice in a next edition?
>
>G
>___
>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://context.aanhet.net
>archive  : https://bitbucket.org/phg/context-mirror/commits/
>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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] demo-symbols not working with LMTX

2021-01-19 Thread Hans Hagen

On 1/19/2021 12:18 PM, Jairo A. del Rio wrote:

Hi, list.

I was looking for information about fonts in ConTeXt defined using 
MetaPost and I found demo-symbols.tex for an Unicode (?) character. 
However, it doesn't work. While LMTX just doesn't print the symbol, MkIV 
complains from the Lua side. Has something changed?


i'll fix it for mkiv (has to be adapted to lua 5.3+)

the lmtx example usage is like this:

   \showglyphs

\startTEXpage[offset=10pt]
\definemetafont[MyDemoA][demo-symbols][at 
10pt]\MyDemoA\char9754
\definemetafont[MyDemoB][demo-symbols][at 
30pt]\MyDemoB\char9754

\stopTEXpage

(i'll add it to the test file)

Hans

-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
   tel: 038 477 53 69 | www.pragma-ade.nl | 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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] Lua code and table

2021-02-18 Thread Jano Kula
Hello Fabrice,



On Thu, 18 Feb 2021 at 16:19, Fabrice Couvreur 
wrote:

> Hi all, Thanks to you, I'm not at your level with Lua, but I'm learning
> thanks to you
> Hans, I compiled your code and I get an error message :
>
> lua error   > lua error on line 50 in file ./table_1.tex:
>
> token call, syntax: [ctxlua]:11: unexpected symbol near '='
>
> 13 \startluacode
> 14  function document.MyTable(specification)
> 15
> 16  local pattern= specification.pattern
> 17  local action = specification.action
> 18  local conversion = specification.conversion or "Characters"
> 19
> 20  local n = #pattern
> 21
> 22  --  context.startxtable { align = "middle,lohi", width =
> "0.8cm",
> 23 >>  offset = "0.8ex", bodyfont = "9pt", framecolor = "cyan" }
>

Just comment out line 23, too, or join 22 + 23 to one line.

Jano
___
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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] No space between \cite and next word.

2021-04-18 Thread Hans Hagen

On 4/16/2021 12:00 PM, Mikael Sundqvist wrote:

Hi,

I think there has been some change recently. Is it on purpose that
there is no space after the \cite. Look how the parenthesis that ends
the citation and the word "text" are set without space inbetween.

/Mikael

\startbuffer[mybib]
@article{a,
   author = {An Author},
   title = {A title},
   year = {2021},
}
\stopbuffer

\usebtxdefinitions[apa]
  \usebtxdataset[mybib.buffer]

\starttext

Text \cite[a] text.

\placelistofpublications

\stoptext

Wolfgang and I agreed upon the following commands keeping spaces

\cite (and variants)
\citation (and variants)
\date
\figuresymbol
\note
\notesymbol
\symbol
\typeinlinebuffer
\externalfigure

Hans


-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
   tel: 038 477 53 69 | www.pragma-ade.nl | 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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] What do you miss in ConTeXt?

2010-02-10 Thread Alan BRASLAU
On Wednesday 10 February 2010 10:07:26 Sebastien Mengin wrote:
> > > 4. Commands \primo, \secundo, \tertio and \quarto print 1o, 2o, 3o, 4o.
> > > \FrenchEnumerate{6} prints 6o.
> >
> > 
> >
> > > obtained via the commands \No, \Nos, \no, \nos.
> > >
> > > 6. Two commands are provided to typeset the symbol for \degre
> >
> > No.
> 
> You mean: not for the moment?
> 

Of course, should be 1°, 2°.
I believe that "No" means that \primo, \secundo, ... and \No, \Nos, ...
make absolutely NO sense in mkiv, nor does \degre as we have unicode input.

Nothing, of course, prevents a user from defining \degre, etc.
if he/she prefers to write input in this way.

(I suppose that one could take a similar position on other, traditional
TeX definitions like \ldots and many others...)

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] \fieldstack with mkiv

2010-02-14 Thread Hans Hagen

On 14-2-2010 17:45, Wolfgang Schuster wrote:

Am 14.02.10 14:32, schrieb Hans Hagen:

On 13-2-2010 11:45, Peter Münster wrote:

\setupinteraction[state=start]
\definesymbol[step1][AAA]
\definesymbol[step2][BBB]
\definefieldstack[test][step1, step2]
\starttext
\fieldstack[test]

Just click \goto{here}[JS(Walk_Field{test})] to walk through the
fieldstack!
\goto{(restart)}[JS(Set_Field{test, 1})]
\stoptext

\def\dodefinefieldstack[#1][#2][#3]% name, symbols, settings
{\ifcsname fieldstack:#1\endcsname \else
\setgvalue{fieldstack:#1}{\dodofieldstack[#1][#2][#3]}%
\fi}

\else missing

works but only the first symbol is shown, all others are invisible


new attempt

-
  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
-
___
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] \installlanguage questions

2010-05-05 Thread Tomáš Pustelník
Hello,

I have few questions about command \installlanguage. First, in file lang-ini is 
command \setuplanguage for default language. It has parameters lefthyphen, 
righthyphen and hyphen. I would like to ask if these parameters can be used in 
command \installlanguage or not and what is their funcionality becouse I have 
tried use command:

\setuplanguage[cz][lefthyphen=@,righthyphen=@,hyphen=€] 

and I didn't see any changes. I thought it's used to setup hyphen mark when the 
word is spilt at the end of line but I still get symbol -

Also I would like to know whats the difference in \date and parameter date in 
\installlanguage? In parameter date in \installlanguage are curly backets, it's 
just some mask for command \date? Or those two are entirely different?

Thank you answers.

Tomas Pustelnik
___
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] \installlanguage questions

2010-05-06 Thread Hans Hagen

On 5-5-2010 3:48, Tomáš Pustelník wrote:

Hello,

I have few questions about command \installlanguage. First, in file lang-ini is 
command \setuplanguage for default language. It has parameters lefthyphen, 
righthyphen and hyphen. I would like to ask if these parameters can be used in 
command \installlanguage or not and what is their funcionality becouse I have 
tried use command:

 \setuplanguage[cz][lefthyphen=@,righthyphen=@,hyphen=€]

and I didn't see any changes. I thought it's used to setup hyphen mark when the 
word is spilt at the end of line but I still get symbol -


lefthyphen and righthyphen are supported now


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


<    9   10   11   12   13   14   15   16   17   18   >