summaryrefslogtreecommitdiff
path: root/graphics/mcf2graph/mcf_example.tex
blob: c0874a757c4da03c6c8ef2b19a9e2059bb2ea75b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Example of MCF typeset by LaTeX   mcf_examples.tex   by A.Yamaji  2021.05.05
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\documentclass[a4paper]{article}
\usepackage{graphicx}
\makeatletter%
%--------------------------------
\edef\jobname{mcf_exa_soc}%
\usepackage{mcf_setup}
%--------------------------------
%%%%\pdfpkresolution=1200
%--------------------------------
%%%%\edef\f@ext{pk}%
\edef\f@ext{mps}%
%--------------------------------
\pagestyle{empty}
\topmargin=-24mm
\oddsidemargin=-12mm
\textwidth=190mm
\textheight=280mm
\parindent=0mm
\setlength\columnsep{8mm}
%--------------------------------
\newbox \f@box%
\newcount \f@num%
\newcount \tnum%
\tnum=0%
\font\labelM=cmtt8 at 6pt\relax%
%--------------------------------
\newif\ifCONT@%
\newread\@auxf%
%--------------------------------
\f@num=1%
\unitlength=0.01mm%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\begin{document}
\begin{center}
 {\Huge\sf Molecular Coding Format examples} \vspace{5mm} \\
 Author : Akira Yamaji \quad Date : \today \\
 Located at : http://www.ctan.org/pkg/mcf2graph \vspace{3mm} \\
\end{center}
{\small ** use molecular data base file 'mcf\_data\_base.mcf'
 \vspace{3mm} \\
%------------------------------------------------------------------------
\noindent%
\openin\@auxf=\jobname-info.aux%
\CONT@true%
\loop%
\read\@auxf to \info%
\ifeof\@auxf\CONT@false\else%
  \infotovar{\info}%
  \begin{picture}(3750,3350)%
     \put(20,3000){\footnotesize\bf \the\f@num:\EN}%
     \put(20,2750){\labelM MW:\mw { / }FM:\fm}%
     \put(20,2530){\labelM MW:\MW(data)}%
     \put( 0,0){%
       \makebox(3750,2530){%
         \ifx\f@ext\@pk{\font\@font=\jobname\@font\char\f@num}%
         \else%
           \edef\f@file{\jobname-\z@num\f@num.\f@ext}%
           \includegraphics{\f@file}%
         \fi%
       }%
     }%
  \end{picture}%
  %------------------------------------------------------------
  \advance\f@num1\relax%
  \advance\tnum1\relax%
  \ifnum\tnum=5 \\ \tnum=0 \fi%
\fi%
\ifCONT@ \repeat%
\closein\@auxf%
%------------------------------------------------------------------------
\end{document}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%