I want to remove the justification of titles: I would like the titles (here the \section*{}) to be left aligned. Note that I'm using titletoc,
hyperref and preview.
MWE
\documentclass[a4paper, 12pt]{article}
\usepackage[utf8]{inputenc}
\usepackage[francais]{babel}
% Layout pour l'aide
\usepackage[top=1cm, bottom=3cm, left=1cm, right=1cm, paperwidth= 15cm]{geometry}
\usepackage[active,tightpage, noconfig]{preview}
\renewcommand{\PreviewBbAdjust}{-1cm -3cm 1cm 1cm}
% Table of contents
\usepackage{hyperref}
\hypersetup{
colorlinks,
citecolor=blue,
filecolor=blue,
linkcolor=blue,
urlcolor=blue
}
% http://tex.stackexchange.com/a/9290/8323
\let\Contentsline\contentsline
\renewcommand\contentsline[3]{\Contentsline{#1}{#2}{}}
\usepackage{titletoc}
%
\titlecontents{section}[0em]{\smallskip}%
{\large \bfseries \thecontentslabel}%numbered
{}%numberless
{}[\smallskip]%
% Main command
\newcommand{\titre}[1]{\vspace{2cm}\section{#1}
\addcontentsline{toc}{section}{\protect\numberline{}#1}}
\begin{document}
\begin{preview}
\tableofcontents
\titre{Fonctions et notations mathématiques usuelles}
\end{preview}
\end{document}

\raggedright, but how you do it depends on the document class, which you haven't identified. – barbara beeton Dec 08 '16 at 16:25article. Where should I put\raggedright? – Colas Dec 08 '16 at 16:25\documentclassand end with\end{document}. – Werner Dec 08 '16 at 16:32titletoc. here's a potentially duplicate question: titletoc: section titles ragged right – barbara beeton Dec 08 '16 at 16:41