[prev in list] [next in list] [prev in thread] [next in thread] 

List:       pykde
Subject:    [PyQt] QTextEdit based interpreter how to paste multiple lines of string?
From:       Han Jiang <oglops () gmail ! com>
Date:       2016-01-19 7:54:58
Message-ID: CAPiRsUWqigonCvbEPpciJ0HXE5AfONgWxr8bOZijC9A-dGbZ=g () mail ! gmail ! com
[Download RAW message or body]

[Attachment #2 (multipart/alternative)]


I have a embeded python interpreter which is qtextedit, I want it to have
the same behavior as  external python interpreter.

default interpreter:  http://imgur.com/sq7IeUH
my pyqt interpreter:  http://imgur.com/dM6Cian

there are several problems:
1.How do I make the text cursor stay at the line I was editing on, and not
follow my drag selection?  ( with QTextBlock userstate ? )

2.How can I made not editing lines read only, but the lines I am editing
editable? ( with QTextBlock userstate?)

3. How do I add ... to the beginning of lines if I paste multiple lines of
code inside? ( with eventfilter?)

the code is here :   https://github.com/oglops/pyshell

[Attachment #5 (text/html)]

<div dir="ltr"><div><div><div>I have a embeded python interpreter which is qtextedit, \
I want it to have the same behavior as   external python interpreter.<br><br>default \
interpreter:   <a href="http://imgur.com/sq7IeUH">http://imgur.com/sq7IeUH</a><br>my \
pyqt interpreter:   <a \
href="http://imgur.com/dM6Cian">http://imgur.com/dM6Cian</a><br><br>there are several \
problems:<br></div>1.How do I make the text cursor stay at the line I was editing on, \
and not follow my drag selection?   ( with QTextBlock userstate ? \
)<br><br></div>2.How can I made not editing lines read only, but the lines I am \
editing editable? ( with QTextBlock userstate?)<br><br></div>3. How do I add ... to \
the beginning of lines if I paste multiple lines of code inside? ( with \
eventfilter?)<br><div><div><div><br>the code is here :     <a \
href="https://github.com/oglops/pyshell">https://github.com/oglops/pyshell</a><br></div></div></div></div>



[Attachment #6 (text/plain)]

_______________________________________________
PyQt mailing list    PyQt@riverbankcomputing.com
https://www.riverbankcomputing.com/mailman/listinfo/pyqt

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic