TikZ is a higher-level drawing language built on top of the PGF graphics framework. For questions specifically about the PGF layer use {pgf-core} instead. Both tags are possible on the same question. The tag {diagrams} is also compatible with this tag.

learn more… | top users | synonyms (3)

9
votes
2answers
860 views

Aligning two semicircles

I'm making \item commands with coloured circles. One needs to be two colours, i.e. two semicircles which form a single circle. I currently have this, which superimposes both circles: ...
6
votes
0answers
73 views

Why does tikz node parameters fail when given as a macro (set by \newcommand)? [duplicate]

Possible Duplicates: How to submit a set of tikz command with pgfkeys? Multiple TikZ keys with foreach I have a class file which is supposed to modify the maketitle. I use TikZ nodes for ...
3
votes
1answer
157 views

Get equal D and T slopes with tikz-timing

I'm using the tikz-timing package to create a bus timing diagram: \begin{tikztimingtable}[timing/slope=0.5] DT & 2D{}12D{}1D\\ CK & [H] 1H2{6T}2T\\ \end{tikztimingtable} Now it occurs that ...
13
votes
1answer
7k views

pgfplots: Selectively reducing marker size in the legend

I have a plot created using pgfplots in which I have included a legend. However, I find that the marker sizes in the legend are the same size as the markers used in the main plot. I think this is a ...
27
votes
2answers
1k views

How can I create new commands in TikZ?

I am new to the use of TikZ. I have been evaluating the TikZ-KTikZ combination, over the last 2 days, as an alternative to Xfig, which I have used for 17 years. I have managed to create a grid ...
8
votes
0answers
318 views

Help on adjusting histogram plot created by TikZ [duplicate]

