Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

Context: I'm building a new package for my university. I need to set a lot of options for the document class, like twoside, a4paper, 12pt, or firstpagenum=chapter.

I would like to set them by default in my package without creating a new class. Is it possible?

share|improve this question
6  
Maybe what you actually need to develop is a class file instead of a package. They're equally easy or difficult, depending on your experience. As Grandmaster Carlisle has indicated, unless you use \RequirePackage on top of \documentclass, passing options to a class from a package will require a new invention. Passing options to class after the class file has been read is not possible - and the class file can’t be read twice. In your class file, you can call \PassOptionsToClass before \LoadClass, or, in place of these two commands, simply call \LoadClassWithOptions. –  Ahmed Musa May 26 '12 at 2:25
add comment

1 Answer 1

No the class file has been read by the time you load a package, But it sounds like you should be defining a class file. you can have myclass.cls just handle the options it needs and then \LoadClassWithOptions{article} (or whichever base class you need).

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.