Menu
CTAN
Comprehensive TeX Archive Network
Cover Upload Browse

Direc­tory tex-archive/macros/latex/contrib/inlinedef

INLINEDEF -- Inlined expansions within definitions

AUTHOR
  Stephen D. Hicks is author of inlinedef
  email: sdh33@cornell.edu

COPYRIGHT
  This program is provided under the terms of the
  LaTeX Project Public License distributed from CTAN
  archives in the directory macros/latex/base/lppl.txt.
  Copyright 2008 Stephen D. Hicks

INSTALLATION
  Run `latex inlinedef.ins' and copy the inlinedef.sty file into a
  path searched by LaTeX.

DESCRIPTION
  This package provides a macro \Inline that precedes a \def or
  \gdef.  Within the definition text of an inlined definition,
  keywords such as \Expand may be used to selectively inline certain
  expansions at definition-time.  This eases the process of
  redefining macros in terms of the original definition, as well
  as definitions in which the token that must be expanded is deep
  within, where \expandafter would be difficult and \edef is not
  suitable.  Another application is as an easier version of
  \aftergroup, by defining a macro in terms of expanded local
  variables, then ending the group with \expandafter\endgroup\macro

FILES
  README          This file
  inlinedef.dtx   Source code, test suite, and documentation
  inlinedef.ins   Installation script generating source and tests
  inlinedef.pdf	  PDF version of the documentation

Files

Name Size Date Notes
README 1307 2008-07-10 07:01
inlinedef.dtx 40732 2008-07-10 06:53
inlinedef.ins 2680 2008-07-10 06:35
inlinedef.pdf 154151 2008-07-10 07:02
inlinetest.tex 12148 2008-07-10 07:02

Down­load the con­tents of this pack­age in one zip archive (147.1k).

in­linedef – In­line ex­pan­sions within def­i­ni­tions

The pack­age pro­vides a macro \In­line that pre­cedes a \def or \gdef. Within the def­i­ni­tion text of an in­lined def­i­ni­tion, key­words such as \Ex­pand may be used to se­lec­tively in­line cer­tain ex­pan­sions at def­i­ni­tion-time. This eases the pro­cess of re­defin­ing macros in terms of the orig­i­nal def­i­ni­tion, as well as def­i­ni­tions in which the to­ken that must be ex­panded is deep within, where \ex­pandafter would be dif­fi­cult and \edef is not suit­able. Another ap­pli­ca­tion is as an eas­ier ver­sion of \af­ter­group, by defin­ing a macro in terms of ex­panded lo­cal vari­ables, then end­ing the group with \ex­pandafter\end­group\macro.

Pack­age De­tailsin­linedef
Ver­sion1.0
Li­censeThe LaTeX Project Public Li­cense
Copy­right2008 Stephen D. Hicks
Main­tainerStephen Hicks
Con­tained inTeXlive as in­linedef
MikTeX as in­linedef
Topics al­ter­na­tive ways of defin­ing macros
Guest Book Sitemap Contact