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
0 votes
1 answer
75 views

Can't highlight equation with soul package

I cannot highlight an equation by \hl from the soul package! Is there no way to highlight an equation?
Inzo Babaria's user avatar
0 votes
1 answer
90 views

Highlight in yellow a list of citations

I'm using the soul package to highlight fragments of text, using the \hl command. However, this package has problems if you have a command within the \hl command. They can usually be solved by putting ...
user173026's user avatar
10 votes
1 answer
137 views

Microtype and Soul creates a thin white line after words

When using microtype and soul, if I highlight a text that continues on the next line, I get thin white lines after the words on the first line. Here is some code: \documentclass[a4paper, 12pt, twoside]...
user2712231's user avatar
0 votes
1 answer
81 views

How to add a coloured underline to all links

I'm using ModernCV to create my CV and I've spent a long time playing around with link styles. I find coloured links to stand out too much or clash with other colours on the page, and the standard ...
Robin Winslow's user avatar
0 votes
1 answer
36 views

Highlighting Text and Making it Go to the Next Line in Itemize, and Removing Space at End of Highlighting, with Soul and Linegoal

I've been trying to split highlighted text into lines and not go over the margin in the itemize environment, but linegoal calculates the wrong margin in itemize. Also, the highlighting always gets to ...
Cheese Cake's user avatar
1 vote
1 answer
63 views

Need help with package Soul for marking the change of equations [closed]

I am using Soul to mark the change to my manuscript in Overleaf, but it won't work for equations, like \documentclass[12pt]{article} \usepackage{soul} \setstcolor{red} \begin{document} \begin{...
majordoctor's user avatar
3 votes
2 answers
360 views

Using soul as tokenizer gives strange result on specific strings

Following this post, I was trying to use soul as a hack-y tokenizer and ran into unexpected behavior on certain strings. I reduced the problem to the following MWE but haven't been able to make ...
air-wreck's user avatar
1 vote
1 answer
66 views

Remove hl command using notepad++ or Texstudio

During the review process of a manuscript, I was asked to highlight changes according to the comments of the reviewers. I used the soul package in combination with the color package. These two really ...
Zorg's user avatar
  • 15
1 vote
1 answer
248 views

How to highlight texts without changing the column margin, IEEE format?

I am trying to present my reviewer response with highlighted texts. I am using the soul package in IEEE double-column format. The issue is, the texts go beyond the column margin. Is there anyone who ...
Dimuthu D. K. Arachchige's user avatar
2 votes
1 answer
2k views

Highlighting and striking through text in latex

