Questions tagged [ulem]

{ulem} concerns the ulem package for underlining and strikethrough capabilities

Filter by
Sorted by
Tagged with
0
votes
1answer
21 views

Striking out numbers from siunitx

This code will not compile: \documentclass{article} \usepackage{siunitx} \usepackage{ulem} \begin{document} \sout{\SI{180}{\degree}} \end{document} I am writing a command to automatically format ...
0
votes
2answers
80 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 ...
1
vote
1answer
158 views

Strikethrough and line breaks

I need to use \sout{} from the ulem package for longer passages of text and in combination with other macros. However, this removes all linebreaks and the text is kept on a single line. Is there any ...
1
vote
0answers
97 views

\uline cannot wrap the line after texlive2021

I need to underline some text and hope the text automatically wrap at then end of the line. see Why does underlined text not get wrapped once it hits the end of a line ? The \uline works with ...
3
votes
3answers
163 views

ulem with hspace error

The following code \documentclass{minimal} \usepackage{ulem} \begin{document} \emph{\hspace*{2in}} \end{document} used to work without error, to produce an underlined blank space of width 2 inches. ...
1
vote
1answer
24 views

A problem of alignment with "ulem"

I defined a underline style by ulem package to add a = sign under each character, as follows: \newcommand{\suline}{\bgroup\markoverwith{\raisebox{-0.6em}{=}}\ULon} With parskip package added, the ...
0
votes
1answer
59 views

Titlesec's titleformat with ulem

I have a very large document that can be reduced to the below example to provide custom formatting for subsection headers. \documentclass[]{article} \usepackage{ulem} \usepackage[explicit]{titlesec} ...
0
votes
0answers
301 views

\uline does not work with \hspace

Long story short: Changed laptop and previous working documents don't compile anymore. Problem show up with comamand \uline from \usepackage[normalem]{ulem} with argument \hspace{3cm}. \documentclass[...
1
vote
1answer
67 views

Why does \endgroup not work inside \uline?

I want underlined text (or math) where the color of the underline is different from the color of the text (e.g. black text underlined by a red line). Therefore I tried the following code using the \...
0
votes
1answer
2k views

Strikethrough command in LaTeX [closed]

I am trying to have as strikethrough text using base LaTeX command and up till now there is no solution available except the use of some packages, i.e, ulem and cancel. Is there any other way to get a ...
1
vote
1answer
239 views

uline and uuline same line width

How to align uline and uuline same width of line using ulem package? I attached screenshot for your reference.
0
votes
1answer
73 views

Bad interaction between \usepackage{ulem,tikz} and citations (glossaries and footnotes) in Tufte-Book document class

