aboutsummaryrefslogtreecommitdiffstats
path: root/examples/widgets/itemviews/spreadsheet/main.py
blob: e811f62913eb263d39b1d5c51656b1773019efdf (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
# Copyright (C) 2022 The Qt Company Ltd.
# SPDX-License-Identifier: LicenseRef-Qt-Commercial OR BSD-3-Clause
from __future__ import annotations

import sys

from PySide6.QtGui import QPixmap
from PySide6.QtWidgets import QApplication, QLayout

from spreadsheet import SpreadSheet

if __name__ == "__main__":
    app = QApplication()

    sheet = SpreadSheet(10, 6)
    sheet.setWindowIcon(QPixmap(":/images/interview.png"))
    sheet.show()
    sheet.layout().setSizeConstraint(QLayout.SizeConstraint.SetFixedSize)

    sys.exit(app.exec())