Tkinter Text style & to read input & display text on click event of button by get() & set() methods

preview_player
Показать описание

To take any user input or to display data for Edit we have to use Text input boxes in our Tkinter window. This is a multiline text input widget, for single line entry we can use Entry widget only.
Managing Style

Reading and Updating data of the Text box
We can place one text box and one button on the window. On click of the button one fixed string saying welcome will be displayed on the text box. For this the lambda of the button is used to call a function my_upd(). Inside the function my_upd() we kept one line of code.
This will add the string Welcome to text box object t2.
We can modify the script and take user input in t1 text box and then pass the same data to t2 text box on button click. After passing the data we can delete the text ( data ) entered by user in t1 text box. The code inside the function my_upd() will change.
The first line will read the data entered by user and add it to t2 text box. Second line will delete the data from first text box t1.
Рекомендации по теме
Комментарии
Автор

Can you please tell me, How to print terminal outputs in second text box?

dmt_s
Автор

Can you please change your voice by the voice changer I don't understand you well and subtitles are weird.

gamertronky