View Single Post
Old 02-03-2021, 03:32 AM   #533
ownedbycats
Custom User Title
ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.
 
ownedbycats's Avatar
 
Posts: 11,095
Karma: 76037135
Join Date: Oct 2018
Location: Canada
Device: Kobo Libra H2O, formerly Aura HD
I'm not sure how applicable this is to everything else, but JimmXinu modified FFF several months ago to make the syntax highlighting more readable:
https://github.com/JimmXinu/FanFicFa...highlighter.py

This looks to be the relevant part

Code:
        try:
            if QApplication.instance().is_dark_theme:
                colors = {
                    'knownentries':Qt.green,
                    'errors':Qt.red,
                    'allkeywords':Qt.magenta,
                    'knownkeywords':QColor(Qt.blue).lighter(150),
                    'knownsections':Qt.darkCyan,
                    'teststories':Qt.cyan,
                    'storyUrls':Qt.magenta,
                    'comments':Qt.yellow
                    }
        except Exception as e:
            logger.error("Failed to set dark theme highlight colors: %s"%e)
ownedbycats is offline   Reply With Quote