diff -Nru m2l-pyqt-1.3/debian/changelog m2l-pyqt-1.5/debian/changelog --- m2l-pyqt-1.3/debian/changelog 2016-10-24 17:18:21.000000000 +0000 +++ m2l-pyqt-1.5/debian/changelog 2017-09-16 11:04:35.000000000 +0000 @@ -1,3 +1,11 @@ +m2l-pyqt (1.5-1) unstable; urgency=medium + + * New upstream release. Closes: #875046 + * updated Standards-Version and dependencies + * patched src/lang/Makefile to take qt5 in account + + -- Georges Khaznadar Sat, 16 Sep 2017 13:04:35 +0200 + m2l-pyqt (1.3-2) unstable; urgency=medium * upgraded Standards-Version: 3.9.8 diff -Nru m2l-pyqt-1.3/debian/control m2l-pyqt-1.5/debian/control --- m2l-pyqt-1.3/debian/control 2016-10-24 17:17:22.000000000 +0000 +++ m2l-pyqt-1.5/debian/control 2017-09-16 11:04:35.000000000 +0000 @@ -2,17 +2,17 @@ Section: x11 Priority: optional Maintainer: Georges Khaznadar -Build-Depends: debhelper (>= 9.0.0), python3-all, python-qt4-dev, libqt4-dev, - pyqt4-dev-tools +Build-Depends: debhelper (>= 9.0.0), python3-all, python3-pyqt5, + pyqt5-dev-tools, qttools5-dev-tools X-Python3-Version: >= 3.4 -Standards-Version: 3.9.8 +Standards-Version: 4.1.0 Homepage: https://sourceforge.net/projects/mediawiki2latexguipyqt/ Package: mediawiki2latexguipyqt Architecture: all Depends: ${misc:Depends}, ${python3:Depends}, mediawiki2latex, - python3-pyqt4, - iceweasel|www-browser + python3-pyqt5, + firefox-esr|iceweasel|www-browser Description: lightweight GUI for mediawiki2latex This Graphic User Interface allows you to begin using mediawiki2latex most easily. Mediawiki2latex provides the user with a simple way of diff -Nru m2l-pyqt-1.3/debian/patches/series m2l-pyqt-1.5/debian/patches/series --- m2l-pyqt-1.3/debian/patches/series 2016-04-23 16:49:53.000000000 +0000 +++ m2l-pyqt-1.5/debian/patches/series 2017-09-16 11:04:35.000000000 +0000 @@ -0,0 +1 @@ +src-lang-Makefile.patch diff -Nru m2l-pyqt-1.3/debian/patches/src-lang-Makefile.patch m2l-pyqt-1.5/debian/patches/src-lang-Makefile.patch --- m2l-pyqt-1.3/debian/patches/src-lang-Makefile.patch 1970-01-01 00:00:00.000000000 +0000 +++ m2l-pyqt-1.5/debian/patches/src-lang-Makefile.patch 2017-09-16 11:04:35.000000000 +0000 @@ -0,0 +1,17 @@ +Index: m2l-pyqt-1.5/src/lang/Makefile +=================================================================== +--- m2l-pyqt-1.5.orig/src/lang/Makefile ++++ m2l-pyqt-1.5/src/lang/Makefile +@@ -7,10 +7,10 @@ LANG = $(patsubst translations/mediawiki + all: $(QMFILES) + + translations/%.qm : translations/%.ts +- lrelease $< -qm $@ ++ lrelease -qt5 $< -qm $@ + + $(TSFILES): $(SOURCES) translation.pro +- pylupdate4 -verbose translation.pro ++ pylupdate5 -verbose translation.pro + + + clean: diff -Nru m2l-pyqt-1.3/debian/watch m2l-pyqt-1.5/debian/watch --- m2l-pyqt-1.3/debian/watch 1970-01-01 00:00:00.000000000 +0000 +++ m2l-pyqt-1.5/debian/watch 2016-10-24 17:18:21.000000000 +0000 @@ -0,0 +1,2 @@ +version=3 +http://sf.net/mediawiki2latexguipyqt/mediawiki2latexguipyqt-(.+)\.tar\.gz diff -Nru m2l-pyqt-1.3/src/lang/translations/mediawiki2latex-gui-fr_FR.ts m2l-pyqt-1.5/src/lang/translations/mediawiki2latex-gui-fr_FR.ts --- m2l-pyqt-1.3/src/lang/translations/mediawiki2latex-gui-fr_FR.ts 2016-04-23 16:43:16.000000000 +0000 +++ m2l-pyqt-1.5/src/lang/translations/mediawiki2latex-gui-fr_FR.ts 2017-09-13 12:05:50.000000000 +0000 @@ -99,22 +99,22 @@ Dialog - + About À propos - + Authors Auteurs - + License Licence - + Translations Traductions @@ -122,179 +122,179 @@ MainWindow - + downloading article and contributor information téléchargement des informations pour l'article et les contributeurs - + parsing article text analyse du texte de l'article - + forking threads to download of images and contributor information on them lancement de threads pour télécharger les images et les information légales qui s'y appliquent - + precompiling table columns précompilation des colonnes de la table - + joining threads to download the images and contributor information on them attente de la fin des threads pour télécharger les images et les information légales qui s'y appliquent - + preparing for PDF generation préparation de la génération de PDF - + preparing images for LaTeX document préparation des images pour le document LaTeX - + generating PDF file. LaTeX run 1 of 4 génération du fichier PDF. Compilation LaTeX 1/4 - + generating PDF file. LaTeX run 2 of 4 génération du fichier PDF. Compilation LaTeX 2/4 - + generating PDF file. LaTeX run 3 of 4 génération du fichier PDF. Compilation LaTeX 3/4 - + generating PDF file. LaTeX run 4 of 4 génération du fichier PDF. Compilation LaTeX 4/4 - + finished terminé - + echo 'default message; you should not see it' echo 'message par défaut ; vous ne devriez pas le voir' - + File still open Fichier encore ouvert - + Please close your PDF viewer before pressing the run button! This program need writing permission on the PDF file! Veuillez fermer votre visionneuse PDF avant d'appuyer sur le bouton de lancement ! Ce programme a besoin du droit d'écriture sur le fichier PDF ! - + Mediawiki to Latex started... Démarrage de Mediawiki to LaTeX ... - + MediaWiki MediaWiki - + Normal Normal - + Rasterize Rastériser - + running mediawiki2latex mediawiki2latex lancé - + The sequence of processes is finished. You can close the window. La séquences de procédures est terminée. Vous pouvez fermer la fenêtre. - + Mediawiki to LaTeX Mediawiki to LaTeX - + Wiki source Source dans le wiki - + Template expansion Développement des modèles - + Print Print - + Mediawiki Mediawiki - + Paper Papier - + A4 A4 - + A5 A5 - + B5 B5 - + letter letter - + legal legal - + executive executive - + Vector graphics Graphismes vectoriels - + Keep vector form Laisser en forme vectorielle @@ -309,22 +309,22 @@ exclue - + Preferences Préférences - + Logs Journaux - + Errors Erreurs - + Run Lancer @@ -344,12 +344,12 @@ Enregistrer les préférences - + &Quit (Ctrl-Q) &Quitter (Ctrl-Q) - + Ctrl+Q Ctrl+Q @@ -364,12 +364,12 @@ À propos ... (F1) - + F1 F1 - + mediawiki2latex-pyqt version {version}: a gui for mediawiki2latex @@ -417,44 +417,54 @@ Traduction française : ©Georges Khaznadar <georgesk@debian.org> - + Output Format - + Format cible - + PDF - + PDF - + LaTeX Source Zip - + ZIP source LaTeX - + &File - + &Fichier - + A&bout - + À &propos - + &Save preferences - + Enregi&strer les préférences - + &Help - + &Aide - + &About ... (F1) - + À &propos ... (F1) + + + + ODT (Word Processor) + ODT (traitement de texte) + + + + EPUB + EPUB diff -Nru m2l-pyqt-1.3/src/MainWindow.ui m2l-pyqt-1.5/src/MainWindow.ui --- m2l-pyqt-1.3/src/MainWindow.ui 2016-04-23 16:43:16.000000000 +0000 +++ m2l-pyqt-1.5/src/MainWindow.ui 2017-09-13 12:05:50.000000000 +0000 @@ -196,6 +196,16 @@ LaTeX Source Zip + + + ODT (Word Processor) + + + + + EPUB + + diff -Nru m2l-pyqt-1.3/src/Makefile m2l-pyqt-1.5/src/Makefile --- m2l-pyqt-1.3/src/Makefile 2014-09-28 17:32:48.000000000 +0000 +++ m2l-pyqt-1.5/src/Makefile 2017-09-13 12:05:50.000000000 +0000 @@ -3,7 +3,7 @@ UI_PYTHON = $(patsubst %.ui, Ui_%.py, $(UI_SOURCES)) Ui_%.py : %.ui - pyuic4 $< > $@ + pyuic5 $< > $@ all: $(UI_PYTHON) make -C lang $@ DESTDIR="$(DESTDIR)" diff -Nru m2l-pyqt-1.3/src/mediawiki2latex-pyqt m2l-pyqt-1.5/src/mediawiki2latex-pyqt --- m2l-pyqt-1.3/src/mediawiki2latex-pyqt 2016-04-23 16:43:16.000000000 +0000 +++ m2l-pyqt-1.5/src/mediawiki2latex-pyqt 2017-09-13 12:05:50.000000000 +0000 @@ -30,11 +30,13 @@ Copyright © 2014 Georges Khaznadar """ import sys -from PyQt4.QtGui import QLabel, QApplication, qApp, QMainWindow, QLineEdit -from PyQt4.QtGui import QProgressBar, QPushButton, QGridLayout, QComboBox -from PyQt4.QtGui import QMessageBox, QIcon, QDialog -from PyQt4.QtCore import SIGNAL, QTimer, pyqtSignal, QProcess, Qt -from PyQt4.QtCore import QTranslator, QLibraryInfo, qDebug +from PyQt5.QtGui import QIcon +from PyQt5.QtWidgets import QLabel, QApplication, qApp, QMainWindow, QLineEdit +from PyQt5.QtWidgets import QProgressBar, QPushButton, QGridLayout, QComboBox +from PyQt5.QtWidgets import QMessageBox, QDialog +from PyQt5.QtCore import QTimer, pyqtSignal, QProcess, Qt +from PyQt5.QtCore import QTranslator, QLibraryInfo, qDebug +from PyQt5.QtCore import QByteArray import webbrowser import os import tempfile @@ -52,19 +54,14 @@ locale = getdefaultlocale() try: - from PyQt4 import QtCore - _fromUtf8 = QtCore.QString.fromUtf8 + _encoding = QApplication.UnicodeUTF8 + def _translate(context, text, disambig=None): + return text + return QApplication.translate(context, text, disambig, _encoding) except AttributeError: - def _fromUtf8(s): - return s - - try: - _encoding = QApplication.UnicodeUTF8 - def _translate(context, text, disambig=None): - return QApplication.translate(context, text, disambig, _encoding) - except AttributeError: - def _translate(context, text, disambig=None): - return QApplication.translate(context, text, disambig) + def _translate(context, text, disambig=None): + return text + return QApplication.translate(context, text, disambig) class Progressor: def __init__(self): @@ -104,7 +101,7 @@ self.nextKnownRelativeProgressToBeReached=self.expectedRealiveProgresses[0][1] def __call__(self,line): for (k,v) in self.expectedRealiveProgresses: - if k in line: + if str(k) in str(line): if k=='finished': self.progressBarValue=1.0 return 100 @@ -310,6 +307,10 @@ """ if self.getZip(self.inccombo.currentText())=="-z": return ".".join(self.outFilename.split(".")[:-1])+".zip" + if self.getZip(self.inccombo.currentText())=="-d": + return ".".join(self.outFilename.split(".")[:-1])+".odt" + if self.getZip(self.inccombo.currentText())=="-b": + return ".".join(self.outFilename.split(".")[:-1])+".epub" return self.outFilename def callbackrun(self): @@ -360,6 +361,8 @@ return "-g" def getZip(self, switch): if switch==_translate("MainWindow","LaTeX Source Zip"): return "-z" + if switch==_translate("MainWindow","ODT (Word Processor)"): return "-d" + if switch==_translate("MainWindow","EPUB"): return "-b" return "" def scheduleM2L(self): @@ -377,9 +380,9 @@ # the parameter expect=10000 means that 10000 lines are expected in # stdout. This parameter can be also a pattern compiled as a regular # expression or a callable to filter lines of stdout. - bp=bashProcess(self, cmd=cmd, message=_translate("MainWindow","running mediawiki2latex"), + self.bp=bashProcess(self, cmd=cmd, message=_translate("MainWindow","running mediawiki2latex"), expect=Progressor()) - self.processList.append(bp) + self.processList.append(self.bp) return def closeEvent(self, event): @@ -403,8 +406,8 @@ self.ui.statusbar.showMessage(_translate("MainWindow","The sequence of processes is finished. You can close the window.")) self.t.stop() # end of tick service self.button.setEnabled(True) - self.pbar.setValue(100) self.ui.tabWidget.setCurrentIndex(0) + self.pbar.setValue(100) webbrowser.open('file://{0}'.format(os.path.abspath(self.pdfFile()))) return @@ -413,7 +416,7 @@ User preferences for Mediawiki2latex """ def __init__(self, - mwSource="http://en.wikipedia.org/wiki/Homomorphism", + mwSource="https://en.wikipedia.org/wiki/Homomorphism", ): """ the constructor diff -Nru m2l-pyqt-1.3/src/processes.py m2l-pyqt-1.5/src/processes.py --- m2l-pyqt-1.3/src/processes.py 2016-04-23 16:43:16.000000000 +0000 +++ m2l-pyqt-1.5/src/processes.py 2017-09-13 12:05:50.000000000 +0000 @@ -22,8 +22,8 @@ . """ -from PyQt4.QtCore import * -from PyQt4.QtGui import * +from PyQt5.QtCore import * +from PyQt5.QtWidgets import * import re, collections class bashProcess(QProcess): diff -Nru m2l-pyqt-1.3/src/processTimer.py m2l-pyqt-1.5/src/processTimer.py --- m2l-pyqt-1.3/src/processTimer.py 2014-09-28 15:32:33.000000000 +0000 +++ m2l-pyqt-1.5/src/processTimer.py 2017-09-13 12:05:50.000000000 +0000 @@ -21,8 +21,8 @@ . """ -from PyQt4.QtCore import * -from PyQt4.QtGui import * +from PyQt5.QtCore import * +from PyQt5.QtWidgets import * class processTimer(QTimer):