summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/hep-graphic/hep-plot.sty
blob: 3a64f41e47920e49f8c58c18b17b8240a8808b1d (plain)
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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
%%
%% This is file `hep-plot.sty',
%% generated with the docstrip utility.
%%
%% The original source files were:
%%
%% hep-graphic-implementation.dtx  (with options: `plot')
%% This is a generated file.
%% Copyright (C) 2019-2023 by Jan Hajer
%% This file may be distributed and/or modified under the
%% conditions of the LaTeX Project Public License, either
%% version 1.3c of this license or (at your option) any later
%% version. The latest version of this license is in:
%% http://www.latex-project.org/lppl.txt
%% and version 1.3c or later is part of all distributions of
%% LaTeX version 2005/12/01 or later.
\ProvidesPackage{hep-plot}[2023/07/01 v1.0 Plots in High Energy Physics]

\RequirePackage{tikz}
\tikzset{
 dashdotdotdotted/.style={dash pattern=on 3pt off 2pt
  on \the\pgflinewidth off 2pt on \the\pgflinewidth off 2pt
  on \the\pgflinewidth off 2pt
 },
 dashdotdotdotdotted/.style={dash pattern=on 3pt off 2pt
  on \the\pgflinewidth off 2pt on \the\pgflinewidth off 2pt
  on \the\pgflinewidth off 2pt on \the\pgflinewidth off 2pt
 },
}%
\pgfkeys{/pgf/number format/.cd,1000 sep={\,}}%
\RequirePackage{pgfplots}
\pgfplotsset{
 compat=newest,
 width=\linewidth,
 height=\linewidth,
 enlargelimits=false,
}
\pgfplotsset{
 every y tick scale label/.append style={
  inner sep=1pt,
  xshift=-1pt,
  yshift=-1pt,
 },
}
\pgfplotsset{
  legend style={font=\footnotesize},
  tick label style={font=\footnotesize},
  label style={font=\small},
  title style={font=\small},
  max space between ticks=30,
}
\pgfplotsset{
  three panels/.style={
    legend style={font=\scriptsize},
    tick label style={font=\scriptsize},
    label style={font=\footnotesize},
    title style={font=\footnotesize},
    max space between ticks=25,
    /tikz/mark size=1.5pt,
    major tick length=1mm,
    minor tick length=0.66mm,
    every axis title shift=0pt,
  },
}
\colorlet{darkgreen}{green!50!black}
\pgfplotscreateplotcyclelist{colors}{
 blue, red, darkgreen, violet, orange, yellow!25!orange,
 brown, black
}
\pgfplotscreateplotcyclelist{line styles}{
 solid, dashed, {densely dotted, semithick}, dashdotted,
 dashdotdotted, dashdotdotdotted, dashdotdotdotdotted
}
\pgfplotscreateplotcyclelist{marks}{
 -, |, Mercedes star flipped, Mercedes star, +, x, star,
 asterisk, 10-pointed star
}
\pgfplotscreateplotcyclelist{vertical marks}{
 |, Mercedes star flipped, Mercedes star, x, star,
 asterisk, 10-pointed star
}
\pgfplotscreateplotcyclelist{horizontal marks}{
 -, Mercedes star flipped, Mercedes star, x, star, %asterisk,
 10-pointed star
}
\pgfplotsset{
 cycle multiindex* list={colors\nextlist line styles},
}
\newcounter{cyclelistshift}
\newcommand\cyclelistshift{
  \globaldefs=1\relax
  \addtocounter{cyclelistshift}{1}
  \pgfplotsset{cycle list shift=\value{cyclelistshift}}
  \globaldefs=0\relax
}
\pgfplotsset{
 legend cell align=left,
 legend style={
  at={(1,1)},
  anchor=north east,
  inner sep=1pt,
  outer sep=6pt,
  draw=none,
  fill opacity=.9,
  draw opacity=1,
  text opacity=1,
  cells={align=left},
  /tikz/every even column/.append style={column sep=.5em},
 },
}
\pgfplotsset{
 contour legend/.style={
  contour prepared={labels=false},
  colorbar sampled line,
  colorbar style={
   mark size=7pt,
   mark options={semithick},
   tickwidth=0pt,
   subtickwidth=0pt,
   },
 },
}
\usepgfplotslibrary{colormaps}
\pgfplotsset{
 contour legend x/.style={
  colorbar horizontal,
  colormap/jet,
  contour legend,
  colorbar style={
   at={(0.5,1.025)},
   anchor=south,
   mark=|,
   axis x line*=top,
   axis y line=none,
   xticklabel pos=upper,
   title style={
    at={(-0.05,1)},
    anchor=east,
   },
   xlabel style={
    at={(-0.06,1)},
    anchor=south east,
   },
  },
 },
}
\pgfplotsset{
 contour legend y/.style={
  contour legend,
  colorbar style={
   at={(1.025,0.5)},
   anchor=west,
   mark=-,
   axis x line=none,
   title style={
    at={(1,-0.1)},
    anchor=north west,
   },
  },
 },
}
\pgfplotsset{
 contour plot x/.style={
  contour legend x,
  contour prepared={labels=false},
 },
 contour plot y/.style={
  contour legend y,
  contour prepared={labels=false},
 },
}
\pgfplotsset{
 error legend/.style n args={3}{
  legend image code/.code={
   \draw[draw=none,fill=#1,#3](0mm,-1mm)rectangle(6mm,1mm);
   \draw[draw=#1,#2] (0mm,0mm)--(6mm,0mm);
  }
 },
}
\newcommand{\addlegendtitle}[2][]{
 \addlegendimage{empty legend}
 \addlegendentry[#1]{\hspace{-7mm}#2}
}%

\endinput
%%
%% End of file `hep-plot.sty'.