Questions tagged [qplaintextedit]

QPlainTextEdit is class in QtGui module which provides a widget that is used to edit and display plain text.

QPlainTextEdit is class in QtGui module which provides a widget that is used to edit and display plain text.

136 questions
0
votes
2 answers

Setting the Height of a QPlainTextEdit Delegate in a QTableView

I'm working here on a project and currently I'm stuck on the following problem. It is about a QTableView which has a column called "Description", the cells of this column contain a QPlainTextEditDelegate. I'm failing on setting the Height of the…
user925861
0
votes
0 answers

How to correctly use find() function with qplaintextedit

I have this part of the code but it cause an infinity loop during execution, how I can avoid it ? find is a method from qplaintextedit class if (query.useRegex) { auto options = (query.flags & QTextDocument::FindCaseSensitively) ?…
0
votes
1 answer

Qt 6 crash in QPlainText::setExtraSelections after QPlainText::setDocument

I'm trying to set up a text widget that highlights the searched word, when I open a new file with QPlainText::setDocument, then immediately use QPlainText::setExtraSelections I get a SIGSEV crash…
0
votes
1 answer

How to remove spacing above the first line of a QPlainTextEdit?

I am working on creating a line numbers widget for a QPlainTextEdit. It is basically a QListWidget. However, I have detected a small space only above the first line of a QPlainTextEdit as you can see in my screenshot. How can I remove this space…
Baradé
  • 1,290
  • 1
  • 15
  • 35
0
votes
1 answer

Insert text before and after selected text in PyQt5 QPlainTextEdit

I am trying to insertText before and after the selected word in QPlainTextEdit PyQt5 For example: when I write "My name is AbdulWahab" and select AbdulWahab then if I press left Parenthesis then AbdulWahab should turn into (AbdulWahab) Thank you
0
votes
1 answer

PyQt5 QPlainTextEdit make hyperlinks

We are a chat application in python using PyQt5 but we hit a roadblock while trying to make hyperlinks clickable in our QPlainTextEdit which we use for our chatbox. Our output is just a plain html tag without highlighting. chatbox =…
0
votes
1 answer

How to add a myOwn-background image to QPlainTextEdit?

For example, if you create a simple plaintextedit, the background is just white. How do I change white background with my own image?
0
votes
0 answers

Run python script whit QProcess and show into textEdit the result in realtime

I wolud print the result during my script run via Qprocess but nothing happen. I thinking I wrote wrong the args into process start but im not sure. Some one has an idea? Below my code class TotalopenstationDialog(QtWidgets.QDialog, FORM_CLASS): …
enzo cocca
  • 35
  • 1
  • 7
0
votes
1 answer

how to detect scroll bar move down in QPlainTextEdit

I am writing a slot method for the signal of scrolling down a scrollbar in QPlainTextEdit. I only found this signalQPlainTextEdit.verticalScrollBar().valueChanged. I tested this signal and it returned the position number when scrolls to a new…
Lisen
  • 168
  • 1
  • 2
  • 11
0
votes
1 answer

Parent function terminates whenever I try to call QTextCharFormat on QTextCursor selection

I recently ran into a weird issue where my QPlainTextEdit::selectionChanged handler function terminates prematurely whenever QTextCursor::mergeCharFormat/setCharFormat/setBlockCharFormat is called. Additionally, after terminating it gets called…
Dex
  • 164
  • 1
  • 2
  • 18
0
votes
1 answer

How to auto replace characters typed inside a QtPlainTextEdit Widget

This is the first time, that I ever used PyQt5 and it's pretty good as well, so I built a text editor like thing with it, and I want to replace every typed character with another character in a QtPlainTextEdit. Actually what I want to do is…
0
votes
0 answers

Disable modification to plain text editor

I try to do a terminal in pyqt5 using plain text editor. This terminal should print some output but also should take some inputes from users. My question is how can we disable modifications (but not just set in readOnly mode) for plain text editor…
antoine
  • 3
  • 5
0
votes
2 answers

How to delete a textline with matched text in QPlainTextEdit?

Below lines are in A QPlainTextEdit: I want to delete a matched line with line variable help. For example, I want to delete line 2 s44 grade with the help of line variable(line = "line 2") I am able to delete the particular text with below…
user3030327
  • 411
  • 1
  • 7
  • 19
0
votes
0 answers

Qt4 and Qt5 QPlainTextEdit incompatibility

I'm trying to build a program via Qt4, which was written on Qt5. My UI form have QPlainTextEdit and I receive following errors: 'class QPlainTextEdit' has no member named 'setSizeAdjustPolicy'; did you mean 'setSizePolicy'? …
ans
  • 378
  • 1
  • 5
  • 18
0
votes
1 answer

Print PrettyTable data to QPlainTextEdit

My setup is Windows 10, Python 3.7, PyQt5 The goal is to print a formatted table to a QPlainTextEdit. I have some data in a PrettyTable object. When I print this data to stdout, the table gets printed perfectly! But when printing to QPlainTextEdit…