emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* Change color for two words in LaTeX export using cologr package?
@ 2015-07-24 13:07 Rainer M Krug
  2015-07-24 13:39 ` Eric S Fraga
  0 siblings, 1 reply; 5+ messages in thread
From: Rainer M Krug @ 2015-07-24 13:07 UTC (permalink / raw)
  To: emacs-orgmode

[-- Attachment #1: Type: text/plain, Size: 749 bytes --]

Hi

In an org document, I want to change the text colour of two words
{\color{red} red line } to red in a sentence and the rest should be
normal colour.

I am missing something, as this changes the text colour for the rest of
the sentence into red. How can I only change the colour of the two
words?

Thanks,

Rainer

-- 
Rainer M. Krug, PhD (Conservation Ecology, SUN), MSc (Conservation Biology, UCT), Dipl. Phys. (Germany)

Centre of Excellence for Invasion Biology
Stellenbosch University
South Africa

Tel :       +33 - (0)9 53 10 27 44
Cell:       +33 - (0)6 85 62 59 98
Fax :       +33 - (0)9 58 10 27 44

Fax (D):    +49 - (0)3 21 21 25 22 44

email:      Rainer@krugs.de

Skype:      RMkrug

PGP: 0x0F52F982

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 480 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Change color for two words in LaTeX export using cologr package?
  2015-07-24 13:07 Change color for two words in LaTeX export using cologr package? Rainer M Krug
@ 2015-07-24 13:39 ` Eric S Fraga
  2015-07-24 13:43   ` Rainer M Krug
  0 siblings, 1 reply; 5+ messages in thread
From: Eric S Fraga @ 2015-07-24 13:39 UTC (permalink / raw)
  To: Rainer M Krug; +Cc: emacs-orgmode

On Friday, 24 Jul 2015 at 15:07, Rainer M Krug wrote:
> Hi
>
> In an org document, I want to change the text colour of two words
> {\color{red} red line } to red in a sentence and the rest should be
> normal colour.
>
> I am missing something, as this changes the text colour for the rest of
> the sentence into red. How can I only change the colour of the two
> words?

I usually do this type of thing as follows:

#+latex: {\color{red}
red line
#+latex: }

which allows for org-isms in the text.  Alternatively, you could do:

... @@latex:{\color{red} red line}@@

if you don't need to use org syntax within the {}.

-- 
: Eric S Fraga (0xFFFCF67D), Emacs 25.0.50.1, Org release_8.3beta-1293-g985420

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Change color for two words in LaTeX export using cologr package?
  2015-07-24 13:39 ` Eric S Fraga
@ 2015-07-24 13:43   ` Rainer M Krug
  2015-07-27  9:09     ` Fabrice Niessen
  0 siblings, 1 reply; 5+ messages in thread
From: Rainer M Krug @ 2015-07-24 13:43 UTC (permalink / raw)
  To: emacs-orgmode

[-- Attachment #1: Type: text/plain, Size: 1214 bytes --]

Eric S Fraga <e.fraga@ucl.ac.uk> writes:

> On Friday, 24 Jul 2015 at 15:07, Rainer M Krug wrote:
>> Hi
>>
>> In an org document, I want to change the text colour of two words
>> {\color{red} red line } to red in a sentence and the rest should be
>> normal colour.
>>
>> I am missing something, as this changes the text colour for the rest of
>> the sentence into red. How can I only change the colour of the two
>> words?
>
> I usually do this type of thing as follows:
>
> #+latex: {\color{red}
> red line
> #+latex: }
>
> which allows for org-isms in the text.  Alternatively, you could do:
>
> ... @@latex:{\color{red} red line}@@
>
> if you don't need to use org syntax within the {}.

Thanks - I will try it out on Monday. But it looks good.

Thanks,

Rainer

-- 
Rainer M. Krug, PhD (Conservation Ecology, SUN), MSc (Conservation Biology, UCT), Dipl. Phys. (Germany)

Centre of Excellence for Invasion Biology
Stellenbosch University
South Africa

Tel :       +33 - (0)9 53 10 27 44
Cell:       +33 - (0)6 85 62 59 98
Fax :       +33 - (0)9 58 10 27 44

Fax (D):    +49 - (0)3 21 21 25 22 44

email:      Rainer@krugs.de

Skype:      RMkrug

PGP: 0x0F52F982

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 480 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Change color for two words in LaTeX export using cologr package?
  2015-07-24 13:43   ` Rainer M Krug
@ 2015-07-27  9:09     ` Fabrice Niessen
  2015-07-27  9:13       ` Rasmus
  0 siblings, 1 reply; 5+ messages in thread
From: Fabrice Niessen @ 2015-07-27  9:09 UTC (permalink / raw)
  To: emacs-orgmode-mXXj517/zsQ

Hello,

Rainer M Krug <Rainer-vfylz/Ys1k4@public.gmane.org> writes:
> Eric S Fraga <e.fraga-hclig2XLE9Zaa/9Udqfwiw@public.gmane.org> writes:
>> On Friday, 24 Jul 2015 at 15:07, Rainer M Krug wrote:
>>> In an org document, I want to change the text colour of two words
>>> {\color{red} red line } to red in a sentence and the rest should be
>>> normal colour.
>>>
>>> I am missing something, as this changes the text colour for the rest
>>> of the sentence into red. How can I only change the colour of the
>>> two words?
>>
>> I usually do this type of thing as follows:
>>
>> #+latex: {\color{red}
>> red line
>> #+latex: }
>>
>> which allows for org-isms in the text.  Alternatively, you could do:
>>
>> ... @@latex:{\color{red} red line}@@
>>
>> if you don't need to use org syntax within the {}.
>
> Thanks - I will try it out on Monday. But it looks good.

Or, use a macro "color"...

I've begun writing such generic macros for basic and advanced formatting
(see [1]), though they are currently limited to the HTML backend:

  #+MACRO: color @@html:<span style="color: $1">$2</span>@@

I'll update that particular one in the coming hours or days.

Best regards,
Fabrice

Footnotes:

[1] https://github.com/fniessen/org-macros

-- 
Fabrice Niessen
Leuven, Belgium
http://www.pirilampo.org/

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Change color for two words in LaTeX export using cologr package?
  2015-07-27  9:09     ` Fabrice Niessen
@ 2015-07-27  9:13       ` Rasmus
  0 siblings, 0 replies; 5+ messages in thread
From: Rasmus @ 2015-07-27  9:13 UTC (permalink / raw)
  To: emacs-orgmode

Fabrice Niessen <fni-news@pirilampo.org> writes:

> I've begun writing such generic macros for basic and advanced formatting
> (see [1]), though they are currently limited to the HTML backend:

LaTeX has textcolor via (x)xcolor (AFAIR).  odt it probably pretty easy to
get from LO trials.

Rasmus

-- 
This space is left intentionally blank

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2015-07-27  9:14 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-07-24 13:07 Change color for two words in LaTeX export using cologr package? Rainer M Krug
2015-07-24 13:39 ` Eric S Fraga
2015-07-24 13:43   ` Rainer M Krug
2015-07-27  9:09     ` Fabrice Niessen
2015-07-27  9:13       ` Rasmus

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).