Introduction to Programming using Python 1st Edition

Published by Pearson
ISBN 10: 0132747189
ISBN 13: 978-0-13274-718-9

Chapter 9 - GUI Programming using Tkinter - Section 9.6 - The Geometry Managers - Check Point - MyProgrammingLab - Page 286: 9.24

Answer

Here is a sample code to display the values defined in the named constants X, Y, BOTH, S, N, E, W, NW, NE, SW, and SE in the Tkinter module: (Provided code in step-by-step procedure)

Work Step by Step

import tkinter as tk print("X:", tk.X) print("Y:", tk.Y) print("BOTH:", tk.BOTH) print("S:", tk.S) print("N:", tk.N) print("E:", tk.E) print("W:", tk.W) print("NW:", tk.NW) print("NE:", tk.NE) print("SW:", tk.SW) print("SE:", tk.SE) These named constants are used to specify the direction or orientation of various elements in a Tkinter GUI, such as the direction in which a widget should expand when using the pack manager, or the orientation of text in a label. The specific values of these constants may vary depending on the implementation of Tkinter.
Update this answer!

You can help us out by revising, improving and updating this answer.

Update this answer

After you claim an answer you’ll have 24 hours to send in a draft. An editor will review the submission and either publish your submission or provide feedback.