新增标题框和文本框
This commit is contained in:
@@ -4,6 +4,7 @@
|
||||
%% 完成时间:2022-05-09
|
||||
|
||||
\RequirePackage{listings,verbatim}%引入代码包
|
||||
\RequirePackage{caption}
|
||||
\usepackage{tcolorbox} %引入彩色框
|
||||
\tcbuselibrary{most} %引入所有包
|
||||
|
||||
@@ -43,7 +44,6 @@
|
||||
}
|
||||
|
||||
%% 代码块标题设定
|
||||
\RequirePackage{caption}
|
||||
\DeclareCaptionFormat{codecaptionformat}{%
|
||||
\parbox{\textwidth}{\hspace{2em}\textcolor{violet}\faCode~\textcolor{violet}{#1#2}\hspace{.5em}#3}%代码块caption的设置
|
||||
}
|
||||
@@ -124,6 +124,25 @@
|
||||
title=#1
|
||||
}
|
||||
|
||||
%文本框textbox
|
||||
\newtcolorbox{textbox}[1]{
|
||||
colback=#1!5!white,
|
||||
colframe=#1,
|
||||
boxrule=0.5pt,
|
||||
arc=2pt,
|
||||
}
|
||||
|
||||
%标题框headbox
|
||||
\newtcolorbox{headbox}[1]{
|
||||
colback=#1,
|
||||
colframe=#1,
|
||||
boxrule=0.5pt,
|
||||
arc=2pt,
|
||||
coltext=white,
|
||||
fontupper= \bfseries,
|
||||
left=0pt, right=0pt, top=0pt, bottom=0pt,%内部文字边距
|
||||
}
|
||||
|
||||
|
||||
%一些元素的中文名称
|
||||
\renewcommand{\figurename}{图}
|
||||
|
||||
@@ -75,7 +75,7 @@
|
||||
\defbeamertemplate{title page}{text}{%
|
||||
\begin{center} %所有文字居中
|
||||
\vspace{2.5cm} %标题距离banner的距离
|
||||
\usebeamercolor[white]{title}\usebeamerfont*{title}\strut{}\inserttitle\par%字体颜色为白色
|
||||
\usebeamercolor[white]{title}\usebeamerfont*{title}\strut{}\texorpdfstring{\inserttitle}\par%字体颜色为白色
|
||||
\vspace{0.5cm}%副标题到主标题的距离
|
||||
\usebeamercolor[white]{subtitle}\usebeamerfont{subtitle}\strut{}\insertsubtitle\par%字体为白色
|
||||
\vspace{1.6cm}%作者到副标题的距离
|
||||
@@ -102,7 +102,7 @@
|
||||
%普通页面左下角信息
|
||||
\setbeamertemplate{footline}{%
|
||||
\hspace{0.8cm}
|
||||
\usebeamercolor[fg]{title}\insertauthor\enspace\vrule width0.3pt\enspace\inserttitle%左下角作者信息和标题信息
|
||||
\usebeamercolor[fg]{title}\insertauthor\enspace\vrule width0.3pt\enspace\texorpdfstring{\inserttitle}%左下角作者信息和标题信息
|
||||
\vspace{0.04cm} %页脚到底部的距离
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user