New answers tagged

0

Another alternative that might work if the document is simple, and if packages and kernel does the right job when saving/restoring the definition of \par. Which is not probable. \def\thelasttext{\textbf{(this the last text)}} \let\savedpar\par \protected\def\par{\futurelet\tmp\editedpar} \protected\def\editedpar {\ifx\tmp\end\expandafter\editedparcheckend\...


0

I am having the same issue. This is the message: ! LaTeX Error: File `xetex.def' not found. Type X to quit or to proceed, or enter new name. (Default extension: def) Enter file name: ! Emergency stop.


1

The usual classes take a draft option whereby any overlong line (or other typeset material) is marked by a black box in the margin. \documentclass[...,draft,...]% % {memoir} % or % {book} % or {report} % or % {article} % or others The classes can also take a final option which does not mark overfull lines (this is a default option so there is no need ...


2

What about a solution like this? (Ispired by David Carlisle's answer to this question: Combine column types defined in dcolumn with tabularx). Even if a column header is needed... \documentclass[a4paper,12pt]{article} \usepackage{array} \usepackage{siunitx} \usepackage{tabularx} \usepackage{booktabs} \begin{document} \newcolumntype W{S[round-mode=places,...


2

Tell fontspec to select the bold variant by appending /B. Just for reference, there is also /I for italic and /BI for bold-italic. \documentclass{article} \usepackage{fontspec} \setmainfont[BoldFont={Latin Modern Roman/B}]{CMU Concrete} \begin{document} Hello \textbf{World!} \end{document}


0

This is not a bug in pgf, but in pgf-blur. I found a working version here: http://bazaar.launchpad.net/~tex-sx/tex-sx/development/files made by Andrew Stacey. This version fixes some other bugs, too.


4

It hyphenates as you have it in luatex, but xetex, like classic tex, doesn't hyphenate the first word of a paragraph, so you need a 0pt width space. Also because of some polyglossia timing? I needed to do the hyphenation exception after begin document. \documentclass[12pt]{memoir} \usepackage{polyglossia} \setdefaultlanguage{danish} % set language for ...


3

There was discussion of this problem on the Ling-TeX mailing list in 2014. John Frampton (the author of ExPex) posted a way to do this, but I don't think it has been incorporated into ExPex as a permanent solution. Here's a (subscribers only) link to Frampton's message. The other footnote code that you had in your example document that is described in ...


3

With setmainfont you're essential building case-sensitive font paths. Path=working directory for fonts BoldFont=filename segment of path ItalicFont=filename segment of path Extension=file extension of path You're code does not work because you are telling fontspec to look in all paths like this (example shows paths for bold font): /usr/local/texlive/...


4

The \text command requires amsmath (or amstext that's automatically loaded by amsmath). However, for textual subscripts there is \textsubscript. I changed the fonts to ones I have, just to show the output. \documentclass[a4paper,fontsize=13pt]{scrartcl} \usepackage{fix-cm} % to turn off annoying warnings \usepackage{xeCJK} \setmainfont{Libertinus Serif}...


0

The \set*font commands should accept a parameter Path=[Path] that points to the directory containing the files. This is only relevant if using fonts that are not known to the system. Otherwise you should provide the name of the font family as noted by bernard (first comment).


0

Ulrike Fischer above got me on the right track with more detailed output logging, thanks! ...If this isn't the source of the problem run on a command line xelatex --no-pdf file and xdvipdfmx -vv file to get a better error message. Running xelatex --no-pdf test.tex completed fine with no errors Running xdvipdfmx -vv test.xdv returned the following ...


0

There is no need for \Chi and \Alpha, because the glyphs are not distinguishable from “X” and “A”. However, the standard TeX convention is to typeset uppercase Greek letters in upright shape. Doing \newcommand{\Chi}{\mathrm{X}} \newcommand{\Alpha}{\mathrm{A}} in your setting would do no good, because the font corresponding to \mathrm would be Arial, ...


2

I just remembered: I added some time ago this in my the UserData-texmf tree in ...\fontconfig\config\localfonts2.conf <?xml version="1.0"?> <!DOCTYPE fontconfig SYSTEM "fonts.dtd"> <fontconfig> <selectfont> <rejectfont> <glob>D:/MiKTeX2.9/fonts/type1/public/fontawesome/*</glob> </rejectfont> &...


3

I am not too proud about my ⺼-trick, but if you just need it a few times... % arara: xelatex \documentclass{book} \usepackage{polyglossia} \setmainlanguage{chinese} \setotherlanguage{english} \usepackage[AutoFallBack=true]{xeCJK}[2016/05/14] \setCJKmainfont[FallBack=SimSun-ExtB]{SimSun} \parindent=0pt \begin{document} Simplified Characters ...


2

Remove the trick fontspec does for respecting \itshape when \scshape is executed. \documentclass[a4paper, 12pt]{article} \usepackage{amsmath} \usepackage{fontspec} \usepackage[cmbraces]{newtxmath} \usepackage{ebgaramond-maths} \usepackage{polyglossia} \usepackage{mathrsfs} \setmainfont{EB Garamond} \setmonofont{CMU Typewriter Text} \setmainlanguage{french}...


2

Well now, if I wanted something quite as ugly as this (and I accept my taste is probably different from yours), here's how I'd do it. The secret sauce you're looking for is, I think \textup (for "upright"): \documentclass[12pt]{article} \usepackage{ebgaramond} \newcommand{\textscup}[1]{\textsc{\textup{#1}}} \begin{document} \emph{Lorem \textsc{ipsum} dolor}...


1

If xetex does not like the &'s, than don't use them. http://tex.stackexchange.com/a/276133/36296 shows how to use other symbols as alignment markers for the table (maybe using a space is not the best idea, just change it to something that suits you). \documentclass{beamer} \beamertemplatetransparentcovered \newenvironment{mytabular}[2][c]{% \...


3

In your case better use of \newfontfamily\arabicfont[Script=Arabic, Scale=1.2]{Amiri} \newfontfamily\arabicfonttt{Courier New} Rather then \setmainfont[Script=Arabic, Scale=1.2]{Amiri} \setmonofont{Courier New} And you can remove bidi pachage which is loaded by default in case of RTL languages with polyglossia Code \documentclass[11pt, a4paper]{...


1

Emacs-fu blog presented a solution to use XeTeX to import with emacs. You need to set org-latex-to-pdf-process to XeTeX, XeLaTeX or any other engine: (setq org-latex-to-pdf-process '("xelatex -interaction nonstopmode %f" "xelatex -interaction nonstopmode %f")) ;; for multiple passes Also, if you can use an "Arial like" you can have a look at ...


1

xelatex doesn't work with this package. Use instead pdflatex --shell-escape and \documentclass{article} \usepackage{pstricks} \usepackage{pst-dosage} \usepackage{auto-pst-pdf} \begin{document} \psset{unit=0.5cm} \dosageAfBF[pKA=4.75,VA=20,CB=0.1,CA=0.05,dpHunit=0.25,pH1=6,tangentes=true] \end{document}


3

Here is a solution, with a macro \rectonedge with 5 arguments. It is based on a patched version of the leftbarenvironment, from the framed package and the geometry package. The part with the rectangle should break across pages if necessary: \documentclass[12pt]{article} \usepackage[utf8]{inputenc} \usepackage{gillius2} \usepackage[showframe, verbose]{...


5

This has to do with the redefinition of \em performed by fontspec, which doesn't take into account the context, but only nesting of \em inside \em. The following workaround should work: \documentclass{article} \usepackage{fontspec} \usepackage{polyglossia} \usepackage{mathtools, amsthm} \usepackage{unicode-math} \setdefaultlanguage{english} \...


0

Add \usepackage{shellesc} in main.tex before \usepackage{minted}


3

The expex package allows you to use + in the gla line to break lines manually. See section 9.2.1 in the documentation. \documentclass[11pt]{book} \usepackage[margin=1in]{geometry} \usepackage{titlesec} \usepackage{polyglossia} \defaultfontfeatures{Ligatures=TeX} \setmainlanguage{brazil} \setotherlanguage[variant=ancient]{greek} \setmainfont{Linux Libertine ...


3

It seems to be a feature of CMU Serif, that uses different glyphs for Greek when the script is Latin. You can do \setmainfont{CMU Serif}[Script=Greek] and the result will be the same. However, it's better to properly segregate the other language using \foreignlanguage or the otherlanguage or otherlanguage* environment. \documentclass[twoside,a4paper,...


0

Try David's Balancing long table inside multicol in LaTeX. Use longtable Viewer discretion advised.


3

Find a font with the required glyph (not GFS Porson, which hasn't it) and use \newunicodechar for choosing it. \documentclass{scrartcl} \usepackage[no-math]{fontspec} \usepackage{polyglossia} \usepackage{newunicodechar} \setmainlanguage[variant=ancient]{greek} \setmainfont{GFS Porson} \newfontfamily{\greekfont}{GFS Porson} \newfontfamily\digammafont{...


3

Since you need to have your \gla lines be in Arabic and you want those lines to be set RTL, it's best to set the whole example in an {Arabic} environment, and then make the other gloss lines to use the correct font for those lines. Here's a fully worked out example. (You may need to change fonts to ones you have to get this to compile.) I've also added some ...


0

maybe like this \documentclass[11pt]{book} \usepackage[margin=1in]{geometry} \usepackage{titlesec} \usepackage{fontspec} %\defaultfontfeatures{Ligatures=TeX} \setmainfont[Ligatures=TeX]{Linux Libertine O} \newfontfamily\arabicfont[Script=Arabic,Mapping=arabicdigits]{Amiri} \usepackage{polyglossia} \setmainlanguage{brazil} \setotherlanguage[variant=ancient]...


0

Here some remarks on your code Package polyglossia call Package fontspec by default, so you can remove \usepackage{fontspec}. \setotherlanguage{arabic} instead of \setotherlanguage[arabic]. You must define font which contain arabic script with \newfontfamily\arabicfont[Script=Arabic]{name_of_font} Use \textarabic{arabic-text} rather then Arabic ...


4

TeX doesn't add interline glue around an \hrule. You have to add the space yourself. Note that spacing is useless: if you want bigger leading in the title, just modify the second argument to \fontsize. \documentclass{book} \usepackage{lmodern} % or any other scalable font \newenvironment{ruledtitle} {% \par % ensure being in vertical mode \begingroup ...


4

Edit: If we want reversed order, an exemplary solution for three columns may be as follows: \documentclass{book} \begin{document} \begin{center} Original \begin{tabular}{c|c|c} $p$ & $q$ & $p\vee q$ \\ \hline $T$ & $T$ &T\\ $T$ & $F$ &T\\ $F$ & $T$ &T\\ $F$ & $F$ &F \end{tabular} Reversed order \def\1#1&#2&...


0

I just opened up those PDFs on Debian Jessie (MATE, LXDE). They're looked exactly same, both pdflatex and xelatex. I think it's an OS/viewer issue..


1

This is only a clarification for your question, the problem is due to bidi package which is used from ArabXeTeX for right to left sentences, you can for example enclose dot inside group but this is not an elegant method, best is declare bug to the maintainer of the bidi package. \documentclass[12pt]{article} \usepackage{fontspec} \setromanfont[Mapping=tex-...


0

Ok, I got this (thanks a bunch @alwaysask). It turns out that I actually had to specify the name of the *.otf file (instead of the abstract human-readable name of the font) as the argument of the \newfontfamily\russianfont command, as it was suggested here. The only thing that was wrong in that post was that you have to specify the complete file name (with ...


1

Note this answer assumes you didn't add the TeX Live fonts to the system environment variables such that they are found when fontspec searches the system fonts. (either because you don't know how or because it isn't practical e.g. multi-client Version Control System situation) Assuming you are using XeLaTeX: To minimize maintenance with each sequential TeX ...


1

Using system fonts requires xelatex or lualatex. Just load the fontspec package, set the font as shown below and compile the document with lualatex or xelatex. %!TEX program = lualatex \documentclass{article} \usepackage{fontspec,blindtext} \setmainfont{<your font name>} \begin{document} \blindtext \end{document} You can determine the font name for ...



Top 50 recent answers are included