# Tag Info

0

Another answer from the perspective of "you don't need variable variables". This uses \long\def and adds a \vtop box to the material under the line. \documentclass{article} \usepackage{setspace} \long\def\sigblockB#1#2#3% Defined 3 arguments% \long\def allows for paragraphs % within the arguments of a control sequence ...

5

If I understand correctly, you want to use the relative positions of the saved nodes in your new picture. That is, each node should refer to a position in the new picture relative to the new origin. Here's some code that saves all the data for a list of specified nodes which can then be restored at a later time in the document. It uses LaTeX3 stuff ...

1

Testing for the fd-file is useless: It exists anyway, also it contains only font definitions, it is not the font itself. You need to test for a tfm and/or a pfb-font which is specific to the complete version. With pipes enabled you could do something like this (see Search for files first in the texmf trees): \documentclass{article} \pdfmapfile{=mtpro2.map} ...

5

If you're mixing math and LaTeX you should consider looking into the sagetex package which gives you access to a computer algebra system, called Sage, to handle the math. Documentation on basic statistics is here. You'll need Sage installed locally on your computer or, better yet, you use the free Sagemath Cloud site. In that case, no Sage to download and ...

2

If ( is used, it will be absorbed as #2. \documentclass{article} \usepackage{tikz} \makeatletter \def\macro{\pgfutil@ifnextchar[{\macrob}{\macrob[]}} \def\macrob[#1]#2{% \begingroup \def\parenthesis@for@err{(}% \def\maybe@parenthesis{#2}% \ifx\maybe@parenthesis\parenthesis@for@err \PackageError{mynicepackage}{You donkey!}{I told you to use {}, ...

2

Perhaps not the easiest or quickest way, but the \@ifnextchar way could be exploited to test whether there's a ( after the optional argument [] (it does not check for ) however. Use \GenericInfo{...}{...} to write some information to the Log File \documentclass{article} \usepackage{tikz} \begin{document} \makeatletter ...

2

Though I recommend to use the answer from @egreg here is a way to implement what you are looking for using \@ifnextchar. The idea is that \sigblock prepares everything until it comes to processing the lines beneath the signature field. Then \sigblock@ is invoked which will set the next grouped argument as a line beneath the signature field and starts a ...

2

By trying to solve this problem I've come up with a possibly interesting macro, so I want to share it here. This macro is called \vardef and allows us to define a macro which can receive a variable number of arguments (any number, not limited to 9 arguments) enclosed in curly brackets. Inside the definition of a \vardefined macro one can use the macro ...

7

You're overthinking: the tool is already there, namely tabular. \documentclass{article} \newcommand{\sigblock}[3]{% \par\vspace{\medskipamount}\noindent \hspace*{#1in}\makebox[#2in]{\hrulefill}\\*[.2ex] \hspace*{#1in}% \begin{tabular}{@{}l@{}} #3 \end{tabular}% } \begin{document} \sigblock{0}{3}{Notary Public \\ At Large} ...

1

Use a \Longstack. \documentclass{article} \documentclass{article} \usepackage{stackengine,lipsum,setspace} \setstackEOL{\cr} \def\sigblock#1#2#3% Defined 3 arguments% {\singlespacing{\vbox{\vskip.75in\noindent\hskip#1in% {\hbox to #2in{\leaders\hbox to 0.00625in{\hfil.\hfil}\hfill}}}% \par\noindent\hskip#1in\Longstack[l]{#3}}} \parindent 0pt ...

1

Here's a easy way with xparse and using an optional g argument, which allows to use an optional argument to be used with {...} group pair. \documentclass{article} \usepackage{setspace} \usepackage{xparse} \NewDocumentCommand{\sigblock}{mm+m+g}{% \IfValueTF{#4}{% \singlespacing{\vbox{\vskip.75in\noindent\hskip#1in% {\hbox to #2in{\leaders\hbox to ...

16

The commands \rm, \bf etc are called "deprecated" because they have been removed from the latex kernel. The way the commands work don't fit in the (much better) "new font selection scheme" (nfss) used by latex2e. A number of classes nevertheless provide the definitions for these commands, but the definitions differ. E.g. memoir: \@memoldfonterr {\rm ...

19

Is there any reason(s) not to use \let to redefine \bf to \bfseries and \it to \itshape? Yes, there are good reasons. :-) With the above \let-based setup, {\bf\it ...} produces bold-italic. In contrast, in a plain-TeX document {\bf\it ...} produces italic text. If the goal is to make \bf and \it behave the same way in LaTeX and plain-TeX, the \let-based ...

Top 50 recent answers are included