We’re rewarding the question askers & reputations are being recalculated! Read more.

Hot answers tagged

18

\DeclareUnicodeCharacter takes the codepoint in hexadecimal notation: \documentclass{article} \usepackage{wasysym} \DeclareUnicodeCharacter{1F600}{\smiley} \begin{document} Hello 😀 \end{document}


5

While this doesn't use fontspec, you can use Ulrike Fischer's experimental combofont package. This uses luaotfload's built-in support for combining fonts: \documentclass{article} \usepackage{verbatim} \usepackage{combofont} % Define a combofont for every font in the family \setupcombofont{hack-symbola-regular}{ {Hack:\combodefaultfeat} at #1pt, {Symbola:...


4

In LuaLaTeX this can be done using the combofont package by Ulrike Fischer. This allows to specify fallback fonts, and fallback fonts for the fallback fonts. MWE, mostly taken from the combofont manual: \documentclass{scrartcl} \usepackage{combofont} \usepackage{fontspec} \setmainfont{Latin Modern Sans} \setupcombofont{multiscript-regular} { {file:...


3

U+0AA2 is not a math symbol, so using range does not work. A simple way is to use \textnormal. \documentclass{article} % Main Packages \usepackage{amsmath} \usepackage{unicode-math} \usepackage{newunicodechar} % optional % for Gujarati symbols \newfontfamily{\gujarati}{FreeSerif} \newcommand{\ddha}{\textnormal{\gujarati ^^^^0aa2}} \newunicodechar{ઢ}{\ddha}...


2

This is what I could come up with: \documentclass{article} \usepackage{fontspec} \setmonofont{Hack} \usepackage{verbatim} \newfontface\Symbola{Symbola} {\Symbola\global\expandafter\let\expandafter\fallbackfont\the\font} \usepackage{luacode} \begin{luacode} local fontcharacters = { } local nullfont = 0 local glyph_t = nodes.nodecodes.glyph ...


1

The package pmboxdraw contains definitions for such characters, which are drawn as lines. In pdfLaTeX this works directly, if you use the characters in the main text. Inside lstlisting you need to define such characters separately in lstset, see How to use extended ASCII characters in the lstlisting environment?. For more characters see the pmboxdraw manual ...


1

You need to employ a TeX engine that is Unicode-aware and can handle OpenType "smart" fonts. In short, use either LuaLaTeX or XeLaTeX, along with a font that has a non-empty entry for \char"262A. E.g., \documentclass{article} \usepackage{fontspec} % for "\setmainfont" directive \setmainfont{Segoe UI Symbol} % or some other suitable font \begin{document} \...


1

Depends on the font designer, I think: how they arrange conjuncts and so on. And whether they are a Sanskritist. Here is the word rishi (sage): (Arial Unicode MS is OK, in this regard.) And here it is with consonant R added in front (र्ऋषि = र + ् + ऋ + ष + ि); and in front of that, consonant R + vocalic R vowel marker (रृ): Only the Sanskrit-orientated ...


Only top voted, non community-wiki answers of a minimum length are eligible