Document Classes"Scene change" within a chapter

Information and discussion about specific document classes and how to create your own document classes.
Post Reply
dr8086
Posts: 4
Joined: Thu May 03, 2012 2:39 pm

"Scene change" within a chapter

Post by dr8086 »

Hello all!

I'm using LaTeX to compile a book into a lovely pdf.
Within chapters I sometimes have scene changes, like a break in the action or a change of . What I see in books I've read is basically a large vertical space with some small character like an asterisk in the middle. I'll try to recreate the effect I'm after below.

Code: Select all

text text text text text text text text text text 
text text text text text text text text text text 



                       *


text text text text text text text text text text 
text text text text text text text text text text 
I've tried using the \section command, but this isn't really what I'm looking for.
I could probably recreate the effect using a combination of commands for other purposes, but if there's a proper LaTeX way to do it I'm sure it would look much better.
Many thanks all!
Last edited by Stefan Kottwitz on Fri Aug 10, 2012 4:26 pm, edited 1 time in total.

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

And: Currently, Packt sells ebooks for $4.99 each if you buy 5 of their over 1000 ebooks. If you choose only a single one, $9.99. How about combining 3 LaTeX books with Python, gnuplot, mathplotlib, Matlab, ChatGPT or other AI books? Epub and PDF. Bundle (3 books, add more for higher discount): https://packt.link/MDH5p

Stefan Kottwitz
Site Admin
Posts: 10335
Joined: Mon Mar 10, 2008 9:44 pm

"Scene change" within a chapter

Post by Stefan Kottwitz »

The proper LaTeX way, besides using a dedicated package if existing, is to define a macro for this. You can change the macro any time you want, and the whole document will be updated.

Here, you could use \hfill before and after the symbol, so it would be centered. You could add paragraph breaks and vertical space, if you like.

Code: Select all

\documentclass{article}
\usepackage{lipsum}
\usepackage{pifont}
\newcommand{\decoline}{%
  \par
  \vspace{\baselineskip}
  \hfill
  \ding{100}
  \hfill
  \vspace{\baselineskip}
\par}
\begin{document}
\lipsum[1]
\decoline
\lipsum[2]
\decoline
\lipsum[3]
\end{document}
decorations.png
decorations.png (48.42 KiB) Viewed 5482 times
There are packages and fonts with nice decorations, if you don't want to use just \star or \ast or a \ding symbol.

Stefan
LaTeX.org admin
User avatar
nlct
Posts: 276
Joined: Thu Nov 06, 2008 11:15 am

"Scene change" within a chapter

Post by nlct »

I don't know what class you are using, but memoir provides some commands to do this. The most convenient is \pfbreak which just puts a gap if the scene break occurs in the middle of the page, but puts a symbol (such as an asterisk) if the scene break occurs near the page boundary (where it's harder to see). The symbol and the size of the gap can be customized if the default doesn't suit you.

Regards
Nicola Talbot
dr8086
Posts: 4
Joined: Thu May 03, 2012 2:39 pm

Re: "Scene change" within a chapter

Post by dr8086 »

Apologies for the late reply.
Defining the Macro worked great, many thanks!
I'm using the book class, which I think I shall stick with rather than switching to memoir.
Cheers
Post Reply