I constructed a figure with TikZ in a tufte-book document class, and I need to use the ulem package as follows \documentclass[symmetric,justified,marginals=raggedouter]{tufte-book} \usepackage{ulem,...
3
votes
2answers
982 views

Changing the color of special underlines with ulem

I'm using the ulem package to produce different kinds of underlining, and want each underline style to be in a different color (so that the difference is visible whether you're viewing the document in ...
4
votes
1answer
168 views

Math accent at line start in align causes error

The following code no longer works after the LaTeX2e 2019-10-01 kernel update (error occurs using XeLaTeX). \documentclass{article} \usepackage{fontspec,ulem,amsmath} \begin{document} \begin{align} \...
1
vote
2answers
126 views

Centering table entries with a custom underline that matches width of column

I have a simple table with 3 columns, which I am using as a heading for data. I have defined a custom underline rule (with custom thickness, color and depth) that I am using to underline each table ...
2
votes
1answer
287 views

Redefining contour colour (for underlining)

I'm using the following code (taken from this site for putting nice underlines under my text. \usepackage{ulem} \usepackage{contour} \renewcommand{\ULdepth}{1.8pt} \contourlength{0.8pt} \newcommand{...
3
votes
1answer
78 views

How to use a command that takes one argument as a declaration?

I would like to apply \sout{} from the ulem package to anything between \DIFdelbegin and \DIFdelend below (commands from the Latexdiff script). Can the definitions of the two commands be modified in ...
3
votes
2answers
138 views

`\uline` from `ulem` package won't break lines automatically when containing boolean expression

Here is the MWE: \documentclass{minimal} % \usepackage{lipsum} % \let\uline\underline \usepackage{ulem} \newif\ifanswer \newcommand{\showanswer}[0]{\answertrue} \newcommand{\hideanswer}[0]{\...
3
votes
1answer
62 views

Can quotes made with \MakeAutoQuote made robust in a \ulem?

The following example gives the error ! Extra }, or forgotten \endgroup because of the »« in the \uwave command. Can the definition of the quotes be changed to avoid the error without loosing the ...
2
votes
2answers
270 views

Extending section heading underline into margin

I'm using Koma and have got my section heading numbers set in the margin of the page. I have also got a coloured underline for the section headings. I want, if possible, the underline for the section ...
5
votes
3answers
217 views

ULdepth does not change space in equation

I am trying to underline a result within an equation environment. The result contains a Matrix. I use the ulem package with uline. How can I add more space between my matrix and the line? I tried ...
8
votes
2answers
422 views

A problem with Hebrew and English underlined text

When I'm combined at the same line Hebrew and English, the line below is "breaking" for two lines.... e.g. MWE: \documentclass[a4paper,english,hebrew,numbers=noenddot]{scrartcl} \usepackage{...
0
votes
2answers
1k views

Using \cite in \sout causes errors

When I use \cite[something with spaces]{ref} inside \sout{...} I get errors. For the article document class it helps to replace spaces by ~. That doesn't help, however, for the elsarticle document ...
3
votes
1answer
165 views

Striking out colored text through user defined commands

I have been trying to strikeout a colored text defined by a macro, but it seems that it does not support line breaking. I have a command bt to type blue text and I want to strike some of the text with ...
1
vote
1answer
397 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 ...
2
votes
2answers
932 views

How to control the vertical space below a double-underline?

I use an edited version of the \\uline command from the ulem package to get a nice compact double underline to denote tensor variables. The used code comes from this question. My problem is that the ...
3
votes
3answers
181 views

Redefine `\uline` so `\colorbox` is locally defined to have underlined text, too

Initial problem: I want to underline the text with a continuous line with the following code: \uline{No underlining for \colorbox{lightgray}{everything} inside the colorbox.} Workaround: A ...
0
votes
1answer
623 views

How can I use `\uline` from the `ulem` package to underline text inside a `\colorbox`?

Screenshot: I have the following code: \uline{No underlining for \colorbox{lightgray}{everything} inside the colorbox.} Which looks like this: How can I get a continuous line for the text inside \...
2
votes
2answers
1k views

insert text in rule

I have difficulty writing a compact command that allows me to insert a text between two lines. I read some links such as this and this, but each one treats the left and right line separately \...
1
vote
1answer
62 views

How do I get permission for exam materials?

MWE \documentclass{minimal} \usepackage{ulem} book = 1 phone = 0 photocopy = 1 internet = 0 tablet = 1 \begin{document} Book, \xout{phone}, photocopy, \xout{internet}, tablet, \ldots\ free or open. ...
3
votes
2answers
364 views

Size/density of dots used by \dotuline command (ulem package)

I would like to use the \dotuline command (from the ulem package) to create a "fill in the blanks" document. It gives good results but when the blank becomes small it is hardly noticeable (a single ...
3
votes
1answer
254 views

Punctuation and text decoration - 'csquotes' not compatible with 'ulem' or 'soul'

I'm using TeX for a long time now, but I'm currently struggling integrating some features for my daily use. To be more precise: I'm intending to use features like text highlighting (yellow markup), ...
1
vote
0answers
704 views

How to underline text with in-text citation with wrapping?

The line of text I want to underline includes in-text citation. My problem is that \uline only works on this line when I use \mbox(I get an error without \mbox), which makes it impossible to wrap the ...
3
votes
1answer
409 views

How to underline whole bibitem in biblatex?

I want to underline whole bibitem when using biblatex. I tried \AtEveryBibitem{\uline} but failed. What I want to do:
2
votes
1answer
955 views

Problem with linebreak in combination with strikeout from the ulem package and newcommand

Is it possible to combine the "result" of a newcommand with the sout command of the ulem package with working linebrak/hyphenation? \documentclass{article} \usepackage{ulem,lipsum} \textwidth=3cm % ...
2
votes
1answer
1k views

Line break and hyphenation for underlined text

I am struggling with a problem that occurs using \underline. From other posts I heard that there is no possiblity for linebreaks using this command. However, I tried using the ulem package. In fact, ...
1
vote
2answers
2k views

highlighting strikeout text with ulem shifts the line downwards

I'm trying to highlight a text with a strikeout word by defining a new command as explained in the docs of ulem. Unfortunately, that moves down the strikeout line a few points, which looks strange ...
1
vote
1answer
269 views

Textwidth underline while ragged right text

I want to do this: But all I can do is: \documentclass[14pt]{extreport} \usepackage[normalem]{ulem} \begin{document} \hfill\begin{minipage}[t]{0.7\textwidth} \begin{flushleft} Lorem:~\uline{ipsum ...
0
votes
1answer
109 views

Strange behaviour of ulem?

I know, it's ugly and seems stupid, but I need to redefine like that. I try a lot of things (\edef, \expandafter...) Nothing seems to work. No break line. \documentclass{article} \usepackage{...
4
votes
1answer
320 views

KOMA -- Underlined headings using `ulem` conflicts with `hyperref`

I noticed, that if you underline headings with the use of ulem and redefining \sectionlinesformat (as done in this answer) does conflict with hyperref. The conflict only occurs on unnumbered sections, ...
7
votes
2answers
979 views

Underlining words with dash-dotted line without affecting the other text in LaTeX

NOTE: I am searching for a LaTeX solution. The ConText code was offered, which is a good answer, but that doesn't fit my purpose. I want to underline some words in text to show the parts of ...
3
votes
1answer
80 views

Comfortable solution for using ulem together with (r)eledmac

Preface: Sorry for the long text. By writing it, I was able to solve an earlier problem leading to this one. In Underlining with ulem package breaks footnotes Ulrike Fischer and Heiko Oberdiek answer ...
7
votes
2answers
2k views

How to underline name of specific authors in biblatex?

My goal is to underline the name of specific authors in a bibliography processed by biber/biblatex. I can make them in bold following https://tex.stackexchange.com/a/73246/127979 and https://tex....
0
votes
1answer
400 views

fun style cross-strike-out

I want to cross out (strike out) words or letters in fun ways for poster-sized text for children. ulem and cancel produce rather formal/sterile-looking cancellations, as do tikz-based combinations of ...
1
vote
0answers
316 views

xecjk conflict with ulem?

Building the following MWE with xelatex in TeXnicCenter results in 5 errors: \documentclass{article} \usepackage{fontspec} \setmainfont[Mapping=tex-text]{Times New Roman} \usepackage{xeCJK} \...
2
votes
1answer
3k views

Underline colored text with linebreak

I would like to underline colored text with a black line, and preserve line breaking. My best solution so far is using \uline from the ulem package. However, I cannot get my desired result. My ...
2
votes
0answers
232 views

Bibliography messed up by ulem package [duplicate]

I needed to use the ulem package to underline sections and subsections, and it works great. The problem is now that the bibliography of my document got messed up. This is how I have configured it: \...
2
votes
3answers
585 views

How to have comments + text until the end of the line in ulem underline environment?

Code % https://tex.stackexchange.com/a/159996/13173 \documentclass{article} \usepackage[normalem]{ulem} \begin{document} \begin{enumerate} \item Initials: \uline{A.B.C.} \item Age: \uline{50} \item ...
3
votes
2answers
1k views

Colored underlining without affecting vertical spacing

I'm using the coloured underlining trick described in the ulem package manual (p.3). The underlining looks good, but interacts poorly with align-like environments, where (in contrast to \uline) it ...
5
votes
1answer
182 views

Interaction between xcolor, ulem, and no-break spaces

Using no-break spaces seems to break interaction between xcolor and ulem: \documentclass{article} \usepackage{xcolor} \usepackage[normalem]{ulem} \begin{document} \textcolor{green}{\uline{\...