Skip to content

Instantly share code, notes, and snippets.

@KernelA
Created September 30, 2023 14:36
Show Gist options
  • Save KernelA/ab6d2a8db0e597150475469088280ed4 to your computer and use it in GitHub Desktop.
Save KernelA/ab6d2a8db0e597150475469088280ed4 to your computer and use it in GitHub Desktop.
hello_xelatex_toc
\documentclass[12pt, oneside]{extarticle}
\usepackage{polyglossia}
\setdefaultlanguage[indentfirst=true,forceheadingpunctuation=false]{russian}
\setotherlanguages{english}
\IfFontExistsTF{Times New Roman}
{\setmainfont{Times New Roman}
\newfontfamily\cyrillicfont{Times New Roman}[Script=Cyrillic]}
{\setmainfont[Script=Cyrillic]{FreeSerif}}
\IfFontExistsTF{Courier New}
{\setmonofont{Courier New}
\newfontfamily\cyrillicfonttt{Courier New}[Script=Cyrillic]
}
{\setmonofont[Script=Cyrillic]{FreeMono}}
\IfFontExistsTF{Arial}
{\setsansfont{Arial}
\newfontfamily\cyrillicfontsf{Arial}[Script=Cyrillic]
}
{\setsansfont[Script=Cyrillic]{FreeSans}}
\usepackage{hyperref}
\title{Привет XeLaTeX}
\author{Автор}
\date{\today}
\begin{document}
\maketitle
\clearpage
\tableofcontents
\clearpage
\section{Введение}
\subsection{Сгенерированный текст языковой моделью (пунктуация и орфография оригинальная)}
Latex - это система компьютерной вёрстки, разработанная для создания технической и научной документации, а также других видов печатной продукции. Она широко используется в академических кругах, научно-исследовательских институтах и промышленных предприятиях для создания различных документов, включая научные статьи, учебники, технические отчёты и т.д. Latex предоставляет набор инструментов и команд для форматирования текста, составления математических формул, графиков, таблиц и других элементов документа. Одной из главных особенностей Latex является его расширяемость и возможность создания собственных команд и стилей.
{\sloppy
}
\end{document}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment