1

Currently using a template from my university that uses this to define font:

 \def\titlefont{\rmfamily}

AND

 \setsansfont[
    Path = fonts/,
    Extension = .ttf,
    BoldFont = *-Bold,
    ItalicFont = *,
    ItalicFeatures = FakeSlant,
    BoldItalicFont = *-Bold,
    BoldItalicFeatures = FakeSlant
]{Tahoma}

AND

\renewcommand*\familydefault{\sfdefault}

Now, I must admit I am fairly new to working with XeLaTeX, so I have tried to find a solution to make the Tahoma now used one or two sizes smaller, but I could not find it. I have tried using scale and size and variations of this:

\newcommand{\bigfont}[1]{% \fontspec[Ligatures={Common,Rare}]{Zapfino}% \fontsize{30pt}{36pt}\selectfont #1}

but no actual luck.

Can someone help me out?

Thank you in advance.

5
  • 2
    Welcome to TeX SX! Could you post a small compilable code that we can play with?
    – Bernard
    Apr 14 '19 at 12:01
  • If using a "template" the font sizes are presumably fixed to be standard for all submissions . So first question is why are you needing to change from what the instructions give as perceived "requirements" the most likely location is in the style/classes files but you could try \small \large \Huge
    – user170109
    Apr 14 '19 at 20:02
  • If the reason you want Tahoma to be slightly bigger or smaller than the other fonts in your document, you want to add the command \defaultfontfeatures{Scale=MatchLowercase} before you load your fonts. If you do this, also add the font feature Scale=1.0 to \setmainfont. It’s a good idea to do this by default.
    – Davislor
    May 15 '19 at 15:48
  • If you want to make the font bigger or smaller in one place, you can use commands like \large, and if you want to select a specific point size, use \fontsize.
    – Davislor
    May 15 '19 at 15:50
  • Finally, if you just want all the text in your document to be bigger, you can pass the option 12pt or 14pt to your \documentclass.
    – Davislor
    May 15 '19 at 15:51
1

The usual way to set a font, let's say Tahoma is this one :

\setmainfont[
Scale=1,Ligatures={TeX},
BoldFont={Tahoma Bold}, 
ItalicFont={Tahoma Italic},]{Tahoma}

Using that, it doesn't matter if you have serif or sans since it's your main font.

Then you just have to do this in order to have a 5 size factor in your font :

\newfontfamily\font5{Tahoma}[Scale=5]

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.