0
votes
0answers
30 views

Allow line breaks in highlighted text [duplicate]

When I highlight a bit of text using \colorbox, it prevents line breaking. How does one give tex permission to break lines? Example: \documentclass{article} \usepackage{color} \begin{document} ...
9
votes
2answers
194 views

How to get listings that both feature line breaking of long identifiers and keywords highlighting?

I'm currently writing a book chapter in bioinformatics, and I would like to provide my readers some useful command lines to invoke recent software. To that purpose, I'm using the listings package to ...
4
votes
1answer
340 views

wrapping inline long lines and adding background color

Objective I'm trying to achieve the following output. Here's the code I used to produce it. I had to hack it \begin{document} \begin{description} \item In ...
11
votes
1answer
408 views

How to highlight arabic texts with allowing line breaks?

I would like to highlight some texts. For Latin texts the \hl command of the soul package works well, but not for Arabic texts. (\hl{SOME ARABIC TEXT} has only a small line as output in the pdf ...
8
votes
2answers
237 views

Is there any solution for highlighting text in CJK?

Is there any solution for highlighting texts or sentences in Chinese, Japanese, and Korean? I know none, at the moment. But this will be changed, if someone would like to help me with CJK in LaTeX. ...
6
votes
2answers
2k views

labeling underlined text over multiple lines

I have a large number of documents I need to create, and there is one very particular need I cannot find a solution for. In these documents, there are pieces of text that are underlined and they ...
2
votes
1answer
325 views

Force minted to insert new space in code that won't fit on the page

Essentially I would like to have listings' breaklines option on minted. I can't seem to find it. I could manually insert new lines but it becomes difficult when the code comes from an external file.
9
votes
2answers
822 views

Fixing a code to highlight formulas and text on several lines

In this post I've found the following amazing code to highlight text on several lines. The problem is that code dosen't work well with formulas : for example, fraction using the mode display are ...