I am using rmarkdown and I want the Country "Afghanistan" to become HUGE, Center and in Oswald Regular I tried \Centering\Huge but I failed.
---
documentclass: report
classoption: twoside
fontsize: 12pt
output:
pdf_document:
latex_engine: xelatex
keep_tex: true
keep_tex: true
header-includes: |
\usepackage{geometry}
\geometry{a4paper,asymmetric,
top=3.5cm,left=2cm,right=2cm,bottom=1cm,
headsep=0pt,footskip=0pt,
headheight=200pt}
\usepackage{fontspec}
\setmainfont{Roboto-Regular}[Extension = .ttf,BoldFont = Roboto-Bold,ItalicFont = Roboto-LightItalic,BoldItalicFont = Roboto-BoldItalic]
\newfontfamily\oswaldfont{Oswald Regular}
---
\noindent
\oswaldfont{Afghanistan} \newline
\bigskip
\begin{minipage}[t]{0.4\linewidth}
minipage1
\end{minipage}
\hfill
\begin{minipage}[t]{0.4\linewidth}
minipage2
\end{minipage}
The gambia
\centering
, not\Centering
. To prevent everything that follows from being centered and\Huge
, enclose the commands in a group:\begingroup\centering\Huge\oswaldfont{Afghanistan}\par\endgroup
– erik Dec 17 '20 at 19:09