XeLaTeX: Arial small caps

arialoverleafsmall-caps

I'm searching for the way to use \textsc and \scshape when I compile with XeLaTeX my document and I set Arial font.

\usepackage[T1]{fontenc}\usepackage{fontspec}\setmainfont{Arial}

I am using Overleaf.

Best Answer

You provided no example showing your problem, it should just work with no additional definitions.

enter image description here

\documentclass{article}

\usepackage{fontspec}
\setmainfont{Arial}

\begin{document}

Abc \textsc{Abc}

\end{document}

Note That this assumes a full modern Arial as distributed with Windows. The Arial available in linux (including Overleaf) is an older version with fewer variants. However you can use the TeX Gyre Helvetica clone.

enter image description here

\documentclass{article}
 \usepackage{fontspec} \setmainfont{TeX Gyre Heros}
 \title{Example} \author{Francesco Contini}
\date{December 2021}
\begin{document}
\maketitle 
\section{Introduction} This is an \textsc{example}.
\end{document}


\documentclass{article}

\usepackage{fontspec}
\setmainfont{Arial}

\begin{document}

Abc \textsc{Abc}

\end{document}
Related Question