对于学术版,我需要一个相当复杂的布局。我尝试使用列和 tkiz,但我没有足够的经验来完成这项艰巨的任务。
我该如何去把|第。|不完全幻方|完全魔方|文本|彼此相邻,并仍然保持拥有幸福的土星以上不完全幻方?
我设法分别转录了每个片段,但我不知道如何将它们浮动在一起。我提供了 MWE,但如果我以错误的方式处理这个问题,欢迎提出其他建议!
平均能量损失
% !TeX spellcheck = nl_NL
% !TEX encoding = UTF-8 Unicode
% -*- coding: utf-8 -*-
\documentclass[a4paper]{article}
\usepackage{tikz}
\begin{document}
\textit{lood}
\paragraph{}
Habere bona \textit{Saturni}
\begin{tikzpicture}
\draw[step=1cm,gray,very thin] (0,0+0.5) grid (3,2);
\node at (0.5,1.5){2}; \node at (1.5,1.5){0}; \node at (2.5,1.5){4};
\node at (0.5,0.5){[7]}; \node at (1.5,0.5){[5]}; \node at (2.5,0.5){[3]};
\end{tikzpicture}
\paragraph{}
\begin{tikzpicture}
\draw[step=1cm,gray,very thin] (0,0) grid (3,3);
\node at (0.5,2.5){2}; \node at (1.5,2.5){9}; \node at (2.5,2.5){4};
\node at (0.5,1.5){7}; \node at (1.5,1.5){5}; \node at (2.5,1.5){3};
\node at (0.5,0.5){6}; \node at (1.5,0.5){1}; \node at (2.5,0.5){8};
\end{tikzpicture}
\paragraph{}
sculpa haec in plumbo \textit{Saturno} in\\
\textit{libra} \textit{piscibus} \textit{aquario} Direct\textit{o} et fortunat\textit{o}\\
et \textit{Luna} eum aspic\textit{iente} amico aspectu
\end{document}
感谢您的帮助!
答案1
使用该包来整理各个部件非常容易xcoffins
。
1 分配棺材。(\New..)。棺材是带有把手的盒子!
2 将材料填入棺材中。(\Set ...)
3 用把手将棺材连接起来,组装起来。(\连接...)
4 写入结果。(\Typeset ...)
这个棺材叫做“零维框架”,它有一个“支撑架”来收集其他所有东西。
最终的写入是在当前插入点完成的。
在之前的问答中可以找到一些扩展的解释
使用 tcolorbox 包或任何其他包创建一个框?(图像)
我重复使用了你问题中的 tikz 图像,并添加了相同的位移来分离材料。(我不知道把“lood”放在哪里)
% !TeX spellcheck = nl_NL
% !TEX encoding = UTF-8 Unicode
% -*- coding: utf-8 -*-
\documentclass[a4paper]{article}
\usepackage{xcoffins}
\usepackage{tikz}
\begin{document}
\NewCoffin\Frame
\NewCoffin\completeMagic
\NewCoffin\incompleteMagic
\NewCoffin\iniText
\NewCoffin\aboveText
\NewCoffin\lastText
\SetHorizontalCoffin\completeMagic{%
\begin{tikzpicture}%
\draw[step=1cm,gray,very thin] (0,0) grid (3,3);%
\node at (0.5,2.5){2}; \node at (1.5,2.5){9}; \node at (2.5,2.5){4};%
\node at (0.5,1.5){7}; \node at (1.5,1.5){5}; \node at (2.5,1.5){3};%
\node at (0.5,0.5){6}; \node at (1.5,0.5){1}; \node at (2.5,0.5){8}; %
\end{tikzpicture}}
\SetHorizontalCoffin\iniText{.th.}
\SetHorizontalCoffin\incompleteMagic{%
\begin{tikzpicture}
\draw[step=1cm,gray,very thin] (0,0+0.5) grid (3,2);
\node at (0.5,1.5){2}; \node at (1.5,1.5){0}; \node at (2.5,1.5){4};
\node at (0.5,0.5){[7]}; \node at (1.5,0.5){[5]}; \node at (2.5,0.5){[3]};
\end{tikzpicture}
}
\SetVerticalCoffin\lastText{200pt}{sculpa haec in plumbo \textit{Saturno} in\par
\textit{libra} \textit{piscibus} \textit{aquario} Direct\textit{o} et fortunat\textit{o}\par
et \textit{Luna} eum aspic\textit{iente} amico aspectu}
\SetHorizontalCoffin\aboveText{Habere bona \textit{Saturni}}
\JoinCoffins*\incompleteMagic[hc,t]\aboveText[hc,b](0pt,5pt)
\JoinCoffins*\Frame[hc,vc]\iniText[r,vc]
\JoinCoffins*\Frame[\iniText-r,\iniText-vc]\incompleteMagic[l,vc](15pt,0pt)
\JoinCoffins*\Frame[\incompleteMagic-r,\incompleteMagic-t]\completeMagic[l,t](20pt,0pt)
\JoinCoffins*\Frame[\completeMagic-r,\completeMagic-t]\lastText[l,t]
\noindent\TypesetCoffin\Frame
\end{document}
将最后的文本分成三个句子并使用三个棺材,可以将它们每个与最后一个方块的行对齐。(更大的字体大小,sculpa 还是 Sculpa?)
\NewCoffin\lastTexti
\NewCoffin\lastTextii
\NewCoffin\lastTextiii
\SetHorizontalCoffin\lastTexti{\large Sculpa haec in plumbo \textit{Saturno} in}
\SetHorizontalCoffin\lastTextii{\large \textit{libra} \textit{piscibus} \textit{aquario} Direct\textit{o} et fortunat\textit{o}}
\SetHorizontalCoffin\lastTextiii{\large et \textit{Luna} eum aspic\textit{iente} amico aspectu}
....
%\JoinCoffins*\Frame[\completeMagic-r,\completeMagic-t]\lastText[l,t]
\JoinCoffins*\Frame[\completeMagic-r,\completeMagic-t]\lastTexti[l,t](20pt,-2ex)
\JoinCoffins*\Frame[\completeMagic-r,\completeMagic-vc]\lastTextii[l,t](20pt,1ex)
\JoinCoffins*\Frame[\completeMagic-r,\completeMagic-b]\lastTextiii[l,t](20pt,4ex)
\noindent\TypesetCoffin\Frame
答案2
首先,如果你把一个接一个tikzpicture
地放上去,它们会试图对齐在一条线上。因此,你要做的就是去掉\paragraph{}
它们之间的 并删除空格。至于上面的标题,你可以使用node label
它并将其放置在node
你放置它的 上。如果你试图对齐的图像具有相同的尺寸,那么添加“填充”是一种方法(我添加了一个空节点)。
% !TeX spellcheck = nl_NL
% !TEX encoding = UTF-8 Unicode
% -*- coding: utf-8 -*-
\documentclass[a4paper]{article}
\usepackage{tikz}
\begin{document}
\textit{lood}
\begin{tikzpicture}
\draw[step=1cm,gray,very thin] (0,0+0.5) grid (3,2);
\node at (0.5,1.5){2}; \node[label={[yshift=0.5cm]Habere bona \textit{Saturini}}] at (1.5,1.5){0}; \node at (2.5,1.5){4}; % label on the middle node so it is above
\node at (0.5,0.5){[7]}; \node at (1.5,0.5){[5]}; \node at (2.5,0.5){[3]};
\node at (0.5,-0.9) {}; % fake node so that the boxes have the same dimensions
\end{tikzpicture} % no space = same line
\begin{tikzpicture}
\draw[step=1cm,gray,very thin] (0,0) grid (3,3);
\node at (0.5,2.5){2}; \node at (1.5,2.5){9}; \node at (2.5,2.5){4};
\node at (0.5,1.5){7}; \node at (1.5,1.5){5}; \node at (2.5,1.5){3};
\node at (0.5,0.5){6}; \node at (1.5,0.5){1}; \node at (2.5,0.5){8};
\end{tikzpicture}
\paragraph{}
sculpa haec in plumbo \textit{Saturno} in\\
\textit{libra} \textit{piscibus} \textit{aquario} Direct\textit{o} et fortunat\textit{o}\\
et \textit{Luna} eum aspic\textit{iente} amico aspectu
\end{document}
希望这可以帮助 :)