Compare commits

...
Sign in to create a new pull request.
Author SHA1 Message Date
Reuben Green
e6eb371942 prevent segfaults when no document loaded
See the issue report for a description of the bug. The root cause is
dereferencing of NULL pointers, specifically the priv->document member of
EvWindow structures when no document is loaded. This commit adds checks
for a NULL value of priv->document at all the points in the file
shell/ev-window.c where this pointer was previously dereferenced without
being checked.

Fixes 357 (https://github.com/mate-desktop/atril/issues/357)
2019-08-06 22:53:23 +02:00
Pablo Barciela
d65a7b260a travis: use Debian Buster which has 1.20 2019-05-25 16:38:44 +02:00
raveit65
c3bb50fa90 travis: use f28 and disable archlinux 2019-05-21 18:53:13 +02:00
raveit65
bb0203bb6b add travis-CI support 2019-03-07 19:49:00 +01:00
rbuj
f16828cdba Remove generated files 2019-02-09 09:24:45 +01:00
raveit65
08b7fef125 tx: sync with fixed translations from transifex 2019-02-05 16:41:49 +01:00
raveit65
1a8eefc4f4 tx: update resource file for transifex 2019-02-03 14:55:20 +01:00
rbuj
31b0fe8ffa Add pixbuf, tiff and xps TypeDescription to POTFILES.in 2019-02-03 14:48:26 +01:00
monsta
966e36f973 move appdata to metainfo directory
fixes https://github.com/mate-desktop/atril/issues/292
2019-01-21 16:38:21 +03:00
Eli Schwartz
7332ba89c1 comics: fix incorrect mimetype saying to open and thumbnail all rarfiles
application/vnd.rar is for files with the .rar extension,
application/vnd.comicbook-rar is the subtype for files with the .cbr
extension.
2018-12-20 21:01:53 +01:00
raveit65
93f6b1f234 release 1.20.3 2018-12-11 11:56:31 +01:00
raveit65
1ca30efc3a tx: sync with transifex 2018-12-11 11:56:31 +01:00
raveit65
a44081835f disable deprecation warnings for distcheck 2018-12-11 11:56:31 +01:00
raveit65
bba0eaf668 tx: fix typo 2018-12-05 09:56:15 +01:00
raveit65
8bf0fa7ea3 Use make functions for HELP_LINGUAS 2018-11-15 17:03:16 +01:00
Pablo Barciela
413f6ccdfc comics: support application/vnd.rar MIME type
Fixes https://github.com/mate-desktop/atril/issues/341
2018-11-13 11:28:26 +01:00
Germán Poo-Caamaño
91d5b0f695 shell: Save document to the same path it was opened from
When annotating or filling a form in a document, this must be saved
    as a different document as atril does not overwrite documents.
    The user can expect to store the modified file in the same place
    than the original document, except when the document lives in
    a temporary directory (e.g. downloaded automatically with a web
    browser), in whose case it must fallback to the Documents
    directory (if set) or the the home directory.

    Previously, atril assumed the latest directory used, or the place
    where an image or attachment was stored last. Such behaviour is
    confusing because the latest place opened might have no relation
    with the document modified.

    Fixes https://bugzilla.gnome.org/show_bug.cgi?id=767611
    Adapted from 319a6d49
2018-10-26 23:03:18 +02:00
Giovanni Campagna
f4b9c800c5 Reduce the chattiness of atril daemon
Use g_debug instead of g_printerr for debug warnings that happen
during normal operation. This way messages are suppressed, unless
the G_MESSAGES_DEBUG variable is set, and we avoid filling everyone's
journal with repetitive debugging info.

https://bugzilla.gnome.org/show_bug.cgi?id=723972

origin commit:
707725e

fixes https://github.com/mate-desktop/atril/issues/315
2018-10-26 22:51:35 +02:00
Colomban Wendling
a7d0b8dfb7 EvView: Fix cursor movement when logical and visual line order differs
Make sure not to move the caret in the wrong direction when restoring
the visual line X offset, in case the visual and logical order is
slightly different.

The algorithm used to move the cursor on the next line and restore the
X position across lines works as follows:

1. Move `cursor_offset` to the next line by incrementing it until
   reaching a line break;
2. Find the Y coordinate corresponding to the new cursor_offset;
3. Find the text closest to the new Y coordinate and the previous X
   coordinate.
4. Move cursor_offset to the text at this new (X, Y) location.

The issue lies in step 3, which can find a position on a different line
than expected in case several lines have a nearly the same Y position.

Evince references:
* https://gitlab.gnome.org/GNOME/evince/issues/889
* https://gitlab.gnome.org/GNOME/evince/merge_requests/81
* dddd98b4c7
2018-10-20 18:06:52 +02:00
raveit65
f4a771536e tx: improve makepot 2018-10-01 17:12:14 +02:00
rbuj
2f89c60106 Update atril_start_window.png 2018-09-29 09:06:05 +02:00
raveit65
e3574492af tx: update translation source 2018-09-27 20:58:09 +02:00
rbuj
bf74341ab8 moveable (older spelling) -> movable 2018-09-27 20:48:19 +02:00
raveit65
5943a4bf07 tx: fix help link of atril user-quide
fixes 1b4ce12
2018-09-26 17:27:57 +02:00
raveit65
1b4ce120ba tx: add resource for transifex 2018-09-18 11:01:43 +02:00
raveit65
f4e107c800 tx: add atril-user-guide to transifex config
and correct path of normal .pot file
2018-09-18 10:42:05 +02:00
rbuj
81934df6a2 Update Catalan screenshot 2018-09-16 17:40:50 +02:00
raveit65
23e7c60915 release 1.20.2 2018-06-11 20:04:50 +02:00
raveit65
a6c6e13f7a sync with transifex 2018-06-11 19:49:56 +02:00
raveit65
d980c127b6 update atril.pot 2018-06-11 19:21:35 +02:00
monsta
b365c22e4a disable StartPresentation action in fullscreen if document has no pages
this also disables it when no document is loaded
2018-04-08 13:15:50 +02:00
monsta
e710942aab disable ViewPresentation action if document has no pages
follow-up to 9c08159f6c - this action
should be disabled when e.g. a truncated pdf is loaded
2018-04-08 13:15:36 +02:00
Carlos Garcia Campos
73ca24244f libdocument: Use gdk_pixbuf_get_from_surface()
....instead of our own implementation

origin commit:
https://git.gnome.org/browse/evince/commit/?h=gnome-3-0&id=91a30f4
2018-04-08 13:15:23 +02:00
Christian Persch
62ca1c0f5e thumbnailer: Remove unused code
The code to overlay an icon is unused since commit
https://git.gnome.org/browse/evince/commit/?id=808285c

origin commit:
https://git.gnome.org/browse/evince/commit/?id=171918f
2018-04-08 13:15:04 +02:00
Carlos Garcia Campos
027a658112 view: Fix page background rendering while loading
origin commit:
https://git.gnome.org/browse/evince/commit/?h=gnome-3-8&id=38528f9
2018-04-07 10:07:45 +02:00
Carlos Garcia Campos
df069ae284 libdocument: Deprecate misc_get_page_border_size()
.... and misc_paint_one_page()

origin commit:
https://git.gnome.org/browse/evince/commit/?h=gnome-3-8&id=a610d49
2018-04-07 10:07:27 +02:00
William Jon McCann
c09efef34a view: Use a rendered frame instead of custom border
So it can be styled with CSS.

https://bugzilla.gnome.org/show_bug.cgi?id=653294

origin commit:
https://git.gnome.org/browse/evince/commit/?h=gnome-3-8&id=7a6b53a
https://git.gnome.org/browse/evince/commit/?h=gnome-3-8&id=4657961
2018-04-07 10:07:11 +02:00
Jason Crain
0d841130ff a11y: Return correct start and end offsets
This modifies ev_page_accessible_get_range_for_boundary to ensure that
the start and end offsets it returns are within the allowed range.

https://bugzilla.gnome.org/show_bug.cgi?id=777992

origin commit:
https://git.gnome.org/browse/evince/commit/?id=e95a4e3
2018-04-05 17:51:24 +02:00
Jason Crain
e3ce0a476a a11y: Fix crash with Orca screen reader
ev_page_accessible_get_substring gets called with out of bounds values
leading to a crash.  Clamp start_offset to a valid range.

https://bugzilla.gnome.org/show_bug.cgi?id=777992

origin commit:
https://git.gnome.org/browse/evince/commit/?id=b34f357
2018-04-05 17:51:07 +02:00
raveit65
4065873142 libview: drop deprecated unneeded code
inspired by:
https://git.gnome.org/browse/evince/commit/?h=gnome-3-8&id=a56186e
2018-04-04 12:33:36 +02:00
Carlos Garcia Campos
bb4e4b78eb ev-loading-message: Remove unused variables
origin commit:

https://git.gnome.org/browse/evince/commit/?h=gnome-3-8&id=3fd4162
2018-04-04 11:42:14 +02:00
monsta
05b1f12040 libview: fix text selection with mouse in annotation window
taken from:
91ac78bc58
2018-04-02 17:06:10 +02:00
raveit65
4ecb05838d libview: fix build without epub
Fixes https://github.com/mate-desktop/atril/issues/308
2018-03-27 15:09:27 +03:00
raveit65
82db9cef2c release 1.20.1 2018-03-26 16:26:57 +02:00
Christian Persch
6fe65745b5 shell: Don't dist generated files 2018-03-26 16:26:57 +02:00
Lubos Koudelka
c238f519ce Disable view presentation if there is no document.
otherwise atril crashes

https://bugzilla.gnome.org/show_bug.cgi?id=685591

origin commit:
https://git.gnome.org/browse/evince/commit/?h=gnome-3-8&id=b4bf316
2018-03-26 15:37:02 +02:00
William Jon McCann
50bdf3f446 Allow changing the page of a presentation
https://bugzilla.gnome.org/show_bug.cgi?id=693749

origin commit:
https://git.gnome.org/browse/evince/commit/?h=gnome-3-8&id=53d6a3
2018-03-26 15:36:49 +02:00
Carlos Garcia Campos
454ca8b142 libview: Fix goto window in presentation mode
It wasn't correctly set as modal.

origin commit:
https://git.gnome.org/browse/evince/commit/?h=gnome-3-2&id=987aab6
2018-03-26 15:36:36 +02:00
raveit65
b9dcc2af55 libview: avoid deprecated gdk_screen_get_monitor
....in ev-view-presentation

This was introduced again in previous commit.
2018-03-26 15:36:24 +02:00
Owen W. Taylor
c0cf2c6824 EvPresentationView: Render correctly on hi-dpi displays
Create rendering jobs with a scale that incorporate the scale factor of
the widget, and then use cairo_surface_set_device_scale() to make the
resulting surfaces render at the correct size. Handle changes to the scale
factor both for the cached surfaces, and also for the monitor dimensions,
which are reported in scaled coordinates.

https://bugzilla.gnome.org/show_bug.cgi?id=723431

origin commit:
https://git.gnome.org/browse/evince/commit/?id=37c13b
2018-03-26 15:36:10 +02:00
Carlos Garcia Campos
14c88f266b libview: Fix g_return condition in set_device_scale_on_surface()
Fail when device scale is not 1 if hidpi is not available, we were doing
the opposite.

origin commit:
https://git.gnome.org/browse/evince/commit/?id=90a258
2018-03-26 15:36:00 +02:00
Owen W. Taylor
58486bb360 EvView: render correctly on hi-dpi displays
Make EvPixbufCache generate surfaces with extra resolution based on
gtk_widget_get_scale_factor(). Handle cairo surfaces with a device
scale in ev_view_draw(). Trigger an update of the pixbuf cache when
the scale factor changes.

https://bugzilla.gnome.org/show_bug.cgi?id=723431

origin commit:
https://git.gnome.org/browse/evince/commit/?id=a612f8
2018-03-26 15:35:47 +02:00
raveit65
f4b94ea0e1 tx: update config with branch specific resoures 2018-03-23 12:10:19 +01:00
raveit65
02970c6cc1 libview: use css to draw the background of presentations
With the recent changes in gtk+, widgets have to draw themselves,
causing the current use of gdk_window_set_background_rgba to fail.

https://bugzilla.gnome.org/show_bug.cgi?id=765557

view: Redraw ev-view-presentation when setting normal and black mode.

The black and normal mode are the same from the CSS point of view.
The difference is that in the draw function the page is not drawn
in black mode. Hence, we need to explicitly queue a redraw in these
cases. Since setting the white mode add a CSS class, this queues
the redraw for us.

Fixes https://bugzilla.gnome.org/show_bug.cgi?id=772390.

origin commits:
https://git.gnome.org/browse/evince/commit/?id=2b352b3
https://git.gnome.org/browse/evince/commit/?id=b3f49f4

Fixes https://github.com/mate-desktop/atril/issues/232
2018-03-22 21:45:13 +01:00
Carlos Garcia Campos
1e531cb51e Move custom css to a file compiled as a gresource
origin commit:
https://git.gnome.org/browse/evince/commit/shell?h=gnome-3-6&id=65fa4ff
2018-03-22 21:44:58 +01:00
Christian Persch
c7fcfa103e shell: Use GResource for data files
origin commit:
https://git.gnome.org/browse/evince/commit/?h=gnome-3-6&id=ba06a5e
2018-03-22 21:44:49 +01:00
Christian Persch
e0f26b9dbe toolbar-editor: Add methods to load from GResource
origin commit:
https://git.gnome.org/browse/evince/commit/?h=gnome-3-6&id=8c240d9
2018-03-22 21:44:39 +01:00
Christian Persch
6b84d6fde5 previewer: Use GResource for data files
origin commit:
https://git.gnome.org/browse/evince/commit/?h=gnome-3-6&id=45be486
2018-03-22 21:44:27 +01:00
Christian Persch
95437d1825 build: Add configure check for glib-compile-resources
origin commit:
https://git.gnome.org/browse/evince/commit/?id=119e6ac
2018-03-22 21:44:17 +01:00
raveit65
eaee969096 update resource for translations 2018-03-22 10:55:50 +01:00
raveit65
c417e7c492 fix distcheck 2018-03-22 10:47:12 +01:00
Marek Kasik
3fddbe735f libview: Check number of pages when processing button events
Check whether there are some pages in the opened document
when processing button events to avoid crash.

https://bugzilla.gnome.org/show_bug.cgi?id=769700

origin commit:
https://git.gnome.org/browse/evince/commit/?id=f30aed7
2018-03-22 08:45:27 +01:00
Joanmarie Diggs
10d764dae5 libview: Add check for pageless documents to ev_view_accessible_focus_changed
Without this check, Evince will crash when opening a document that, for
whatever reason, has no pages.

https://bugzilla.gnome.org/show_bug.cgi?id=731046

origin commit:
https://git.gnome.org/browse/evince/commit/?id=c0ecc95
2018-03-22 08:45:14 +01:00
Germán Poo-Caamaño
aa3bcfa731 libview: Check number of pages on ev_view_document_changed_cb
Fix crash on corrupted PDF with no pages.

Thanks to Juha Kylmänen from OUSPG who were testing robutness.
(CVE-2013-3718).

libview: Fix warning on ev_view_document_changed_cb
There was an introduction of a warning when fixing the bug
https://bugzilla.gnome.org/show_bug.cgi?id=701302

If ev_view_document_changed_cb () is emitted when there
is no previous document, the check fails.

This patch change the order of the condition checks.

origin commits:
https://git.gnome.org/browse/evince/commit/?h=gnome-3-8&id=62b1585
https://git.gnome.org/browse/evince/commit/?h=gnome-3-8&id=5431595
2018-03-22 08:44:47 +01:00
Carlos Garcia Campos
6346384963 Use GtkOverlay to show the loading message
Remove the EvLoadingWindow from libview and move the implementation to
the shell using a EvLoadingMessage widget and GtkOverlay. EvView has now
a is-loading property that allows the users to implement their own
loading notification system. This fixes several realted to the loading
window.

origin commit:
https://git.gnome.org/browse/evince/commit/?h=gnome-3-8&id=035c1cb
2018-03-22 08:44:32 +01:00
Christian Persch
7d0ac84307 shell: Remove unused marshalers
Since there was only the one, also remove the whole glib-genmarshal setup.
If we ever need another non-stock marshaler, we'll just use the new glib
generic marshaler.

origin commit:
https://git.gnome.org/browse/evince/commit/?h=gnome-3-6&id=fe7f842
2018-03-22 08:44:18 +01:00
Christian Persch
c99d7683a8 thumbnailer: Send error messages to stderr
Use g_printerr, not g_print.

origin commit:
https://git.gnome.org/browse/evince/commit/?h=gnome-3-6&id=3b59d64
2018-03-22 08:44:05 +01:00
Christian Persch
21073d44b5 shell: Use GtkApplication to inhibit the screensaver
Remove TotemScrsaver copy, and use GtkApplication inhibition instead.

origin commit:
https://git.gnome.org/browse/evince/commit/?h=gnome-3-6&id=612701f
2018-03-22 08:43:51 +01:00
Christian Persch
674a6b31d3 shell: Port to GtkApplication
origin commit:
https://git.gnome.org/browse/evince/commit/?h=gnome-3-6&id=b999bdd
2018-03-22 08:43:35 +01:00
Christian Persch
b0f83ee776 shell: Use g_printerr instead of g_warning
These are really runtime errors, not warnings, so just use g_printerr.

origin commit:
https://git.gnome.org/browse/evince/commit/?id=adbed8b
2018-03-22 08:43:22 +01:00
Christian Persch
0884be6232 daemon: Port to GApplication
origin commit:
https://git.gnome.org/browse/evince/commit/?h=gnome-3-6&id=1b3d4dd
2018-03-22 08:43:08 +01:00
Christian Persch
3728fb7446 daemon: Use gdbus-codegen for the org.mate.atril.Daemon interface
origin commit:
https://git.gnome.org/browse/evince/commit/?h=gnome-3-6&id=1aac15e
2018-03-22 08:42:47 +01:00
Christian Persch
e2420ea857 shell: Use gdbus-codegen for the org.mate.atril.Window interface
origin commit:
https://git.gnome.org/browse/evince/commit/?h=gnome-3-6&id=5141dcb
2018-03-22 08:42:30 +01:00
Christian Persch
18a20e89f7 shell: Use gdbus-codegen for the org.mate.atril.Application interface
origin commit:
https://git.gnome.org/browse/evince/commit/?h=gnome-3-6&id=c9aada8
2018-03-22 08:42:19 +01:00
Piiit
e4f8fce987 libview: save inverted colors in a document
The web-view callback for inverted colors got called, and if it did not find a web-view open
it defaulted to FALSE for inverted colors.

origin commit:
abb5060
https://github.com/linuxmint/xreader/issues/38
2018-03-19 09:43:04 +01:00
raveit65
6217a89c6f Save/restore context when getting colors for a different state
Getting colors for a state different from the current state of the
corresponding widget without saving the context might trigger an
invalidation and a redraw. Because this was happening from the draw
function this resulted in a redraw loop and constant high CPU usage.

This could be triggered by selecting text or searching.

https://bugzilla.gnome.org/show_bug.cgi?id=755442

inspired by:
https://git.gnome.org/browse/evince/commit/?id=1987f04
e76a18d
2018-03-19 09:42:45 +01:00
raveit65
56e08ae002 update pot file for translations 2018-03-16 18:10:39 +01:00
raveit65
27f459a770 epub: allow to save epub documents
inspired by:
https://github.com/linuxmint/xreader/commit/63a28f
https://github.com/linuxmint/xreader/issues/165
2018-03-16 18:05:20 +01:00
Mickael Albertus
bd799f45f1 epub: fix loading epub thumbnails
origin commit:
6ed0ee1

Note: origin commit causes some serious build warnings,
......fixed.
2018-03-16 18:04:56 +01:00
raveit65
8770730b64 shell: fix menu-accel for inverted colors
fixes conflict with zoom_in
2018-03-16 18:04:20 +01:00
raveit65
1c2e9ea54f shell: add keypad accels for zoom_reset 2018-03-16 18:03:55 +01:00
Lars Mueller
7619dc678f Add zoom reset
origin commit:
43acb8f
2018-03-16 18:03:35 +01:00
Pablo Barciela
58e7446290 avoid deprecated GtkStock 2018-03-16 18:03:09 +01:00
Germán Poo-Caamaño
005d88500d Check legal boundaries of accessible pages
Fixes https://github.com/mate-desktop/atril/issues/302

Keep the accessible view end page under the limits of the document.
Sometimes when a document is reloaded, it may have less pages making
the end page higher than the actual number of pages.

Fix end_page reset after reload a page

When a document is reloaded, and the accessible end_page is higher
than the number of pages, it must be re-initialized to the number
of pages minus one because it refers to elements in an array.

Fix https://bugzilla.gnome.org/show_bug.cgi?id=735744

origin commits:
https://git.gnome.org/browse/evince/commit/?id=feff531
https://git.gnome.org/browse/evince/commit/?id=e6e0d29
2018-03-16 16:18:47 +01:00
raveit65
83efd99baa tx: add makepot and move .pot file to srcdir 2018-03-15 18:30:45 +01:00
raveit65
4f0467b225 add atril.pot for auto-update translations 2018-03-12 16:39:59 +01:00
raveit65
42e6a5f3de transifex: set minimum_perc and type in config file 2018-03-11 15:31:16 +01:00
316 changed files with 236605 additions and 46786 deletions

141
.travis.yml Normal file
View file

@ -0,0 +1,141 @@
# vim: set ts=2 sts=2 sw=2 expandtab :
dist: xenial
sudo: required
language: bash
services:
- docker
before_install:
- curl -Ls -o docker-build https://github.com/mate-desktop/mate-dev-scripts/raw/master/travis/docker-build
- chmod +x docker-build
install:
- sudo apt-get install -y python3-pip python3-setuptools
- sudo pip3 install --upgrade pip
- sudo pip install PyGithub
- ./docker-build --name ${DISTRO} --config .travis.yml --install
script:
- ./docker-build --name ${DISTRO} --verbose --config .travis.yml --build autotools
env:
# - DISTRO="archlinux/base"
- DISTRO="debian:buster"
- DISTRO="fedora:28"
- DISTRO="ubuntu:18.10"
##########################################################
# THE FOLLOWING LINES IS USED BY docker-build
##########################################################
requires:
archlinux:
# Useful URL: https://git.archlinux.org/svntogit/community.git/tree/atril
- caja
- djvulibre
- gcc
- git
- gobject-introspection
- intltool
- itstool
- libgxps
- make
- mate-common
- poppler-glib
- texlive-bin
- webkit2gtk
- which
- yelp-tools
debian:
# Useful URL: https://github.com/mate-desktop/debian-packages
# Useful URL: https://salsa.debian.org/debian-mate-team/atril
- git
- gobject-introspection
- intltool
- libcaja-extension-dev
- libdjvulibre-dev
- libgail-3-dev
- libgirepository1.0-dev
- libglib2.0-dev
- libgtk-3-dev
- libgxps-dev
- libkpathsea-dev
- libpoppler-glib-dev
- libsecret-1-dev
- libsm-dev
- libspectre-dev
- libtiff-dev
- libwebkit2gtk-4.0-dev
- libx11-dev
- libxml2-dev
- lsb-release
- make
- mate-common
- xsltproc
- yelp-tools
- zlib1g-dev
fedora:
# Useful URL: https://src.fedoraproject.org/cgit/rpms/atril.git
- cairo-gobject-devel
- caja-devel
- desktop-file-utils
- djvulibre-devel
- gcc
- gcc-c++
- git
- gobject-introspection-devel
- gtk3-devel
- libXt-devel
- libglade2-devel
- libgxps-devel
- libjpeg-turbo-devel
- libsecret-devel
- libspectre-devel
- libtiff-devel
- make
- mate-common
- poppler-glib-devel
- redhat-rpm-config
- texlive-lib-devel
- webkitgtk4-devel
- yelp-tools
ubuntu:
- git
- gobject-introspection
- intltool
- libcaja-extension-dev
- libdjvulibre-dev
- libgail-3-dev
- libgirepository1.0-dev
- libglib2.0-dev
- libgtk-3-dev
- libgxps-dev
- libkpathsea-dev
- libpoppler-glib-dev
- libsecret-1-dev
- libsm-dev
- libspectre-dev
- libtiff-dev
- libwebkit2gtk-4.0-dev
- libx11-dev
- libxml2-dev
- lsb-release
- make
- mate-common
- xsltproc
- yelp-tools
- zlib1g-dev
variables:
- CFLAGS="-Wall -Werror=format-security"
before_scripts:
- if [ ${DISTRO_NAME} == "debian" ];then
- curl -Ls -o debian.sh https://github.com/mate-desktop/mate-dev-scripts/raw/master/travis/debian.sh
- bash ./debian.sh
- fi
after_scripts:
- make distcheck

View file

@ -1,7 +1,16 @@
[main]
host = https://www.transifex.com
[MATE.atril]
[MATE.1-20--atril]
file_filter = po/<lang>.po
source_file = po/atril.pot
source_file = atril.pot
source_lang = en
type = PO
minimum_perc = 2
[MATE.1-20--atril-user-guide]
file_filter = help/<lang>/<lang>.po
source_file = help/atril.pot
source_lang = en
type = PO
minimum_perc = 2

View file

@ -82,7 +82,8 @@ DISTCHECK_CONFIGURE_FLAGS = \
--enable-gtk-doc \
--disable-caja \
--disable-tests \
--disable-silent-rules
--disable-silent-rules \
CFLAGS='-Wno-deprecated-declarations'
distuninstallcheck_listfiles = find . -type f -print | grep -v /share/mate/help/ | grep -v \.omf

69
NEWS
View file

@ -1,3 +1,72 @@
### atril 1.20.3
* Translations update
* Use make functions for HELP_LINGUAS
* comics: support application/vnd.rar MIME type
* shell: Save document to the same path it was opened from
* Reduce the chattiness of atril daemon
* EvView: Fix cursor movement when logical and visual line order differs
* Update atril_start_window.png
* moveable (older spelling) -> movable
* tx: add atril-user-guide to transifex config
* Update Catalan screenshot
### atril 1.20.2
* Translations update
* disable StartPresentation action in fullscreen if document has no pages
* disable ViewPresentation action if document has no pages
* libdocument: Use gdk_pixbuf_get_from_surface()
* thumbnailer: Remove unused code
* view: Fix page background rendering while loading
* libdocument: Deprecate misc_get_page_border_size()
* view: Use a rendered frame instead of custom border
* a11y: Return correct start and end offsets
* a11y: Fix crash with Orca screen reader
* libview: drop deprecated unneeded code
* ev-loading-message: Remove unused variables
* libview: fix text selection with mouse in annotation window
* libview: fix build without epub
### atril 1.20.1
* Disable view presentation if there is no document.
* Allow changing the page of a presentation
* libview: Fix goto window in presentation mode
* libview: avoid deprecated gdk_screen_get_monitor
* EvPresentationView: Render correctly on hi-dpi displays
* libview: Fix g_return condition in set_device_scale_on_surface()
* EvView: render correctly on hi-dpi displays
* libview: use css to draw the background of presentations
* Move custom css to a file compiled as a gresource
* shell: Use GResource for data files
* toolbar-editor: Add methods to load from GResource
* previewer: Use GResource for data files
* build: Add configure check for glib-compile-resources
* update resource for translations
* libview: Check number of pages when processing button events
* libview: Add check for pageless documents to ev_view_accessible_focus_changed
* libview: Check number of pages on ev_view_document_changed_cb
* Use GtkOverlay to show the loading message
* shell: Remove unused marshalers
* thumbnailer: Send error messages to stderr
* shell: Use GtkApplication to inhibit the screensaver
* shell: Port to GtkApplication
* shell: Use g_printerr instead of g_warning
* daemon: Port to GApplication
* daemon: Use gdbus-codegen for the org.mate.atril.Daemon interface
* shell: Use gdbus-codegen for the org.mate.atril.Window interface
* shell: Use gdbus-codegen for the org.mate.atril.Application interface
* libview: save inverted colors in a document
* Save/restore context when getting colors for a different state
* epub: allow to save epub documents
* epub: fix loading epub thumbnails
* shell: fix menu-accel for inverted colors
* shell: add keypad accels for zoom_reset
* Add zoom reset
* avoid deprecated GtkStock
* Check legal boundaries of accessible pages
### atril 1.20.0
* Translations update

1864
atril.pot Normal file

File diff suppressed because it is too large Load diff

View file

@ -1,4 +1,4 @@
[Atril Backend]
Module=comicsdocument
_TypeDescription=Comic Books
MimeType=application/x-cbr;application/x-cbz;application/x-cb7;application/x-cbt;application/vnd.comicbook+zip;
MimeType=application/x-cbr;application/x-cbz;application/x-cb7;application/x-cbt;application/vnd.comicbook+zip;application/vnd.comicbook-rar;

View file

@ -124,9 +124,10 @@ epub_document_thumbnails_get_thumbnail (EvDocumentThumbnails *document,
cairo_surface_t *webpage;
GdkPixbuf *thumbnailpix = NULL ;
gint width,height;
epub_document_thumbnails_get_dimensions(document,rc,&width,&height);
webpage = ev_document_misc_surface_rotate_and_scale(rc->page->backend_page,width,height,0);
thumbnailpix = ev_document_misc_pixbuf_from_surface(webpage);
epub_document_thumbnails_get_dimensions (document, rc, &width, &height);
webpage = ev_document_misc_surface_rotate_and_scale (rc->page->backend_page,
width, height, 0);
thumbnailpix = ev_document_misc_pixbuf_from_surface (webpage);
return thumbnailpix;
}
@ -351,7 +352,11 @@ epub_document_save (EvDocument *document,
{
EpubDocument *epub_document = EPUB_DOCUMENT (document);
return ev_xfer_uri_simple (epub_document->archivename, uri, error);
gchar *source_uri = g_filename_to_uri (epub_document->archivename, NULL, error);
if (source_uri == NULL)
return FALSE;
return ev_xfer_uri_simple (source_uri, uri, error);
}
static int

View file

@ -4,7 +4,7 @@
m4_define([ev_major_version], [1])
m4_define([ev_minor_version], [20])
m4_define([ev_micro_version], [0])
m4_define([ev_micro_version], [3])
m4_define([ev_extra_version], [])
m4_define([ev_version], [ev_major_version.ev_minor_version.ev_micro_version()ev_extra_version])
@ -59,8 +59,6 @@ AC_PROG_CXX
AC_STDC_HEADERS
AM_PROG_LIBTOOL
AC_PROG_SED
AC_PATH_PROG([GLIB_GENMARSHAL], [glib-genmarshal])
AC_PATH_PROG([GLIB_MKENUMS], [glib-mkenums])
MATE_MAINTAINER_MODE_DEFINES
MATE_COMPILE_WARNINGS
@ -113,6 +111,34 @@ PKG_CHECK_MODULES(GMODULE, gmodule-2.0 >= $GLIB_REQUIRED)
PKG_CHECK_MODULES([SHELL_CORE],[libxml-2.0 >= $LIBXML_REQUIRED gtk+-3.0 >= $GTK_REQUIRED gio-2.0 >= $GLIB_REQUIRED gthread-2.0 x11])
# ***************
# Build utilities
# ***************
AC_ARG_VAR([GLIB_GENMARSHAL],[the glib-genmarschal programme])
AC_PATH_PROG([GLIB_GENMARSHAL],[glib-genmarshal],[])
if test -z "$GLIB_GENMARSHAL"; then
AC_MSG_ERROR([glib-genmarshal not found])
fi
AC_ARG_VAR([GLIB_MKENUMS],[the glib-mkenums programme])
AC_PATH_PROG([GLIB_MKENUMS],[glib-mkenums],[])
if test -z "$GLIB_MKENUMS"; then
AC_MSG_ERROR([glib-mkenums not found])
fi
AC_ARG_VAR([GLIB_COMPILE_RESOURCES],[the glib-compile-resources programme])
AC_PATH_PROG([GLIB_COMPILE_RESOURCES],[glib-compile-resources],[])
if test -z "$GLIB_COMPILE_RESOURCES"; then
AC_MSG_ERROR([glib-compile-resources not found])
fi
AC_ARG_VAR([XMLLINT],[the xmllint programme])
AC_PATH_PROG([XMLLINT],[xmllint],[])
if test -z "$XMLLINT"; then
AC_MSG_ERROR([xmllint not found])
fi
# Although GTK+ 3.10 includes hi-dpi functionality, it does not require a cairo with
# cairo_surface_set_device_scale(), which we also need if we're to support hi-dpi,
# so we need check for that explicity.
@ -144,9 +170,15 @@ AS_IF([test "x$found_zlib" = "xno"], [
AC_SUBST(ZLIB_LIBS)
])
dnl
dnl SM client
dnl
AC_ARG_VAR([GDBUS_CODEGEN],[the gdbus-codegen programme])
AC_PATH_PROG([GDBUS_CODEGEN],[gdbus-codegen],[])
if test -z "$GDBUS_CODEGEN"; then
AC_MSG_ERROR([gdbus-codegen not found])
fi
# *********
# SM client
# *********
PKG_CHECK_MODULES([SMCLIENT],[gtk+-3.0 gthread-2.0 sm >= 1.0.0])
AC_SUBST([SMCLIENT_CFLAGS])
@ -607,7 +639,7 @@ if test "x$enable_tiff" = "xyes"; then
ATRIL_MIME_TYPES="${ATRIL_MIME_TYPES}image/tiff;"
fi
if test "x$enable_comics" = "xyes"; then
ATRIL_MIME_TYPES="${ATRIL_MIME_TYPES}application/x-cbr;application/x-cbz;application/x-cb7;application/x-cbt;application/vnd.comicbook+zip;"
ATRIL_MIME_TYPES="${ATRIL_MIME_TYPES}application/x-cbr;application/x-cbz;application/x-cb7;application/x-cbt;application/vnd.comicbook+zip;application/vnd-comicbook.rar;"
fi
if test "x$enable_pixbuf" = "xyes"; then
ATRIL_MIME_TYPES="${ATRIL_MIME_TYPES}image/*;"
@ -682,7 +714,6 @@ cut-n-paste/Makefile
cut-n-paste/smclient/Makefile
cut-n-paste/toolbar-editor/Makefile
cut-n-paste/zoom-control/Makefile
cut-n-paste/totem-screensaver/Makefile
cut-n-paste/synctex/Makefile
data/atril.desktop.in
data/Makefile

View file

@ -1,3 +1,3 @@
SUBDIRS = zoom-control toolbar-editor totem-screensaver smclient synctex
SUBDIRS = zoom-control toolbar-editor smclient synctex
-include $(top_srcdir)/git.mk

View file

@ -1464,9 +1464,9 @@ egg_editable_toolbar_set_ui_manager (EggEditableToolbar *etoolbar,
static const GtkActionEntry actions[] = {
{ "MoveToolItem", STOCK_DRAG_MODE, N_("_Move on Toolbar"), NULL,
N_("Move the selected item on the toolbar"), G_CALLBACK (move_item_cb) },
{ "RemoveToolItem", GTK_STOCK_REMOVE, N_("_Remove from Toolbar"), NULL,
{ "RemoveToolItem", "list-remove", N_("_Remove from Toolbar"), NULL,
N_("Remove the selected item from the toolbar"), G_CALLBACK (remove_item_cb) },
{ "RemoveToolbar", GTK_STOCK_DELETE, N_("_Delete Toolbar"), NULL,
{ "RemoveToolbar", "edit-delete", N_("_Delete Toolbar"), NULL,
N_("Remove the selected toolbar"), G_CALLBACK (remove_toolbar_cb) },
};

View file

@ -509,8 +509,8 @@ editor_create_item_from_name (EggToolbarEditor *editor,
icon = gtk_image_new_from_icon_name (icon_name,
GTK_ICON_SIZE_LARGE_TOOLBAR);
else
icon = gtk_image_new_from_stock (stock_id ? stock_id : GTK_STOCK_DND,
GTK_ICON_SIZE_LARGE_TOOLBAR);
icon = gtk_image_new_from_icon_name (stock_id ? stock_id : "gtk-dnd",
GTK_ICON_SIZE_LARGE_TOOLBAR);
item_name = g_strdup (name);
collate_key = g_utf8_collate_key (short_label, -1);

View file

@ -607,6 +607,36 @@ egg_toolbars_model_load_toolbars (EggToolbarsModel *model,
return TRUE;
}
gboolean
egg_toolbars_model_load_toolbars_from_resource (EggToolbarsModel *model,
const char *path)
{
xmlDocPtr doc;
xmlNodePtr root;
GBytes *bytes;
GError *error = NULL;
const guint8 *data;
gsize data_len;
g_return_val_if_fail (EGG_IS_TOOLBARS_MODEL (model), FALSE);
bytes = g_resources_lookup_data (path, G_RESOURCE_LOOKUP_FLAGS_NONE, &error);
g_assert_no_error (error);
data = g_bytes_get_data (bytes, &data_len);
doc = xmlParseMemory ((const char *) data, data_len);
if (doc == NULL)
g_error ("Failed to load XML data from resource %s", path);
root = xmlDocGetRootElement (doc);
parse_toolbars (model, root->children);
xmlFreeDoc (doc);
g_bytes_unref (bytes);
return TRUE;
}
static void
parse_available_list (EggToolbarsModel *model,
xmlNodePtr child)
@ -671,6 +701,36 @@ egg_toolbars_model_load_names (EggToolbarsModel *model,
return TRUE;
}
gboolean
egg_toolbars_model_load_names_from_resource (EggToolbarsModel *model,
const char *path)
{
xmlDocPtr doc;
xmlNodePtr root;
GBytes *bytes;
GError *error = NULL;
const guint8 *data;
gsize data_len;
g_return_val_if_fail (EGG_IS_TOOLBARS_MODEL (model), FALSE);
bytes = g_resources_lookup_data (path, G_RESOURCE_LOOKUP_FLAGS_NONE, &error);
g_assert_no_error (error);
data = g_bytes_get_data (bytes, &data_len);
doc = xmlParseMemory ((const char *) data, data_len);
if (doc == NULL)
g_error ("Failed to load XML data from resource %s", path);
root = xmlDocGetRootElement (doc);
parse_names (model, root->children);
xmlFreeDoc (doc);
g_bytes_unref (bytes);
return TRUE;
}
static void
egg_toolbars_model_class_init (EggToolbarsModelClass *klass)
{

View file

@ -23,6 +23,7 @@
#include <glib.h>
#include <glib-object.h>
#include <gio/gio.h>
#include <gdk/gdk.h>
G_BEGIN_DECLS
@ -114,12 +115,16 @@ GType egg_tb_model_flags_get_type (void);
GType egg_toolbars_model_get_type (void);
EggToolbarsModel *egg_toolbars_model_new (void);
gboolean egg_toolbars_model_load_names (EggToolbarsModel *model,
const char *xml_file);
const char *xml_file);
gboolean egg_toolbars_model_load_toolbars (EggToolbarsModel *model,
const char *xml_file);
const char *xml_file);
void egg_toolbars_model_save_toolbars (EggToolbarsModel *model,
const char *xml_file,
const char *version);
const char *xml_file,
const char *version);
gboolean egg_toolbars_model_load_names_from_resource (EggToolbarsModel *model,
const char *path);
gboolean egg_toolbars_model_load_toolbars_from_resource (EggToolbarsModel *model,
const char *path);
/* Functions for manipulating the types of portable data this toolbar understands. */
GList * egg_toolbars_model_get_types (EggToolbarsModel *model);

View file

@ -1,16 +0,0 @@
noinst_LTLIBRARIES = libtotemscrsaver.la
libtotemscrsaver_la_SOURCES = \
totem-scrsaver.h \
totem-scrsaver.c
libtotemscrsaver_la_CPPFLAGS = \
$(AM_CPPFLAGS)
libtotemscrsaver_la_CFLAGS = \
$(SHELL_CORE_CFLAGS) \
$(DBUS_CFLAGS) \
$(WARNING_CFLAGS) \
$(DISABLE_DEPRECATED) \
$(AM_CFLAGS)
-include $(top_srcdir)/git.mk

View file

@ -1,3 +0,0 @@
The sources for the screensaver enabling/disabling code are copied from Totem.
A simple replacement (s/WITH_DBUS/ENABLE_DBUS/g) was needed. The hardcoded
"reason for inhibiting" string was also modified.

View file

@ -1,544 +0,0 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*-
Copyright (C) 2004-2006 Bastien Nocera <hadess@hadess.net>
Copyright © 2010 Christian Persch
Copyright © 2010 Carlos Garcia Campos
The Mate Library is free software; you can redistribute it and/or
modify it under the terms of the GNU Library General Public License as
published by the Free Software Foundation; either version 2 of the
License, or (at your option) any later version.
The Mate Library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Library General Public License for more details.
You should have received a copy of the GNU Library General Public
License along with the Mate Library; see the file COPYING.LIB. If not,
write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
Boston, MA 02110-1301 USA.
Authors: Bastien Nocera <hadess@hadess.net>
Christian Persch
Carlos Garcia Campos
*/
#include "config.h"
#include <glib/gi18n.h>
#include <gdk/gdk.h>
#ifdef GDK_WINDOWING_X11
#include <gdk/gdkx.h>
#include <X11/keysym.h>
#ifdef HAVE_XTEST
#include <X11/extensions/XTest.h>
#endif /* HAVE_XTEST */
#endif /* GDK_WINDOWING_X11 */
#include "totem-scrsaver.h"
#define GS_SERVICE "org.gnome.SessionManager"
#define GS_PATH "/org/gnome/SessionManager"
#define GS_INTERFACE "org.gnome.SessionManager"
#define GSM_INHIBITOR_FLAG_IDLE 1 << 3
#define XSCREENSAVER_MIN_TIMEOUT 60
enum {
PROP_0,
PROP_REASON
};
static void totem_scrsaver_finalize (GObject *object);
struct TotemScrsaverPrivate {
/* Whether the screensaver is disabled */
gboolean disabled;
/* The reason for the inhibition */
char *reason;
GDBusProxy *gs_proxy;
gboolean have_session_dbus;
guint32 cookie;
/* To save the screensaver info */
int timeout;
int interval;
int prefer_blanking;
int allow_exposures;
/* For use with XTest */
int keycode1, keycode2;
int *keycode;
gboolean have_xtest;
};
G_DEFINE_TYPE(TotemScrsaver, totem_scrsaver, G_TYPE_OBJECT)
static gboolean
screensaver_is_running_dbus (TotemScrsaver *scr)
{
return scr->priv->have_session_dbus;
}
static void
on_inhibit_cb (GObject *source_object,
GAsyncResult *res,
gpointer user_data)
{
GDBusProxy *proxy = G_DBUS_PROXY (source_object);
TotemScrsaver *scr = TOTEM_SCRSAVER (user_data);
GVariant *value;
GError *error = NULL;
value = g_dbus_proxy_call_finish (proxy, res, &error);
if (!value) {
g_warning ("Problem inhibiting the screensaver: %s", error->message);
g_object_unref (scr);
g_error_free (error);
return;
}
/* save the cookie */
if (g_variant_is_of_type (value, G_VARIANT_TYPE ("(u)")))
g_variant_get (value, "(u)", &scr->priv->cookie);
else
scr->priv->cookie = 0;
g_variant_unref (value);
g_object_unref (scr);
}
static void
on_uninhibit_cb (GObject *source_object,
GAsyncResult *res,
gpointer user_data)
{
GDBusProxy *proxy = G_DBUS_PROXY (source_object);
TotemScrsaver *scr = TOTEM_SCRSAVER (user_data);
GVariant *value;
GError *error = NULL;
value = g_dbus_proxy_call_finish (proxy, res, &error);
if (!value) {
g_warning ("Problem uninhibiting the screensaver: %s", error->message);
g_object_unref (scr);
g_error_free (error);
return;
}
/* clear the cookie */
scr->priv->cookie = 0;
g_variant_unref (value);
g_object_unref (scr);
}
static void
screensaver_inhibit_dbus (TotemScrsaver *scr,
gboolean inhibit)
{
TotemScrsaverPrivate *priv = scr->priv;
if (!priv->have_session_dbus)
return;
g_object_ref (scr);
if (inhibit) {
g_return_if_fail (scr->priv->reason != NULL);
g_dbus_proxy_call (priv->gs_proxy,
"Inhibit",
g_variant_new ("(susu)",
g_get_application_name (),
0,
scr->priv->reason,
GSM_INHIBITOR_FLAG_IDLE),
G_DBUS_CALL_FLAGS_NO_AUTO_START,
-1,
NULL,
on_inhibit_cb,
scr);
} else {
g_dbus_proxy_call (priv->gs_proxy,
"Uninhibit",
g_variant_new ("(u)", priv->cookie),
G_DBUS_CALL_FLAGS_NO_AUTO_START,
-1,
NULL,
on_uninhibit_cb,
scr);
}
}
static void
screensaver_enable_dbus (TotemScrsaver *scr)
{
screensaver_inhibit_dbus (scr, FALSE);
}
static void
screensaver_disable_dbus (TotemScrsaver *scr)
{
screensaver_inhibit_dbus (scr, TRUE);
}
static void
screensaver_update_dbus_presence (TotemScrsaver *scr)
{
TotemScrsaverPrivate *priv = scr->priv;
gchar *name_owner;
name_owner = g_dbus_proxy_get_name_owner (priv->gs_proxy);
if (name_owner) {
priv->have_session_dbus = TRUE;
g_free (name_owner);
} else {
priv->have_session_dbus = FALSE;
}
}
static void
screensaver_dbus_owner_changed_cb (GObject *object,
GParamSpec *pspec,
gpointer user_data)
{
TotemScrsaver *scr = TOTEM_SCRSAVER (user_data);
screensaver_update_dbus_presence (scr);
}
static void
screensaver_dbus_proxy_new_cb (GObject *source,
GAsyncResult *result,
gpointer user_data)
{
TotemScrsaver *scr = TOTEM_SCRSAVER (user_data);
TotemScrsaverPrivate *priv = scr->priv;
priv->gs_proxy = g_dbus_proxy_new_for_bus_finish (result, NULL);
if (!priv->gs_proxy)
return;
screensaver_update_dbus_presence (scr);
g_signal_connect (priv->gs_proxy, "notify::g-name-owner",
G_CALLBACK (screensaver_dbus_owner_changed_cb),
scr);
}
static void
screensaver_init_dbus (TotemScrsaver *scr)
{
g_dbus_proxy_new_for_bus (G_BUS_TYPE_SESSION,
G_DBUS_PROXY_FLAGS_DO_NOT_LOAD_PROPERTIES,
NULL,
GS_SERVICE,
GS_PATH,
GS_INTERFACE,
NULL,
screensaver_dbus_proxy_new_cb,
scr);
}
static void
screensaver_finalize_dbus (TotemScrsaver *scr)
{
if (scr->priv->gs_proxy) {
g_object_unref (scr->priv->gs_proxy);
}
}
#ifdef GDK_WINDOWING_X11
static void
screensaver_enable_x11 (TotemScrsaver *scr)
{
Display *display;
#ifdef HAVE_XTEST
if (scr->priv->have_xtest != FALSE)
{
g_source_remove_by_user_data (scr);
return;
}
#endif /* HAVE_XTEST */
display = GDK_DISPLAY_XDISPLAY (gdk_display_get_default ());
XLockDisplay (display);
XSetScreenSaver (display,
scr->priv->timeout,
scr->priv->interval,
scr->priv->prefer_blanking,
scr->priv->allow_exposures);
XUnlockDisplay (display);
}
#ifdef HAVE_XTEST
static gboolean
fake_event (TotemScrsaver *scr)
{
if (scr->priv->disabled)
{
Display *display;
display = GDK_DISPLAY_XDISPLAY (gdk_display_get_default ());
XLockDisplay (display);
XTestFakeKeyEvent (display, *scr->priv->keycode,
True, CurrentTime);
XTestFakeKeyEvent (display, *scr->priv->keycode,
False, CurrentTime);
XUnlockDisplay (display);
/* Swap the keycode */
if (scr->priv->keycode == &scr->priv->keycode1)
scr->priv->keycode = &scr->priv->keycode2;
else
scr->priv->keycode = &scr->priv->keycode1;
}
return TRUE;
}
#endif /* HAVE_XTEST */
static void
screensaver_disable_x11 (TotemScrsaver *scr)
{
Display *display;
display = GDK_DISPLAY_XDISPLAY (gdk_display_get_default ());
#ifdef HAVE_XTEST
if (scr->priv->have_xtest != FALSE)
{
XLockDisplay (display);
XGetScreenSaver(display, &scr->priv->timeout,
&scr->priv->interval,
&scr->priv->prefer_blanking,
&scr->priv->allow_exposures);
XUnlockDisplay (display);
if (scr->priv->timeout != 0) {
g_timeout_add_seconds (scr->priv->timeout / 2,
(GSourceFunc) fake_event, scr);
} else {
g_timeout_add_seconds (XSCREENSAVER_MIN_TIMEOUT / 2,
(GSourceFunc) fake_event, scr);
}
return;
}
#endif /* HAVE_XTEST */
XLockDisplay (display);
XGetScreenSaver(display, &scr->priv->timeout,
&scr->priv->interval,
&scr->priv->prefer_blanking,
&scr->priv->allow_exposures);
XSetScreenSaver(display, 0, 0,
DontPreferBlanking, DontAllowExposures);
XUnlockDisplay (display);
}
static void
screensaver_init_x11 (TotemScrsaver *scr)
{
#ifdef HAVE_XTEST
int a, b, c, d;
Display *display;
display = GDK_DISPLAY_XDISPLAY (gdk_display_get_default ());
XLockDisplay (display);
scr->priv->have_xtest = (XTestQueryExtension (display, &a, &b, &c, &d) == True);
if (scr->priv->have_xtest != FALSE)
{
scr->priv->keycode1 = XKeysymToKeycode (display, XK_Alt_L);
if (scr->priv->keycode1 == 0) {
g_warning ("scr->priv->keycode1 not existent");
}
scr->priv->keycode2 = XKeysymToKeycode (display, XK_Alt_R);
if (scr->priv->keycode2 == 0) {
scr->priv->keycode2 = XKeysymToKeycode (display, XK_Alt_L);
if (scr->priv->keycode2 == 0) {
g_warning ("scr->priv->keycode2 not existent");
}
}
scr->priv->keycode = &scr->priv->keycode1;
}
XUnlockDisplay (display);
#endif /* HAVE_XTEST */
}
static void
screensaver_finalize_x11 (TotemScrsaver *scr)
{
g_source_remove_by_user_data (scr);
}
#endif
static void
totem_scrsaver_get_property (GObject *object,
guint property_id,
GValue *value,
GParamSpec *pspec)
{
TotemScrsaver *scr;
scr = TOTEM_SCRSAVER (object);
switch (property_id)
{
case PROP_REASON:
g_value_set_string (value, scr->priv->reason);
break;
default:
G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
}
}
static void
totem_scrsaver_set_property (GObject *object,
guint property_id,
const GValue *value,
GParamSpec *pspec)
{
TotemScrsaver *scr;
scr = TOTEM_SCRSAVER (object);
switch (property_id)
{
case PROP_REASON:
g_free (scr->priv->reason);
scr->priv->reason = g_value_dup_string (value);
break;
default:
G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
}
}
static void
totem_scrsaver_class_init (TotemScrsaverClass *klass)
{
GObjectClass *object_class = G_OBJECT_CLASS (klass);
g_type_class_add_private (klass, sizeof (TotemScrsaverPrivate));
object_class->set_property = totem_scrsaver_set_property;
object_class->get_property = totem_scrsaver_get_property;
object_class->finalize = totem_scrsaver_finalize;
g_object_class_install_property (object_class, PROP_REASON,
g_param_spec_string ("reason", NULL, NULL,
NULL, G_PARAM_READWRITE));
}
/**
* totem_scrsaver_new:
*
* Creates a #TotemScrsaver object.
* If the MATE screen saver is running, it uses its DBUS interface to
* inhibit the screensaver; otherwise it falls back to using the X
* screensaver functionality for this.
*
* Returns: a newly created #TotemScrsaver
*/
TotemScrsaver *
totem_scrsaver_new (void)
{
return TOTEM_SCRSAVER (g_object_new (TOTEM_TYPE_SCRSAVER, NULL));
}
static void
totem_scrsaver_init (TotemScrsaver *scr)
{
scr->priv = G_TYPE_INSTANCE_GET_PRIVATE (scr,
TOTEM_TYPE_SCRSAVER,
TotemScrsaverPrivate);
screensaver_init_dbus (scr);
#ifdef GDK_WINDOWING_X11
screensaver_init_x11 (scr);
#else
#warning Unimplemented
#endif
}
void
totem_scrsaver_disable (TotemScrsaver *scr)
{
g_return_if_fail (TOTEM_IS_SCRSAVER (scr));
if (scr->priv->disabled != FALSE)
return;
scr->priv->disabled = TRUE;
if (screensaver_is_running_dbus (scr) != FALSE)
screensaver_disable_dbus (scr);
else
#ifdef GDK_WINDOWING_X11
screensaver_disable_x11 (scr);
#else
#warning Unimplemented
{}
#endif
}
void
totem_scrsaver_enable (TotemScrsaver *scr)
{
g_return_if_fail (TOTEM_IS_SCRSAVER (scr));
if (scr->priv->disabled == FALSE)
return;
scr->priv->disabled = FALSE;
if (screensaver_is_running_dbus (scr) != FALSE)
screensaver_enable_dbus (scr);
else
#ifdef GDK_WINDOWING_X11
screensaver_enable_x11 (scr);
#else
#warning Unimplemented
{}
#endif
}
void
totem_scrsaver_set_state (TotemScrsaver *scr, gboolean enable)
{
g_return_if_fail (TOTEM_IS_SCRSAVER (scr));
if (scr->priv->disabled == !enable)
return;
if (enable == FALSE)
totem_scrsaver_disable (scr);
else
totem_scrsaver_enable (scr);
}
static void
totem_scrsaver_finalize (GObject *object)
{
TotemScrsaver *scr = TOTEM_SCRSAVER (object);
g_free (scr->priv->reason);
screensaver_finalize_dbus (scr);
#ifdef GDK_WINDOWING_X11
screensaver_finalize_x11 (scr);
#else
#warning Unimplemented
{}
#endif
G_OBJECT_CLASS (totem_scrsaver_parent_class)->finalize (object);
}

View file

@ -1,57 +0,0 @@
/*
Copyright (C) 2004, Bastien Nocera <hadess@hadess.net>
The Mate Library is free software; you can redistribute it and/or
modify it under the terms of the GNU Library General Public License as
published by the Free Software Foundation; either version 2 of the
License, or (at your option) any later version.
The Mate Library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Library General Public License for more details.
You should have received a copy of the GNU Library General Public
License along with the Mate Library; see the file COPYING.LIB. If not,
write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
Boston, MA 02110-1301 USA.
Author: Bastien Nocera <hadess@hadess.net>
*/
#ifndef TOTEM_SCRSAVER_H
#define TOTEM_SCRSAVER_H
#include <glib-object.h>
G_BEGIN_DECLS
#define TOTEM_TYPE_SCRSAVER (totem_scrsaver_get_type ())
#define TOTEM_SCRSAVER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TOTEM_TYPE_SCRSAVER, TotemScrsaver))
#define TOTEM_SCRSAVER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TOTEM_TYPE_SCRSAVER, TotemScrsaverClass))
#define TOTEM_IS_SCRSAVER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TOTEM_TYPE_SCRSAVER))
#define TOTEM_IS_SCRSAVER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TOTEM_TYPE_SCRSAVER))
typedef struct TotemScrsaver TotemScrsaver;
typedef struct TotemScrsaverClass TotemScrsaverClass;
typedef struct TotemScrsaverPrivate TotemScrsaverPrivate;
struct TotemScrsaver {
GObject parent;
TotemScrsaverPrivate *priv;
};
struct TotemScrsaverClass {
GObjectClass parent_class;
};
GType totem_scrsaver_get_type (void) G_GNUC_CONST;
TotemScrsaver *totem_scrsaver_new (void);
void totem_scrsaver_enable (TotemScrsaver *scr);
void totem_scrsaver_disable (TotemScrsaver *scr);
void totem_scrsaver_set_state (TotemScrsaver *scr,
gboolean enable);
G_END_DECLS
#endif /* !TOTEM_SCRSAVER_H */

View file

@ -15,14 +15,8 @@ man_MANS=atril.1
uidir = $(pkgdatadir)
ui_DATA = \
atril-ui.xml \
atril-toolbar.xml \
hand-open.png
if ENABLE_PREVIEWER
ui_DATA += atril-previewer-ui.xml
endif
#
# Desktop file
#
@ -51,7 +45,7 @@ endif
# App data file
#
@INTLTOOL_XML_NOMERGE_RULE@
appdatadir = $(datadir)/appdata
appdatadir = $(datadir)/metainfo
appdata_in_files = atril.appdata.xml.in
appdata_DATA = $(appdata_in_files:.xml.in=.xml)

View file

@ -14,6 +14,7 @@
<toolitem name="ViewZoom"/>
<toolitem name="ViewZoomIn"/>
<toolitem name="ViewZoomOut"/>
<toolitem name="ViewZoomReset"/>
<toolitem name="ViewFitPage"/>
<toolitem name="ViewFitWidth"/>
<toolitem name="ViewFullscreen"/>

View file

@ -49,6 +49,7 @@
<separator/>
<menuitem name="ViewZoomInMenu" action="ViewZoomIn"/>
<menuitem name="ViewZoomOutMenu" action="ViewZoomOut"/>
<menuitem name="ViewZoomResetMenu" action="ViewZoomReset"/>
<menuitem name="ViewFitPageMenu" action="ViewFitPage"/>
<menuitem name="ViewFitWidthMenu" action="ViewFitWidth"/>
<menuitem name="ViewExpandWindowMenu" action="ViewExpandWindow"/>
@ -128,6 +129,7 @@
<accelerator name="KpMinusAccel" action="KpMinus"/>
<accelerator name="CtrlKpPlusAccel" action="CtrlKpPlus"/>
<accelerator name="CtrlKpMinusAccel" action="CtrlKpMinus"/>
<accelerator name="CtrlKpZeroAccel" action="CtrlKpZero"/>
<accelerator name="CtrlInsertAccel" action="CtrlInsert" />
<accelerator name="FitPageAccel" action ="FitPage" />
<accelerator name="FitWidthAccel" action ="FitWidth" />

View file

@ -1,493 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv="Content-Style-Type" content="text/css" />
<meta name="generator" content="pandoc" />
<meta name="author" content="Oz Nahum (2012)" />
<meta name="author" content="Nickolay V. Shmyrev" />
<meta name="author" content="Niels Giesen" />
<meta name="author" content="Claude Paroz (2004)" />
<meta name="date" content="2012-09-18" />
<title>Atril</title>
<style type="text/css">
/*
:Author: Enrico Troeger
:Contact: enrico(dot)troeger(at)uvena(dot)de
:Copyright: This stylesheet has been placed in the public domain.
Stylesheet Atril is based on Geany's documentation based on a version of John Gabriele.
see www.geany.org
*/
@media screen {
body {
background-color: #f2f2f2;
color: #404040;
margin-left: 0.4em;
max-width: 60em;
font-size: 90%;
}
a {
color: #990000;
}
a:visited {
color: #7E558E;
}
a:hover {
text-decoration: none;
}
h1 {
border-top: 1px dotted;
margin-top: 2em;
}
h1, h2, h3 {
font-family: sans-serif;
color: #5D0606;
}
h1.title {
text-align: left }
h2 {
margin-top: 30px;
}
h2.subtitle {
text-align: left }
h3 {
padding-left: 3px;
}
blockquote, pre {
border: 1px solid;
padding: 0.4em;
}
blockquote {
font-family: sans-serif;
background-color: #DBEDD5;
border: 1px dotted;
border-left: 4px solid;
border-color: #9FD98C;
}
pre {
background-color: #ECDFCE;
border: 1px dotted;
border-left: 4px solid;
border-color: #D9BE9A;
}
tt, pre, code {
color: #6D4212;
}
table {
border: 1px solid #D9BE9A;
}
th {
background-color: #ECDFCE;
border: 1px dotted #D9BE9A;
}
td {
border: 1px dotted #D9BE9A;
}
.docinfo-name {
color: #5D0606;
}
p.admonition-title {
color: #990000;
font-weight: bold;
}
div.note {
margin: 1em 3em;
padding: 0em;
}
dt {
font-style: italic;
}
}
@media print {
}
</style>
</head>
<body>
<div class="document" id="Atril">
<h1 class="title">Atril</h1>
<h2 class="subtitle" id="Mate Document Viewer">A simple document viewer</h2>
<table class="docinfo" frame="void" rules="none">
<col class="docinfo-name" />
<col class="docinfo-content" />
<tbody valign="top">
<tr><th class="docinfo-name">Authors:</th>
<td>Oz Nahum (2012)
<br /> Nickolay V. Shmyrev (2005)
<br />Niels Giesen (2004)
<br /> Claude Paroz (2004) </td></tr>
<tr><th class="docinfo-name">Date:</th>
<td>2012-09-18</td></tr>
<tr><th class="docinfo-name">Version:</th>
<td>1.22</td></tr>
</tbody>
</table>
<p>Copyright © 2004-2012</p>
<p>This document is distributed under the terms of the GNU General Public
License as published by the Free Software Foundation; either version 2
of the License, or (at your option) any later version. A copy of this
license can be found in the file COPYING included with the source code
of this program, and also in the chapter
<a class="reference internal" href="#gnu-general-public-license">GNU General Public License</a>.</p>
<div class="contents topic" id="contents">
<h1 id="introduction">Introduction</h1>
<p>Atril enables you to view documents of various formats like Portable Document Format (PDF) files and PostScript files. Atril follows Freedesktop.org and MATE standards to provide integration with Desktop Environment.</p>
<h1 id="getting-started">Getting Started</h1>
<h2 id="to-start-atril">To Start atril</h2>
<p>atril starts when you open a document such as a PDF or PostScript file.</p>
<p>Alternatively, you can start atril from the command line, with the command: <code>atril</code>.</p>
<h2 id="when-you-start-atril">When You Start atril</h2>
<p>When you start atril, the following window is displayed.</p>
<div class="figure">
<img src="figures/atril_start_window.png" alt="Shows atril main window. Contains titlebar, menubar, toolbar and display area. Menubar contains File, Edit, View, Go and Help menus." /><p class="caption">Shows atril main window. Contains titlebar, menubar, toolbar and display area. Menubar contains File, Edit, View, Go and Help menus.</p>
</div>
<p>Atril window contains the following elements:</p>
<dl>
<dt>Menubar</dt>
<dd><p>The menus on the menubar contain all of the commands that you need to work with documents in APP.</p>
</dd>
<dt>Toolbar</dt>
<dd><p>The toolbar contains a subset of the commands that you can access from the menubar.</p>
</dd>
<dt>Display area</dt>
<dd><p>The display area displays the document.</p>
</dd>
</dl>
<p>In atril, you can perform the same action in several ways. For example, you can open a document in the following ways:</p>
<table>
<col width="48%" />
<col width="48%" />
<thead>
<tr class="header">
<th align="left">UI Component</th>
<th align="left">Action</th>
</tr>
</thead>
<tbody>
<tr class="odd">
<td align="left">Window</td>
<td align="left">- Drag a file into the APP window from another application such as a file manager.</td>
</tr>
<tr class="even">
<td align="left"></td>
<td align="left">- Double-click on the file name in the file manager</td>
</tr>
<tr class="odd">
<td align="left">Menubar</td>
<td align="left">Choose FileOpen.</td>
</tr>
<tr class="even">
<td align="left">Shortcut keys</td>
<td align="left">Press CtrlO.</td>
</tr>
</tbody>
</table>
<p>This manual documents functionality from the menubar.</p>
<h1 id="usage">Usage</h1>
<h2 id="to-open-a-document">To Open A Document</h2>
<p>To open a document, perform the following steps:</p>
<ol style="list-style-type: decimal">
<li><p>Choose FileOpen.</p></li>
<li><p>In the Open Document dialog, select the file you want to open.</p></li>
<li><p>Click Open. atril displays the name of the document in the titlebar of the window.</p></li>
</ol>
<p>To open another document, choose FileOpen again. atril opens each file in a new window.</p>
<p>If you try to open a document with format that atril does not recognize, the application displays an error message.</p>
<h2 id="to-navigate-through-a-document">To Navigate Through a Document</h2>
<p>You can navigate through a file as follows:</p>
<ul>
<li><p>To view the next page, choose Go Next Page.</p></li>
<li><p>To view the previous page, choose Go Previous Page.</p></li>
<li><p>To view the first page in the document, choose Go First Page.</p></li>
<li><p>To view the last page in the document, choose Go Last Page.</p></li>
<li><p>To view a particular page, enter the page number or page label in the text box on the toolbar, then press Return.</p></li>
</ul>
<h2 id="to-scroll-a-page">To Scroll a Page</h2>
<p>To display the page contents that are not currently displayed in the display area, use the following methods:</p>
<ul>
<li><p>Use the arrow keys or space key on the keyboard.</p></li>
<li><p>Drag the display area by clicking with the middle mouse button somewhere in the document and then moving the mouse. For example, to scroll down the page, drag the display area upwards in the window.</p></li>
<li><p>Use the scrollbars on the window.</p></li>
</ul>
<h2 id="to-change-the-page-size">To Change the Page Size</h2>
<p>You can use the following methods to resize a page in the atril display area:</p>
<ul>
<li><p>To increase the page size, choose View Zoom In.</p></li>
<li><p>To decrease the page size, choose View Zoom Out.</p></li>
<li><p>To resize a page to have the same width as the atril display area, choose View Fit page width.</p></li>
<li><p>To resize a page to fit within the atril display area, choose View Best Fit.</p></li>
<li><p>To resize the atril window to have the same width and height as the screen, choose View Full Screen. To resize the atril window to the original size, click on the Exit Full Screen button.</p></li>
</ul>
<h2 id="to-view-pages-or-document-structure">To View Pages or Document Structure</h2>
<p>To view bookmarks or pages, perform the following steps:</p>
<ol style="list-style-type: decimal">
<li><p>Choose View Sidebar or press F9.</p></li>
<li><p>Use the drop-down list in the side-pane header to select whether to display document structure or pages in the side pane.</p></li>
<li><p>Use the side-pane scrollbars to display the required item or page in the side pane.</p></li>
<li><p>Click on an entry to navigate to that location in the document. Click on a page to navigate to that page in the document.</p></li>
</ol>
<h2 id="to-view-the-properties-of-a-document">To View the Properties of a Document</h2>
<p>To view the properties of a document, choose File Properties.</p>
<p>The Properties dialog displays all information available</p>
<h2 id="to-print-a-document">To Print a Document</h2>
<p>To print a Document, choose File Print.</p>
<blockquote>
<p><strong>Note</strong></p>
<p>If you cannot choose the Print menu item, the author of the document has disabled the print option for this document. To enable the print option, you must enter the master password when you open the document.</p>
</blockquote>
<p>The Print dialog has the following tabbed sections:</p>
<ul>
<li><p><a href="#print-dialog-job">Job</a></p></li>
<li><p><a href="#print-dialog-printer">Printer</a></p></li>
<li><p><a href="#print-dialog-paper">Paper</a></p></li>
</ul>
<h3 id="job">Job</h3>
<dl>
<dt>Print range</dt>
<dd><p>Select one of the following options to determine how many pages to print:</p>
<ul>
<li><p>All</p>
<p>Select this option to print all of the pages in the document.</p></li>
<li><p>Pages From</p>
<p>Select this option to print the selected range of pages in the document. Use the spin boxes to specify the first page and last page of the range.</p></li>
</ul>
</dd>
</dl>
<h3 id="printer">Printer</h3>
<dl>
<dt>Printer</dt>
<dd><p>Use this drop-down list to select the printer to which you want to print the document.</p>
<blockquote>
<p><strong>Note</strong></p>
<p>The Create a PDF document option is not supported in this version of APP.</p>
</blockquote>
</dd>
<dt>Settings</dt>
<dd><p>Use this drop-down list to select the printer settings.</p>
<p>To configure the printer, click Configure. For example, you can enable or disable duplex printing, or schedule delayed printing, if this functionality is supported by the printer.</p>
</dd>
<dt>Location</dt>
<dd><p>Use this drop-down list to select one of the following print destinations:</p>
<dl>
<dt>CUPS</dt>
<dd><p>Print the document to a CUPS printer.</p>
<blockquote>
<p><strong>Note</strong></p>
<p>If the selected printer is a CUPS printer, CUPS is the only entry in this drop-down list.</p>
</blockquote>
</dd>
<dt>lpr</dt>
<dd><p>Print the document to a printer.</p>
</dd>
<dt>File</dt>
<dd><p>Print the document to a PostScript file.</p>
<p>Click Save As to display a dialog where you specify the name and location of the PostScript file.</p>
</dd>
<dt>Custom</dt>
<dd><p>Use the specified command to print the document.</p>
<p>Type the name of the command in the text box. Include all command-line arguments.</p>
</dd>
</dl>
</dd>
<dt>State</dt>
<dd><p>This functionality is not supported in this version of atril.</p>
</dd>
<dt>Type</dt>
<dd><p>This functionality is not supported in this version of atril.</p>
</dd>
<dt>Comment</dt>
<dd><p>This functionality is not supported in this version of atril.</p>
</dd>
</dl>
<h3 id="paper">Paper</h3>
<dl>
<dt>Paper size</dt>
<dd><p>Use this drop-down list to select the size of the paper to which you want to print the document.</p>
</dd>
<dt>Width</dt>
<dd><p>Use this spin box to specify the width of the paper. Use the adjacent drop-down list to change the measurement unit.</p>
</dd>
<dt>Height</dt>
<dd><p>Use this spin box to specify the height of the paper.</p>
</dd>
<dt>Feed orientation</dt>
<dd><p>Use this drop-down list to select the orientation of the paper in the printer.</p>
</dd>
<dt>Page orientation</dt>
<dd><p>Use this drop-down list to select the page orientation.</p>
</dd>
<dt>Layout</dt>
<dd><p>Use this drop-down list to select the page layout. A preview of each layout that you select is displayed in the Preview area.</p>
</dd>
<dt>Paper Tray</dt>
<dd><p>Use this drop-down list to select the paper tray.</p>
</dd>
</dl>
<h2 id="to-copy-a-document">To Copy a Document</h2>
<p>To copy a file, perform the following steps:</p>
<ol style="list-style-type: decimal">
<li><p>Choose File Save a Copy.</p></li>
<li><p>Type the new filename in the Filename text box in the Save a Copy dialog.</p>
<p>If necessary, specify the location of the copied document. By default, copies are saved in your home directory.</p></li>
<li><p>Click Save.</p></li>
</ol>
<h2 id="to-work-with-password-protected-documents">To Work With Password-Protected Documents</h2>
<p>An author can use the following password levels to protect a document:</p>
<ul>
<li><p>User password that allows others only to read the document.</p></li>
<li><p>Master password that allows others to perform additional actions, such as print the document.</p></li>
</ul>
<p>When you try to open a password-protected document, atril displays a security dialog. Type either the user password or the master password in the Enter document password text box, then click Open Document.</p>
<h2 id="to-close-a-document">To Close a Document</h2>
<p>To close a document, choose File Close.</p>
<p>If the window is the last atril window open, the application exits.</p>
<h1 id="list-of-keyboard-shortcuts">List of Keyboard Shortcuts</h1>
<p>Below is a table of all shortcuts present in atril:</p>
<table>
<col width="33%" />
<col width="38%" />
<thead>
<tr class="header">
<th align="left">Shortcut</th>
<th align="left">Action</th>
</tr>
</thead>
<tbody>
<tr class="odd">
<td align="left">Ctrl-O</td>
<td align="left">Open an existing document</td>
</tr>
<tr class="even">
<td align="left">Ctrl-S</td>
<td align="left">Save a copy of the current document</td>
</tr>
<tr class="odd">
<td align="left">Ctrl-P</td>
<td align="left">Print document</td>
</tr>
<tr class="even">
<td align="left">Ctrl-W</td>
<td align="left">Close window</td>
</tr>
<tr class="odd">
<td align="left">Ctrl-C</td>
<td align="left">Copy selection</td>
</tr>
<tr class="even">
<td align="left">Ctrl-A</td>
<td align="left">Select All</td>
</tr>
<tr class="odd">
<td align="left"><p>Ctrl-F ,</p>
<p>/ (slash)</p></td>
<td align="left">Find a word or phrase in the document</td>
</tr>
<tr class="even">
<td align="left">Ctrl-G F3</td>
<td align="left">Find next</td>
</tr>
<tr class="odd">
<td align="left"><p>Ctrl + (plus sign)</p>
<p>+</p>
<p>=</p></td>
<td align="left">Zoom in</td>
</tr>
<tr class="even">
<td align="left">Ctrl -(minus sign),-</td>
<td align="left">Zoom out</td>
</tr>
<tr class="odd">
<td align="left">Ctrl-R</td>
<td align="left">Reload the document</td>
</tr>
<tr class="even">
<td align="left">Page Up</td>
<td align="left">Go to the previous page</td>
</tr>
<tr class="odd">
<td align="left">Page Down</td>
<td align="left">Go to the next page</td>
</tr>
<tr class="even">
<td align="left"><p>Space, j</p>
<p>Shift Backspace</p>
<p>Return</p></td>
<td align="left">Scroll forward</td>
</tr>
<tr class="odd">
<td align="left">Shift Space, k Backspace</td>
<td align="left">Scroll backward</td>
</tr>
<tr class="even">
<td align="left">Shift Return Shift Page Up</td>
<td align="left">Go a bunch of pages up</td>
</tr>
<tr class="odd">
<td align="left">Shift Page Down</td>
<td align="left">Go a bunch of pages down</td>
</tr>
<tr class="even">
<td align="left">Home</td>
<td align="left">Go to the first page</td>
</tr>
<tr class="odd">
<td align="left">End</td>
<td align="left">Go to the last page</td>
</tr>
<tr class="even">
<td align="left">Ctrl-L</td>
<td align="left">Go to page by number or label</td>
</tr>
<tr class="odd">
<td align="left">F1</td>
<td align="left">Help</td>
</tr>
<tr class="even">
<td align="left">F5</td>
<td align="left">Run document as presentation</td>
</tr>
<tr class="odd">
<td align="left">F9</td>
<td align="left">Show or hide the side pane</td>
</tr>
<tr class="even">
<td align="left">F11</td>
<td align="left">Toggle fullscreen mode</td>
</tr>
</tbody>
</table>
</body>
</html>

View file

@ -1,388 +0,0 @@
% Atril
% Oz Nahum (2012); Nickolay V. Shmyrev; Niels Giesen; Claude Paroz (2004)
% 18 September 2012
Introduction
============
Atril enables you to view documents of various formats
like Portable Document Format (PDF) files and PostScript files. Atril
follows Freedesktop.org and MATE standards to provide integration with
Desktop Environment.
Getting Started
===============
To Start atril
----------------
atril starts when you open a document such as a PDF or PostScript file.
Alternatively, you can start atril from the command line, with the
command: `atril`.
When You Start atril
----------------------
When you start atril, the following window is displayed.
![ Shows atril main window. Contains titlebar, menubar, toolbar and
display area. Menubar contains File, Edit, View, Go and Help menus.
](figures/atril_start_window.png)
Atril window contains the following elements:
Menubar
: The menus on the menubar contain all of the commands that you need
to work with documents in APP.
Toolbar
: The toolbar contains a subset of the commands that you can access
from the menubar.
Display area
: The display area displays the document.
In atril, you can perform the same action in several ways. For example,
you can open a document in the following ways:
-------------------------------------------------------------------------
UI Component Action
------------------------------------ ------------------------------------
Window - Drag a file into the APP window
from another application such as
a file manager.
- Double-click on the file name in
the file manager
Menubar Choose FileOpen.
Shortcut keys Press CtrlO.
-------------------------------------------------------------------------
This manual documents functionality from the menubar.
Usage
=====
To Open A Document
------------------
To open a document, perform the following steps:
1. Choose FileOpen.
2. In the Open Document dialog, select the file you want to open.
3. Click Open. atril displays the name of the document in the titlebar of
the window.
To open another document, choose FileOpen again. atril opens each file in
a new window.
If you try to open a document with format that atril does not recognize,
the application displays an error message.
To Navigate Through a Document
------------------------------
You can navigate through a file as follows:
- To view the next page, choose Go Next Page.
- To view the previous page, choose Go Previous Page.
- To view the first page in the document, choose Go First Page.
- To view the last page in the document, choose Go Last Page.
- To view a particular page, enter the page number or page label in
the text box on the toolbar, then press Return.
To Scroll a Page
----------------
To display the page contents that are not currently displayed in the
display area, use the following methods:
- Use the arrow keys or space key on the keyboard.
- Drag the display area by clicking with the middle mouse button
somewhere in the document and then moving the mouse. For example, to
scroll down the page, drag the display area upwards in the window.
- Use the scrollbars on the window.
To Change the Page Size
-----------------------
You can use the following methods to resize a page in the atril display
area:
- To increase the page size, choose View Zoom In.
- To decrease the page size, choose View Zoom Out.
- To resize a page to have the same width as the atril display area,
choose View Fit page width.
- To resize a page to fit within the atril display area, choose View
Best Fit.
- To resize the atril window to have the same width and height as the
screen, choose View Full Screen. To resize the atril window to the
original size, click on the Exit Full Screen button.
To View Pages or Document Structure
-----------------------------------
To view bookmarks or pages, perform the following steps:
1. Choose View Sidebar or press F9.
2. Use the drop-down list in the side-pane header to select whether to
display document structure or pages in the side pane.
3. Use the side-pane scrollbars to display the required item or page in
the side pane.
4. Click on an entry to navigate to that location in the document.
Click on a page to navigate to that page in the document.
To View the Properties of a Document
------------------------------------
To view the properties of a document, choose File Properties.
The Properties dialog displays all information available
To Print a Document
-------------------
To print a Document, choose File Print.
> **Note**
>
> If you cannot choose the Print menu item, the author of the document
> has disabled the print option for this document. To enable the print
> option, you must enter the master password when you open the document.
The Print dialog has the following tabbed sections:
- [Job](#print-dialog-job)
- [Printer](#print-dialog-printer)
- [Paper](#print-dialog-paper)
### Job
Print range
: Select one of the following options to determine how many pages to
print:
- All
Select this option to print all of the pages in the document.
- Pages From
Select this option to print the selected range of pages in the
document. Use the spin boxes to specify the first page and last
page of the range.
### Printer
Printer
: Use this drop-down list to select the printer to which you want to
print the document.
> **Note**
>
> The Create a PDF document option is not supported in this version
> of APP.
Settings
: Use this drop-down list to select the printer settings.
To configure the printer, click Configure. For example, you can
enable or disable duplex printing, or schedule delayed printing, if
this functionality is supported by the printer.
Location
: Use this drop-down list to select one of the following print
destinations:
CUPS
: Print the document to a CUPS printer.
> **Note**
>
> If the selected printer is a CUPS printer, CUPS is the only
> entry in this drop-down list.
lpr
: Print the document to a printer.
File
: Print the document to a PostScript file.
Click Save As to display a dialog where you specify the name and
location of the PostScript file.
Custom
: Use the specified command to print the document.
Type the name of the command in the text box. Include all
command-line arguments.
State
: This functionality is not supported in this version of atril.
Type
: This functionality is not supported in this version of atril.
Comment
: This functionality is not supported in this version of atril.
### Paper
Paper size
: Use this drop-down list to select the size of the paper to which you
want to print the document.
Width
: Use this spin box to specify the width of the paper. Use the
adjacent drop-down list to change the measurement unit.
Height
: Use this spin box to specify the height of the paper.
Feed orientation
: Use this drop-down list to select the orientation of the paper in
the printer.
Page orientation
: Use this drop-down list to select the page orientation.
Layout
: Use this drop-down list to select the page layout. A preview of each
layout that you select is displayed in the Preview area.
Paper Tray
: Use this drop-down list to select the paper tray.
To Copy a Document
------------------
To copy a file, perform the following steps:
1. Choose File Save a Copy.
2. Type the new filename in the Filename text box in the Save a Copy
dialog.
If necessary, specify the location of the copied document. By
default, copies are saved in your home directory.
3. Click Save.
To Work With Password-Protected Documents
-----------------------------------------
An author can use the following password levels to protect a document:
- User password that allows others only to read the document.
- Master password that allows others to perform additional actions,
such as print the document.
When you try to open a password-protected document, atril displays a
security dialog. Type either the user password or the master password in
the Enter document password text box, then click Open Document.
To Close a Document
-------------------
To close a document, choose File Close.
If the window is the last atril window open, the application exits.
List of Keyboard Shortcuts
==========================
Below is a table of all shortcuts present in atril:
+-----------------------+---------------------------+
| Shortcut | Action |
+=======================+===========================+
| Ctrl-O | Open an existing document |
+-----------------------+---------------------------+
| Ctrl-S | Save a copy of the current|
| | document |
+-----------------------+---------------------------+
| Ctrl-P | Print document |
+-----------------------+---------------------------+
| Ctrl-W | Close window |
+-----------------------+------------------------------+
| Ctrl-C | Copy selection |
+-----------------------+------------------------------+
| Ctrl-A | Select All |
+-----------------------+------------------------------+
| Ctrl-F , | Find a word or phrase in the |
| | document |
| / (slash) | |
+-----------------------+------------------------------+
| Ctrl-G | Find next |
| F3 | |
+-----------------------+------------------------------+
| Ctrl + (plus sign) | Zoom in |
| | |
| + | |
| | |
| = | |
+-----------------------+---------------------------+
| Ctrl -(minus sign),- | Zoom out |
+-----------------------+---------------------------+
| Ctrl-R | Reload the document |
+-----------------------+---------------------------+
| Page Up | Go to the previous page |
+-----------------------+---------------------------+
| Page Down | Go to the next page |
+-----------------------+---------------------------+
| Space, j | Scroll forward |
| | |
| Shift Backspace | |
| | |
| Return | |
+-----------------------+---------------------------+
| Shift Space, k | Scroll backward |
| Backspace | |
+-----------------------+---------------------------+
| Shift Return | |
| Shift Page Up | Go a bunch of pages up |
+-----------------------+---------------------------+
| Shift Page Down | Go a bunch of pages down |
+-----------------------+---------------------------+
| Home | Go to the first page |
+-----------------------+---------------------------+
| End | Go to the last page |
+-----------------------+---------------------------+
| Ctrl-L | Go to page by number or label|
+-----------------------+---------------------------+
| F1 | Help |
+-----------------------+---------------------------+
| F5 | Run document as presentation|
+-----------------------+---------------------------+
| F9 | Show or hide the side pane|
+-----------------------+---------------------------+
| F11 | Toggle fullscreen mode |
+-----------------------+---------------------------+

Binary file not shown.

Before

Width:  |  Height:  |  Size: 16 KiB

After

Width:  |  Height:  |  Size: 23 KiB

Before After
Before After

View file

@ -1,4 +0,0 @@
xml docs converted to markdown using pandoc.
pandoc -S -f docbook -t markdown atril.xml -o atril.md

View file

@ -6,6 +6,10 @@ HELP_ID = atril
HELP_FILES = index.docbook legal.xml
HELP_MEDIA = figures/atril_start_window.png
HELP_LINGUAS = bg ca cs de el en_GB es eu fi fr it ja nl oc pt_BR ru sl sr sv uk vi zh_CN
# Add linguas to be ignored, e.g. IGNORE_HELP_LINGUAS = ca de es fr
IGNORE_HELP_LINGUAS =
HELP_LINGUAS = $(if $(IGNORE_HELP_LINGUAS), \
$(filter-out $(IGNORE_HELP_LINGUAS),$(subst /,,$(dir $(wildcard */*.po)))), \
$(subst /,,$(dir $(wildcard */*.po))) )
-include $(top_srcdir)/git.mk

1350
help/af/af.po Normal file

File diff suppressed because it is too large Load diff

1347
help/am/am.po Normal file

File diff suppressed because it is too large Load diff

1351
help/ar/ar.po Normal file

File diff suppressed because it is too large Load diff

1346
help/as/as.po Normal file

File diff suppressed because it is too large Load diff

1348
help/ast/ast.po Normal file

File diff suppressed because it is too large Load diff

1141
help/atril.pot Normal file

File diff suppressed because it is too large Load diff

1351
help/az/az.po Normal file

File diff suppressed because it is too large Load diff

1349
help/be/be.po Normal file

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

1351
help/bn/bn.po Normal file

File diff suppressed because it is too large Load diff

1350
help/bn_IN/bn_IN.po Normal file

File diff suppressed because it is too large Load diff

1347
help/br/br.po Normal file

File diff suppressed because it is too large Load diff

1347
help/bs/bs.po Normal file

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

Binary file not shown.

Before

Width:  |  Height:  |  Size: 15 KiB

After

Width:  |  Height:  |  Size: 16 KiB

Before After
Before After

File diff suppressed because it is too large Load diff

1349
help/cmn/cmn.po Normal file

File diff suppressed because it is too large Load diff

1348
help/crh/crh.po Normal file

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

1349
help/cy/cy.po Normal file

File diff suppressed because it is too large Load diff

1570
help/da/da.po Normal file

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

1349
help/dz/dz.po Normal file

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

1346
help/en_AU/en_AU.po Normal file

File diff suppressed because it is too large Load diff

1346
help/en_CA/en_CA.po Normal file

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

1379
help/eo/eo.po Normal file

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

1352
help/es_AR/es_AR.po Normal file

File diff suppressed because it is too large Load diff

1348
help/es_CL/es_CL.po Normal file

File diff suppressed because it is too large Load diff

1349
help/es_CO/es_CO.po Normal file

File diff suppressed because it is too large Load diff

1352
help/et/et.po Normal file

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

1348
help/fa/fa.po Normal file

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

1346
help/fur/fur.po Normal file

File diff suppressed because it is too large Load diff

1350
help/fy/fy.po Normal file

File diff suppressed because it is too large Load diff

1349
help/ga/ga.po Normal file

File diff suppressed because it is too large Load diff

1411
help/gl/gl.po Normal file

File diff suppressed because it is too large Load diff

1347
help/gu/gu.po Normal file

File diff suppressed because it is too large Load diff

1346
help/ha/ha.po Normal file

File diff suppressed because it is too large Load diff

1348
help/he/he.po Normal file

File diff suppressed because it is too large Load diff

1352
help/hi/hi.po Normal file

File diff suppressed because it is too large Load diff

1382
help/hr/hr.po Normal file

File diff suppressed because it is too large Load diff

1408
help/hu/hu.po Normal file

File diff suppressed because it is too large Load diff

1347
help/hy/hy.po Normal file

File diff suppressed because it is too large Load diff

1347
help/ia/ia.po Normal file

File diff suppressed because it is too large Load diff

1372
help/id/id.po Normal file

File diff suppressed because it is too large Load diff

1346
help/ig/ig.po Normal file

File diff suppressed because it is too large Load diff

1350
help/is/is.po Normal file

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

1346
help/ka/ka.po Normal file

File diff suppressed because it is too large Load diff

1346
help/kab/kab.po Normal file

File diff suppressed because it is too large Load diff

1347
help/kk/kk.po Normal file

File diff suppressed because it is too large Load diff

1349
help/kn/kn.po Normal file

File diff suppressed because it is too large Load diff

1371
help/ko/ko.po Normal file

File diff suppressed because it is too large Load diff

1346
help/ks/ks.po Normal file

File diff suppressed because it is too large Load diff

1346
help/ku/ku.po Normal file

File diff suppressed because it is too large Load diff

1346
help/ku_IQ/ku_IQ.po Normal file

File diff suppressed because it is too large Load diff

1346
help/ky/ky.po Normal file

File diff suppressed because it is too large Load diff

1393
help/lt/lt.po Normal file

File diff suppressed because it is too large Load diff

1349
help/lv/lv.po Normal file

File diff suppressed because it is too large Load diff

1346
help/mai/mai.po Normal file

File diff suppressed because it is too large Load diff

1346
help/mg/mg.po Normal file

File diff suppressed because it is too large Load diff

1347
help/mk/mk.po Normal file

File diff suppressed because it is too large Load diff

1348
help/ml/ml.po Normal file

File diff suppressed because it is too large Load diff

1348
help/mn/mn.po Normal file

File diff suppressed because it is too large Load diff

1347
help/mr/mr.po Normal file

File diff suppressed because it is too large Load diff

1565
help/ms/ms.po Normal file

File diff suppressed because it is too large Load diff

1359
help/nb/nb.po Normal file

File diff suppressed because it is too large Load diff

1349
help/nds/nds.po Normal file

File diff suppressed because it is too large Load diff

1350
help/ne/ne.po Normal file

File diff suppressed because it is too large Load diff

Some files were not shown because too many files have changed in this diff Show more