New answers tagged

0

Rather then \normalfont which doesn't work correctly as @Ulrike said you can use \upshape to change font shape for page numbering \documentclass{article} \usepackage{polyglossia} \setdefaultlanguage{russian} \setmainfont{CMU Serif} \usepackage{amsthm} \newtheorem{theorem}{Theorem} \renewcommand{\thepage}{\upshape\arabic{page}} \begin{document} ...


2

Using fontenc with XeLaTeX is wrong, because the engine uses Unicode which is based on Latin-1 for the lowest block and T1 doesn't coincide with Latin-1. The glyph ğ is covered by T1, but it is in a position that can't correspond to the glyph as XeTeX sees it, because it is not in Latin-1. Other glyphs have the same problem; others that are in Latin-1 are ...


4

Do not use fontenc with xetex, you are specifying T1 encoded fonts which is a non-unicode encoding with just 256 characters, biber and xetex want unicode so you get in the log Missing character: There is no ğ in font ecrm1200! ğ is U+011f so can not be in a T1 encoded font that only has slots up to FF Instead use \usepackage{fontspec} and delete ...


1

You can avoid the error by loading ruby after xecjk. Be aware that this is cheating: You are only preventing xecjk to detect that you are loading cjk. It is quite possible that you get other conflicts -- ruby and cjk is not written for xelatex. But it could work, if you adapt the \ruby command as shown in this ...


0

Please see the comments to the original post. To summarise, \includepdf was the real bottleneck, and compile time had little to do with the packages included. Using the option draft or commenting out the \includepdf greatly reduced compile time. Thanks to all those who helped me find this workaround in order to reduce compile time while working on the ...


10

I suggest you use the datetime2 package with the option en-US: The instruction \DTMlangsetup{ord=raise} instructs datetime2 to treat the day number as an ordinal and to raise the st/nd/rd particles to superscript height. \documentclass{article} \usepackage[en-US]{datetime2} \DTMlangsetup{ord=raise} \begin{document} \today \end{document} Addendum to ...


2

if you use xepersian package, the better way is to set SepMark as follows: \usepackage{xepersian} \SepMark{-} This way the direction of the numbers is also kept!


4

It appears that the macro code for xetex/dvipdfm(x) only inserts the link in the first choice of a mathchoice (so it works in displaystyle only) You could use \mbox or a similar construct that forces text size so avoids the mathchoice internally or a possibly better fix is here I disabled amstext package \iffirstchoice@ test so the macros can not tell ...


1

There are 2 reasons for using filecontents or filecontents* before the \usepackage[..options..]{pdfx}. pdfx.sty processes the metadata as part of loading the package. Thus you want \jobname.xmpdata to be available on disk when pdfx.sty is being loaded, so its information can be read and interpreted at that time. If the .xmpdata file has not been written at ...


1

The latest version (1.5.8) of the pdfx package has been used to create valid PDF/A documents using XeLaTeX. However there are some difficulties. Firstly, you must use an invocation of: xelatex -shell-escape -output-driver="xdvipdfmx -z 0" <filename> which means that the resulting PDF uses no compression, so can be more than 10x the size that it ...


1

