hyperref support and babel-spanish commands conflict

2009-03-07 Thread Ignacio García
Spanish style of babel system provides some user options for fine
settings or special conflicts prevention.

When I check the hyperref support in LyX document setting, the
spanish.ldf user options don't work. babel is loaded before.

However, if I insert manually hyperref in the LyX latex preamble,
spanish user commands work now. babel is loaded after.

Do you think that is right? Is there any mistake in either of the
packages or in LyX?

Thanks in advance
Ignacio García

Here is the relevant latex output in both cases:

Hyperref loaded in LyX document setting:

 \documentclass[spanish]{article}
 \usepackage[T1]{fontenc}
 \usepackage[latin9]{inputenc}
 \usepackage{babel}

 \usepackage[unicode=true, pdfusetitle,
  bookmarks=true,bookmarksnumbered=false,bookmarksopen=false,
  breaklinks=false,pdfborder={0 0 1},backref=false,colorlinks=false]
  {hyperref}

 %% User specified LaTeX commands.
 \def\spanishoptions{es-minimal}

 \begin{document}

Hyperref loaded in LyX latex preamble:

 \documentclass[spanish]{article}
 \usepackage[T1]{fontenc}
 \usepackage[latin9]{inputenc}

 %% User specified LaTeX commands.
 \def\spanishoptions{es-minimal}
 \usepackage[unicode=true, pdfusetitle,
  bookmarks=true,bookmarksnumbered=false,bookmarksopen=false,
  breaklinks=false,pdfborder={0 0 1},backref=false,colorlinks=false]
  {hyperref}

 \usepackage{babel}

 \begin{document}


Re: hyperref support and babel-spanish commands conflict

2009-03-07 Thread Uwe Stöhr

Ignacio García schrieb:


When I check the hyperref support in LyX document setting, the
spanish.ldf user options don't work. babel is loaded before.

However, if I insert manually hyperref in the LyX latex preamble,
spanish user commands work now. babel is loaded after.


This doesn't work for me, see below. Can you send me please an example LyX file?

The problem is that hyperref has to be loaded _after_ babel. Unfortunately Spanish support is a bit 
different that any other babel language support. I think I read recently that the Spanish babel 
maintainer will change this or perhaps has already changed it in the latest babel release.



Here is the relevant latex output in both cases:

Hyperref loaded in LyX document setting:

 \documentclass[spanish]{article}
 \usepackage[T1]{fontenc}
 \usepackage[latin9]{inputenc}
 \usepackage{babel}

 \usepackage[unicode=true, pdfusetitle,
  bookmarks=true,bookmarksnumbered=false,bookmarksopen=false,
  breaklinks=false,pdfborder={0 0 1},backref=false,colorlinks=false]
  {hyperref}

 %% User specified LaTeX commands.
 \def\spanishoptions{es-minimal}

 \begin{document}


Hmm, that woks/compiles here.


Hyperref loaded in LyX latex preamble:

 \documentclass[spanish]{article}
 \usepackage[T1]{fontenc}
 \usepackage[latin9]{inputenc}

 %% User specified LaTeX commands.
 \def\spanishoptions{es-minimal}
 \usepackage[unicode=true, pdfusetitle,
  bookmarks=true,bookmarksnumbered=false,bookmarksopen=false,
  breaklinks=false,pdfborder={0 0 1},backref=false,colorlinks=false]
  {hyperref}

 \usepackage{babel}

 \begin{document}


This doesn't compile here, because babel must be loaded _before_ \def\spanishoptions{es-minimal}, 
because otherwise \spanishoptions is not defined.


regards Uwe


Re: hyperref support and babel-spanish commands conflict

2009-03-08 Thread Ignacio García
2009/3/7, Uwe Stöhr :
> Ignacio García schrieb:
>
>> When I check the hyperref support in LyX document setting, the
>> spanish.ldf user options don't work. babel is loaded before.
>>
>> However, if I insert manually hyperref in the LyX latex preamble,
>> spanish user commands work now. babel is loaded after.
>
> This doesn't work for me, see below. Can you send me please an example LyX
> file?

You are right. Here it compiles because there was my stupid error: I
have loaded hyperref but I had not used it in the document. Inserting
a simple hyperlink, KO. (But this method works in 1.5.5)

> The problem is that hyperref has to be loaded _after_ babel. Unfortunately
> Spanish support is a bit
> different that any other babel language support.

Oh yes, I know very well! :-)

> I think I read recently that the Spanish babel
> maintainer will change this or perhaps has already changed it in the latest
> babel release.

I have the last version... As the author has just opened a new forum,
there I shall raise this issue.

>
>> Here is the relevant latex output in both cases:
>>
>> Hyperref loaded in LyX document setting:
>>
>>  \documentclass[spanish]{article}
>>  \usepackage[T1]{fontenc}
>>  \usepackage[latin9]{inputenc}
>>  \usepackage{babel}
>>
>>  \usepackage[unicode=true, pdfusetitle,
>>   bookmarks=true,bookmarksnumbered=false,bookmarksopen=false,
>>   breaklinks=false,pdfborder={0 0 1},backref=false,colorlinks=false]
>>   {hyperref}
>>
>>  %% User specified LaTeX commands.
>>  \def\spanishoptions{es-minimal}
>>
>>  \begin{document}
>
> Hmm, that woks/compiles here.
>
>> Hyperref loaded in LyX latex preamble:

Yes, it works/compiles for me too, but {es-minimal} doesn't work. (see
sample please)

>>
>>  \documentclass[spanish]{article}
>>  \usepackage[T1]{fontenc}
>>  \usepackage[latin9]{inputenc}
>>
>>  %% User specified LaTeX commands.
>>  \def\spanishoptions{es-minimal}
>>  \usepackage[unicode=true, pdfusetitle,
>>   bookmarks=true,bookmarksnumbered=false,bookmarksopen=false,
>>   breaklinks=false,pdfborder={0 0 1},backref=false,colorlinks=false]
>>   {hyperref}
>>
>>  \usepackage{babel}
>>
>>  \begin{document}
>
> This doesn't compile here, because babel must be loaded _before_
> \def\spanishoptions{es-minimal},
> because otherwise \spanishoptions is not defined.

Is that related with the order in tex file? See you please sample.lyx file.

Thanks a lot!
Regards
 Ignacio


Re: hyperref support and babel-spanish commands conflict

2009-03-08 Thread Ignacio García
2009/3/8, Ignacio García :

> See you please sample.lyx file.

Where is it!?
Sorry
Regards
Ignacio


sample.lyx
Description: application/lyx