在本网站下载的书的封面,编译老出错

发布于 2025-04-13 22:41:32
\documentclass{article}
\usepackage{amsmath}
\usepackage{tikz}
\usetikzlibrary{intersections,decorations.text}
\definecolor{c1}{RGB}{62, 97, 127}
\definecolor{c2}{RGB}{104, 182, 182}
\definecolor{c3}{RGB}{107, 190, 190}
\definecolor{c4}{RGB}{100, 172, 174}
\definecolor{c5}{RGB}{95, 162, 162}
\begin{document}
    \thispagestyle{empty}
    \begin{tikzpicture}[overlay,remember picture,font=\sffamily\bfseries]
        \draw[ultra thick,c4,name path=big arc] ([xshift=-2mm]current page.north) arc(150:285:11)
        coordinate[pos=0.225] (x0);
        \begin{scope}
            \clip ([xshift=-2mm]current page.north) arc(150:285:11) --(current page.north
            east);
            \fill[c4!50,opacity=0.25] ([xshift=4.55cm]x0) circle (4.55);
            \fill[c4!50,opacity=0.25] ([xshift=3.4cm]x0) circle (3.4);
            \fill[c4!50,opacity=0.25] ([xshift=2.25cm]x0) circle (2.25);
            \draw[ultra thick,c4!50] (x0) arc(-90:30:6.5);
            \draw[ultra thick,c4] (x0) arc(90:-30:8.75);
            \draw[ultra thick,c4!50,name path=arc1] (x0) arc(90:-90:4.675);
            \draw[ultra thick,c4!50] (x0) arc(90:-90:2.875);
            \path[name intersections={of=big arc and arc1,by=x1}];
            \draw[ultra thick,c4,name path=arc2] (x1) arc(135:-20:4.75);
            \draw[ultra thick,c4!50] (x1) arc(135:-20:8.75);
            \path[name intersections={of=big arc and arc2,by={aux,x2}}];
            \draw[ultra thick,c4!50] (x2) arc(180:50:2.25);
        \end{scope}
        \path[decoration={text along path,text color=c4,
            raise = -2.8ex,
            text  along path,
            text = {|\sffamily\bfseries|02/18/2019},
            text align = center,
        },
        decorate
        ] ([xshift=-2mm]current page.north) arc(150:245:11);
        %
        \begin{scope}
            \path[clip,postaction={fill=c3}]
            ([xshift=2cm,yshift=-8cm]current page.center) rectangle ++ (4.2,7.7);
            \draw[c5,ultra thick,fill=c2] ([xshift=0.5cm,yshift=-8cm]current page.center)
            ([xshift=0.5cm,yshift=-8cm]current page.center)  arc(180:60:2)
            |- ++ (-3,6) --cycle;
            \draw[ultra thick,c5] ([xshift=-1.5cm,yshift=-8cm]current page.center)
            arc(180:0:2);
            \draw[ultra thick,c5] ([xshift=0.5cm,yshift=-8cm]current page.center)
            arc(180:0:2);
            \draw[ultra thick,c5] ([xshift=2.5cm,yshift=-8cm]current page.center)
            arc(180:0:2);
            \draw[ultra thick,c5] ([xshift=4.5cm,yshift=-8cm]current page.center)
            arc(180:0:2);
            \fill[red] ([xshift=2.5cm,yshift=-8cm]current page.center) +(60:2) circle(1.5mm)
            node[above
            right=2mm,text=c5!80!black]{$\rho:=\dfrac{1+\sqrt{-3}}{2}$};
        \end{scope}
        %
        \fill[c1] ([xshift=2cm,yshift=-8cm]current page.center) rectangle ++ (-12.7,7.7);
        \node[text=white,anchor=west,scale=5,inner sep=0pt] at
        ([xshift=-8cm,yshift=-3.25cm]current page.center) {Some text};
        \node[text=white,anchor=west,scale=2.5,inner sep=0pt] at
        ([xshift=-8cm,yshift=-6cm]current page.center) {Some text};
        %
        \draw[gray,line width=5mm]
        ([xshift=2mm,yshift=-1mm]current page.south west) rectangle ([xshift=-2mm,yshift=1mm]current
        page.north east);
    \end{tikzpicture}
