46

I am a kind of TikZ addict, and also be a fan of football. This time - WorldCup 2018 - is nice change of relaxing by drawing flags of 32 football teams by pure TikZ or TikZ-based codes. Some are easy (like the Japan flag ^^), some are somehow difficult! Please join and/or suggest me!

Let me start with the South-Korean flag. In its code, I like the way of (i) drawing the Yin Yang symbols and the 4 black trigrams via only one parameter \YYrotation; (ii) using scope, foreach, and (iii) using a trick of coloring black/white trigrams with a little bit bigger line width. I first draw trigrams at (0,0), then use rotation and shift to move to the corners. Description of the South-Korean flag can be found here https://en.wikipedia.org/wiki/Flag_of_South_Korea

enter image description here

The followings are the TikZ codes for the South-Korean flag.

% Description of The SOUTH-KOREAN FLAG 
% https://en.wikipedia.org/wiki/Flag_of_South_Korea
% A rectangle: width = 2/3 length,
% the Yin Yang symbol (red above, blue below) at center,
% the 4 black trigrams at 4 corners.

\documentclass[border=5mm]{standalone}
\usepackage{tikz}
\usetikzlibrary{calc}
\begin{document}

\begin{tikzpicture}
\def\a{7.5}  % a half of the length 
\def\b{5}    % a half of the width 
\def\r{1.25} % radius of the Yin/Yang symbol 

% radius of the big circle
\pgfmathsetmacro{\R}{2*\r} 
% the rotation angle of Yin/Yang/trigrams
\pgfmathsetmacro{\YYrotation}{atan(3/2)} 

% the whole rectangle of the flag
\path (-\a,-\b) rectangle (\a,\b); 

% the Yin Yang symbol: draw, then rotate
\begin{scope}[rotate=\YYrotation]
\fill[red] (0,\R) arc (90:-90:\R) arc(-90:90:\r) arc(270:90:\r);
\fill[blue] (0,-\R) arc (270:90:\R) arc(90:270:\r) arc(90:-90:\r);
\end{scope}

% the spring trigram (the above-left corner)
\begin{scope}[rotate=\YYrotation,shift={(0,4.6)},line width=.42 cm]
\foreach \j in {0,5/8,-5/8} \draw (-5/4,\j)--(5/4,\j);
\end{scope}

% the autumn trigram (the below-left corner)
\begin{scope}[rotate=-\YYrotation,shift={(0,-4.6)},line width=.42 cm]
\foreach \j in {0,5/8,-5/8} \draw (-5/4,\j)--(5/4,\j);
\draw[white,line width=.44 cm] (-5/48,0)--(5/48,0);
\end{scope}

% the winter trigram (the above-right corner)
\begin{scope}[rotate=-\YYrotation,shift={(0,4.6)},line width=.42 cm]
\foreach \j in {0,5/8,-5/8} \draw (-5/4,\j)--(5/4,\j);
\foreach \j in {5/8,-5/8} \draw[white,line width=.44 cm] (-5/48,\j)--(5/48,\j);
\end{scope}

