New answers tagged

0 votes

Get rid of Type 3 fonts in PDF for manuscript

A useful tool to weed out which files are using which fonts is pdffonts from the poppler package (Mac:brew install poppler, Linux:apt install poppler-utils) e.g.: pdffonts figure1.pdf If you used ...
  • 449
3 votes
Accepted

Koma script: using the fontstyle of chapter and section for a paragraph

The font settings of the chapter (section) title are stored in the font elements dispostion and chapter (section). They can be enabled using \usekomafont{disposition}\usekomafont{chapter} or \...
  • 83.7k
3 votes

Adjust italic correction for a math symbol for subscripts

This is not an answer, but too long for a comment. The problem you see is the following (as has been told, but with the boxes shown): The f in the Dejavu Math font has a rather wide side bearing. The ...
  • 6,885
1 vote

Koma script: using the fontstyle of chapter and section for a paragraph

Please try this code. \RequirePackage{fix-cm}% needed when using Computer Modern typefaces \documentclass[ fontsize = 10pt, twoside, toc=listofnumbered, listof=flat, headinclude, footinclude, index=...
5 votes

Adjust italic correction for a math symbol for subscripts

Since you're using LuaLaTeX, you could (a) define a Lua function that does the subscript kerning correction and (b) assign it to LuaTeX's process_input_buffer callback, so that it can act as a pre-...
  • 469k
1 vote

Italic (math) units with siunitx, kpfonts and lualatex

In v3, siunitx aims to create as far as possible the same math mode intermediate content as one would be hand for typesetting units: here \mathrm{F} with the standard settings. As a result, you are ...
  • 251k
0 votes

Misalignment with bold font and additional symbols in siunitx

See, if the following solution is acceptable to you: \documentclass{article} \usepackage[showframe]{geometry} \usepackage[T1]{fontenc} \usepackage{xcolor} \usepackage{tabularray} \UseTblrLibrary{...
  • 276k
4 votes

Misalignment with bold font and additional symbols in siunitx

Your \hl{...} macro acts as a barrier which siunitx cannot look into. Perhaps use \hlx -0.123\sym{***} instead Where \NewDocumentCommand\hlx{}{\color{highlightColor}\bfseries} and \sym is modified to ...
  • 51.3k
2 votes
Accepted

How to use Helvetica Neue in a beamer template on Overleaf?

You can set the sans font, this should change (more or less) everything: % !TeX TS-program = lualatex \documentclass{beamer} \usepackage{fontspec} \setsansfont{TeX Gyre Heros} \title{Title} \...
0 votes

Beamer metropolis math font

The easiest way to use computer modern font with the metropolis theme is to simply not compile with xelatex/lualatex. If you compile with pdflatex, the theme will automatically use the default ...
4 votes
Accepted

How to change the font for an entire row in tabularray?

\documentclass{article} \usepackage{tabularray} \font\andk=andk-Bold-tlf-sc-t2b \begin{document} \begin{tblr} { colspec = {Q[l,m]Q[l,m]Q[c,m]}, row{3} = {cmd=\andk}, hline{1,Z} = {wd=.08em}, ...
  • 3,632
3 votes

How to change the font for an entire row in tabularray?

This may not be what you are looking for, but here is a solution that uses fontspec. In this example, I've changed the font of row 3. \documentclass{article} % \usepackage{tabularray} \UseTblrLibrary{...
1 vote

how to get good looking copyright and registered symbols

getting inspired by all of you: \textsuperscript{\textregistered} works for me, even without typing \usepackage{textcomp} hope it works for you guys as well!
0 votes

How do I get the LuaTex fonts to show up?

Is it possible that you downloaded the ARM version of LyX, instead of the Intel version? I had problems with fonts, too, on my M1 ARM MacBook Air. Download the Intel (LyX-2.4.0-beta2+qt5-x86_64-cocoa....
3 votes
Accepted

Help with some special characters (░█)

Firefox reported it used a font Cascadia Mono to show your question, so I told lualatex to use the same. You may have different fonts, but you can use whichever font your browser finds for these ...
3 votes
Accepted

change font used for forest package

Oh dear, turns out this was an extremely elementary question. The answer is: make sure to compile using xelatex rather than pdflatex! I'll leave this question up rather than deleting it just in case ...
  • 1,387
2 votes
Accepted

How can I switch back to Computer Modern in formulas within XeLaTeX?

If you want to keep Latin Modern as the default text and math font, don't execute \setmainfont instructions. Conversely, if you do want to switch the main text font to Linux Libertine O, you should ...
  • 469k
5 votes

XeLaTex does not show unicode symbol

You can use your preferred font, not necessarily one that has that character. The character is present, for instance, in Menlo (a macOS font). \documentclass{article} \usepackage{fontspec} \usepackage{...
  • 1.1m
9 votes
Accepted

XeLaTex does not show unicode symbol

xelatex reports Missing character: There is no ♘ (U+2658) in font [lmroman12-regular]:mapping=t ex-text;! As Latin Modern does not have this character. albatross U+2658 will list fonts you have ...
0 votes

Why can't I change this CV template's font?

Embedding your fragment of code into a plain document and running it on a current TeX Live changes the fonts to any of the fonts listed in the commented lines if you uncomment those particular line. ...
  • 208k
0 votes

Pale lmtt fonts and can't be made in italics or bold

Your question is not clear as you provided no example but lm typewriter is available in slanted and slanted bold. \documentclass{article} \renewcommand\familydefault{\sfdefault} \renewcommand{\...
0 votes
Accepted

Main language not reselected correctly if previous section ends with other language and section title starts with other language

As suggested by Ulrike Fischer, using \newcommand{\heb}[1]{\bgroup\selectlanguage{hebrew}\RL{#1}\egroup} fixes the issue.
  • 5,097
2 votes
Accepted

x-height correction for different fonts

You may use two font families, with different scaling factors, for uppercase and lowercase. \documentclass{article} \usepackage{arevmath} \usepackage{amsmath} \usepackage{bm} \DeclareFontFamily{U}{...
  • 1.1m
0 votes

How do I get babel to use the same typeface for regular and bold Hebrew text?

This is a very old post deserving of an update. With babel it’s recommended relying on lualatex. Here is an example (random text from Wikipedia): \documentclass{article} \usepackage[hebrew, bidi=...
  • 8,888
1 vote
Accepted

Problem or feature: Package gfsartemisia-euler changes ú for ý when using \textsc

It is indeed a bug in the T1 version of GFSArtemisia. This is the part of the fonttable corresponding to Latin smallcaps: You can see that Ý is listed twice while the first entry should be Ú. This ...
  • 34.5k
0 votes

Springer Nature template - no citations & font issue

With the references, I think this helps. Try checking this one for the font size issue.
1 vote

Change font in minted Python

I don't know how to do that with minted, but I can say that, with piton (a LuaLaTeX package designed to format Python listings), it's very easy to change the styles of the different syntaxic elements. ...
  • 31.1k
0 votes
Accepted

Format contents titles the same as section titles

The formatting of the table of contents can be customized with titletoc, a companion for titlesec. \documentclass{article} \usepackage{titlesec} \usepackage{titletoc} % format section title \...
  • 18.9k
1 vote

What is the simplest way to typeset an entire document in sans-serif?

You can use the fontsetup package for easy configuration of fonts if you are willing to use XeLaTeX/LuaLaTeX. It supports two sans serif fonts Fira Sans and GFS Neohellenic, both with math support as ...
0 votes

What is the simplest way to typeset an entire document in sans-serif?

No existing solution I found on SE or elsewhere worked for me, with the most common problem being pixelated math fonts. After testing many random packages and commands, I finally pieced together ...
  • 950
2 votes
Accepted

PDFLaTeX Font conflict (LuaLaTeX OK) XCharter + roboto-light get no Charter italics

latex does warn you LaTeX Font Warning: Font shape `T1/XCharter-TLF/l/n' undefined (Font) using `T1/XCharter-TLF/m/n' instead on input line 112. so there is no light Xcharter normal ...
1 vote

LyX menu font size too small

Reboot solved a similar issue for me.
  • 111
2 votes

How can I get a list of all \fontfamily{...}\fontseries{...} combinations?

This website might help. Useful to check fonts available. https://tug.org/FontCatalogue/
0 votes
Accepted

How can I set math font to a custom TrueType font?

You can declare the font as a math font and declare digits use it: \documentclass[10pt,a4paper]{article} % not in xetex \usepackage[utf8]{inputenc} \usepackage{amsmath} \usepackage{amssymb} \...
6 votes

Why should I not use EC fonts with XeTeX?

XeTeX and LuaTeX read Unicode input (files in UTF8) and works internally in Unicode. I.e. it expects Unicode fonts, it loads hyphenation patterns in Unicode. The EC fonts were designed immediately ...
  • 63.3k
0 votes

how to use a webfont in a Sphinx build environment?

thanks for the headstart àscd, I finally managed to make it work: first step as you mentioned move to XeLaTex compiler: # conf.py latex_engine = "xelatex" Then use the fontspec package: # ...
1 vote
Accepted

How to change the font of a MetaPost?

Just in case you are able to switch to lualatex, here is one way to get what you want: \documentclass{article} \usepackage{sourcesanspro} \renewcommand{\familydefault}{\sfdefault} \usepackage{luamplib}...
  • 39.1k
2 votes
Accepted

xepersian problem with HM fonts

I see no special cases for HM as there were in some early versions, and the same output for a renamed font The xepersian-hmpackage loads xepersian then adds some extensions including better support ...
4 votes
Accepted

How to create PDF output in exactly 11pt font?

You can use the anyfontsize package to select a choice font size. In TeX, 1pt=1/72.27in while in Adobe and most contemporary applications, 1pt=1/72in. (See: Why does a TeX point differ from a Desktop ...
2 votes
Accepted

Sans Serif and Roman Sigma with Source Sans Pro and Charter

I guess you want to modify \mathsf to point to the default sans serif font (in OT1 encoding). \documentclass{article} %\usepackage[utf8]{inputenc}% no longer needed \usepackage[T1]{fontenc} % fonts \...
  • 1.1m
0 votes

Reduce font size of particular line in algorithm and algorithmic pseudocode

Rather than reducing the font size, I'd split the formula across lines. \documentclass[twocolumn]{article} \usepackage[a4paper, total={6in, 8in}]{geometry} \usepackage{amsmath} \usepackage{algorithm} ...
  • 1.1m
0 votes

Reduce font size of particular line in algorithm and algorithmic pseudocode

You can use the \resizebox in graphicx such as: \STATE \resizebox{\linewidth}{!}{\ $w_h^{k,j} = w_h^{k,j-1} - \eta_k \nabla L_k^h(w_h^{k,j-1}) + \sqrt{2\eta_k \beta_k^{-1}}\epsilon_h^{k,j}$}
  • 3,632
9 votes

Too much space in \begin{bfseries} as compared to {\bfseries ...}

In my opinion, the idea that \begin{env} is a wrapper for \env is a design mistake of LaTeX. Alas, it's not really possible to change this after 40 years. There are no environments called bfseries, ...
  • 1.1m
5 votes
Accepted

Too much space in \begin{bfseries} as compared to {\bfseries ...}

Description insert %, so no space is inserted at the end of the line (in code) or simply use \textbf{...} Result Code \documentclass[12pt]{article} \begin{document} A sentence with \begin{bfseries}...
  • 7,402
1 vote
Accepted

Line breaks don't work properly when fontspec uses as main font some fonts different from default Latex font

Adding \sloppy resolves all overflow boxes in this example. % !TeX program = lualatex \documentclass[12pt]{article} \usepackage[a4paper, total={180mm,257mm},left=15mm,top=20mm,showframe]{geometry} \...
  • 35.8k
0 votes
Accepted

How can I produce italic Georgia font in a title page, via a custom class?

(Credit here to the comment by Ulrike Fischer; I'm happy to accept their answer instead if they post one) I'm still unclear as to why the less-global font declaration let me make the author line ...
  • 483
2 votes
Accepted

Bold font in Metropolis looks too heavy

You can change the bold font for title using fontspec package. \documentclass{beamer} \usepackage{fontspec} \usetheme{metropolis} % Metropolis default font below? Bold font looks too heavy \...
  • 1,428
6 votes
Accepted

Why should I not use EC fonts with XeTeX?

The encoding is wrong for plain tex so you will get incorrect characters for example \font\tenrm=ecrm1000 \def\rm{\tenrm} \rm éducation % French virtù % Italian Constitución % Spanish Fuß % German \...
7 votes
Accepted

How to define \sc in TeX?

Sorry, but if you insist in using plain TeX, you'll get into troubles with this font. \font\tensc=eccc1000 {\tensc \'a\`a\"u\c{a}\={a}\d{a}} \bye Oops! What happened? The EC fonts are encoded ...
  • 1.1m
6 votes
Accepted

How can I create a new command that has italic text based on \caption command?

I suggest the following: \usepackage{caption} \captionsetup[figure]{font=it} \documentclass{article} \usepackage{caption} \captionsetup[figure]{font=it} \begin{document} \begin{table}[h] \caption{...
  • 469k

Top 50 recent answers are included