Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit ee64f0a

Browse files
committed
Small adjustment
1 parent 0a98b59 commit ee64f0a

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

handout-tips.tex

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,7 @@ \subsection*{\rmfamily Multiline plot}
163163

164164
% -----------------------------------------------------------------------------
165165
\subsection*{\rmfamily Dotted lines}
166-
To have rounded dotted line, use custom {\ttfamily linestyle} and
166+
To have rounded dotted lines, use a custom {\ttfamily linestyle} and
167167
modify {\ttfamily dash\_capstyle}.
168168
\begin{lstlisting}
169169
plt.plot([0,1], [0,0], "C1",
@@ -202,11 +202,11 @@ \subsection*{\rmfamily Colorbar adjustment}
202202
\raisebox{-0.75em}{\includegraphics[width=\linewidth]{tip-colorbar.pdf}}
203203
\end{tabular}
204204

205-
\subsection*{\rmfamily Take advantage of typography}
205+
\subsection*{\rmfamily Taking advantage of typography}
206206
You can use a condensed face such as Roboto
207207
Condensed to save space on tick labels.
208208
\begin{lstlisting}
209-
for tick in ax.get_xticklabels():
209+
for tick in ax.get_xticklabels(which='both'):
210210
tick.set_fontname("Roboto Condensed")
211211
\end{lstlisting}
212212
\includegraphics[width=\linewidth]{tip-font-family.pdf}

scripts/tip-font-family.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ def setup(ax):
4040
ax.xaxis.set_minor_formatter(ticker.ScalarFormatter())
4141
ax.tick_params(axis='x', which='minor', rotation=0)
4242

43-
for tick in ax.get_xticklabels():
43+
for tick in ax.get_xticklabels(which='both'):
4444
tick.set_fontname("Roboto Condensed")
4545

4646
plt.tight_layout()

0 commit comments

Comments
 (0)