{pgfkeys} concerns a flexible key management system in TikZ/PGF.

learn more… | top users | synonyms

2
votes
1answer
61 views

How to show multi-choice answer key at the end of the document?

I want to show the answer keys at the end of the (multiple-choice) exam page. I have a bank of questions and answers (always the first answer in the bank is assumed to be the right choice), and some ...
1
vote
1answer
61 views

Parametric tikzset style with argument

I am working on a way to curtomize @percusse from Simulating hand-drawn lines to make it parametric. My idea is to have something like: \draw[penciline={jag ratio=2},decorate,thick] ...
3
votes
1answer
60 views

create new TikZ key with code and style tags

Assume I want to perform a complicated calculation within a TikZ key defintion. What is the recommended way to do this? Reading through the manual and digging around in other questions led me to ...
27
votes
2answers
737 views

How do I debug pgfkeys?

I'm sure if you're reading this question you are already familiar with my love for pgfkeys. However, it is absolutely impossible to debug: \tracingmacros is a total mess, with every key expanding to ...
3
votes
0answers
51 views

Custom vertical lines with pgfgantt (pgf multiplier issues)

I'm having some issues drawing vertical lines in a ganttchart (using the pgfgantt package). The approach is to define the bars in the chart using a dd-mm-yyyy format but only showing the months. To ...
4
votes
4answers
122 views

How do I override a previously set value for `/tikz/rotate`?

I was writing my own style for a particular collection of nodes, most of which I wanted rotated in the same manner. So I defined the following style: my node style/.style={rotate=60,draw} Please ...
0
votes
0answers
44 views

In Ubuntu 14.04 — Package pgfkeys Error:

I borrowed the following code from here (answer by @Gonzalo). I switched from Windows 7 to Ubuntu 14.04. Given code was working fine on Windows 7 but now on Ubuntu 14.04, I'm getting the following ...
8
votes
1answer
272 views

Shorten both ends of a line with one key

Consider the following snippet: \begin{tikzpicture} \def\ptRad{2pt} \fill (0,0) circle (\ptRad); \fill (1,1) circle (\ptRad); \draw[<->, shorten <=\ptRad,shorten >=\ptRad] ...
8
votes
1answer
86 views

Why is my /.is choice key not working correctly?

This example is much longer than it really needs to be, but I don't have the time to prune it down right now (apologies!). Everything in this example works as expected except the my fill key which is ...
1
vote
1answer
140 views

Custom separator for CSV import via csvsimple

I have successfully used csvsimple to import .csv files. But I would like to have commas as number separators, so I modified the .csv file to use semicolons as separators and as csvsimple manual says, ...
4
votes
1answer
65 views

Expanding arguments to pgf/tikz styles

In an answer on this site is proposed a method to draw arrows on paths. For example, using the style [arrow inside={pos=0.2}] will put an arrow at position 0.2 on the path : \begin{tikzpicture} ...
2
votes
1answer
123 views

How to define a special tikz node?

I want to define a special tikz node, that I'll use that way: \specialNode[name=mynode, label=mylabel, otherTikzOptions...] (node_name) at (some_coordinate); And gets coverted to: \node[circle, ...
4
votes
0answers
90 views

Global definition of pgfplots axes style conflicts with colorbar

I am trying to plot an individual colorbar (with no axis), using the code below (MWE): \documentclass{standalone} \usepackage{pgfplots} \pgfplotsset{compat=1.3} \begin{document} ...
4
votes
1answer
117 views

Extracting the value stored in the /tikz/x option

It is possible to change the x distance within TikZ internal coordinate system by passing the /tikz/x= key to the tikzpicture environment. \begin{tikzpicture}[x=14pt] % Picture code \end{tikzpicture} ...
2
votes
1answer
293 views

! Package pgfkeys Error | compiling a standalone picture as \includestandalone{fig}

I have two tikz pictures in external files (fig1.tex and fig2.tex): fig1.tex \documentclass[a4paper,class=minimal,border=0pt]{standalone} \usepackage{tikz} \usetikzlibrary{plotmarks} ...
4
votes
1answer
48 views

pgfkeys computed (i.e., dynamically defined) key

I would like to perform some simple simulation in latex/tikz (in order to produce dynamical graphs). Say something like cellular automata, Ising model, etc. I need to store somewhere the value of ...
5
votes
1answer
129 views

