16

I want to create a macro that typesets the text "julia" with two slanted dots above the "ia" at the end, so it looks like this:

   _       _ _(_)_     
  (_)     | (_) (_)    
   _ _   _| |_  __ _   
  | | | | | | |/ _` |  
  | | |_| | | | (_| |  
 _/ |\__'_|_|_|\__'_|  
|__/                   

Since \.a gives me a dotted a, I thought maybe I could use \.{i\.a} to produce the third dot, but it didn't work - jul\.{i\.a} just outputs "juli".

Actually, I'm looking to recreate the logo at julialang.org.

Is there a way to get all the dots there?

3
  • 1
    I know the tag "fonts" isn't the best, but I had no idea what to tag this and it was suggested by the site. Please feel free to retag. May 9, 2013 at 12:39
  • 2
    Your reference below to the julia language icon suggests that you'd be better off asking for an equilateral triangle of dots over the ia rather than a mark over the a. @barbarabeeton 's answer seems to come closest. May 9, 2013 at 13:51
  • By the way, you might consider changing the title of this question to something along the lines of "Making a LaTeX version of a textual logo", since it has turned out that diacritics and umlauts are not really what this question is about. May 11, 2013 at 15:31

5 Answers 5

24

Here is my attempt.

A julia logo

I tried to emulate the original julia logo from julialang.org. Some features:

  • The positioning of the dots is relative to the x-height of the current font, which means that they should stay in the right position if the font size changes.
  • The word "julia" is set in the cmss (Computer Modern sans serif) font, which means the logo won't change if you change your default sans serif font to Helvetica or something.
  • The \julia command is declared as a 'robust' command, which means that it can safely be used inside section headings and so on. See the picture below:

A julia logo, shown at various text sizes

Here is my code:

\documentclass{article}

\usepackage{tikz}
\usetikzlibrary{positioning}
\usetikzlibrary{calc}

\definecolor{mylightred}{RGB}{211,79,73}
\definecolor{mydarkred}{RGB}{199,44,38}
\definecolor{mylightgreen}{RGB}{78,153,67}
\definecolor{mydarkgreen}{RGB}{43,129,33}
\definecolor{mylightpurple}{RGB}{150,107,178}
\definecolor{mydarkpurple}{RGB}{126,78,160}
\definecolor{mylightblue}{RGB}{49,101,205}
\definecolor{mydarkblue}{RGB}{20,92,205}

\tikzset{
  juliadot/.style args={#1,#2}{shape=circle,line width=0.03ex,minimum width=0.4ex,fill=#1,draw=#2}
}

\newcommand\julialetter[1]{{\strut\fontfamily{cmss}\bfseries\selectfont{#1}}}

\DeclareRobustCommand\julia{%
\begin{tikzpicture}[baseline=0mm, every node/.style={inner sep=0mm, outer sep=0mm}]
\node[anchor=base]        (j) at (0,0) {\julialetter{\j}};
\node[anchor=base, right=0ex of j] (u) {\julialetter{u}};
\node[anchor=base, right=0ex of u] (l) {\julialetter{l}};
\node[anchor=base, right=0ex of l] (i) {\julialetter{\i}};
\node[anchor=base, right=0ex of i] (a) {\julialetter{a}};
\path let \p1 = (j) in node[juliadot={mylightblue,mydarkblue}] (bluedot) at (\x1+0.02ex,1.4ex) {};
\path let \p1 = (i) in node[juliadot={mylightred,mydarkred}] (reddot) at (\x1,1.4ex) {};
\path let \p1 = (reddot) in node[juliadot={mylightpurple,mydarkpurple}] (purpledot) at (\x1+0.5ex,\y1) {};
\path let \p1 = (reddot) in node[juliadot={mylightgreen,mydarkgreen}] (greendot) at (\x1+0.25ex,\y1+0.42ex) {};
\end{tikzpicture}%
}

\begin{document}

\section{The \julia\ logo}

\parbox{8cm}{
\tiny Here is a {\julia} logo.
\small The {\julia} logo is made using TikZ.
\normalsize The dimensions in {\julia}'s logo are relative,
\large so {\julia} scales quite nicely,
\LARGE when {\julia} is big, and even
\Huge when {\julia} is huge.}

\end{document}
4
  • This looks fantastic! Great! Is it possible to make it work also in section headers, titles etc? (Try adding \section{\julia} to your document for error output...) May 10, 2013 at 9:23
  • Yes, I have edited my answer to make \julia a robust command, so it should now work in section headings and titles. May 11, 2013 at 13:27
  • Again, this is brilliant - thanks a lot! Do you mind if I put together a small LaTeX package with this code and publish on e.g. github and/or CTAN? I'll of course make sure that you get the credit for this code. May 11, 2013 at 13:36
  • Not at all, glad to help :). May 11, 2013 at 13:38
12

here is an absolute kludge. the amounts of kern may need to be adjusted depending on the size used for setting it.

\documentclass[12pt]{article}
\begin{document}
\large
\thispagestyle{empty}
jul\.\i\raisebox{.4ex}{\kern-.1em\.{}\kern-.2em}\.a
\end{document}

output from sample code

(from the verbal description, it sounded like you were describing the "hungarian umlaut", but that's not what your graphic shows. i've tried to match the graphic.)

here's another try, with three dots in a triangle, and an unadorned "julia" for comparison. again, full code, and caveat that the amount of kerning really is size-dependent.

\documentclass[12pt]{article}
\usepackage{graphicx}
\begin{document}
\huge
\thispagestyle{empty}
\scalebox{2}{julia}

\scalebox{2}{%
\leavevmode\rlap{julia}%
jul\.\i\raisebox{.4ex}{\kern-.15em\.{}\kern-.125em}\.{\kern-.27em}a}

\end{document}

enter image description here

7
  • jul\.\i\raisebox{.5ex}{\kern-.07em\.{}\kern-.2em}\.a seems a tad better.
    – jub0bs
    May 9, 2013 at 13:15
  • Actually, I'm looking to recreate the logo at julialang.org, so this is quite close. I've been experimenting with the kerning a little, trying to get the two rightmost dots to move a little left without bringing the a with them, but since I don't really understand what's going on, I'm not doing so well... May 9, 2013 at 13:19
  • @Jubobs -- thanks for enlarging the image, but i fear that the kerning between the "i" and the "a" got a bit tighter than it was originally. (that's the reason i included the entire code, which i usually don't do. the kerning should ideally be the same as if there were no diacritics at all.) May 9, 2013 at 13:45
  • @barbarabeeton Sorry, I had good intentions. Feel free to revert to your original post.
    – jub0bs
    May 9, 2013 at 13:57
  • 1
    @barbarabeeton: I'm glad I've been able to nerd-snipe you ;) I'm very grateful for all attempts at this - it is really beyond my LaTeX skills, but I would be very excited to have a working macro. Thanks a lot just for trying! May 9, 2013 at 16:38
9

Maybe simply:

\documentclass{article}

\begin{document}

\huge
Jul${\textrm{\i}}\dot{\ddot{}}$a

\end{document}

enter image description here

3
  • Yes, this is quite good actually =) May 9, 2013 at 13:45
  • \i gets a complaint about being invalid in math mode. you can use \textrm instead to get rid of the complaint. May 9, 2013 at 13:54
  • why not simply place the \i outside of the $...$?
    – waldyrious
    May 12, 2013 at 12:59
4

MWE

\documentclass{article}
\usepackage{amssymb}
\begin{document}
Jul\i\raisebox{.55em}
{\kern-.2em \tiny\ensuremath{\therefore}}\kern-.3em a
\end{document}

One more:

enter image description here

\documentclass{article}
\begin{document}
Julia, Juli\kern-.85em\raisebox{-.01em}{
\r{ }\kern-.6em\raisebox{.2em}{\r{ }}\kern-.6em\r{ }
}\kern-.9em \ae 
\end{document}
2

I tried a combination of \makebox and \raisebox:

juli\makebox[0pt][c]{\raisebox{0.5ex}{\.{}}}\.a

This is quite similar to barbara beeton's answer but uses a zero-width \makebox instead of \kerning.

EDIT: However, having looked at the OP's source I've decided it's a bit ugly; the dot above the a is too close far from dot between the i and the a. \kerning seems to be a better solution, IMHO.

I also looked into using the \therefore command from amssymb but it was broadly unworkable - the symbol has too much space in normalsize but the dots are weirdly small in tiny or scriptsize.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .