Questions tagged [soul]

Questions with this tag are about the uses, and also problems with using, the `soul` package for letterspacing, underlining, overstriking and highlighting, perhaps also using colour.

Filter by
Sorted by
Tagged with
1
vote
0answers
37 views

Why does highlighting in the soul package change the spacing between letters?

\documentclass{ieeeaccess} \usepackage[noadjust]{cite} \usepackage{amsmath,amssymb,amsfonts} %\usepackage{algorithmic} \usepackage{graphicx} \usepackage{textcomp} \usepackage{color, soul} % comment ...
0
votes
0answers
22 views

How to highlight multiple lines of inline equations?

\documentclass{ieeeaccess} \usepackage[noadjust]{cite} \usepackage{amsmath,amssymb,amsfonts} %\usepackage{algorithmic} \usepackage{graphicx} \usepackage{textcomp} \usepackage{color, soul} % comment ...
1
vote
0answers
63 views

MDPI Default Template Highlight

Hi everyone I am working on MDPI submission using their template avaliable on overleaf and their site here I am highlighting changes using the soul package and the \hl{} but everytime I do this on the ...
1
vote
0answers
27 views

SOUL not working with “ě” character

I have the following code in soul to allow underlines for letters with descenders. \usepackage{xcolor} \usepackage{xparse} \usepackage{soul} \makeatletter \ExplSyntaxOn \cs_new:Npn \...
2
votes
1answer
38 views

Using the 'soul' package to redefine \emph -> Problems in Bibtex

I was planning on using the soul package to redefine \emph to \so, so that everytime I use \emph, the text would not be italics but l i k e t h i s (spacing out, so). However, once I use \usepackage{...
1
vote
1answer
38 views

Colored underline without affecting the default LaTeX style

I would like to have a colored line. I tried the following: \documentclass[11pt,english]{article} \usepackage[T1]{fontenc} \usepackage[parfill]{parskip} \usepackage{color,soul} \setulcolor{red} \...
1
vote
1answer
30 views

Getting soulutf8 to work with luatex

Is it possible to get soul(utf8) to work with luatex? In the following example only the first three lines are typeset. \documentclass{article} \usepackage{fontspec} \usepackage{soulutf8} \...
1
vote
1answer
21 views

How can I highlight blocks of text which include citations and display equations?

I am addressing reviewer comments for a scientific article. I would like to highlight significant changes to make it easier for reviewers to spot the changes. However, I find that when using the soul ...
0
votes
0answers
28 views

newcommand + csname + sout + cref = ERROR: Extra }, or forgotten \endgroup

I'm not sure to understand why, but I created a command to automatically add a strike-command per author. If I use it strike normal text, it works. If I use it to strike a text with \cref{...} inside, ...
0
votes
0answers
38 views

Highlight and label anything in LaTex article

I'm looking for a package that highlights and labels anything I wrap with it. So that I can then create a list of those highlights according to the label. I was thinking of something like the ...
3
votes
1answer
50 views

Soulpos package definitions

Here is the soulpos package link:: https://www.ctan.org/tex-archive/macros/latex/contrib/soulpos I wrote the code from soulpos manual, But I don't know how can I use \ulpgfB \ulpgfC definitions? \...
0
votes
0answers
46 views

highlighting with soul corrupts text structure

I have a text where students have to individually highlight certain passages. The lines are numbered for later comparison. I use \hl{} from the soul-package for highlighting, but have found that it ...
0
votes
0answers
40 views

apply nested box in soul package