I am trying to create a tikzpicture similar to what I have made in MATLAB. MATLAB gives me the following result after running histogram: myhistnorm = [ 0.1231 0 0 0 0 0 0 0.0001 0.0001 ...
31
votes
2answers
7k views

How to diagonally divide a table cell … properly?

There have been many threads discussing solutions to the task of drawing a diagonal line in a table cell. There are also two packages to do this, slashbox and the better looking makecell with its ...
10
votes
2answers
657 views

Hyperlinked nodes in TikZ mindmap

I am trying to make a small mindmap such that some of the child nodes are hyperlinked. I tried to follow the advice given here, about the new node style hyperlink node, but the following MWE compiles ...
16
votes
1answer
527 views

nodes structure like file system

I would like to draw a picture that reflects some file structure. Below code works almost as expected. I need to adjust the connections between nodes so they don't start from the center of the bottom ...
4
votes
2answers
2k views

Install Gnuplot on Mac OS-X 10.8.2 for use with 'tkz-fct' package

I have recently discovered the TikZ packages for LaTeX: http://altermundus.com/pages/tkz/index.html I have run the examples for tkz-euclide with success. I would also like to use the tkz-fct ...
4
votes
1answer
385 views

PGFPLOTS 3d box line for Z axis not being drawn

The vertical 3d box line for Z axis is not being drawn. If I make the grid lines dashed, the line is drawn, but also appears dashed, as the grid lines. To me, it looks that the line is in fact drawn, ...
1
vote
1answer
1k views

How to create a Markov chain with an empty node

I would create using tikz package this Markov chain but I encountered many problems. Who can post the right code to create the follow Markov chain?
77
votes
2answers
4k views

pgf-Tikz QR code generator

I am looking for a Tikz QR code generator. I am aware of pst-barcode as well as several "local" programs, a luatex solution and web services to do this. Nevertheless, if at all possible, I would much ...
8
votes
1answer
269 views

Tikz plots distorted mark

Consider the following code: \documentclass{minimal} \usepackage{tikz} \usetikzlibrary{plotmarks} \begin{document} \tikz{\draw (0,0) -- plot[mark=o] (0.5,0) -- (1,0);} \end{document} It seems ...
13
votes
1answer
4k views

Positioning relative to page in TikZ

Consider the following: Let's say I have a dot. I would like to be able to position this dot anywhere on the page: at the corner, in the middle, anywhere. So far, despite poring over manuals and ...
9
votes
1answer
193 views

TikZ: positioning label at the end of a path

I'm trying in TikZ to find a general way to draw an arrow and label it at the end. Something like this works reasonably well: \draw[->] (0, 0) -- (1, 3) node[pos=1.1]{$\vec{v}$}; However, ...
23
votes
3answers
721 views

Why does pdfTeX hang on this file?

MWE: \documentclass{minimal} \usepackage{commath, tikz} \begin{document} \begin{tikzpicture} \node {$:$}; \end{tikzpicture} \end{document} When I compile this, pdfTeX enters an infinite loop. Why?
19
votes
3answers
1k views

Can I mark ends of lines with a cross?

I have the following image: \documentclass{article} \usepackage[pdftex,active,tightpage]{preview} \setlength\PreviewBorder{2mm} \usepackage{tkz-fct} \usetikzlibrary{arrows, ...
2
votes
1answer
122 views

How to rearrange a tikzpicture in a page that uses the class suftesi

I drew an ER schema for a database and put it in my mini-thesis written using suftesi. This class has the peculiarity of adding a mini-column beside the main column of contents, used for notes. This ...
13
votes
2answers
554 views

How to avoid nesting of tikzpicture?

I have to draw the probability distribution function (PDF) in the following MWE multiple times in a figure as well as across multiple figures. I have read the following questions: Problem with ...
6
votes
2answers
316 views

Why can't I apply this decoration to a curve produced using the “to” path operation?

I have found that I cannot make decorations apply to (most) curves drawn using the "to" path operation. Here is a working example: \documentclass[a4paper, reqno]{amsart} \usepackage{tikz} ...
4
votes
1answer
657 views

Tikz bar plot problem: Missing number, treated as zero \end

I have been trying to plot the figure: by using TikZ. However, the code does not compile and I get many errors on line 48, which is \end{axis}, as follows: Dimension too large Missing number, ...
5
votes
1answer
243 views

Save tikz picture to disk

I need to save the result of a tikzpicture to disk in code. Basically I have written some optimization routines for other things that only create the image if it does not exist on disk. I want to ...
8
votes
1answer
645 views

Changing the indentation of a Tikz tree

I've drawn a directory listing style tree using code similar to that found in Drawing a directory listing a la the tree command in TikZ. I'll repeat it here for clarity ...
5
votes
1answer
171 views

Tikzpicture to Tikz Conversion

I have the following code which draws a tikzpicture. \documentclass{article} \usepackage{tikz} \begin{document} \begin{tikzpicture} \usepgflibrary{shapes.arrows} \tikzstyle{every ...
4
votes
1answer
230 views

interrupting edge in automata

I have the following automata in tikz. \documentclass{article} \usepackage{pgf} \usepackage{tikz} \usetikzlibrary{automata, arrows} \begin{document} \begin{figure}[htb] \centering ...
5
votes
2answers
179 views

Pgfplots gives spurious lines in external mode with geometry

This is not a major problem but all the same I would like to confirm that I am not doing anything wrong. Geometry package with showframe=true option is used to see if all the figures are within the ...
8
votes
2answers
390 views

How to ensure consecutive diagonal arrows form a straight line?

How can I ensure that consecutive diagonal arrows in a tikz-cd commutative diagram spanning many rows and columns lie on a straight line (as is automatically the case for consecutive horizontal ...
7
votes
1answer
1k views

tikzscale and histograms in pgfplots

Tikzscale is giving wrong results for histograms drawn in pgfplots. Histogram without scaling by tikzscale: Histogram after scaling: I have included a histogram from page 67 from pgfplots manual ...
5
votes
1answer
686 views

\resizebox shifts tikzpicture up when in a subfloat environment

Why when I try to re-scale a tikz figure using \resizebox the baseline is shifted up (regardless of how small the scale factor is), and two horizontal floats are not aligned properly. ...
5
votes
1answer
404 views

tikzpicture log-log histogram

I am trying to create a graph with TikZ similar to this image (link: http://www.flickr.com/photos/68902462@N08/8340520199/in/photostream) It is a histogram whose axes are in logarithmic scale. I ...
3
votes
1answer
366 views

TikZ External and tikzscale: Figure is regenerated every time

I am using tikzscale with tikz external library in the list and make mode. Before using tikzscale, if I issued make -f main.makefile command, only the figures that were not present would be generated. ...
5
votes
3answers
335 views

Correct way of test blank element in array

I'm trying to test whether an element in a defined list (array) is "empty." I tried using the \empty macro, or putting white spaces inside the quote, but nothing seems to work. I'm testing the ...
10
votes
1answer
366 views

Glitch in 'Cool text highlighting'

This answer provides a fantastic "ragged text highlight". Unfortunately I'm getting a weird glitch with it: I have literally taken the source code from the link and replaced the material between ...
6
votes
3answers
582 views

Putting a coloured background behind text without adding whitespace

Consider this: I want to be able to highlight text like this without adding space around it -- so each word in the first line should line up with the corresponding word in the second line. (I know ...
7
votes
1answer
893 views

Tikz: Avoiding line segments in snake path

I am using tikz to draw Feynman diagrams, and I learned how to draw a curved snake path. The problem is that in general line segments are present (I'd like to avoid them). I found a couple of post ...
7
votes
1answer
147 views

How to use tikz to draw an angle with the same degree of an existing one?

\begin{tikzpicture} \tikzset{mypoints/.style={fill=white,draw=black}} \tikzstyle{help lines}+=[very thin] \coordinate[label={[label distance=0.5em]180:$A$}] (A) at (120:5); ...
4
votes
1answer
126 views

Special \boxed environment

My problem is the following: I have a tikz picture: I want those boxes to all have the same height, and I also want them to start completely at the bottom like the box in the top right corner. ...
8
votes
1answer
3k views

Curved waved lines with TikZ

I'm trying to write a code for Feynman diagrams with TikZ (I know it is a common subject in the forum). I found very useful posts. However, I would like to draw a curved waved line ...
3
votes
1answer
513 views

Does tikz work in wrapfigure environment?

I tried to use tikz in wrapfigure and received the errors below:
5
votes
3answers
539 views

How to label or dimension a circle radius in TikZ?

I have a circle in the picture... How to add dimension of radius... form center of the circle to any point on the circle? Rotation is not giving what i want... \documentclass[10pt]{article} ...
27
votes
2answers
418 views

Align nodes containing numbers on the decimal separators

In a plot, I have several vertically distributed nodes containing numbers with different numbers of digits before and after the decimal separator, and a trailing percent sign. I would like to align ...
1
vote
0answers
478 views

3D surface in pgfplots with given data [closed]

I am trying to make a 3D surface in pgfplots with input data. I am not able to get the expected graph. I would highly appreciate if you could point out to me what I am missing. ...
7
votes
1answer
408 views

Fine-tuning a commutative diagram

I am trying to type the following simple commutative diagram in LaTeX. I have the basics, but I need for the V to be centered, and for the arrow under the g to be in the opposite direction. ...
20
votes
3answers
411 views

Strange behaviour with PGF/TikZ and Plain TeX output routine

I noticed a strange behavior when running PGF/tikZ with pdfTeX on my Debian box : a simple session without tikz: pdftex **\relax *Hello World *\bye do output the page number on the page footer. On ...
9
votes
2answers
2k views

How to draw an Icosahedron?

After going through the pgf manual and also searching the web for some solution or at least a hint on how it can be done (preferably using TikZ), so I came here with my question: How to draw an ...
42
votes
2answers
2k views

Text spirals with TikZ

I just ran across this, and I'm curious about whether it can be replicated in TeX... Ideally one would have the spiral getting tighter and tighter as one got to the centre, as in I know TikZ has ...
4
votes
1answer
568 views

Long label for a tikz picture (Having multiple line label for a tikz shape)

I have trouble making a tikz picture label break into couple lines. Here is specific MWE: \documentclass{article} \usepackage[latin1]{inputenc} \usepackage{tikz} ...
9
votes
1answer
850 views

Speeding up latex/lua/tikz

I have a rather large LaTeX document in that it generates a lot of LaTeX code using lua (small .tex file on disk but large amount of generated LaTeX code). It is very slow to compile and takes about 1 ...
16
votes
2answers
4k views

equilateral triangle in tikz

I was wondering if there is a way to define an equilateral triangle in tikz. I am aware that there is a predefined isosceles triangle in tikz. Specifically I'd like to define a \tikzstyle for ...