eric7/Tools/webBrowserSupport.py

Thu, 30 Dec 2021 11:17:58 +0100

author
Detlev Offenbach <detlev@die-offenbachs.de>
date
Thu, 30 Dec 2021 11:17:58 +0100
branch
eric7
changeset 8881
54e42bc2437a
parent 8318
962bce857696
permissions
-rw-r--r--

Updated copyright for 2022.

#!/usr/bin/env python3
# -*- coding: utf-8 -*-

# Copyright (c) 2018 - 2022 Detlev Offenbach <detlev@die-offenbachs.de>
#

"""
Script to determine the supported web browser variant.

It looks for QtWebEngine. It reports the variant found or the string 'None' if
it is absent.
"""

import sys
import contextlib

variant = "None"

with contextlib.suppress(ImportError):
    from PyQt6 import QtWebEngineWidgets    # __IGNORE_WARNING__
    variant = "QtWebEngine"

print(variant)      # __IGNORE_WARNING_M801__

sys.exit(0)

eric ide

mercurial