Tag Info

New answers tagged

3

You can use the \normalfont switch before \textit, or the \textnormal command, to "kill" the boldface font attribute; of course, you can define a dedicated command for this: \documentclass{article} \usepackage{enumitem} \setlist[description]{style=nextline} \newcommand\MyIt[1]{{\normalfont\textit{#1}}} \begin{document} \begin{description} \item[Abd ...


4

An example by using encTeX: \mubyte\myquoteout '\endmubyte\def\myquoteout{\char"0D} \mubyte\myquotein `\endmubyte\def\myquotein{\char"12}\mubytein=0 \let\oldtt\tt\def\tt{\mubytein=1\oldtt} % `test' {\tt `test'} `test' \bye


5

Many TeX-aware front-end programs nowawadays make it as easy to compile a document under either XeLaTeX or LuaLaTeX as it is under pdfLaTeX. Quite a few will even switch automatically to XeLaTeX or LuaLaTeX, respectively, if directives such as either % !TEX TS-program = xelatex or % !TEX TS-program = lualatex are provided at the top of the file, i.e., ...


2

xelatex or luatex are as easy to use as pdflatex (in most cases the input is the same once the fonts are set up) so if you are in a community that is guaranteed to have that font, just using it via fontspec loaded in the class should "just work" \documentclass{article} \usepackage{fontspec} \setmainfont{Gill Sans Ultra Bold} \begin{document} A bit gross ...


1

Not sure that you really want this but the graphicx package and \begin{center} \bfseries \resizebox{\textwidth}{!}{My Title} \end{center} will stretch the text out and add some vertical space.


3

You could set Latin Modern as the main font if you like it for the Latin range, and then use CMU Serif as a fallback font for higher Unicode ranges. Depends on how much higher Unicode you need. I still hope someone can devise a mechanism for an automatic font-fallback system like in CSS. (Define fallback font for specific Unicode characters in LuaLaTeX) ...


1

If anybody in the future encounters the same problem, please read this: After a lot of trial, I came to the conclusion, that it is probably the best to use matlab2tikz or pgfplots. The link that @Dolphin posted in his comment leads to a handy extension of Inkscape, which fulfills its purpose. All the text in the Matlab figures got recognized. The problem ...


2

The Latin Modern font family is available in OpenType format as well; see The Latin Modern (LM) Family of Fonts site. Even better, it's distributed with both TeXLive and MikTeX. (Am I maybe missing something about capabilities of CMU that are not available in LM?) Thus, you could write % !TEX TS-program = lualatex \documentclass{scrartcl} ...


3

If you want to change the labels in a description to use small caps, the easiest way is to use enumitem: \documentclass[12pt]{book} \usepackage{enumitem} \setlist[description]{font=\normalfont\scshape} \begin{document} This is normal text. \textsc{This is in small caps.} \begin{description} \item [It's small caps] as you clearly see \end{description} ...


3

You can fake bold small caps with my \fauxsc{}, first described at Fake small caps with XeTeX/fontspec?. There are three parameters for tuning the fauxsc font \def\Hscale{.85}\def\Vscale{.72}\def\Cscale{1.10} which define the horizontal scale on lc letters, the vertical scale on lc letters, and the horizontal scale on uc letters. ...


1

Based on a hint of Ulrike Fischer on c.t.t I found the following solution: Step 1: download (and unzip) yinit-as.zip from CTAN. It contains: yinit-as/ yinit-as/initials.sty yinit-as/yinitas.txt yinit-as/README yinit-as/yinitas.tfm yinit-as/yinitas.mf Step 2: put the files where tex can find them (e.g in ~/texmf or .../texmf-local) md ...


4

Macro \vv breaks in a \typeout message, because \vv is not robust. \protect helps: \documentclass{article} \usepackage{esvect} \usepackage[outline]{contour} \begin{document} \contour{red}{$\protect\vv{aa}$} \end{document}


5

Here, I take Bruno's answer at Shear transform a "box", and use it to unslant the computer-modern greek letters. I introduce \unslant[slant]{math-symbol}, where the default value of unslant correction is set to -0.25. As you can see, the unslanted font is very visually very compatible with the original, both of which are shown. No packages ...


5

EDITED to better demonstrate the technique, using txtt as the ttfont. FIX for lstlisting and \verb given in FOLLOW UP at end: Here, I show how a simple \scalebox can be used to invert the slash through a defined macro \0. I also show how making the 0 active allows one to use the reversed version of the zero inside verbatim environments. Obviously, one ...


11

The TUGboat article linked by Barbara Beeton provides an in-depth study of the ambiguous-zero problem. In LaTeX's default typeface, Computer Modern, the zero in the typewriter font is narrow and round, as opposed to a squarish capital "Oh". But you may have your pick of other monospaced typefaces. The LaTeX Font Catalog provides a list of all the ...


4

I tried your input changing the loading of fontspec into \usepackage[no-math]{fontspec} (and using a Times font I have on my machine, which should be irrelevant); this is the report by pdffonts without no-math name type emb sub uni object ID ------------------------------------ ----------------- --- --- --- ...


1

I had the same issue and I resolved it by replacing yinitas with yinit in file yfonts.dtx.


1

Rather than re-creating the wheel, it's best to just base your document on one of the standard classes. The article class is about as standard as you can get, but memoir and the KOMA-script classes are good options as well. When using article, you can specify the margins with the geometry package, but the layout is already justified. \documentclass{article} ...


4

Like this? \documentclass[tikz]{standalone} \usepackage[outline]{contour} \usepackage{tikz} \begin{document} \begin{tikzpicture} \node[fill=black]{\textcolor{red}{\contour{white}{This is some text}}}; \node[text = white]at (0,-0.5){\contour{red}{This is some text}}; \end{tikzpicture} \end{document}


0

Here is a very simple solution which I use when I'm forced by editors to use the Times New Roman font, which have no Small Caps implemented. Since I want to leave the rest of my document intact, I simple redefine \textsc in the following way: \renewcommand{\textsc}[1]{{\footnotesize \uppercase{#1}}}


3

Latin Modern math doesn't blend with Times New Roman. You're better using NewTX: \documentclass{article} \usepackage{newtxtext,newtxmath} \begin{document} The text is in Times; $\lambda\lambdaup$. \end{document} If you insist in using Latin Modern math symbols, here's how you can do: \documentclass{article} \usepackage{amsmath} \usepackage{lmodern} ...


1

If you are able to use Lua- or XeLaTeX, I would recommend the package unicode-math: % arara: lualatex \documentclass{article} \usepackage{unicode-math} \usepackage{fontspec} \setmainfont{Times New Roman} \usepackage{blindtext} \begin{document} \blindtext $\mathup{\lambda}\lambda$ \end{document}


3

Listings is using math mode for some characters so you can add \boldmath to the style, but then still in OT1 with cm fonts substitutions make some characters non bold, here I use T1 latin modern which gets a slightly more consistent look: \documentclass[xcolor=dvipsnames]{beamer} \usepackage[french]{babel} \usepackage[utf8]{inputenc} \usepackage{listings} ...


3

The style you prefer was prepared using different software. More specifically, it probably used LaTeX or TeX to output the .dvi and then definitely used Acrobat Distiller to produce the pdf. In contrast, yours was created with pdfTeX. Moreover, although I don't know enough about Distiller to say, the result is that the other document uses truetype fonts ...


1

Now it exists a new package to draw keys of a scientific calculator. I used that calculator when I teached at Junior High School. ticollege.sty : https://www.ctan.org/pkg/ticollege


0

Here are two ways how I would do that. The second one gives you more flexibility if you want to switch the font for this symbol or alike... I do not know about your s' approach. % arara: pdflatex \documentclass{article} \begin{document} \'s\'S \end{document} % arara: lualatex \documentclass{article} \usepackage{fontspec} ...


1

TexStudio works with Cygwin TeX Live using the following: Menu -> Options -> Configure -> Commands -> PdfLaTeX: "C:\cygwin64\bin\bash" -l "/cygdrive/c/users/porterb/pdflx.sh" Contents of pdflx.sh: pdflatex -synctex=1 -interaction=nonstopmode -output-directory=/cygdrive/c/users/porterb/data/home/tex -output-format=pdf ...


3

There are two issues here: the first is finding a font that actually contains the glyphs you want, and the second is getting them to appear where you want them. Here are the currently available OpenType math fonts that offer multiple weights: Lucida Bright Math offers Regular and Demibold Minion Math offers Regular, Medium, Semibold, and Bold (each in ...


1

As long as using XeTeX or LuaTeX instead of pdfLaTeX is an option, you can use basically whichever font you have installed in your system. Document --> Settings --> Fonts. Check the box for Use non-TeX fonts (via XeTeX/LuaTeX) at the top: Move down to the LaTeX preamble panel, add \newfontfamily\mylistingsfont{<name of font>} If you want the ...


2

If you installed the fonts as traditional TeX fonts i.e. you generated .tfm and .map files etc., then you can back them up as part of backing up your personal and local TEXMF directories. Whether or not you have installed these particular things in these places, you probably want to back these up. The local tree will be /usr/local/texlive/texmf-local ...


1

I introduce \fat that emboldens the argument with a multi-offset-overlay. While it can be invoked in text mode or math mode, its argument is processed in math mode (unless delimited by $ which will process it in text mode). Importantly, the current math style is preserved. For things like \vee, it is easier to define \fvee in terms of \fat and \vee. ...


0

The ultimate answer to your question is: When you are not satisfied with the look of the available fonts, design your own! But font design is hard and tedious work, you probably don't have the time needed left given your other duties in life. There is a shortcut: When you want to mix characters from different fonts, you can create a virtual font and use ...


2

First, if you are using proper OpenType maths fonts like Cambria Math or Minion Math, you only need the unicode-math package. You shouldn't also load the mathspec package, which is intended to allow one to employ regular text fonts for maths. Unfortunately, Cambria Math doesn't contain the necessary integral glyphs in the correct size. While you could ...


3

The CMU fonts are based on Computer Modern (and the CB fonts for Greek): \documentclass{scrreprt} \usepackage{fontspec} \setmainfont{CMU Serif} \setsansfont{CMU Sans Serif} \newfontfamily{\greekfont}{CMU Serif} \newfontfamily{\greekfontsf}{CMU Sans Serif} \usepackage{polyglossia} \setdefaultlanguage{greek} \begin{document} \tableofcontents{} ...


3

Why don't use the option eulermath for classicthesis? The Euler font for math is really nice. MWE \documentclass{scrreprt} \usepackage[eulermath]{classicthesis} \usepackage{blindtext} \begin{document} \blindtext Some math $x+y+z=15$. \end{document} Output Anyway, if you really want Computer Modern as the math font, add the following lines in your ...


8

I'd use a different character for this. Here I use ! for upright subscripts (and define \exclam if you need ! in math mode as itself. \documentclass{article} \usepackage{amsmath} \begingroup\lccode`~=`! \lowercase{\endgroup\def~}#1{_{\mathrm{#1}}} \mathchardef\exclam=\mathcode`! \AtBeginDocument{\mathcode`!=\string"8000 } \begin{document} ...


2

I usually use something like the following: \newcommand{\mstr}[1] {\ensuremath{\mathit{#1}}} \newcommand{\subs}[2] {#1\mstr{_#2}} Of course, you could e.g. change \mathit to \mathrm. Then use it like \subs{x}{y}


1

See two marked bits (otherwise the tic labels are set in math mode by default) \documentclass[12pt]{standalone} \usepackage{tikz} \usepackage{pgfplots} \usepackage{fontspec} \usepackage{ebgaramond}%<=== think you needed this - you presumably have the font locally otherwise \begin{document} \pgfplotsset{every axis/.append style={ line width=.5 pt, tick ...


4

As the warning message now reports, caption does not know about what beamer is doing, and as a result, gives up. But beamer already has hooks to the caption label/text fonts that we can use directly to achieve the same result: \setbeamerfont{caption}{size=\scriptsize,shape=\itshape} \setbeamerfont{caption ...


0

Following the answer of Bruno, the wiki package allow a very simplified entry of boldface and italics fonts using the Wikipedia syntax: \documentclass{article} \usepackage{wiki} \begin{document} \wikimarkup Write in '''bold''', ''italic'' or '''''both'''''. \end{document} Bold and italics can be nested and even overlapped, so that you can obtain the ...


5

The package misses the redefinition of \cdotp according to the different slot assigned to \cdot with respect to the OMS encoding: \documentclass{article} \usepackage{boisik} \DeclareMathSymbol{\cdotp}{\mathpunct}{symbols}{"79} \begin{document} $A \ldots B \cdots C \cdot D \cdotp E$ \end{document}


2

This is (unfortunately) not working with the 28 Days Later font, since the xelatex compilation breaks with some error 11. The principal way is to use \setmainfont{fontname}[options] The manual of fontspec states, that following font options must be set if the font is specified by filename (and not fontname) BoldFont ItalicFont BoldItalicFont Since 28 ...


0

The downloaded zip file must compile as it is, once it is extracted. Remember to use xelatex. On the other hand, if you want to use the attached fonts, just copy the otf files to your /home font folder, usually /home/USER/.fonts. If you don't find it, then there are two possibilities: either you have to tell nautilus to «unhide» files (then you'll see ...


4

It's the \ttdefault command which normally takes care of this. \documentclass{article} \begin{document} \texttt{How to use a typewriter font}% CM default typewriter font \par \renewcommand\ttdefault{cmvtt} % selects CM typewriter proportional font \texttt{How to use a typewriter font} \par \renewcommand{\ttdefault}{pcr} % selects Courier font \texttt{How ...


2

It seems, as stated by @scottkosty, to be related to the font, probably Computer Modern. So, just change it. In Lyx, go to Document > Settings... > Fonts and change it to something that suits you better, like TeX Gyre Bonum.


6

If using either XeLaTeX or LuaLaTeX is an option for you, you may want to use the Cambria Math font. The following table contrasts the looks of w and \omega, as well as looks of the notoriously-similar triple v, \upsilon, and \nu. Clearly, w and \omega are very different if Cambria Math is loaded. Pagella, a Palatino clone, arguably does a credible job as ...


0

It is good to be reminded that from a LaTeX team member's viewpoint font choice is just a style choice. But from a user's viewpoint some choices would be unacceptably odd and others would be not best. Manuel brings up a technical issue decisive for me. Even using the amsmath and amsfonts packages you do not have \mathds. Of course I can easily add the ...


0

For a call to a function/procedure use \Call{<function>}{<parms>} \documentclass{article} \usepackage[noend]{algpseudocode} \begin{document} \begin{algorithmic} \Function{Something}{$G$, $e$} \State \ldots \State \Call{Something else}{$G$, $e$} \EndFunction \State \Function{Something else}{$G$, $e$} \While{true} ...


5

Use \setmainfont{Fontin Regular}[SmallCapsFont = Fontin SmallCaps] (newer syntax), or \setmainfont[SmallCapsFont = Fontin SmallCaps]{Fontin Regular} (older syntax).


0

On Windows 7, running MiKTeX 2.9, I just updated the fonts, by running (as an Admin), the "Update" module (under the "Maintenance (Admin)" folder), and then selecting all possible updates.



Top 50 recent answers are included