-1

How can I draw something like this on latex:

enter image description here

I have seen this on Trying to do graphical decorations in "ClassicThesis style":

\begin{tikzpicture}[remember picture,overlay,shorten >= -10pt]

\coordinate (aux1) at ([yshift=-15pt]current page.north east);
\coordinate (aux2) at ([yshift=-410pt]current page.north east);
\coordinate (aux3) at ([xshift=-4.5cm]current page.north east);
\coordinate (aux4) at ([yshift=-150pt]current page.north east);

\begin{scope}[titlepagecolor!40,line width=12pt,rounded corners=12pt]
\draw
  (aux1) -- coordinate (a)
  ++(225:5) --
  ++(-45:5.1) coordinate (b);
\draw[shorten <= -10pt]
  (aux3) --
  (a) --
  (aux1);
\draw[opacity=0.6,titlepagecolor,shorten <= -10pt]
  (b) --
  ++(225:2.2) --
  ++(-45:2.2);
\end{scope}
\draw[titlepagecolor,line width=8pt,rounded corners=8pt,shorten <= -10pt]
  (aux4) --
  ++(225:0.8) --
  ++(-45:0.8);
\begin{scope}[titlepagecolor!70,line width=6pt,rounded corners=8pt]
\draw[shorten <= -10pt]
  (aux2) --
  ++(225:3) coordinate[pos=0.45] (c) --
  ++(-45:3.1);
\draw
  (aux2) --
  (c) --
  ++(135:2.5) --
  ++(45:2.5) --
  ++(-45:2.5) coordinate[pos=0.3] (d);   
\draw 
  (d) -- +(45:1);
\end{scope}
\end{tikzpicture}%

Can some give me an idea??

H.H
  • 826
  • 6
    And what's the relation with the code (taken from here and the figure you want? If you wanted to show some effort, I think this is not the best way. – Ignasi Nov 02 '16 at 10:53
  • 1
    Like what? There's nothing to indicate what you are trying to draw. – cfr Nov 02 '16 at 23:30
  • I've rolled back so that people don't have to view the revision history to figure out your question. It makes no sense to remove the image and just makes it seem very odd that anybody tried to answer at all. – cfr Nov 02 '16 at 23:33

2 Answers2

9

The graphics can be drawn as kind of double lines. First a very thick line is drawn with the color of the outer lines. Then the same path is used to draw the hell blue as inner line:

\documentclass{article}
\usepackage{tikz}
\usetikzlibrary{calc}
\usepackage{xcolor}
\begin{document}
\begin{tikzpicture}
  \def\Unit{30pt}
  \def\InnerLineWidth{8pt}
  \def\OuterLineWidth{2pt}
  \definecolor{OuterLineColor}{rgb}{.15, .15, .55}
  \definecolor{InnerLineColor}{rgb}{.55, .85, .97}
  \def\LineDrawing{%
    (0, 0) coordinate (A)
    \foreach \p/\a in {
      B/-30, C/30, D/-30, E/30,
      F/90, G/150, H/90, I/150,
      J/210, K/-90, L/210%
    } {
      -- ++(\a:\Unit) coordinate (\p)
    } -- cycle
    (A)
    \foreach \p in {A, B, C, D, E} {
      -- ($(\p) + (-90:\Unit)$) coordinate (\p2)
    }
    -- (E)
    \foreach \p in {E, F, G, H, I} {
      -- ($(\p) + (30:\Unit)$) coordinate (\p2)
    }
    -- (I)
    \foreach \p in {I, J, K, L, A} {
      -- ($(\p) + (150:\Unit)$) coordinate (\p2)
    }
    -- cycle
    \foreach \p in {
      B, C, D,
      F, G, H,
      J, K, L%
    } {
      (\p) -- (\p2)
    }
  }
  \draw[OuterLineColor, line width=\InnerLineWidth + 2 * \OuterLineWidth]
    \LineDrawing
  ;
  \draw[InnerLineColor, line width=\InnerLineWidth]
    \LineDrawing
  ;
\end{tikzpicture}
\end{document}

Result

Heiko Oberdiek
  • 271,626
4

To make the tridimensional shape you can use the xyz canvas and set the coordinate system as you like. The default is x=1cm, y=1cm and z=(-3.85mm,-3.85mm), to which the following code:

\coordinate (center) at (0,0);
\draw [->] (center) -- (1,0,0);
\draw [->] (center) -- (0,1,0);
\draw [->] (center) -- (0,0,1);

Results in:

Default tikz xyz coordinate system

It is possible to redefine this values like this:

\begin{scope}[z={(-8.66mm,-5mm)},x={(8.66mm,-5mm)}]
\coordinate (center) at (0,0);
\draw [->] (center) -- (1,0,0);
\draw [->] (center) -- (0,1,0);
\draw [->] (center) -- (0,0,1);
\end{scope}

Which results in a better coordinate system to draw the specified picture:

Redefined xyz coordinate system

Now, when using the xyz CS, the x, y and z axes will follow the previously defined increments, making it easier to draw the outer and inner shapes:

\documentclass{standalone}
\usepackage{tikz}
\usetikzlibrary{shapes.geometric,calc}
\definecolor{titlepagecolor}{RGB} {96,200,244}

\begin{document}
\begin{tikzpicture}
\coordinate (center) at (0,0);
\begin{scope}[z={(-8.66mm,-5mm)},x={(8.66mm,-5mm)},line width=2pt]
\fill[titlepagecolor!40, draw=blue!80!black] (center) ++(0,-2,0) --
               ++(0,0,1) --
               ++(-1,0,0) --
               ++(0,1,0) --
               ++(-1,0,0) --
               ++(0,1,0) --
               ++(0,0,-1) --
               ++(0,1,0) --
               ++(0,0,-1) --
               ++(1,0,0) --
               ++(0,0,-1) --
               ++(1,0,0) --
               ++(0,-1,0) --
               ++(1,0,0) --
               ++(0,-1,0) --
               ++(0,0,1) --
               ++(0,-1,0) --
               ++(0,0,1) -- cycle;
\fill[white, draw=blue!80!black] (center) ++(0,-0.8,0) --
               ++(0,0,1) --
               ++(-0.8,0,0) --
               ++(0,0.8,0) --
               ++(0,0,-1) --
               ++(0,1,0) --
               ++(0,0,-0.8) --
               ++(0.8,0,0) --
               ++(0,-1,0) --
               ++(1,0,0) --
               ++(0,-0.8,0) --
               ++(0,0,0.8) -- cycle;
\fill[white, draw=blue!80!black] (center) ++(0,-1.05,0.2) -- ++(0,0,0.6) -- ++(0,-0.7,0) -- ++(0,0,-0.6) -- cycle;
\fill[white, draw=blue!80!black] (center) ++(1,-1.05,-0.8) -- ++(0,0,0.6) -- ++(0,-0.7,0) -- ++(0,0,-0.6) -- cycle;
\end{scope}
\end{tikzpicture}
\end{document}

I had no bright ideas to draw the squares, and it got a Little exhaustive, so I left an example of a (boring) way to do it.

Compilation result