From 4088b968617854a80fecf8da562f7a1d32007180 Mon Sep 17 00:00:00 2001 From: Jan Grewe Date: Tue, 5 Jan 2021 12:06:58 +0100 Subject: [PATCH] [main] set a minimum app size, do not try to open a file it no file arg given --- nixview.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/nixview.py b/nixview.py index 6ecde7e..e1815b2 100755 --- a/nixview.py +++ b/nixview.py @@ -10,7 +10,10 @@ def main(): args = parser.parse_args() app = QApplication(sys.argv) window = NixView() - window.open_file(args.file) + window.setMinimumWidth(800) + window.setMinimumHeight(600) + if len(args.file.strip()) > 0: + window.open_file(args.file) window.show() sys.exit(app.exec_())