From 4d391443f53dad9eec3cbe65fc2e8b6e8d669a66 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?G=C3=BCnter=20Milde?= Date: Wed, 11 Jan 2017 18:10:50 +0100 Subject: [PATCH 1/5] configure.py: Add 'evince' as DVI viewer The GNOME document viewer "evince" supports also DVI. See https://wiki.gnome.org/Apps/Evince/SupportedDocumentFormats/ --- lib/configure.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/configure.py b/lib/configure.py index e374673010..4ce398961a 100644 --- a/lib/configure.py +++ b/lib/configure.py @@ -694,7 +694,8 @@ def checkFormatEntries(dtl_tools): \Format pdf7 pdf "PDF (cropped)" "" "%%" "" "document,vector" "" \Format pdf8 pdf "PDF (lower resolution)" "" "%%" "" "document,vector" ""''']) # - checkViewer('a DVI previewer', ['xdvi', 'kdvi', 'okular', 'yap', 'dviout -Set=!m'], + checkViewer('a DVI previewer', ['xdvi', 'kdvi', 'okular', 'evince', + 'yap', 'dviout -Set=!m'], rc_entry = [r'''\Format dvi dvi DVI D "%%" "" "document,vector,menu=export" "application/x-dvi" \Format dvi3 dvi "DVI (LuaTeX)" V "%%" "" "document,vector,menu=export" ""''']) if dtl_tools: From bcf8a40a10f9fd6ed5f23581810fef240d50320f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?G=C3=BCnter=20Milde?= Date: Wed, 11 Jan 2017 18:23:03 +0100 Subject: [PATCH 2/5] configure.py: Add 'xreader' document viewer (evince fork) 'xreader' is the successor of 'evince' by Linux-Mint. It inherits evince's functionaly and adds a traditional UI matching the XFCE, MATE and Cinnamon desktop environments. See: https://de.wikipedia.org/wiki/X-Apps --- lib/configure.py | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) diff --git a/lib/configure.py b/lib/configure.py index 4ce398961a..b7cdf83132 100644 --- a/lib/configure.py +++ b/lib/configure.py @@ -672,19 +672,21 @@ def checkFormatEntries(dtl_tools): # #checkProg('a Postscript interpreter', ['gs'], # rc_entry = [ r'\ps_command "%%"' ]) - checkViewer('a Postscript previewer', ['kghostview', 'okular', 'qpdfview --unique', - 'evince', 'gv', 'ghostview -swap', - 'gsview64', 'gsview32'], + checkViewer('a Postscript previewer', + ['kghostview', 'okular', 'qpdfview --unique', + 'evince', 'xreader', + 'gv', 'ghostview -swap', 'gsview64', 'gsview32'], rc_entry = [r'''\Format eps eps EPS "" "%%" "" "vector" "image/x-eps" \Format eps2 eps "EPS (uncropped)" "" "%%" "" "vector" "" \Format eps3 eps "EPS (cropped)" "" "%%" "" "document" "" \Format ps ps Postscript t "%%" "" "document,vector,menu=export" "application/postscript"''']) # for xdg-open issues look here: http://www.mail-archive.com/lyx-devel@lists.lyx.org/msg151818.html # the MIME type is set for pdf6, because that one needs to be autodetectable by libmime - checkViewer('a PDF previewer', ['pdfview', 'kpdf', 'okular', 'qpdfview --unique', - 'evince', 'kghostview', 'xpdf', 'SumatraPDF', - 'acrobat', 'acroread', 'mupdf', 'gv', - 'ghostview', 'AcroRd32', 'gsview64', 'gsview32'], + checkViewer('a PDF previewer', + ['pdfview', 'kpdf', 'okular', 'qpdfview --unique', + 'evince', 'xreader', 'kghostview', 'xpdf', 'SumatraPDF', + 'acrobat', 'acroread', 'mupdf', + 'gv', 'ghostview', 'AcroRd32', 'gsview64', 'gsview32'], rc_entry = [r'''\Format pdf pdf "PDF (ps2pdf)" P "%%" "" "document,vector,menu=export" "" \Format pdf2 pdf "PDF (pdflatex)" F "%%" "" "document,vector,menu=export" "" \Format pdf3 pdf "PDF (dvipdfm)" m "%%" "" "document,vector,menu=export" "" @@ -694,7 +696,8 @@ def checkFormatEntries(dtl_tools): \Format pdf7 pdf "PDF (cropped)" "" "%%" "" "document,vector" "" \Format pdf8 pdf "PDF (lower resolution)" "" "%%" "" "document,vector" ""''']) # - checkViewer('a DVI previewer', ['xdvi', 'kdvi', 'okular', 'evince', + checkViewer('a DVI previewer', ['xdvi', 'kdvi', 'okular', + 'evince', 'xreader', 'yap', 'dviout -Set=!m'], rc_entry = [r'''\Format dvi dvi DVI D "%%" "" "document,vector,menu=export" "application/x-dvi" \Format dvi3 dvi "DVI (LuaTeX)" V "%%" "" "document,vector,menu=export" ""''']) From 95085724ec7c110b8584d0ca9eb88f82bd1b239e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?G=C3=BCnter=20Milde?= Date: Wed, 11 Jan 2017 20:18:15 +0100 Subject: [PATCH 3/5] configure.py: Add 'xed' editor (gedit fork) 'xed' is the 'gedit/plume' successor by Linux-Mint. It inherits gedit's functionaly and adds a traditional UI matching the XFCE, MATE and Cinnamon desktop environments. See: https://de.wikipedia.org/wiki/X-Apps --- lib/configure.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/lib/configure.py b/lib/configure.py index b7cdf83132..0b4f57f1cf 100644 --- a/lib/configure.py +++ b/lib/configure.py @@ -626,8 +626,10 @@ def checkFormatEntries(dtl_tools): addToRC(imageformats % (iv, ie, iv, ie, iv, ie, iv, ie, iv, ie, iv, ie, iv, ie, iv, ie, iv, ie, iv, ie) ) # - checkViewerEditor('a text editor', ['xemacs', 'gvim', 'kedit', 'kwrite', 'kate', - 'nedit', 'gedit', 'notepad', 'geany', 'leafpad', 'mousepad'], + checkViewerEditor('a text editor', + ['xemacs', 'gvim', 'kedit', 'kwrite', 'kate', + 'nedit', 'gedit', 'notepad', + 'geany', 'leafpad', 'mousepad', 'xed'], rc_entry = [r'''\Format asciichess asc "Plain text (chess output)" "" "" "%%" "" "" \Format docbook sgml DocBook B "" "%%" "document,menu=export" "" \Format docbook-xml xml "DocBook (XML)" "" "" "%%" "document,menu=export" "application/docbook+xml" From 8e65250110cc0003b370c71e27c5713b8051ac0e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?G=C3=BCnter=20Milde?= Date: Thu, 12 Jan 2017 15:35:24 +0100 Subject: [PATCH 4/5] configure.py: Make 'notepad' last in text editor list Place "notepad" at the end of the text editor selection list. * Under Linux, notepad comes with the Windows emulator "wine" but it is not a good choice for the default text editor. * Most Windows users will not have the Linux programs and not see any change. * Windows users with the Windows version of "geany" will see this (syntax highlighting) editor preferred over notepad by default. --- lib/configure.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/lib/configure.py b/lib/configure.py index 0b4f57f1cf..8b502c5d9b 100644 --- a/lib/configure.py +++ b/lib/configure.py @@ -628,8 +628,7 @@ def checkFormatEntries(dtl_tools): # checkViewerEditor('a text editor', ['xemacs', 'gvim', 'kedit', 'kwrite', 'kate', - 'nedit', 'gedit', 'notepad', - 'geany', 'leafpad', 'mousepad', 'xed'], + 'nedit', 'gedit', 'geany', 'leafpad', 'mousepad', 'xed', 'notepad'], rc_entry = [r'''\Format asciichess asc "Plain text (chess output)" "" "" "%%" "" "" \Format docbook sgml DocBook B "" "%%" "document,menu=export" "" \Format docbook-xml xml "DocBook (XML)" "" "" "%%" "document,menu=export" "application/docbook+xml" From bd3e6033db4adad942fc671e4bbd479909d0f334 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?G=C3=BCnter=20Milde?= Date: Thu, 12 Jan 2017 15:42:02 +0100 Subject: [PATCH 5/5] configure.py: Add raster image viewers Add common raster image viewing applications: gwenview: KDE image viewer, eog: Eye of Gnome, the Gnome default viewer, xviewer: Eye of Gnome successor for MATE and Cinnamon, ristretto: XFCE image viewer, gpicview: LXDE image viewer, lximage-qt: QXDE image viewer, xdg-open: generic file handler The problem with xdg-open is, that it calls the browser (firefox) as fallback. This is not good for DVI and PDF, but still better than an editor (Gimp) for raster images. Kee Gimp as last option for viewing, and default choice for editing. --- lib/configure.py | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/lib/configure.py b/lib/configure.py index 8b502c5d9b..2e28c070cd 100644 --- a/lib/configure.py +++ b/lib/configure.py @@ -621,10 +621,14 @@ def checkFormatEntries(dtl_tools): \Format tiff tif TIFF "" "%s" "%s" "" "image/tiff" \Format xbm xbm XBM "" "%s" "%s" "" "image/x-xbitmap" \Format xpm xpm XPM "" "%s" "%s" "" "image/x-xpixmap"''' - path, iv = checkViewerNoRC('a raster image viewer', ['xv', 'kview', 'gimp-remote', 'gimp'], rc_entry = [imageformats]) - path, ie = checkEditorNoRC('a raster image editor', ['gimp-remote', 'gimp'], rc_entry = [imageformats]) - addToRC(imageformats % - (iv, ie, iv, ie, iv, ie, iv, ie, iv, ie, iv, ie, iv, ie, iv, ie, iv, ie, iv, ie) ) + path, iv = checkViewerNoRC('a raster image viewer', + ['xv', 'gwenview', 'kview', + 'eog', 'xviewer', 'ristretto', 'gpicview', 'lximage-qt', + 'xdg-open', 'gimp-remote', 'gimp'], + rc_entry = [imageformats]) + path, ie = checkEditorNoRC('a raster image editor', + ['gimp-remote', 'gimp'], rc_entry = [imageformats]) + addToRC(imageformats % ((iv, ie)*10)) # checkViewerEditor('a text editor', ['xemacs', 'gvim', 'kedit', 'kwrite', 'kate',