% the summer trigram (the below-right corner)
\begin{scope}[rotate=\YYrotation,shift={(0,-4.6)},line width=.42 cm]
\foreach \j in {0,5/8,-5/8} \draw (-5/4,\j)--(5/4,\j);
\foreach \j in {0,5/8,-5/8} \draw[white,line width=.44 cm] (-5/48,\j)--(5/48,\j);
\end{scope}
\end{tikzpicture}
\end{document} 
  • 4
    I suggest waiting until the final and drawing 2. :) – Alan Munn Jun 26 '18 at 17:31
  • 5
    @AlanMunn So sad that egreg cannot contribute Italy :-( – user121799 Jun 26 '18 at 17:36
  • 3
    My tikz-fu is only good for Japan 🇯🇵 – Dr. Manuel Kuehner Jun 26 '18 at 18:03
  • 1
    @Dr.ManuelKuehner \fbox{\Huge\color{red}.} – Robert Jun 27 '18 at 1:25
  • 1
    I guess I'm the only one who finds these sorts of attention-grabbing highly-upvoted "fun" drawing questions to be extremely stale. – hftf Jun 27 '18 at 14:31

13 Answers 13

27

Here one for Peru, The normal flag of my country is simple, what happens is that for this 2018 tournament, they have used the flag with a shield, so in this post I will try to complete it even with the shield and the frame style that they have given it, on the official page of FIFA.

Although my country has already been eliminated but hopefully at least winning its last game.

UPDATE: Finishig the tikz drawing using decorations markings library. enter image description here

MWE:

% arara: pdflatex: {synctex: yes, action: nonstopmode}
% By J. Leon V. Share as Beerware philosophy
\documentclass[border=20pt]{standalone}
\usepackage{xcolor}
\definecolor{gold}{HTML}{D1BA87}
\definecolor{Redper}{HTML}{C60C30}
\definecolor{sky}{HTML}{0083C4}
\definecolor{vicug}{HTML}{A84A0E}
\usepackage{tikz}
\usepackage{pgfmath}
\usepackage{xifthen}
\usepackage[keli]{malayalam}
\usetikzlibrary{decorations.markings, arrows.meta,calc,shadows.blur,shadings,decorations.shapes}


\begin{document}
    \begin{tikzpicture}[
        %Environment Styles
        Laurel/.style={
            draw,
            double=green!50!black,
            postaction={
                decorate,
                decoration={
                    markings,
                    mark=between positions 0.4 and 0.8 step 0.2
                    with {
                        \draw[double=green!50!black,line width=0.5pt](0,0) [out=0,in=135]
                            to ++(0.25,-.1)
                            (0,0) [out=0,in=-90]
                            to ++(0.25,.15);
                        \draw[fill=Redper](0.25,-.1) circle (1.2pt);
                        \draw[fill=Redper](0.25,.15) circle (1.2pt);
                    }
                }
            },
            postaction={
                decorate,
                decoration={
                    markings,
                    mark=between positions 0.3 and 1 step 0.2
                    with {
                        \draw[fill=green!50!black](0,0) [out=-45,in=180]
                            to ++(0.5,-.1)[out=105,in=0]
                            to cycle;
                        \draw[fill=green!50!black](0,0) [out=-45,in=180]
                            to ++(0.5,-.2)[out=105,in=0]
                            to cycle;
                        \draw[fill=green!50!black](0,0) [out=45,in=180]
                            to ++(0.5,.1)[out=-105,in=0]
                            to cycle;
                        \draw[fill=green!50!black](0,0) [out=45,in=180]
                            to ++(0.5,.2)[out=-105,in=0]
                            to cycle;
                    }
                }
            }
        },
        Palma/.style={
            draw,
            double=green!50!black,
            postaction={
                decorate,
                decoration={
                    markings,
                    mark=between positions 0.3 and 1 step 0.08
                    with {
                        \draw[fill=green!50!black](0,0) [out=-30,in=160]
                            to ++(0.5,-.2)[out=150,in=0]
                            to cycle;
                        \draw[fill=green!50!black](0,0) [out=-30,in=160]
                            to ++(0.5,-.3)[out=150,in=0]
                            to cycle;
                        \draw[fill=green!50!black](0,0) [out=30,in=-160]
                            to ++(0.6,.0)[out=-150,in=0]
                            to cycle;
                        \draw[fill=green!50!black](0,0) [out=30,in=-160]
                            to ++(0.6,.1)[out=-150,in=0]
                            to cycle;
                        \draw[fill=green!50!black](0,0) [out=15,in=180]
                            to ++(0.65,-0.1)[out=-180,in=-15]
                            to cycle;
                    }
                }
            }
        },
        Corona/.style={
            draw,
            double=green!50!black,
            postaction={
                decorate,
                decoration={
                    markings,
                    mark=between positions 0 and 0.95 step 0.1
                    with {
                        \draw[fill=green!50!black](0,0) [out=-45,in=-135]
                            to ++(0.15,0)[out=135,in=45]
                            to cycle;
                        \draw[fill=green!50!black](0,0) [out=-90,in=180]
                            to ++(0.1,-.1)[out=90,in=0]
                            to cycle;
                        \draw[fill=green!50!black](0,0) [out=90,in=-180]
                            to ++(0.1,.1)[out=-90,in=0]
                            to cycle;
                    }
                }
            }
        },
        Quina/.style={
            draw,
            double=green!50!black,
            postaction={
                decorate,
                decoration={
                    markings,
                    mark=between positions 0 and 1 step 0.5
                    with {
                        \fill[fill=green!50!black](0,0) [out=-45,in=-135]
                            to ++(0.08,0)[out=135,in=45]
                            to cycle;
                        \fill[fill=green!50!black](0,0) [out=-90,in=180]
                            to ++(0.05,-.05)[out=90,in=0]
                            to cycle;
                        \fill[fill=green!50!black](0,0) [out=90,in=-180]
                            to ++(0.05,.05)[out=-90,in=0]
                            to cycle;
                    }
                }
            }
        }
    ]
    % Image to used to get coordinates. obtained from my country in fifa web page.
    %\node[inner sep=0pt] (FIG1) at (0,8) {\includegraphics[scale=2]{Peru-flag-russia-2018.pdf}};

    \fill[fill=Redper,out=48,in=180] (-6.2,0) 
        to ++(2.5,3.1)
        -- ++(7.45,0)[out=0,in=138]
        to ++(2.5,-3.1)[out=-138,in=0]
        to ++(-2.5,-3.1)
        -- ++(-7.45,0)[out=180,in=-48]
        to cycle;
    \fill[fill=white,even odd rule]
    (0,0)++(-2.05,-3.1) rectangle ++(4.1,6.2);
    \fill[fill=gold,even odd rule]
    [out=48,in=180] (-6.2,0) 
        to ++(2.5,3.1)
        -- ++(7.45,0)[out=0,in=138]
        to ++(2.5,-3.1)[out=-138,in=0]
        to ++(-2.5,-3.1)
        -- ++(-7.45,0)[out=180,in=-48]
        to cycle
    [out=48,in=180] (-6.6,0) 
        to ++(2.6,3.25)
        -- ++(8,0)[out=0,in=138]
        to ++(2.6,-3.25)[out=-138,in=0]
        to ++(-2.6,-3.25)
        -- ++(-8,0)[out=180,in=-48]
        to cycle;

    %Shield W.I.P.

    \draw[color=gold!80!black,line width=2pt,fill=Redper](0,0)++(-0.66,0)[out=-90,in=90]
    to ++(-0.17,-0.46)[out=-90,in=180]
    to ++(0.33,-0.33)[out=0,in=105]
    to ++(.5,-0.2)[out=75,in=180]
    to ++(.5,0.2)[out=0,in=-90]
    to ++(0.33,0.33)[out=90,in=-90]
    to ++(-0.17,0.46);

    \draw[color=gold!80!black,line width=2pt,fill=sky](0,0) --++(-0.66,0)[out=90,in=-30]
    to ++(-0.25,0.4)[out=30,in=-105]
    to ++(0.25,0.35)[out=-20,in=-135]
    to ++(0.66,0.15) -- cycle;

    \draw[color=gold!80!black,line width=2pt,fill=white](0,0)--++(0.66,0)[out=90,in=-150]
    to ++(0.25,0.4)[out=150,in=-75]
    to ++(-0.25,0.35)[out=-160,in=-45]
    to ++(-0.66,0.15) -- cycle;

    \draw[Laurel](0,0)++(-0.7,-1.5)[out=35,in=180]
    to ++(0.7,0.3)[out=0,in=-95]
    to ++(1.3,0.8)[out=85,in=-50]
    to ++(-.3,1.2);%1

    \draw[Palma](0,0)++(0.7,-1.5)[out=145,in=0]
    to ++(-0.7,0.3)[out=180,in=-65]
    to ++(-1.15,0.5)[out=115,in=-120]
    to ++(0,1.5);%1

    \draw[Corona](0,0)++(0,0.9)[out=0,in=-90]
    to ++(0.4,0.25)[out=90,in=0]
    to ++(-0.4,0.25);

    \draw[Corona](0,0)++(0,0.9)[out=180,in=-90]
    to ++(-0.4,0.25)[out=90,in=180]
    to ++(0.4,0.25);

    \draw[double=gold!60!black,line width=0.5pt](0,0)++(0.37,0.04)
    -- ++(0,0.4);

    \draw[Quina](0,0)++(0.37,0.35) coordinate (A)
    -- ++(0,0.2);
    \draw[Quina](A) -- ++(0.12,0.12);
    \draw[Quina](A) -- ++(-0.12,0.12);
    \draw[Quina](A)++(0,-0.15) -- ++(0.12,0.12);
    \draw[Quina](A)++(0,-0.15) -- ++(-0.12,0.12);

    % Draw Vicugna
    \draw[fill=vicug](0,0)++(-0.25,0.1)
    -- ++(0.02,0) -- ++(0.03,0.2)[out=0,in=-90] to ++(0.02,0.2) -- ++(0.06,0) --  ++ (-0.01,0.03)
    -- ++(-0.04,0.02)--  ++ (-0.02,0.02)--  ++ (0,0.05)--  ++ (-0.04,-0.05)--  ++ (-0.01,-0.02)[out=-135,in=0]
    to ++(-0.05,-0.16)[out=165,in=15] to ++(-0.25,0.04)[out=180,in=90] to ++(-0.05,-0.04)[out=180,in=90]
    to ++(-0.02,-0.04)[out=45,in=90] to ++(0.03,-0.03)[out=-90,in=90] to ++(0.04,-0.08)[out=-90,in=90]
    to ++(0.03,-0.06)[out=-90,in=90]to ++(0.02,-0.08) -- ++(0.02,0 )-- ++(0.03,0.15)[out=-90,in=135] to ++(0.15,-0.03)
    -- cycle;

    % Draw Rich Cornus
    \draw[fill=gold](0,0)++(0.5,-0.45)[out=180,in=-90] to ++ (-0.05,0.05)[out=90,in=180] to ++ (0.05,0.05)
    [out=0,in=90] to ++ (0.15,-0.15)[out=-90,in=0] to ++ (-0.18,-0.15) -- ++ (0,0.1)[out=0,in=-90] to ++ (0.1,0.1)
    [out=90,in=0] to ++ (-0.05,0.05)[out=180,in=135] to cycle;
    \foreach \distance in {0,0.4,0.45,...,1}{
        \draw[
            draw=none,
            decoration={
                markings,
                mark=at position \distance with {
                    \draw[fill=gold] (0,0) circle (5*\distance pt);
                }
            },
            postaction={decorate}
        ](0,0)++(0.5,-0.45) arc (270:90:0.05)
        arc (90:-90:0.12)[out=180,in=0] to ++(-0.6,0.38)[out=180,in=60] to ++(-0.2,-0.17);
    }

    \foreach \distance in {0,1,...,40}{
        \draw[fill=gold!] (0,0)++(-0.3+rand*0.15,-0.4-rand*0.15) circle (1pt and 0.5pt);
    }


    \end{tikzpicture}
\end{document}
  • @J Leon V.: Image Peru-flag-russia-2018.pdf to used to get coordinates. Which software you use to get coordinates from pdf file? – Black Mild Sep 12 '18 at 3:53
  • 1
    I downloaded the image from the official page, then I edited it with inkscape to cut the canvas, then export it in pdf format; the program that allows me to see the coordinates is TikzEdt, start importing the image in pdf format as a background, then using the WYSIWYG mode with the cursor I found the coordinates. – J Leon V. Sep 12 '18 at 4:41
  • Out of curiosity, why \usepackage[keli]{malayalam}? – nidhin Dec 9 '18 at 6:52
  • aha, I can mark only 1 answer for my question. Is that reasonable? I want to mark several answer in this post – Black Mild Jul 28 at 16:46
48

Some spy practice with completely off colors and shapes and ratios just to replicate a viral I've seen some time ago.

\documentclass[tikz]{standalone}
\usetikzlibrary{spy}
\definecolor{pantone 200}{RGB}{186,12,47}
\definecolor{pantone 280}{RGB}{0,32,91}
\begin{document}
\begin{tikzpicture}[spy using outlines={rectangle, magnification=4,width=11mm, height=8mm, connect spies}]
\fill[pantone 200] (0,0) rectangle (22mm,16mm);
\draw[white, line width=4mm] (0,8mm) -- ++(22mm,0) (8mm,0) -- ++(0mm,16mm);
\draw[pantone 280, line width=2mm] (0,8mm) -- ++(22mm,0) (8mm,0) -- ++(0mm,16mm);

\spy[draw=none] on (2mm,10mm) in node[label={[black, label distance=-2mm]90:IND}] at (-1.5,1.25);
\spy[draw=none] on (2mm,6mm) in node[label={[black, label distance=-2mm]90:POL}] at (-1.5,0);
\spy[draw=none] on (9.5mm,3mm) in node[label={[black, label distance=-2mm]90:FRA}] at (0,-1);
\spy[draw=none, magnification=3] on (12mm,9.5mm) in node[label={[black, label distance=-2mm]90:NLD}] at (3,1.25);
\spy[draw=none, magnification=2] on (8.5mm,8mm) in node[label={[black, label distance=-2mm]90:FIN}] at (1.2,2.5);
\spy[draw=none, magnification=1.5] on (18mm,8mm) in node[label={[black, label distance=-2mm]90:THA}] at (3,-0.5);

\end{tikzpicture}
\end{document}

enter image description here

  • Ohhh, I never read about this! – Sigur Jun 27 '18 at 0:26
  • 1
    @Sigur Probably because it is all made up – percusse Jun 27 '18 at 2:39
  • 4
    oooooooooooooooooooh – Paulo Cereda Jun 27 '18 at 9:56
  • 2
    One tiny detail: the Netherlands is not participating in the FIFA World Cup... 2018 :) – Willem Van Onsem Jun 27 '18 at 19:44
  • 3
    The center piece alone warrants an upvote. – Torbjørn T. Jun 28 '18 at 15:59
32

Here is the Brazilian flag (high resolution PNG here).

enter image description here

Informations can be found in Wiki and about text positioning here.

\documentclass[border=0]{standalone}
\usepackage[scaled]{helvet}
\renewcommand\familydefault{\sfdefault}
\usepackage[T1]{fontenc}
\usepackage{tikz}
\usetikzlibrary{calc}

\definecolor{green} {RGB}{  0,156, 59}
\definecolor{yellow}{RGB}{255,223,  0}
\definecolor{blue}  {RGB}{  0, 39,118}

