LyXParagraphs in italic

Information and discussion about LyX, a WYSIWYM editor, available for Linux, Windows and Mac OS X systems.
Post Reply
luc4
Posts: 13
Joined: Thu Apr 09, 2009 12:43 pm

Paragraphs in italic

Post by luc4 »

Hi! I'm writing a book and I chose 'book' as document class. I'm using example paragraphs to insert some examples, but I was wondering if it is possible to change the style of the font, leaving the rest unchanged. I would like the example to be italic instead of normal... is this possible without redefining the entire document class?
Thanks!

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

mas
Posts: 226
Joined: Thu Dec 04, 2008 4:39 am

Paragraphs in italic

Post by mas »

luc4 wrote:I would like the example to be italic instead of normal... is this possible without redefining the entire document class?
The following should work :

Code: Select all

\begin{itshape}
your example ...
\end{itshape}
Regards,

sridhar

OS: Debian/GNU Linux; LaTeX System : TeXLive; Editor : Vim
User avatar
localghost
Site Moderator
Posts: 9202
Joined: Fri Feb 02, 2007 12:06 pm

Paragraphs in italic

Post by localghost »

There is no itshape environment (although it works) but only the \itshape switch.

Code: Select all

\itshape
The quick brown fox jumps over the lazy dog.
\normalshape

Best regards
Thorsten
luc4
Posts: 13
Joined: Thu Apr 09, 2009 12:43 pm

Re: Paragraphs in italic

Post by luc4 »

I'm not an expert of Latex, but won't this only set to italic what's inside the switch? I would like every example of my document to be italic, even the examples I've already written. Is this possible? I used a paragraph style 'Example' present in the menu of LyX, which adds 'Example a.b' to the beginning of the paragraph. Is it possible to change the style of these paragraphs?
Thanks!
mas
Posts: 226
Joined: Thu Dec 04, 2008 4:39 am

Re: Paragraphs in italic

Post by mas »

For that, you need to define an environment/macro. But, we still do not know how you have set up your Examples.

Regards,

sridhar

OS: Debian/GNU Linux; LaTeX System : TeXLive; Editor : Vim
luc4
Posts: 13
Joined: Thu Apr 09, 2009 12:43 pm

Re: Paragraphs in italic

Post by luc4 »

I don't know the setup as it is already defined. I used the document class 'book' with some modules: 'Theorems (AMS)' and 'Theorems (By Chapter)'. When those are added to the LyX document in the settings I get the paragraph style 'Example' and many others. I would like to change that. Maybe I should overwrite it somehow because I don't even know where it is defined...
Thanks again!

EDIT: I solved! It was sufficient to edit theorems-ams.inc. Thanks!
Post Reply