Adventures in Python by Craig Richardson
Author:Craig Richardson
Language: eng
Format: epub, pdf
ISBN: 9781118951842
Publisher: Wiley
Published: 2015-01-23T09:59:13+00:00
Below the line that begins with canvas = tk.Canvas add the following line of code to create the text box: hexText = tk.Entry(window)
Find this line of code in your program: window.mainloop()
Above it, add this line of Python code to add the text box to the window using the grid system: hexText.grid(row=3, column=1, columnspan=3)
Save the program and run it using Run⇒Run Module.
You should notice that the window now has an additional text box at the bottom. Try moving the sliders and you will notice that the value in the text box changes. This value will be the same as the colour used for the background of the canvas.
Figure 4-5 shows the program with the added text box.
FIGURE 4-5 The colour picker with the text box
Download
This site does not store any files on its server. We only index and link to content provided by other sites. Please contact the content providers to delete copyright contents if any and email us, we'll remove relevant links or contents immediately.
Linux Device Driver Development Cookbook by Rodolfo Giometti(3935)
Embedded Programming with Modern C++ Cookbook by Igor Viarheichyk(3635)
Implementing Cellular IoT Solutions for Digital Transformation by Dennis McCain(3570)
Embedded Linux Development Using Yocto Project - Third Edition by Otavio Salvador & Daiane Angolini(3409)
TinyML Cookbook by Gian Marco Iodice(3338)
Simplifying 3D Printing with OpenSCAD by Colin Dow(2843)
TinyML Cookbook by Gian Marco Iodice & Ronan Naughton(2606)
Fusion 360 for Makers by Lydia Sloan Cline(2222)
Networking A Beginner's Guide by Bruce Hallberg(2210)
Hands-On Linux for Architects by Denis Salamanca(2053)
But How Do It Know? by J. Clark Scott(2033)
Computers For Seniors For Dummies by Nancy C. Muir(2003)
Raspberry Pi and MQTT Essentials by Dhairya Parikh(1954)
Arduino Project Handbook, Volume 2: 25 Simple Electronics Projects for Beginners by Geddes Mark(1952)
9781803246888-ENHANCING DEEP LEARNING WITH BAYESIAN INFERENCE by Unknown(1902)
Hack and HHVM by Owen Yamauchi(1884)
31 Days Before Your CompTIA A+ Exams (Shanette Luellen's Library) by Benjamin Patrick Conry(1863)
MicroPython Projects by Jacob Beningo(1741)
Hands-On Internet of Things with MQTT by Tim Pulver(1713)
