Reputation
67,063
Next tag badge:
107/100 score
18/20 answers
Badges
3 127 241
Newest
 Nice Answer
Impact
~1.4m people reached

Jul
23
revised How do you test whether a known key value has been set in pgfkeys
included \lccase
Jul
23
comment How do you test whether a known key value has been set in pgfkeys
And by the way, the previous version could be easily tricked with \makeatletter\begin{mytestenv}{mytestkey=\ae@unset@key@value}\end{mytestenv}\ma‌​keatother. You actually need to protect \ae@unset@key@value and not the content of it (which is irrelevant).
Jul
23
comment How do you test whether a known key value has been set in pgfkeys
The edit you made makes the same mistake as my previous version. It expands too much. Try: \begin{mytestenv}{mytestkey={aa}}\end{mytestenv}
Jul
23
revised How do you test whether a known key value has been set in pgfkeys
deleted 21 characters in body
Jul
23
revised How do you test whether a known key value has been set in pgfkeys
added 738 characters in body
Jul
23
revised Nodes vertical distance in a legend of a tikzpicture
CVS version handles polar coordinates differently.
Jul
23
answered How do you test whether a known key value has been set in pgfkeys
Jul
23
comment How do you test whether a known key value has been set in pgfkeys
I don't think that anymore. Instead of \relax (which might not be the ideal macro to check against as we have learned) we can simply use \pgfkeys@notset we can check against. Best would be to create our own handlers for that and an own \ifpgfkeyssetbyuser for a better interface.
Jul
23
comment Is there a way to define starred variants for a keyvalue system?
@A.Ellett (I have updated my answer after your edit. The \par seems—in this case—a better approach as you use \raggedleft. If you want to use \\, you need to issue a \noindent at the start. This reduces the conditionals to two.) You can of course initialize the keys with a special macro (say \pgfkeys@notset@by@user) and test against that if an empty value is otherwise a valid input).
Jul
23
revised Is there a way to define starred variants for a keyvalue system?
deleted 48 characters in body
Jul
23
comment Is there a way to define starred variants for a keyvalue system?
@A.Ellett If the key has not been set excludes setting the key with .initial. There is no value-key that is not set. (This is just TeX: \csnameing an undefined macro name expands to \relax.) If the key has not been set by the user it simply has the value of its .initialization. If the user sets a key that has not been .initialized they will get an error message.
Jul
23
comment Is there a way to define starred variants for a keyvalue system?
@A.Ellett \@empty means literally empty: \def\@empty{}. And this also true for the value-key (which is \defed into the special pgfk@/… macro). The \pgfkeysgetvalue macro \lets the second argument to the \pgfk@/… macro, basically \let\@epi@title\pgfk@/ae/…/title. Thus \@epi@title is as it would have been defined as \def\@epi@title{} and can now compared to \@empty. That has nothing to do with \relax.
Jul
23
revised Nodes vertical distance in a legend of a tikzpicture
deleted 46 characters in body
Jul
23
answered Nodes vertical distance in a legend of a tikzpicture
Jul
23
revised How to detect if option provided via \tikzset
edited tags
Jul
23
comment How do you test whether a known key value has been set in pgfkeys
I think this question is related: How to detect if option provided via \tikzset
Jul
23
revised Is there a way to define starred variants for a keyvalue system?
added 1205 characters in body
Jul
22
answered Is there a way to define starred variants for a keyvalue system?
Jul
22
revised Tikz clip shapes with another (built in) shape
added 728 characters in body
Jul
22
answered Tikz clip shapes with another (built in) shape