allow all single-length charactors
This commit is contained in:
parent
795dbad1b1
commit
366a5f96cc
1 changed files with 1 additions and 2 deletions
3
nboard
3
nboard
|
@ -5,7 +5,6 @@ import curses,time,json,sys
|
||||||
|
|
||||||
dataPath = '/home/lickthecheese/nboard/nboard.json'
|
dataPath = '/home/lickthecheese/nboard/nboard.json'
|
||||||
|
|
||||||
allowedChars = "█▒░ `~1234567890-=!@#$%^&*()_+qwertyuiop[]\\QWERTYUIOP{}|asdfghjkl;'ASDFGHJKL:\"zxcvbnm,./ZXCVBNM<>?"
|
|
||||||
data = {}
|
data = {}
|
||||||
|
|
||||||
def main(stdscr):
|
def main(stdscr):
|
||||||
|
@ -64,7 +63,7 @@ def main(stdscr):
|
||||||
data = json.load(openfile)
|
data = json.load(openfile)
|
||||||
|
|
||||||
# if valid key pressed, write it
|
# if valid key pressed, write it
|
||||||
if k in allowedChars:
|
if len(k) == 1:
|
||||||
data[str((ty,tx))] = k
|
data[str((ty,tx))] = k
|
||||||
vx = vx+1
|
vx = vx+1
|
||||||
with open(dataPath, 'w') as outfile:
|
with open(dataPath, 'w') as outfile:
|
||||||
|
|
Loading…
Reference in a new issue