LATEX-L Archives

Mailing list for the LaTeX3 project

LATEX-L@LISTSERV.UNI-HEIDELBERG.DE

Options: Use Forum View

Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Subject:
From:
Ulrike Fischer <[log in to unmask]>
Reply To:
Mailing list for the LaTeX3 project <[log in to unmask]>
Date:
Fri, 12 Jun 2015 22:49:16 +0200
Content-Type:
text/plain
Parts/Attachments:
text/plain (57 lines)
Am Fri, 12 Jun 2015 19:12:07 +0100 schrieb Joseph Wright:

> On 12/06/2015 11:58, Ulrike Fischer wrote:

>> That's a relieve. I was really very bewildered ;-)
> 
> Glad I could help: is a release urgent?

No.  
> 
>> Btw: I came across the problem because I was looking for a way to
>> get 
>> 
>>  \keys_set:nn { test } {type=\testvalue}
>> 
>> working, if \testvalue expands to a known choice. Is there some good
>> way to do it? 
>> 
>> \exp_args:Nnx\keys_set:nn { test } {type=\testvalue}
>>  
>> works but could lead to problems if more keys are in the list. 
> 
> Like other keyval systems, l3keys does no expansion of the key or value
> when parsing: that's by-design.

I know ;-). But sometimes it would be useful to be able to set a
choice or a boolean key through a tl or bool variable and not
explicitly. 

Btw: This doesn't work either

\documentclass{article}
\usepackage{expl3}
\begin{document}
\ExplSyntaxOn

\def\testvalueA{A}

\keys_define:nn {test}
 {
  type    .choices:nn = { A , B , \testvalueA }
   {
    blub
   },
 }

\keys_set:nn { test } {type=\testvalueA}

\ExplSyntaxOff
%Error
\end{document}
 

-- 
Ulrike Fischer 
http://www.troubleshooting-tex.de/

ATOM RSS1 RSS2