There have been a few questions here on how to pass options to packages in LyX, especially those loaded automagically.
- Lyx: How to add option to package automatically load
- Can I change options of packages loaded by a Lyx module?
Fuhrmanator in https://tex.stackexchange.com/a/318743/42648 and https://tex.stackexchange.com/a/318745/42648 tells about using the Document > Settings > Local Layout settings and adding PackageOptions
there.
PackageOptions geometry includeheadfoot
PackageOptions url hyphens
which if I understand correctly, expands to commands like \PassOptionsToPackage{hyphens}{url}
However, as Deve mentions in Can I change options of packages loaded by a Lyx module?
Use
\PassOptionsToPackage
. No error, but also no effect. I think this command must be used before loading the package, which I can't do as the module's preamble additions are done before the user's additions.
I also had problems passing in some of the core documentclass options (I am using KOMA-Script report class) using this method.
Further, Bernard points out in answer to footer options in Lyx that one can use \geometry{}
in the document preamble to pass options to the geometry
package in LyX.
My question:
Is the command \geometry
specific to the geometry
package, or if one can use a similar mechanism to pass options to any package. For example, \url{hyphens}
instead of PackageOptions url hyphens
.
What would/should be the preferred method?
\geometry
is specific to thegeometry
package: thehyperref
package uses\hypersetup
, and some packages don't have a command to do this. In the case ofurl
, the\url
command is used to typeset URLs, e.g.\url{www.google.com}
, so cannot be used for this purpose.\url
part :( Any pointers to where one can get a lift of suchsetup
commands?