Gentoo Archives: gentoo-commits

From: "Michael Weber (xmw)" <xmw@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in app-text/mupdf/files: mupdf-9999-zoom.patch
Date: Mon, 31 Jan 2011 14:45:49
Message-Id: 20110131144535.66CF020054@flycatcher.gentoo.org
1 xmw 11/01/31 14:45:35
2
3 Added: mupdf-9999-zoom.patch
4 Log:
5 Live cvs version for app-text/llpp
6
7 (Portage version: 2.1.9.25/cvs/Linux x86_64)
8
9 Revision Changes Path
10 1.1 app-text/mupdf/files/mupdf-9999-zoom.patch
11
12 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-text/mupdf/files/mupdf-9999-zoom.patch?rev=1.1&view=markup
13 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-text/mupdf/files/mupdf-9999-zoom.patch?rev=1.1&content-type=text/plain
14
15 Index: mupdf-9999-zoom.patch
16 ===================================================================
17 Michael Weber <xmw at gentoo dot org> 09/09/2010
18
19 --- mupdf-9999/apps/pdfapp.c.orig
20 +++ mupdf-9999/apps/pdfapp.c
21 @@ -650,6 +650,20 @@
22 pdfapp_showpage(app, 0, 1, 1);
23 break;
24
25 + case '_': // zoom to default resolution
26 + app->resolution = 72;
27 + pdfapp_showpage(app, 0, 1, 1);
28 + break;
29 +
30 + case 'z': // zoom to fit window
31 + case 'Z': // zoom to fill window
32 + if ( ( c == 'Z' ) ^ ( app->image->w * app->winh > app->winw * app->image->h ) )
33 + app->resolution = ( app->resolution * app->winw ) / app->image->w;
34 + else
35 + app->resolution = ( app->resolution * app->winh ) / app->image->h;
36 + pdfapp_showpage(app, 0, 1, 1);
37 + break;
38 +
39 case 'L':
40 app->rotate -= 90;
41 pdfapp_showpage(app, 0, 1, 1);
42 @@ -773,6 +787,7 @@
43 break;
44
45 case 'b':
46 + case '\b': //backspace
47 panto = DONT_PAN;
48 if (app->numberlen > 0)
49 app->pageno -= atoi(app->number);
50 @@ -781,6 +796,7 @@
51 break;
52
53 case ' ':
54 + case 'f':
55 panto = DONT_PAN;
56 if (app->numberlen > 0)
57 app->pageno += atoi(app->number);
58 --- mupdf-9999/debian/mupdf.1.orig
59 +++ mupdf-9999/debian/mupdf.1
60 @@ -1,4 +1,4 @@
61 -.TH MUPDF 1 "March 15, 2010"
62 +.TH MUPDF 1 "September 9, 2010"
63 .\" Please adjust this date whenever revising the manpage.
64 .SH NAME
65 mupdf \- MuPDF is a lightweight PDF viewer written in portable C
66 @@ -37,6 +37,15 @@
67 .B \+, \-
68 Zoom in or out.
69 .TP
70 +.B _
71 +Reset zoom to default (72dpi).
72 +.TP
73 +.B z
74 +Zoom page size to fit into the window frame.
75 +.TP
76 +.B Z
77 +Zoom page size to fill the window frame.
78 +.TP
79 .B w
80 Shrinkwrap window to fit the page.
81 .TP