I have used \documentclass{article} \usepackage{soul} \usepackage[normalem]{ulem} \begin{document} \hl{\mbox{\sout{This is my text which I want to highlight and strike through. The text does not go to ...
YatShan's user avatar
  • 155
1 vote
0 answers
46 views

highlight and strikethrough with soul [duplicate]

I would like to highlight and strike through a text via the latex package soul. I'm pretty sure this can be solved via the answer https://tex.stackexchange.com/a/178701#178701 Unfortunately, I am not ...
Mark Zieße's user avatar
2 votes
1 answer
114 views

How to expand the title text on the chapter title fully and on the header partially?

Having benefited from this TeX.SE answer I've written this code: \documentclass[a5paper,openany,14pt,]{extbook} \usepackage[left=2.34cm, right=2.34cm, top=2.66cm]{geometry} \usepackage[explicit]{...
Lars Malmsteen's user avatar
1 vote
1 answer
119 views

Soul package does not work with XeLatex with Chinese text

Minimal example: \documentclass{article} \usepackage{xeCJK} \usepackage{soul} \begin{document} \ul{I love you 我 爱 你} % This works \ul{I love you 我爱你} % This throws error \end{...
Yan King Yin's user avatar
  • 1,743
1 vote
1 answer
73 views

`soul` and `soulpos` cause page restart if used heavily

I use lots of highlights as it is used to mark my revision from each version before I gave to my lecturer. When I highlight lots of texts, I found out that sometimes page restarted in the middle. ...
Muhammad Yasirroni's user avatar
0 votes
1 answer
213 views

Argument of \textbf has an extra }

I am writing the latex table code as follows: \usepackage[normalem]{ulem} \useunder{\uline}{\ul}{} \begin{table}[] \begin{tabular}{l|cc|cc|} \cline{2-5} & \multicolumn{2}{c|}{{\ul \textbf{One-vs-...
aakhan's user avatar
  • 3
0 votes
1 answer
57 views

Why does the text overlap? [duplicate]

It may not be easy to see, but the error is definitely there -- look at the "r" in "Nordamerikas": How can I remedy this? This was brought to my attention during a final check of ...
Kristian Nordestgaard's user avatar
3 votes
3 answers
547 views

How to add italic words inside highlight?

I want to highlight text, but some text inside it need to be italic. The problem is, \hl{... \textit{...}...} cause all space inside \texit{...} removed. Using \ can solve the problem, but that is ...
Muhammad Yasirroni's user avatar
0 votes
2 answers
69 views

\ignorespaces does not work inside \ul

I am trying to write a document template in which the necessary text would be set using \def at the beginning, and then used in the text. And I ran into the problem that if there are spaces in the ...
Alexey Ismagilov's user avatar
0 votes
0 answers
49 views

How to underline text from a macro when using Alex Chan's implementation of 'a really nice underline'

Following David Carlisle's answer in How to underline text from a macro including a line break?, I am attempting to adapt David Carlisle's use of \expandafter to allow linebreaks (when underlining ...
RosesBouquet's user avatar
0 votes
0 answers
33 views

\ul from the soul package eats last character if it has less common diacritics [duplicate]

I am using the soul package to underline text, since it allows me to select at which height to place the underline. However, for some reason if the last underlined character has a less common ...
matea's user avatar
  • 143
1 vote
1 answer
166 views

hl with automatic line-break for long words [duplicate]

Im using the soul package for highlighting. I noticed that \hl will go simply out of the margin, if the word is too long: \hl{Loremipsumdolorsitamet,consetetursadipscingelitr,...
user16910689's user avatar
0 votes
1 answer
202 views

Soul Highlighting Dimensions

I'm having trouble understanding part of the documentation for the soul package. I want to know the exact lower and upper positions of the produced colored rectangle when highlighting text via the \hl ...
User23456234's user avatar
  • 1,864
1 vote
1 answer
82 views

Underline command of soul doesn't work with Hebrew

I am trying to use soul to underline a word in a Hebrew document: % !TEX TS-program = xelatex \documentclass{beamer} \usepackage{xcolor,soul} \setul{0.2ex}{0.1ex} \setulcolor{red} \usepackage{...
tush's user avatar
  • 1,125
0 votes
1 answer
314 views

{soul} and {xcolor} packages not working

I would like to strikeout a paragraph with some different text colorings in it. As I learned here: Strikeout - when which package ? ( ulem vs soul vs ...) the \st command in soul strikesout whole ...
D.R's user avatar
  • 771
1 vote
1 answer
95 views

Problem when using polyglossia and soul packages together

The following code presents a strange error found using polyglossia and soul packages. \documentclass{article} \usepackage{polyglossia} \setmainlanguage[variant=brazilian]{portuguese} \...
LEo's user avatar
  • 772
0 votes
1 answer
601 views

Changing colors in soul package

I am writing a template for my lecture notes and I wanted to have a different color as my highlighted text. \usepackage{soul} \usepackage[dvipsnames]{xcolor} \definecolor{delectricblue}{RGB}{93, ...
Kid A's user avatar
  • 3
0 votes
1 answer
214 views

URL with track changes and line breaking

I am trying to handle URLs such that I can: split the URL in multiple lines if too long exceeding the page width include a track change mode which means being able to: strikethrough and underline ...
SimoneR's user avatar
2 votes
1 answer
61 views

Why does highlighting stop working when I introduce hyphenation and text including an equals sign?

I'm using soul's \texthl in combination with \texttt to render inline code that can break at arbitrary hyphenation points when it reaches the end of a line. To simulate the "verbatim" aspect ...
user32882's user avatar
  • 1,594
0 votes
0 answers
34 views

Importing geometry package messes up line breaking behavior of \texthl

It looks like uncommenting line 6 of the code below suppresses the line breaking behavior of \texthl \documentclass[a4paper, 11pt]{article} \usepackage{parskip} \usepackage{fontspec} \usepackage{...
user32882's user avatar
  • 1,594
0 votes
1 answer
382 views

How to use soul's `\ul` instead of `\underline` in TeXstudio

I'm using TeXstudio on Linux, and there is an option under the LaTeX/Font Styles menu to underline the selected text. For convenience, I set Alt + U as a shortcut so that I can quickly underline ...
Ben Zelnick's user avatar
0 votes
1 answer
54 views

How to Underline (with Linebreaking) within Contiguously Highlighted Text Using Soul

I would like to use the command \ul within a block of text that is contiguously highlighted using the macro contained in the following code: \documentclass[12pt,openany]{book} \usepackage{soul} \...
DDS's user avatar
  • 8,826
4 votes
4 answers
420 views

pdflatex: conflict between pdfcomment and soul

Here's the MWE: \documentclass{article} \usepackage{soul} \usepackage{pdfcomment} \begin{document} \section*{\hl{Fine}} \section{\hl{Error}} \end{document} which gives the following error ...
ThomasS's user avatar
  • 71
1 vote
1 answer
98 views

How to Break Text-Underlining within a Paragraph without the Soul Package

Consider the code: \documentclass{book} \usepackage{soul} \begin{document} \thispagestyle{empty} \large How may I do this without the \textit{soul} package?\\[7pt] \ul{Text underlining with ...
DDS's user avatar
  • 8,826
0 votes
0 answers
96 views

How to set background color for long in-text citations with line wrapping?

Normally for revised-version, the revised text should be highlighted. When it contains long in-text citations which span more than one line, the background color will extend to the margin, and ...
miya's user avatar
  • 43
0 votes
1 answer
331 views

Make \hl include linebreaks

I am using soul package and \hl to highlight text in my Latex. However, it does not work when there is a linebreak or a new paragraph. I have a whole page to highlight. Is it possible to make \hl ...
Pankaj Singh's user avatar
0 votes
0 answers
43 views

Underline gap in both side aligned line only using `\ul{}` command

Ho do I underline gap in both side aligned line like this: \documentclass{article} \usepackage{cmap} \usepackage[utf8]{inputenc} \usepackage[T2A,T1]{fontenc} \usepackage[english,russian,ukrainian]{...
Konstantin's user avatar
0 votes
1 answer
37 views

Soul hl within a mdframed environment won't print footnote number?

I am trying to highlight some text with soul::hl within a mdframed environment defined by newmdenv. I get expected output using: hl text outside of the environment normal text within the environment. ...
Matifou's user avatar
  • 722
1 vote
1 answer
111 views

How can I patch `minted` to use `soul`s higlighting

I'd like to highlight code with a gray background like StackExchange does. I know that I can set bgcolor in minted to put a solid background color on inline code. However, this makes minted use ...
Eric's user avatar
  • 679
1 vote
0 answers
72 views

highlighting with different heights

I want to use \hl from the soul package to highlight my mathematical definitions. The problem is, that it is very inflexible when it comes to height. For example when I write \documentclass{article} \...
Stefan Friedl's user avatar
1 vote
1 answer
146 views

No automatic line-breaks with ulem and soul packages

In below code, I define two commands \refpage and \refpages using in turn, the ulem and soul packages, but both of them do not break a sentence when that sentence runs on beyond the end of a line. ...
niksirat's user avatar
  • 617
1 vote
1 answer
750 views

Multiple line strikeout with ulem/soul and newcommand

I'm having a hard time doing a strikeout of a multi-line text within a newcommand using ulem and soul. The answers below were not helpful: https://tex.stackexchange.com/a/74910/265141 % Multi-line ...
BGranato's user avatar
4 votes
3 answers
361 views

Turning soul:hl function into an environment

I am using the function hl from package soul to highlight text. I would like to create a specific environment, that would be used for the highlighting. I tried with newenvironment, but did not figure ...
Matifou's user avatar
  • 722
0 votes
1 answer
147 views

How to change the font used in text highlighted with soul's package \hl{} command

I'm using LaTeX with soul's package \hl{text} command to highlight text. I'd like to know if it is possible to automatically change the font used in text marked with hl{text}. I know that I can do ...
Gustavo Mirapalheta's user avatar
2 votes
2 answers
294 views

l e t t e r s p a c i n g with soul/soulutf8

I use l e t t e r s p a c i n g provided by soul/soulutf8 to emphasize words. But If I try to copy a spaced word from the pdf-file, then I get "w o r d" instead of "word". Also ...
Anton Petrunin's user avatar
1 vote
1 answer
242 views

underline a specific hyper link

I would be happy if anyone can help me to color differently only one specific hyperlink, (preferably, without setting \hypersetup{}. Many thanks in advance. \documentclass{article} \usepackage{soul} ...
Seyma Kalay's user avatar
0 votes
1 answer
1k views

Using \ul{} (from soul package) with referencing labels (\nameref)

I have this following code: \documentclass[12pt]{article} \usepackage{hyperref} \usepackage{soul} \usepackage{blindtext} \begin{document} \section{Introducton} \label{sec:intro} \blindtext{} \...
Hussein Esmail's user avatar
2 votes
2 answers
312 views

soul package and Cyrillic with xelatex

How to handle Cyrillic ymbols with soul package? \documentclass[a4paper,10pt]{book} \usepackage{polyglossia} \defaultfontfeatures{Ligatures={TeX}} \setmainfont{Liberation Serif} \...
Yola's user avatar
  • 481
1 vote
0 answers
58 views

soul package with Latex delimiter [duplicate]

I would like to ask that how can we use Latex delimiter \(\) instead of $…$ inside parameter of \hl{} highlight from soul package? \documentclass[a5paper,12pt]{beamer} \usepackage{soul,xcolor} \...
Nuec Tah's user avatar
  • 139
0 votes
0 answers
147 views

Looking for a Soul Alternative to Underline in Color with Custom Depth and Thickness Using Pdflatex

Consider the code \documentclass{article} \usepackage{color,soul} \begin{document} \Huge \setulcolor{red} \setul{}{2.5pt} \textcolor{blue}{\ul{\textbf{some text}}} \end{document} with output This ...
DDS's user avatar
  • 8,826
0 votes
2 answers
132 views

Why and how ulem package disable linebreaking and stretching encountering brace and macro replacement

Descriptions of my questions So, I am doing some hacking which requires me to use ulem package. I found on page 5 of the documentation of this package (dated 2019/11/18) that One important ...
Qi Tianluo's user avatar

1
2 3 4 5