diff --git a/Makefile b/Makefile index 305cac6..1d4d8bf 100644 --- a/Makefile +++ b/Makefile @@ -6,16 +6,6 @@ include VERSION ARCH:=`uname -i` PACKAGE = mambareport -DISTROID = openmamba - -RPM_VENDOR = openmamba -RPM_DISTRIBUTION = openmamba -RPM_DISTROEXT = mamba - -SYSCONFIGFILE = netsrpminstall - -DISTROid = $(shell echo $(DISTROID) | tr A-Z a-z) -DISTROICON = $(DISTROid) DESTDIR = @@ -41,10 +31,6 @@ xdg_directorydir = ${datadir}/desktop-directories xdg_menudir = ${sysconfdir}/xdg/menus xdg_mergedmenudir = $(xdg_menudir)/applications-merged -distrorootdir = ${datadir}/$(DISTROid) -distrobindir = ${distrorootdir}/bin -distrosrpmsdir = ${distrorootdir}/SRPMS -distrodesktopdir = ${distrorootdir}/desktop srcdir = . INSTALL = /usr/bin/install @@ -76,12 +62,6 @@ install-locales: locales done @lrelease-qt5 mambareport/mambareport_it.ts -qm $(DESTDIR)$(datadir)/locale/it/LC_MESSAGES/mambareport.qm -install-icons: - @for i in 16x16 22x22 32x32 48x48 64x64 128x128; do \ - $(INSTALL_DIR) $(DESTDIR)$(iconsdir)/$$i/apps/; \ - $(INSTALL_DATA) mambareport/mambareport-$$i.png $(DESTDIR)$(iconsdir)/$$i/apps/mambareport.png; \ - done - install-mambareport: @$(INSTALL_DIR) $(DESTDIR)$(bindir) @$(INSTALL_DIR) $(DESTDIR)$(mambareportdatadir) @@ -89,14 +69,11 @@ install-mambareport: $(INSTALL_SCRIPT) mambareport/mambareport $(DESTDIR)$(bindir)/mambareport $(INSTALL_SCRIPT) mambareport/mambareport.py $(DESTDIR)$(mambareportdatadir) $(INSTALL_DATA) mambareport/mambareport.desktop $(DESTDIR)$(xdg_appsdir) - $(INSTALL_DATA) mambareport/openmamba.png $(DESTDIR)$(mambareportdatadir) - $(INSTALL_DATA) mambareport/mambareport.png $(DESTDIR)$(mambareportdatadir) cp mambareport/*.ui $(DESTDIR)$(mambareportdatadir) install: $(pck_infiles:.in=) \ install-mambareport \ - install-locales \ - install-icons + install-locales dist: clean @mkdir /tmp/$(distdir) @@ -115,4 +92,3 @@ clean: rm -f $(dist_archive) rm -f $(patsubst %.in,%,$(pck_infiles)) rm -f $(pck_catalogs:.po=.mo) - rm -f $(pck_catalogs1:.po=.mo) diff --git a/mambareport/GenerateReportPage.ui b/mambareport/GenerateReportPage.ui index 968b7c9..14a499f 100644 --- a/mambareport/GenerateReportPage.ui +++ b/mambareport/GenerateReportPage.ui @@ -108,9 +108,9 @@ background-color: rgb(255, 255, 255); 10 - 20 + 30 491 - 201 + 191 diff --git a/mambareport/WelcomePage.ui b/mambareport/WelcomePage.ui index 0328af5..80095bc 100644 --- a/mambareport/WelcomePage.ui +++ b/mambareport/WelcomePage.ui @@ -7,7 +7,7 @@ 0 0 552 - 380 + 385 @@ -16,6 +16,12 @@ 0 + + + 75 + true + + Form @@ -55,7 +61,7 @@ - 20 + 30 10 491 61 @@ -71,7 +77,7 @@ - openmamba.png + /usr/share/pixmaps/vendor-logo-large.png Qt::AlignCenter @@ -88,22 +94,12 @@ - + - <html><head/><body><p><span style=" font-style:italic;">mambareport - Copyright (c) 2022 by Silvan Calarco<br/>Released under the terms of the GNU GPL v3 license</span></p></body></html> + <html><head/><body><p><br/></p></body></html> - Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter - - - - - - - <html><head/><body><p><a href="https://openmamba.org"><span style=" text-decoration: underline; color:#2980b9;">openmamba.org</span></a></p></body></html> - - - Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter + Qt::AlignCenter @@ -120,7 +116,7 @@ - background-color: rgb(239, 240, 241); + background-color: rgb(255,255,255); QFrame::StyledPanel @@ -131,14 +127,14 @@ - 10 - 10 - 511 - 16 + 20 + 60 + 501 + 20 - <html><head/><body><p>Please enter a description of the reason why you are generating a diagnostic report:</p></body></html> + <html><head/><body><p>Please enter a description of the problem(s) you are reporting:</p></body></html> Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop @@ -163,13 +159,32 @@ - 10 - 40 - 531 - 29 + 20 + 80 + 511 + 31 + + + + 20 + 20 + 521 + 20 + + + + + 75 + true + + + + Generate a system report to help us diagnose your problem + + diff --git a/mambareport/mambareport-128x128.png b/mambareport/mambareport-128x128.png deleted file mode 100644 index 7951ee3..0000000 Binary files a/mambareport/mambareport-128x128.png and /dev/null differ diff --git a/mambareport/mambareport-16x16.png b/mambareport/mambareport-16x16.png deleted file mode 100644 index 9b66b49..0000000 Binary files a/mambareport/mambareport-16x16.png and /dev/null differ diff --git a/mambareport/mambareport-22x22.png b/mambareport/mambareport-22x22.png deleted file mode 100644 index 6aee518..0000000 Binary files a/mambareport/mambareport-22x22.png and /dev/null differ diff --git a/mambareport/mambareport-32x32.png b/mambareport/mambareport-32x32.png deleted file mode 100644 index ea54640..0000000 Binary files a/mambareport/mambareport-32x32.png and /dev/null differ diff --git a/mambareport/mambareport-48x48.png b/mambareport/mambareport-48x48.png deleted file mode 100644 index 787b10f..0000000 Binary files a/mambareport/mambareport-48x48.png and /dev/null differ diff --git a/mambareport/mambareport-64x64.png b/mambareport/mambareport-64x64.png deleted file mode 100644 index 6f2ec5a..0000000 Binary files a/mambareport/mambareport-64x64.png and /dev/null differ diff --git a/mambareport/mambareport.png b/mambareport/mambareport.png deleted file mode 100644 index 7951ee3..0000000 Binary files a/mambareport/mambareport.png and /dev/null differ diff --git a/mambareport/mambareport.py b/mambareport/mambareport.py index dd34f9f..a5dec4f 100755 --- a/mambareport/mambareport.py +++ b/mambareport/mambareport.py @@ -9,6 +9,7 @@ from pathlib import Path import gettext import subprocess import os +import distro import gi gi.require_version('PackageKitGlib', '1.0') @@ -20,13 +21,18 @@ DATADIR = os.path.dirname(os.path.realpath((__file__))) + "/" class MambareportWizard(QtWidgets.QWizard): def __init__(self, parent=None): super(MambareportWizard, self).__init__(parent) + self.setWindowTitle(_("Diagnostic report tool") + + " - {}".format(distro.name())) + self.setFixedSize(571,465) + self.welcomePage = WelcomePage(self) + self.welcomePage.distroInfoLabel.setText(distro.name(pretty=True) + + "

" + distro.os_release_info()['home_url'] + "") self.addPage(self.welcomePage) + self.generateReportPage = GenerateReportPage(self) self.addPage(self.generateReportPage) - self.setWindowTitle(_("Diagnostic report tool") + - " - openmamba.org") - self.setFixedSize(571,465) self.currentIdChanged.connect(self.currentIdChangedSlot) self.generateReportThread = GenerateReportThread(self) @@ -65,7 +71,7 @@ class GenerateReportThread(QtCore.QThread): self.updateProgressSignal.emit({ 'details': result.stderr.decode('UTF-8').replace('\n', '
')}) self.updateProgressSignal.emit({ 'value': 100, - 'label': _("Done. Report saved as {}.").format(reportFile)}) + 'label': _("Done. Report saved as {}.").format(reportFile)}) # Enable back and next buttons self.parent.generateReportPage.done = True self.doneSignal.emit() @@ -105,7 +111,7 @@ class GenerateReportPage(QtWidgets.QWizardPage): if __name__ == '__main__': import sys app = QtWidgets.QApplication(sys.argv) - app.setWindowIcon(QtGui.QIcon(DATADIR + "mambareport.png")) + app.setWindowIcon(QtGui.QIcon.fromTheme("mambareport")) # UI translations locale = QLocale.system().name() language = locale[0:2] diff --git a/mambareport/mambareport_it.ts b/mambareport/mambareport_it.ts index 66813a2..43d14c7 100644 --- a/mambareport/mambareport_it.ts +++ b/mambareport/mambareport_it.ts @@ -5,39 +5,35 @@ Form - + Form - + Form <html><head/><body><p align="center"><span style=" font-size:14pt; font-weight:600;">Generating report...</span></p></body></html> - + <html><head/><body><p align="center"><span style=" font-size:14pt; font-weight:600;">Generazione del report...</span></p></body></html> <html><head/><body><p><span style=" font-weight:600;">Report generation output:</span></p></body></html> - + <html><head/><body><p><span style=" font-weight:600;">Esito della generazione del report:</span></p></body></html> - - <html><head/><body><p><span style=" font-style:italic;">mambareport - Copyright (c) 2022 by Silvan Calarco<br/>Released under the terms of the GNU GPL v3 license</span></p></body></html> - - - - - <html><head/><body><p><a href="https://openmamba.org"><span style=" text-decoration: underline; color:#2980b9;">openmamba.org</span></a></p></body></html> - - - - - <html><head/><body><p>Please enter a description of the reason why you are generating a diagnostic report:</p></body></html> - - - - + + <html><head/><body><p><br/></p></body></html> - + + + + + <html><head/><body><p>Please enter a description of the problem(s) you are reporting:</p></body></html> + <html><head/><body><p>Inserisci una descrizione del problema che intendi segnalare:</p></body></html> + + + + Generate a system report to help us diagnose your problem + Genera un report del sistema per aiutare a diagnosticare il tuo problema diff --git a/mambareport/openmamba.png b/mambareport/openmamba.png deleted file mode 100644 index ff941ba..0000000 Binary files a/mambareport/openmamba.png and /dev/null differ diff --git a/mambareport/po/it.po b/mambareport/po/it.po index 1cba43e..28c11e5 100644 --- a/mambareport/po/it.po +++ b/mambareport/po/it.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2022-06-18 16:58+0200\n" +"POT-Creation-Date: 2022-06-19 20:04+0200\n" "Last-Translator: Silvan Calarco \n" "Language-Team: LANGUAGE \n" "Language: \n" @@ -16,15 +16,14 @@ msgstr "" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -#: mambareport.py:27 +#: mambareport.py:24 msgid "Diagnostic report tool" msgstr "Generazione di un report diagnostico" -#: mambareport.py:68 -msgid "Done. Report saved as {}." -msgstr "Fatto. Report salvato in {}." +#: mambareport.py:74 +msgid "Done. Report saved as {}." +msgstr "Fatto. Report salvato in {}." -#: mambareport.py:54 +#: mambareport.py:60 msgid "Generating report..." msgstr "Generazione del report..." - diff --git a/mambareport/po/messages.pot b/mambareport/po/messages.pot index c31dae4..5144b0f 100644 --- a/mambareport/po/messages.pot +++ b/mambareport/po/messages.pot @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2022-06-18 16:58+0200\n" +"POT-Creation-Date: 2022-06-19 20:04+0200\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -17,14 +17,14 @@ msgstr "" "Content-Type: text/plain; charset=CHARSET\n" "Content-Transfer-Encoding: 8bit\n" -#: mambareport.py:27 +#: mambareport.py:24 msgid "Diagnostic report tool" msgstr "" -#: mambareport.py:68 -msgid "Done. Report saved as {}." +#: mambareport.py:74 +msgid "Done. Report saved as {}." msgstr "" -#: mambareport.py:54 +#: mambareport.py:60 msgid "Generating report..." msgstr ""