Package pgfkeys Error: The key '/tikz/opacity' requires a value

I'm drawing a diagram for a physical phenomenon, "motion in one dimension". I have this figure with a tikzpicture: \documentclass{article} \usepackage{tikz} \definecolor{particle}{rgb}{1.0,0.7,0.3} ...
7
votes
2answers
252 views

Using LaTeX commands inside pgfplotsset

Is there any way to use LaTeX commands inside \pgfplotsset? For instance, the following code produces an error indicated in the \pgfplotsset line, whereas if one replaced \contents in the ...
2
votes
0answers
35 views

Filtering key-value options

I want to define a new environment whose implementation depends on another environment. The first environment should accept a list of key-value options. Some of these options are for use only on this ...
3
votes
0answers
109 views

Getting a value, which has been given to a TikZ key

I'm trying to write a package based on TikZ, and this is the problem i'm currently stumbling upon. Let's assume, that I have a key, for example /tikz/circuit symbol unit, which executes some code. ...
3
votes
0answers
45 views

pgfkeys error in ytableau package

I'm running TeX Live 2013 Debian (on a Linux Mint 17 machine). I'm getting the following error when I try to load the ytableau package: ! LaTeX Error: File `pgfkeys.sty' not found. When I search ...
4
votes
1answer
2k views

Problem with “Package pgfkeys Error”

I am trying to create a color box using tcolorbox package. source code is like this- \documentclass[11pt]{article} \usepackage[top=.5in, bottom=.5in, left=1in, right=1in]{geometry} ...
12
votes
3answers
208 views

Is there a compact way to set the same default for multiple pgfkeys?

I want to set the same default value for multiple PGF keys, like in this case where both a and b have a default of 1: \documentclass{article} \usepackage{pgfkeys} \pgfkeys{ a/.code={a:#1}, ...
9
votes
2answers
1k views

Simple example of pgfkeys

I'm struggling to get my head around the pgfkeys package. I currently use the keycommand package, which I find very easy to understand: it's just ordinary LaTeX commands with named rather than ...
5
votes
1answer
79 views

How to store tcolorbox's (multiple) settings in a macro?

I'd like to store tcolorbox' (multiple) settings in a (single) macro (in fact, a xkeyval's \cmdKV@fam@key macro) and use them afterwards via this macro (I know I should use pgfkeys instead, but my ...
14
votes
2answers
401 views

PGF Keys differences between .initial and .default

I am not too sure just by reading the manual as to the subtle differences between the .initial and .default PGF key types. Can someone explain and demonstrate the differences with a minimal example?
5
votes
1answer
115 views

Tikz fit library: fitting only one dimension and accumulating calls

The fit library is very useful for adjusting the size of a node to fit other nodes inside it. It is also useful in conjunction with shift to make a node span to the width/height of other nodes but ...
4
votes
2answers
277 views

Parsing and programming in TikZ

Background: I'be been reading the PGF manual (keys section) and today the TeX Book just arrived in the mail and just started reading chapter 7 (How TeX reads what you type) -- feeling like Mickey ...
4
votes
0answers
45 views

How can I decide whether a key has had .value forbidden applied?

Is there a way to decide whether a given key has had the .value forbidden handler applied? For example, I would like to write a handler .only that can be applied to keys to simulate Beamer's \only ...
4
votes
1answer
218 views

Pass a 3d coordinate via pgfkeys

I'm using 3dplot to draw in 3D. Now I want to define my own environment, called pose, that is supposed to be used inside a tikzpicture-environment. It should perform a coordinate system tansformation ...
2
votes
0answers
180 views

I do not know the keys /tcb/flush right upper — pgfkeys error

On compiling with PdfLaTeX, the below MWE generates me the following error I do not know the keys /tcb/flush right upper. To resolve this issue, I downloaded tcolorbox and pgfkeys package from CTAN ...
4
votes
1answer
200 views

Alternate lefthand/righthand width and check odd page in tcolorbox

I am creating a new environment using the tcolorbox package in the define options pos=t,b,r,l and lwidth and rwidth for margins, using the scheme key=value of pgfkeys. My idea is to create two new ...
13
votes
1answer
134 views

Which arguments of `\includegraphics` cannot be set beforehand?

From the documentation of the graphicx package: Most of the keyval keys used in the graphicx package may also be set using the command \setkeys provided by the keyval package. For instance, ...
2
votes
0answers
167 views

Problem with pgf library in TexLive [closed]

I am using TexLive, and I am writing a paper with someone else. He has sent me all of his files. He uses tikz to draw commutative diagrams. I am trying to compile his files, but I get an undefined ...
3
votes
1answer
115 views

pgfkey to set anchor for negative values in a bar chart

I have a ybar chart with positive and negative bars and "node near coords". I'd like to have the nodes of pos. bars at the top and nodes of neg. bars at the bottom/under the bar. With the following ...
5
votes
1answer
68 views

Passing (just) other options, when using pgfopts

I want to use pgfopts (and therefore pgfkeys) when customizing a class with new options, keeping the old ones, and using some of them. Here is a simplified example with a class "exa" which extends ...
6
votes
0answers
144 views

how to add parameters to shape which internally use 'append after command'

years ago Mark Wibrow provided me the following code to adding text in inside border of a (rectangle) shape on this comp.text.tex thread: \documentclass[tikz,border=5mm]{standalone} %%% code from ...
2
votes
0answers
52 views

Using key-value interface for pgfkeys results in error

I've been reading a lot of posts lately on the difference between using the key-value interface and the handler interface of pgfkeys. To my understanding, the same values can be stored and retrieved ...
4
votes
0answers
25 views

The difference between \pgfkeysvalueof and /.store in [duplicate]

I thought using \pgfkeysvalueof on a key that does not have a /.store in and the variable of a key that does have a /.store in would give the same result. This seems not to be the case. This example, ...
5
votes
1answer
126 views

Reset pgfkey to default value in nested command call

I have created a new command whose argument can be a new call to the same command. How can I then reset the values of the pgfkeys in the nested call to their default values, so that they don't have ...
1
vote
1answer
181 views

set tikz options through pgfkeys

I'm using tcolorbox and using pgfkeys to set some of the tikz options. But they do not seem to be working. Consider the MWE given below. If I set draw color using \pgfkeys{/tikz/.cd, fill=red, ...
2
votes
0answers
36 views

Remove key from style

Is it possible to create a key handler with the pgfkeys package that removes a key from a style? Here's a minimal working example: \documentclass[preview,margin=10pt,convert]{standalone} ...
1
vote
1answer
82 views

Check the value of a pgfkey

I need to be able to check if the value of a pgfkey is empty or not. A solution I have tried (using package etoolbox): \edef\temp{\pgfkeysvalueof{/path/key}}% ...
4
votes
1answer
72 views

Changing the default value of a pgfkey

I want to create a command that can change the default value of my pgfkeys. I think the problem is that the value set as default is not expanded. Therefore the icondefaultsa below doesn't work. ...
24
votes
2answers
631 views

What is the correct way to get a pgfkey value?

This is my first foray into the pgfkeys package and I found the following behavior really odd. The Tikz/pgfkeys manual mentions two ways for setting key values: \pgfkeys{key=value} and ...
2
votes
1answer
662 views

Package pgfkeys Error: I do not know the key '/tcb/library/most'

I get the following error while compiling and the pdf is also not generated properly: ERROR: Package pgfkeys Error: I do not know the key '/tcb/library/most' and I am going to ignore it. Perhaps you ...
8
votes
2answers
195 views

How to create and use a new pgf key

In this example, I would like to have a new key NbGrad then I could write : \begin{tikzpicture}[>=stealth,x=6cm,font=\footnotesize,NbGrad=12] And use the key as I use \NbGrad or another way if ...
9
votes
1answer
132 views

Working with keys instead of \def

I have looked around on TeX.SX and I have learnt a lot of things. One of the things I have not yet mastered is how to use the key=value function that packages like keyval or xkeyval offer or even ...
6
votes
1answer
85 views

Style key syntax problem

I tried both \documentclass{standalone} \usepackage{tikz,pgfplots} \tikzset{axeseul/.style={% /pgfplots/axis x line align=center, % rien en y /pgfplots/axis y line align=none, % sans axe ...
4
votes
1answer
118 views

\AfterGroup sorcery and choking tex/pgf

In the following code, the line \AfterGroup* (from theetextools package) causes the pdfLatex compiler to 'choke', i.e it produces only this output and the process is stuck forever, consuming 13% of ...