Line-Numbering of a textEdit in pyqt

ε祈祈猫儿з 提交于 2020-01-04 09:36:08

问题


I wish to number the lines in a textEdit in such a way that the line number do not get copied or cut where as the rest of the data which I dump in it can be accesed.


回答1:


You'll need a separate widget on the side to display line numbers. You can find details here: http://harmattan-dev.nokia.com/docs/library/html/qt4/widgets-codeeditor.html



来源:https://stackoverflow.com/questions/17424032/line-numbering-of-a-textedit-in-pyqt

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!