[XeTeX] Polyglossia "broken"?

Zdenek Wagner zdenek.wagner at gmail.com
Wed Sep 21 15:19:29 CEST 2011


2011/9/21 Heiko Oberdiek <heiko.oberdiek at googlemail.com>:
> On Wed, Sep 21, 2011 at 02:34:41PM +0200, Zdenek Wagner wrote:
>
>> That's right. \RequirePackage and \usepackage maintain internally a
>> list of already loaded packages. There is one potential problem, you
>> are not specified a different list of options. Thus if you use
>> \RequirePackage{something} without any options, it is harmless. If a
>> user needs "something" with some options, he or she must load it
>> explicitely with these options in advance.
>
> The option lists may differ. But the requirement of LaTeX is that
> the option list of the first load request is the superset of
> the options in all load requests.
> ("load request": \RequirePackage, \usepackage, (\PassOptionsToPackage))
>
> \usepackage[foo,bar,xyz]{something}
> \usepackage[bar,foo,xyz]{something}
> \usepackage[bar]{something}
> \usepackage{something}
>
> is ok, but any new option given later
>  \usepackage[foo,bar,xyz]{something}
>  \usepackage[new]{something}% throws an error
>
> If there is an option clash, the user can press "h" to get
> the exented help text of the error and LaTeX shows the options.
> Then the user can resolve it by calling the package earlier with
> the option superset as option list. And the package documentation
> needs to be checked, if options of this package might overwrite
> each other.
>
Agreed. What I meant was if package "anything" contains
\RequirePackage{something} without any options but user needs
"something" with some option, then the correct way is

\usepackage[options]{something}
\usepackage{anything}

I am not sure whether the same effect can be achieved by giving the
option in \documentclass, probably yes but I would have to check it. I
agree that it is a bug if a package relies that a requested package
will be loaded by some automagic mechanism.

> Yours sincerely
>  Heiko Oberdiek
>
>
> --------------------------------------------------
> Subscriptions, Archive, and List information, etc.:
>  http://tug.org/mailman/listinfo/xetex
>



-- 
Zdeněk Wagner
http://hroch486.icpf.cas.cz/wagner/
http://icebearsoft.euweb.cz



More information about the XeTeX mailing list