[NTG-context] Enumeration numbering in the left margin

2021-11-19 Thread kauśika via ntg-context
Dear list,

I have the following enumeration block.

\defineenumeration[verse]
\setupenumeration[verse]
  [alternative=leftmargin,
   text=,
   width=fit,
   distance=1em,
   way=bysection]

I actually want to (flush) left align the enumeration's number inside the left 
margin and give it a blue color. But even if I have 
   \setupmargindata[inleftmargin][color=bblue4,align=flushleft]
there is no alignment, no color.

However, if I do 
\setupenumeration[verse]
  [alternative=leftmargin,
   text=,
   width=\leftmarginwidth,
   headcolor=bblue4,
   distance=0em,
   way=bysection]
I am able to get the desired effect.

Is this the 'correct' way to do it? I mean to ask, am I doing something wrong 
with \setupmargindata or is this expected behaviour.

Thanks,
kauśika


___
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] Bug in lmt_arrow

2021-11-19 Thread Aditya Mahajan via ntg-context
On Mon, 15 Nov 2021, Hans Hagen wrote:

> On 11/15/2021 4:07 AM, Aditya Mahajan wrote:
> > On Sun, 14 Nov 2021, Aditya Mahajan via ntg-context wrote:
> > 
> > > On Sun, 14 Nov 2021, Hans Hagen wrote:
> > > 
> > 
> > Spoke too soon. Now straight lines don't work:
> 
> new attempt (submitted to build)

The following still fails with ver 2021.11.19 

\starttext

\startMPcode
  newpath p;
  ahfactor := 5;
  p := origin .. (3cm,0);
  draw lmt_arrow
   [
 path = p, 
 location = "percentage",
 percentage = 50,
 alternative = "curved", 
   ]
   withpen pencircle scaled 1bp;
\stopMPcode
\stoptext

I get an error:

metafun > log >
metafun > log > error: This can't happen (division by zero)
metafun > log >

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


Re: [NTG-context] \doifanydefinedelse, \doifallundefinedelse

2021-11-19 Thread Hans Hagen via ntg-context

On 11/19/2021 4:26 PM, Joey McCollum via ntg-context wrote:
I was checking the "Branches and Decisions" wiki entry at 
https://wiki.contextgarden.net/System_Macros/Branches_and_Decisions 
, 
and I saw that ConTeXt has a useful \doifalldefinedelse macro that 
checks a comma-separated list of macro names and proceeds according to 
whether or not all of the macros with those names are defined. I was 
curious as to whether or not there is also a \doifanydefinedelse (or, 
equivalently, a \doifallundefinedelse) macro that would check if /any 
/of the macros with names in the comma-separated list is defined (or, 
equivalently, if all of them are undefined). I don't see any mention of 
such a macro on the wiki page, so I wanted to ask: has something like 
this already been implemented, and if not, is there a simple way to do a 
check like this? This functionality would be useful for performing some 
checks on a key-value assignment, and passing a comma-separated list to 
a macro would be much cleaner than doing a bunch of nested if-else blocks.

i'll add \doifelseallundefined

btw, you don't need to nest if's in lmtx:

\ifdefined\foo
\orelse\ifdefined\ofo
\orelse\ifdefined\oof
\else
\fi

sort of stays on the same level ... makes tex bit more like other 
programming languages (but of course also makes macros less impressive)


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] \doifanydefinedelse, \doifallundefinedelse

2021-11-19 Thread Joey McCollum via ntg-context
I was checking the "Branches and Decisions" wiki entry at
https://wiki.contextgarden.net/System_Macros/Branches_and_Decisions, and I
saw that ConTeXt has a useful \doifalldefinedelse macro that checks a
comma-separated list of macro names and proceeds according to whether or
not all of the macros with those names are defined. I was curious as to
whether or not there is also a \doifanydefinedelse (or, equivalently, a
\doifallundefinedelse) macro that would check if *any *of the macros with
names in the comma-separated list is defined (or, equivalently, if all of
them are undefined). I don't see any mention of such a macro on the wiki
page, so I wanted to ask: has something like this already been implemented,
and if not, is there a simple way to do a check like this? This
functionality would be useful for performing some checks on a key-value
assignment, and passing a comma-separated list to a macro would be much
cleaner than doing a bunch of nested if-else blocks.

Joey
___
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] Multiline cell in spreadsheettable

2021-11-19 Thread juh via ntg-context
Am Fri, Nov 19, 2021 at 09:19:08AM +0100 schrieb Henning Hraban Ramm via 
ntg-context:
> Maybe in https://wiki.contextgarden.net/TABLE
> That page needs some better structure...

Thats probably correct.

I inserted a paragraph without improving the structure. 

juh

-- 
Autoren-Homepage: . http://literatur.hasecke.com
Satiren & Essays: . http://www.sudelbuch.de
Privater Blog:  http://www.hasecke.eu
Netzliteratur-Projekt:  http://www.generationenprojekt.de




signature.asc
Description: PGP signature
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

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


Re: [NTG-context] Multiline cell in spreadsheettable

2021-11-19 Thread Henning Hraban Ramm via ntg-context

Am 19.11.21 um 08:48 schrieb juh via ntg-context:


And in https://wiki.contextgarden.net/Command/setupTABLE the parameter
width is not mentioned at all.


Because it inherits from \setupframed where all these parameters are 
declared.



I would like to improve the wiki, any hint where a hint to this would
fit?


Maybe in https://wiki.contextgarden.net/TABLE
That page needs some better structure...

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