\documentclass[a4paper,twocolumn]{article} \usepackage{tikz} \usetikzlibrary{decorations.pathmorphing} % \usepackage{soul} \usepackage{soulpos} \begin{document} \ulposdef\ulpgfC[xoffset=.15em]{% \...
0
votes
0answers
47 views

How to highlight text spanning multiple lines that includes macros?

I am currently proofreading a document and want to highlight some sentences. Unfortunately, I haven't found a highlighting package that can both Preserve linebreaks Highlight text produced by macros, ...
0
votes
1answer
657 views

The installed file does not exist - soul.sty

I want to use this beamer template that I found on Overleaf with MiKTeX in TeXstudio: https://www.overleaf.com/latex/templates/presentation-template-au-theme/ffhvmnbyvdjg I downloaded the the whole ...
2
votes
0answers
19 views

\hl gives 5 errors and I don't know why [duplicate]

The sentence \hl{Upphängningsmetoden visade att masscentrumet låg i punkten (10,5;7,30) i centimeter medan den algebraiska metoden visade på att tyngdpunkten låg i $(10,5;7,34)$} gives 5 errors and I ...
7
votes
2answers
435 views

Alternative to the soul package?

Context One may want to highlight some text, or strike it. This can be done with either the soul package, or with the ulem package using a trick, although it does not work that well. Problem The ...
1
vote
1answer
33 views

Babel seems to break letterspacing of soul package

This is a MWE of a book I'm working on. \documentclass[10pt,twoside]{book} % \usepackage[ngerman]{babel} \usepackage{blindtext} \usepackage{soul} \usepackage{fancyhdr} \pagestyle{fancy} \renewcommand{...
0
votes
0answers
52 views

Adding underline to titles of books and journal in bibliography with respect to page limits

My university has this thing in its bibliography where we make the titles of books and journal bold and underlined. I almost finished writing an article, however, I am unable to add an underline to ...
1
vote
1answer
63 views

Package soul Error: Reconstruction failed in \tableofcontents and bibliography

I'm writing a book in a scrreprt format. And, for the spacing and underlining the sections, I'm using the soul package. However, it throws an error in tableofcontents and bibliography. I'm clueless ...
0
votes
1answer
585 views

Use \hl command to highlight a subsection title

I am trying to use the \hl command to highlight a subsection and subsubsection title. I have tried wrapping the commands in a \mbox or between parenthesis but it doesn't seem to work. They worked with ...
0
votes
0answers
80 views

Problem of compilation with XelateX (Package soul error)

In a previous question (https://tex.stackexchange.com/questions/548738/special-character-oe-and-biblatex-with-xelatex), it was proposed to modify a part of the code to solve the problem. But the new ...
0
votes
1answer
78 views

Color text: Soul - reconstruction failed with font switching

I want to color my text and followed this sample code. Now I have \documentclass[a4paper,11pt]{article} \usepackage[a4paper,includeheadfoot,margin=2.54cm]{geometry} % for margins on a A4paper \...
0
votes
0answers
29 views

Figure touching the top or bottom of page causes page numbering to reset to zero? [duplicate]

I am experiencing this weird bug where if a figure touches the top or bottom of a page, is the page numbering reset to zero on that page. I haven't been able to make a minimal example showing the ...
0
votes
0answers
22 views

Reducing margin of highlighted text

The soul package adds a little bit of margin to highlighted text. Roughly speaking, 10 lines of highlighted text are as tall as 11 lines of non-highlighted text, i.e. a 10% margin. I am very ...
0
votes
2answers
164 views

Trouble with soul and utf8 [duplicate]

Here is a working example \documentclass{book} \usepackage[utf8]{inputenc} \linewidth 150mm \usepackage[spanish]{babel} \usepackage{soul} \sodef\secso{\scshape}{.125bp}{0.33em ...
3
votes
1answer
151 views

Suppressing text with strikethrough?

I would like to suppress text that has been strickenthrough (struckthrough?). I don't think that hide does this, because hide replaces with an empty box of the same size. I think something like \...
0
votes
0answers
34 views

Page counter is reset when highlighting long text using sethlcolor from soul package [duplicate]

I encounter a similar problem like this TeX question or this other one. However, I open a new question because the examples given by the previous ones were not suited to highlight the potential ...
1
vote
1answer
53 views

Printing TeX special symbols with tex.print, but also highlighted

I would like to be able to automatically print TeX special symbols into pdf. Mostly (but not only) the underscore symbol _, but also highlighted by grey color (similar to how it is displayed in this ...
1
vote
1answer
186 views

\Verb{} in fvextra: Highlighting \Verb{} text to be able to break at the end of line

Searching through various packages documentation and this site I have found how to write inline verbatim text, that is (when neccessary) broken at the end of line. For this feature, I am using \Verb{} ...
4
votes
1answer
268 views

pdfx causes soul to stop working

I noticed that adding pdfx package to my document stopped the soul package from highlighting the text in yellow. \documentclass[a4paper,12pt]{article} \usepackage[a-1b]{pdfx} % comment this out \...
2
votes
1answer
179 views

Conflict between package pdfcomment and polyglossia during compilation by LuaLatex

I would like to prepare a bilingual document and at the same time I would like to be able adding pdf comments by pdfcomment. Compilation by the command lualatex test.tex gets stuck when the library ...
1
vote
0answers
42 views

How do I mix ö with \hl{} using [utf8x]{inputenc} [duplicate]

Say I'm writing about Schrödinger's cat. I would like to be able to put use soul's \hl{} function to make the cat yellow. This should work, but it doesn't: % Minimum working example of UTF-8 ö ...
0
votes
1answer
180 views

combining soul package and color one in a newcommand

I have to use \st (from soul package) for crossing a line over a word in a text file. In addition, for presenting a specific replaced word instead of the first one, I use {\color{blue} second word}. ...
0
votes
0answers
71 views

How to change padding in a colored text

I want to color some block of text (multi line), so I took package xcolor and soul. It works, but I want to have some adjustments: first, the colored text shall have some padding around it, so the ...
1
vote
1answer
73 views

Incompatibility between soul/tikz and accents package

The following code throws an error. \documentclass{amsart} \usepackage{accents} \usepackage{tikz} \usepackage{soul} \def\ubar#1{\underaccent{\bar}{#1}} \begin{document} $\ubar{x}$ \hl{$\bar{x}$} \hl{$...
0
votes
0answers
61 views

How to make a realistic highlighting [duplicate]

I'm using \hl{} from soul package to highlight some words in my document. However, I'd like a "realistic" highlighting, simulating the result of a "manual" note: a not-so-regular rectangle with "...
0
votes
0answers
155 views

Why does \cite command does not work inside \add or \hl commands…?

Why does \cite command not work inside \add or \hl commands...? If my sentence goes like... \cite{Brown2015} studied so and so things and I wish to highlight the citation, so I would modify \hl{\...
2
votes
0answers
27 views

Cyrillic characters don't appear when enclosed by \ul with soulutf8

MWE: \documentclass[17pt,a4paper]{extarticle} \usepackage{graphicx} \usepackage{fontspec} \usepackage{polyglossia} \usepackage{soulutf8} \setmainfont{LMR12R-Gregory} \setdefaultlanguage[variant=...
0
votes
3answers
349 views

Package soul underline problem with macro text

I have been slowly learning LaTeX over the past few years. I have been mostly successful in these efforts. Recently, I stumbled across a problem, I know is probably quite simple to fix, but it has me ...
3
votes
1answer
70 views

My spaces are swallowed

I want to have my code examples show up with not only \code{\textbackslash texttt} but also a grey box. You might be familiar with the looks from some famous web page with questions and answers on ...
3
votes
2answers
111 views

What is the difference between \somecmd and \csname somecmd\endcsname?

This is a demo \documentclass{article} \usepackage{soul} \makeatletter \newcommand{\mydef}[2]{% \expandafter\def\csname my#1\endcsname {#2} } \newcommand{\mygetdef}[1]{% \ifcsname my#1\...
0
votes
0answers
259 views

How to use \discretionary inside soul's \hl?

\documentclass{article} \usepackage{soul} \usepackage{color} \begin{document} Some \hl{te\discretionary{-}{-}{-}xt}. \end{document} The above does not compile due to Missing { inserted, Improper ...
3
votes
1answer
3k views

How to highlight text containing citation and figure referencing?

I am trying to highlight a text with reference. Without references, the below works fine. Could anyone know how to handle the highlighting the text containing citation and figure references? MWE is ...
1
vote
1answer
260 views

How to have underlined text break line in table?

I have a long text in a table which is combined from two commands with a space in between, which has to be underlined. How can I make it wrap while being underlined? The example below shows the ...
1
vote
1answer
536 views

how to add vertical space between words and the underline effect?

I searched around here and did not find anything accurate to what I wanted. I would like to know other ways to increase the decrease in the space between underline and words as well as in this MWE ...
3
votes
2answers
98 views

How to use the global definition of a variable in a command where that variable has already been defined?

I was trying to highlight some text, which contains \x, using the \hl command from the soul package, where \x is simply defined as \def\x{\mathbf{x}}. However, I've found that \x has already been ...
2
votes
1answer
165 views

Enable highlighting and auto-line-breaking for texttt{}

I'm using the following command to modify texttt{} so that it automatically breaks long lines (without inserting a hyphen), and it's very helpful when writing documents where I have to write lengthy ...
3
votes
2answers
57 views

How to change the colour of the line when I strike out a sentence

I have the following MWE \documentclass{standalone} \usepackage{soul} \usepackage{xcolor} \begin{document} \st{I want to strike out this sentence} using a red line and I want to replace it with ...
0
votes
1answer
383 views

How to highlight deleted text in the PDF output generated by compiling latexdiff

For the purposes of showing corrections to a PhD thesis, I am using latexdiff to produce a PDF showing the difference between the original and the new version. My examiner has requested me to not ...