2.12: Text Wrapping in This Book

Making Games with Python and Pygame · LibreTexts

0%

Contents

    Text

    Size
    100%
    Theme
    Typeface
    Line length
    Spacing

    From LibreTexts, under CC BY-NC-SA 3.0, as the source states it; its equations are written in TeX, which the PDF shows typeset. This page at LibreTexts.

    2.12: Text Wrapping in This Book

    Some lines of code are too long to fit on one line on the pages in this book, and the text of the code will wrap around to the next line. When you type these lines into the file editor, enter the code all on one line without pressing Enter.

    You can tell when a new line starts by looking at the line numbers on the left side of the code. For example, the code below has only two lines of code, even though the first line wraps around:

    1. print('This is the first line! xxxxxxxxxxxxxxxxxxxxxxxxxxxxx
    xxxxxxxxxxxxxx’)
    2. print('This is the second line, not the third line.') 
    

    This page titled 2.12: Text Wrapping in This Book was last modified on Sun, 27 Oct 2019 23:54:55 GMT and is shared under a CC BY-NC-SA 3.0 license and was authored, remixed, and/or curated by Al Sweigart via source content that was edited to the style and standards of the LibreTexts platform.