kopia lustrzana https://github.com/pimoroni/pimoroni-pico
Added clip image to MicroPython pico_display docs
Updated the text and added clip.jpg to the MicroPython Pico Display docs to help communicate the use of clips.pull/32/head
rodzic
7192dbcb4c
commit
b59b3d2d9e
|
@ -176,12 +176,14 @@ picodisplay.text(string,x,y,wrap, scale)
|
|||
|
||||
### set_clip
|
||||
|
||||
This function defines a rectangular area outside which no drawing actions will take effect. If a drawing action crosses the boundary of the clip then only the pixels inside the clip will be drawn. Note that `clip` does not remove pixels which have already been drawn, it only prevents new pixels being drawn outside the described area. Only one clip can be active at a time, and defining a new clip replaces any previous clips. The `x` and `y` parameters describe the upper-left corner of the clip area, `w` and `h` describe the width and height in pixels.
|
||||
This function defines a rectangular area outside which no drawing actions will take effect. If a drawing action crosses the boundary of the clip then only the pixels inside the clip will be drawn. Note that `clip` does not remove pixels which have already been drawn, it only prevents new pixels being drawn outside the described area. A more visual description of the function of clips can be found below. Only one clip can be active at a time, and defining a new clip replaces any previous clips. The `x` and `y` parameters describe the upper-left corner of the clip area, `w` and `h` describe the width and height in pixels.
|
||||
|
||||
```python
|
||||
picodisplay.set_clip(x,y,w,h)
|
||||
```
|
||||
|
||||
![A diagram explaining clips](/micropython/modules/pico_display/clip.jpg)
|
||||
|
||||
### remove_clip
|
||||
|
||||
This function removes any currently implemented clip.
|
||||
|
|
Ładowanie…
Reference in New Issue