Skip to main content

The livelexqt Python module

Project description

Small Python library to use livelex with Qt’s QTextDocument

This module depends on livelex.

Homepage: https://github.com/wbsoft/livelex-qt Download: https://pypi.org/project/livelex-qt

Example:

from PyQt5.QtWidgets import QApplication
from PyQt5.QtGui import QTextDocument

app = QApplication([])

import livelexqt
import livelex.lang.xml

lexicon = livelex.lang.xml.Xml.root
doc = QTextDocument()
livelexqt.SyntaxHighlighter.instance(doc, lexicon)

# Now the text in the document is automatically highlighted using the
# specified root lexicon.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

livelex-qt-0.3.0.tar.gz (7.9 kB view hashes)

Uploaded source

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Huawei Huawei PSF Sponsor Microsoft Microsoft PSF Sponsor NVIDIA NVIDIA PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page