Closed muzimuzhi closed 7 months ago
Describe the bug
The second example in section "Bar Plots" looks different than that in PDF, sec. 4.5.4 "Bar Plots".
Current link: https://tikz.dev/pgfplots/reference-2dplots#sec-16.4. This link will change when #27 is solved.
Screenshots
Analysis
Compile this example raises an error
! Package tikz Error: You need to say \usetikzlibrary{patterns}.
Adding that library solves the problem.
\documentclass{article} \usepackage{pgfplots} \pgfplotsset{width=7cm,compat=1.18} \usetikzlibrary{patterns} \begin{document} % Preamble: \pgfplotsset{width=7cm,compat=1.18} \begin{tikzpicture} \begin{axis}[xbar,enlargelimits=0.15] \addplot [draw=blue, pattern=horizontal lines light blue, ] coordinates { (10,5) (15,10) (5,15) (24,20) (30,25) }; \addplot [draw=black, pattern=horizontal lines dark blue, ] coordinates { (3,5) (5,10) (15,15) (20,20) (35,25) }; \end{axis} \end{tikzpicture} \end{document}
Thank you for such a quick fix!
Describe the bug
The second example in section "Bar Plots" looks different than that in PDF, sec. 4.5.4 "Bar Plots".
Current link: https://tikz.dev/pgfplots/reference-2dplots#sec-16.4. This link will change when #27 is solved.
Screenshots
Analysis
Compile this example raises an error
Adding that library solves the problem.