\end{document}
\documentclass{article}
\usepackage{tikz}
\usetikzlibrary{intersections,decorations.text}
\definecolor{c1}{RGB}{62, 97, 127}
\definecolor{c2}{RGB}{104, 182, 182}
\definecolor{c3}{RGB}{107, 190, 190}
\definecolor{c4}{RGB}{100, 172, 174}
\begin{document}
    \thispagestyle{empty}
    \begin{tikzpicture}[overlay,remember picture,font=\sffamily\bfseries]
        \draw[very thick,c4,name path=big arc] ([xshift=-2mm]current page.north) arc(150:285:11)
        coordinate[pos=0.225] (x0);
        \begin{scope}
            \clip ([xshift=-2mm]current page.north) arc(150:285:11) --(current page.north
            east);
            \fill[c4!50,opacity=0.25] ([xshift=4.55cm]x0) circle (4.55);
            \fill[c4!50,opacity=0.25] ([xshift=3.4cm]x0) circle (3.4);
            \fill[c4!50,opacity=0.25] ([xshift=2.25cm]x0) circle (2.25);
            \draw[very thick,c4!50] (x0) arc(-90:30:6.5);
            \draw[very thick,c4] (x0) arc(90:-30:8.75);
            \draw[very thick,c4!50,name path=arc1] (x0) arc(90:-90:4.675);
            \draw[very thick,c4!50] (x0) arc(90:-90:2.875);
            \path[name intersections={of=big arc and arc1,by=x1}];
            \draw[very thick,c4,name path=arc2] (x1) arc(135:-20:4.75);
            \draw[very thick,c4!50] (x1) arc(135:-20:8.75);
            \path[name intersections={of=big arc and arc2,by={aux,x2}}];
            \draw[very thick,c4!50] (x2) arc(180:50:2.25);
        \end{scope}
        \path[decoration={text along path,text color=c4,
            raise = -2.8ex,
            text  along path,
            text = {|\sffamily\bfseries|02/18/2019},
            text align = center,
        },
        decorate
        ] ([xshift=-2mm]current page.north) arc(150:245:11);
        %
        \begin{scope}
            \path[clip,postaction={fill=c3}]
            ([xshift=2cm,yshift=-8cm]current page.center) rectangle ++ (4.2,7.7);
            \fill[c2] ([xshift=0.5cm,yshift=-8cm]current page.center)
            ([xshift=0.5cm,yshift=-8cm]current page.center)  arc(180:60:2)
            |- ++ (-3,6) --cycle;
            \draw[very thick,c4] ([xshift=-1.5cm,yshift=-8cm]current page.center)
            arc(180:0:2);
            \draw[very thick,c4] ([xshift=0.5cm,yshift=-8cm]current page.center)
            arc(180:0:2);
            \draw[very thick,c4] ([xshift=2.5cm,yshift=-8cm]current page.center)
            arc(180:0:2);
            \draw[very thick,c4] ([xshift=4.5cm,yshift=-8cm]current page.center)
            arc(180:0:2);
            \fill[red] ([xshift=2.5cm,yshift=-8cm]current page.center) +(60:2) circle(1.5mm)
            node[above right=2mm]{$\displaystyle\rho=\frac{1+\sqrt{-3}}{2}$};
        \end{scope}
        %
        \fill[c1] ([xshift=2cm,yshift=-8cm]current page.center) rectangle ++ (-12.7,7.7);
        \node[text=white,anchor=west,scale=5,inner sep=0pt] at
        ([xshift=-8cm,yshift=-3.25cm]current page.center) {Some text};
        \node[text=white,anchor=west,scale=2.5,inner sep=0pt] at
        ([xshift=-8cm,yshift=-6cm]current page.center) {Some text};
        %
        \draw[gray,line width=5mm]
        ([xshift=2mm,yshift=-1mm]current page.south west) rectangle ([xshift=-2mm,yshift=1mm]current
        page.north east);
    \end{tikzpicture}
\end{document}

上面是在本网站下载的一个封面,编译提示:

xkeyval.sty: 错误: : Emergency stop.

工具是texstudio,新手请大家不吝赐教。不止是这一个,我在咱们这个网站上下载的书籍封面编译都有这个错误!

查看更多

关注者
0
被浏览
250
3 个回答
远方不远
远方不远 2025-04-13
Hello, LuaLaTeX!

哪儿错了?
关于编译TeX源文档这种入门级问题,请阅读lshort.
9bc32b9ce078c7c2c4b5dcef0f3e356f.png

啸行
啸行 2025-04-14
这家伙很懒,什么也没写!

我复制了问题中的第2段代码,并用我的 texlive 尝试编译了一下,编译命令

latexmk -pdf filename

一切正常,麻烦你试试命令行编译,如果它能通过,可能是你的 texstudio 设置出了问题

Sagittarius Rover
Sagittarius Rover 2025-04-13
我要成为Typst糕手/(ㄒoㄒ)/~~

@u134168 请你具体提供你的TeXLive版本信息。您可以在cmd输入tex -v查看版本。

另外,AFAIK,xkeyval以及过时了...

撰写答案

请登录后再发布答案,点击登录

发布
问题

分享
好友

手机
浏览

扫码手机浏览