ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* inside halign
@ 2006-06-25 19:50 Hans van der Meer
  2006-06-26  8:37 ` Taco Hoekwater
  0 siblings, 1 reply; 3+ messages in thread
From: Hans van der Meer @ 2006-06-25 19:50 UTC (permalink / raw)



[-- Attachment #1.1: Type: text/plain, Size: 819 bytes --]

This works:
\def\dodotablexrule[#1][#2]{\noalign{\color[#2]{\hrule height#1 depth 
\z@}}}

But doing inside halign (tables) things like:
\def\tablexrule{\dodoubleargument\dotablexrule}
\def\dotablexrule[#1][#2]{%
	\doifemptyelse{#2}%
		{\dodotablexrule[#1][\@@tbxframecolor]}%
		{\dodotablexrule[#1][#2]}%
	}
\def\dodotablexrule[#1][#2]{\noalign{\color[#2]{\hrule height#1 depth 
\z@}}}

I get the error:
	! Misplaced \noalign.
\dodotablexrule [#1][#2]->\noalign
                                    {\color [#2]{\hrule height#1 depth 
\z@ }}

I get the impression that none if these argument related stuff works  
inside the halign template.
Is there a remedy? Or do I just have to give up hope using a unified  
macro and will have to resort  to separate macro's for default/chosen  
parameters?

Hans van der Meer




[-- Attachment #1.2: Type: text/html, Size: 3234 bytes --]

[-- Attachment #2: Type: text/plain, Size: 139 bytes --]

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

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: inside halign
  2006-06-25 19:50 inside halign Hans van der Meer
@ 2006-06-26  8:37 ` Taco Hoekwater
  2006-06-27 18:53   ` Hans van der Meer
  0 siblings, 1 reply; 3+ messages in thread
From: Taco Hoekwater @ 2006-06-26  8:37 UTC (permalink / raw)




Hans van der Meer wrote:
> I get the impression that none if these argument related stuff works 
> inside the halign template.

Correct. TeX is in a very special state when it is looking for a
potential \noalign, and the argument parsing required for optional
arguments destroys that special state,

Greetings, Taco

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: inside halign
  2006-06-26  8:37 ` Taco Hoekwater
@ 2006-06-27 18:53   ` Hans van der Meer
  0 siblings, 0 replies; 3+ messages in thread
From: Hans van der Meer @ 2006-06-27 18:53 UTC (permalink / raw)


Thanks. Spares me a lot of puzzling.
In some places things with dodoubleargument etc seem to work, so here  
and there a workaround is possible.

On Jun 26, 2006, at 10:37, Taco Hoekwater wrote:

>
>
> Hans van der Meer wrote:
>> I get the impression that none if these argument related stuff works
>> inside the halign template.
>
> Correct. TeX is in a very special state when it is looking for a
> potential \noalign, and the argument parsing required for optional
> arguments destroys that special state,
>
> Greetings, Taco

Hans van der Meer

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2006-06-27 18:53 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-06-25 19:50 inside halign Hans van der Meer
2006-06-26  8:37 ` Taco Hoekwater
2006-06-27 18:53   ` Hans van der Meer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).