LaTeX forum ⇒ Text Formatting ⇒ Add a line above/below the section title

Information and discussion about LaTeX's general text formatting features (e.g. bold, italic, enumerations, ...)
jjmm
Posts: 11
Joined: Tue Jul 12, 2016 5:23 am

Add a line above/below the section title

Hi,

(1) I manage to add a line above and below the title. I modify some codes I search from the web, and I can only add a line below the title, but I do not know how to add a line above the section title. Could someone show me how to do it?
(2) Another thing I would like to do is to add a dot after the section number, e.g., I would like "3. The application of ......", but I have "3 The application of ......" Thanks!

The core codes are as follows:

\usepackage[explicit]{titlesec}\definecolor{Blue}{rgb}{0,0,0.8}.......\titleformat{\section}{\normalfont\large\bfseries\color{Blue}}{\titlerule\vspace{1pc}\thesection}{1em}{#1}[{\titlerule[0.8pt]}]

Complete codes:


Tags:

cgnieder
Site Moderator
Posts: 1988
Joined: Sat Apr 16, 2011 7:27 pm
Clemens
------------------------------
chemmacros · chemformula · leadsheets · xsim