adafruit / Adafruit_CircuitPython_CharLCD

Library code for character LCD interfacing
MIT License
69 stars 50 forks source link

cursor_position fix, add column check #20

Closed kattni closed 5 years ago

kattni commented 5 years ago

If you set the coordinate column or line in cursor_position to the same number as the number of columns or lines in the initialisation of the display, it would move the cursor off of the display. This fixes that issue.

Also added a check to keep the cursor on the screen if the number provides for the column coordinate is outside the number of columns.