-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathfarsi-latex-template-article.tex
77 lines (70 loc) · 2.94 KB
/
farsi-latex-template-article.tex
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
%!TEX TS-program = xelatex
%!TEX encoding = UTF-8 Unicode
\documentclass[letterpaper,12pt]{article}
% == Metadata =============================================
\def\ptitle{}
\def\pauthor{}
\title{\ptitle}
\author{\pauthor}
\date{\today}
% == Packages =============================================
\usepackage[parfill]{parskip} % Begin paragraphs with an empty line rather than an indent
\usepackage{fancyhdr} % Running Headers and footers
\usepackage{graphicx} % Images loaded externally
\usepackage[usenames,dvipsnames]{xcolor} % Color setup
\usepackage[pdftex]{hyperref} % Making links in PDF
\usepackage[localise]{xepersian} % Persian in TEX
% == Package Settings ========================================
\settextfont[Scale=1]{XB Kayhan}
\setlatintextfont[Scale=1]{Helvetica}
\setdigitfont[Scale=1]{XB Zar}
%\defpersianfont\Nastaliq[Scale=1]{IranNastaliq}
%\deflatinfont\Myriad[Scale=1]{Myriad Pro}
%-- Hyperref -------------------------------------------------------(fold)
\hypersetup{
bookmarks=true, % show bookmarks bar?
unicode=true, % non-Latin characters in Acrobat’s bookmarks
pdftoolbar=true, % show Acrobat’s toolbar?
pdfmenubar=true, % show Acrobat’s menu?
pdffitwindow=false, % window fit to page when opened
pdfstartview={FitH}, % fits the width of the page to the window
pdftitle={\ptitle}, % title
pdfauthor={\pauthor}, % author
pdfcreator={XelaTeX}, % creator of the document
pdfproducer={\pauthor}, % producer of the document
pdfnewwindow=false, % links in new window
colorlinks=true, % false: boxed links; true: colored links
linkcolor=BrickRed, % color of internal links
citecolor=OliveGreen, % color of links to bibliography
filecolor=magenta, % color of file links
urlcolor=BlueViolet % color of external links
}
% -------------------------------------------------------------------(end)
%-- Fancy Header ---------------------------------------------------(fold)
\pagestyle{fancy}
%\renewcommand{\chaptermark}[1]{\markboth{#1}{}}
\renewcommand{\sectionmark}[1]{\markright{\thesection\ #1}}
\fancyhf{} % delete current header and footer
\fancyhead[LE,RO]{\bfseries\thepage}
\fancyhead[LO]{\bfseries\rightmark}
\fancyhead[RE]{\bfseries\leftmark}
\renewcommand{\headrulewidth}{0.5pt}
\renewcommand{\footrulewidth}{0pt}
\addtolength{\headheight}{0.5pt} % space for the rule
\fancypagestyle{plain}{
\fancyhead{} % get rid of headers on plain pages
\renewcommand{\headrulewidth}{0pt} % and the line
}
% -------------------------------------------------------------------(end)
\begin{document}
\maketitle
\begin{latin}
Latin
\end{latin}
\begin{persian}
فارسی
\end{persian}
% == Document ============================================
\بخش{آشنایی}
\بخش{دوستی}
\end{document}