Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Strange cause of fatal error misdefined \pgfkeyscurrentkeyRAW #818

Closed
teepeemm opened this issue Dec 13, 2016 · 1 comment
Labels
Milestone

Comments

@teepeemm
Copy link
Contributor

@teepeemm teepeemm commented Dec 13, 2016

I've isolated a fatal error to the last \draw of the following:

\documentclass{article}
\usepackage{tikz}
\begin{document}
\begin{tikzpicture}
\draw [red,fill=blue] (1,1) circle (3pt) ;
\draw [draw={red},fill={blue}] (2,1) circle (3pt) ;
\draw [red,fill={blue}] (3,1) circle (3pt) ;
\draw [{red},fill=blue] (4,1) circle (3pt) ; % line 8
\draw [fill={blue},draw={red}] (5,1) circle (3pt) ;
\draw [fill={blue},{red}] (6,1) circle (3pt) ; % line 10, LaTeX renders as if fill=red
\draw [{red},fill={blue}] (7,1) circle (3pt) ; % line 11
\end{tikzpicture}
\end{document}

When I compile this, I get:

Warning:unexpected:pgfkeys In package pgfkeys: I do not know the key '/tikz/{red}', to which you passed
	at /Users/tprescott/Documents/programming/latexml/fill/fill.tex; line 8 col 23
	'', and I am going to ignore it. Perhaps you
	misspelled it
	In Core::Definition::Expandable[\pgfkeys... from pgfkeys.code.tex.ltxml line 111

Warning:unexpected:pgfkeys In package pgfkeys: I do not know the key '/tikz/{red}', to which you passed
	at /Users/tprescott/Documents/programming/latexml/fill/fill.tex; line 10 col 25
	'', and I am going to ignore it. Perhaps you
	misspelled it
	In Core::Definition::Expandable[\pgfkeys... from pgfkeys.code.tex.ltxml line 111

Fatal:misdefined:\pgfkeyscurrentkeyRAW Expansion of '\pgfkeyscurrentkeyRAW' has unbalanced {}
	at /Users/tprescott/Documents/programming/latexml/fill/fill.tex; line 11 col 25
	Expansion is red}
	In Core::Definition::Primitive[\pgfqkeys... from pgfkeys.code.tex.ltxml line 133

The warnings seem to happen when draw= is omitted and the draw color is surrounded by {}. Not surprisingly, when the document compiles (with the last draw commented out), those two circles don't have red borders.

The fatal error on the last draw I find strange. All other permutations of the arguments I could think of work out just fine. It's only that last arrangement that leads to a fatal error. I'm happy to work around the error by any of those other permutations (and chalk it up to bad luck that I hit it in the first place), but I thought you might be interested in a possible source of the second leading cause of fatal errors when we try to convert arXiv (if I'm reading http://cortex.mathweb.org/corpus/arXMLiv/tex_to_html/fatal/misdefined correctly).

@dginev dginev added this to the LaTeXML-0.8.3 milestone Dec 14, 2016
@brucemiller

This comment has been minimized.

Copy link
Owner

@brucemiller brucemiller commented Jan 10, 2017

Interesting way that pgfkeys is handling braces around keys and values. Actually, I'd fixed this awhile ago, but got sidetracked trying to fix some other tikz issues, while I was at it. Sorry for the delay, and thanks for the report!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants
You can’t perform that action at this time.