![买者自负](https://linux22.com/image/350348/%E4%B9%B0%E8%80%85%E8%87%AA%E8%B4%9F.png)
答案1
找到一些你喜欢的汽车和公交车图标或图片。并将它们作为节点包含在内:
\documentclass[tikz,border=2mm]{standalone}
\usetikzlibrary{positioning, arrows.meta}
\begin{document}
\begin{tikzpicture}
\fill[green!70] (0,0) rectangle (10,2);
\fill[red!70] (0,0) rectangle (10,-2);
\draw[line width=1mm, dashed] (0,0)--(10,0);
\draw[line width=1mm] (0,2)--(10,2);
\draw[line width=1mm] (0,-2)--(10,-2);
\draw[-LaTeX, line width=.5mm] (.5,-1) --++(3,0) node[pos=.2, above] {Car lane};
\draw[-LaTeX, line width=.5mm, red] (.5,1) --++(3,0) node[pos=.2, above] {Bus lane};
\node at (5,1) {\reflectbox{\includegraphics[height=8mm]{bus-symbol-tobefree}}};
\node at (8,1) {\reflectbox{\includegraphics[height=8mm]{bus-symbol-tobefree}}};
\node at (5,-1) {\includegraphics[height=5mm]{carsymbol3-crop}};
\node at (6,-.35) {\includegraphics[height=5mm]{carsymbol3-crop}};
\node at (7,-1.25) {\includegraphics[height=5mm]{carsymbol3-crop}};
\node at (8,-0.7) {\includegraphics[height=5mm]{carsymbol3-crop}};
\node at (9,-1.4) {\includegraphics[height=5mm]{carsymbol3-crop}};
\end{tikzpicture}
\end{document}
答案2
请注意,我认为我不应该回答“为我做”,但有时还是会回答。当我回答时,我会严格按照原样回答。我为自己做,不会同情微调或解释的要求,除非我喜欢它们,并且不认为自己严格受限于问题中给出的任何要求、愿望或约束。如果它有用,那就是幸运的奖励;如果没有用,那就太难了。
买者自负
汽车是危险的、污染环境的、毁灭地球和心灵的东西。仅提供公共交通支持。
\begin{filecontents}{tikzlibrarytrambws.code.tex}
\ProvidesFile{tikzlibrarytrambws.code.tex}
\usetikzlibrary{backgrounds}
\colorlet{lliwytram}{red!75!black}
\colorlet{lliwffenestri}{gray!75!blue}
\colorlet{lliwolwynion}{gray!75}
\tikzset{
lliw y tram/.code={
\colorlet{lliwytram}{#1}
},
lliw ffenestri/.code={
\colorlet{lliwffenestri}{#1}
},
lliw olwynion/.code={
\colorlet{lliwolwynion}{#1}
},
olwyn/.style={circle, draw, line width=#1*.8pt, minimum width=#1*5pt, inner sep=0pt, fill=lliwolwynion},
pics/tram/.style={
code={
\path [draw, line width=#1*.8pt]
coordinate (tram) ++(-.2*#1,#1*2.75pt) node (w1) [olwyn=#1] {}
++(#1*.425,0) node (w2) [olwyn=#1] {}
++(#1*.425,0) node (w3) [olwyn=#1] {};
\path [draw, fill, line width=#1*.4pt]
(w1) circle (#1*1pt)
(w2) circle (#1*1pt)
(w3) circle (#1*1pt);
\path [draw, left color=lliwytram, right color=lliwytram!20, line width=#1*.4pt]
(tram) ++(-.4*#1,#1*1.5pt) coordinate (t1) |- ++(#1*1.25,#1*.35) coordinate (t2) |- (w3.south east -| w3.east) |- (w3.west) |- (w2.south east -| w2.east) |- (w2.west) |- (w1.south east -| w1.east) |- (w1.west) -- (w1.south west -| w1.west) -| cycle
(t1 -| t2) ++(-.05*#1pt,#1*4pt) coordinate (t3) |- ++(-.175*#1,#1*.175) coordinate (t4) |- cycle
(t3 -| t4) ++(-.5*#1pt,0) |- ++(-.25*#1,.175*#1) coordinate (t5) |- cycle
(t3 -| t5) ++(-.5*#1pt,0) |- ++(-.25*#1,.175*#1) coordinate (t6) |- cycle
(t3 -| t6) ++(-.5*#1pt,0) |- ++(-.25*#1,.175*#1) coordinate (t7) |- cycle
(t3 -| t7) ++(-.5*#1pt,0) |- ++(-.25*#1,.175*#1) coordinate (t8) |- cycle;
\scoped [on background layer] \fill [left color=lliwffenestri!50, right color=lliwffenestri!10] (t3) rectangle (t8);
}
}
}
\endinput
\end{filecontents}
\documentclass[border=10pt,tikz]{standalone}
\usetikzlibrary{trambws,fit,arrows.meta,calc}
\begin{document}
\begin{tikzpicture}[font=\sffamily]
\path (0,0) node (bl) [anchor=south east, text=magenta] {Bus lane} (2,0) [lliw ffenestri=gray!75!red, lliw olwynion=orange] pic {tram=1} ++(2,0) [lliw y tram=blue!50!cyan, lliw ffenestri=gray!75!blue, lliw olwynion=blue] pic {tram=1}++(2,0) [lliw y tram=green!75!black, lliw ffenestri=green!25!gray!75, lliw olwynion=magenta] pic {tram=1};
\draw [-Stealth, thick, magenta] (bl) -- +(2,0);
\begin{scope}[on background layer]
\node (g) [top color=green!50!black, bottom color=green!50!black, middle color=green!25, fit=(current bounding box.north west) (current bounding box.south east)] {};
\path (current bounding box.north west) coordinate (tl) (current bounding box.south east) coordinate (mr) (tl |- mr) coordinate (ml) (tl -| mr) coordinate (tr);
\shade [top color=red!50!black, bottom color=red!50!black, middle color=red!25] ($2*(ml)-(tl)$) coordinate (bl) rectangle (mr);
\end{scope}
\draw [double=black, double distance=3pt, draw=white] (tl) -- (tr) (bl) -- (bl -| mr) ;
\draw [line width=1.5pt, dashed, preaction={line width=1.5pt, draw=white}] (ml) -- (mr);
\end{tikzpicture}
\end{document}