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)

12
votes
1answer
451 views

How to inverse top and bottom ?

I would like to get 100 "above" the radius, if I consider that the radius comes from the center towards the circle. A little example : \documentclass[landscape]{scrartcl} \usepackage{tikz} \begin{...
4
votes
1answer
959 views

Curiosity - 3D animation in TikZ

Is it possible to create animations shown in the link below in TikZ http://ubcsanskrit.ca/lesson2/writingtutor.html to start animation click on any of the letters on the page. I know it may not be ...
31
votes
2answers
961 views

An Example from the Microtype Documentation

While exploring the depths of the microtype package with regard to LuaTeX I came across this innocent looking page 18 from the microtype.pdf 2.5 beta-08. As the blue note in the margins hints a ...
1
vote
1answer
390 views

tikz code doesn't compile when opened after a while

I finished my phd a couple of months ago, compiled it then completely just fine. I opened it today to make changes and during compilation I get error messages about "missing number treated as zero". I ...
9
votes
2answers
4k views

Defining variables in TikZ

I'm trying to define random variables - for example to draw some random points of the form (r,r) when r is a random number. I tried \def\myrandomnumber{rnd}, but that seems to give me a new random ...
6
votes
1answer
2k views

Decorating (with random steps) a filling pattern

\fill[pattern=north east lines] (A,B) rectangle (C,D); How to make so that the stripe the pattern creates is of style decoration = {random steps, segment length = 0.5mm, amplitude = 0.15pt}
3
votes
2answers
534 views

Why is tikz so much slower when plotting a huge amount of data than WYSIWYG plotting tools?

I was wondering why a tikz/pgf plot of a data file containing several thousand data points needs a couple of minutes to compile while creating the same plot with a WYSIWYG plotting tool (like Grace) ...
7
votes
3answers
956 views

Help on TikZ diagram

I'm very sorry about dull question, but I am totally confused by TikZ. Would anyone help me to draw following diagram, please? What I've done so far is as follows. \documentclass{article} \...
13
votes
1answer
5k views

TikZ Styles that set Nodepart Styles

In the following, I'm using user-defined macros to set the type style for the nodeparts for class nodes (\texttt{\textbf{#1}}), interfaces (\texttt{\textit{#1}}). Using the \tikzset command I also ...
10
votes
3answers
2k views

Tikz fit-library vs fill (overlaying nested node colors)

I am trying to figure out the best way of nesting tikz nodes having a different background color. I would like the "inner" nodes to "win" concerning the background color. Currently the "outer" node ("...
12
votes
1answer
4k views

Bending arrows in Tikz

In Tikz, I would like to bend an arrow like the one between $H_2O$ and $O_2$ in this figure: I'm able to have a bended line between $H_2O$ and $O_2$, but it's not touching the photophosphorylation ...
8
votes
1answer
2k views

circuitikz labeling

I am trying to create a few logic circuits for a class that I teach. After brief investigation I decided to use TikZ library circuit due to the lack of the support by PSTricks for American notation. ...
32
votes
3answers
11k views

Using math in TikZ

I know it has been asked and answered before, and I need to put { and } around it, but for some reason this doesn't work: \draw (0,0) -- ({atan(1)}:{sqrt(2)}); Any idea why?
16
votes
2answers
2k views

How can I draw a tangent ending smoothly in a circle?

I'm trying to draw a tanget on a circle, but I'm not happy with the result I get from the tangent option. particularly, I'd like to have the lines ending smoothly in the circle. The problem is ...
4
votes
2answers
479 views

How to generate labels next to junctions and avoid self-collision with tikz?

I have an ASCII-art phylogenetic tree that looks (in part) like /------ PLN /-----+ 0.9 | \------ IL1 /--------+ 1.8 | | /----- PVD | ...
6
votes
2answers
1k views

Drawing a rectangle along the border of a circle

I would like to draw a rectangle along the border of a circle. The \draw with the \angle operation might do it, but it is rather cumbersome. I was wondering if there is another more elegant/shorter ...
8
votes
2answers
1k views

Dependency diagrams using Tikz

I'm trying to draw a database dependency diagram, similar to the one shown below (Gaaah! I can't upload images. ASCII art it is then...) +------+------+------+------+------+------+ | | ...
36
votes
1answer
4k views

optional arguments to tikzpicture to set style globally

I can't get my head around how to get tikz and pgfkeys to do what I want. I would like to define a command which draws a little tikz picture. I'd like this command that would take optional keyval ...
8
votes
1answer
268 views

from the pgf Basic Layer to the pgf System Layer

I would like to translate a code from the pgf Basic Layer to the pgf System Layer. My first code is : \documentclass{scrartcl} \usepackage{tikz} \begin{document} a\fbox{\begin{tikzpicture} \...
7
votes
1answer
1k views

Reusing TikZ Path Definition

I'd like to know if somebody know a way to define a path in TikZ and reuse the path's definition several times. For example, consider the following: If I wanted to change the path (0,2) -- (0,2) -- ...
7
votes
2answers
2k views

Tikz mindmaps sharing children

Is it possible to have two mindmaps that share children? This is what I would like to have: Concept 1 is blue, and has some children. Concept 2 is red, and has some children. Concept 1 and two ...
11
votes
1answer
3k views

Table typesetting with pgfplotstable

I have two questions concerning pgfplotstable and number formatting with pgf. Consider the following piece of code: \documentclass{article} \usepackage{pgfplotstable} \usepackage{amsmath} \begin{...
44
votes
4answers
13k views

Draw mechanical springs in TikZ

Currently I am using the following path style to draw springs in TikZ \tikzstyle{spring}=[thick,decorate,decoration={zigzag,pre length=0.1cm,post length=0.1cm,segment length=6}] for example \...
5
votes
1answer
2k views

Align arrow to text box with Tikz?

I'm new to TikZ, and I can't seem to figure out how to align lines to a text box. In the figure below, the bottom arrow is aligned exactly how I would like (from the upper right corner of box C to ...
7
votes
3answers
3k views

How to Intersect an arc with a line without calculating the angle

I'd like to draw an optics-related figure, for which I need to draw several beams with varying opening angles, which will need to be labeled. What I've come up at the moment (boiled down to a minimal ...
5
votes
1answer
313 views

Width of empty multi-part node segment larger than expected

If I draw the following node, I'd expect to get four squares: \documentclass{article} \usepackage{tikz} \usetikzlibrary{shapes.multipart} \begin{document} \begin{tikzpicture}[multibox/.style={draw, ...
6
votes
1answer
3k views

why does latex report errors when using styles in a tikz pgf picture?

I get three errors when attempting to build the following example (with the tikzpicture taken from the tikz pgf manual). Why does this happen, and what am I doing wrong? \documentclass[12pt]{article} ...
3
votes
2answers
778 views

Wrong TikZ filepaths when included used input

I'm using TikZ for my thesis but have run into a small problem. In order to maintain some overview of the main tex file I have split all images into separate TikZ files (This also allows me to edit ...
2
votes
3answers
3k views

Help to plot a surface

I would like to plot the surface $S=\{(x,y,z)\in\mathbb{R}^3\ z=xy\}$ for an exercise of affine geometry but I am a novice in graphics! Can I use GeoGebra? or TikZ or Asymptote?
22
votes
1answer
6k views

Is there a Tikz library for network symbols?

Is there a Tikz library for network symbols? For example: Server Database Firewall PC Laptop etc...
6
votes
1answer
3k views

Adding Arrows to Lines Drawn in TikZ

I am using the markup listing from Draw comparison lines between two listings. \documentclass{article} \usepackage{listings}% http://ctan.org/pkg/listings \usepackage{tikz}% http://ctan.org/pkg/pgf \...
10
votes
1answer
2k views

Draw in pgfplot axis before axis and grid are drawn

Is there a way to draw something using the axis coordinates (axis cs:x,y) before the axis and the grid are drawn? Namely I would like to draw rectangles with tikz to give different areas of the plot ...
3
votes
2answers
757 views

How can I draw an arc with varying line thickness?

I'm trying to redraw existing figures with TikZ as an exercise to learn it. This time I have choosen an interesting logo and I'm having difficulties drawing the arc. Here is the logo I noticed that ...
2
votes
1answer
2k views

Why does 'every node' not work inside a scope environment?

I just tried the following and was suprised it didn't work: \begin{tikzpicture} ... some commands \begin{scope}[very thick, every node=./style={circle, fill=white, minimum size=1.2mm, inner ...
6
votes
1answer
2k views

Remove top and bottom margins around listings

When using the lstlisting environment, or similar ones from the listings package, there are paragraph-like margins above and below the actual text. This makes sense in a paper, but gets in the way if ...
5
votes
1answer
2k views

Naming coordinates in a foreach loop

I have the following problem: I am using beamer together with tikz, and I want to use some random points in a drawing which is shown over a couple of slides. If I use the normal random method, the ...
10
votes
3answers
981 views

How can I make circle plots?

I have not idea how to call these things, but I just saw a paper with the following figure and I was wondering how one would go about doing it in LaTeX. The closest thing I saw on TeXample.net was ...
9
votes
5answers
5k views

Place a TikZ picture on every page

I am looking to place a picture (TikZ picture) on every page of my document. How can I do that? In essence I would like to control the placing of the image on even and odd pages. For example the ...
14
votes
3answers
5k views

TikZ picture on the entire frame in beamer without using overlays

I have a beamer presentation with several TikZ diagrams that spread across the entire frame, i.e., use the full screen size. I am using the overlay option to make sure the picture captures the entire ...
6
votes
1answer
1k views

Labeling a function's plot generated by “plot function” [duplicate]

Possible Duplicate: How to label a path drawn using tikz with \draw plot? Consider plotting a parabola using the following code: \begin{scope}[domain=-2:2] \draw[<->,color=green,line ...
12
votes
3answers
15k views

Gnuplot Setting the Number of Key Columns

I am having an issue setting the number of key (i.e., legend) columns using Gnuplot with the TiKz terminal. Here's a minimal working example of what I'm talking about: #!/usr/bin/env gnuplot set term ...
3
votes
1answer
817 views

Wrapping minted in a Tikz box with a command

I'm familiar with the Defining a command for a minted environment question. In addition to defining the mint parameters I also want to wrap the minted code inside a Tikz box for its nice looks. I've ...
7
votes
1answer
977 views

TikZ Layer Invisible

I'm trying to place an image in the background using TikZ layers but as soon as I enable the layers option, everything in the background layer disappears. I have no idea why. I found some hints about ...
3
votes
2answers
632 views

Changing colors of MATH functions and DRAWING lines

My problem is that I want my math functions and drawing illustrations to be in different colors. I want my colors to be defined at the beginning so they will automatically change the color of math and ...
3
votes
1answer
7k views

PGF/TikZ arrow line width not consistent with line width

I have a document I created several months back, and maybe with a new version of PGF/TikZ it is not working as previously (currently using Arch Linux, TexLive 2011, pgf version 2.10). The fast ...
6
votes
5answers
2k views

Macro to draw a parabola with pgf/TikZ

I have been trying to build a macro \parabola{...} to draw a parabola passing through 3 coordinates with TikZ but without success. For example \parabola{A}{B}{C} would draw the parabola ...
5
votes
1answer
577 views

How to align a vertical tree to the upper-left corner?

How do I align vertical trees to to the top? This is my current tree:       I want to get this tree:                  ^ That's a part of ...
3
votes
2answers
560 views

PDFLaTeX cannot produce shaded TikZ objects

\documentclass{article} \usepackage{tikz} \begin{document} \begin{tikzpicture} \shadedraw[draw=blue] (0,0) circle (1); \end{tikzpicture} \end{document} can produce a shaded circle when it is ...
19
votes
1answer
957 views

How do I pronounce “TikZ”?

I have heard people pronounce the name of the package "TikZ" in many different ways: "tiks" or "tikz" or "tik-zee" or even "tee-eye-kay-zee". Does anyone know the authoritatively correct ...
8
votes
1answer
2k views

Tikz - Drawing in the unit circle

I am working on learning how to use tikz for mathematical drawings and I am currently trying to make... well... if you read or typeset the code you will get the idea. If you look at the results the ...