Here is my code:
\documentclass[tikz]{standalone}
\usetikzlibrary{shapes,snakes}
\usepackage[html]{xcolor}
\definecolor{rot}{HTML}{e40303}
\definecolor{xorange}{HTML}{ff8c00}
\definecolor{gelb}{HTML}{ffed00}
\definecolor{gruen}{HTML}{008026}
\definecolor{blau}{HTML}{004dff}
\definecolor{lilla}{HTML}{750787}
\begin{document}
\begin{tikzpicture}[x=0.026458cm,y=0.026458cm]
\fill[fill=rot](0,0)rectangle(750,70);
\fill[fill=xorange](0,0)rectangle(750,140);
\fill[fill=gelb](0,0)rectangle(750,210);
\fill[fill=gruen](0,0)rectangle(750,280);
\fill[fill=blau](0,0)rectangle(750,350);
\fill[fill=lilla](0,0)rectangle(750,420);
\end{tikzpicture}
\end{document}
I don't know why it doesn't do what I wanted it to do. Hopefully some of you can help?
Kind regards!
Best Answer
Some comments :
xcolor
is loaded bytikz
, so don't reload it again,foreach
.Here is the code :