diff options
author | Karl Berry <karl@freefriends.org> | 2013-11-19 00:56:32 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2013-11-19 00:56:32 +0000 |
commit | 0c16ddd29d43c785b867739f9b8fad8885ee548b (patch) | |
tree | 7402f2695ae367f7c96dba3224b4f1158900f077 /Master/texmf-dist/source/latex/xymtex/base/assurelatexmode.dtx | |
parent | 717e7ac16b923e6683f358eab146a2a96a46d7e4 (diff) |
xymtex (now lppl, minus manuals without sources)
git-svn-id: svn://tug.org/texlive/trunk@32182 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/source/latex/xymtex/base/assurelatexmode.dtx')
-rw-r--r-- | Master/texmf-dist/source/latex/xymtex/base/assurelatexmode.dtx | 340 |
1 files changed, 340 insertions, 0 deletions
diff --git a/Master/texmf-dist/source/latex/xymtex/base/assurelatexmode.dtx b/Master/texmf-dist/source/latex/xymtex/base/assurelatexmode.dtx new file mode 100644 index 00000000000..cc8834aa14a --- /dev/null +++ b/Master/texmf-dist/source/latex/xymtex/base/assurelatexmode.dtx @@ -0,0 +1,340 @@ +% \iffalse meta-comment +%% File: assurelatexmode.dtx +% +% Copyright 2010,2013 by Shinsaku Fujita +% +% This file is part of XyMTeX system. +% ------------------------------------- +% +% This file (assurelatexmode.sty) is a successor to: +% +% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +% \typeout{XyMTeX for Drawing Chemical Structural Formulas. Version 1.00} +% \typeout{ -- Released December 1, 1993 by Shinsaku Fujita} +% Copyright (C) 1993 by Shinsaku Fujita, all rights reserved. +% +% This file is a part of the macro package ``XyMTeX'' which has been +% designed for typesetting chemical structural formulas. +% +% This file is to be contained in the ``xymtex'' directory which is +% an input directory for TeX. It is a LaTeX optional style file and +% should be used only within LaTeX, because several macros of the file +% are based on LaTeX commands. +% +% For the review of XyMTeX, see +% (1) Shinsaku Fujita, ``Typesetting structural formulas with the text +% formatter TeX/LaTeX'', Computers and Chemistry, in press. +% The following book deals with an application of TeX/LaTeX to +% preparation of manuscripts of chemical fields: +% (2) Shinsaku Fujita, ``LaTeX for Chemists and Biochemists'' +% Tokyo Kagaku Dozin, Tokyo (1993) [in Japanese]. +% +% This work may be distributed and/or modified under the +% conditions of the LaTeX Project Public License, either version 1.3 +% of this license or (at your option) any later version. +% The latest version of this license is in +% http://www.latex-project.org/lppl.txt +% and version 1.3 or later is part of all distributions of LaTeX +% version 2005/12/01 or later. +% +% This work has the LPPL maintenance status `maintained'. +% The Current Maintainer of this work is Shinsaku Fujita. +% +% This work consists of the files assurelatexmode.dtx and assurelatexmode.ins +% and the derived file lewisstruc.sty. +% +% Please report any bugs, comments, suggestions, etc. to: +% Shinsaku Fujita, +% Shonan Institute of Chemoinformatics and Mathematical Chemistry +% Kaneko 479-7 Ooimachi, Ashigara-Kami-Gun, Kanagawa 250-0019 Japan +% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +% \def\j@urnalname{assurelatexmode} +% \def\versi@ndate{October 01, 2010} +% \def\versi@nno{ver5.00} +% \def\copyrighth@lder{SF}% Shinsaku Fujita +% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +% +% \fi +% +% \CheckSum{189} +%% \CharacterTable +%% {Upper-case \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z +%% Lower-case \a\b\c\d\e\f\g\h\i\j\k\l\m\n\o\p\q\r\s\t\u\v\w\x\y\z +%% Digits \0\1\2\3\4\5\6\7\8\9 +%% Exclamation \! Double quote \" Hash (number) \# +%% Dollar \$ Percent \% Ampersand \& +%% Acute accent \' Left paren \( Right paren \) +%% Asterisk \* Plus \+ Comma \, +%% Minus \- Point \. Solidus \/ +%% Colon \: Semicolon \; Less than \< +%% Equals \= Greater than \> Question mark \? +%% Commercial at \@ Left bracket \[ Backslash \\ +%% Right bracket \] Circumflex \^ Underscore \_ +%% Grave accent \` Left brace \{ Vertical bar \| +%% Right brace \} Tilde \~} +% +% \setcounter{StandardModuleDepth}{1} +% +% \StopEventually{} +% \MakeShortVerb{\|} +% +% \iffalse +% \changes{v5.00}{2010/10/01}{First release for XyMTeX5.00} +% \fi +% +% \iffalse +%<*driver> +\NeedsTeXFormat{pLaTeX2e} +% \fi +\ProvidesFile{assurelatexmode.dtx}[2010/10/01 v5.00 assurelatexmode package file] +% \iffalse +\documentclass{ltxdoc} +\GetFileInfo{lewisstruc.dtx} +% +% %%XyMTeX Logo: Definition 2%%% +\def\UPSILON{\char'7} +\def\XyM{X\kern-.30em\smash{% +\raise.50ex\hbox{\UPSILON}}\kern-.30em{M}} +\def\XyMTeX{\XyM\kern-.1em\TeX} +% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +\title{Dummy Declarations for assuring the \protect\TeX/\protect\LaTeX{} mode +by {\sffamily assurelatexmode.sty} +(\fileversion) of \XyMTeX{}} +\author{Shinsaku Fujita \\ +Shonan Institute of Chemoinformatics and +Mathematical Chemistry \\ +Kanagawa, 258-0019 Japan +} +\date{\filedate} +% +\begin{document} + \maketitle + \DocInput{assurelatexmode.dtx} +\end{document} +%</driver> +% \fi +% +% \section{Introduction}\label{assurelatexmode:intro} +% +% \subsection{Options for {\sffamily docstrip}} +% +% \DeleteShortVerb{\|} +% \begin{center} +% \begin{tabular}{|l|l|} +% \hline +% \emph{option} & \emph{function}\\ \hline +% assurelatexmode & assurelatexmode.sty \\ +% driver & driver for this dtx file \\ +% \hline +% \end{tabular} +% \end{center} +% \MakeShortVerb{\|} +% +% \subsection{Version Information} +% +% \begin{macrocode} +%<*assurelatexmode> +\typeout{Part of XyMTeX for Drawing Chemical Structural Formulas. Version 5.01} +\typeout{ -- Released May 27, 2013 by Shinsaku Fujita} +% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +\def\j@urnalname{assurelatexmode} +\def\versi@ndate{May 27, 2013} +\def\versi@nno{ver5.01} +\def\copyrighth@lder{SF} % Shinsaku Fujita +% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +\typeout{XyMTeX Macro File `\j@urnalname' (\versi@nno) <\versi@ndate>% +\space[\copyrighth@lder]} +% \end{macrocode} +% +% \begin{macrocode} +\RequirePackage{chemstr} +% \end{macrocode} +% +% \section{Dummy Declarations} +% If a document written for the PostScript or PDF mode is processed by the TeX/LaTeX mode, +% some commands for the PS or PDF mode (defined in the \textsf{xymtx-ps} or \textsf{xymtx-pdf} +% package) cause errors of non-existence. To avoid these errors, +% dummy commands are defined as follows. These dummy commands are overwritten or replaced by +% equivalent commands when processed by the PS or PDF mode. +% +% \begin{macro}{changedashtowedge} +% \begin{macro}{changewedgetodash} +% \changes{v5.00}{2010/10/01}{TeX/LaTeX, PS, and PDF modes: Switch for wedged bonds} +% \begin{macrocode} +\newif\if@wedgesw \@wedgeswtrue +\newif\if@hasheddashsw \@hasheddashswtrue +\def\wedgehasheddash{\@wedgeswtrue\@hasheddashswtrue} +\def\wedgehashedwedge{\@wedgeswtrue\@hasheddashswfalse} +\def\dashhasheddash{\@wedgeswfalse\@hasheddashswtrue} +\@ifundefined{ifmolfront}{\newif\ifmolfront \molfrontfalse}{} +\@ifundefined{if@skbondlist}{\newif\if@skbondlist \@skbondlistfalse}{} +% \end{macrocode} +% \end{macro} +% \end{macro} +% +% \begin{macro}{\if@thicklinesw etc.} +% \changes{v5.00}{2010/10/01}{TeX/LaTeX mode compatible to PS, and PDF modes} +% \begin{macrocode} +\newif\if@thicklinesw \@thicklineswfalse +\def\Thick@Lines{\@thicklineswtrue}%redefinition +\def\Thin@Lines{\@thicklineswfalse}%redefinition +\def\thickLineWidth{1.6pt} +\def\thinLineWidth{0.4pt} +% \end{macrocode} +% \end{macro} +% +% \begin{macro}{WedgeAsSubst} +% \changes{v5.00}{2010/10/01}{TeX/LaTeX mode compatible to PS, and PDF modes} +% \begin{macrocode} +\def\WedgeAsSubstTeXLaTeX(#1,#2)(#3,#4)#5{% +\begingroup +\@thicklineswtrue \@wedgeswtrue +\molfrontfalse \@skbondlistfalse +\leavevmode +\Put@@Line(#1,#2)(#3,#4){#5}% +\endgroup} +\let\WedgeAsSubst=\WedgeAsSubstTeXLaTeX%for compatibility to PS/PDF mode +% \end{macrocode} +% \end{macro} +% +% The macro |\WedgeAsSubstX| has a starting point, +% an endpoint, and the width of a wedge as its arguments. +% Compare this command with |\WedgeAsSubst|, which has +% a starting point, a slope, and the width of a wedge +% as its arguments. +% +% \begin{macro}{WedgeAsSubstX} +% \changes{v5.01}{2013/05/27}{TeX/LaTeX mode compatible to PS, and PDF modes} +% \begin{macrocode} +\def\WedgeAsSubstXTeXLaTeX(#1,#2)(#3,#4){% +\@ifnextchar[{\Wedge@AsSubstXTeXLaTeX(#1,#2)(#3,#4)}% +{\Wedge@AsSubstXTeXLaTeX(#1,#2)(#3,#4)[10]}} +\def\Wedge@AsSubstXTeXLaTeX(#1,#2)(#3,#4)[#5]{% +\begingroup +%#5 not used +\leavevmode \thicklines +\drawline(#1,#2)(#3,#4)% +\endgroup} +\let\WedgeAsSubstX=\WedgeAsSubstXTeXLaTeX%for compatibility to PS/PDF mode +% \end{macrocode} +% \end{macro} +% +% The macro |\PUT@@bondLINE| is used in the macro |\Put@@Line|, +% which draws a bond line. +% +% \begin{macro}{\PUT@@bondLINE} +% \begin{macro}{\PutTeXLaTeXLine} +% \begin{macro}{\PutBondLine} +% \changes{v5.00}{2010/10/01}{TeX/LaTeX mode compatible to PS, and PDF modes} +% \begin{macrocode} +\def\PUT@@bondLINE(#1,#2)(#3,#4)#5{\begingroup% +\linethickness{#5}\drawline(#1,#2)(#3,#4)% +\endgroup} +\let\PutTeXLaTeXLine=\PUT@@bondLINE%for user's use +\let\PutBondLine=\PUT@@bondLINE%for user's use +% \end{macrocode} +% \end{macro} +% \end{macro} +% \end{macro} +% +% The macro |\PUT@@dashedLINE| is used to draw a dashed bond line, +% which usually links two non-adjacent atoms of a cyclic compound. +% +% \begin{macro}{\PUT@@dashedLINE} +% \begin{macro}{\PutTeXLaTeXdashed} +% \begin{macro}{\PutDashedBond} +% \changes{v5.00}{2010/10/01}{TeX/LaTeX mode compatible to PS, and PDF modes} +% \begin{macrocode} +\def\PUT@@dashedLINE(#1,#2)(#3,#4)#5{% +\begingroup +\ifdim\unitlength>0.08pt +\linethickness{#5}\dottedline{20}(#1,#2)(#3,#4)% +%\dashline{2}[2](#1,#2)(#3,#4)% +\else +\linethickness{#5}\dottedline{20}(#1,#2)(#3,#4) +%\dashline{1.8}[1.8](#1,#2)(#3,#4)% +\fi +\endgroup +} +\let\PutTeXLaTeXdashed=\PUT@@dashedLINE%for user's use +\let\PutDashedBond=\PUT@@dashedLINE%for compatibility to PS and PDF mode +% \end{macrocode} +% \end{macro} +% \end{macro} +% \end{macro} +% +% \begin{macro}{\HashWedgeAsSubst} +% \changes{v5.01}{2010/05/27}{TeX/LaTeX mode compatible to PS, and PDF modes} +% \begin{macrocode} +\def\HashWedgeAsSubstTeXLaTeX(#1,#2)(#3,#4)#5{% +\begingroup +\SlopetoXY(#1,#2)(#3,#4){#5}%%replaced (code from chemstr.sty) +\leavevmode +\linethickness{1pt}\dottedline{20}(#1,#2)(\the\@tempcntXa,\the\@tempcntYa)% +\endgroup} +\let\HashWedgeAsSubst=\HashWedgeAsSubstTeXLaTeX%for compatibility to PS and PDF mode +% \end{macrocode} +% \end{macro} +% +% The macro |\HashWedgeAsSubstX| has a starting point, +% an endpoint, and the width of a wedge as its arguments. +% Compare this command with |\HashWedgeAsSubst|, which has +% a starting point, a slope, and the width of a wedge +% as its arguments. +% +% \begin{macro}{\HashWedgeAsSubstX} +% \changes{v5.01}{2010/05/27}{TeX/LaTeX mode compatible to PS, and PDF modes} +% \begin{macrocode} +\def\HashWedgeAsSubstXTeXLaTeX(#1,#2)(#3,#4){% +\@ifnextchar[{\HashWedge@AsSubstXTeXLaTeX(#1,#2)(#3,#4)}% +{\HashWedge@AsSubstXTeXLaTeX(#1,#2)(#3,#4)[10]}} +\def\HashWedge@AsSubstXTeXLaTeX(#1,#2)(#3,#4)[#5]{% +\begingroup +\leavevmode\@tempdima=#5\unitlength +\linethickness{\@tempdima}\dottedline{20}(#1,#2)(#3,#4) +\endgroup} +\let\HashWedgeAsSubstX=\HashWedgeAsSubstXTeXLaTeX%for compatibility to PS and PDF mode +% \end{macrocode} +% \end{macro} +% +% The macro |\putRoundArrowTeXLaTeX| throws its main task to its inner +% macro |\putRound@rrowTeXLaTeX|, which is incapable of treating +% an optional argument for specifying the direction of an arrow head. +% The macro |\putRoundArrow| is defined as a user command to +% assure the compatibility to the PostScript and the PDF mode. +% This command should be used in the PostScript or the PDF mode! +% +% \begin{macro}{\putRoundArrowTeXLaTeX} +% \begin{macro}{\putRound@rrowTeXLaTeX} +% \begin{macro}{\putRoundArrow} +% \changes{v5.00}{2010/10/01}{For TeXLaTeX mode} +% \begin{macrocode} +\def\putRoundArrowTeXLaTeX{% +\@ifnextchar[{\putRound@rrowTeXLaTeX}{\putRound@rrowTeXLaTeX[->]}} +\def\putRound@rrowTeXLaTeX[#1]#2{\drawline#2% + \XyMTeXWarning{The command + \string\putRoundArrow\space is unavailable in TeX/LaTeX mode. ^^J + Please try the PostScript or PDF mode}} +\let\putRoundArrow=\putRoundArrowTeXLaTeX%for the compatibility to PDF and PS mode +% \end{macrocode} +% \end{macro} +% \end{macro} +% \end{macro} +% +% \begin{macro}{\thinlines} +% \begin{macro}{\thicklines} +% \changes{v5.00}{2010/10/01}{TeX/LaTeX mode compatible to PS, and PDF modes} +% \begin{macrocode} +\gdef\thinlines{\let\@linefnt\tenln \let\@circlefnt\tencirc + \@wholewidth=\thinLineWidth \@halfwidth .5\@wholewidth} +\gdef\thicklines{\let\@linefnt\tenlnw \let\@circlefnt\tencircw + \@wholewidth=\thickLineWidth \@halfwidth .5\@wholewidth} +\endinput +%</assurelatexmode> +% \end{macrocode} +% \end{macro} +% \end{macro} +% +% \Finale +% +\endinput |