Ti 中的线条间距看起来不一致钾Z 框。我该如何修复它?
\documentclass[20pt]{extarticle}
\usepackage[utf8]{inputenc}
\usepackage{geometry}
\usepackage{graphicx}
\usepackage{lipsum}
\usepackage{bookman}
\geometry{paperheight=77.45cm,paperwidth=101.6cm,margin=4mm}
\usepackage[ngerman]{babel}
\usepackage{tikz}
\definecolor{almond}{rgb}{0.94, 0.87, 0.8}
\begin{document}
\centering
\tikzstyle{mybox} = [draw=black, fill=almond,
rectangle, rounded corners, inner sep=40pt, inner ysep=40pt, xshift=5cm]
\tikzstyle{fancytitle} =[fill=white, text=black]
\begin{tikzpicture}[remember picture,overlay]
\node [mybox,anchor=north west,font=\fontsize{70}{0}\selectfont] (box) at
([shift={(1cm,-5cm)}]current page.north west){%
\begin{minipage}{0.40\textwidth}
\lipsum[1-1]
\end{minipage}
};
\node[fancytitle, right=10pt,font=\fontsize{60}{0}\selectfont] at (box.north
west) {WARNING};
\end{tikzpicture}
\tikzstyle{mybox} = [draw=black, fill=almond,
rectangle, rounded corners, inner sep=40pt, inner ysep=40pt, xshift=-1cm]
\tikzstyle{fancytitle} =[fill=white, text=black]
\begin{tikzpicture}[remember picture,overlay]
\node [mybox,anchor=north east,font=\fontsize{60}{0}\selectfont] (box) at
([shift={(-5cm,-5cm)}]current page.north east){%
\begin{minipage}{0.40\textwidth}
\lipsum[1-1]
\end{minipage}
};
\node[fancytitle, right=10pt,font=\fontsize{60}{0}\selectfont] at (box.north
west) {BLENDING INFORMATION};
\end{tikzpicture}
\end{document}
答案1
看看以下内容是否是您想要的:
\documentclass[20pt]{extarticle}
\usepackage[paperheight=77.45cm,paperwidth=101.6cm,
margin=4mm]{geometry}
\usepackage[ngerman]{babel}
\usepackage{bookman}
\usepackage{tikz}
\usetikzlibrary{positioning}
\definecolor{almond}{rgb}{0.94, 0.87, 0.8}
\usepackage{graphicx}
\usepackage{lipsum}
\begin{document}
\centering
\tikzset{mybox/.style = {draw=black, fill=almond,
rectangle, rounded corners,
inner sep=40pt, text width=#1},
fancytitle/.style = {fill=white, text=black}
}
\begin{tikzpicture}[remember picture,overlay,
node distance=5cm and 5cm]
\node [mybox=0.4\textwidth,
font=\fontsize{70}{77}\selectfont,
below right=of current page.north west] (box-left) {\\ \lipsum[1-1]};
\node[fancytitle,
font=\fontsize{60}{66}\selectfont,
below right] at (box-left.north west) {WARNING};
%
\node [mybox=0.4\linewidth,
font=\fontsize{60}{66}\selectfont,
below left=of current page.north east] (box-right) {\\ \lipsum[1-1]};
\node[fancytitle,
font=\fontsize{60}{66}\selectfont,
below right] at (box-right.north west) {BLENDING INFORMATION};
\end{tikzpicture}
\end{document}
笔记:
- 在上面的 MWE 中,被视为问题下面的评论。
- 如果在所有节点中使用相同的字体大小,您将获得更好的结果。在这种情况下,其大小的选择可以移动到
box
样式定义中:
\documentclass[20pt]{extarticle}
\usepackage[paperheight=77.45cm,paperwidth=101.6cm,
margin=4mm]{geometry}
\usepackage[ngerman]{babel}
\usepackage{bookman}
\usepackage{tikz}
\usetikzlibrary{positioning}
\definecolor{almond}{rgb}{0.94, 0.87, 0.8}
\usepackage{graphicx}
\usepackage{lipsum}
\begin{document}
\centering
\tikzset{mybox/.style = {draw=black, fill=almond,
rectangle, rounded corners,
inner sep=40pt, text width=#1,
font=\fontsize{60}{72}\selectfont,},
fancytitle/.style = {fill=white, text=black,
font=\fontsize{60}{72}\selectfont}
}
\begin{tikzpicture}[remember picture,overlay,
node distance=5cm and 5cm]
\node [mybox=0.4\textwidth,
below right=of current page.north west] (box-left) {\lipsum[1-1]};
\node[fancytitle,
right] at (box-left.north west) {WARNING};
%
\node [mybox=0.4\linewidth,
below left=of current page.north east] (box-right) {\lipsum[1-1]};
\node[fancytitle,
right] at (box-right.north west) {BLENDING INFORMATION};
\end{tikzpicture}
\end{document}