Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions doc/generic/pgf/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
### Fixed

- `sloped` should consider the current transformation #1058
- Use `render instead` for the `colormixin` example #1134

### Changed

Expand Down
37 changes: 30 additions & 7 deletions doc/generic/pgf/pgfmanual-en-xxcolor.tex
Original file line number Diff line number Diff line change
Expand Up @@ -33,18 +33,41 @@ \section{Extended Color Support}
|90!blue| will mix in 10\% of blue into everything, whereas |25!white| will
make everything nearly white.
%
\begin{codeexample}[width=4cm,preamble={\usepackage{xxcolor}}]
\begin{codeexample}[%
width=4cm,
preamble={\usepackage{xxcolor}},
% We use render instead with the exact same content here, because the normal
% codeexample is rendered in hmode with \catcode`\^^M=9 which ignores all line
% endings instead of converting them to spaces. Using \catcode`\^^M=10 in
% contrast would correctly convert line endings to spaces, but that leads to
% spurious spaces because of how the example is absorbed token-by-token by the
% renderer. Sigh...
render instead={%
\begin{minipage}{3.5cm}\raggedright
\color{red}Red text,
\begin{colormixin}{25!white}
washed-out red text,
\color{blue}washed-out blue text,
\begin{colormixin}{25!black}
dark washed-out blue text,
\color{green}dark washed-out green text,
\end{colormixin}%
back to washed-out blue text,
\end{colormixin}%
and back to red.
\end{minipage}%
}]
\begin{minipage}{3.5cm}\raggedright
\color{red}Red text,%
\color{red}Red text,
\begin{colormixin}{25!white}
washed-out red text,
\color{blue} washed-out blue text,
\color{blue}washed-out blue text,
\begin{colormixin}{25!black}
dark washed-out blue text,
\color{green} dark washed-out green text,%
\end{colormixin}
back to washed-out blue text,%
\end{colormixin}
\color{green}dark washed-out green text,
\end{colormixin}%
back to washed-out blue text,
\end{colormixin}%
and back to red.
\end{minipage}%
\end{codeexample}
Expand Down
2 changes: 1 addition & 1 deletion doc/generic/pgf/pgfmanual-test.tex
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,6 @@

\begin{document}

\include{pgfmanual-en-pgfkeys}
\include{pgfmanual-en-xxcolor}

\end{document}
Loading