diff --git a/Assets/Font/times.ttf b/Assets/Font/times.ttf new file mode 100644 index 0000000..53ccf4c Binary files /dev/null and b/Assets/Font/times.ttf differ diff --git a/Assets/Font/timesbd.ttf b/Assets/Font/timesbd.ttf new file mode 100644 index 0000000..3f2987f Binary files /dev/null and b/Assets/Font/timesbd.ttf differ diff --git a/Assets/Font/timesbi.ttf b/Assets/Font/timesbi.ttf new file mode 100644 index 0000000..3f383fb Binary files /dev/null and b/Assets/Font/timesbi.ttf differ diff --git a/Assets/Font/timesi.ttf b/Assets/Font/timesi.ttf new file mode 100644 index 0000000..565a02e Binary files /dev/null and b/Assets/Font/timesi.ttf differ diff --git a/Config/00_config.tex b/Config/00_config.tex index 32b1ab6..0163312 100644 --- a/Config/00_config.tex +++ b/Config/00_config.tex @@ -8,7 +8,7 @@ \newcommand{\DocTitle}{عنوان اصلی و کامل برای مستندات پروژه} \newcommand{\DocHeaderTitle}{عنوان کوتاه مستند} \newcommand{\DocSubtitle}{توضیحات کوتاه یا زیرعنوان مستند} -\newcommand{\DocVersion}{1.0.3} +\newcommand{\DocVersion}{2.0.0} \newcommand{\DocID}{\lr{[DOC-PRJ-01]}} \newcommand{\DocDate}{\today} % می‌توانید تاریخ دستی بنویسید مثل: 1403/08/02 diff --git a/System/team_template.sty b/System/team_template.sty index d28a720..7a48bee 100644 --- a/System/team_template.sty +++ b/System/team_template.sty @@ -54,8 +54,8 @@ % --- Main Text Font --- \settextfont[Path=Assets/Font/, Extension=.ttf, BoldFont=BNazanin-Bold]{BNazanin} -% --- Fix English Text --- -\setlatintextfont{Times New Roman} % You can also use Arial or Calibri +% --- Fix English Text (Local Font Bypass) --- +\setlatintextfont[Path=Assets/Font/, Extension=.ttf, BoldFont=timesbd, ItalicFont=timesi, BoldItalicFont=timesbi]{times} % --- Custom Font Definitions --- \defpersianfont\vazirfont[Path=Assets/Font/, Extension=.ttf, BoldFont=Vazirmatn-Bold]{Vazirmatn-Regular} @@ -190,21 +190,16 @@ % Using \AtBeginDocument ensures these headers can read variables (like \DocVersion) defined in main.tex \AtBeginDocument{ - \fancyhead[LO]{% - \hspace{1.8cm}% - \llap{\smash{\raisebox{-0.75cm}{\includegraphics[height=1.2cm]{logo.png}}}\hspace{0.3cm}} - \textcolor{primary}{\nazaninfont\textbf{\DocHeaderTitle}} - } - \fancyhead[RE]{% - \textcolor{primary}{\nazaninfont\textbf{\DocHeaderTitle}} - \rlap{\hspace{0.3cm}\smash{\raisebox{-0.75cm}{\includegraphics[height=1.2cm]{logo.png}}}} - \hspace{1.8cm}% - } - \fancyhead[RO]{\textcolor{gray}{نسخه \lr{\DocVersion}}} - \fancyhead[LE]{\textcolor{gray}{نسخه \lr{\DocVersion}}} + % Clear all default headers to prevent ghosting + \fancyhead[LO]{} + \fancyhead[RE]{} + \fancyhead[RO]{} + \fancyhead[LE]{} + \fancyfoot[C]{\textcolor{gray}{صفحه \thepage}} \fancyhead[C]{% + % 1. Draw the Background Shapes \ifModernShapes \pgfmathtruncatemacro{\pagecycle}{mod(int((\value{page}-1)/2), 2)} \ifnum\pagecycle=0 @@ -213,6 +208,25 @@ \ifodd\value{page} \OddPageShapesB \else \EvenPageShapesB \fi \fi \fi + + % 2. Draw the Text and Logo securely tied to the physical margins + \ifodd\value{page}% + % ODD PAGE: Shapes are on the RIGHT. Gap is on the RIGHT (1.8cm). + \makebox[\headwidth][s]{% + {\makebox[1.8cm][c]{\smash{\raisebox{-0.75cm}{\includegraphics[height=1.2cm]{logo.png}}}}% + \textcolor{primary}{\nazaninfont\textbf{\DocHeaderTitle}}}% + \hfill + {\textcolor{gray}{نسخه \lr{\DocVersion}}}% + }% + \else + % EVEN PAGE: Shapes are on the LEFT. Gap is on the LEFT (1.8cm). + \makebox[\headwidth][s]{% + {\textcolor{gray}{نسخه \lr{\DocVersion}}}% + \hfill + {\textcolor{primary}{\nazaninfont\textbf{\DocHeaderTitle}}% + \makebox[1.8cm][c]{\smash{\raisebox{-0.75cm}{\includegraphics[height=1.2cm]{logo.png}}}}}% + }% + \fi } }