Dev Prakash Sharma has Published 556 Articles

Creating a LabelFrame inside a Tkinter Canvas

Dev Prakash Sharma

Dev Prakash Sharma

Updated on 16-Dec-2021 10:54:10

1K+ Views

Tkinter provides many built-in widgets which can be used to create highlevel desktop applications. The LabelFrame widget is one of them, which allows the users to add a labelled frame. The Label is another widget in the LabelFrame, which is used to add text or images in a frame or ... Read More

How to get a new API response in a Tkinter textbox?

Dev Prakash Sharma

Dev Prakash Sharma

Updated on 16-Dec-2021 10:52:25

836 Views

APIs are extremely useful in implementing a service or feature in an application. APIs help to establish the connection between the server and a client, so whenever a client sends a request using one of the API methods to the server, the server responds with a status code (201 as ... Read More

Adding coloured text to selected text in Tkinter

Dev Prakash Sharma

Dev Prakash Sharma

Updated on 16-Dec-2021 10:42:46

927 Views

If we want to implement a text editor in an application that can accept multiline user input, then we can use the Tkinter Text widget. The Text widget in Tkinter is generally used to create a text editor for an application, where we can write text and perform operations like ... Read More

How to set a certain number of rows and columns of a Tkinter grid?

Dev Prakash Sharma

Dev Prakash Sharma

Updated on 16-Dec-2021 10:41:34

3K+ Views

In Tkinter, you can set the GUI of the application by using a different geometry manager. The grid geometry manager is one of the most useful geometry managers in tkinter that is used to set the widgets location in the application using the 2D geometry form.With a grid geometry manager, ... Read More

Drawing a line between two mouse clicks using tkinter

Dev Prakash Sharma

Dev Prakash Sharma

Updated on 11-Oct-2021 07:45:01

892 Views

Consider a case for creating a GUI application such that when we click on the window with a mouse button, it stores the coordinates and creates a line between two given points. Tkinter provides events that allow the user to bind the keys or buttons with the functions.To draw a ... Read More

Initialize a window as maximized in Tkinter Python

Dev Prakash Sharma

Dev Prakash Sharma

Updated on 08-Oct-2021 13:03:25

6K+ Views

Tkinter creates a default window with its default size while initializing the application. We can customize the geometry of the window using the geometry method.However, in order to maximize the window, we can use the state() method which can be used for scaling the tkinter window. It maximizes the window ... Read More

Creating Tkinter full-screen application

Dev Prakash Sharma

Dev Prakash Sharma

Updated on 08-Oct-2021 13:01:26

792 Views

Tkinter initially creates a window that contains application components such as widgets and control bars. We can switch a native-looking application to a full-screen application by using the attribute(‘-fullscreen’, True) method. To make the window full-screen, just invoke the method with the particular window.Example# Import tkinter library from tkinter import ... Read More

Get contents of a Tkinter Entry widget

Dev Prakash Sharma

Dev Prakash Sharma

Updated on 20-Aug-2021 16:25:39

3K+ Views

An Entry widget is a basic one-line character widget that supports only single-line text input. An Entry widget can be defined by initializing the Entry(parent, width) constructor.To validate the Entry widget, we can use the get() method which results in the character entered in the Entry widget.Let us define an Entry ... Read More

Save File Dialog Box in Tkinter

Dev Prakash Sharma

Dev Prakash Sharma

Updated on 20-Aug-2021 16:20:01

10K+ Views

We often use Open and Save Dialog. They are common across many applications and we already know how these dialogs work and behave. For instance, if we click on open, it will open a dialog to traverse the location of the file. Similarly, we have the Save Dialog.We can create ... Read More

How to change the size of text on a label in Tkinter?

Dev Prakash Sharma

Dev Prakash Sharma

Updated on 06-Aug-2021 07:49:05

20K+ Views

The label widget in Tkinter is used to display text and images in a Tkinter application. In order to change the properties of the label widget such as its font-property, color, background color, foreground color, etc., you can use the configure() method.If you want to change the size of the ... Read More

Previous 1 ... 4 5 6 7 8 ... 56 Next
Advertisements