Questions tagged [fontspec]

{fontspec} is a package for loading {opentype} fonts in XeLaTeX and LuaLaTeX.

Filter by
Sorted by
Tagged with
2
votes
1answer
46 views

“CMU Serif” font is not found by fontspec

When I compile a document using the CMU Serif font: %!TeX program = xelatex \documentclass{article} \usepackage{fontspec} \setmainfont{CMU Serif} \begin{document} Lorem ipsum... \end{document} I ...
3
votes
1answer
212 views

Writing ॐ in latex

I am trying to write a document in Bengali, where at a point I need to write the sanskrit letter ॐ. However, I am not able to write it yet. Here is my working example: \documentclass{article} \...
0
votes
1answer
27 views

Cantonese characters in LaTeX (Ubuntu)

I'm trying to type the characters 部機都冇咗嘞。in a LaTeX document, but I've never done it before (this sentence can be found in sentence #9 in this Universal Dependencies Github repository). I tried \...
1
vote
1answer
34 views

Why hindi is not getting typeset in this example?

\documentclass[12pts, a4paper, twocolumn, columnsep= 4 mm]{article} \usepackage{fontspec, polyglossia} \usepackage[Devanagari]{ucharclasses} \setmainfont{Calibri} \setTransitionTo{Devanagari}{\...
5
votes
1answer
155 views
+100

LuaLaTeX: Smarter font selection macro for super-families

Fontspec with LuaLaTeX works well for small font families, but appears cumbersome to use with super-families. A modern super-family can contain tens of fonts in Weight/Width/Slope (WWS) matrix. As an ...
1
vote
2answers
35 views

Why error is coming when using listings in polyglossia package?

The complete file is here. MWE: \documentclass[11pt,fancy,authoryear,twoside]{elegantbook} %-------------------------------------------------- %Bengali Font in Document %--------------------------...
1
vote
1answer
47 views

How to use fontspec in details?

I would like to use the fontspec package to change the font family. I use four different fonts in the same document and want to create a font family based on the fonts installed on my Windows machine, ...
0
votes
1answer
19 views

Adding Font Features to only certain Font Shapes

How do I add some font features (such as ligatures) to only certain font shapes? The ideas is to disable ligatures for RB, RBI shapes, etc. since they give me a warning anyway. I briefed over the ...
1
vote
1answer
66 views

Why doesn't chapter number show when elegant book class uses polyglossia package?

When elegantbook class (3.11) uses polyglossia package it does not show chapter number at header? MWE: \documentclass[11pt,fancy,authoryear,twoside]{elegantbook} \usepackage{lipsum} %-------------...
3
votes
1answer
49 views

Fontspec - Italic small caps with semi-bold

I have problems when I use small italic capitals with a "non-standard" font weight (here semi-bold). I tried several things like FontFace={sb}{it}{Font=LinLibertine_RZI_G. ttf, ...
1
vote
0answers
114 views

example from “novel” book class does not compile

I tried to compile the example document novel-example.tex delivered as part of the novel package. The compilation terminated with the message: ! Package fontspec Error: The font "LatinModernRoman&...
3
votes
1answer
82 views

Chapter number is not showing in elegantbook class for Bengali

MWE: \documentclass[11pt]{elegantbook} %-------------------------------------------------- %Bengali Font in Document %-------------------------------------------------- % For a bilingual document \...
3
votes
0answers
49 views

Change a font weight

I want to create a new font family with \newfontfamily{\rb}{Roboto} from here: https://fonts.google.com/specimen/Roboto?subset=latin&preview.text=Hello&preview.text_type=custom#standard-styles ...
5
votes
2answers
78 views

,,Improper \halign inside $$'s`` with lmodern/microtype/fontspec

This is less of an actual problem than a "why does this happen" question. When working on a larger document, I started getting spurious and (to me) inexplicable Improper \halign inside $$'s. ...
2
votes
2answers
78 views

Define different fonts for different scripts

I'm trying to define different fonts for different scripts, Latin and Greek. I'm currently using Linux Libertine O as my main font, which includes support for Greek, but I would like to try using a ...
8
votes
1answer
59 views

emshape undefined

In the following example the line \renewcommand\emshape works fine on one Linux computer using Kile but has to be commented out on another Linux computer also using Kile. There are not other ...
1
vote
1answer
40 views

Use FiraCode ss01 font feature with fontspec and LuaLaTeX

How can I set specific stylistic sets of a font (ss01, ss03, but not ss02) with fontspec and LuaLaTeX? For instance, with the FiraCode font. This question is not a duplicate of How to replace a letter?...
1
vote
1answer
47 views

\\selectlanguage{} cumulates word spacings in non-normalsize environments

The following MWE shows an effect where the word spacing in non-normalsize-d text blocks "grows" with every \selectlanguage that introduces a previously unused language (using lualatex): \...
0
votes
0answers
45 views

How to use / importing Calibri font into Overleaf with LuaLaTeX compiler

I'm trying to get a Calibri font to work on Overleaf for the entire document with the LuaLaTeX as the compiler. I'm a bit new to LuaLaTeX. Currently, I have defined a folder, called Fonts, which has ...
2
votes
1answer
80 views

In a typical document where does sans font apply?

I am learning about the fontspec package to load fonts when compiling with Xelatex. I am aware of three types of fonts - mainfont which applies to the main text in paragraphs, monofont which applies ...
3
votes
0answers
38 views

Badly formed hyperref link boxes when using certain fonts with fontspec in XeLaTeX

Question: How to use fontspec fonts so that hyperref boxes are well formed and not too high? Solved: I don't know why but adding Extension=.ttf inside setmainfont options solves this. What I expected: ...
1
vote
1answer
106 views

Windows/Unix Xelatex font usage with fontspec and ttf fonts semi-bold weight

I'm trying to write a file, that compiles both on windows and unix (I'm using the alpine-tinytex image, but the answer should be portable across *nix). I would like to use the semi-bold fontface of ...
1
vote
1answer
45 views

R Markdown LaTeX Tufte font cannot be found

I'm new to getting LaTeX working in R Markdown and have the following error when I tried to knit the tufte template from github: ! Package fontspec Error: The font "Kaiti SC" cannot be found....
0
votes
2answers
52 views

How to get CMU small caps as a separate font?

CMU bold small capitals work for me with \usepackage[T1]{fontenc} but not with \usepackage{fontspec}. Is there a way to get a separate CMU font that only has small capitals? When I buy fonts they come ...
0
votes
1answer
21 views

Problem placing numbers after Vedic accents in Tamil

I am having a problem placing a number after a vedic accent in Tamil. The minimum map file is ********************************************************************** LHSName "tamv" RHSName &...
1
vote
0answers
38 views

Minion Pro + fontspec = very strange kerning

I have an MWE, mostly derived from this answer: \documentclass{article} \usepackage{fontspec} \setmainfont[ UprightFeatures={ SizeFeatures={ {Size={-8.4},Font=MinionPro-Capt}, ...
0
votes
0answers
29 views

Foreign-Language support in \part, \Section, etc

I have a document with a lot of different languages, some of which appear in \part{}, \section{}, etc. blocks. For example, the following MWE: \documentclass[12pt,a4paper,oneside]{scrbook} \...
1
vote
1answer
30 views

how can I change an arbitrary portion of my document to monospaced/typewriter font in xetex?

I want to put arbitrary portions of my text into a font that looks like it came out of a 1960s manual typewriter. In particular, each character must occupy a column, identical in width to all other ...
0
votes
1answer
42 views

Chinese text in English scrbook with luatexja-fontspec and polyglossia

I have the following document: \documentclass[12pt,a4paper,oneside]{scrbook} \usepackage{fontspec} \makeatletter \usepackage{csquotes} \usepackage{luacode} %\usepackage[UTF8]{ctex} \usepackage{...
4
votes
1answer
73 views

Straight quote literals when using LuaTeX and fontspec

This is a similar question to How to get straight quotation marks?, but in my case, I want literal ' and " marks to stay that way, as I use Unicode curly quotes when I want curly quotes. Is there ...
1
vote
2answers
40 views

Access and use $HOME environment for setting the path for a new font

I want to use a font I just downloaded for a document class I created. This document class will be used on other workstations so I would like the path of the font not to be "hardcoded" but ...
1
vote
1answer
50 views

Problem with Cyrillic in resume with XeLaTeX and fontspec

So I'm fairly new to TeX but managed to make myself a decent resume using quite a well-known Deedy-Resume template. I use overleaf to complie my .tex code into pdfs. I all worked fine enough until one ...
0
votes
1answer
50 views

Change font in my document-class [closed]

I created a new documentclass that is based on the \documentclass{article} . I would like to use the font Barlow that I just downloaded. I use the package fontspec and the compiler XeLaTeX. When I ...
0
votes
0answers
20 views

Adding random padding/rotation into texts so it gives it a handwriting feel

The image above is of an handwriting example, it shows the random font size and the random padding/rotation between them. The image above is an example of a LaTeX generated texts. How can I make my ...
1
vote
1answer
49 views

Randomly reusing a custom font for the same letters (On first iteration use custom font no 1, on second iteration use custom font no 2, and so on)

I have some custom fonts that I have imported to my Font Book (I am using a macOS machine and am using XeTeX). I can import those custom fonts with the answer written in Package for changing font with ...
4
votes
1answer
173 views

Adobe Reader cannot extract embedded font New Computer Modern

When I create a PDF using the newcomputermodern font and try to open it in Adobe Acrobat Reader DC, I get following error message, and some characters will not be displayed: Cannot extract embedded ...
1
vote
0answers
31 views

Wrong font in section/subsection [duplicate]

Im using fontspec to have Arial in my scrartcl -document. For some reason this Arial is not applied to sectiontitle/subsectiontitle. Compiling with Xelatex \documentclass[a4paper]{scrartcl} %%%%%%%%%%...
0
votes
1answer
68 views

Sans serif symbols in XeLaTeX

I want to introduce a family of sans serif symbols using the TeX Gyre Heros italic font. I have only managed to use the upright font, How do I achieve this with the italic font? \documentclass{article}...
2
votes
1answer
85 views

LuaLaTeX, Vollkorn and Math Symbols

A similar question was asked a few years ago here but since then, Vollkorn claims to have included support for a variety of math symbols, greek letters, and others. I have tried to use the .otf files ...
1
vote
0answers
91 views

Adobe Acrobat cannot extract embedded font FiraMath

When I create a pdf using Fira Math Regular as the math font I get the error Cannot extract embedded font 'SBTYLT+FiraMathRegular'. Some characters may not display or print correctly In my example ...
0
votes
1answer
102 views

miktex does not find STIX2Math.otf font

latest updated MiKTex does return: e:\miktex-portable\texmfs\data\miktex\log\miktex-maketfm.log ! Font TU/STIX2Math.otf(1)/m/n/12=[STIX2Math.otf]/OT at 12.0pt not loadable: Me tric (TFM) file or ...
0
votes
2answers
59 views

Using degree symbol with lualatex and mathdesign package

I started writing my thesis with pdflatex, since this is what the template used. But I have some large tables, which just barely do not fit. By reducing the font size they become a bit small, still ...
0
votes
0answers
32 views

Adding unicode (Cherokee) characters in Latex? [duplicate]

Most of my Latex is in regular English, but there are a couple of lines of Cherokee here and there that I want to include. What packages do I need to install? I tried playing around with fontspec and ...
6
votes
1answer
131 views

Trying to understand the interaction between baskervillef and fontspec

My high level goal is to get a good, free Baskerville font working that supports smallcaps and "rare" ligatures. I have achieved this, apart from rare ligatures, using the baskervillef ...
1
vote
1answer
38 views

urlstyle, urlfont and newfontfamily interaction

I'm using XeLaTeX and fontspec. I want to change the font (to the courier font) that is shown when using \url. I don't understand why "\renewcommand\UrlFont{\courierfont}" works but "\...
0
votes
1answer
60 views

Custom font does not support numbers in math mode

I was trying to change fonts in my document but run into some problems: It seems that the custom font I am using does not support numbers (and symbols) in math mode and instead the default font is ...
1
vote
0answers
42 views

Set font for numbers in Polyglossia

\documentclass[12pt,a4paper]{article} \usepackage{fontspec} \newfontfamily\englishfont{CMU Serif} % English font \newfontfamily\thaifont[Script=Thai]{TH Sarabun New} % Thai font \usepackage{...
3
votes
2answers
117 views

Find fontspec name for font lmr and increase its size in select portions of document

On my mac running OSX 11.0.1 and TeX Live 2020, I'm trying to find the fontspec-name for the default font used by latex so that I can increase the font size in some locations of my document. By using ...
1
vote
0answers
39 views

After upgrade of texlive I cannot integrate Sanskrit fonts in Tufte book style anymore [closed]

After upgrading from a very old Version to Tex Live 2019/Debian I cannot render my "tufte style book" with Sanskrit fonts anymore. In the old version I was able to render with "Quick ...
0
votes
0answers
25 views

Multiple fonts in a numbered section heading with XeLaTeX and Hyperref

I'm trying to use XeLaTeX to build my document. I define sections containing two different fonts within the section command. I've managed to get this to work, but only when using the * version to ...

1
2 3 4 5
38