SetMargins(left, right[, noclip])
left
argument specifies the left end
of the margin and the right
argument is the right end of the
margin. Words exceeding those margins will automatically be
wrapped to the next line.
The default setting for left
is 0 and for right
the default
setting is your display width minus 1.
By default, the margins you specify in left
and right
will
be clipped against the display's boundaries. If you don't
want that, you can set the optional noclip
argument to True
.
If noclip
is True
, left
can also be less than 0 and right
can be greater than the display width.
True
if left and right edges
of the margin shouldn't be clipped to the display's boundaries (V9.0)SetMargins(200, 300) Print("Hello World. This is my first program using margins.")The above code defines the margins 200 and 300, which means that text output will only be made between pixels 200 and 300. Then it prints some text.