Comments (4)
guizero simply returns what was is given to it by tkinter (the underlying GUI framework). If tkinter doesnt return these characters then there probably isnt a lot which can be done.
https://github.com/lawsie/guizero/blob/master/guizero/event.py#L33
The event object return also includes the underlying tk_event object which you may be able to interrogate to get at the non-printing characters. e.g.
def enterKeyClicked(event):
print("tk event object", event.tk_event)
app = App()
textbox = TextBox(app)
textbox.when_key_pressed = enterKeyClicked
app.display()
from guizero.
You can get the keycode from the tk_event
which includes non-printing charactors.
from guizero import App, TextBox
def enterKeyClicked(event):
print("keycode:" + str(event.tk_event.keycode))
app = App()
textbox = TextBox(app)
textbox.when_key_pressed = enterKeyClicked
app.display()
Suggest we add tk_event.keycode
to the guizero event object at some point. Its a minor change to the event.EventData
object.
from guizero.
Now in dev
from guizero.
Released in v1.4.0
from guizero.
Related Issues (20)
- Bug report - Documentation Fix HOT 3
- Bug report in documentation - Widgets - Window - Creating a Window object HOT 1
- Request to have SVG image support. HOT 2
- Slider 'end' starting parameters. HOT 4
- Mention App().tk.geometry() Functionality HOT 2
- guizero title font (not titlebox) HOT 12
- when_mouse_leaves does not seem to be detected correctly HOT 6
- Image resizing - cannot scale the image as PIL is not available HOT 4
- Gradually Increases Memory HOT 11
- Widgets can be given a tab order
- Color control - TextBox Background and Pushbutton HOT 1
- Destroying a container could destroy the widgets contained inside it. HOT 3
- Guizero animation importing picture into a moving oval HOT 2
- Scrollable boxes (really a box inside a scrollable canvas)
- Create right-click context menu for copy-paste with app.add_tk_widget HOT 1
- MCP3008 HOT 4
- Pillow.Image.ANTIALIAS is deprecated and will be removed HOT 1
- #Recursive call dont work in Guizero_Auto_Update HOT 6
- TextBox command HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from guizero.