2

Here's an excerpt clipped from a nice, colourful executive summary.


enter image description here


This is the kind of thing that word processors seem to be really good at. There's often a bunch of presets that you can just browse through using the GUI, pick a theme, and modify it until you're happy. Whereas LaTeX is left looking a bit.. ordinary:


enter image description here


Don't get me wrong, it doesn't look bad. It's very sensible. Maybe too sensible. It's just boring by comparison. Which isn't ideal for an executive summary. What can I do to get my LateX version looking a bit more like the first one? It's okay to not look exactly the same, because on the other hand, it's always nice to avoid that "Eww. MS Word" aesthetic, if you know what I mean.Perhaps we can achieve a healthy balance. I'm also working on pie charts, hyper-colourful diagrams, and other minor (debatable) typesetting faux pas. Anyway, Lacklustre MWE follows:


%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\documentclass{article}
\usepackage{booktabs,array,arydshln}
\setlength\dashlinedash{0.2pt}
\setlength\dashlinegap{1.5pt}
\setlength\arrayrulewidth{0.3pt}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\begin{document}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\huge\centering\noindent
10.0.0.8 \\
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\large\phantom{|} \\\centering\noindent
\begin{tabular}{ccccc}
\toprule                              %%
11       & 83   & 110    & 8   & 0    \\
\midrule                              %%
CRITICAL & HIGH & MEDIUM & LOW & INFO \\
\bottomrule                           %%
\end{tabular} 
\\ \phantom{|} \\
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\small\centering\noindent
\begin{tabular}{llll}
\toprule                                                                %%
SEVERITY & CVSS & PLUGIN & NAME                                         \\
\midrule                                                                %%
CRITICAL & 10.0 & 82138 & Debian DLA-155-1 : linux 2.6 security update  \\\hdashline
CRITICAL & 10.0 & 82139 & Debian DLA-156-1 : samba security update      \\\hdashline
CRITICAL & 10.0 & 82718 & Debian DLA-195-1 : libtasn1-3 security update \\\hdashline
CRITICAL & 10.0 & 84061 & Debian DLA-239-1 : cups security update       \\\hdashline
CRITICAL & 10.0 & 85808 & Debian DLA-307-1 : php5 security update       \\
\bottomrule                                                             %%
\end{tabular}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\end{document}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
voices
  • 2,039
  • Please change your posting's title so that it doesn't come across as pure clickbait. E.g., "How to convey quantitative information in tabular format using lots of colors" would be more appropriate. – Mico Oct 29 '19 at 11:56
  • You want to make advertisement flyers with LaTeX? ;o) – Bernard Oct 29 '19 at 11:59
  • @Bernard Nah, not advertisements. Although I suppose it's not so different really. The executive summary has to grab and direct the attention of upper management and executive officers; people with less time or perhaps shorter attention spans, and less interest in the finer technical details. So we try to condense the report into one or two pages in a way that kind of resembles a Pinterest-style infographic that says "this stuff happened!". What follows is a typical report that elaborates and says "..and this is how and why.". – voices Oct 29 '19 at 12:50
  • If you REALLY want a captivating executive summary, try https://tex.stackexchange.com/questions/29402/how-do-i-make-my-document-look-like-it-was-written-by-a-cthulhu-worshipping-madm – John Kormylo Oct 29 '19 at 13:50

1 Answers1

4

Just read up on the use of the xcolor package. It gives the tools you need.

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\documentclass{article}
\usepackage{booktabs,array,arydshln,xcolor}
\setlength\dashlinedash{0.2pt}
\setlength\dashlinegap{1.5pt}
\setlength\arrayrulewidth{0.3pt}
\newcommand\colbox[2]{\colorbox{#1}{\makebox[60pt]{\rule[-10pt]{0pt}{30pt}%
  \textcolor{white}{\large\sffamily\bfseries#2}}}}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\begin{document}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\huge\centering\sffamily
10.0.0.8 \\
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\large\phantom{|} \\\centering\noindent
\begingroup\tabcolsep=0pt
\scriptsize
\begin{tabular}{ccccc}
\toprule                              %%
\colbox{red}{11}       & \colbox{orange}{83}   & \colbox{yellow!95!black}{110}
     & \colbox{green}{8}   & \colbox{blue!50}{0}    \\
\midrule                              %%
CRITICAL & HIGH & MEDIUM & LOW & INFO \\
\bottomrule                           %%
\end{tabular}
\endgroup 
\\ \phantom{|} \\
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\begingroup
\renewcommand\arraystretch{1.5}
\small\centering\noindent
\begin{tabular}{llll}
\toprule                                                                %%
SEVERITY & CVSS & PLUGIN & NAME                                         \\
\midrule                                                                %%
\colorbox{red}{CRITICAL} & 10.0 & \textcolor{blue}{82138} 
  & Debian DLA-155-1 : linux 2.6 security update  \\\hdashline
\colorbox{red}{CRITICAL} & 10.0 & \textcolor{blue}{82139} 
  & Debian DLA-156-1 : samba security update      \\\hdashline
\colorbox{red}{CRITICAL} & 10.0 & \textcolor{blue}{82718} 
  & Debian DLA-195-1 : libtasn1-3 security update \\\hdashline
\colorbox{red}{CRITICAL} & 10.0 & \textcolor{blue}{84061} 
  & Debian DLA-239-1 : cups security update       \\\hdashline
\colorbox{red}{CRITICAL} & 10.0 & \textcolor{blue}{85808} 
  & Debian DLA-307-1 : php5 security update       \\
\bottomrule                                                             %%
\end{tabular}
\endgroup
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\end{document}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

enter image description here