-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtikz06.tex
50 lines (46 loc) · 1.42 KB
/
tikz06.tex
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
\documentclass[12pt]{article}
\usepackage{tikz}
\usetikzlibrary{shadings,patterns}
\author{Binit Pandit}
\title{Drawing in \LaTeX\ using PGF/TikZ}
\date{}
\begin{document}
\maketitle\vskip-25pt\hrule\vskip10pt
%\begin{tikzpicture}[options]
%\path[optional1][optional1] <specifications> ;
%\end{tikzpicture}
\begin{tikzpicture}
\draw (0,0) rectangle (3,4);
\end{tikzpicture}
\vskip25pt
\begin{tikzpicture}
\fill[color=yellow] (0,0) rectangle (3,4);
\end{tikzpicture}
\vskip25pt
\begin{tikzpicture}
\fill[color=yellow] (0,0) rectangle (3,4);
\draw[color=red] (0,0) rectangle (3,4);
\end{tikzpicture}
\vskip25pt
\begin{tikzpicture}
%\shade[shading=ball] (0,0) rectangle (3,4);
\shade[left color = red, right color = blue] (0,0) rectangle (3,4);
\draw (0,0) rectangle (3,4);
\end{tikzpicture}
\vskip25pt
\begin{tikzpicture}
\fill [color=magenta] (0,0) circle[radius=1cm] (1,0) circle[radius=1cm];
\draw (0,0) circle[radius=1cm] (1,0) circle[radius=1cm];
\end{tikzpicture}
\vskip25pt
\begin{tikzpicture}
\fill [color=magenta, even odd rule] (0,0) circle[radius=1cm] (1,0) circle[radius=1cm];
\draw (0,0) circle[radius=1cm] (1,0) circle[radius=1cm];
\end{tikzpicture}
\vskip25pt
\begin{tikzpicture}
%\pattern [pattern=dots] (0,0) rectangle (3,4);
\pattern [pattern=fivepointed stars,pattern color = red] (0,0) rectangle (3,4);
\draw [color=red] (0,0) rectangle (3,4);
\end{tikzpicture}
\end{document}