I have this graph where the times above the nodes is the departure time. How can I format the "+1" better? It stands for the "next day". Now is too big with respect to the time, and also the 'plus' is exaggerated. I was trying to put the "+1" smaller and maybe with a different colour.
How can I achieve this? Thanks!
EDIT: How can I also reduce the white part that covers each edges? (the part in the middle of the edge covered by a number)
\documentclass[margin=10pt]{standalone}
\usepackage{color,xcolor}
\usepackage{tikz-qtree, tikz}
\usepackage{pgfplots}
\usepackage[utf8]{inputenc}
\usetikzlibrary{decorations.pathreplacing,arrows,shapes,positioning,shadows,calc}
\usetikzlibrary{decorations, decorations.text,backgrounds}
\tikzset{every picture/.style={font issue=\footnotesize},
font issue/.style={execute at begin picture={#1\selectfont}}
}
\pgfplotsset{width=10cm,compat=1.17}
\usepgfplotslibrary{fillbetween}
\usetikzlibrary{arrows.meta}
\usetikzlibrary{positioning}
\usepackage{clock}
\usepackage[clock]{ifsym}
\ClockFrametrue\ClockStyle=0
\newcommand{\orig}{\mathcal{O}} % origin position
\newcommand{\dest}{\mathcal{D}} % destination position
\begin{document}
\begin{tikzpicture}
\begin{scope}[every node/.style={circle,thick,draw}]
\node[fill=red!30] (Orig) at (0,0) {$\orig$};
\node (A) at (2,2) {A};
\node (B) at (2.3,0.5) {B};
\node (C) at (3.3,-1.2) {C};
\node (H) at (4.2,2.1) {H};
\node (L) at (6.4,-0.5) {L};
\node (E) at (5.9,1.9) {E} ;
\node[fill=green!30] (Dest) at (8,1) {$\dest$};
\end{scope}
\begin{scope}[>={stealth[black]},
every node/.style={fill=white,circle},
every edge/.style={draw=red,very thick}]
\path [->] (Orig) edge node {$5$} (A);
\path [->] (A) edge node {$5$} (H);
\path [->] (H) edge node {$3$} (E);
\path [->] (E) edge node {$8$} (Dest);
% \path [->] (B) edge[bend right=60] node {$1$} (E);
\end{scope}
\begin{scope}[>={stealth[black]},
every node/.style={fill=white,circle},
every edge/.style={draw=black,very thick}]
\path [->] (Orig) edge node {$5$} (B);
\path [->] (Orig) edge node {$5$} (C);
\path [->] (B) edge node {$3$} (C);
\path [->] (B) edge node {$3$} (H);
\path [->] (B) edge node {$3$} (L);
\path [->] (C) edge node {$5$} (L);
\path [->] (E) edge node {$8$} (L);
\path [->] (L) edge node {$8$} (Dest);
\end{scope}
\begin{scope}[font=\tiny]
\node [above=0.5pt of A] {\clock{15}{30} 15:30};
\node [below=0.5pt of Orig] {\clock{18}{15} 18:15};
\node [above=0.5pt of H] {\clock{8}{30} 8:30$^{+1}$};
\node [above=0.5pt of E] {\clock{10}{45} 10:45$^{+1}$};
\node [above=0.5pt of Dest, align=center] {Arrive \\ \clock{12}{00} 12:00$^{+1}$};
\end{scope}
\matrix [draw,above left, row sep=1mm, nodes={font=\scriptsize}] at (current bounding box.north east) {
\node [circle, black, draw, label=right:Hotel] {H}; \\
\node [circle, black, draw, label=right:Lunch] {L}; \\
};
\end{tikzpicture}
\end{document}
inner sep=1pt
(or any size that suits you). For the clocks, you could scale them usingscale=0.8
in the node definition, for example.