# Latexit - using \displaystyle for larger inline math

I am using Latexit to generate latex for some powerpoint slides. LatexIt is an equation editor that makes it easy to generate equations and export them as PNG, PDF, SVG, etc to use in other programs, without going through the hassle of creating a full document yourself. Its website is:

https://www.chachatelier.fr/latexit/

My problem: I can't seem to get the inline math characters to be larger using \displaystyle:

this is a test sentence for $\mathcal{D}$ inline math $f$ in $g$ this sentence.

renders as:

I want the characters to be larger, bolder, etc.

My Minimum Working Example illustrating the problem consists of the template below, and the line above.

My template is:

\documentclass[10pt]{article}
%\usepackage[utf8]{inputenc} %useful to type directly diacritic characters
\usepackage{fontspec}
\setmainfont{Roboto}
\usepackage[usenames]{color} %used for font color
\usepackage{amssymb} %maths
\usepackage{amsmath} %maths
\usepackage{xcolor}

% Seaborn Colors
\definecolor{seabornBlue}{RGB}{76,114,176}
\definecolor{seabornGreen}{RGB}{85,168,104}
\definecolor{seabornRed}{RGB}{196,78,82}

% FLAT UI COLORS
\definecolor{orangePumpkin}{RGB}{211,84,0}
\definecolor{orangeCarrot}{RGB}{230,126,34}
\definecolor{blueBelizeHole}{RGB}{41,128,185}
\definecolor{redAlizarin}{RGB}{231,76,60}
\definecolor{redNasturcianFlower}{RGB}{232,65,24}

% Color shortcuts
\newcommand{\blue}[1]{\textcolor{blueBelizeHole}{#1}}
\newcommand{\green}[1]{\textcolor{seabornGreen}{#1}}
\newcommand{\red}[1]{\textcolor{redNasturcianFlower}{#1}}
\newcommand{\orange}[1]{\textcolor{orangeCarrot}{#1}}
\newcommand{\vecb}[1]{\mathbf{#1}}

• The preamble you posted bears no relation with the issue you are reporting. The standard behavior in LaTeX is to have the sizes of the fonts used in mathematical formulas scale with the size of the text they are embedded in, so there’s something strange in the behavior you reported. Please add more details and provide a Minimal Working Example. – GuM Mar 20 '18 at 18:44
• @guM This isn't as trivial to do as it seems, since LaTeXit is an app designed for making snippets of code, so a traditional MWE might not be of help. – Alan Munn Mar 20 '18 at 19:11
• @AlanMunn: It’s not clear, actually, what the OP is doing: (s)he seems to be writing an article using some “template” source code, isn’t (s)he? – GuM Mar 20 '18 at 19:14
• @GuM No. This is the preamble for the snippet maker. It's a Mac program. – Alan Munn Mar 20 '18 at 19:16
• thank you @AlanMunn, I've edited the question with more details about latexit. – user79950 Mar 20 '18 at 19:30

I don't have the Roboto font, so I can't test this exactly, but with the following preamble:

\documentclass[10pt]{article}
\usepackage[svgnames]{xcolor} %used for font color
\usepackage{fontspec}
\setmainfont[Scale=MatchLowercase]{DejaVu Sans}
\usepackage{amssymb} %maths


I get the following output:

So try loading adding the [Scale=MatchLowercase] option to your \setmainfont command.

Using the Roboto font I get a similar result:

• thanks for your response Alan. It seems that does work, when I downloaded and installed DejaVu Sans. It did not work with Roboto font. I'm not sure why that matters, as I am just trying to render the latex math font larger. – user79950 Mar 20 '18 at 19:38
• @user79950 That's odd, since I just downloaded Roboto and it works for me. – Alan Munn Mar 20 '18 at 19:40
• hm. I had to first render with DejaVu, see it, then change to roboto, restart, and it worked. Not sure whats going on, but I will accept this answer. Thanks! – user79950 Mar 20 '18 at 20:05
• do you know how to make it larger than that? – user79950 Mar 21 '18 at 22:24
• @user79950 You can try adding \DeclareMathSizes{10}{12}{9}{7} to the preamble. See how to scale math font only for more details. – Alan Munn Mar 22 '18 at 2:09