Questions tagged [package-options]

These reference options specified to the package at loading time. For optional arguments to macros or environments, use {optional-arguments} instead.

Filter by
Sorted by
Tagged with
0 votes
2 answers
35 views

Can't define a macro with a name derived from another macro's value: `! Missing \endcsname inserted.`

What happened Given that the macro \CurrentOption whose value is an unknown string of English letters already exists in the document, I want to create another macro whose name is the capitalized value ...
user avatar
0 votes
0 answers
115 views

How may I create a Multiple correct answerS' exercice using xsim

I would like to adapt the MWE below to accept and display MULTIPLE correct answers exercices using xsim. %Code to adapt from @cgnieder: \documentclass{book} \usepackage[no-files]{xsim} \usepackage{...
user avatar
  • 1
2 votes
1 answer
107 views

Package option (for xcolor) is not being properly used in beamer

After a recent upgrade of my system (to Ubuntu 22.04), many of my previous files are failing to compile with undefined colors. Please see the following self-contained examples for clarification. The ...
user avatar
  • 16.8k
1 vote
1 answer
122 views

LyX: Using \PassOptionsToPackage in LyX

Wondering how to use \PassOptionsToPackage in lyx for beamer. Using t, unknownkeysallowed, compress, xcolor=dvipsnames, notheorems under Custom in Document Class in Document -> Setting ... as ...
user avatar
  • 8,349
0 votes
2 answers
59 views

Using a package with and without an option in latex

I need to use a specific package in two different ways, once with an option and another time without that option. More specifically, I want to use algpseudocode package once with [noend] option and ...
user avatar
1 vote
0 answers
81 views

Mathematica code to Latex

I want to export my Mathematica code to Latex, so I saved the mathematica notebook as LaTeX document. Copying this latex code to overleaf, I get the attention message "\hbox too wide" and ...
user avatar
  • 11
0 votes
0 answers
17 views

Passing `table' option to bespoke class, not recognised by `xcolor`

I'm working on a document that uses a university-specific class file. For the purposes of this question, I've reduced the class file to one called test.cls, which contains the following: \...
user avatar
  • 1,373
2 votes
1 answer
75 views

How do I import these three specific symbols from mathabx?

I would like to use the symbols \smalltriangleup, \smalltriangledown and \blacktriangleup from mathabx. The problem is that if I use the mathabx package, some of the other symbols change (like \infty ...
user avatar
1 vote
0 answers
80 views

Package problems with tikz-cd and xcolor [closed]

I have a problem with some packages interfering (I think). I am working on a document where I both want to have a tikz diagram and a table with some of the cells colored. For the cell color, I use the ...
user avatar
  • 111
1 vote
1 answer
52 views

Passing options across multiple style files

I load a package, say aaa.sty, from a main document. In aaa.sty, I also load a package, say bbb.sty. The reason why I maintain two style files is that aaa.sty is in the TeX default folder, and bbb.sty ...
user avatar
0 votes
1 answer
49 views

Hyperref issues

I want to use hyperref in my work "report", and (option clash for package color) is the error message I am receiving with my report document class. This is a part of my preamble with error ...
user avatar
0 votes
0 answers
41 views

Use a code when one special package option value is used

I have missed something with the definitely M(not)WE code below. When the option auto is used, I would like to achieve the action in the "funny" macro \babellang that makes me feel ashamed. ...
user avatar
  • 11.5k
0 votes
0 answers
21 views

Package flacards - newcommand

I'm using flacards, and every card is composed of, in the frontside a word with it's category behind it, and in the backside the translation and a sample phrase behind it. For instance \card{è \\ \...
user avatar
3 votes
1 answer
127 views

LaTeX3 - Failing to define the default value of a package option

I fail to obtain a default value for an option of a package. What is a good way to obtain a default "string" value for an option? Here is what I have tried. % File: main.sty \NeedsTeXFormat{...
user avatar
  • 11.5k
1 vote
1 answer
39 views

How may I put packages with options in vector?

As you all know, instead of writing \usepackage{package1} \usepackage{package2} \usepackage{package3} and so on, we may write \usepackage{package1, package2, package3} How may I obtain instructions ...
user avatar
  • 3,675
1 vote
0 answers
33 views

passing version option to package loaded by class

With the latest changes made to siunitx, I would like the pass the version option =v2 to the package. However the class I use is the one loading the package not my document. I know I can use \...
user avatar
  • 15.6k
4 votes
0 answers
75 views

How to list options supported by a package?

Sometimes options supported by a package are scattered all over a 100-page documentation rather than given in a list, and it is hard to understand if the package implements certain functionality. Is ...
user avatar
0 votes
1 answer
130 views

Reset a tcolorbox option after setting it once using tcbset

I'm using tcolorbox package to draw colored boxes. After I set options with \tcbset {opt1, opt2} I would like to reset just the opt1 back to default. After going through its docs, I couldn't find a ...
user avatar
1 vote
1 answer
55 views

invoice2 package: Replace VAT with GST

I'm trying to generate an invoice using the invoice2 package. It works (adding items and applying a VAT at a rate I supply). However, I would like the invoice to show "GST" instead of "...
user avatar
3 votes
1 answer
26 views

Executing only specific options

I'm pretty new to advanced LaTeX coding and therefore may not have a perfectly specific question. I hope you can help me anyway: I want to maintain different preambles at once. They can be seen as ...
user avatar
  • 366
1 vote
1 answer
59 views

Have option conditionally require package [duplicate]

I want to declare an option in my package that, if provided, will require another package. However, just doing \DeclareOption{requiresomething}{ \RequirePackage{somepackage} } does not work, as ...
user avatar
  • 13
1 vote
1 answer
66 views

Will it work if I use \PassOptionsToPackage twice to the same package?

Sometimes I need to \PassOptionsToPackage under certain conditions. Would it work if I \PassOptionsToPackage multiple times to the same package? For example, when I write: \PassOptionsToPackage{...
user avatar
  • 6,190
1 vote
0 answers
151 views

Any reference and tutorial on writing .cls file class? [closed]

I was trying to re-edit the report.cls file to adapt to our institution thesis presentation format. I was stuck at declaring and executing options,also with error flag on xcolor file execution. Having ...
user avatar
1 vote
2 answers
57 views

Suppress page numbers in in-text citations but one-time only

My advisor requires page number in in-text citations, consider the following MWE and its output: \documentclass{article} \begin{filecontents}{references.bib} @article{einstein, author = &...
user avatar
  • 15
0 votes
1 answer
41 views

Should loading a package with no options behave the same as calling a macro with no options using pgfopts and pgfkeys?

This is a followup to my previous question Why does pgfkeys .initial not work in these cases?. In that question I created a macro with a key-value interface using pgfkeys and it works perfectly. Now, ...
user avatar
1 vote
2 answers
188 views

Is this a correct way to handle Boolean options?

In trying to get a better understanding of kvoptions I have the following minimal example package and document. In the package, I construct a new macro command based on the logical states of three ...
user avatar
0 votes
1 answer
53 views

Even without reading a package option the code defined in it is read in the compilation. What is the problem in the codes?

The problem! My tex file is ... \PassOptionsToPackage{svgnames}{xcolor} \documentclass{scrbook} %%% \usepackage[capimage]{suave} %%% \begin{document} \frontmatter \chapterimage{imagetest} \...
user avatar
0 votes
0 answers
35 views

Change footmisc options midway through document

I would like to be able to use the para option of footmisc in one chapter of my book and have it not be in use in another chapter. In the package documentation I don't see a command defined for making ...
user avatar
0 votes
1 answer
156 views

Why can I not use the "superiors" package with any options?

I am trying to compile the following document: \documentclass[a4paper,11pt]{scrartcl} \usepackage[supstfm=libertinesups,supscaled=1.2,raised=-.13em]{superiors} \begin{document} a \end{document} The ...
user avatar
0 votes
1 answer
78 views

Why does uniquelist=false option of biblatex package work only if it is inserted at the first time?

With biblatex package I was using these options: \usepackage[style=authoryearcomp,maxbibnames=99,maxcitenames=2,isbn=false,backend=biber]{biblatex} but later I needed to add the uniquelist=false ...
user avatar
  • 59
0 votes
1 answer
157 views

Misunderstanding of \PassOptionsToPackage?

In the following code I would like to use \PassOptionsToPackage but this does not work. What am I doing wrong ? \documentclass{article} \RequirePackage{algorithm2e} \PassOptionsToPackage{french}{...
user avatar
  • 11.5k
0 votes
1 answer
58 views

Personalize the first \addConstraint using optidef package

I have this MWE where I have used optidef package, a specific library for optimization problems. \documentclass[a4paper,12pt]{article} \usepackage[short]{optidef} \begin{document} \begin{mini!} {\...
user avatar
  • 46.3k
1 vote
1 answer
90 views

Using a .sty file with if-else options

I have a .sty file with the following part: % a.sty ... \if@twoside \setlength\oddsidemargin {36.1\p@} \setlength\evensidemargin {0\p@} \setlength\marginparwidth {40\p@} \else ...
user avatar
2 votes
0 answers
84 views

Pencil effect in TikZ [duplicate]

We assume that to have drawn a vector.... \documentclass[a4paper,12pt]{article} \usepackage{tikz} \begin{document} \tikz\draw[->,line width=1pt] (0,0) -- (1,1); \end{document} Is there a pencil ...
user avatar
  • 46.3k
1 vote
1 answer
242 views

Multiset symbol

Recently in a question on Math.SE, I have seen for the first time in my life an unknown symbol of double binomial coefficient. It is simply possible to make it with a code of this style: \...
user avatar
  • 46.3k
1 vote
0 answers
26 views

Change global settings on framebox, margin above [closed]

How do I change the global settings of framebox so that I don’t have to write \vspace{2mm} above every framebox I use. \vspace{2mm} \framebox(380,200){\textit{To be completed}}
user avatar
1 vote
3 answers
243 views

How to resolve general "package clash" in Latex

There are so many questions related to "package clash" in this forum, but all of them relate to specific packages (why?). For instance I use more than 50 packages in my document. Even if I ...
user avatar
0 votes
1 answer
72 views

Package options depending on compiler

I'm experimenting with custom packages, and I try to create the "ultimate" package for keeping notes. Now I know it isn't great but it works. Now -because I'm indecisive- I want to be able ...
user avatar
6 votes
1 answer
481 views

Proper way to use `RequirePackage` and avoid option clash

I'm developing a small LaTeX library that requires hyperref to work, but I'm facing 2 problems: I think that hyperref should usually be loaded at the very end. However, if I put a \RequirePackage{...
user avatar
  • 5,093
0 votes
1 answer
74 views

Environment with default output and command to change it

In the past for my dissertation I made a code that was outputting the result as a tex file for each experiment, generating a new table every time, but most of the entries I expected were the same. It ...
user avatar
1 vote
1 answer
342 views

general options for graphix overriding every includegraphics settings

I have multimarkdown text compiled from an external source and which is including its own settings for each figure compiled. I would like to have a general settings at the beginning of the document ...
user avatar
  • 113
3 votes
1 answer
114 views

Passing formatting options in pgfkeys using pgfopts

I am trying to design packages and handle package options using pgfkeys through the pgfopts package. However when an option include a formatting command, the whole thing fail and I don't get the ...
user avatar
  • 4,263
0 votes
0 answers
81 views

How to use only a few commands from a package?

I am writing a quantum mechanics lecture note. So I use \ket{} very often. I also use siunitx package and the package has a command \kelvin. The \kelvin command appears above \ket in the overleaf ...
user avatar
  • 101
2 votes
0 answers
50 views

How to *not* define command when a package option is called [closed]

I've recently written my own personal package (let's call it mypkg), which contains all the math macros I use on a regular basis. I would like to get this package to work with beamer. My package loads ...
user avatar
0 votes
0 answers
82 views

want to use my own language babel but clashing with document class

I want to use mongolian babel with the other document class but it crashes everytime. \documentclass[colophon, english]{phduio} \usepackage{phdstyle} % Custom style \usepackage{kantlipsum} % Dummy ...
user avatar
  • 155
0 votes
1 answer
603 views

Pass beamer class options to beamer theme

How do I pass the document class options to a beamer theme? I am writing a beamer theme. I would like to use the beamer class option aspectratio to have individual layout settings for the 43 and 169 ...
user avatar
  • 1,742
0 votes
1 answer
38 views

If a style uses requires a package with options, are these options enforced in the document that uses it?

I am writing a style and I used a package with one option set, as in: \RequirePackage[fit]{truncate} However, I am curious if this option is now enforced everywhere in the document and if there is ...
user avatar
  • 169
2 votes
0 answers
321 views

A valid alternative(s) to siunitx package [duplicate]

Although this question is very simple in the substance, I would like to ask it anyway. Visibly if I use the comma within the mathematical environment you can see a small space that I have underlined ...
user avatar
  • 46.3k
0 votes
1 answer
387 views

Custom Package Parameters

I am writing a custom, package using Texmaker with Pdftex. I have a function, which I would like to change a certain delimiter to whatever the user wishes if my provided delimiters are not good, or ...
user avatar
0 votes
1 answer
67 views

Two questions about compiling order of packages codes

I have a question about compiling order of packages. For example consider a package (for instance tocloft) and I have the following document: \documentclass{book} \usepackage{tocloft} \setlength{\...
user avatar

1
2 3 4 5 6