Maria Gouskova wrote:
Dear LyX users,

I suspect this may be a LaTeX rather than a LyX issue, but perhaps
some of you might know the answer. The usual solution for breaking
lines in LaTeX tables is to set the table width to a fixed value, for
example, 1 inch. This solution is clumsy (in my opinion, at least) but
it produces the desired result, with some experimentation. It doesn't
work, however, when the contents of the cell is underlined. The Is
there any way to break up the contents of a table cell across lines
with underlining?

Maria


Try the following:

1.  In the preamble, '\usepackage[normalem]{ulem}'.
2. In ERT, inside the table cell at the start of the text to be underlined, '\uline{'.
3.  In ERT, at the end of the underlined text, '}'.

This of course presumes you've installed the ulem package. :-) The "normalem" option tells it not to convert emphasized text from italics to underlined (its default behavior).

I'll note in passing that http://dillgroup.ucsf.edu/latex/texfaq_14.html, specifically the section "Underlined text won't break", contains the following quote: "Nevertheless, typographically illiterate people (such as those that specify double-spaced thesis styles) continue to require underlining of us ..." My impression is that underlining was "deprecated" at about the same time that the IBM Selectric typewriter passed into history, other than for occasional funky uses (such as identifying keyboard input, say). I'm not a purist on these things, but I usually consider something like a monospaced font as a substitute for underlining.

HTH,
Paul

Reply via email to