Re: consigli sull’uso di Titlesec

#16103
DMW
    Up
    0
    Down
    ::


    Ho fatto alcune prove e questo codice non è ottimale,
    `
    \titleformat{\chapter}[block]
    {\huge}
    {\hfill\oldstylenums{\thechapter}.}
    {3ex}
    {\huge}
    [\vspace{.7ex}{\titleline[r]{\rule{.75\textwidth}{.4pt}}}]
    \titlespacing{\chapter}{0pt}{40pt}{40pt}
    `

    Infatti provate a mettere l’indice o un capitolo senza numero.

    Invece così, a mio avviso, è un po’ meglio:
    `
    \titleformat{\chapter}[block]
    {\huge}
    {\oldstylenums{\thechapter}.}
    {3ex}
    {\huge\filleft}
    [\vspace{.7ex}{\titleline[r]{\rule{.75\textwidth}{.4pt}}}]
    \titlespacing{\chapter}{0pt}{40pt}{40pt}
    `

    Ciao

    Andrea

    Go to top