I'm trying to set linespread independent of my content. But I don't know how.
I need single space between Professor 1 & Professor 2
Here is MWE.
\documentclass[a4paper,12pt]{report}
\usepackage{geometry}
\geometry{margin=2.5cm}
\usepackage{kantlipsum}
\linespread{1.2}
%-------------Title Chap & Section------------------------
\usepackage{titlesec}
\titleformat{\section}[block]{\filleft\bfseries\Large}{\thesection.}{0.5em}{}
\titleformat{\subsection}[block]{\filleft\bfseries\large}{\thesection.}{0.5em}{}
\titleformat{\subsubsection}[block]{\filleft\bfseries\large}{\thesection.}{0.5em}{}
\titleformat
{\chapter} % command
[display] % shape
{\Huge\bfseries\raggedleft} % format
{} % label
{22pt} % separation between label and chapter-title
{\Huge}[\vspace{1ex}] % before-code
\titleformat
{\section} % command
[display] % shape
{\Huge\bfseries\raggedleft} % format
{} % label
{25pt} % separation between label and chapter-title
{\Huge}[\vspace{2ex}] % before-code
% \titleformat{\section}{\bfseries\Large\raggedleft}{}{0.5em}{}
\titleformat{\subsection}{\bfseries\normalsize\raggedleft}{}{0.5em}{}
\titleformat{\subsubsection}{\bfseries\normalsize\raggedleft}{}{0.5em}{}
\titlespacing*{\chapter}{0pt}{\baselineskip}{\baselineskip}
\titlespacing*{\section}{0pt}{4ex}{1ex}
\titlespacing*{\subsection}{0pt}{0pt}{1ex}
\titlespacing*{\subsubsection}{0pt}{0pt}{6ex}
\newcommand{\autor}[1]{\textbf{\Large {#1}}\medskip\par}
\newcommand{\scoala}[1]{\textit{\normalsize{#1}}\medskip\par}
\newcommand{\prof}[1]{\textit{\small prof. coord. {#1}}\\ \smallskip}
\begin{document}
\chapter{Chapter 1}
\begin{flushright}
\autor{Author 1}
\scoala{Name of School}
\prof{Professor 1}
\prof{Professor 2}
\end{flushright}
\kant[1]
\end{document}
Best Answer
I suggest to modify the
\prof
command to accept a full list of names separated by\\
.The code for the document would be
You might prefer a key-value approach, that has the advantage of not requiring a particular order in which the keys are given; however the order in which multiple
prof
keys appear will be respected.You'd get the same output with
or variations thereon.