Skip to main content

QT UI Extension

Project description

quite6: QT UI Extension for Python3

|Build Status|

Features

  1. powerful signal-slot
  2. user friendly widget classes

User Friendly Widget Classes

Uniform wrapper on frequently-used widget, including:

container widget:

  1. Widget <./quite6/gui/widgets/widget.py>__
  2. Dialog <./quite6/gui/widgets/dialog.py>__
  3. MainWindow <./quite6/gui/widgets/main_window.py>__
  4. GroupBox <./quite6/gui/widgets/group_box.py>__
  5. DockWidget <./quite6/gui/widgets/dock_widget.py>__

value widget:

  1. Label <./quite6/gui/widgets/label.py>__
  2. LineEdit <./quite6/gui/widgets/line_edit.py>__
  3. ComboBox <./quite6/gui/widgets/combo_box.py>__
  4. ListWidget <./quite6/gui/widgets/list_widget.py>__
  5. SpinBox <./quite6/gui/widgets/spin_box.py>__
  6. DoubleSpinBox <./quite6/gui/widgets/double_spin_box.py>__

behavior widget:

  1. InputDialog <./quite6/gui/widgets/input_dialog.py>__
  2. Action <./quite6/gui/widgets/action.py>__
  3. Shortcut <./quite6/gui/widgets/shortcut.py>__
  4. PushButton <./quite6/gui/widgets/push_button.py>__

Container Widget


*Example 1*: `create widget <./examples/1_create_widget/example-1.py>`__

.. code:: python

    import quite6

    w = quite6.Widget()
    w.exec()

.. figure:: docs/images/1.simple.widget.png
   :alt: Simple Widget

   Simple Widget

*Example 2*: `nested widget <./examples/2_nested_widget/example-2.py>`__

.. code:: python

    import quite6


    class CustomWidget(quite6.Widget):
        def paint(self, painter: quite6.Painter):
            painter.setFont(quite6.QFont("Courier New", 14.0))
            painter.draw_text_bottom_right(quite6.PointF(0, 0), "Custom Widget")
            painter.end()

    main_window = quite6.MainWindow()
    custom_widget = CustomWidget(parent=main_window)
    main_window.set_central_widget(custom_widget)
    main_window.exec()

.. figure:: docs/images/2.nested.widget.png
   :alt: Nested Widget

   Nested Widget

*Example 3*: `widget from ui
file <./examples/3_widget_from_ui_file/example-3.py>`__

.. code:: python

    import os
    from quite6 import *


    class CustomWidget(Widget):
        def paint(self, painter: Painter):
            w, _ = self.size
            painter.setFont(QFont("Courier New", 14.0))
            painter.draw_text_bottom_right(PointF(0, 0), "So Cool!")
            painter.draw_text_bottom_left(PointF(w, 0), "From Custom Widget")
            painter.end()


    main_window = load_ui(filename=os.path.join(os.path.dirname(__file__), 'main_window.ui'))
    main_window.set_central_widget(CustomWidget(parent=main_window))
    main_window.exec()

Use QtDesigner to create a ui file:

.. figure:: docs/images/3.ui.design.png
   :alt: UI Design

   UI Design

.. |Build Status| image:: https://travis-ci.com/KD-Group/quite6.svg?branch=master
   :target: https://travis-ci.com/KD-Group/quite6

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

quite6-1.0.4.tar.gz (24.7 kB view details)

Uploaded Source

Built Distribution

quite6-1.0.4-py3-none-any.whl (39.2 kB view details)

Uploaded Python 3

File details

Details for the file quite6-1.0.4.tar.gz.

File metadata

  • Download URL: quite6-1.0.4.tar.gz
  • Upload date:
  • Size: 24.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.10.14

File hashes

Hashes for quite6-1.0.4.tar.gz
Algorithm Hash digest
SHA256 dc43b31665cf4fad965d7685c405609d81f98475d678c0d7a8f72f33f62b54ea
MD5 b4bc41df8d84a218117677655f293a9b
BLAKE2b-256 7bb607e6c988fffaec0ecb4bdca9a0f08023dbc4b12c4c1b80db89013fe2f89e

See more details on using hashes here.

File details

Details for the file quite6-1.0.4-py3-none-any.whl.

File metadata

  • Download URL: quite6-1.0.4-py3-none-any.whl
  • Upload date:
  • Size: 39.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.10.14

File hashes

Hashes for quite6-1.0.4-py3-none-any.whl
Algorithm Hash digest
SHA256 4fcb3323e32e56ba8f209e5b7bd03ebaae30ea0e8fbc70ccea21214e1ffc3d54
MD5 3e7a9759768c5ffce4324a6026965bba
BLAKE2b-256 b5fbe779e6af7af870ec8ff7e6d5337144a083fb32162d75b7dc6da86c180d82

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page