Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > gnu.groff.bug > #1559

groffer: add "atril" to document viewers

From Ben Pfaff <blp@cs.stanford.edu>
Newsgroups gnu.groff.bug
Subject groffer: add "atril" to document viewers
Date 2019-08-20 16:06 -0700
Message-ID <mailman.547.1566344527.30381.bug-groff@gnu.org> (permalink)
References <20190820230655.GA8387@sigurg.benpfaff.org>

Show all headers | View raw


Atril is the document viewer that comes with the MATE desktop
environment.  It is included in, for example, Debian GNU/Linux and
installed by default when the MATE environment is included.  The
"groffer" program doesn't know about it.  The following patch enables
support.  I'd appreciate it if this patch, or an equivalent one, could
be included in a future release of groff.

It took me a long time to understand the problem because the error
message displayed when "groffer --pdf" cannot find a PDF viewer is
obscure:

    set mode: no suitable display mode found under pdf; at
    /usr/lib/groff/groffer/main_subs.pl line 1077.

Maybe it should display a more appropriate message, such as "cannot find
a viewer for PDF".

diff -up groff-1.22.4/contrib/groffer/groffer.pl\~ groff-1.22.4/contrib/groffer/groffer.pl
--- groff-1.22.4/contrib/groffer/groffer.pl~	2018-10-10 14:44:56.000000000 -0700
+++ groff-1.22.4/contrib/groffer/groffer.pl	2019-08-20 15:46:58.998952715 -0700
@@ -179,18 +179,18 @@ our %Viewer_tty = ('DVI' => [],
 		  'X' => [],
 		 );
 
-our %Viewer_X = ('DVI' => ['kdvi', 'xdvi', 'dvilx'],
+our %Viewer_X = ('DVI' => ['kdvi', 'xdvi', 'dvilx', 'atril'],
 		'HTML' => ['konqueror', 'epiphany'. 'mozilla-firefox',
 			   'firefox', 'mozilla', 'netscape', 'galeon',
 			   'opera', 'amaya','arena', 'mosaic'],
 		'XHTML' => ['konqueror', 'epiphany'. 'mozilla-firefox',
 			   'firefox', 'mozilla', 'netscape', 'galeon',
 			   'opera', 'amaya','arena', 'mosaic'],
-		'PDF' => ['okular', 'kpdf', 'acroread', 'evince',
+		'PDF' => ['okular', 'kpdf', 'acroread', 'evince', 'atril',
 			  'xpdf -z 150', 'gpdf', 'xpdf', 'zathura'.
 			  'epdfview', 'qpdfview', 'apvlv', 'qpdfview',
 			  'kghostview --scale 1.45', 'gv', 'ggv'],
-		'PS' => ['okular', 'evince', 'gv',
+		'PS' => ['okular', 'evince', 'atril', 'gv',
 			 'gs', 'gs_x11', 'ghostscript', 'ghostview',
 			 'kghostview --scale 1.45', 'ggv', 'kpdf'],
 		'TTY' => ['xless'],

Back to gnu.groff.bug | Previous | Next | Find similar | Unroll thread


Thread

groffer: add "atril" to document viewers Ben Pfaff <blp@cs.stanford.edu> - 2019-08-20 16:06 -0700

csiph-web