\newcommand{\wstar}[2]{%
  \fill[white]
  ($#1+(234:#2)$) --
  ($#1+( 90:#2)$) --
  ($#1+(306:#2)$) --
  ($#1+(162:#2)$) --
  ($#1+( 18:#2)$) --
  cycle;
}

\newcommand{\letter}[2][0]{%
  \rotatebox[origin=c]{#1}{%
    \resizebox{.3cm}{.33cm}{%
      \textcolor{green}{\textbf{#2}}%
}}}

\newcommand{\Eletter}[2][0]{%
  \rotatebox[origin=c]{#1}{%
    \resizebox{.25cm}{.3cm}{%
      \textcolor{green}{\textbf{#2}}%
}}}

\begin{document}
\begin{tikzpicture}[scale=1]

%% rectangle, losangle, circle
\fill[green]  (-10,-7) rectangle (10,7);
\fill[yellow] (0,-5.3) -- (-8.3,0) -- (0,5.3) -- (8.3,0) -- cycle;
\fill[blue]   (0,0)    circle    ( 3.5);

%% white band
\begin{scope}
    \clip        ( 0, 0) circle (3.5);
    \fill[white] (-2,-7) circle (8.5);
    \fill[blue]  (-2,-7) circle (8  );
\end{scope}

%% stars
\wstar{( 1.080, 1.100)}{0.15} % 1 Spica (α Virginis)
\wstar{(-2.860, 0.630)}{0.15} % 2 Procyon (α Canis Minoris)
\wstar{(-1.330,-0.140)}{0.12} % 3 Alphard (α Hydrae)
\wstar{( 0.950, 0.175)}{0.10} % 4 Dhanab al Shuja (γ Hydrae)
\wstar{(-2.550,-0.840)}{0.15} % 5 Sirius (α Canis Majoris)
\wstar{(-2.975,-1.155)}{0.12} % 6 Mirzam (β Canis Majoris)
\wstar{(-2.200,-0.630)}{0.07} % 7 Muliphen (γ Canis Majoris)
\wstar{(-1.820,-1.190)}{0.12} % 8 Wezen (δ Canis Majoris)
\wstar{(-1.920,-1.540)}{0.10} % 9 Adhara (ε Canis Majoris)
\wstar{(-1.405,-1.860)}{0.15} %10 Canopus (α Carinae)
\wstar{( 0.000,-0.560)}{0.12} %11 Gacrux (γ Crucis)
\wstar{(-0.351,-0.875)}{0.10} %12 Pálida (δ Crucis)
\wstar{(-0.175,-1.120)}{0.07} %13 Intrometida (ε Crucis)
\wstar{( 0.000,-1.575)}{0.15} %14 Acrux (α Crucis)
\wstar{( 0.407,-0.875)}{0.12} %15 Mimosa (β Crucis)
\wstar{( 2.455,-1.225)}{0.15} %16 Antares (α Scorpii)
\wstar{( 2.940,-1.260)}{0.10} %17 Graffias (β Scorpii)
\wstar{( 2.595,-1.535)}{0.12} %18 Wei (ε Scorpii)
\wstar{( 2.383,-1.822)}{0.12} %19 Shaula (λ Scorpii)
\wstar{( 2.100,-1.990)}{0.10} %20 Girtab (κ Scorpii)
\wstar{( 1.740,-1.930)}{0.10} %21 Denebakrab (μ Scorpii)
\wstar{( 1.755,-2.270)}{0.12} %22 Sargas (θ Scorpii)
\wstar{( 1.750,-2.625)}{0.10} %23 Apollyon (ι Scorpii)
\wstar{( 1.350,-2.050)}{0.10} %24 δ Trianguli Australis
\wstar{( 1.050,-2.356)}{0.12} %25 Atria (α Trianguli Australis)
\wstar{( 0.775,-1.960)}{0.10} %26 γ Trianguli Australis
\wstar{( 0.000,-2.740)}{0.05} %27 Polaris Australis (σ Octantis)

%% curved text 'ORDEM PROGRESSO'
\foreach \a/\l/\t in {%
  97.130000/O/ 7.130000,
  94.090000/R/ 4.090000,
  91.050000/D/ 1.050000,
  88.010000/E/-1.990000,
  84.970000/M/-5.030000,
%
  75.970000/P/-14.030000,
  72.846250/R/-17.153750,
  69.722500/O/-20.277500,
  66.598750/G/-23.401250,
  63.475000/R/-26.525000,
  60.351250/E/-29.648750,
  57.227500/S/-32.772500,
  54.103750/S/-35.896250,
  50.980000/O/-39.020000
}{%
  \node at ($(-2,-7)+(\a:8.25)$) {\letter[\t]{\l}};
}

%% curved text 'E' (smaller than other letters)
\foreach \a/\l/\t in {%
  80.470000/E/-9.530000
}{%
  \node at ($(-2,-7)+(\a:8.25)$) {\Eletter[\t]{\l}};
}

\end{tikzpicture}
\end{document}
  • 2
    Awesome work! :) – Paulo Cereda Jun 27 '18 at 9:05
  • At least Brazil need not fear a 7:1 knockout by Germany any more ... – Hagen von Eitzen Jun 27 '18 at 19:19
  • 1
    @Sigur Fantastic! Congrats! – Paulo Cereda Jun 28 '18 at 17:15
  • 1
    @Sigur really great job! – Joseph Jun 29 '18 at 23:36
  • 1
    @BlackMild, the position of star in the circle are determined according to origin (centre of circle), which was divided into equal parts. So, the numbers (in tikz units) were chosen by hand to put the stars in the right position, comparing with the official draw. – Sigur Sep 12 '18 at 12:25
29

Marmots support Iceland!

\documentclass[tikz,border=3.14mm]{standalone}
\begin{document}
\begin{tikzpicture}[scale=0.5]
\definecolor{SkyBlue}{rgb}{0.00784314,0.32156864,0.61176473}
\fill[SkyBlue] (0,0) rectangle (25,18);
\fill[white] (7,0) rectangle (11,18);
\fill[white] (0,7) rectangle (25,11);
\definecolor{FireRed}{rgb}{0.86274511,0.11764706,0.20784314}
\fill[FireRed] (8,0) rectangle (10,18);
\fill[FireRed] (0,8) rectangle (25,10);
\end{tikzpicture}
\end{document}

enter image description here

UPDATE: Dimensions corrected! Big thanks to @Torbjørn T.!

The dimensions are (now) in agreement with official Iceland web site:

enter image description here

As pointed out by @ShreevatsaR, the width of a flag is not the analogue of a \textwidth, say, but the analogue of the \textheight. The dimensions there are consistent with my updated previous post, but much simpler, and have first been used in Jürgen G's answer. Really hope that this is the flag of the world cup winner in 2022! ;-)

  • 2
    Standard flag terminology seems to be that “width” means “vertical width” (sometimes aka “hoist”) (the “span of a flag down the side parallel to the flagpole”), and the other dimension is called the [horizontal] “length” (sometimes aka “fly”). (Wikipedia) So the description you quote seems to be correct and fit the image, as out of a [vertical] width of 18, the red cross indeed has [vertical] width 2, and the white strips have 1 each. – ShreevatsaR Jun 27 '18 at 3:01
20

The easy ones. Now with correct aspect ratios per country. It's a tough audience out there...

\documentclass{article}
\usepackage{calc}
\newlength{\barwidth}
\usepackage{tikz}
\usetikzlibrary{shapes.multipart,calc,shapes.geometric,positioning}
\usepackage{array}
\newcommand{\flagratio}[1]{\gdef\flrat{#1}\setlength{\barwidth}{\flrat pt*100/3}}
\flagratio{1}
\parindent=0pt
\begin{document}
\tikzset{
    horizontal stripes/.style={
        rectangle split, 
        rectangle split parts=3,
        draw,
        minimum width=100pt*\flrat,
        minimum height=100pt,
        rectangle split part fill={#1},
        inner sep=0pt,outer sep=0pt,
        name=flag},
    vertical stripes/.style={
        rectangle split,
        rectangle split horizontal, 
        rectangle split parts=3,
        draw,
        minimum width=100pt*\flrat,
        minimum height=100pt,
        text width=100pt*\flrat/3,
        rectangle split part fill={#1},
        inner sep=0pt,outer sep=0pt,
        name=flag},
    two stripes/.style={
        rectangle split, 
        rectangle split parts=2,
        draw,
        minimum width=150pt,
        minimum height=100pt,
        rectangle split part fill={#1},
        inner sep=0pt,outer sep=0pt}
    }
\newcommand{\vflag}[3][.5]{\flagratio{#2}\tikz[baseline]{\node[vertical stripes={#3},scale=#1](a){\rule{0pt}{\barwidth}\nodepart{two}\rule{0pt}{\barwidth}\nodepart{three}\rule{0pt}{\barwidth}};}}
\newcommand{\hflag}[3][.5]{\flagratio{#2}\tikz[baseline]{\node[horizontal stripes={#3},scale=#1](a){\rule{0pt}{33.3pt}\nodepart{two}\rule{0pt}{33.3pt}\nodepart{three}\rule{0pt}{33.3pt}};}}
\newcommand{\twobar}[3][.5]{\flagratio{#2}\tikz[baseline]{\node[two stripes={#3},scale=#1](a){\rule{0pt}{50pt}\nodepart{two}\rule{0pt}{50pt}};}}
\newcommand{\colombia}[1][.5]{\flagratio{1.5}\tikz[baseline]{\node[horizontal stripes={ColombiaYellow,ColombiaBlue,ColombiaRed},scale=#1](a){\rule{0pt}{50pt}\nodepart{two}\rule{0pt}{25pt}\nodepart{three}\rule{0pt}{25pt}};}}
\newcommand{\senegal}[1][.5]{\tikz[baseline]{\node[vertical stripes={SenegalGreen,SenegalYellow,SenegalRed},scale=#1](a){\rule{0pt}{\barwidth}\nodepart{two}\rule{0pt}{\barwidth}\nodepart{three}\rule{0pt}{\barwidth}};\node[star,fill=SenegalGreen,star point ratio=1.5,star point height=7.5pt,scale=.75] {};}}
\newcommand{\morocco}[1][.5]
{\flagratio{1.5}\tikz[baseline={(0,25pt)},scale=#1]{%
% Code here from https://tex.stackexchange.com/a/400055/2693
\pgfmathsetmacro{\ct}{.5} % distance center to tip
\pgfmathsetmacro{\cc}{\ct*sin(18)/sin(126)} % distance center to corner (sine rule)
\draw[rectangle,fill=MoroccoRed] (0pt,0pt) -- (0pt,100pt) -- (100pt*\flrat,100pt) -- (100pt*\flrat,0pt) -- cycle;
\draw[ultra thick,MoroccoGreen] (75pt,50pt)
    +(90-0*36:\ct) coordinate(T1)
    foreach[evaluate=\x as \nc using int((\x+1)/2),   % number for corner coordinates
            evaluate=\x as \nt using int((\x+1)/2+1)] % number for tip coordinates
        \x in {1,3,...,9}{
        -- +(90-\x*36:\cc) coordinate(C\nc) -- +({90-(\x+1)*36}:\ct) coordinate(T\nt)}
    -- cycle;
% the rest
\draw[ultra thick,MoroccoGreen] (C1) -- (C2) -- (C3) -- (C4) -- (C5) -- cycle;}}
\newcommand{\england}[1][.5]{\flagratio{1.667}\tikz[baseline={(0pt,25pt)},scale=#1]{
\draw[rectangle] (0pt,0pt) -- (0pt,100pt) -- (100pt*\flrat,100pt) -- (100pt*\flrat,0pt) -- cycle;
\draw[line width=20pt*#1,EnglishRed] (0pt,50pt) -- (100pt*\flrat,50pt);
\draw[line width=20pt*#1,EnglishRed] (50pt*\flrat,0pt) -- (50pt*\flrat,100pt);
}
}
\newcommand{\sweden}[1][.5]{\flagratio{1.6}\tikz[baseline={(0pt,25pt)},scale=#1]{%
\draw[rectangle,fill=SwedishBlue] (0pt,0pt) -- (0pt,100pt) -- (100pt*\flrat,100pt) -- (100pt*\flrat,0pt) -- cycle;
\draw[line width=20pt*#1,SwedishYellow] (0pt,50pt) -- (100pt*\flrat,50pt);
\draw[line width=20pt*#1,SwedishYellow] (37.5pt*\flrat,0pt) -- (37.5pt*\flrat,100pt);
}
}
\newcommand{\denmark}[1][.5]{\flagratio{1.321}\tikz[baseline={(0pt,25pt)},scale=#1]{%
\draw[rectangle,fill=DanishRed] (0pt,0pt) -- (0pt,100pt) -- (100pt*\flrat,100pt) -- (100pt*\flrat,0pt) -- cycle;
\draw[line width=14.28pt*#1,white] (0pt,50pt) -- (100pt*\flrat,50pt);
\draw[line width=14.28pt*#1,white] (37.8pt*\flrat,0pt) -- (37.8pt*\flrat,100pt);
}
}


\definecolor[named]{NigerianGreen}{RGB}{0,135,83}
\definecolor[named]{GermanGold}{RGB}{255,204,0}
\definecolor[named]{GermanRed}{RGB}{255,0,0}
\definecolor[named]{BelgianYellow}{RGB}{253,218,36}
\definecolor[named]{BelgianRed}{RGB}{239,51,64}
\definecolor[named]{FrenchBlue}{RGB}{0,85,164}
\definecolor[named]{FrenchRed}{RGB}{239,65,53}
\definecolor[named]{RussianBlue}{RGB}{0,57,166}
\definecolor[named]{RussianRed}{RGB}{213,43,30}
\definecolor[named]{PolishRed}{RGB}{220, 20, 60}
\definecolor[named]{ColombiaYellow}{RGB}{252,209,22}
\definecolor[named]{ColombiaBlue}{RGB}{0,56,147}
\definecolor[named]{ColombiaRed}{RGB}{206,17,38}
\definecolor[named]{SenegalGreen}{RGB}{0, 133, 63}
\definecolor[named]{SenegalYellow}{RGB}{253, 239, 66}
\definecolor[named]{SenegalRed}{RGB}{227, 27, 35}
\definecolor[named]{MoroccoRed}{RGB}{193, 39, 45}
\definecolor[named]{MoroccoGreen}{RGB}{0, 98, 51}
\definecolor[named]{EnglishRed}{RGB}{207, 8, 31}
\definecolor[named]{SwedishBlue}{RGB}{45, 95, 161}
\definecolor[named]{SwedishYellow}{RGB}{255, 202, 32}
\definecolor[named]{DanishRed}{RGB}{224, 24, 54}


\setlength{\extrarowheight}{30pt}
\begin{tabular}{p{1in}m{1.5in}p{1in}m{1.5in}}
France: & \vflag{1.5}{FrenchBlue,white,FrenchRed} &
Nigeria: & \vflag{2}{NigerianGreen,white,NigerianGreen}\\
Belgium: & \vflag{1.154}{black,BelgianYellow,BelgianRed} &
Russia: & \hflag{1.5}{white,RussianBlue,RussianRed}\\
Germany: & \hflag{1.667}{black,GermanRed,GermanGold} &
Poland: & \twobar{1.6}{white,PolishRed}\\
Colombia: & \colombia & 
Senegal: & \senegal \\
Morocco: & \morocco  & England & \england\\
Sweden & \sweden & Denmark & \denmark
\end{tabular}



\end{document}

output of code

  • Your drawings do not match the official ratios. en.wikipedia.org/wiki/List_of_aspect_ratios_of_national_flags – AndréC Jun 26 '18 at 20:45
  • 7
    @AndréC These are 3D pictures and Alan is looking at the flags from and angle. ;-) – user121799 Jun 26 '18 at 20:51
  • @AndréC See updated answer. :) – Alan Munn Jun 26 '18 at 21:51
  • 3
    Shouldn't all flags have equal area in the name of justice? – cfr Jun 27 '18 at 0:28
  • 2
    @cfr You supply the dragon and I'll do the rest. :) – Alan Munn Jun 27 '18 at 0:53
15

For anyone who is interested: Save the following as pst-flags.sty and put it into the root path of your TeX system or just into your working folder:

    \ProvidesPackage{pst-flags}[2012/11/16 v. 0.01 Flags for Europe (jg)]
\RequirePackage{pst-xkey}
\RequirePackage{pst-eucl}
\RequirePackage{pstricks-add}
\SpecialCoor

\pst@addfams{pst-flags}
\define@key[psset]{pst-flags}{nation}[Germany]{\def\pst@flag@nation{#1}}
\psset{nation=Germany}

\def\pstFlag{\pst@object{pstFlag}}
\def\pstFlag@i{{\use@par\@nameuse{pst@Flag\pst@flag@nation}}}

\def\pst@FlagAustria{%
\definecolor{austriaRed}{HTML}{F5002F} %Pantone 186
\begin{pspicture}(0,0)(15,10)
%% Flagge (Verh\"{a}ltnis 3 Breite : 2 H\"{o}he)
\psframe[linecolor=austriaRed,fillstyle=solid,fillcolor=austriaRed](!0 10 3 div 2 mul)(15,10)
\psframe[linecolor=white,fillstyle=solid,fillcolor=white](!0 10 3 div)(!15 10 3 div 2 mul)
\psframe[linecolor=austriaRed,fillstyle=solid,fillcolor=austriaRed](0,0)(!15 10 3 div)%
\end{pspicture}}

\def\pst@FlagGermany{%
\definecolor{germanRed}{HTML}{FF0000}
\definecolor{germanGold}{HTML}{FFCC00}
\begin{pspicture}(0,0)(15,9)
%% Flagge (Verh\"{a}ltnis 5 Breite : 3 H\"{o}he)
\psframe[linecolor=black,fillstyle=solid,fillcolor=black](0,6)(15,9)
\psframe[linecolor=germanRed,fillstyle=solid,fillcolor=germanRed](0,3)(15,6)
\psframe[linecolor=germanGold,fillstyle=solid,fillcolor=germanGold](0,0)(15,3)
\end{pspicture}}

\def\pst@FlagBelgium{%
\definecolor{belgiumYellow}{RGB}{255 233 54}
\definecolor{belgiumRed}{RGB}{255 15 33}
\begin{pspicture}(0,0)(15,13)
%% Flagge (Verh\"{a}ltnis 15 Breite : 13 H\"{o}he)
\psframe[linecolor=black,fillstyle=solid,fillcolor=black](0,0)(5,13)
\psframe[linecolor=belgiumYellow,fillstyle=solid,fillcolor=belgiumYellow](5,0)(10,13)
\psframe[linecolor=belgiumRed,fillstyle=solid,fillcolor=belgiumRed](10,0)(15,13)
\end{pspicture}}

\def\pst@FlagBulgaria{%
\definecolor{bulgariaRed}{HTML}{D62612}
\definecolor{bulgariaGreen}{HTML}{00966E}
\psset{unit=0.6}
\begin{pspicture}(0,0)(25,15)
%% Flagge (Verh\"{a}ltnis 5 Breite : 3 H\"{o}he)
\psframe[linecolor=white,fillstyle=solid,fillcolor=white](0,10)(25,15)
\psframe[linecolor=bulgariaGreen,fillstyle=solid,fillcolor=bulgariaGreen](0,5)(25,10)
\psframe[linecolor=bulgariaRed,fillstyle=solid,fillcolor=bulgariaRed](0,0)(25,5)
\end{pspicture}}

\def\pst@FlagCzechRepublic{%
\definecolor{czechRed}{HTML}{D7141A}
\definecolor{czechBlue}{HTML}{11457E}
\begin{pspicture}(0,0)(15,10)
%% Flagge (Verh\"{a}ltnis 3 Breite : 2 H\"{o}he)
%% Breite 1,5 : 1.5 H\"{o}he 1 : 1
\psframe[linecolor=white,fillstyle=solid,fillcolor=white](0,5)(15,10)
\psframe[linecolor=czechRed,fillstyle=solid,fillcolor=czechRed](0,0)(15,5)
\pspolygon[linecolor=czechBlue,fillstyle=solid,fillcolor=czechBlue](0,0)(7.5,5)(0,10)
\end{pspicture}}

\def\pst@FlagDenmark{%
\definecolor{denmarkRed}{HTML}{FF173D} %Pantone 185
\psset{unit=0.4054}
\begin{pspicture}(0,0)(37,28)
%% Flagge (Verh\"{a}ltnis 37 Breite : 28 H\"{o}he)
%% Breite 12 - 4 - 21 : H\"{o}he 12 - 4 - 12
\psframe[linecolor=denmarkRed,fillstyle=solid,fillcolor=denmarkRed](0,0)(37,28)
\pspolygon[linecolor=white,fillstyle=solid,fillcolor=white](0,12)(12,12)(12,0)(16,0)(16,12)(37,12)(37,16)(16,16)(16,28)(12,28)(12,16)(0,16)
\end{pspicture}}

\def\pst@FlagEstonia{%
\definecolor{estoniaBlue}{RGB}{18 145 255}
\psset{unit=1.3636}
\begin{pspicture}(0,0)(11,7)
%% Flagge (Verh\"{a}ltnis 11 Breite : 7 H\"{o}he)
\psframe[linecolor=estoniaBlue,fillstyle=solid,fillcolor=estoniaBlue](0,3.5)(11,7)
\psframe[linecolor=black,fillstyle=solid,fillcolor=black](0,0)(11,3.5)
\end{pspicture}}

\def\pst@FlagFinland{%
\definecolor{finlandBlue}{RGB}{0 82 165}
\psset{unit=0.8333}
\begin{pspicture}(0,0)(18,11)
%% Flagge (Verh\"{a}ltnis 18 Breite : 11 H\"{o}he)
%% Breite 5 - 3 - 10 : H\"{o}he 4 - 3 - 4
\psframe[linecolor=white,fillstyle=solid,fillcolor=white](0,0)(18,11)
\pspolygon[linecolor=finlandBlue,fillstyle=solid,fillcolor=finlandBlue](0,4)(5,4)(5,0)(8,0)(8,4)(18,4)(18,7)(8,7)(8,11)(5,11)(5,7)(0,7)
\end{pspicture}}

\def\pst@FlagFrance{%
\definecolor{frenchRed}{HTML}{EF4531}
\definecolor{frenchBlue}{HTML}{0055A4}
\begin{pspicture}(0,0)(15,10)
%% Flagge (Verh\"{a}ltnis 3 Breite : 2 H\"{o}he)
\psframe[linecolor=frenchBlue,fillstyle=solid,fillcolor=frenchBlue](0,0)(5,10)
\psframe[linecolor=white,fillstyle=solid,fillcolor=white](5,0)(10,10)
\psframe[linecolor=frenchRed,fillstyle=solid,fillcolor=frenchRed](10,0)(15,10)
\end{pspicture}}

\def\pst@FlagUnitedKingdom{%
\definecolor{ukRed}{RGB}{204 0 0}
\definecolor{ukBlue}{RGB}{0 0 102}
\psset{unit=0.25}
\begin{pspicture*}(0,0)(60,30)
%% Flagge (Verh\"{a}ltnis 2 Breite : 1 H\"{o}he)
\psframe[linecolor=ukBlue,fillstyle=solid,fillcolor=ukBlue](0,0)(60,30)
\rput{26.56}(0,-3.3){%
\psframe[linecolor=white,fillstyle=solid,fillcolor=white](-10,0)(70,6)
\psframe[linecolor=ukRed,fillstyle=solid,fillcolor=ukRed](-10,1)(30,3)
\psframe[linecolor=ukRed,fillstyle=solid,fillcolor=ukRed](30,3)(70,5)
}
\rput{-26.56}(!0 30 3.3 sub){%
\psframe[linecolor=white,fillstyle=solid,fillcolor=white](-10,0)(70,6)
\psframe[linecolor=ukRed,fillstyle=solid,fillcolor=ukRed](-10,1)(30,3)
\psframe[linecolor=ukRed,fillstyle=solid,fillcolor=ukRed](30,3)(70,5)
}
\pspolygon[linecolor=white,fillstyle=solid,fillcolor=white](0,10)(25,10)(25,0)(35,0)(35,10)(60,10)(60,20)(35,20)(35,30)(25,30)(25,20)(0,20)
\pspolygon[linecolor=ukRed,fillstyle=solid,fillcolor=ukRed](0,12)(27,12)(27,0)(33,0)(33,12)(60,12)(60,18)(33,18)(33,30)(27,30)(27,18)(0,18)
\end{pspicture*}}

\def\pst@FlagGreece{%
\definecolor{greeceBlue}{cmyk}{1 0.6 0 0.05}
\psset{unit=0.5555}
\begin{pspicture}(0,0)(27,18)
%% Flagge (Verh\"{a}ltnis 3 Breite : 2 H\"{o}he)
\psframe[linecolor=white,fillstyle=solid,fillcolor=white](0,0)(27,18)
\multido{\iA=0+4}{5}{%
\rput(0,\iA){\psframe[linecolor=greeceBlue,fillstyle=solid,fillcolor=greeceBlue](0,0)(27,2)}
}
\psframe[linecolor=greeceBlue,fillstyle=solid,fillcolor=greeceBlue](0,18)(10,8)
\pspolygon[linecolor=white,fillstyle=solid,fillcolor=white](0,12)(4,12)(4,8)(6,8)(6,12)(10,12)(10,14)(6,14)(6,18)(4,18)(4,14)(0,14)
\end{pspicture}}

\def\pst@FlagHungary{%
\definecolor{hungaryRed}{HTML}{CE1126}
\definecolor{hungaryGreen}{HTML}{008751}
\psset{unit=0.5}
\begin{pspicture}(0,0)(30,15)
%% Flagge (Verh\"{a}ltnis 2 Breite : 1 H\"{o}he)
\psframe[linecolor=hungaryRed,fillstyle=solid,fillcolor=hungaryRed](0,10)(30,15)
\psframe[linecolor=white,fillstyle=solid,fillcolor=white](0,5)(30,10)
\psframe[linecolor=hungaryGreen,fillstyle=solid,fillcolor=hungaryGreen](0,0)(30,5)
\end{pspicture}}

\def\pst@FlagIceland{%
\definecolor{icelandBlue}{HTML}{0048E0}
\definecolor{icelandRed}{HTML}{FF0F00}
\psset{unit=0.6}
\begin{pspicture}(0,0)(25,18)
%% Flagge (Verh\"{a}ltnis 25 Breite : 18 H\"{o}he)
%% Breite 7 - 4 - 14 : H\"{o}he 7 - 4 - 7
\psframe[linecolor=icelandBlue,fillstyle=solid,fillcolor=icelandBlue](0,0)(25,18)
\pspolygon[linecolor=white,fillstyle=solid,fillcolor=white](0,7)(7,7)(7,0)(11,0)(11,7)(25,7)(25,11)(11,11)(11,18)(7,18)(7,11)(0,11)
\pspolygon[linecolor=icelandRed,fillstyle=solid,fillcolor=icelandRed](0,8)(8,8)(8,0)(10,0)(10,8)(25,8)(25,10)(10,10)(10,18)(8,18)(8,10)(0,10)
\end{pspicture}}

\def\pst@FlagIreland{%
\definecolor{irelandOrange}{HTML}{FF7900}
\definecolor{irelandGreen}{HTML}{009A49}
\psset{unit=0.5}
\begin{pspicture}(0,0)(30,15)
%% Flagge (Verh\"{a}ltnis 2 Breite : 1 H\"{o}he)
\psframe[linecolor=irelandGreen,fillstyle=solid,fillcolor=irelandGreen](0,0)(10,15)
\psframe[linecolor=white,fillstyle=solid,fillcolor=white](10,0)(20,15)
\psframe[linecolor=irelandOrange,fillstyle=solid,fillcolor=irelandOrange](20,0)(30,15)
\end{pspicture}}

\def\pst@FlagItaly{%
\definecolor{italyRed}{RGB}{206 43 55}
\definecolor{italyWhite}{RGB}{241 242 241}
\definecolor{italyGreen}{RGB}{0 146 70}
\begin{pspicture}(0,0)(15,10)
%% Flagge (Verh\"{a}ltnis 3 Breite : 2 H\"{o}he)
\psframe[linecolor=italyGreen,fillstyle=solid,fillcolor=italyGreen](0,0)(5,10)
\psframe[linecolor=italyWhite,fillstyle=solid,fillcolor=italyWhite](5,0)(10,10)
\psframe[linecolor=italyRed,fillstyle=solid,fillcolor=italyRed](10,0)(15,10)
\end{pspicture}}

\def\pst@FlagLatvia{%
\definecolor{latviaMaroon}{HTML}{9E1B34}
\psset{unit=0.5}
\begin{pspicture}(0,0)(30,15)
%% Flagge (Verh\"{a}ltnis 2 Breite : 1 H\"{o}he)
%% H\"{o}he 2 - 1 - 2
\psframe[linecolor=latviaMaroon,fillstyle=solid,fillcolor=latviaMaroon](0,9)(30,15)
\psframe[linecolor=white,fillstyle=solid,fillcolor=white](0,6)(30,9)
\psframe[linecolor=latviaMaroon,fillstyle=solid,fillcolor=latviaMaroon](0,0)(30,6)
\end{pspicture}}

\def\pst@FlagLithuania{%
\definecolor{lithuaniaYellow}{RGB}{253 185 19}
\definecolor{lithuaniaGreen}{RGB}{0 106 68}
\definecolor{lithuaniaRed}{RGB}{193 39 45}
\psset{unit=0.6}
\begin{pspicture}(0,0)(25,15)
%% Flagge (Verh\"{a}ltnis 5 Breite : 3 H\"{o}he)
\psframe[linecolor=lithuaniaYellow,fillstyle=solid,fillcolor=lithuaniaYellow](0,10)(25,15)
\psframe[linecolor=lithuaniaGreen,fillstyle=solid,fillcolor=lithuaniaGreen](0,5)(25,10)
\psframe[linecolor=lithuaniaRed,fillstyle=solid,fillcolor=lithuaniaRed](0,0)(25,5)
\end{pspicture}}

\def\pst@FlagLuxembourg{%
\definecolor{luxembourgRed}{HTML}{FF1A24} %Pantone 032
\definecolor{luxembourgBlue}{HTML}{26CFFF} %Pantone 299
\psset{unit=3}
\begin{pspicture}(0,0)(5,3)
%% Flagge (Verh\"{a}ltnis 5 Breite : 3 H\"{o}he)
\psframe[linecolor=luxembourgRed,fillstyle=solid,fillcolor=luxembourgRed](0,2)(5,3)
\psframe[linecolor=white,fillstyle=solid,fillcolor=white](0,1)(5,2)
\psframe[linecolor=luxembourgBlue,fillstyle=solid,fillcolor=luxembourgBlue](0,0)(5,1)
\end{pspicture}}

\def\pst@FlagMonaco{%
\definecolor{monacoRed}{cmyk}{0 0.9 0.8 0.05}
\psset{unit=0.6}
\begin{pspicture}(0,0)(25,20)
%% Flagge (Verh\"{a}ltnis 5 Breite : 4 H\"{o}he)
\psframe[linecolor=white,fillstyle=solid,fillcolor=white](0,0)(25,10)
\psframe[linecolor=monacoRed,fillstyle=solid,fillcolor=monacoRed](0,10)(25,20)
\end{pspicture}}

\def\pst@FlagNetherlands{%
\definecolor{netherlandsRed}{HTML}{AE1C28}
\definecolor{netherlandsBlue}{HTML}{21468B}
\begin{pspicture}(0,0)(15,10)
%% Flagge (Verh\"{a}ltnis 3 Breite : 2 H\"{o}he)
\psframe[linecolor=netherlandsRed,fillstyle=solid,fillcolor=netherlandsRed](!0 10 3 div 2 mul)(15,10)
\psframe[linecolor=white,fillstyle=solid,fillcolor=white](!0 10 3 div)(!15 10 3 div 2 mul)
\psframe[linecolor=netherlandsBlue,fillstyle=solid,fillcolor=netherlandsBlue](0,0)(!15 10 3 div)
\end{pspicture}}

\def\pst@FlagNorway{%
\definecolor{norgeBlue}{HTML}{002868}
\definecolor{norgeRed}{HTML}{EF2B2D}
\psset{unit=0.6818}
\begin{pspicture}(0,0)(22,16)
%% Wei{\ss}er Grundrahmen \"{u}ber komplette Flagge (Verh\"{a}ltnis 22 Breite : 16 H\"{o}he)
%% 6 - 1 - 2 - 1 - 12 Breite : 6 - 1 - 2 - 1 - 6 H\"{o}he
\psframe[linecolor=white,fillstyle=solid,fillcolor=white](0,0)(22,16)
%% Rote Felder
\psframe[linecolor=norgeRed,fillstyle=solid,fillcolor=norgeRed](0,16)(6,10)
\psframe[linecolor=norgeRed,fillstyle=solid,fillcolor=norgeRed](10,16)(22,10)
\psframe[linecolor=norgeRed,fillstyle=solid,fillcolor=norgeRed](0,0)(6,6)
\psframe[linecolor=norgeRed,fillstyle=solid,fillcolor=norgeRed](10,0)(22,6)
%% Blaue Felder
\pspolygon[fillstyle=solid,fillcolor=norgeBlue,linecolor=norgeBlue](0,7)(7,7)(7,0)(9,0)(9,7)(22,7)(22,9)(9,9)(9,16)(7,16)(7,9)(0,9)
\end{pspicture}}

\def\pst@FlagPoland{%
\definecolor{polandRed}{HTML}{DC143C}
\psset{unit=1.875}
\begin{pspicture}(0,0)(8,5)
%% Flagge (Verh\"{a}ltnis 8 Breite : 5 H\"{o}he)
\psframe[linecolor=white,fillstyle=solid,fillcolor=white](0,2.5)(8,5)
\psframe[linecolor=polandRed,fillstyle=solid,fillcolor=polandRed](0,0)(8,2.5)
\end{pspicture}}

\def\pst@FlagRomania{%
\definecolor{romaniaBlue}{RGB}{0 43 127}
\definecolor{romaniaYellow}{RGB}{252 209 22}
\definecolor{romaniaRed}{RGB}{206 17 38}
\begin{pspicture}(0,0)(15,10)
%% Flagge (Verh\"{a}ltnis 3 Breite : 2 H\"{o}he)
\psframe[linecolor=romaniaBlue,fillstyle=solid,fillcolor=romaniaBlue](0,0)(5,10)
\psframe[linecolor=romaniaYellow,fillstyle=solid,fillcolor=romaniaYellow](5,0)(10,10)
\psframe[linecolor=romaniaRed,fillstyle=solid,fillcolor=romaniaRed](10,0)(15,10)
\end{pspicture}}

\def\pst@FlagRussia{%
\definecolor{russiaBlue}{HTML}{0039A6}
\definecolor{russiaRed}{HTML}{D52B1E}
\psset{unit=0.3333}
\begin{pspicture}(0,0)(45,30)
%% Flagge (Verh\"{a}ltnis 3 Breite : 2 H\"{o}he)
\psframe[linecolor=white,fillstyle=solid,fillcolor=white](0,20)(45,30)
\psframe[linecolor=russiaBlue,fillstyle=solid,fillcolor=russiaBlue](0,10)(45,20)
\psframe[linecolor=russiaRed,fillstyle=solid,fillcolor=russiaRed](0,0)(45,10)
\end{pspicture}}

\def\pst@FlagSweden{%
\definecolor{swedenBlue}{RGB}{0 127 229}
\definecolor{swedenYellow}{RGB}{255 204 0}
\begin{pspicture}(0,0)(15,10)
%% Flagge (Verh\"{a}ltnis 3 Breite : 2 H\"{o}he)
%% Breite 5 - 2 - 9 : H\"{o}he 4 - 2 - 4
\psframe[linecolor=swedenBlue,fillstyle=solid,fillcolor=swedenBlue](0,0)(15,10)
\pspolygon[linecolor=swedenYellow,fillstyle=solid,fillcolor=swedenYellow](0,4)(5,4)(5,0)(7,0)(7,4)(15,4)(15,6)(7,6)(7,10)(5,10)(5,6)(0,6)
\end{pspicture}}

\def\pst@FlagSwitzerland{%
\definecolor{switzerlandRed}{HTML}{FF0000}
\psset{unit=0.4689}
\begin{pspicture}(0,0)(32,32)
%% Flagge (Verh\"{a}ltnis 1 Breite : 1 H\"{o}he)
%% Kreuz: 6 7 6 7 6 : 6 7 6 7 6
\psframe[linecolor=switzerlandRed,fillstyle=solid,fillcolor=switzerlandRed](0,0)(32,32)
\pspolygon[linecolor=white,fillstyle=solid,fillcolor=white](6,13)(13,13)(13,6)(19,6)(19,13)(26,13)(26,19)(19,19)(19,26)(13,26)(13,19)(6,19)
\end{pspicture}}

\def\pst@FlagTurkey{%
\definecolor{turkeyRed}{HTML}{CE1126}
\psset{unit=0.55555}
\begin{pspicture}(0,0)(27,18)
%% Flagge (Verh\"{a}ltnis 3 Breite : 2 H\"{o}he)
\pnode(9,9){M1}
\pnode(4.5,9){A1}
\pnode(!9 1 16 div 18 mul add 9){M2}
\pnode(!9 1 16 div 18 mul add 1 5 div 18 mul sub 9){A2}
\psframe[linecolor=turkeyRed,fillstyle=solid,fillcolor=turkeyRed](0,0)(27,18)
\pscircle[linecolor=white,fillstyle=solid,fillcolor=white](M1){4.5}
\pscircle[linecolor=turkeyRed,fillstyle=solid,fillcolor=turkeyRed](M2){!1 5 div 18 mul}
\pnode(0,9){A}
\pnode(27,9){B}
\pstInterCC[PointName=none,PointSymbol=none]{M1}{A1}{M2}{A2}{S1}{S2}
\pstInterLL[PointName=none,PointSymbol=none]{A}{B}{S1}{S2}{D}
\rput(D){\rput(2.25,0){%
\pspolygon[linecolor=white,fillstyle=solid,fillcolor=white](2.25;180)(2.25;-36)(2.25;108)(2.25;252)(2.25;36)
}}
\end{pspicture}}

\def\pst@FlagUkraine{%
\definecolor{ukraineBlue}{HTML}{005BBB}
\definecolor{ukraineYellow}{HTML}{FFD500}
\begin{pspicture}(0,0)(15,10)
%% Flagge (Verh\"{a}ltnis 3 Breite : 2 H\"{o}he)
\psframe[linecolor=ukraineBlue,fillstyle=solid,fillcolor=ukraineBlue](0,5)(15,10)
\psframe[linecolor=ukraineYellow,fillstyle=solid,fillcolor=ukraineYellow](0,0)(15,5)
\end{pspicture}}

\def\pst@FlagUnitedStates{%
\definecolor{USred}{HTML}{B22234}
\definecolor{USblue}{HTML}{3C3B6E}
\psset{unit=0.789}
\begin{pspicture}(0,0)(19,10)
%% White Background = Proportion of the flag
\psframe[fillstyle=solid,fillcolor=USred,linecolor=USred,linestyle=none,linewidth=0pt](0,0)(19,10)
%% 6 white stripes: 13 stripes alternating red (7) and white (6)
\multido{\rA=0.769+1.538}{6}{%
\rput(0,\rA){\psframe[fillstyle=solid,linestyle=none,linewidth=0pt,fillcolor=white](0,0)(!19 10 13 div)}
}
%%Blue rectangle in the upper left (Union)
\psframe[fillstyle=solid,fillcolor=USblue,linecolor=USblue](!0 6 13 div 10 mul)(!2 5 div 19 mul 10)
%%PENTAGRAMM
\def\star{%
\def\outer{0.308}
\pnode(\outer;90){A}
\pnode(\outer;162){B}
\pnode(\outer;234){C}
\pnode(\outer;306){D}
\pnode(\outer;18){E}
\pspolygon[fillstyle=solid,fillcolor=white,linestyle=none,linewidth=0pt]
(A)(C)(E)(B)(D)(A)
}
%% Arrangment of the stars
%% 5 lines with 6 stars
\multido{\rV=9.462+-1.076}{5}{%
\multido{\rL=0.633+1.266}{6}{%
\rput(\rL,\rV){\star}
}}
%% 4 lines with 5 stars
\multido{\rV=8.924+-1.076}{4}{%
\multido{\rL=1.266+1.266}{5}{%
\rput(\rL,\rV){\star}
}}
\end{pspicture}}

\def\pst@FlagMacedonia{%
\definecolor{macedoniaRed}{HTML}{D20000}
\definecolor{macedoniaYellow}{HTML}{FFE600}
\psset{unit=0.5357}
\begin{pspicture}(-14,-7)(14,7)
%% Flagge (Verh\"{a}ltnis 2 Breite : 1 H\"{o}he)
\psframe[linecolor=macedoniaRed,fillstyle=solid,fillcolor=macedoniaRed](-14,-7)(14,7)
\pspolygon[linecolor=macedoniaYellow,fillstyle=solid,fillcolor=macedoniaYellow](1.4,7)(-1.4,7)(1.4,-7)(-1.4,-7)
\pspolygon[linecolor=macedoniaYellow,fillstyle=solid,fillcolor=macedoniaYellow](14,-1.4)(14,1.4)(-14,-1.4)(-14,1.4)
\pspolygon[linecolor=macedoniaYellow,fillstyle=solid,fillcolor=macedoniaYellow](-14,-7)(-9.8,-7)(9.8,7)(14,7)
\pspolygon[linecolor=macedoniaYellow,fillstyle=solid,fillcolor=macedoniaYellow](14,-7)(9.8,-7)(-9.8,7)(-14,7)
\pscircle[linecolor=macedoniaRed,fillstyle=solid,fillcolor=macedoniaRed](0,0){2.5}
\pscircle[linecolor=macedoniaYellow,fillstyle=solid,fillcolor=macedoniaYellow](0,0){2}
\end{pspicture}}

\def\pst@FlagEuropeanUnion{%
\definecolor{euBlue}{HTML}{003399}
\definecolor{euYellow}{HTML}{FFCC00}
\begin{pspicture}(0,0)(15,10)
%% Flagge (Verh\"{a}ltnis 3 Breite : 2 H\"{o}he)
\psframe[linecolor=euBlue,fillstyle=solid,fillcolor=euBlue](0,0)(15,10)
\def\eurostar{%
\def\outer{0.5555}
\pnode(\outer;90){A}
\pnode(\outer;162){B}
\pnode(\outer;234){C}
\pnode(\outer;306){D}
\pnode(\outer;18){E}
\pspolygon[fillstyle=solid,fillcolor=euYellow,linestyle=none,linewidth=0pt]
(A)(C)(E)(B)(D)(A)
}
\rput(7.5,5){%
\multido{\iA=0+30}{12}{%
\rput(3.333;\iA){\eurostar}
}}
\end{pspicture}}

\def\pst@FlagBosniaHerzegovina{%
\definecolor{bhBlue}{HTML}{0053A1}
\definecolor{bhYellow}{HTML}{FFD911}
\psset{unit=0.75}
\begin{pspicture*}(0,0)(20,10)
%% Flagge (Verh\"{a}ltnis 2 Breite : 1 H\"{o}he)
\psframe[linecolor=bhBlue,fillstyle=solid,fillcolor=bhBlue](0,0)(20,10)
\pspolygon[linecolor=bhYellow,fillstyle=solid,fillcolor=bhYellow](5.3,10)(15.3,0)(15.3,10)
\def\bhstar{%
\def\outer{0.95}
\pnode(\outer;90){A}
\pnode(\outer;162){B}
\pnode(\outer;234){C}
\pnode(\outer;306){D}
\pnode(\outer;18){E}
\pspolygon[fillstyle=solid,fillcolor=white,linestyle=none,linewidth=0pt]
(A)(C)(E)(B)(D)(A)
}
\multido{\rA=0+1.25}{9}{
\rput(!13.4 \rA\space sub 0.12 \rA\space add){\bhstar}}
\end{pspicture*}}

\def\pst@FlagScotland{%
\definecolor{scotlandBlue}{HTML}{0072C6} %Pantone 300
\psset{unit=0.75}
\begin{pspicture*}(0,0)(20,12)
%% Flagge (Verh\"{a}ltnis 5 Breite : 3 H\"{o}he)
\psframe[linecolor=scotlandBlue,fillstyle=solid,fillcolor=scotlandBlue](0,0)(20,12)
\pspolygon[linecolor=white,fillstyle=solid,fillcolor=white](0,1.5)(0,0)(2.5,0)(20,10.5)(20,12)(17.5,12)
\pspolygon[linecolor=white,fillstyle=solid,fillcolor=white](0,10.5)(0,12)(2.5,12)(20,1.5)(20,0)(17.5,0)
\end{pspicture*}}

\endinput

The following will then be a not so minimal example:

\documentclass{article}
\usepackage{pst-flags}

\parindent0pt
\parskip7pt

\begin{document}

The default is \verb!nation=Germany!.

Possible values for \texttt{nation} are:

\texttt{Austria, Belgium, BosniaHerzegovina, Bulgaria, CzechRepublic, Denmark, Estonia, EuropeanUnion, Finland, France, Germany, Greece, Hungary, Iceland, Ireland, Italy, Latvia, Lithuania, Luxembourg, Macedonia, Monaco, Netherlands, Norway, Poland, Romania, Russia, Scotland, Sweden, Switzerland, Turkey, Ukraine, UnitedKingdom, UnitedStates}

\psset{unit=3.4mm,linewidth=0pt}

\pstFlag

\pstFlag[nation=Austria]\quad\pstFlag[nation=Belgium]\quad\pstFlag[nation=Bulgaria]

\pstFlag[nation=CzechRepublic]\quad\pstFlag[nation=Denmark]\quad\pstFlag[nation=Estonia]

\pstFlag[nation=Finland]\quad\pstFlag[nation=France]\quad\pstFlag[nation=UnitedKingdom]

\pstFlag[nation=Greece]\quad\pstFlag[nation=Hungary]\quad\pstFlag[nation=Iceland]

\pstFlag[nation=Ireland]\quad\pstFlag[nation=Italy]\quad\pstFlag[nation=Latvia]

\pstFlag[nation=Lithuania]\quad\pstFlag[nation=Luxembourg]\quad\pstFlag[nation=Monaco]

\pstFlag[nation=Netherlands]\quad\pstFlag[nation=Norway]\quad\pstFlag[nation=Poland]

\pstFlag[nation=Romania]\quad\pstFlag[nation=Russia]\quad\pstFlag[nation=Sweden]

\pstFlag[nation=Switzerland]\quad\pstFlag[nation=Turkey]\quad\pstFlag[nation=Ukraine]

\pstFlag[nation=BosniaHerzegovina]\quad\pstFlag[nation=Macedonia]\quad\pstFlag[nation=Scotland]

\pstFlag[nation=EuropeanUnion]\quad\pstFlag[nation=UnitedStates]


\end{document} 

enter image description here enter image description here enter image description here

12

The most-difficult-to-create flag in the world.

\documentclass[pstricks]{standalone}
\begin{document}
\begin{pspicture}[linecolor=red](3,2)
    \qdisk(1.5,1){.6}
\end{pspicture}
\end{document}

Note: As I was born with complete achromatopsia, the selected colors might be wrong. Feel free to update as many as you want.

enter image description here

8

... Turkey -- the PSTricks way ... a more tricky one -- for whom it may interest ...

\documentclass{article}
\parindent0pt
\usepackage{pstricks,pst-eucl,pstricks-add}
\definecolor{turkeyRed}{HTML}{CE1126}
\begin{document}
\psset{unit=0.25}
\begin{pspicture}(0,0)(27,18)
%% Flagge (Verhältnis 3 Breite : 2 Höhe)
\pnode(9,9){M1}
\pnode(4.5,9){A1}
\pnode(!9 1 16 div 18 mul add 9){M2}
\pnode(!9 1 16 div 18 mul add 1 5 div 18 mul sub 9){A2}
\psframe[linecolor=turkeyRed,fillstyle=solid,fillcolor=turkeyRed](0,0)(27,18)
\pscircle[linecolor=white,fillstyle=solid,fillcolor=white](M1){4.5}
\pscircle[linecolor=turkeyRed,fillstyle=solid,fillcolor=turkeyRed](M2){!1 5 div 18 mul}
\pnode(0,9){A}
\pnode(27,9){B}
\pstInterCC[PointName=none,PointSymbol=none]{M1}{A1}{M2}{A2}{S1}{S2}
\pstInterLL[PointName=none,PointSymbol=none]{A}{B}{S1}{S2}{D}
\rput(D){\rput(2.25,0){%
\pspolygon[linecolor=white,fillstyle=solid,fillcolor=white](2.25;180)(2.25;-36)(2.25;108)(2.25;252)(2.25;36)
}}
\end{pspicture}
\end{document}

enter image description here

8

... PS-Iceland ...

    \documentclass{article}
\parindent0pt
\usepackage{pstricks,pstricks-add}
\definecolor{icelandBlue}{HTML}{0048E0}
\definecolor{icelandRed}{HTML}{FF0F00}

\begin{document}
\thispagestyle{empty}
\psset{unit=0.25}
\begin{pspicture}(0,0)(25,18)
%% Flagge (Verhältnis 25 Breite : 18 Höhe)
%% Breite 7 - 4 - 14 : Höhe 7 - 4 - 7
\psframe[linecolor=icelandBlue,fillstyle=solid,fillcolor=icelandBlue](0,0)(25,18)
\pspolygon[linecolor=white,fillstyle=solid,fillcolor=white](0,7)(7,7)(7,0)(11,0)(11,7)(25,7)(25,11)(11,11)(11,18)(7,18)(7,11)(0,11)
\pspolygon[linecolor=icelandRed,fillstyle=solid,fillcolor=icelandRed](0,8)(8,8)(8,0)(10,0)(10,8)(25,8)(25,10)(10,10)(10,18)(8,18)(8,10)(0,10)
%\psgrid
\end{pspicture}
\end{document}

enter image description here

enter image description here

Are these the correct dimensions?

7

Sadly, my country went out at group stage :(. But we can still have the Australian flag here!

Features

  • Real PANTONE spot colours!
  • Lazy clipping :)

Code

I hope I got all the stupid ratios right…

\documentclass[tikz]{standalone}
\usetikzlibrary{shapes}
\usepackage[illuminant=d50]{colorspace}
\definespotcolor{PANTONE-185-C}{PANTONE 185 C}[alt=lab]%
  {49.78,77.43,49.23/0.0,0.93,0.79,0.0}
\definespotcolor{PANTONE-280-C}{PANTONE 280 C}[alt=lab]%
  {15.12,15.25,-46.45/1.0,0.85,0.05,0.22}
\definecolor{white}{cmyk}{0,0,0,0}
\newlength\fw\setlength{\fw}{10cm}
\begin{document}
\begin{tikzpicture}[
    commonwealth/.style={star, star points=7, star point ratio=2.25, fill=white,
      minimum width=0.3\fw},
    alpha/.style={commonwealth, minimum size=1/7*\fw},
    beta/.style={alpha},
    gamma/.style={alpha},
    delta/.style={alpha},
    epsilon/.style={commonwealth, star points=5, minimum size=1/12*\fw},
    stgeorgebg/.style={white, line width=1/6*\fw},
    stgeorge/.style={PANTONE-185-C, line width=0.1\fw},
    standrew/.style={white, line width=0.1\fw},
    stpatrick/.style={PANTONE-185-C, line width=1/15*\fw}
  ]
  \fill [PANTONE-280-C] (0,0) rectangle (2\fw,\fw);
  \node [commonwealth] at (0.5\fw,0.25\fw) {};
  \node [alpha] at (1.5\fw,1/6*\fw) {};
  \node [beta] at (1.25\fw,0.5625\fw) {};
  \node [gamma] at (1.5\fw,5/6*\fw) {};
  \node [delta] at (31/18*\fw,151/240*\fw) {};
  \node [epsilon] at (1.6\fw,11/24*\fw) {};
  \clip (0,0.5\fw) rectangle (\fw,\fw);
  \draw [standrew] (0,0.5\fw) -- (\fw,\fw);
  \draw [standrew] (0,\fw) -- (\fw,0.5\fw);
  \begin{scope}
    \clip (0,\fw) -- (\fw,0.5\fw) -- (\fw,0.75\fw) -- (0,0.75\fw) -- cycle;
    \draw [stpatrick] (0,\fw) -- (\fw,0.5\fw);
  \end{scope}
  \begin{scope}
    \clip (0,0.5\fw) -- (\fw,\fw) -- (0.5\fw,\fw) -- (0.5\fw,0.5\fw) -- cycle;
    \draw [stpatrick] (0,0.5\fw) -- (\fw,\fw);
  \end{scope}
  \draw [stgeorgebg] (0,0.75\fw) -- (\fw,0.75\fw);
  \draw [stgeorgebg] (0.5\fw,0.5\fw) -- (0.5\fw,\fw);
  \draw [stgeorge] (0,0.75\fw) -- (\fw,0.75\fw);
  \draw [stgeorge] (0.5\fw,0.5\fw) -- (0.5\fw,\fw);
\end{tikzpicture}
\end{document}

Output

enter image description here

  • Well, you guys are not planning to participate 2022, do you? So there is time. ;-) – user121799 Apr 7 at 22:05
  • Haha. @marmot, actually, for flag waving you should use rgb colours and not spot colours with the colorspace package. I'll look up the colours for you. – David Purton Apr 7 at 22:54
  • 1
    @marmot, RGB colours: Blue is #00008B, red is #FF0000 and white is #FFFFFF. – David Purton Apr 7 at 22:56
6

... here we go Great Britain with PSTricks ...

    \documentclass{article}
\parindent0pt
\usepackage{pstricks,pstricks-add}
\definecolor{ukRed}{RGB}{204 0 0}
\definecolor{ukBlue}{RGB}{0 0 102}

\begin{document}
\thispagestyle{empty}
\psset{unit=0.1}
\begin{pspicture*}(0,0)(60,30)
%% Flagge (Verhältnis 2 Breite : 1 Höhe)
\def\diag{%
\psframe[linecolor=white,fillstyle=solid,fillcolor=white](-10,0)(70,6)
\psframe[linecolor=ukRed,fillstyle=solid,fillcolor=ukRed](-10,1)(30,3)
\psframe[linecolor=ukRed,fillstyle=solid,fillcolor=ukRed](30,3)(70,5)
}

\psframe[linecolor=ukBlue,fillstyle=solid,fillcolor=ukBlue](0,0)(60,30)
\rput{26.56}(0,-3.3){\diag}
\rput{-26.56}(!0 30 3.3 sub){\diag}

\pspolygon[linecolor=white,fillstyle=solid,fillcolor=white](0,10)(25,10)(25,0)(35,0)(35,10)(60,10)(60,20)(35,20)(35,30)(25,30)(25,20)(0,20)
\pspolygon[linecolor=ukRed,fillstyle=solid,fillcolor=ukRed](0,12)(27,12)(27,0)(33,0)(33,12)(60,12)(60,18)(33,18)(33,30)(27,30)(27,18)(0,18)
\end{pspicture*}
\end{document}

enter image description here

  • 6
    Except in football, GB don't compete...so just remove all the blue and the diagonal red. :) – Alan Munn Jun 26 '18 at 20:46
  • If they compete or not -- isn't it the founder football nation ;-) – user151328 Jun 26 '18 at 20:53
  • 2
    @AlanMunn Remove all the red and all axis-aligned white :) – yo' Jun 26 '18 at 21:52
  • 11
    It isn't A nation. That's the point. GB = 3 nations. UK = 4 or 3 and part of 1, depending on your political view. – cfr Jun 27 '18 at 0:30
  • 2
    You want the flag of England. – gerrit Jun 27 '18 at 9:57
6

I think this FIFA thing is some kind of cup of sports. Anyway I do not care and chose to spam my own country's flag, Dannebrog from Denmark here:

\documentclass[tikz, border=2mm]{standalone}
\begin{document}
\begin{tikzpicture}[scale=0.2]
\definecolor{DannebrogRed}{RGB}{224, 24, 54}
\fill[DannebrogRed] (0,0) rectangle (34,28);
\fill[white] (12,0) rectangle (16,28);
\fill[white] (0,12) rectangle (34,16);
\end{tikzpicture}
\end{document}

Dannebrog

made with color and dimensions from: https://da.wikipedia.org/wiki/Dannebrog. See also https://en.wikipedia.org/wiki/Flag_of_Denmark.

Dannebrog is the oldest continuously used national flag from app. year 1208. A popular legend tells that the flag fell from the sky during a battle as a sign from the gods.

EDIT:

Now implemented as four red squares on a white background instead of a white cross on a red background. -as I was unhappy about the artifacts made by viewer and rasterization.

\documentclass[tikz, border=2mm]{standalone}
\usepackage{pagecolor}
\begin{document}
\pagecolor{black}
\begin{tikzpicture}[scale=0.2]
\definecolor{DannebrogRed}{RGB}{224, 24, 54}
\fill[white] (0,0) rectangle (34,28);
\fill[DannebrogRed] (0,0) rectangle (12,12);
\fill[DannebrogRed] (16,0) rectangle (34,12);
\fill[DannebrogRed] (0,16) rectangle (12,28);
\fill[DannebrogRed] (16,16) rectangle (34,28);
\end{tikzpicture}
\end{document}

Improved Dannebrog

  • 3
    Judging by all the nordic flags, those gods need safety trainings and proper toolbelts to avoid dropping stuff onto peoples' heads. – percusse Jun 27 '18 at 2:33
  • 1
    Do you also have the porcine version? en.wikipedia.org/wiki/Danish_Protest_Pig zoo-hannover.de/de/tiere/tier-lexikon/… – moewe Jun 27 '18 at 10:12
  • 1
    I thought it looked shorter than usual but this is actually the shortest legal version. – pipe Jun 29 '18 at 11:19
  • @pipe - The wikipedia is actually a bit confusing. -one can be led to believe that the dimensions within the interval can be chosen totally free. That is not true. The reason the flag is elongated with a 'slidkant' on the right side, is so that there is extra material to cut off when a cloth flag becomes torn. Also the side away from the pole of a cloth flag seem smaller when waving in the wind - and therefore looks nicer when extended. – hpekristiansen Jun 29 '18 at 20:10
5

For whom it might be of interest ...

Some more fun, using the font CountriesOfEurope

\documentclass{article}
\usepackage[margin=1cm]{geometry}
\usepackage[tiling]{pst-fill}      % PSTricks package for filling/tiling
\usepackage{pst-text}              % PSTricks package for character path
\usepackage[scaled=60]{CountriesOfEurope}

\def\tricolore{%
\definecolor{frenchRed}{HTML}{EF4531}
\definecolor{frenchBlue}{HTML}{0055A4}
\begin{pspicture}(0,0)(15,10)
%% Flagge (Verhältnis 3 Breite : 2 Höhe)
\psframe[linecolor=frenchBlue,fillstyle=solid,fillcolor=frenchBlue](0,0)(5,10)
\psframe[linecolor=white,fillstyle=solid,fillcolor=white](5,0)(10,10)
\psframe[linecolor=frenchRed,fillstyle=solid,fillcolor=frenchRed](10,0)(15,10)
\end{pspicture}
}
\pagestyle{empty}
\begin{document}
\begin{pspicture}(0,0)(18,20)
\psset{boxfillsize={(-0.75\linewidth,-22cm)(0.5\linewidth,15cm)}}
\psboxfill{\psset{unit=20mm}\pspicture(10,10)\tricolore\endpspicture}
\centerline{\pscharpath[fillstyle=solid,fillcolor=white,addfillstyle=boxfill,fillangle=0,fillsep=1mm]{\rput[b](0,-1){\EUCountry{140}}}}
\end{pspicture}
\end{document}

enter image description here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.