GeneralLearning Macros used in Packages

LaTeX specific issues not fitting into one of the other forums of this category.
Post Reply
dallgood
Posts: 2
Joined: Thu Feb 14, 2013 4:37 pm

Learning Macros used in Packages

Post by dallgood »

All,

Can anyone recommend books or documentation that describes the macros used to create your own LaTeX styles. For example, fancybox.sty is written using macros I do not understand. Unfortunately, I'm not getting anywhere on learning these macros or finding their documentation.

Are these TeX macros? Where could I find more information about them?

Thank you

David

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

dallgood
Posts: 2
Joined: Thu Feb 14, 2013 4:37 pm

Re: Learning Macros used in .sty

Post by dallgood »

here are some solutions:
www.tug.org/TUGboat/tb28-1/tb88flynn.pdf
http://blog.scribtex.com/how-to-write-a ... -design-yo
http://tutex.tug.org/pracjourn/2005-4/h ... fferon.pdf

I'd been search and searching on "LaTeX macros," "\thesection," and others, but I really needed to search for "create LaTeX styles." Some good material out there for those interested.

Dave
User avatar
Stefan Kottwitz
Site Admin
Posts: 10347
Joined: Mon Mar 10, 2008 9:44 pm

Learning Macros used in Packages

Post by Stefan Kottwitz »

Hi Dave,

welcome to the board!

I agree, style files are sometimes hard to read. One reason may be preferring efficiency, i.e. speed, over readability. For example, packages might use TeX macros instead of LaTeX macros just to be faster.

To better understand LaTeX macros, you could read source2e, which is the documented source code of core LaTeX. Another nice document is clsguide, but this is more about writing packages and classes, rather than writing macros. If you would like to understand macros more in depth, have a look at texbytopic. Probably all mentioned files are already on your computer in your TeX installation, accessible by typing

Code: Select all

texdoc source2e
and similar at the command prompt.

Finally, the texbook is of course a great book for understanding TeX.

Stefan
LaTeX.org admin
Post Reply