I
I
I3EKTOP2019-03-01 02:38:49
Python
I3EKTOP, 2019-03-01 02:38:49

How to make a textbox toggle in PyQt5?

Good afternoon everyone! I need to combine a radio button switcher and multi-line text fields, so that it would be possible to select only one text field from the proposed ones and use it in the future. Is it possible to do this in PyQt5? Prokhorenko has a section separately about radio buttons, separately about text fields, I didn’t find any information in Google, thank you very much in advance for your answer!

Answer the question

In order to leave comments, you need to log in

1 answer(s)
S
saw_tooth, 2019-05-02
@saw_tooth

QStackedWidget to the rescue.
You create the necessary widgets with QTextEdits, add them to the above class, and, based on events on QRadioButtons, set the index of the widget you need.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question