von forenthomas » Mo 26. Aug 2019, 12:42
Hallo,
ich komme irgendwie nicht klar mit der Schriftgröße in Grafiken. Jetzt habe ich mal ein konkretes Beispiel:
Wenn ich in der Grafik eine (oder die?) Fläche füllen lasse, dann wird die Schrift vergrößert. Warum? Und wie kann ich das verhindern? Im Moment hantiere ich dann immer noch pro Grafik mit relativen Schriftgrößen (tiny, scriptsize und so) rum, aber das kann's ja irgendwie nicht sein. Wie geht ihr mir Schriftgrößen in Grafiken um?
\documentclass[a4paper, parskip=half, 11pt]{scrartcl}
\usepackage{tikz}
\usepackage{pgfplots}
\pgfplotsset{compat=1.16}
\usepgfplotslibrary{fillbetween}
\begin{document}
\begin{center}
\begin{tikzpicture}[scale=0.7]
\begin{axis}[
axis lines=middle,
domain=0:42,
]
\addplot[name path = N] {-0.8*\x+38.5} node[pos = 0.18,anchor = south west] { $y = -0.8x + 38.5$};
\addplot[name path = A] {0.9*\x+4.5} node[pos = 0.2,anchor = north west] {$y = 0.9x + 4.5$};
\addplot[name path = T1,domain=0:20, dotted] {22.5};
\addplot[gray!20] fill between [of=N and T1, soft clip={domain=0:20}];
\end{axis}
\end{tikzpicture}
\end{center}
\begin{center}
\begin{tikzpicture}[scale=0.7]
\begin{axis}[
axis lines=middle,
domain=0:42,
]
\addplot[name path = N] {-0.8*\x+38.5} node[pos = 0.18,anchor = south west] { $y = -0.8x + 38.5$};
\addplot[name path = A] {0.9*\x+4.5} node[pos = 0.2,anchor = north west] {$y = 0.9x + 4.5$};
\end{axis}
\end{tikzpicture}
\end{center}
\end{document}
Für jeden Erkenntnisgewinn dankbar,
Thomas
Hallo,
ich komme irgendwie nicht klar mit der Schriftgröße in Grafiken. Jetzt habe ich mal ein konkretes Beispiel:
Wenn ich in der Grafik eine (oder die?) Fläche füllen lasse, dann wird die Schrift vergrößert. Warum? Und wie kann ich das verhindern? Im Moment hantiere ich dann immer noch pro Grafik mit relativen Schriftgrößen (tiny, scriptsize und so) rum, aber das kann's ja irgendwie nicht sein. Wie geht ihr mir Schriftgrößen in Grafiken um?
[code]\documentclass[a4paper, parskip=half, 11pt]{scrartcl}
\usepackage{tikz}
\usepackage{pgfplots}
\pgfplotsset{compat=1.16}
\usepgfplotslibrary{fillbetween}
\begin{document}
\begin{center}
\begin{tikzpicture}[scale=0.7]
\begin{axis}[
axis lines=middle,
domain=0:42,
]
\addplot[name path = N] {-0.8*\x+38.5} node[pos = 0.18,anchor = south west] { $y = -0.8x + 38.5$};
\addplot[name path = A] {0.9*\x+4.5} node[pos = 0.2,anchor = north west] {$y = 0.9x + 4.5$};
\addplot[name path = T1,domain=0:20, dotted] {22.5};
\addplot[gray!20] fill between [of=N and T1, soft clip={domain=0:20}];
\end{axis}
\end{tikzpicture}
\end{center}
\begin{center}
\begin{tikzpicture}[scale=0.7]
\begin{axis}[
axis lines=middle,
domain=0:42,
]
\addplot[name path = N] {-0.8*\x+38.5} node[pos = 0.18,anchor = south west] { $y = -0.8x + 38.5$};
\addplot[name path = A] {0.9*\x+4.5} node[pos = 0.2,anchor = north west] {$y = 0.9x + 4.5$};
\end{axis}
\end{tikzpicture}
\end{center}
\end{document}[/code]
Für jeden Erkenntnisgewinn dankbar,
Thomas