Xelatex 章节、章节、小节标题的字体更改
因此,我正在努力改变latex中标题/章节/小节的字体 这是我的密码:Xelatex 章节、章节、小节标题的字体更改,xelatex,Xelatex,因此,我正在努力改变latex中标题/章节/小节的字体 这是我的密码: % !TEX TS?program = pdflatexmk \documentclass[fontsize=12pt]{book} \usepackage[T1]{fontenc} \usepackage{amsmath} \usepackage{mathpazo} %changing font of section/chapter title \usepackage{fontspec} \usepackage{
% !TEX TS?program = pdflatexmk
\documentclass[fontsize=12pt]{book}
\usepackage[T1]{fontenc}
\usepackage{amsmath}
\usepackage{mathpazo}
%changing font of section/chapter title
\usepackage{fontspec}
\usepackage{titlesec}
\newfontfamily\headingfont{Papyrus}
\titleformat{\chapter}{\LARGE\headingfont}
\titleformat{\section}{\LARGE\headingfont}
\titleformat{\subsection}{\Large\headingfont}
\titleformat{\subsubsection}{\large\headingfont}
\title{my report}
\author{user name}
\date
\linespread{1.5}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\begin{document}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\maketitle
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\tableofcontents
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\chapter{introduction}
text : intro
\section{first section}
text : section
\subsection{this subsection}
text :section
\subsubsection{this and that subsection}
text :subsub
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\end{document}
这是输出:
字体仅在章节
和小节
中使用。不适合其他人。
而且编号也丢失了。例如,如果没有titlesec
和fontspec
这就是它的外观。章节和小节编号随此丢失。
我找不到虫子。(使用fontspec也有点烦人,因为它找不到默认的latex字体,所以必须复制粘贴工作目录中的otf
文件)