2

I'm writing using \article class and I want to make every section of it centered and small caps with no bold. I use sectstypackage for this.

I tried it this way

\documentclass{article}
\usepackage{amssymb,amsmath,sectsty, blindtext}

\title{\scshape This Is The Title\\\large and this is another text}
\author{Azlif}
\date{Somewhere in 2018}
\sectionfont{\centering \scshape\normalfont} 
\renewcommand{\abstractname}{Abstrak}
\begin{document}
\maketitle
\begin{abstract}
This paper only contains blind text
\end{abstract}
\section{I Hope I can Be a Small Caps Someday}
\blind text
\section{Other Section}
\section{Yet Another Section}
\end{document}

I also try adding \usepackage[sc]{titlesec}. It works but then the section heading is not centered.

  • 1
    If you stare long enough at \scshape\normalfont perhaps you can find the solution your self. Hint: what does \normalfont do? Hint2: try changing the order. Also probably a good idea to add \usepackage[T1]{fontenc} – daleif Jan 10 '18 at 14:25
  • Oh gosh. It works perfectly. I should've just put that \normalfont at the front. – Azlif Jan 10 '18 at 14:26
4

It is a fairly simple human error. \normalfont resets the font settings, so \scshape\normalfont is the same as just \normalfont.

Try \normalfont\scshape.

1

With titlesec, just add to your preamble

\titleformat*{\filcenter\scshape}

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.