Apple Event: May 7th at 7 am PT

Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

line numbering in pages

How can I add line numbering to Pages documents as one can do in Word/Microsoft?


Posted on Jun 30, 2019 11:03 AM

Reply
Question marked as Best reply

Posted on Jul 1, 2019 12:30 PM

Here is a Pages v8.1 finished example of what Barry referred too. Normal text body, with an elongated text box just outside of the body text border. The text box has its Layout Tab : Text Inset set to 0 pt, before pasting the sequence of right-justifed numbers into it. With the Text box selected, and from the Arrange tab, set Text Wrap to None.


Both the body text and text box, in the example, are set to 16 pt Baskerville Regular, and Spacing Exactly at 19 pt (which is a line height of 1.2, based on that 16 pt body text.


In the Terminal application, I put (in this example) 32 right justified numbers onto the clipboard with the number field being 5 digits.


seq -f "%5g" 1 32 | pbcopy


In the Text box, you would use Paste and Match Style when inserting the sequential numbers. If the Text box is too narrow, it will appear as though some lines are blank, and you only need to widen the Text box to alleviate that. I have left the Pages View menu : Show Layout enabled as a visual aid.



When you export to Word .docx, the line numbers will not appear in Preview, but are preserved in LibreOffice Writer 6.2.4 with essentially the same alignment as in Pages v8.1. The line numbers are preserved when exporting to PDF too.


This is labor intensive so consider making a custom Pages template with the Text box and line numbers already in place.

4 replies
Question marked as Best reply

Jul 1, 2019 12:30 PM in response to lilia294

Here is a Pages v8.1 finished example of what Barry referred too. Normal text body, with an elongated text box just outside of the body text border. The text box has its Layout Tab : Text Inset set to 0 pt, before pasting the sequence of right-justifed numbers into it. With the Text box selected, and from the Arrange tab, set Text Wrap to None.


Both the body text and text box, in the example, are set to 16 pt Baskerville Regular, and Spacing Exactly at 19 pt (which is a line height of 1.2, based on that 16 pt body text.


In the Terminal application, I put (in this example) 32 right justified numbers onto the clipboard with the number field being 5 digits.


seq -f "%5g" 1 32 | pbcopy


In the Text box, you would use Paste and Match Style when inserting the sequential numbers. If the Text box is too narrow, it will appear as though some lines are blank, and you only need to widen the Text box to alleviate that. I have left the Pages View menu : Show Layout enabled as a visual aid.



When you export to Word .docx, the line numbers will not appear in Preview, but are preserved in LibreOffice Writer 6.2.4 with essentially the same alignment as in Pages v8.1. The line numbers are preserved when exporting to PDF too.


This is labor intensive so consider making a custom Pages template with the Text box and line numbers already in place.

line numbering in pages

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple ID.