Here is a solution. \documentclass{article} \usepackage{lipsum}% just for the example \usepackage{geometry} \geometry{a4paper, left=35mm, right=35mm, top=51mm, bottom=30mm} \usepackage{etoolbox} \newlength\newtop \setlength{\newtop}{21mm} \makeatletter \patchcmd\@outputpage{\global \@colht \textheight}{% ...


0

I just saw this while looking for how to set the heading font using pandoc->xelatex It is possible to set the mainfont and mainfont options using metadata settings. For example, your configuration would look like this: mainfont: Font-Regular.otf mainfontoptions: BoldFont=Font-Bold.otf mainfontoptions: ItalicFont=Font-Italic.otf mainfontoptions: ...


0

The problem seems to be connected to the Cyrillic font families not being properly selected. More like a side-effect than a bug, if you ask me. Adding the following two definitions to my template, actually helps me to solve the issue without removing the currently default \defaultfontfeatures{Ligatures=TeX,Scale=MatchLowercase}: % Define the main Cyrillic ...


2

The package cmbright doesn't make sense with XeLaTeX/fontspec, because it loads legacy fonts. You can use the CM-Unicode version of CMBright. \documentclass[10pt,a4paper]{article} \usepackage{fontspec} \usepackage{polyglossia} \setmainlanguage{french} \setmainfont{cmunb}[ Extension=.otf, UprightFont=*mr, ItalicFont=*mo, BoldFont=*bx, ...


1

Thérèse explained what happens (see comment and question's update section). The font doesn't have the simple parenthesis. A workaround I used for this: defined an english (the main language of the document) parenthesis with \textenglish to force the parenthesis from the Unicode Block "Basic Latin" LEFT PARENTHESIS (U+0028) and RIGHT PARENTHESIS (U+0029) to ...


0

When I asked my original question, I was new to the package background and to \parbox. In fact, I was (am) fairly new to LaTeX, having used LyX in the past. With a little more experience, I found a very simple solution to the original problem: how to get more than one line of "watermark-like" text at the bottom of the page. And that is simply to use \parbox ...


1

First of all, let's get away with the SizeFeatures option. If you declare \setmainfont{Zapfino}[ SizeFeatures={Size=20}, % ... other options ... ] you're basically telling to use size 20 independently of the context. If I do it and ask for \fontsize{30}{36}\selectfont, I get LaTeX Font Warning: Font shape `EU1/Zapfino(0)/m/n' in size <30> not ...


7

One way is to use fit library of tikz. With minimal change to the code provided in question, I have added some dummy text in empty nodes using \phantom and then used fit library. \documentclass{article} \usepackage{tikz} \usetikzlibrary{matrix, backgrounds,fit} \begin{document} \centering \begin{tikzpicture}[% block/.style={draw, text width=5em, text ...


4

Your file needs to be encoded as UTF-8, not Latin1, (or if you're using a Mac Mac Roman) With either of these encodings you will get this output. Most editors will allow you to resave the file with that encoding. You should also probably set that to be the default for future files. Output from your file saved as either Latin1 or Mac Roman: Output of ...


2

A possible solution consists in using some anchors on matrix node to define convenient rectangles on a background layer. First of all I've changed deprecated tikzstyle by tikzset. You can read about it in Should \tikzset or \tikzstyle be used to define TikZ styles? The matrix has been changed to a matrix of nodes (you need matrix library) and adjusted ...


2

Just uninstall the whole MiKTeX package itself (don't touch LyX), download from MiKTeX then do a whole reconfigure from within LyX. It worked. Things are back to normal now.


1

There seems to be an incompatibility between xelatex and tcolorbox regarding colors--and perhaps also listings. It is currently unclear which one is at fault. Temporary Solution Explicitly set the color after each \end{myexample} by adding \AfterEndEnvironment{myexample}{\color{black}} to the preamble. This should be safe because xcolor explicitly sets ...


4

There's some strange interaction between listings wrapped in a tcolorbox and xelatex. I recommend to use a special \newtcblisting and use this (in the outer wrapper, if really needed ;-)) In this case the text does not vanish, regardless whether it is compiled with pdflatex, xelatex or lualatex. \documentclass{article} \usepackage{fontspec}%compile with ...


3

This is very similar to What's the difference between pdfTeX and pdfLaTeX?, in that you are confusing the plain TeX format with the LaTeX format. The only difference is the 'engine' in use: the other question is about pdfTeX, here you are using XeTeX. Essentially: A file starting \documentclass requires the LaTeX format, which using the XeTeX engine ...


3

The more general solution to including git metadata in documents is the gitinfo2 package (which supersedes gitinfo that I mentioned in a comment). Having set that up, \gitAbbrevHash gives you a seven character hash. There may be more elegant ways of achieving this, but as a workaround you can use the catchfile package to store the full hash in a macro, ...


1

You can't do this by defining the color in TeX code. However, there is a way to get the custom color you want. Using an html color converter and inputting #B28B3C for your custom color, it appears that the cmyk code for the color is cmyk(0%, 22%, 66%, 30%). Similarly, if you ask for Purple from the color converter, you get the cmyk code cmyk(0%, 100%, 0%, ...


4

I assume the OP has finished his book by now, but I found a solution and thought I'd share it anyway. With the csquotes package, a custom quote style can be declared with \DeclareQuoteStyle. The undesired "In: " can be removed from all citations using \renewbibmacro{in:}{}, and the page numbers can be omitted only for Japanese entries using the following: ...


0

Protip: Don't have file names with empty space in them such as "Spider Man" Or "Dolly Parton" For whatever reason XeLatex compiler can't handle them.


2

I don't know why Latin Modern Roman is not recognized, perhaps it's not correctly installed as a system font. For getting the “traditional” calligraphic and blackboard fonts you can use the standard setup. \documentclass{article} \usepackage{amsmath} % should go before unicode-math %\usepackage{fontspec} % already loaded by unicode-math ...


2

It works: \documentclass{article} \usepackage{fontspec} \usepackage{polyglossia} \setmainlanguage{french} \begin{document} f; f ; «f» « f »; $\epsilon$; A: Aspace : $Amath$: $Amathspace$ : \end{document}


1

You probably mean the frame title. The command \setbeamerfont{frametitle}{shape=\scshape} sets the shape of the frame titles to SmallCaps. So you probably just want to remove this line.


1

I think the immediate cause of this error message were the empty brackets in \includegraphics{}, as this will look for an image with an empty file name which will most likely not be found. But to avoid further errors, much of the superfluous code should be removed. beamer itself provides many packages, so there is no need use graphicx, hyperref, color or ...


2

Not a direct answer but rather a pointer to a possible route to a solution. Last year I developed a BibTeX style for a book catalogue bookdb.bst which involved extending one of the regular BibTeX files. Run texdoc bookdb to view the User Manual and possibly read bookdb.bst if you want the gory internal details. The User Manual doesn't describe the internal ...


0

After a week of checking versions and uninstalling and reinstalling Miktex, I finally have the eps figures working in xetex. I deleted all folders relating to Miktex from any and all temporary local folders. I turned off my virus softward (Kaspersky) I uninstalled as an administrator: Go to C:\Program Files\MiKTeX 2.9\miktex\bin\x64\internal. Right-click ...


0

You can also use the class europecv2013 (see europasscv-template project on GitHub), with better support to pictures (also including the possibility to embed a qrcode) and better support to academic curricula (i.e. support to scientific results).


1

If you want to use csquotes you should make the quotes active, and input them (also the colon) without spaces as spaces can insert unwanted break points: \documentclass[12pt]{article} \usepackage[paperwidth=14cm,paperheight=20.5cm]{geometry} \usepackage{libertine}% use this font and geometry width to reproduce bad break \usepackage{ifxetex} \ifxetex ...


4

For babel, you have to use \frenchbsetup{og=«, fg=»}. For polyglossia, you have nothing to do, except the package inserts a breakable space (bug?), so in case the space does break, you have to insert an unbreakable thin space by hand (\,`). % !TeX TXS-program:compile = txs:///xelatex/[--shell-escape] \documentclass[12pt]{article} ...


1

There's no way xesearch can work with babel-french. Both want to put - in a particular character class for exploiting the \XeTeXinterchartoks feature. However, you can directly input the en-dash and em-dash and the result is as expected, at least in your example. But malfunctions of xesearch might arise, because the character class of - will be 0 with ...


1

Here a full working MWE. \documentclass[12pt]{article} \usepackage{geometry} \geometry{b5paper} \usepackage{graphicx} \usepackage{amssymb} \usepackage{setspace} \usepackage{reledmac} \usepackage[]{reledpar} \usepackage{makeidx} \usepackage{fontspec,xltxtra,xunicode} \usepackage{polyglossia} \setmainlanguage{dutch} \setotherlanguage{hebrew} ...


0

Well, with your image file squarebdd.eps or with the file example-image.eps (do not leave the extention out!) I can compile your code with or without bb without error and showing up image in XeLaTeX or PdfLaTeX. The only difference to your system I can see that my logfile tells me, that I'm using LaTeX2e <2015/10/01> patch level 2 but you have ...



Top 50 recent answers are included