# Filling Text with Pattern

Text can be colored:

\documentclass{standalone}
\usepackage{xcolor}
\begin{document}
{\textcolor{green}{\Large I}}
\end{document}


Areas can be filled with patterns:

\documentclass{standalone}
\usepackage{tikz}
\usetikzlibrary{patterns}
\begin{document}
\begin{tikzpicture}
\draw[pattern=bricks, pattern color=green] (0,0) -- (0,1) -- (1,1) -- (1,0) -- cycle;
\end{tikzpicture}
\end{document}


How could you fill letters or symbols with a pattern?

For example, an "I" filled with green bricks would look something like this:

\documentclass{standalone}
\usepackage{tikz}
\usetikzlibrary{patterns}
\begin{document}
\begin{tikzpicture}
% shouldn't need to trace a symbol!
\draw[pattern=bricks, pattern color=green] (0,0) -- (3,0) -- (3,1) -- (2,1) -- (2,3) -- (3,3) -- (3,4) -- (0, 4) -- (0,3) -- (1,3) -- (1,1) -- (0,1) -- cycle;
\end{tikzpicture}
\end{document}


Conceptually this is very similar to this answer.

\documentclass{article}
\usepackage{tikz}
\begin{document}
\newcommand\textpattern[2][pattern=bricks]{%
\node [text=transparent!0,scale=10,font=\bfseries\sffamily] {#2};
\begin{tikzpicture}
\node [opacity=0,scale=10,font=\bfseries\sffamily] (aux) {#2};

• @anonymous_pigeon Yes, more or less. #1 are keys that control the pattern, and the default is pattern=bricks. #2 is the text, as you say. There are many ways in which you could write the command, and one may use pgf keys to make it more flexible. – user121799 Aug 7 '19 at 20:22