38

I have tried to search, but I have not been able to found any repository with the flags of the most common countries defined with TikZ. It must be very possible as most flags are really vectors.

7
31

Update

Sadly, this solution no longer works (as of TeX Live 2015). In the change history of minitoc:

2015/07/13

  • Jean-Pierre F. Drucbert passed away in 2009. So this package is now looking for a maintainer.
  • Reduce size of documentation, by eliminating flags and other images, from 25+mb to less than 2mb.

You can retrieve the original version of the documentation from the TeXLive historic archive here.

Original answer

The astonishingly bizarre documentation for the minitoc package has done most of the work for you. (Although with .png images.) So for any flag you can think of the following will work: (You can also find maps as well.)

\documentclass{article}
\usepackage{graphicx}
% change the year to match your current distribution up to 2014
\graphicspath{{/usr/local/texlive/2010/texmf-dist/doc/latex/minitoc/}}
\begin{document}
\includegraphics[width=.3\textwidth]{brazil-f}
\includegraphics[width=.3\textwidth]{vanuatu-f}
\includegraphics[width=.3\textwidth]{belarus-f}
\end{document}

Just for entertainment, here are the flags of Brazil, Vanuatu, and Belarus.

Brazil Vanuatu Belarus flags

7
  • 14
    That is weird
    – Seamus
    May 18 '11 at 16:26
  • 1
    Note: This won’t work with MiKTeX – for two reasons: especially for this package the flag files are not included in minitoc’s documentation directory, and generally the whole documentation subtree is unfortunately not included into the filename database. One could, of course, install all missing files in a local texmf tree and then give the absolute path or use \graphicspath – or put the needed files into the document directory.
    – Speravir
    Nov 6 '12 at 3:20
  • 5 interesting flags: Poland, Indonesia, Monaco, Austria, and Peru. Nov 6 '12 at 4:21
  • 1
    @pasbi No it doesn't. The package was changed in 2015 and all the flags were removed. I've updated the answer.
    – Alan Munn
    May 27 '19 at 12:59
  • 1
    @pasbi There is a new package, now. See my answer: tex.stackexchange.com/a/594051/101651
    – CarLaTeX
    Apr 22 at 19:52
11

Now (April 2021) there is!

Wilhelm Haager created the package worldflags.

Here some examples:

\documentclass{article}
\usepackage{worldflags}
\begin{document}
\begin{center}
Standard flags

\worldflag{IT}
\worldflag{BR}
\worldflag{AD}\vspace{10pt}

Flags with special dimensions

\worldflag{CH}
\worldflag{GB}
\worldflag{VA}\vspace{10pt}

There are also some options 

(for the complete list see the package documentation)

\worldflag[length=3cm]{EU}
\worldflag[grid]{UNO}
\worldflag[noemblem]{EC}
\end{center}
\end{document}

enter image description here

3
  • Very nice, I had to update everything on MikTeX to be able to use it as the package is very new! Although I have to add, that for some flags using an aspect ratio where the horizontal length is smaller than the vertical width results into an odd output. An example of what I mean can be seen when using \worldflag[length=1cm, width=2cm]{US}.
    – owmal
    Apr 24 at 18:14
  • 1
    @owmal Unfortunately, I'm not the package author, you should write to him to report the bug.
    – CarLaTeX
    Apr 24 at 18:37
  • Thank you, I have just contacted him. :)
    – owmal
    Apr 24 at 21:17
8

bclogo also includes some of them in format .mps.

enter image description here

1
  • 3
    The set is quite limited though. The flags included in the answer of @Ignasi (6 November 2012) are the only ones currently included (checked on 19 January 2016).
    – O0123
    Jan 19 '17 at 11:08

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.