├── .github ├── ISSUE_TEMPLATE │ ├── bug_report.yaml │ └── feature_request.md └── workflows │ └── build.yml ├── .gitignore ├── AUTHORS ├── COPYING ├── ChangeLog ├── INSTALL.md ├── NEWS ├── README.md ├── backend ├── backend.symbols ├── comics │ ├── comics-document.c │ ├── comics-document.h │ ├── comicsdocument.xreader-backend.in │ ├── ev-archive.c │ ├── ev-archive.h │ ├── meson.build │ └── test-ev-archive.c ├── djvu │ ├── djvu-document-private.h │ ├── djvu-document.c │ ├── djvu-document.h │ ├── djvu-links.c │ ├── djvu-links.h │ ├── djvu-text-page.c │ ├── djvu-text-page.h │ ├── djvudocument.xreader-backend.in │ └── meson.build ├── dvi │ ├── cairo-device.c │ ├── cairo-device.h │ ├── dvi-document.c │ ├── dvi-document.h │ ├── dvidocument.xreader-backend.in │ ├── fonts.c │ ├── fonts.h │ ├── mdvi-lib │ │ ├── afmparse.c │ │ ├── afmparse.h │ │ ├── bitmap.c │ │ ├── bitmap.h │ │ ├── color.c │ │ ├── color.h │ │ ├── common.c │ │ ├── common.h │ │ ├── defaults.h │ │ ├── dviopcodes.h │ │ ├── dviread.c │ │ ├── files.c │ │ ├── font.c │ │ ├── fontmap.c │ │ ├── fontmap.h │ │ ├── fontsrch.c │ │ ├── gf.c │ │ ├── hash.c │ │ ├── hash.h │ │ ├── list.c │ │ ├── mdvi.h │ │ ├── meson.build │ │ ├── pagesel.c │ │ ├── paper.c │ │ ├── paper.h │ │ ├── pk.c │ │ ├── private.h │ │ ├── setup.c │ │ ├── sp-epsf.c │ │ ├── special.c │ │ ├── sysdeps.h │ │ ├── t1.c │ │ ├── tfm.c │ │ ├── tfmfile.c │ │ ├── tt.c │ │ ├── util.c │ │ └── vf.c │ └── meson.build ├── epub │ ├── epub-document.c │ ├── epub-document.h │ ├── epubdocument.xreader-backend.in │ ├── meson.build │ └── minizip │ │ ├── ioapi.c │ │ ├── ioapi.h │ │ ├── meson.build │ │ ├── unzip.c │ │ └── unzip.h ├── meson.build ├── pdf │ ├── ev-poppler.cc │ ├── ev-poppler.h │ ├── meson.build │ └── pdfdocument.xreader-backend.in ├── pixbuf │ ├── meson.build │ ├── pixbuf-document.c │ ├── pixbuf-document.h │ └── pixbufdocument.xreader-backend.in ├── ps │ ├── ev-spectre.c │ ├── ev-spectre.h │ ├── meson.build │ └── psdocument.xreader-backend.in ├── tiff │ ├── meson.build │ ├── tiff-document.c │ ├── tiff-document.h │ ├── tiff2ps.c │ ├── tiff2ps.h │ └── tiffdocument.xreader-backend.in └── xps │ ├── meson.build │ ├── xps-document.c │ ├── xps-document.h │ └── xpsdocument.xreader-backend.in ├── cut-n-paste ├── meson.build ├── smclient │ ├── eggdesktopfile.c │ ├── eggdesktopfile.h │ ├── eggsmclient-private.h │ ├── eggsmclient-xsmp.c │ ├── eggsmclient.c │ ├── eggsmclient.h │ └── meson.build ├── synctex │ ├── meson.build │ ├── synctex_parser.c │ ├── synctex_parser.h │ ├── synctex_parser_local.h │ ├── synctex_parser_utils.c │ ├── synctex_parser_utils.h │ ├── synctex_parser_version.txt │ └── update-synctex-from-TL.sh ├── totem-screensaver │ ├── README │ ├── meson.build │ ├── totem-scrsaver.c │ └── totem-scrsaver.h └── zoom-control │ ├── ephy-zoom-action.c │ ├── ephy-zoom-action.h │ ├── ephy-zoom-control.c │ ├── ephy-zoom-control.h │ ├── ephy-zoom.c │ ├── ephy-zoom.h │ └── meson.build ├── data ├── hand-open.png ├── icons │ ├── 16x16 │ │ ├── actions │ │ │ ├── object-rotate-left.png │ │ │ ├── object-rotate-right.png │ │ │ ├── view-page-continuous.png │ │ │ ├── view-page-continuous.xcf │ │ │ ├── view-page-facing.png │ │ │ ├── view-page-facing.xcf │ │ │ ├── zoom-fit-height.png │ │ │ ├── zoom-fit-page.svg │ │ │ ├── zoom-fit-width.png │ │ │ ├── zoom-fit-width.svg │ │ │ ├── zoom.png │ │ │ └── zoom.svg │ │ ├── apps │ │ │ └── xreader.png │ │ └── mimetypes │ │ │ └── x-office-presentation.png │ ├── 22x22 │ │ ├── actions │ │ │ ├── eye.png │ │ │ ├── object-rotate-left.png │ │ │ ├── object-rotate-right.png │ │ │ ├── view-page-continuous.png │ │ │ ├── view-page-continuous.xcf │ │ │ ├── view-page-facing.png │ │ │ ├── view-page-facing.xcf │ │ │ ├── zoom-fit-page.png │ │ │ ├── zoom-fit-page.svg │ │ │ ├── zoom-fit-width.png │ │ │ ├── zoom-fit-width.svg │ │ │ ├── zoom.png │ │ │ └── zoom.svg │ │ ├── apps │ │ │ └── xreader.png │ │ └── mimetypes │ │ │ └── x-office-presentation.png │ ├── 24x24 │ │ ├── actions │ │ │ ├── object-rotate-left.png │ │ │ ├── object-rotate-right.png │ │ │ ├── stock_filters-invert.png │ │ │ ├── view-page-continuous.png │ │ │ ├── view-page-facing.png │ │ │ ├── zoom-fit-height.png │ │ │ ├── zoom-fit-width.png │ │ │ └── zoom.png │ │ ├── apps │ │ │ └── xreader.png │ │ └── mimetypes │ │ │ └── x-office-presentation.png │ ├── 32x32 │ │ ├── actions │ │ │ ├── object-rotate-left.png │ │ │ ├── object-rotate-right.png │ │ │ ├── view-page-continuous.png │ │ │ └── view-page-facing.png │ │ └── mimetypes │ │ │ └── x-office-presentation.png │ ├── 48x48 │ │ ├── actions │ │ │ ├── close.png │ │ │ ├── resize-se.png │ │ │ ├── resize-sw.png │ │ │ ├── view-page-continuous.png │ │ │ └── view-page-facing.png │ │ └── apps │ │ │ └── xreader.png │ ├── meson.build │ └── scalable │ │ ├── actions │ │ ├── object-rotate-left.svg │ │ └── object-rotate-right.svg │ │ ├── apps │ │ └── xreader.svg │ │ └── mimetypes │ │ └── x-office-presentation.svg ├── meson.build ├── org.x.reader.Daemon.service.in ├── org.x.reader.gschema.xml ├── thumbnail-frame.png ├── xreader.1 ├── xreader.appdata.xml.in └── xreader.desktop.in.in ├── debian ├── changelog ├── control ├── copyright ├── gir1.2-xreader.install.in ├── libxreaderdocument-dev.install ├── libxreaderdocument3.install ├── libxreaderview-dev.install ├── libxreaderview3.install ├── rules ├── source │ └── format ├── xreader-common.install ├── xreader.install ├── xreader.postinst └── xreader.prerm ├── help ├── C │ ├── figures │ │ └── xreader_start_window.png │ ├── index.docbook │ ├── legal.xml │ ├── readme.txt │ ├── xreader.html │ └── xreader.md ├── ChangeLog ├── LINGUAS ├── bg │ └── bg.po ├── ca │ └── ca.po ├── cs │ └── cs.po ├── de │ └── de.po ├── el │ └── el.po ├── en_GB │ └── en_GB.po ├── es │ └── es.po ├── eu │ └── eu.po ├── fi │ └── fi.po ├── fr │ └── fr.po ├── it │ └── it.po ├── ja │ └── ja.po ├── meson.build ├── nl │ └── nl.po ├── oc │ └── oc.po ├── pt_BR │ └── pt_BR.po ├── reference │ ├── libdocument │ │ ├── libxreaderdocument-docs.xml │ │ ├── libxreaderdocument-overrides.txt │ │ ├── libxreaderdocument-sections.txt │ │ ├── libxreaderdocument.types │ │ ├── meson.build │ │ └── version.xml.in │ ├── libview │ │ ├── libxreaderview-docs.xml │ │ ├── libxreaderview-overrides.txt │ │ ├── libxreaderview-sections.txt │ │ ├── libxreaderview.types │ │ ├── meson.build │ │ └── version.xml.in │ └── shell │ │ ├── meson.build │ │ ├── version.xml.in │ │ ├── xreader-docs.xml │ │ ├── xreader-overrides.txt │ │ ├── xreader-sections.txt │ │ └── xreader.types ├── ru │ └── ru.po ├── sl │ └── sl.po ├── sr │ └── sr.po ├── sv │ └── sv.po ├── uk │ └── uk.po ├── vi │ └── vi.po ├── xreader.omf.in └── zh_CN │ └── zh_CN.po ├── install-scripts ├── meson.build ├── meson_install_schemas.py ├── meson_update_icon_cache.py └── meson_update_mime_database.py ├── libdocument ├── ev-annotation.c ├── ev-annotation.h ├── ev-async-renderer.c ├── ev-async-renderer.h ├── ev-attachment.c ├── ev-attachment.h ├── ev-backends-manager.c ├── ev-backends-manager.h ├── ev-debug.c ├── ev-debug.h ├── ev-document-annotations.c ├── ev-document-annotations.h ├── ev-document-attachments.c ├── ev-document-attachments.h ├── ev-document-factory.c ├── ev-document-factory.h ├── ev-document-find.c ├── ev-document-find.h ├── ev-document-fonts.c ├── ev-document-fonts.h ├── ev-document-forms.c ├── ev-document-forms.h ├── ev-document-images.c ├── ev-document-images.h ├── ev-document-info.h ├── ev-document-layers.c ├── ev-document-layers.h ├── ev-document-links.c ├── ev-document-links.h ├── ev-document-misc.c ├── ev-document-misc.h ├── ev-document-print.c ├── ev-document-print.h ├── ev-document-security.c ├── ev-document-security.h ├── ev-document-text.c ├── ev-document-text.h ├── ev-document-thumbnails.c ├── ev-document-thumbnails.h ├── ev-document-transition.c ├── ev-document-transition.h ├── ev-document-type-builtins.c.template ├── ev-document-type-builtins.h.template ├── ev-document.c ├── ev-document.h ├── ev-file-exporter.c ├── ev-file-exporter.h ├── ev-file-helpers.c ├── ev-file-helpers.h ├── ev-form-field.c ├── ev-form-field.h ├── ev-image.c ├── ev-image.h ├── ev-init.c ├── ev-init.h ├── ev-layer.c ├── ev-layer.h ├── ev-link-action.c ├── ev-link-action.h ├── ev-link-dest.c ├── ev-link-dest.h ├── ev-link.c ├── ev-link.h ├── ev-macros.h ├── ev-mapping-list.c ├── ev-mapping-list.h ├── ev-module.c ├── ev-module.h ├── ev-page.c ├── ev-page.h ├── ev-render-context.c ├── ev-render-context.h ├── ev-selection.c ├── ev-selection.h ├── ev-transition-effect.c ├── ev-transition-effect.h ├── ev-version.h.in └── meson.build ├── libmisc ├── ev-page-action-widget.c ├── ev-page-action-widget.h ├── ev-page-action.c ├── ev-page-action.h └── meson.build ├── libview ├── ev-annotation-window.c ├── ev-annotation-window.h ├── ev-document-model.c ├── ev-document-model.h ├── ev-job-scheduler.c ├── ev-job-scheduler.h ├── ev-jobs.c ├── ev-jobs.h ├── ev-link-accessible.c ├── ev-link-accessible.h ├── ev-loading-window.c ├── ev-loading-window.h ├── ev-page-cache.c ├── ev-page-cache.h ├── ev-pixbuf-cache.c ├── ev-pixbuf-cache.h ├── ev-print-operation.c ├── ev-print-operation.h ├── ev-stock-icons.c ├── ev-stock-icons.h ├── ev-timeline.c ├── ev-timeline.h ├── ev-transition-animation.c ├── ev-transition-animation.h ├── ev-view-accessible.c ├── ev-view-accessible.h ├── ev-view-cursor.c ├── ev-view-cursor.h ├── ev-view-marshal.list ├── ev-view-presentation.c ├── ev-view-presentation.h ├── ev-view-private.h ├── ev-view-type-builtins.c.template ├── ev-view-type-builtins.h.template ├── ev-view.c ├── ev-view.h ├── ev-web-view.c ├── ev-web-view.h └── meson.build ├── makepot ├── meson.build ├── meson_options.txt ├── po ├── ChangeLog ├── LINGUAS ├── POTFILES.in ├── POTFILES.skip ├── ab.po ├── af.po ├── am.po ├── ar.po ├── as.po ├── ast.po ├── az.po ├── be.po ├── be@latin.po ├── ber.po ├── bg.po ├── bn.po ├── bn_IN.po ├── br.po ├── ca.po ├── ca@valencia.po ├── cmn.po ├── cs.po ├── cy.po ├── da.po ├── de.po ├── dz.po ├── el.po ├── en@shaw.po ├── en_AU.po ├── en_CA.po ├── en_GB.po ├── eo.po ├── es.po ├── es_CO.po ├── es_VE.po ├── et.po ├── eu.po ├── fa.po ├── fi.po ├── fr.po ├── fr_CA.po ├── ga.po ├── gl.po ├── gnome-copyrights.txt ├── gu.po ├── he.po ├── hi.po ├── hr.po ├── hu.po ├── hy.po ├── ia.po ├── id.po ├── ie.po ├── is.po ├── it.po ├── ja.po ├── jv.po ├── ka.po ├── kab.po ├── kk.po ├── kn.po ├── ko.po ├── ks.po ├── ku.po ├── ky.po ├── la.po ├── lt.po ├── lv.po ├── mai.po ├── meson.build ├── mg.po ├── mk.po ├── ml.po ├── mn.po ├── mr.po ├── ms.po ├── nb.po ├── nds.po ├── ne.po ├── nl.po ├── nn.po ├── oc.po ├── or.po ├── pa.po ├── pl.po ├── ps.po ├── pt.po ├── pt_BR.po ├── ro.po ├── ru.po ├── rw.po ├── sc.po ├── si.po ├── sk.po ├── sl.po ├── sq.po ├── sr.po ├── sr@latin.po ├── sv.po ├── ta.po ├── te.po ├── th.po ├── tr.po ├── tt.po ├── uk.po ├── ur.po ├── uz.po ├── vi.po ├── wa.po ├── zgh.po ├── zh_CN.po ├── zh_HK.po └── zh_TW.po ├── previewer ├── ev-previewer-window.c ├── ev-previewer-window.h ├── ev-previewer.c ├── meson.build ├── previewer-ui.xml ├── previewer.gresource.xml ├── xreader-previewer.1 └── xreader-previewer.css ├── shell ├── eggfindbar.c ├── eggfindbar.h ├── ev-annotation-properties-dialog.c ├── ev-annotation-properties-dialog.h ├── ev-annotations-toolbar.c ├── ev-annotations-toolbar.h ├── ev-application.c ├── ev-application.h ├── ev-bookmark-action.c ├── ev-bookmark-action.h ├── ev-bookmarks.c ├── ev-bookmarks.h ├── ev-daemon-gdbus.xml ├── ev-daemon.c ├── ev-file-monitor.c ├── ev-file-monitor.h ├── ev-gdbus.xml ├── ev-history-action-widget.c ├── ev-history-action-widget.h ├── ev-history-action.c ├── ev-history-action.h ├── ev-history.c ├── ev-history.h ├── ev-keyring.c ├── ev-keyring.h ├── ev-marshal.list ├── ev-message-area.c ├── ev-message-area.h ├── ev-metadata.c ├── ev-metadata.h ├── ev-open-recent-action.c ├── ev-open-recent-action.h ├── ev-password-view.c ├── ev-password-view.h ├── ev-preferences-dialog.c ├── ev-preferences-dialog.h ├── ev-preferences-dialog.ui ├── ev-progress-message-area.c ├── ev-progress-message-area.h ├── ev-properties-dialog.c ├── ev-properties-dialog.h ├── ev-properties-fonts.c ├── ev-properties-fonts.h ├── ev-properties-license.c ├── ev-properties-license.h ├── ev-properties-view.c ├── ev-properties-view.h ├── ev-sidebar-annotations.c ├── ev-sidebar-annotations.h ├── ev-sidebar-attachments.c ├── ev-sidebar-attachments.h ├── ev-sidebar-bookmarks.c ├── ev-sidebar-bookmarks.h ├── ev-sidebar-layers.c ├── ev-sidebar-layers.h ├── ev-sidebar-links.c ├── ev-sidebar-links.h ├── ev-sidebar-page.c ├── ev-sidebar-page.h ├── ev-sidebar-thumbnails.c ├── ev-sidebar-thumbnails.h ├── ev-sidebar.c ├── ev-sidebar.h ├── ev-toolbar.c ├── ev-toolbar.h ├── ev-utils.c ├── ev-utils.h ├── ev-window-title.c ├── ev-window-title.h ├── ev-window.c ├── ev-window.h ├── ev-zoom-action.c ├── ev-zoom-action.h ├── main.c ├── meson.build ├── xreader-ui.xml ├── xreader.css └── xreader.gresource.xml ├── test ├── meson.build ├── test-encrypt.pdf ├── test-links.pdf ├── test-mime.bin ├── test-page-labels.pdf ├── testBookmarksMenu.py ├── testCommon.py ├── testEditMenu.py ├── testEncryptedFile.py ├── testFileMenu.py ├── testFileReloading.py ├── testGoMenu.py ├── testHelpMenu.py ├── testWrongFileExtension.py └── testZoom.py ├── thumbnailer ├── meson.build ├── xreader-thumbnailer.1 ├── xreader-thumbnailer.c └── xreader.thumbnailer.in ├── xreader-document.h ├── xreader-document.pc.in ├── xreader-view.h ├── xreader-view.pc.in └── xreader.pot /.github/ISSUE_TEMPLATE/feature_request.md: -------------------------------------------------------------------------------- 1 | --- 2 | name: Feature request (OBSOLETE) 3 | about: Feature requests are no longer accepted here, please use https://github.com/orgs/linuxmint/discussions instead. 4 | title: "" 5 | labels: ["FEATURE REQUEST"] 6 | assignees: '' 7 | 8 | --- 9 | 10 | Please use: 11 | 12 | https://github.com/orgs/linuxmint/discussions 13 | -------------------------------------------------------------------------------- /.github/workflows/build.yml: -------------------------------------------------------------------------------- 1 | name: Build 2 | 3 | on: 4 | push: 5 | branches: 6 | - master 7 | pull_request: 8 | branches: 9 | - master 10 | workflow_dispatch: 11 | 12 | jobs: 13 | build: 14 | uses: linuxmint/github-actions/.github/workflows/do-builds.yml@master 15 | with: 16 | commit_id: master 17 | ############################## Comma separated list - like 'linuxmint/xapp, linuxmint/cinnamon-desktop' 18 | dependencies: linuxmint/xapp 19 | ############################## 20 | -------------------------------------------------------------------------------- /AUTHORS: -------------------------------------------------------------------------------- 1 | https://github.com/linuxmint/xreader/graphs/contributors 2 | -------------------------------------------------------------------------------- /ChangeLog: -------------------------------------------------------------------------------- 1 | The ChangeLog is auto-generated when releasing. If you are seeing this, use 2 | 'git log' for a detailed list of changes. 3 | -------------------------------------------------------------------------------- /NEWS: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/NEWS -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Xreader 2 | ![build](https://github.com/linuxmint/xreader/actions/workflows/build.yml/badge.svg) 3 | 4 | **Xreader** is a document viewer capable of displaying multiple and single page 5 | document formats like PDF and Postscript. For more general information about 6 | Xreader please visit our website at https://github.com/linuxmint/xreader. 7 | 8 | This software is licensed under GNU GENERAL PUBLIC LICENSE Version 2 from June 9 | 1991 (see COPYING). 10 | 11 | ## Installation 12 | 13 | - This package may be available through your system's package manager. This is the recommended method of installation. 14 | - The latest unstable version is available for Linux Mint and LMDE in the [releases](https://github.com/linuxmint/xreader/releases) section. 15 | - See [INSTALL](INSTALL.md) for instructions for building from source. 16 | 17 | ## Hacking 18 | 19 | Our Coding Guidelines can be found under 20 | https://linuxmint-developer-guide.readthedocs.io/en/latest/guidelines.html 21 | 22 | 23 | ## Optional Backend Libraries 24 | 25 | - Poppler for PDF Backend [ http://poppler.freedesktop.org/ ] 26 | - DjVuLibre for DjVu viewing [ http://djvulibre.djvuzone.org/ ] 27 | - Rar for viewing CBR comics [ http://www.rarsoft.com/ ] 28 | - libgxps for XPS documents [ https://wiki.gnome.org/libgxps ] 29 | - GhostScript for Postscript Backend [ http://www.cs.wisc.edu/~ghost/ ] 30 | - What about libspectre [ http://libspectre.freedesktop.org/wiki/ ] 31 | - TIFF Backend 32 | - DVI Backend 33 | - Pixbuf Backend 34 | - Comics Backend 35 | - Impress Backend 36 | 37 | ----- 38 | ### Optional Programs 39 | - Freeware unrar for viewing CBR comics [ http://www.rarsoft.com/ ] 40 | - Gna! unrar (unrar-free) can be used too, though it can't decompress rar v3.0 41 | files [ http://gna.org/projects/unrar/ ] 42 | - unzip for viewing CBZ comics [ http://www.info-zip.org ] 43 | - p7zip for viewing CB7 comics [ http://p7zip.sourceforge.net/ ] 44 | -------------------------------------------------------------------------------- /backend/backend.symbols: -------------------------------------------------------------------------------- 1 | register_xreader_backend 2 | -------------------------------------------------------------------------------- /backend/comics/comics-document.h: -------------------------------------------------------------------------------- 1 | /* comics-document.h: Implementation of EvDocument for comic book archives 2 | * Copyright (C) 2005, Teemu Tervo 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2, or (at your option) 7 | * any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 17 | */ 18 | 19 | #pragma once 20 | 21 | #include "ev-macros.h" 22 | #include "ev-document.h" 23 | 24 | G_BEGIN_DECLS 25 | 26 | #define COMICS_TYPE_DOCUMENT (comics_document_get_type ()) 27 | #define COMICS_DOCUMENT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), COMICS_TYPE_DOCUMENT, ComicsDocument)) 28 | #define COMICS_IS_DOCUMENT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), COMICS_TYPE_DOCUMENT)) 29 | 30 | typedef struct _ComicsDocument ComicsDocument; 31 | 32 | GType comics_document_get_type (void) G_GNUC_CONST; 33 | GType register_evince_backend (GTypeModule *module); 34 | 35 | G_END_DECLS 36 | -------------------------------------------------------------------------------- /backend/comics/comicsdocument.xreader-backend.in: -------------------------------------------------------------------------------- 1 | [Xreader Backend] 2 | Module=comicsdocument 3 | TypeDescription=Comic Books 4 | MimeType=@COMICS_MIME_TYPES@; 5 | -------------------------------------------------------------------------------- /backend/comics/meson.build: -------------------------------------------------------------------------------- 1 | backend_desktop_conf = configuration_data() 2 | backend_desktop_conf.set('COMICS_MIME_TYPES', comic_mimetypes) 3 | 4 | backend_desktop = configure_file( 5 | input: 'comicsdocument.xreader-backend.in', 6 | output: 'comicsdocument.xreader-backend', 7 | configuration: backend_desktop_conf, 8 | install: true, 9 | install_dir: backendsdir, 10 | ) 11 | 12 | comics_sources = files( 13 | 'comics-document.c', 14 | 'ev-archive.c', 15 | ) 16 | 17 | comics_deps = [ 18 | cairo, 19 | glib, 20 | gtk, 21 | libarchive_dep, 22 | ] 23 | 24 | shared_module( 25 | 'comicsdocument', 26 | comics_sources, 27 | link_with: [libdocument], 28 | link_args: ['-Wl,-Bsymbolic', '-Wl,-z,relro', '-Wl,-z,now'], 29 | include_directories: include_dirs, 30 | dependencies: comics_deps, 31 | install: true, 32 | install_dir: backendsdir 33 | ) 34 | 35 | 36 | 37 | test_name = 'test-ev-archive' 38 | 39 | test_sources = files( 40 | 'ev-archive.c', 41 | 'test-ev-archive.c', 42 | ) 43 | 44 | executable( 45 | test_name, 46 | test_sources, 47 | include_directories: include_dirs, 48 | dependencies: comics_deps, 49 | ) 50 | -------------------------------------------------------------------------------- /backend/djvu/djvu-document-private.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Declarations used throughout the djvu classes 3 | * 4 | * Copyright (C) 2006, Michael Hofmann 5 | * 6 | * This program is free software; you can redistribute it and/or modify 7 | * it under the terms of the GNU General Public License as published by 8 | * the Free Software Foundation; either version 2, or (at your option) 9 | * any later version. 10 | * 11 | * This program is distributed in the hope that it will be useful, 12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | * GNU General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU General Public License 17 | * along with this program; if not, write to the Free Software 18 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 19 | */ 20 | 21 | #ifndef __DJVU_DOCUMENT_INTERNAL_H__ 22 | #define __DJVU_DOCUMENT_INTERNAL_H__ 23 | 24 | #include "djvu-document.h" 25 | 26 | #include 27 | 28 | struct _DjvuDocument { 29 | EvDocument parent_instance; 30 | 31 | ddjvu_context_t *d_context; 32 | ddjvu_document_t *d_document; 33 | ddjvu_format_t *d_format; 34 | ddjvu_format_t *thumbs_format; 35 | 36 | gchar *uri; 37 | 38 | /* PS exporter */ 39 | gchar *ps_filename; 40 | GString *opts; 41 | }; 42 | 43 | int djvu_document_get_n_pages (EvDocument *document); 44 | void djvu_handle_events (DjvuDocument *djvu_document, 45 | int wait, 46 | GError **error); 47 | 48 | #endif /* __DJVU_DOCUMENT_INTERNAL_H__ */ 49 | -------------------------------------------------------------------------------- /backend/djvu/djvu-document.h: -------------------------------------------------------------------------------- 1 | /* djvu-document.h: Implementation of EvDocument for djvu documents 2 | * Copyright (C) 2005, Nickolay V. Shmyrev 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2, or (at your option) 7 | * any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 17 | */ 18 | 19 | #ifndef __DJVU_DOCUMENT_H__ 20 | #define __DJVU_DOCUMENT_H__ 21 | 22 | #include "ev-document.h" 23 | 24 | G_BEGIN_DECLS 25 | 26 | #define DJVU_TYPE_DOCUMENT (djvu_document_get_type ()) 27 | #define DJVU_DOCUMENT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), DJVU_TYPE_DOCUMENT, DjvuDocument)) 28 | #define DJVU_IS_DOCUMENT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), DJVU_TYPE_DOCUMENT)) 29 | 30 | typedef struct _DjvuDocument DjvuDocument; 31 | 32 | GType djvu_document_get_type (void) G_GNUC_CONST; 33 | 34 | G_MODULE_EXPORT GType register_xreader_backend (GTypeModule *module); 35 | 36 | G_END_DECLS 37 | 38 | #endif /* __DJVU_DOCUMENT_H__ */ 39 | -------------------------------------------------------------------------------- /backend/djvu/djvu-links.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2006 Pauli Virtanen 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2, or (at your option) 7 | * any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 17 | */ 18 | 19 | #ifndef __DJVU_LINK_H__ 20 | #define __DJVU_LINK_H__ 21 | 22 | #include "ev-document-links.h" 23 | #include "djvu-document.h" 24 | 25 | #include 26 | 27 | GtkTreeModel *djvu_links_get_links_model (EvDocumentLinks *document_links); 28 | EvMappingList *djvu_links_get_links (EvDocumentLinks *document_links, 29 | gint page, 30 | double scale_factor); 31 | EvLinkDest *djvu_links_find_link_dest (EvDocumentLinks *document_links, 32 | const gchar *link_name); 33 | gint djvu_links_find_link_page (EvDocumentLinks *document_links, 34 | const gchar *link_name); 35 | gboolean djvu_links_has_document_links (EvDocumentLinks *document_links); 36 | 37 | #endif /* __DJVU_LINK_H__ */ 38 | -------------------------------------------------------------------------------- /backend/djvu/djvudocument.xreader-backend.in: -------------------------------------------------------------------------------- 1 | [Xreader Backend] 2 | Module=djvudocument 3 | _TypeDescription=DjVu Documents 4 | MimeType=image/vnd.djvu;image/vnd.djvu+multipage 5 | -------------------------------------------------------------------------------- /backend/djvu/meson.build: -------------------------------------------------------------------------------- 1 | djvu_sources = [ 2 | 'djvu-document.c', 3 | 'djvu-document.h', 4 | 'djvu-document-private.h', 5 | 'djvu-links.c', 6 | 'djvu-links.h', 7 | 'djvu-text-page.c', 8 | 'djvu-text-page.h', 9 | ] 10 | 11 | djvu_deps = [ 12 | cairo, 13 | djvu, 14 | glib, 15 | gtk 16 | ] 17 | 18 | shared_module( 19 | 'djvudocument', 20 | djvu_sources, 21 | link_with: [libdocument], 22 | link_args: ['-Wl,-Bsymbolic', '-Wl,-z,relro', '-Wl,-z,now'], 23 | include_directories: include_dirs, 24 | dependencies: djvu_deps, 25 | install: true, 26 | install_dir: backendsdir, 27 | ) 28 | 29 | custom_target( 30 | 'djvu_backend', 31 | input: 'djvudocument.xreader-backend.in', 32 | output: 'djvudocument.xreader-backend', 33 | command: [intltool_merge, '-d', '-u', po_dir, '@INPUT@', '@OUTPUT@'], 34 | install: true, 35 | install_dir: backendsdir, 36 | ) 37 | -------------------------------------------------------------------------------- /backend/dvi/cairo-device.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2007 Carlos Garcia Campos 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2, or (at your option) 7 | * any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 17 | */ 18 | 19 | #ifndef MDVI_CAIRO_DEVICE 20 | #define MDVI_CAIRO_DEVICE 21 | 22 | #include 23 | #include 24 | 25 | #include "mdvi.h" 26 | 27 | G_BEGIN_DECLS 28 | 29 | void mdvi_cairo_device_init (DviDevice *device); 30 | void mdvi_cairo_device_free (DviDevice *device); 31 | cairo_surface_t *mdvi_cairo_device_get_surface (DviDevice *device); 32 | void mdvi_cairo_device_render (DviContext* dvi); 33 | void mdvi_cairo_device_set_margins (DviDevice *device, 34 | gint xmargin, 35 | gint ymargin); 36 | void mdvi_cairo_device_set_scale (DviDevice *device, 37 | gdouble scale); 38 | 39 | G_END_DECLS 40 | 41 | #endif /* MDVI_CAIRO_DEVICE */ 42 | -------------------------------------------------------------------------------- /backend/dvi/dvi-document.h: -------------------------------------------------------------------------------- 1 | /* dvi-document.h: Implementation of EvDocument for dvi documents 2 | * Copyright (C) 2005, Nickolay V. Shmyrev 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2, or (at your option) 7 | * any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 17 | */ 18 | 19 | #ifndef __DVI_DOCUMENT_H__ 20 | #define __DVI_DOCUMENT_H__ 21 | 22 | #include "ev-document.h" 23 | 24 | G_BEGIN_DECLS 25 | 26 | #define DVI_TYPE_DOCUMENT (dvi_document_get_type ()) 27 | #define DVI_DOCUMENT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), DVI_TYPE_DOCUMENT, DviDocument)) 28 | #define DVI_IS_DOCUMENT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), DVI_TYPE_DOCUMENT)) 29 | 30 | typedef struct _DviDocument DviDocument; 31 | 32 | GType dvi_document_get_type (void) G_GNUC_CONST; 33 | 34 | G_MODULE_EXPORT GType register_xreader_backend (GTypeModule *module); 35 | 36 | G_END_DECLS 37 | 38 | #endif /* __DVI_DOCUMENT_H__ */ 39 | -------------------------------------------------------------------------------- /backend/dvi/dvidocument.xreader-backend.in: -------------------------------------------------------------------------------- 1 | [Xreader Backend] 2 | Module=dvidocument 3 | _TypeDescription=DVI Documents 4 | MimeType=application/x-dvi;application/x-bzdvi;application/x-gzdvi 5 | -------------------------------------------------------------------------------- /backend/dvi/fonts.c: -------------------------------------------------------------------------------- 1 | #include "config.h" 2 | #include "fonts.h" 3 | #include "mdvi.h" 4 | 5 | static int registered = 0; 6 | 7 | extern DviFontInfo pk_font_info; 8 | extern DviFontInfo pkn_font_info; 9 | extern DviFontInfo gf_font_info; 10 | extern DviFontInfo vf_font_info; 11 | extern DviFontInfo ovf_font_info; 12 | #if 0 13 | extern DviFontInfo tt_font_info; 14 | #endif 15 | #ifdef WITH_TYPE1_FONTS 16 | extern DviFontInfo t1_font_info; 17 | #endif 18 | extern DviFontInfo afm_font_info; 19 | extern DviFontInfo tfm_font_info; 20 | extern DviFontInfo ofm_font_info; 21 | 22 | static struct fontinfo { 23 | DviFontInfo *info; 24 | char *desc; 25 | int klass; 26 | } known_fonts[] = { 27 | {&vf_font_info, "Virtual fonts", 0}, 28 | {&ovf_font_info, "Omega's virtual fonts", 0}, 29 | #if 0 30 | {&tt_font_info, "TrueType fonts", 0}, 31 | #endif 32 | #ifdef WITH_TYPE1_FONTS 33 | {&t1_font_info, "Type1 PostScript fonts", 0}, 34 | #endif 35 | {&pk_font_info, "Packed bitmap (auto-generated)", 1}, 36 | {&pkn_font_info, "Packed bitmap", -2}, 37 | {&gf_font_info, "Metafont's generic font format", 1}, 38 | {&ofm_font_info, "Omega font metrics", -1}, 39 | {&tfm_font_info, "TeX font metrics", -1}, 40 | {&afm_font_info, "Adobe font metrics", -1}, 41 | {0, 0} 42 | }; 43 | 44 | void mdvi_register_fonts (void) 45 | { 46 | struct fontinfo *type; 47 | 48 | if (!registered) { 49 | for(type = known_fonts; type->info; type++) { 50 | mdvi_register_font_type(type->info, type->klass); 51 | } 52 | registered = 1; 53 | } 54 | return; 55 | } 56 | 57 | 58 | -------------------------------------------------------------------------------- /backend/dvi/fonts.h: -------------------------------------------------------------------------------- 1 | #ifndef MDVI_FONTS_REGISTRATION_H 2 | #define MDVI_FONTS_REGISTRATION_H 3 | 4 | void mdvi_register_fonts (void); 5 | 6 | #endif /* MDVI_FONTS_REGISTRATION_H */ 7 | -------------------------------------------------------------------------------- /backend/dvi/mdvi-lib/color.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2000, Matias Atria 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2 of the License, or 7 | * (at your option) any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 17 | */ 18 | 19 | 20 | #ifndef _COLOR_H_ 21 | #define _COLOR_H_ 22 | 23 | #include "common.h" 24 | 25 | extern Ulong *get_color_table(DviDevice *dev, 26 | int nlevels, Ulong fg, Ulong bg, double gamma, int density); 27 | 28 | extern void mdvi_set_color __PROTO((DviContext *, Ulong, Ulong)); 29 | extern void mdvi_push_color __PROTO((DviContext *, Ulong, Ulong)); 30 | extern void mdvi_pop_color __PROTO((DviContext *)); 31 | extern void mdvi_reset_color __PROTO((DviContext *)); 32 | 33 | #endif /* _COLOR_H_ */ 34 | 35 | -------------------------------------------------------------------------------- /backend/dvi/mdvi-lib/defaults.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2000, Matias Atria 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2 of the License, or 7 | * (at your option) any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 17 | */ 18 | #ifndef _MDVI_DEFAULTS_H 19 | #define _MDVI_DEFAULTS_H 1 20 | 21 | /* resolution */ 22 | #define MDVI_DPI 600 23 | #define MDVI_VDPI MDVI_DPI 24 | 25 | /* horizontal margins */ 26 | #define MDVI_HMARGIN "1in" 27 | 28 | /* vertical margins */ 29 | #define MDVI_VMARGIN "1in" 30 | 31 | /* rulers */ 32 | #define MDVI_HRUNITS "1in" 33 | #define MDVI_VRUNITS "1in" 34 | 35 | /* paper */ 36 | #define MDVI_PAPERNAME "letter" 37 | 38 | /* magnification */ 39 | #define MDVI_MAGNIFICATION 1.0 40 | 41 | /* fallback font */ 42 | #define MDVI_FALLBACK_FONT "cmr10" 43 | 44 | /* metafont mode */ 45 | #define MDVI_MFMODE NULL 46 | 47 | /* default shrinking factor */ 48 | #define MDVI_DEFAULT_SHRINKING -1 /* based on resolution */ 49 | 50 | /* default pixel density */ 51 | #define MDVI_DEFAULT_DENSITY 50 52 | 53 | /* default gamma correction */ 54 | #define MDVI_DEFAULT_GAMMA 1.0 55 | 56 | /* default window geometry */ 57 | #define MDVI_GEOMETRY NULL 58 | 59 | /* default orientation */ 60 | #define MDVI_ORIENTATION "tblr" 61 | 62 | /* colors */ 63 | #define MDVI_FOREGROUND "black" 64 | #define MDVI_BACKGROUND "white" 65 | 66 | /* flags */ 67 | #define MDVI_DEFAULT_FLAGS MDVI_ANTIALIASED 68 | 69 | #define MDVI_DEFAULT_CONFIG "mdvi.conf" 70 | 71 | #endif /* _MDVI_DEAFAULTS_H */ 72 | -------------------------------------------------------------------------------- /backend/dvi/mdvi-lib/dviopcodes.h: -------------------------------------------------------------------------------- 1 | #ifndef _MDVI_DVIOPCODES_H 2 | #define _MDVI_DVIOPCODES_H 1 3 | 4 | #define DVI_SET_CHAR0 0 5 | #define DVI_SET_CHAR1 1 6 | #define DVI_SET_CHAR_MAX 127 7 | #define DVI_SET1 128 8 | #define DVI_SET2 129 9 | #define DVI_SET3 130 10 | #define DVI_SET4 131 11 | #define DVI_SET_RULE 132 12 | #define DVI_PUT1 133 13 | #define DVI_PUT2 134 14 | #define DVI_PUT3 135 15 | #define DVI_PUT4 136 16 | #define DVI_PUT_RULE 137 17 | #define DVI_NOOP 138 18 | #define DVI_BOP 139 19 | #define DVI_EOP 140 20 | #define DVI_PUSH 141 21 | #define DVI_POP 142 22 | #define DVI_RIGHT1 143 23 | #define DVI_RIGHT2 144 24 | #define DVI_RIGHT3 145 25 | #define DVI_RIGHT4 146 26 | #define DVI_W0 147 27 | #define DVI_W1 148 28 | #define DVI_W2 149 29 | #define DVI_W3 150 30 | #define DVI_W4 151 31 | #define DVI_X0 152 32 | #define DVI_X1 153 33 | #define DVI_X2 154 34 | #define DVI_X3 155 35 | #define DVI_X4 156 36 | #define DVI_DOWN1 157 37 | #define DVI_DOWN2 158 38 | #define DVI_DOWN3 159 39 | #define DVI_DOWN4 160 40 | #define DVI_Y0 161 41 | #define DVI_Y1 162 42 | #define DVI_Y2 163 43 | #define DVI_Y3 164 44 | #define DVI_Y4 165 45 | #define DVI_Z0 166 46 | #define DVI_Z1 167 47 | #define DVI_Z2 168 48 | #define DVI_Z3 169 49 | #define DVI_Z4 170 50 | #define DVI_FNT_NUM0 171 51 | #define DVI_FNT_NUM1 172 52 | #define DVI_FNT_NUM_MAX 234 53 | #define DVI_FNT1 235 54 | #define DVI_FNT2 236 55 | #define DVI_FNT3 237 56 | #define DVI_FNT4 238 57 | #define DVI_XXX1 239 58 | #define DVI_XXX2 240 59 | #define DVI_XXX3 241 60 | #define DVI_XXX4 242 61 | #define DVI_FNT_DEF1 243 62 | #define DVI_FNT_DEF2 244 63 | #define DVI_FNT_DEF3 245 64 | #define DVI_FNT_DEF4 246 65 | #define DVI_PRE 247 66 | #define DVI_POST 248 67 | #define DVI_POST_POST 249 68 | 69 | #define DVI_ID 2 70 | #define DVI_TRAILER 223 71 | 72 | #endif /* _MDVI_DVIOPCODES_H */ 73 | -------------------------------------------------------------------------------- /backend/dvi/mdvi-lib/files.c: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2000, Matias Atria 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2 of the License, or 7 | * (at your option) any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 17 | */ 18 | 19 | #include 20 | #include 21 | #include 22 | #include 23 | #include 24 | 25 | #include "common.h" 26 | 27 | char *dgets(Dstring *dstr, FILE *in) 28 | { 29 | char buffer[256]; 30 | 31 | dstr->length = 0; 32 | if(feof(in)) 33 | return NULL; 34 | while(fgets(buffer, 256, in) != NULL) { 35 | int len = strlen(buffer); 36 | 37 | if(buffer[len-1] == '\n') { 38 | dstring_append(dstr, buffer, len - 1); 39 | break; 40 | } 41 | dstring_append(dstr, buffer, len); 42 | } 43 | if(dstr->data) 44 | dstr->data[dstr->length] = 0; 45 | return dstr->data; 46 | } 47 | 48 | /* some simple helper functions to manipulate file names */ 49 | 50 | const char *file_basename(const char *filename) 51 | { 52 | const char *ptr = strrchr(filename, '/'); 53 | 54 | return (ptr ? ptr + 1 : filename); 55 | } 56 | 57 | const char *file_extension(const char *filename) 58 | { 59 | const char *ptr = strchr(file_basename(filename), '.'); 60 | 61 | return (ptr ? ptr + 1 : NULL); 62 | } 63 | 64 | int file_readable(const char *filename) 65 | { 66 | int status = (access(filename, R_OK) == 0); 67 | 68 | DEBUG((DBG_FILES, "file_redable(%s) -> %s\n", 69 | filename, status ? "Yes" : "No")); 70 | return status; 71 | } 72 | 73 | int file_exists(const char *filename) 74 | { 75 | int status = (access(filename, F_OK) == 0); 76 | 77 | DEBUG((DBG_FILES, "file_exists(%s) -> %s\n", 78 | filename, status ? "Yes" : "No")); 79 | return status; 80 | } 81 | 82 | -------------------------------------------------------------------------------- /backend/dvi/mdvi-lib/hash.h: -------------------------------------------------------------------------------- 1 | #ifndef MDVI_HASH 2 | #define MDVI_HASH 3 | 4 | /* Hash tables */ 5 | 6 | 7 | typedef struct _DviHashBucket DviHashBucket; 8 | typedef struct _DviHashTable DviHashTable; 9 | 10 | /* 11 | * Hash tables 12 | */ 13 | 14 | typedef Uchar *DviHashKey; 15 | #define MDVI_KEY(x) ((DviHashKey)(x)) 16 | 17 | typedef Ulong (*DviHashFunc) __PROTO((DviHashKey key)); 18 | typedef int (*DviHashComp) __PROTO((DviHashKey key1, DviHashKey key2)); 19 | typedef void (*DviHashFree) __PROTO((DviHashKey key, void *data)); 20 | 21 | 22 | struct _DviHashTable { 23 | DviHashBucket **buckets; 24 | int nbucks; 25 | int nkeys; 26 | DviHashFunc hash_func; 27 | DviHashComp hash_comp; 28 | DviHashFree hash_free; 29 | }; 30 | #define MDVI_EMPTY_HASH_TABLE {NULL, 0, 0, NULL, NULL, NULL} 31 | 32 | #define MDVI_HASH_REPLACE 0 33 | #define MDVI_HASH_UNIQUE 1 34 | #define MDVI_HASH_UNCHECKED 2 35 | 36 | extern void mdvi_hash_init __PROTO((DviHashTable *)); 37 | extern void mdvi_hash_create __PROTO((DviHashTable *, int)); 38 | extern int mdvi_hash_add __PROTO((DviHashTable *, DviHashKey, void *, int)); 39 | extern int mdvi_hash_destroy_key __PROTO((DviHashTable *, DviHashKey)); 40 | extern void mdvi_hash_reset __PROTO((DviHashTable *, int)); 41 | extern void *mdvi_hash_lookup __PROTO((DviHashTable *, DviHashKey)); 42 | extern void *mdvi_hash_remove __PROTO((DviHashTable *, DviHashKey)); 43 | extern void *mdvi_hash_remove_ptr __PROTO((DviHashTable *, DviHashKey)); 44 | 45 | #define mdvi_hash_flush(h) mdvi_hash_reset((h), 1) 46 | #define mdvi_hash_destroy(h) mdvi_hash_reset((h), 0) 47 | 48 | #endif 49 | 50 | -------------------------------------------------------------------------------- /backend/dvi/mdvi-lib/meson.build: -------------------------------------------------------------------------------- 1 | mdvi_sources = [ 2 | 'afmparse.c', 3 | 'afmparse.h', 4 | 'bitmap.c', 5 | 'bitmap.h', 6 | 'color.c', 7 | 'color.h', 8 | 'common.c', 9 | 'common.h', 10 | 'defaults.h', 11 | 'dviopcodes.h', 12 | 'dviread.c', 13 | 'files.c', 14 | 'font.c', 15 | 'fontmap.c', 16 | 'fontmap.h', 17 | 'fontsrch.c', 18 | 'gf.c', 19 | 'hash.c', 20 | 'hash.h', 21 | 'list.c', 22 | 'mdvi.h', 23 | 'pagesel.c', 24 | 'paper.c', 25 | 'paper.h', 26 | 'pk.c', 27 | 'private.h', 28 | 'setup.c', 29 | 'special.c', 30 | 'sp-epsf.c', 31 | 'sysdeps.h', 32 | 't1.c', 33 | 'tfm.c', 34 | 'tfmfile.c', 35 | 'tt.c', 36 | 'util.c', 37 | 'vf.c', 38 | ] 39 | 40 | mdvi_c_args = [ 41 | '-DSIZEOF_INT=__SIZEOF_INT__', 42 | '-DSIZEOF_LONG=__SIZEOF_LONG__', 43 | '-DSIZEOF_SHORT=__SIZEOF_SHORT__', 44 | '-DSIZEOF_VOID_P=__SIZEOF_POINTER__', 45 | ] 46 | 47 | mdvi_deps = [ 48 | kpathsea, 49 | ] 50 | 51 | if t1_enabled 52 | mdvi_c_args += '-DWITH_TYPE1_FONTS' 53 | mdvi_deps += t1lib 54 | endif 55 | 56 | libmdvi = static_library( 57 | 'mdvi', 58 | mdvi_sources, 59 | c_args: mdvi_c_args, 60 | include_directories: include_dirs, 61 | dependencies: mdvi_deps, 62 | ) 63 | 64 | libmdvi_dep = declare_dependency( 65 | include_directories: include_directories('.'), 66 | link_with: libmdvi, 67 | ) 68 | -------------------------------------------------------------------------------- /backend/dvi/mdvi-lib/paper.h: -------------------------------------------------------------------------------- 1 | #ifndef MDVI_PAPER 2 | #define MDVI_PAPER 3 | 4 | typedef struct _DviPaper DviPaper; 5 | typedef struct _DviPaperSpec DviPaperSpec; 6 | 7 | typedef enum { 8 | MDVI_PAPER_CLASS_ISO, 9 | MDVI_PAPER_CLASS_US, 10 | MDVI_PAPER_CLASS_ANY, 11 | MDVI_PAPER_CLASS_CUSTOM 12 | } DviPaperClass; 13 | 14 | struct _DviPaper { 15 | DviPaperClass pclass; 16 | const char *name; 17 | double inches_wide; 18 | double inches_tall; 19 | }; 20 | 21 | struct _DviPaperSpec { 22 | const char *name; 23 | const char *width; 24 | const char *height; 25 | }; 26 | 27 | 28 | extern int mdvi_get_paper_size __PROTO((const char *, DviPaper *)); 29 | extern DviPaperSpec* mdvi_get_paper_specs __PROTO((DviPaperClass)); 30 | extern void mdvi_free_paper_specs __PROTO((DviPaperSpec *)); 31 | 32 | #endif 33 | -------------------------------------------------------------------------------- /backend/dvi/mdvi-lib/private.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2000, Matias Atria 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2 of the License, or 7 | * (at your option) any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 17 | */ 18 | #ifndef _MDVI_PRIVATE_H 19 | #define _MDVI_PRIVATE_H 1 20 | 21 | #define HAVE_PROTOTYPES 1 22 | 23 | #if STDC_HEADERS 24 | # /* kpathsea's headers (wrongly!) redefine strchr() and strrchr() to 25 | # non ANSI C functions if HAVE_STRCHR and HAVE_STRRCHR are not defined. 26 | # */ 27 | # ifndef HAVE_STRCHR 28 | # define HAVE_STRCHR 29 | # endif 30 | # ifndef HAVE_STRRCHR 31 | # define HAVE_STRRCHR 32 | # endif 33 | #endif 34 | 35 | #include 36 | #include 37 | #include 38 | #include 39 | #include 40 | #include 41 | #include 42 | #include 43 | #include 44 | 45 | #define ISSP(p) (*(p) == ' ' || *(p) == '\t') 46 | #define SKIPSP(p) while(ISSP(p)) p++ 47 | #define SKIPNSP(p) while(*(p) && !ISSP(p)) p++ 48 | 49 | #include 50 | #define _(x) gettext(x) 51 | #define _G(x) x 52 | #else 53 | #define _(x) x 54 | #define _G(x) x 55 | 56 | #if defined (__i386__) && defined (__GNUC__) && __GNUC__ >= 2 57 | #define _BREAKPOINT() do { __asm__ __volatile__ ("int $03"); } while(0) 58 | #elif defined (__alpha__) && defined (__GNUC__) && __GNUC__ >= 2 59 | #define _BREAKPOINT() do { __asm__ __volatile__ ("bpt"); } while(0) 60 | #else /* !__i386__ && !__alpha__ */ 61 | #define _BREAKPOINT() 62 | #endif /* __i386__ */ 63 | 64 | #endif /* _MDVI_PRIVATE_H */ 65 | -------------------------------------------------------------------------------- /backend/dvi/mdvi-lib/setup.c: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2000, Matias Atria 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2 of the License, or 7 | * (at your option) any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 17 | */ 18 | 19 | #include 20 | #include 21 | #include 22 | #include 23 | #include 24 | 25 | #include "mdvi.h" 26 | #include "private.h" 27 | 28 | void mdvi_init_kpathsea(const char *program, 29 | const char *mfmode, const char *font, int dpi, 30 | const char *texmfcnf) 31 | { 32 | const char *p; 33 | 34 | /* Stop meaningless output generation. */ 35 | kpse_make_tex_discard_errors = FALSE; 36 | 37 | p = strrchr(program, '/'); 38 | p = (p ? p + 1 : program); 39 | kpse_set_program_name(program, p); 40 | kpse_init_prog(p, dpi, mfmode, font); 41 | kpse_set_program_enabled(kpse_any_glyph_format, 1, kpse_src_compile); 42 | kpse_set_program_enabled(kpse_pk_format, 1, kpse_src_compile); 43 | kpse_set_program_enabled(kpse_tfm_format, 1, kpse_src_compile); 44 | kpse_set_program_enabled(kpse_ofm_format, 1, kpse_src_compile); 45 | if (texmfcnf != NULL) 46 | xputenv("TEXMFCNF", texmfcnf); 47 | } 48 | 49 | -------------------------------------------------------------------------------- /backend/dvi/meson.build: -------------------------------------------------------------------------------- 1 | subdir('mdvi-lib') 2 | 3 | dvi_sources = [ 4 | 'dvi-document.c', 5 | 'dvi-document.h', 6 | 'cairo-device.c', 7 | 'cairo-device.h', 8 | 'fonts.c', 9 | 'fonts.h', 10 | ] 11 | 12 | dvi_deps = [ 13 | cairo, 14 | glib, 15 | gtk, 16 | libmdvi_dep, 17 | math, 18 | spectre, 19 | mdvi_deps, 20 | ] 21 | 22 | shared_module( 23 | 'dvidocument', 24 | dvi_sources, 25 | link_with: [libdocument], 26 | link_whole: libmdvi, 27 | c_args: mdvi_c_args, 28 | include_directories: include_dirs, 29 | dependencies: dvi_deps, 30 | install: true, 31 | install_dir: backendsdir, 32 | ) 33 | 34 | custom_target( 35 | 'dvi_backend', 36 | input: 'dvidocument.xreader-backend.in', 37 | output: 'dvidocument.xreader-backend', 38 | command: [intltool_merge, '-d', '-u', po_dir, '@INPUT@', '@OUTPUT@'], 39 | install: true, 40 | install_dir: backendsdir, 41 | ) 42 | -------------------------------------------------------------------------------- /backend/epub/epub-document.h: -------------------------------------------------------------------------------- 1 | #ifndef __EPUB_DOCUMENT_H__ 2 | #define __EPUB_DOCUMENT_H__ 3 | 4 | #define _GNU_SOURCE 5 | #include "ev-document.h" 6 | 7 | G_BEGIN_DECLS 8 | 9 | #define EPUB_TYPE_DOCUMENT (epub_document_get_type ()) 10 | #define EPUB_DOCUMENT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), EPUB_TYPE_DOCUMENT, EpubDocument)) 11 | #define EPUB_IS_DOCUMENT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), EPUB_TYPE_DOCUMENT)) 12 | 13 | typedef struct _EpubDocument EpubDocument; 14 | 15 | GType epub_document_get_type (void) G_GNUC_CONST; 16 | 17 | G_MODULE_EXPORT GType register_xreader_backend (GTypeModule *module); 18 | 19 | G_END_DECLS 20 | 21 | #endif /* __EPUB_DOCUMENT_H__ */ 22 | -------------------------------------------------------------------------------- /backend/epub/epubdocument.xreader-backend.in: -------------------------------------------------------------------------------- 1 | [Xreader Backend] 2 | Module=epubdocument 3 | _TypeDescription=epub Documents 4 | MimeType=application/epub+zip; 5 | -------------------------------------------------------------------------------- /backend/epub/meson.build: -------------------------------------------------------------------------------- 1 | subdir('minizip') 2 | 3 | epub_sources = [ 4 | 'epub-document.c', 5 | 'epub-document.h', 6 | ] 7 | 8 | epub_deps = [ 9 | cairo, 10 | glib, 11 | gtk, 12 | xml, 13 | minizip_dep, 14 | ] 15 | 16 | shared_module( 17 | 'epubdocument', 18 | epub_sources, 19 | link_with: [libdocument], 20 | link_whole: minizip, 21 | link_args: ['-Wl,-Bsymbolic', '-Wl,-z,relro', '-Wl,-z,now'], 22 | include_directories: include_dirs, 23 | dependencies: epub_deps, 24 | install: true, 25 | install_dir: backendsdir, 26 | ) 27 | 28 | custom_target( 29 | 'epub_backend', 30 | input: 'epubdocument.xreader-backend.in', 31 | output: 'epubdocument.xreader-backend', 32 | command: [intltool_merge, '-d', '-u', po_dir, '@INPUT@', '@OUTPUT@'], 33 | install: true, 34 | install_dir: backendsdir, 35 | ) 36 | -------------------------------------------------------------------------------- /backend/epub/minizip/meson.build: -------------------------------------------------------------------------------- 1 | minizip_sources = [ 2 | 'unzip.c', 3 | 'ioapi.c', 4 | 'unzip.h', 5 | 'ioapi.h', 6 | ] 7 | 8 | minizip_deps = [ 9 | zlib 10 | ] 11 | 12 | minizip = static_library( 13 | 'minizip', 14 | minizip_sources, 15 | dependencies: minizip_deps, 16 | ) 17 | 18 | minizip_dep = declare_dependency( 19 | include_directories: include_directories('.'), 20 | link_with: minizip, 21 | ) 22 | -------------------------------------------------------------------------------- /backend/meson.build: -------------------------------------------------------------------------------- 1 | backendsdir = join_paths(prefix, libdir, meson.project_name(), binary_major_version, 'backends') 2 | 3 | foreach sub : backend_subdirs 4 | subdir(sub) 5 | endforeach 6 | -------------------------------------------------------------------------------- /backend/pdf/ev-poppler.h: -------------------------------------------------------------------------------- 1 | /* pdfdocument.h: Implementation of EvDocument for PDF 2 | * Copyright (C) 2004, Red Hat, Inc. 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2, or (at your option) 7 | * any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 17 | */ 18 | 19 | #ifndef __PDF_DOCUMENT_H__ 20 | #define __PDF_DOCUMENT_H__ 21 | 22 | #include "ev-document.h" 23 | 24 | G_BEGIN_DECLS 25 | 26 | #define PDF_TYPE_DOCUMENT (pdf_document_get_type ()) 27 | #define PDF_DOCUMENT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), PDF_TYPE_DOCUMENT, PdfDocument)) 28 | #define PDF_IS_DOCUMENT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), PDF_TYPE_DOCUMENT)) 29 | 30 | typedef struct _PdfDocument PdfDocument; 31 | typedef struct _PdfDocumentClass PdfDocumentClass; 32 | 33 | GType pdf_document_get_type (void) G_GNUC_CONST; 34 | 35 | G_MODULE_EXPORT GType register_xreader_backend (GTypeModule *module); 36 | 37 | 38 | G_END_DECLS 39 | 40 | #endif /* __PDF_DOCUMENT_H__ */ 41 | -------------------------------------------------------------------------------- /backend/pdf/meson.build: -------------------------------------------------------------------------------- 1 | pdf_sources = [ 2 | 'ev-poppler.cc', 3 | 'ev-poppler.h' 4 | ] 5 | 6 | pdf_deps = [ 7 | gtk, 8 | xml, 9 | poppler, 10 | ] 11 | 12 | shared_module( 13 | 'pdfdocument', 14 | pdf_sources, 15 | link_with: [libdocument], 16 | link_args: ['-Wl,-Bsymbolic', '-Wl,-z,relro', '-Wl,-z,now'], 17 | include_directories: include_dirs, 18 | dependencies: pdf_deps, 19 | install: true, 20 | install_dir: backendsdir, 21 | ) 22 | 23 | custom_target( 24 | 'pdf_backend', 25 | input: 'pdfdocument.xreader-backend.in', 26 | output: 'pdfdocument.xreader-backend', 27 | command: [intltool_merge, '-d', '-u', po_dir, '@INPUT@', '@OUTPUT@'], 28 | install: true, 29 | install_dir: backendsdir, 30 | ) 31 | -------------------------------------------------------------------------------- /backend/pdf/pdfdocument.xreader-backend.in: -------------------------------------------------------------------------------- 1 | [Xreader Backend] 2 | Module=pdfdocument 3 | Resident=true 4 | _TypeDescription=PDF Documents 5 | MimeType=application/pdf;application/x-bzpdf;application/x-gzpdf;application/x-xzpdf;application/x-ext-pdf; 6 | -------------------------------------------------------------------------------- /backend/pixbuf/meson.build: -------------------------------------------------------------------------------- 1 | pixbuf_sources = [ 2 | 'pixbuf-document.c', 3 | 'pixbuf-document.h' 4 | ] 5 | 6 | pixbuf_deps = [ 7 | cairo, 8 | glib, 9 | gtk, 10 | ] 11 | 12 | shared_module( 13 | 'pixbufdocument', 14 | pixbuf_sources, 15 | link_with: [libdocument], 16 | link_args: ['-Wl,-Bsymbolic', '-Wl,-z,relro', '-Wl,-z,now'], 17 | include_directories: include_dirs, 18 | dependencies: pixbuf_deps, 19 | install: true, 20 | install_dir: backendsdir, 21 | ) 22 | 23 | custom_target( 24 | 'pixbuf_backend', 25 | input: 'pixbufdocument.xreader-backend.in', 26 | output: 'pixbufdocument.xreader-backend', 27 | command: [intltool_merge, '-d', '-u', po_dir, '@INPUT@', '@OUTPUT@'], 28 | install: true, 29 | install_dir: backendsdir, 30 | ) 31 | -------------------------------------------------------------------------------- /backend/pixbuf/pixbuf-document.h: -------------------------------------------------------------------------------- 1 | /* pdfdocument.h: Implementation of EvDocument for pixbufs 2 | * Copyright (C) 2004, Anders Carlsson 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2, or (at your option) 7 | * any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 17 | */ 18 | 19 | #ifndef __PIXBUF_DOCUMENT_H__ 20 | #define __PIXBUF_DOCUMENT_H__ 21 | 22 | #include "ev-document.h" 23 | 24 | G_BEGIN_DECLS 25 | 26 | #define PIXBUF_TYPE_DOCUMENT (pixbuf_document_get_type ()) 27 | #define PIXBUF_DOCUMENT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), PIXBUF_TYPE_DOCUMENT, PixbufDocument)) 28 | #define PIXBUF_IS_DOCUMENT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), PIXBUF_TYPE_DOCUMENT)) 29 | 30 | typedef struct _PixbufDocument PixbufDocument; 31 | 32 | GType pixbuf_document_get_type (void) G_GNUC_CONST; 33 | 34 | G_MODULE_EXPORT GType register_xreader_backend (GTypeModule *module); 35 | 36 | G_END_DECLS 37 | 38 | #endif /* __PIXBUF_DOCUMENT_H__ */ 39 | -------------------------------------------------------------------------------- /backend/pixbuf/pixbufdocument.xreader-backend.in: -------------------------------------------------------------------------------- 1 | [Xreader Backend] 2 | Module=pixbufdocument 3 | _TypeDescription=Images 4 | MimeType=image/*; 5 | -------------------------------------------------------------------------------- /backend/ps/ev-spectre.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Ghostscript widget for GTK/MATE 3 | * 4 | * Copyright 1998 - 2005 The Free Software Foundation 5 | * 6 | * Authors: Jaka Mocnik, Federico Mena (Quartic), Szekeres Istvan (Pista) 7 | * 8 | * This library is free software; you can redistribute it and/or 9 | * modify it under the terms of the GNU Library General Public 10 | * License as published by the Free Software Foundation; either 11 | * version 2 of the License, or (at your option) any later version. 12 | * 13 | * This library is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 16 | * Library General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU Library General Public 19 | * License along with this library; if not, write to the 20 | * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, 21 | * Boston, MA 02110-1301, USA. 22 | */ 23 | 24 | #ifndef __PS_DOCUMENT_H__ 25 | #define __PS_DOCUMENT_H__ 26 | 27 | #include "ev-document.h" 28 | 29 | G_BEGIN_DECLS 30 | 31 | #define PS_TYPE_DOCUMENT (ps_document_get_type()) 32 | #define PS_DOCUMENT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), PS_TYPE_DOCUMENT, PSDocument)) 33 | #define PS_DOCUMENT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), PS_TYPE_DOCUMENT, PSDocumentClass)) 34 | #define PS_IS_DOCUMENT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), PS_TYPE_DOCUMENT)) 35 | #define PS_DOCUMENT_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS((obj), PS_TYPE_DOCUMENT, PSDocumentClass)) 36 | 37 | typedef struct _PSDocument PSDocument; 38 | typedef struct _PSDocumentClass PSDocumentClass; 39 | 40 | GType ps_document_get_type (void) G_GNUC_CONST; 41 | 42 | G_MODULE_EXPORT GType register_xreader_backend (GTypeModule *module); 43 | 44 | G_END_DECLS 45 | 46 | #endif /* __PS_DOCUMENT_H__ */ 47 | -------------------------------------------------------------------------------- /backend/ps/meson.build: -------------------------------------------------------------------------------- 1 | ps_sources = [ 2 | 'ev-spectre.c', 3 | 'ev-spectre.h' 4 | ] 5 | 6 | ps_deps = [ 7 | cairo, 8 | glib, 9 | gtk, 10 | spectre, 11 | ] 12 | 13 | shared_module( 14 | 'psdocument', 15 | ps_sources, 16 | link_with: [libdocument], 17 | link_args: ['-Wl,-Bsymbolic', '-Wl,-z,relro', '-Wl,-z,now'], 18 | include_directories: include_dirs, 19 | dependencies: ps_deps, 20 | install: true, 21 | install_dir: backendsdir, 22 | ) 23 | 24 | custom_target( 25 | 'ps_backend', 26 | input: 'psdocument.xreader-backend.in', 27 | output: 'psdocument.xreader-backend', 28 | command: [intltool_merge, '-d', '-u', po_dir, '@INPUT@', '@OUTPUT@'], 29 | install: true, 30 | install_dir: backendsdir, 31 | ) 32 | -------------------------------------------------------------------------------- /backend/ps/psdocument.xreader-backend.in: -------------------------------------------------------------------------------- 1 | [Xreader Backend] 2 | Module=psdocument 3 | Resident=true 4 | _TypeDescription=PostScript Documents 5 | MimeType=application/postscript;application/x-bzpostscript;application/x-gzpostscript;image/x-eps;image/x-bzeps;image/x-gzeps 6 | -------------------------------------------------------------------------------- /backend/tiff/meson.build: -------------------------------------------------------------------------------- 1 | tiff_sources = [ 2 | 'tiff-document.c', 3 | 'tiff-document.h', 4 | 'tiff2ps.c', 5 | 'tiff2ps.h', 6 | ] 7 | 8 | tiff_deps = [ 9 | cairo, 10 | glib, 11 | gtk, 12 | math, 13 | tiff, 14 | ] 15 | 16 | shared_module( 17 | 'tiffdocument', 18 | tiff_sources, 19 | link_with: [libdocument], 20 | link_args: ['-Wl,-Bsymbolic', '-Wl,-z,relro', '-Wl,-z,now'], 21 | include_directories: include_dirs, 22 | dependencies: tiff_deps, 23 | install: true, 24 | install_dir: backendsdir, 25 | ) 26 | 27 | custom_target( 28 | 'tiff_backend', 29 | input: 'tiffdocument.xreader-backend.in', 30 | output: 'tiffdocument.xreader-backend', 31 | command: [intltool_merge, '-d', '-u', po_dir, '@INPUT@', '@OUTPUT@'], 32 | install: true, 33 | install_dir: backendsdir, 34 | ) 35 | -------------------------------------------------------------------------------- /backend/tiff/tiff-document.h: -------------------------------------------------------------------------------- 1 | 2 | /* pdfdocument.h: Implementation of EvDocument for tiffs 3 | * Copyright (C) 2005, Jonathan Blandford 4 | * 5 | * This program is free software; you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation; either version 2, or (at your option) 8 | * any later version. 9 | * 10 | * This program is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with this program; if not, write to the Free Software 17 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 18 | */ 19 | 20 | #ifndef __TIFF_DOCUMENT_H__ 21 | #define __TIFF_DOCUMENT_H__ 22 | 23 | #include "ev-document.h" 24 | 25 | G_BEGIN_DECLS 26 | 27 | #define TIFF_TYPE_DOCUMENT (tiff_document_get_type ()) 28 | #define TIFF_DOCUMENT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TIFF_TYPE_DOCUMENT, TiffDocument)) 29 | #define TIFF_IS_DOCUMENT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TIFF_TYPE_DOCUMENT)) 30 | 31 | typedef struct _TiffDocument TiffDocument; 32 | 33 | GType tiff_document_get_type (void) G_GNUC_CONST; 34 | G_MODULE_EXPORT GType register_xreader_backend (GTypeModule *module); 35 | 36 | G_END_DECLS 37 | 38 | #endif /* __TIFF_DOCUMENT_H__ */ 39 | -------------------------------------------------------------------------------- /backend/tiff/tiff2ps.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2005 rpath, Inc. 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2, or (at your option) 7 | * any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 17 | */ 18 | 19 | #include 20 | #include 21 | #include "tiffio.h" 22 | 23 | typedef struct _TIFF2PSContext TIFF2PSContext; 24 | 25 | TIFF2PSContext *tiff2ps_context_new(const gchar *filename); 26 | void tiff2ps_process_page(TIFF2PSContext* ctx, TIFF* tif, 27 | double pagewidth, double pageheight, 28 | double leftmargin, double bottommargin, 29 | gboolean center); 30 | void tiff2ps_context_finalize(TIFF2PSContext* ctx); 31 | -------------------------------------------------------------------------------- /backend/tiff/tiffdocument.xreader-backend.in: -------------------------------------------------------------------------------- 1 | [Xreader Backend] 2 | Module=tiffdocument 3 | _TypeDescription=Tiff Documents 4 | MimeType=image/tiff 5 | -------------------------------------------------------------------------------- /backend/xps/meson.build: -------------------------------------------------------------------------------- 1 | xps_sources = [ 2 | 'xps-document.c', 3 | 'xps-document.h', 4 | ] 5 | 6 | xps_deps = [ 7 | cairo, 8 | glib, 9 | gtk, 10 | xps, 11 | ] 12 | 13 | shared_module( 14 | 'xpsdocument', 15 | xps_sources, 16 | link_with: [libdocument], 17 | link_args: ['-Wl,-Bsymbolic', '-Wl,-z,relro', '-Wl,-z,now'], 18 | include_directories: include_dirs, 19 | dependencies: xps_deps, 20 | install: true, 21 | install_dir: backendsdir, 22 | ) 23 | 24 | custom_target( 25 | 'xps_backend', 26 | input: 'xpsdocument.xreader-backend.in', 27 | output: 'xpsdocument.xreader-backend', 28 | command: [intltool_merge, '-d', '-u', po_dir, '@INPUT@', '@OUTPUT@'], 29 | install: true, 30 | install_dir: backendsdir, 31 | ) 32 | -------------------------------------------------------------------------------- /backend/xps/xps-document.h: -------------------------------------------------------------------------------- 1 | /* this file is part of xreader, a mate document viewer 2 | * 3 | * Copyright (C) 2010 Carlos Garcia Campos 4 | * 2012 Leandro Vital 5 | * 6 | * Xreader is free software; you can redistribute it and/or modify it 7 | * under the terms of the GNU General Public License as published by 8 | * the Free Software Foundation; either version 2 of the License, or 9 | * (at your option) any later version. 10 | * 11 | * Xreader is distributed in the hope that it will be useful, but 12 | * WITHOUT ANY WARRANTY; without even the implied warranty of 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 14 | * General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU General Public License 17 | * along with this program; if not, write to the Free Software 18 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 19 | */ 20 | 21 | #ifndef __XPS_DOCUMENT_H__ 22 | #define __XPS_DOCUMENT_H__ 23 | 24 | #include "ev-document.h" 25 | 26 | G_BEGIN_DECLS 27 | 28 | #define XPS_TYPE_DOCUMENT (xps_document_get_type()) 29 | #define XPS_DOCUMENT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), XPS_TYPE_DOCUMENT, XPSDocument)) 30 | #define XPS_DOCUMENT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), XPS_TYPE_DOCUMENT, XPSDocumentClass)) 31 | #define XPS_IS_DOCUMENT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), XPS_TYPE_DOCUMENT)) 32 | #define XPS_DOCUMENT_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS((obj), XPS_TYPE_DOCUMENT, XPSDocumentClass)) 33 | 34 | typedef struct _XPSDocument XPSDocument; 35 | typedef struct _XPSDocumentClass XPSDocumentClass; 36 | 37 | GType xps_document_get_type (void) G_GNUC_CONST; 38 | 39 | G_MODULE_EXPORT GType register_xreader_backend (GTypeModule *module); 40 | 41 | G_END_DECLS 42 | 43 | #endif /* __XPS_DOCUMENT_H__ */ 44 | -------------------------------------------------------------------------------- /backend/xps/xpsdocument.xreader-backend.in: -------------------------------------------------------------------------------- 1 | [Xreader Backend] 2 | Module=xpsdocument 3 | Resident=true 4 | _TypeDescription=XPS Documents 5 | MimeType=application/oxps;application/vnd.ms-xpsdocument 6 | -------------------------------------------------------------------------------- /cut-n-paste/meson.build: -------------------------------------------------------------------------------- 1 | subdir('zoom-control') 2 | subdir('totem-screensaver') 3 | subdir('smclient') 4 | subdir('synctex') 5 | -------------------------------------------------------------------------------- /cut-n-paste/smclient/eggsmclient-private.h: -------------------------------------------------------------------------------- 1 | /* eggsmclient-private.h 2 | * Copyright (C) 2007 Novell, Inc. 3 | * 4 | * This library is free software; you can redistribute it and/or 5 | * modify it under the terms of the GNU Lesser General Public 6 | * License as published by the Free Software Foundation; either 7 | * version 2 of the License, or (at your option) any later version. 8 | * 9 | * This library is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 12 | * Lesser General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU Lesser General Public 15 | * License along with this library; if not, write to the 16 | * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, 17 | * Boston, MA 02110-1301, USA. 18 | */ 19 | 20 | #ifndef __EGG_SM_CLIENT_PRIVATE_H__ 21 | #define __EGG_SM_CLIENT_PRIVATE_H__ 22 | 23 | #include "eggsmclient.h" 24 | 25 | G_BEGIN_DECLS 26 | 27 | GKeyFile *egg_sm_client_save_state (EggSMClient *client); 28 | void egg_sm_client_quit_requested (EggSMClient *client); 29 | void egg_sm_client_quit_cancelled (EggSMClient *client); 30 | void egg_sm_client_quit (EggSMClient *client); 31 | 32 | GType egg_sm_client_xsmp_get_type (void); 33 | EggSMClient *egg_sm_client_xsmp_new (void); 34 | 35 | G_END_DECLS 36 | 37 | 38 | #endif /* __EGG_SM_CLIENT_PRIVATE_H__ */ 39 | -------------------------------------------------------------------------------- /cut-n-paste/smclient/meson.build: -------------------------------------------------------------------------------- 1 | smclient_sources = [ 2 | 'eggsmclient.c', 3 | 'eggsmclient.h', 4 | 'eggsmclient-private.h', 5 | 'eggdesktopfile.c', 6 | 'eggdesktopfile.h', 7 | 'eggsmclient-xsmp.c', 8 | ] 9 | 10 | smclient_deps = [ 11 | config_h, 12 | gio, 13 | glib, 14 | gtk, 15 | ice, 16 | sm, 17 | ] 18 | 19 | libsmclient = static_library( 20 | 'smclient', 21 | smclient_sources, 22 | dependencies: smclient_deps, 23 | include_directories: include_dirs, 24 | ) 25 | 26 | libsmclient_dep = declare_dependency( 27 | link_with: libsmclient, 28 | dependencies: smclient_deps, 29 | include_directories: [include_root, include_directories('.')], 30 | ) 31 | -------------------------------------------------------------------------------- /cut-n-paste/synctex/meson.build: -------------------------------------------------------------------------------- 1 | synctex_sources = [ 2 | 'synctex_parser.c', 3 | 'synctex_parser.h', 4 | 'synctex_parser_utils.h', 5 | 'synctex_parser_utils.c', 6 | ] 7 | 8 | synctex_deps = [ 9 | zlib, 10 | ] 11 | 12 | libsynctex = static_library( 13 | 'synctex', 14 | synctex_sources, 15 | dependencies: synctex_deps, 16 | ) 17 | 18 | libsynctex_dep = declare_dependency( 19 | link_with: libsynctex, 20 | dependencies: synctex_deps, 21 | include_directories: include_directories('.'), 22 | ) 23 | -------------------------------------------------------------------------------- /cut-n-paste/synctex/synctex_parser.c: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/cut-n-paste/synctex/synctex_parser.c -------------------------------------------------------------------------------- /cut-n-paste/synctex/synctex_parser_local.h: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright (c) 2008, 2009, 2010 , 2011 jerome DOT laurens AT u-bourgogne DOT fr 3 | 4 | This file is part of the SyncTeX package. 5 | 6 | Latest Revision: Tue Jun 14 08:23:30 UTC 2011 7 | 8 | Version: 1.18 9 | 10 | See synctex_parser_readme.txt for more details 11 | 12 | License: 13 | -------- 14 | Permission is hereby granted, free of charge, to any person 15 | obtaining a copy of this software and associated documentation 16 | files (the "Software"), to deal in the Software without 17 | restriction, including without limitation the rights to use, 18 | copy, modify, merge, publish, distribute, sublicense, and/or sell 19 | copies of the Software, and to permit persons to whom the 20 | Software is furnished to do so, subject to the following 21 | conditions: 22 | 23 | The above copyright notice and this permission notice shall be 24 | included in all copies or substantial portions of the Software. 25 | 26 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 27 | EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES 28 | OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 29 | NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT 30 | HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 31 | WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 32 | FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 33 | OTHER DEALINGS IN THE SOFTWARE 34 | 35 | Except as contained in this notice, the name of the copyright holder 36 | shall not be used in advertising or otherwise to promote the sale, 37 | use or other dealings in this Software without prior written 38 | authorization from the copyright holder. 39 | 40 | */ 41 | 42 | /* This local header file is for TEXLIVE, use your own header to fit your system */ 43 | # include /* for inline && HAVE_xxx */ 44 | /* No inlining for synctex tool in texlive. */ 45 | # define SYNCTEX_INLINE 46 | -------------------------------------------------------------------------------- /cut-n-paste/synctex/synctex_parser_version.txt: -------------------------------------------------------------------------------- 1 | 1.18 -------------------------------------------------------------------------------- /cut-n-paste/synctex/update-synctex-from-TL.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # update-synctex-from-TL.sh 3 | # 4 | # Get latest synctex parser from TexLive SVN repository. 5 | SVN_URI=svn://tug.org/texlive/trunk/Build/source/texk/web2c/synctexdir 6 | SCRIPT_NAME=update-synctex-from-TL.sh 7 | FILES="synctex_parser_version.txt synctex_parser.c synctex_parser.h synctex_parser_local.h synctex_parser_utils.c synctex_parser_utils.h" 8 | 9 | echo "Obtaining latest version of the sources" 10 | for FILE in $FILES 11 | do 12 | svn export $SVN_URI/$FILE 13 | done 14 | 15 | 16 | -------------------------------------------------------------------------------- /cut-n-paste/totem-screensaver/README: -------------------------------------------------------------------------------- 1 | The sources for the screensaver enabling/disabling code are copied from Totem. 2 | A simple replacement (s/WITH_DBUS/ENABLE_DBUS/g) was needed. The hardcoded 3 | "reason for inhibiting" string was also modified. 4 | -------------------------------------------------------------------------------- /cut-n-paste/totem-screensaver/meson.build: -------------------------------------------------------------------------------- 1 | totem_screensaver_sources = [ 2 | 'totem-scrsaver.h', 3 | 'totem-scrsaver.c', 4 | ] 5 | 6 | totem_screensaver_deps = [ 7 | config_h, 8 | gtk, 9 | X11, 10 | ] 11 | 12 | libtotemscrsaver = static_library( 13 | 'totemscrsaver', 14 | totem_screensaver_sources, 15 | dependencies: totem_screensaver_deps, 16 | include_directories: include_root, 17 | ) 18 | 19 | libtotemscrsaver_dep = declare_dependency( 20 | link_with: libtotemscrsaver, 21 | dependencies: totem_screensaver_deps, 22 | include_directories: [include_root, include_directories('.')], 23 | ) 24 | -------------------------------------------------------------------------------- /cut-n-paste/totem-screensaver/totem-scrsaver.h: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright (C) 2004, Bastien Nocera 3 | 4 | The Mate Library is free software; you can redistribute it and/or 5 | modify it under the terms of the GNU Library General Public License as 6 | published by the Free Software Foundation; either version 2 of the 7 | License, or (at your option) any later version. 8 | 9 | The Mate Library is distributed in the hope that it will be useful, 10 | but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 12 | Library General Public License for more details. 13 | 14 | You should have received a copy of the GNU Library General Public 15 | License along with the Mate Library; see the file COPYING.LIB. If not, 16 | write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, 17 | Boston, MA 02110-1301 USA. 18 | 19 | Author: Bastien Nocera 20 | */ 21 | 22 | #ifndef TOTEM_SCRSAVER_H 23 | #define TOTEM_SCRSAVER_H 24 | 25 | #include 26 | 27 | G_BEGIN_DECLS 28 | 29 | #define TOTEM_TYPE_SCRSAVER (totem_scrsaver_get_type ()) 30 | #define TOTEM_SCRSAVER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TOTEM_TYPE_SCRSAVER, TotemScrsaver)) 31 | #define TOTEM_SCRSAVER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TOTEM_TYPE_SCRSAVER, TotemScrsaverClass)) 32 | #define TOTEM_IS_SCRSAVER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TOTEM_TYPE_SCRSAVER)) 33 | #define TOTEM_IS_SCRSAVER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TOTEM_TYPE_SCRSAVER)) 34 | 35 | typedef struct TotemScrsaver TotemScrsaver; 36 | typedef struct TotemScrsaverClass TotemScrsaverClass; 37 | typedef struct TotemScrsaverPrivate TotemScrsaverPrivate; 38 | 39 | struct TotemScrsaver { 40 | GObject parent; 41 | TotemScrsaverPrivate *priv; 42 | }; 43 | 44 | struct TotemScrsaverClass { 45 | GObjectClass parent_class; 46 | }; 47 | 48 | GType totem_scrsaver_get_type (void) G_GNUC_CONST; 49 | TotemScrsaver *totem_scrsaver_new (void); 50 | void totem_scrsaver_enable (TotemScrsaver *scr); 51 | void totem_scrsaver_disable (TotemScrsaver *scr); 52 | void totem_scrsaver_set_state (TotemScrsaver *scr, 53 | gboolean enable); 54 | 55 | G_END_DECLS 56 | 57 | #endif /* !TOTEM_SCRSAVER_H */ 58 | -------------------------------------------------------------------------------- /cut-n-paste/zoom-control/ephy-zoom.c: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2003 Christian Persch 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2, or (at your option) 7 | * any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 17 | * 18 | * $Id$ 19 | */ 20 | 21 | #include "config.h" 22 | 23 | #include "ephy-zoom.h" 24 | 25 | #include 26 | 27 | guint 28 | ephy_zoom_get_zoom_level_index (float level) 29 | { 30 | guint i; 31 | float previous, current, mean; 32 | 33 | /* Handle our options at the beginning of the list. */ 34 | if (level == EPHY_ZOOM_BEST_FIT) { 35 | return 0; 36 | } else if (level == EPHY_ZOOM_FIT_WIDTH) { 37 | return 1; 38 | } else if (level == EPHY_ZOOM_EXPAND_WINDOW_TO_FIT) { 39 | return 2; 40 | } 41 | 42 | previous = zoom_levels[4].level; 43 | 44 | for (i = 5; i < n_zoom_levels; i++) 45 | { 46 | current = zoom_levels[i].level; 47 | mean = sqrt (previous * current); 48 | 49 | if (level <= mean) return i - 1; 50 | 51 | previous = current; 52 | } 53 | 54 | return n_zoom_levels - 1; 55 | } 56 | 57 | 58 | float 59 | ephy_zoom_get_changed_zoom_level (float level, gint steps) 60 | { 61 | guint index; 62 | 63 | index = ephy_zoom_get_zoom_level_index (level); 64 | return zoom_levels[CLAMP(index + steps, 3, n_zoom_levels - 1)].level; 65 | } 66 | 67 | float ephy_zoom_get_nearest_zoom_level (float level) 68 | { 69 | return ephy_zoom_get_changed_zoom_level (level, 0); 70 | } 71 | -------------------------------------------------------------------------------- /cut-n-paste/zoom-control/meson.build: -------------------------------------------------------------------------------- 1 | zoom_sources = [ 2 | 'ephy-zoom-action.h', 3 | 'ephy-zoom-action.c', 4 | 'ephy-zoom-control.c', 5 | 'ephy-zoom-control.h', 6 | 'ephy-zoom.c', 7 | 'ephy-zoom.h', 8 | ] 9 | 10 | zoom_deps = [ 11 | config_h, 12 | glib, 13 | gtk, 14 | math 15 | ] 16 | 17 | libephyzoom = static_library( 18 | 'libephyzoom', 19 | zoom_sources, 20 | include_directories: include_root, 21 | dependencies: zoom_deps, 22 | ) 23 | 24 | libephyzoom_dep = declare_dependency( 25 | link_with: libephyzoom, 26 | include_directories: [include_root, include_directories('.')], 27 | dependencies: zoom_deps, 28 | ) 29 | -------------------------------------------------------------------------------- /data/hand-open.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/hand-open.png -------------------------------------------------------------------------------- /data/icons/16x16/actions/object-rotate-left.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/16x16/actions/object-rotate-left.png -------------------------------------------------------------------------------- /data/icons/16x16/actions/object-rotate-right.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/16x16/actions/object-rotate-right.png -------------------------------------------------------------------------------- /data/icons/16x16/actions/view-page-continuous.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/16x16/actions/view-page-continuous.png -------------------------------------------------------------------------------- /data/icons/16x16/actions/view-page-continuous.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/16x16/actions/view-page-continuous.xcf -------------------------------------------------------------------------------- /data/icons/16x16/actions/view-page-facing.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/16x16/actions/view-page-facing.png -------------------------------------------------------------------------------- /data/icons/16x16/actions/view-page-facing.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/16x16/actions/view-page-facing.xcf -------------------------------------------------------------------------------- /data/icons/16x16/actions/zoom-fit-height.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/16x16/actions/zoom-fit-height.png -------------------------------------------------------------------------------- /data/icons/16x16/actions/zoom-fit-width.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/16x16/actions/zoom-fit-width.png -------------------------------------------------------------------------------- /data/icons/16x16/actions/zoom.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/16x16/actions/zoom.png -------------------------------------------------------------------------------- /data/icons/16x16/apps/xreader.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/16x16/apps/xreader.png -------------------------------------------------------------------------------- /data/icons/16x16/mimetypes/x-office-presentation.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/16x16/mimetypes/x-office-presentation.png -------------------------------------------------------------------------------- /data/icons/22x22/actions/eye.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/22x22/actions/eye.png -------------------------------------------------------------------------------- /data/icons/22x22/actions/object-rotate-left.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/22x22/actions/object-rotate-left.png -------------------------------------------------------------------------------- /data/icons/22x22/actions/object-rotate-right.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/22x22/actions/object-rotate-right.png -------------------------------------------------------------------------------- /data/icons/22x22/actions/view-page-continuous.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/22x22/actions/view-page-continuous.png -------------------------------------------------------------------------------- /data/icons/22x22/actions/view-page-continuous.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/22x22/actions/view-page-continuous.xcf -------------------------------------------------------------------------------- /data/icons/22x22/actions/view-page-facing.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/22x22/actions/view-page-facing.png -------------------------------------------------------------------------------- /data/icons/22x22/actions/view-page-facing.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/22x22/actions/view-page-facing.xcf -------------------------------------------------------------------------------- /data/icons/22x22/actions/zoom-fit-page.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/22x22/actions/zoom-fit-page.png -------------------------------------------------------------------------------- /data/icons/22x22/actions/zoom-fit-width.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/22x22/actions/zoom-fit-width.png -------------------------------------------------------------------------------- /data/icons/22x22/actions/zoom.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/22x22/actions/zoom.png -------------------------------------------------------------------------------- /data/icons/22x22/apps/xreader.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/22x22/apps/xreader.png -------------------------------------------------------------------------------- /data/icons/22x22/mimetypes/x-office-presentation.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/22x22/mimetypes/x-office-presentation.png -------------------------------------------------------------------------------- /data/icons/24x24/actions/object-rotate-left.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/24x24/actions/object-rotate-left.png -------------------------------------------------------------------------------- /data/icons/24x24/actions/object-rotate-right.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/24x24/actions/object-rotate-right.png -------------------------------------------------------------------------------- /data/icons/24x24/actions/stock_filters-invert.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/24x24/actions/stock_filters-invert.png -------------------------------------------------------------------------------- /data/icons/24x24/actions/view-page-continuous.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/24x24/actions/view-page-continuous.png -------------------------------------------------------------------------------- /data/icons/24x24/actions/view-page-facing.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/24x24/actions/view-page-facing.png -------------------------------------------------------------------------------- /data/icons/24x24/actions/zoom-fit-height.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/24x24/actions/zoom-fit-height.png -------------------------------------------------------------------------------- /data/icons/24x24/actions/zoom-fit-width.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/24x24/actions/zoom-fit-width.png -------------------------------------------------------------------------------- /data/icons/24x24/actions/zoom.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/24x24/actions/zoom.png -------------------------------------------------------------------------------- /data/icons/24x24/apps/xreader.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/24x24/apps/xreader.png -------------------------------------------------------------------------------- /data/icons/24x24/mimetypes/x-office-presentation.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/24x24/mimetypes/x-office-presentation.png -------------------------------------------------------------------------------- /data/icons/32x32/actions/object-rotate-left.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/32x32/actions/object-rotate-left.png -------------------------------------------------------------------------------- /data/icons/32x32/actions/object-rotate-right.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/32x32/actions/object-rotate-right.png -------------------------------------------------------------------------------- /data/icons/32x32/actions/view-page-continuous.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/32x32/actions/view-page-continuous.png -------------------------------------------------------------------------------- /data/icons/32x32/actions/view-page-facing.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/32x32/actions/view-page-facing.png -------------------------------------------------------------------------------- /data/icons/32x32/mimetypes/x-office-presentation.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/32x32/mimetypes/x-office-presentation.png -------------------------------------------------------------------------------- /data/icons/48x48/actions/close.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/48x48/actions/close.png -------------------------------------------------------------------------------- /data/icons/48x48/actions/resize-se.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/48x48/actions/resize-se.png -------------------------------------------------------------------------------- /data/icons/48x48/actions/resize-sw.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/48x48/actions/resize-sw.png -------------------------------------------------------------------------------- /data/icons/48x48/actions/view-page-continuous.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/48x48/actions/view-page-continuous.png -------------------------------------------------------------------------------- /data/icons/48x48/actions/view-page-facing.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/48x48/actions/view-page-facing.png -------------------------------------------------------------------------------- /data/icons/48x48/apps/xreader.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/icons/48x48/apps/xreader.png -------------------------------------------------------------------------------- /data/meson.build: -------------------------------------------------------------------------------- 1 | subdir('icons') 2 | 3 | data_dir = include_directories('.') 4 | 5 | install_data( 6 | 'xreader.1', 7 | install_dir : join_paths(get_option('prefix'), get_option('mandir'), 'man1') 8 | ) 9 | 10 | service_conf = configuration_data() 11 | service_conf.set('libexecdir', join_paths(prefix, libexecdir)) 12 | 13 | configure_file( 14 | input: 'org.x.reader.Daemon.service.in', 15 | output: 'org.x.reader.Daemon.service', 16 | configuration: service_conf, 17 | install_dir: join_paths(datadir, 'dbus-1', 'services') 18 | ) 19 | 20 | schema_file = install_data( 21 | 'org.x.reader.gschema.xml', 22 | install_dir: join_paths(datadir, 'glib-2.0', 'schemas') 23 | ) 24 | 25 | desktop_conf = configuration_data() 26 | desktop_conf.set('XREADER_MIME_TYPES', xreader_mime_types) 27 | 28 | desktop = configure_file( 29 | input: 'xreader.desktop.in.in', 30 | output: 'xreader.desktop.in', 31 | configuration: desktop_conf, 32 | ) 33 | 34 | custom_target( 35 | 'desktop', 36 | input: desktop, 37 | output: 'xreader.desktop', 38 | command: [intltool_merge, '-d', '-u', po_dir, '@INPUT@', '@OUTPUT@'], 39 | install: true, 40 | install_dir: desktopdir, 41 | ) 42 | 43 | appdata = custom_target( 44 | 'appdata', 45 | input: 'xreader.appdata.xml.in', 46 | output: 'xreader.appdata.xml', 47 | command: [intltool_merge, '-x', '-u', po_dir, '@INPUT@', '@OUTPUT@'], 48 | install: true, 49 | install_dir: join_paths(datadir, 'metainfo'), 50 | ) 51 | 52 | install_data( 53 | 'hand-open.png', 54 | install_dir: join_paths(prefix, datadir, meson.project_name()) 55 | ) 56 | -------------------------------------------------------------------------------- /data/org.x.reader.Daemon.service.in: -------------------------------------------------------------------------------- 1 | [D-BUS Service] 2 | Name=org.x.reader.Daemon 3 | Exec=@libexecdir@/xreaderd 4 | -------------------------------------------------------------------------------- /data/thumbnail-frame.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/data/thumbnail-frame.png -------------------------------------------------------------------------------- /data/xreader.appdata.xml.in: -------------------------------------------------------------------------------- 1 | 2 | 3 | xreader.desktop 4 | CC0-1.0 5 | GPL-2.0+ 6 | Document Viewer 7 | <_summary>A Document Viewer 8 | <_description> 9 |

10 | Xreader is a simple multi-page document viewer. It can display and 11 | print PostScript (PS), Encapsulated PostScript (EPS), DJVU, DVI, 12 | XPS and Portable Document Format (PDF) files, as well as comic book 13 | archive files. When supported by the document, it also allows 14 | searching for text, copying text to the clipboard, hypertext navigation 15 | and table-of-contents bookmarks. 16 |

17 | 18 | http://github.com/linuxmint/xreader 19 | Linux Mint 20 |
21 | -------------------------------------------------------------------------------- /data/xreader.desktop.in.in: -------------------------------------------------------------------------------- 1 | [Desktop Entry] 2 | _Name=Document Viewer 3 | _Comment=View multi-page documents 4 | TryExec=xreader 5 | Exec=xreader %U 6 | StartupNotify=true 7 | Terminal=false 8 | Type=Application 9 | Icon=xreader 10 | Categories=GTK;Utility;Viewer; 11 | Keywords=document;viewer;pdf;dvi;ps;xps;tiff;djvu;comics; 12 | MimeType=@XREADER_MIME_TYPES@ 13 | -------------------------------------------------------------------------------- /debian/gir1.2-xreader.install.in: -------------------------------------------------------------------------------- 1 | TYPELIBDIR/girepository-1.0 2 | usr/share/gir-1.0 3 | -------------------------------------------------------------------------------- /debian/libxreaderdocument-dev.install: -------------------------------------------------------------------------------- 1 | usr/include/xreader/*/*document* 2 | usr/lib/*/*document*.so 3 | usr/lib/*/pkgconfig/*document* 4 | -------------------------------------------------------------------------------- /debian/libxreaderdocument3.install: -------------------------------------------------------------------------------- 1 | usr/lib/*/*document*.so.* 2 | usr/lib/*/xreader/ 3 | -------------------------------------------------------------------------------- /debian/libxreaderview-dev.install: -------------------------------------------------------------------------------- 1 | usr/include/xreader/*/*view* 2 | usr/lib/*/*view*.so 3 | usr/lib/*/pkgconfig/*view* 4 | -------------------------------------------------------------------------------- /debian/libxreaderview3.install: -------------------------------------------------------------------------------- 1 | usr/lib/*/*view*.so.* 2 | -------------------------------------------------------------------------------- /debian/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | 3 | TYPELIBDIR=$(shell pkg-config gobject-introspection-1.0 --variable libdir | sed -e 's/.//') 4 | 5 | %: 6 | dh $@ 7 | 8 | override_dh_install: 9 | sed 's@TYPELIBDIR@${TYPELIBDIR}@' debian/gir1.2-xreader.install.in > debian/gir1.2-xreader.install 10 | dh_install 11 | 12 | override_dh_auto_configure: 13 | dh_auto_configure -- \ 14 | --prefix=/usr \ 15 | --libexecdir=/usr/libexec \ 16 | --buildtype=debugoptimized \ 17 | -D deprecated_warnings=false \ 18 | -D djvu=true \ 19 | -D dvi=true \ 20 | -D t1lib=true \ 21 | -D pixbuf=false \ 22 | -D comics=true \ 23 | -D introspection=true \ 24 | -D help_files=true \ 25 | # --disable-static \ 26 | 27 | override_dh_strip: 28 | dh_strip -pxreader --dbg-package=xreader-dbg 29 | dh_strip -plibxreaderdocument3 --dbg-package=libxreaderdocument3-dbg 30 | dh_strip -plibxreaderview3 --dbg-package=libxreaderview3-dbg 31 | 32 | override_dh_auto_test: 33 | 34 | override_dh_missing: 35 | dh_missing --fail-missing -------------------------------------------------------------------------------- /debian/source/format: -------------------------------------------------------------------------------- 1 | 3.0 (native) 2 | -------------------------------------------------------------------------------- /debian/xreader-common.install: -------------------------------------------------------------------------------- 1 | usr/share/metainfo/ 2 | usr/share/xreader/ 3 | #usr/share/gtk-doc/ docs temporarily disabled because it doesn't work for meson < 0.48 4 | usr/share/help/ 5 | usr/share/icons/ 6 | usr/share/locale/ 7 | usr/share/thumbnailers/ 8 | -------------------------------------------------------------------------------- /debian/xreader.install: -------------------------------------------------------------------------------- 1 | usr/bin/ 2 | usr/libexec/xreaderd 3 | usr/share/applications/xreader.desktop 4 | usr/share/dbus-1/ 5 | usr/share/glib-2.0/ 6 | usr/share/man/ 7 | -------------------------------------------------------------------------------- /debian/xreader.postinst: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | set -e 4 | 5 | case "$1" in 6 | configure) 7 | # Make sure evince is present, or provide a symlink to xreader 8 | # This is needed for GTK print previews, which call "evince". 9 | if [ ! -f /usr/bin/evince ] 10 | then 11 | echo "/usr/bin/evince not found, providing symlink." 12 | ln -s /usr/bin/xreader /usr/bin/evince 13 | fi 14 | ;; 15 | abort-upgrade|abort-remove|abort-deconfigure) 16 | ;; 17 | triggered) 18 | ;; 19 | *) 20 | echo "postinst called with unknown argument \`$1'" >&2 21 | exit 0 22 | ;; 23 | esac 24 | 25 | exit 0 26 | 27 | 28 | -------------------------------------------------------------------------------- /debian/xreader.prerm: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | set -e 4 | 5 | # Remove our evince symlink 6 | if [ -L /usr/bin/evince ] 7 | then 8 | echo "Removing /usr/bin/evince symbolic link." 9 | rm -f /usr/bin/evince 10 | fi 11 | 12 | exit 0 13 | -------------------------------------------------------------------------------- /help/C/figures/xreader_start_window.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/help/C/figures/xreader_start_window.png -------------------------------------------------------------------------------- /help/C/readme.txt: -------------------------------------------------------------------------------- 1 | xml docs converted to markdown using pandoc. 2 | 3 | pandoc -S -f docbook -t markdown xreader.xml -o xreader.md 4 | 5 | -------------------------------------------------------------------------------- /help/LINGUAS: -------------------------------------------------------------------------------- 1 | bg 2 | ca 3 | cs 4 | de 5 | el 6 | en_GB 7 | es 8 | eu 9 | fi 10 | fr 11 | it 12 | ja 13 | nl 14 | oc 15 | pt_BR 16 | ru 17 | sl 18 | sr 19 | sv 20 | uk 21 | vi 22 | zh_CN 23 | -------------------------------------------------------------------------------- /help/meson.build: -------------------------------------------------------------------------------- 1 | # developer docs 2 | if get_option('docs') 3 | glib_prefix = glib.get_pkgconfig_variable('prefix') 4 | gtk_prefix = gtk.get_pkgconfig_variable('prefix') 5 | 6 | fixref_args = [ 7 | '--extra-dir=' + join_paths(glib_prefix, gnome.gtkdoc_html_dir('glib')), 8 | '--extra-dir=' + join_paths(glib_prefix, gnome.gtkdoc_html_dir('gio')), 9 | '--extra-dir=' + join_paths(gtk_prefix, gnome.gtkdoc_html_dir('gdk')), 10 | '--extra-dir=' + join_paths(gtk_prefix, gnome.gtkdoc_html_dir('gdk-pixbuf')), 11 | '--extra-dir=' + join_paths(gtk_prefix, gnome.gtkdoc_html_dir('gtk')), 12 | ] 13 | 14 | subdir('reference/libdocument') 15 | subdir('reference/libview') 16 | subdir('reference/shell') 17 | endif 18 | 19 | # help files 20 | if get_option('help_files') 21 | help_sources = [ 22 | 'index.docbook', 23 | 'legal.xml', 24 | ] 25 | 26 | help_media = [ 27 | 'figures/xreader_start_window.png', 28 | ] 29 | 30 | gnome.yelp( 31 | meson.project_name(), 32 | sources: help_sources, 33 | media: help_media, 34 | ) 35 | endif 36 | -------------------------------------------------------------------------------- /help/reference/libdocument/libxreaderdocument-overrides.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/help/reference/libdocument/libxreaderdocument-overrides.txt -------------------------------------------------------------------------------- /help/reference/libdocument/libxreaderdocument.types: -------------------------------------------------------------------------------- 1 | ev_annotation_attachment_get_type 2 | ev_annotation_get_type 3 | ev_annotation_markup_get_type 4 | ev_annotation_text_get_type 5 | ev_async_renderer_get_type 6 | ev_attachment_get_type 7 | ev_compression_type_get_type 8 | ev_document_annotations_get_type 9 | ev_document_attachments_get_type 10 | ev_document_error_get_type 11 | ev_document_find_get_type 12 | ev_document_fonts_get_type 13 | ev_document_forms_get_type 14 | ev_document_get_type 15 | ev_document_images_get_type 16 | ev_document_info_fields_get_type 17 | ev_document_info_get_type 18 | ev_document_layers_get_type 19 | ev_document_layout_get_type 20 | ev_document_license_get_type 21 | ev_document_links_get_type 22 | ev_document_mode_get_type 23 | ev_document_permissions_get_type 24 | ev_document_print_get_type 25 | ev_document_security_get_type 26 | ev_document_thumbnails_get_type 27 | ev_document_transition_get_type 28 | ev_document_ui_hints_get_type 29 | ev_file_exporter_capabilities_get_type 30 | ev_file_exporter_format_get_type 31 | ev_file_exporter_get_type 32 | ev_form_field_button_get_type 33 | ev_form_field_button_type_get_type 34 | ev_form_field_choice_get_type 35 | ev_form_field_choice_type_get_type 36 | ev_form_field_get_type 37 | ev_form_field_signature_get_type 38 | ev_form_field_text_get_type 39 | ev_form_field_text_type_get_type 40 | ev_image_get_type 41 | ev_layer_get_type 42 | ev_link_action_get_type 43 | ev_link_action_type_get_type 44 | ev_link_dest_get_type 45 | ev_link_dest_type_get_type 46 | ev_link_get_type 47 | ev_page_get_type 48 | ev_rectangle_get_type 49 | ev_render_context_get_type 50 | ev_selection_get_type 51 | ev_selection_style_get_type 52 | ev_transition_effect_alignment_get_type 53 | ev_transition_effect_direction_get_type 54 | ev_transition_effect_get_type 55 | ev_transition_effect_type_get_type 56 | -------------------------------------------------------------------------------- /help/reference/libdocument/meson.build: -------------------------------------------------------------------------------- 1 | version_conf = configuration_data() 2 | version_conf.set('VERSION', version) 3 | 4 | version_xml = configure_file( 5 | input: 'version.xml.in', 6 | output: 'version.xml', 7 | configuration: version_conf, 8 | ) 9 | 10 | libdoc_doc_deps = declare_dependency( 11 | include_directories: [libdoc_include, include_directories('.')], 12 | link_with: libdocument, 13 | dependencies: libdocument_deps, 14 | ) 15 | 16 | gnome.gtkdoc( 17 | 'libxreaderdocument', 18 | mode: 'xml', 19 | main_xml: 'libxreaderdocument-docs.xml', 20 | gobject_typesfile: files('libxreaderdocument.types'), 21 | src_dir: [ 22 | join_paths(meson.source_root(), 'libdocument'), 23 | ], 24 | ignore_headers: [libdocument_private_headers], 25 | dependencies: libdoc_doc_deps, 26 | mkdb_args: ['--xml-mode', '--output-format=xml', '--name-space=ev'], 27 | fixxref_args: fixref_args, 28 | install: true, 29 | install_dir: 'libxreaderdocument-' + api_version, 30 | ) 31 | -------------------------------------------------------------------------------- /help/reference/libdocument/version.xml.in: -------------------------------------------------------------------------------- 1 | @VERSION@ -------------------------------------------------------------------------------- /help/reference/libview/libxreaderview-overrides.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/help/reference/libview/libxreaderview-overrides.txt -------------------------------------------------------------------------------- /help/reference/libview/libxreaderview.types: -------------------------------------------------------------------------------- 1 | #include 2 | #include "ev-annotation-window.h" 3 | #include "ev-page-cache.h" 4 | #include "ev-view-presentation.h" 5 | 6 | ev_annotation_window_get_type 7 | ev_document_model_get_type 8 | ev_job_attachments_get_type 9 | ev_job_export_get_type 10 | ev_job_find_get_type 11 | ev_job_fonts_get_type 12 | ev_job_get_type 13 | ev_job_layers_get_type 14 | ev_job_links_get_type 15 | ev_job_load_get_type 16 | ev_job_page_data_flags_get_type 17 | ev_job_page_data_get_type 18 | ev_job_print_get_type 19 | ev_job_priority_get_type 20 | ev_job_render_get_type 21 | ev_job_run_mode_get_type 22 | ev_job_save_get_type 23 | ev_job_thumbnail_get_type 24 | ev_page_cache_get_type 25 | ev_print_operation_get_type 26 | ev_sizing_mode_get_type 27 | ev_view_get_type 28 | ev_view_presentation_get_type 29 | ev_view_selection_mode_get_type 30 | -------------------------------------------------------------------------------- /help/reference/libview/meson.build: -------------------------------------------------------------------------------- 1 | version_conf = configuration_data() 2 | version_conf.set('VERSION', version) 3 | 4 | version_xml = configure_file( 5 | input: 'version.xml.in', 6 | output: 'version.xml', 7 | configuration: version_conf, 8 | ) 9 | 10 | libview_doc_deps = declare_dependency( 11 | include_directories: [include_root, libdoc_include, libview_include, include_directories('.')], 12 | link_with: libview, 13 | dependencies: libdoc_deps, 14 | ) 15 | 16 | gnome.gtkdoc( 17 | 'libxreaderview', 18 | mode: 'xml', 19 | main_xml: 'libxreaderview-docs.xml', 20 | gobject_typesfile: files('libxreaderview.types'), 21 | src_dir: [ 22 | join_paths(meson.source_root(), 'libview'), 23 | ], 24 | ignore_headers: [libview_private_headers], 25 | dependencies: libview_doc_deps, 26 | mkdb_args: ['--xml-mode', '--output-format=xml', '--name-space=ev'], 27 | cflags: '-DXREADER_COMPILATION', 28 | fixxref_args: fixref_args, 29 | install: true, 30 | install_dir: 'libxreaderview-' + api_version, 31 | ) 32 | -------------------------------------------------------------------------------- /help/reference/libview/version.xml.in: -------------------------------------------------------------------------------- 1 | @VERSION@ -------------------------------------------------------------------------------- /help/reference/shell/meson.build: -------------------------------------------------------------------------------- 1 | version_conf = configuration_data() 2 | version_conf.set('VERSION', version) 3 | 4 | version_xml = configure_file( 5 | input: 'version.xml.in', 6 | output: 'version.xml', 7 | configuration: version_conf, 8 | ) 9 | 10 | xreader_doc_deps = declare_dependency( 11 | include_directories: [include_root, libdoc_include, libview_include, include_directories('.')], 12 | link_with: [libdocument, libview], 13 | dependencies: xreader_deps, 14 | ) 15 | 16 | gnome.gtkdoc( 17 | meson.project_name(), 18 | mode: 'xml', 19 | main_xml: 'xreader-docs.xml', 20 | gobject_typesfile: files('xreader.types'), 21 | src_dir: [ 22 | join_paths(meson.source_root(), 'libview'), 23 | ], 24 | ignore_headers: [libview_private_headers], 25 | dependencies: xreader_doc_deps, 26 | mkdb_args: ['--xml-mode', '--output-format=xml', '--name-space=ev'], 27 | cflags: '-DXREADER_COMPILATION', 28 | fixxref_args: fixref_args, 29 | install: true, 30 | install_dir: meson.project_name(), 31 | ) 32 | -------------------------------------------------------------------------------- /help/reference/shell/version.xml.in: -------------------------------------------------------------------------------- 1 | @VERSION@ -------------------------------------------------------------------------------- /help/reference/shell/xreader-overrides.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/help/reference/shell/xreader-overrides.txt -------------------------------------------------------------------------------- /help/reference/shell/xreader.types: -------------------------------------------------------------------------------- 1 | egg_find_bar_get_type 2 | ev_application_get_type 3 | ev_file_monitor_get_type 4 | ev_history_get_type 5 | ev_message_area_get_type 6 | ev_metadata_get_type 7 | ev_open_recent_action_get_type 8 | ev_page_action_get_type 9 | ev_page_action_widget_get_type 10 | ev_password_view_get_type 11 | ev_progress_message_area_get_type 12 | ev_properties_dialog_get_type 13 | ev_properties_fonts_get_type 14 | ev_properties_license_get_type 15 | ev_sidebar_attachments_get_type 16 | ev_sidebar_get_type 17 | ev_sidebar_layers_get_type 18 | ev_sidebar_links_get_type 19 | ev_sidebar_page_get_type 20 | ev_sidebar_thumbnails_get_type 21 | ev_window_get_type 22 | -------------------------------------------------------------------------------- /help/xreader.omf.in: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | user's guide 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /install-scripts/meson.build: -------------------------------------------------------------------------------- 1 | # These scripts run as post-installation scripts. 2 | 3 | # They're designed to do nothing if DESTDIR is set, which happens 4 | # during debian builds for instance - there's a fake install target 5 | # so running these would be pointless. 6 | 7 | # When using deb packaging, these aren't needed, as these operations 8 | # are run automatically by the package manager. 9 | 10 | # They're really only necessary in straight builds where 'ninja install' 11 | # will be run directly, to install the program onto the system. 12 | 13 | 14 | # Re-compile gsettings 15 | meson.add_install_script('meson_install_schemas.py') 16 | 17 | # Update mime info 18 | meson.add_install_script('meson_update_mime_database.py') 19 | 20 | # Update the Gtk icon cache 21 | meson.add_install_script('meson_update_icon_cache.py') 22 | -------------------------------------------------------------------------------- /install-scripts/meson_install_schemas.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python3 2 | 3 | import os 4 | import subprocess 5 | 6 | schemadir = os.path.join(os.environ['MESON_INSTALL_PREFIX'], 'share', 'glib-2.0', 'schemas') 7 | 8 | if not os.environ.get('DESTDIR'): 9 | print('Compiling gsettings schemas...') 10 | subprocess.call(['glib-compile-schemas', schemadir]) 11 | -------------------------------------------------------------------------------- /install-scripts/meson_update_icon_cache.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python3 2 | 3 | import os 4 | import subprocess 5 | 6 | themedir = os.path.join(os.environ['MESON_INSTALL_PREFIX'], 'share', 'icons', 'hicolor') 7 | 8 | if not os.environ.get('DESTDIR'): 9 | print('Updating gtk icon cache... %s' % themedir) 10 | subprocess.call(['gtk-update-icon-cache', '-f', '-t', themedir]) 11 | -------------------------------------------------------------------------------- /install-scripts/meson_update_mime_database.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python3 2 | 3 | import os 4 | import subprocess 5 | 6 | mimedir = os.path.join(os.environ['MESON_INSTALL_PREFIX'], 'share', 'mime') 7 | 8 | if not os.environ.get('DESTDIR'): 9 | print('Updating mime database...') 10 | subprocess.call(['update-mime-database', mimedir]) 11 | -------------------------------------------------------------------------------- /libdocument/ev-async-renderer.c: -------------------------------------------------------------------------------- 1 | /* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8; c-indent-level: 8 -*- */ 2 | /* 3 | * Copyright (C) 2004 Marco Pesenti Gritti 4 | * 5 | * This program is free software; you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation; either version 2, or (at your option) 8 | * any later version. 9 | * 10 | * This program is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with this program; if not, write to the Free Software 17 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 18 | * 19 | */ 20 | 21 | #include "config.h" 22 | 23 | #include "ev-async-renderer.h" 24 | #include "ev-document.h" 25 | 26 | enum 27 | { 28 | RENDER_FINISHED, 29 | LAST_SIGNAL 30 | }; 31 | 32 | static guint signals[LAST_SIGNAL] = { 0 }; 33 | 34 | G_DEFINE_INTERFACE (EvAsyncRenderer, ev_async_renderer, 0) 35 | 36 | static void 37 | ev_async_renderer_default_init (EvAsyncRendererInterface *klass) 38 | { 39 | static gboolean initialized = FALSE; 40 | 41 | if (!initialized) { 42 | signals[RENDER_FINISHED] = 43 | g_signal_new ("render_finished", 44 | EV_TYPE_ASYNC_RENDERER, 45 | G_SIGNAL_RUN_LAST, 46 | G_STRUCT_OFFSET (EvAsyncRendererInterface, render_finished), 47 | NULL, NULL, 48 | g_cclosure_marshal_VOID__OBJECT, 49 | G_TYPE_NONE, 50 | 1, 51 | GDK_TYPE_PIXBUF); 52 | initialized = TRUE; 53 | } 54 | } 55 | 56 | void 57 | ev_async_renderer_render_pixbuf (EvAsyncRenderer *async_renderer, 58 | int page, 59 | double scale, 60 | int rotation) 61 | { 62 | EvAsyncRendererInterface *iface = EV_ASYNC_RENDERER_GET_IFACE (async_renderer); 63 | 64 | iface->render_pixbuf (async_renderer, page, scale, rotation); 65 | } 66 | -------------------------------------------------------------------------------- /libdocument/ev-backends-manager.h: -------------------------------------------------------------------------------- 1 | /* this file is part of xreader, a mate document viewer 2 | * 3 | * Copyright (C) 2007 Carlos Garcia Campos 4 | * 5 | * Xreader is free software; you can redistribute it and/or modify it 6 | * under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation; either version 2 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * Xreader is distributed in the hope that it will be useful, but 11 | * WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | * General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with this program; if not, write to the Free Software 17 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 18 | */ 19 | 20 | #if !defined (__EV_XREADER_DOCUMENT_H_INSIDE__) && !defined (XREADER_COMPILATION) 21 | #error "Only can be included directly." 22 | #endif 23 | 24 | #ifndef EV_BACKENDS_MANAGER 25 | #define EV_BACKENDS_MANAGER 26 | 27 | #include 28 | 29 | #include "ev-document.h" 30 | #include "ev-macros.h" 31 | 32 | G_BEGIN_DECLS 33 | 34 | typedef struct _EvTypeInfo { 35 | const gchar *desc; 36 | const gchar **mime_types; 37 | } EvTypeInfo; 38 | 39 | gboolean _ev_backends_manager_init (void); 40 | void _ev_backends_manager_shutdown (void); 41 | 42 | EvDocument *ev_backends_manager_get_document (const gchar *mime_type); 43 | 44 | EV_DEPRECATED 45 | const gchar *ev_backends_manager_get_document_module_name (EvDocument *document); 46 | 47 | EV_DEPRECATED 48 | EvTypeInfo *ev_backends_manager_get_document_type_info (EvDocument *document); 49 | 50 | GList *ev_backends_manager_get_all_types_info (void); 51 | const gchar *ev_backends_manager_get_backends_dir (void); 52 | G_END_DECLS 53 | 54 | #endif /* EV_BACKENDS_MANAGER */ 55 | -------------------------------------------------------------------------------- /libdocument/ev-document-attachments.c: -------------------------------------------------------------------------------- 1 | /* ev-document-attachments.c 2 | * this file is part of xreader, a mate document_links viewer 3 | * 4 | * Copyright (C) 2009 Carlos Garcia Campos 5 | * 6 | * Xreader is free software; you can redistribute it and/or modify it 7 | * under the terms of the GNU General Public License as published by 8 | * the Free Software Foundation; either version 2 of the License, or 9 | * (at your option) any later version. 10 | * 11 | * Xreader is distributed in the hope that it will be useful, but 12 | * WITHOUT ANY WARRANTY; without even the implied warranty of 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 14 | * General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU General Public License 17 | * along with this program; if not, write to the Free Software 18 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 19 | */ 20 | 21 | #include "config.h" 22 | 23 | #include "ev-document-attachments.h" 24 | #include "ev-document.h" 25 | 26 | G_DEFINE_INTERFACE (EvDocumentAttachments, ev_document_attachments, 0) 27 | 28 | static void 29 | ev_document_attachments_default_init (EvDocumentAttachmentsInterface *klass) 30 | { 31 | } 32 | 33 | gboolean 34 | ev_document_attachments_has_attachments (EvDocumentAttachments *document_attachments) 35 | { 36 | EvDocumentAttachmentsInterface *iface = EV_DOCUMENT_ATTACHMENTS_GET_IFACE (document_attachments); 37 | 38 | return iface->has_attachments (document_attachments); 39 | } 40 | 41 | GList * 42 | ev_document_attachments_get_attachments (EvDocumentAttachments *document_attachments) 43 | { 44 | EvDocumentAttachmentsInterface *iface = EV_DOCUMENT_ATTACHMENTS_GET_IFACE (document_attachments); 45 | 46 | return iface->get_attachments (document_attachments); 47 | } 48 | 49 | 50 | -------------------------------------------------------------------------------- /libdocument/ev-document-factory.h: -------------------------------------------------------------------------------- 1 | /* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8; c-indent-level: 8 -*- */ 2 | /* 3 | * Copyright (C) 2005, Red Hat, Inc. 4 | * 5 | * This program is free software; you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation; either version 2, or (at your option) 8 | * any later version. 9 | * 10 | * This program is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with this program; if not, write to the Free Software 17 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 18 | * 19 | */ 20 | 21 | #if !defined (__EV_XREADER_DOCUMENT_H_INSIDE__) && !defined (XREADER_COMPILATION) 22 | #error "Only can be included directly." 23 | #endif 24 | 25 | #ifndef EV_DOCUMENT_FACTORY_H 26 | #define EV_DOCUMENT_FACTORY_H 27 | 28 | #include 29 | 30 | #include "ev-document.h" 31 | 32 | G_BEGIN_DECLS 33 | 34 | EvDocument* ev_document_factory_get_document (const char *uri, GError **error); 35 | void ev_document_factory_add_filters (GtkWidget *chooser, EvDocument *document); 36 | 37 | G_END_DECLS 38 | 39 | #endif 40 | -------------------------------------------------------------------------------- /libdocument/ev-document-find.c: -------------------------------------------------------------------------------- 1 | /* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8; c-indent-level: 8 -*- */ 2 | /* 3 | * Copyright (C) 2004 Red Hat, Inc. 4 | * 5 | * This program is free software; you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation; either version 2, or (at your option) 8 | * any later version. 9 | * 10 | * This program is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with this program; if not, write to the Free Software 17 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 18 | * 19 | */ 20 | 21 | #include "config.h" 22 | 23 | #include "ev-document-find.h" 24 | 25 | G_DEFINE_INTERFACE (EvDocumentFind, ev_document_find, 0) 26 | 27 | static void 28 | ev_document_find_default_init (EvDocumentFindInterface *klass) 29 | { 30 | } 31 | 32 | GList * 33 | ev_document_find_find_text (EvDocumentFind *document_find, 34 | EvPage *page, 35 | const gchar *text, 36 | gboolean case_sensitive) 37 | { 38 | EvDocumentFindInterface *iface = EV_DOCUMENT_FIND_GET_IFACE (document_find); 39 | 40 | return iface->find_text (document_find, page, text, case_sensitive); 41 | } 42 | 43 | guint 44 | ev_document_find_check_for_hits(EvDocumentFind *document_find, 45 | EvPage *page, 46 | const gchar *text, 47 | gboolean case_sensitive) 48 | { 49 | EvDocumentFindInterface *iface = EV_DOCUMENT_FIND_GET_IFACE (document_find); 50 | return iface->check_for_hits (document_find, page, text, case_sensitive); 51 | } -------------------------------------------------------------------------------- /libdocument/ev-document-fonts.c: -------------------------------------------------------------------------------- 1 | /* ev-document-fonts.h 2 | * this file is part of xreader, a mate document_fonts viewer 3 | * 4 | * Copyright (C) 2004 Red Hat, Inc. 5 | * 6 | * Author: 7 | * Marco Pesenti Gritti 8 | * 9 | * Xreader is free software; you can redistribute it and/or modify it 10 | * under the terms of the GNU General Public License as published by 11 | * the Free Software Foundation; either version 2 of the License, or 12 | * (at your option) any later version. 13 | * 14 | * Xreader is distributed in the hope that it will be useful, but 15 | * WITHOUT ANY WARRANTY; without even the implied warranty of 16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 17 | * General Public License for more details. 18 | * 19 | * You should have received a copy of the GNU General Public License 20 | * along with this program; if not, write to the Free Software 21 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 22 | */ 23 | 24 | #include "config.h" 25 | 26 | #include "ev-document-fonts.h" 27 | 28 | G_DEFINE_INTERFACE (EvDocumentFonts, ev_document_fonts, 0) 29 | 30 | static void 31 | ev_document_fonts_default_init (EvDocumentFontsInterface *klass) 32 | { 33 | } 34 | 35 | double 36 | ev_document_fonts_get_progress (EvDocumentFonts *document_fonts) 37 | { 38 | EvDocumentFontsInterface *iface = EV_DOCUMENT_FONTS_GET_IFACE (document_fonts); 39 | 40 | return iface->get_progress (document_fonts); 41 | } 42 | 43 | gboolean 44 | ev_document_fonts_scan (EvDocumentFonts *document_fonts, 45 | int n_pages) 46 | { 47 | EvDocumentFontsInterface *iface = EV_DOCUMENT_FONTS_GET_IFACE (document_fonts); 48 | 49 | return iface->scan (document_fonts, n_pages); 50 | } 51 | 52 | void 53 | ev_document_fonts_fill_model (EvDocumentFonts *document_fonts, 54 | GtkTreeModel *model) 55 | { 56 | EvDocumentFontsInterface *iface = EV_DOCUMENT_FONTS_GET_IFACE (document_fonts); 57 | 58 | iface->fill_model (document_fonts, model); 59 | } 60 | -------------------------------------------------------------------------------- /libdocument/ev-document-images.c: -------------------------------------------------------------------------------- 1 | /* ev-document-images.c 2 | * this file is part of xreader, a mate document_links viewer 3 | * 4 | * Copyright (C) 2006 Carlos Garcia Campos 5 | * 6 | * Xreader is free software; you can redistribute it and/or modify it 7 | * under the terms of the GNU General Public License as published by 8 | * the Free Software Foundation; either version 2 of the License, or 9 | * (at your option) any later version. 10 | * 11 | * Xreader is distributed in the hope that it will be useful, but 12 | * WITHOUT ANY WARRANTY; without even the implied warranty of 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 14 | * General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU General Public License 17 | * along with this program; if not, write to the Free Software 18 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 19 | */ 20 | 21 | #include 22 | #include "ev-document-images.h" 23 | 24 | G_DEFINE_INTERFACE (EvDocumentImages, ev_document_images, 0) 25 | 26 | static void 27 | ev_document_images_default_init (EvDocumentImagesInterface *klass) 28 | { 29 | } 30 | 31 | EvMappingList * 32 | ev_document_images_get_image_mapping (EvDocumentImages *document_images, 33 | EvPage *page) 34 | { 35 | EvDocumentImagesInterface *iface = EV_DOCUMENT_IMAGES_GET_IFACE (document_images); 36 | 37 | return iface->get_image_mapping (document_images, page); 38 | } 39 | 40 | GdkPixbuf * 41 | ev_document_images_get_image (EvDocumentImages *document_images, 42 | EvImage *image) 43 | { 44 | EvDocumentImagesInterface *iface = EV_DOCUMENT_IMAGES_GET_IFACE (document_images); 45 | 46 | return iface->get_image (document_images, image); 47 | } 48 | -------------------------------------------------------------------------------- /libdocument/ev-document-print.c: -------------------------------------------------------------------------------- 1 | /* ev-document-print.c 2 | * this file is part of xreader, a mate document_links viewer 3 | * 4 | * Copyright (C) 2009 Carlos Garcia Campos 5 | * 6 | * Xreader is free software; you can redistribute it and/or modify it 7 | * under the terms of the GNU General Public License as published by 8 | * the Free Software Foundation; either version 2 of the License, or 9 | * (at your option) any later version. 10 | * 11 | * Xreader is distributed in the hope that it will be useful, but 12 | * WITHOUT ANY WARRANTY; without even the implied warranty of 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 14 | * General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU General Public License 17 | * along with this program; if not, write to the Free Software 18 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 19 | */ 20 | 21 | #include "config.h" 22 | 23 | #include "ev-document.h" 24 | #include "ev-document-print.h" 25 | 26 | G_DEFINE_INTERFACE (EvDocumentPrint, ev_document_print, 0) 27 | 28 | static void 29 | ev_document_print_default_init (EvDocumentPrintInterface *klass) 30 | { 31 | } 32 | 33 | void 34 | ev_document_print_print_page (EvDocumentPrint *document_print, 35 | EvPage *page, 36 | cairo_t *cr) 37 | { 38 | EvDocumentPrintInterface *iface = EV_DOCUMENT_PRINT_GET_IFACE (document_print); 39 | 40 | iface->print_page (document_print, page, cr); 41 | } 42 | -------------------------------------------------------------------------------- /libdocument/ev-document-security.c: -------------------------------------------------------------------------------- 1 | /* ev-document-links.h 2 | * this file is part of xreader, a mate document_links viewer 3 | * 4 | * Copyright (C) 2004 Red Hat, Inc. 5 | * 6 | * Author: 7 | * Jonathan Blandford 8 | * 9 | * Xreader is free software; you can redistribute it and/or modify it 10 | * under the terms of the GNU General Public License as published by 11 | * the Free Software Foundation; either version 2 of the License, or 12 | * (at your option) any later version. 13 | * 14 | * Xreader is distributed in the hope that it will be useful, but 15 | * WITHOUT ANY WARRANTY; without even the implied warranty of 16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 17 | * General Public License for more details. 18 | * 19 | * You should have received a copy of the GNU General Public License 20 | * along with this program; if not, write to the Free Software 21 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 22 | */ 23 | 24 | #include "config.h" 25 | 26 | #include "ev-document-security.h" 27 | 28 | G_DEFINE_INTERFACE (EvDocumentSecurity, ev_document_security, 0) 29 | 30 | static void 31 | ev_document_security_default_init (EvDocumentSecurityInterface *klass) 32 | { 33 | } 34 | 35 | gboolean 36 | ev_document_security_has_document_security (EvDocumentSecurity *document_security) 37 | { 38 | EvDocumentSecurityInterface *iface = EV_DOCUMENT_SECURITY_GET_IFACE (document_security); 39 | return iface->has_document_security (document_security); 40 | } 41 | 42 | void 43 | ev_document_security_set_password (EvDocumentSecurity *document_security, 44 | const char *password) 45 | { 46 | EvDocumentSecurityInterface *iface = EV_DOCUMENT_SECURITY_GET_IFACE (document_security); 47 | iface->set_password (document_security, password); 48 | } 49 | -------------------------------------------------------------------------------- /libdocument/ev-document-text.c: -------------------------------------------------------------------------------- 1 | /* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8; c-indent-level: 8 -*- */ 2 | /* 3 | * Copyright (C) 2010 Yaco Sistemas, Daniel Garcia 4 | * 5 | * This program is free software; you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation; either version 2, or (at your option) 8 | * any later version. 9 | * 10 | * This program is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with this program; if not, write to the Free Software 17 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 18 | * 19 | * $Id$ 20 | */ 21 | 22 | #include "config.h" 23 | 24 | #include "ev-document-text.h" 25 | 26 | G_DEFINE_INTERFACE (EvDocumentText, ev_document_text, 0) 27 | 28 | static void 29 | ev_document_text_default_init (EvDocumentTextInterface *klass) 30 | { 31 | } 32 | 33 | gchar * 34 | ev_document_text_get_text (EvDocumentText *document_text, 35 | EvPage *page) 36 | { 37 | EvDocumentTextInterface *iface = EV_DOCUMENT_TEXT_GET_IFACE (document_text); 38 | 39 | if (!iface->get_text) 40 | return NULL; 41 | 42 | return iface->get_text (document_text, page); 43 | } 44 | 45 | 46 | gboolean 47 | ev_document_text_get_text_layout (EvDocumentText *document_text, 48 | EvPage *page, 49 | EvRectangle **areas, 50 | guint *n_areas) 51 | { 52 | EvDocumentTextInterface *iface = EV_DOCUMENT_TEXT_GET_IFACE (document_text); 53 | 54 | if (!iface->get_text_layout) 55 | return FALSE; 56 | 57 | return iface->get_text_layout (document_text, page, areas, n_areas); 58 | } 59 | 60 | cairo_region_t * 61 | ev_document_text_get_text_mapping (EvDocumentText *document_text, 62 | EvPage *page) 63 | { 64 | EvDocumentTextInterface *iface = EV_DOCUMENT_TEXT_GET_IFACE (document_text); 65 | 66 | if (!iface->get_text_mapping) 67 | return NULL; 68 | 69 | return iface->get_text_mapping (document_text, page); 70 | } 71 | -------------------------------------------------------------------------------- /libdocument/ev-document-thumbnails.c: -------------------------------------------------------------------------------- 1 | /* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8; c-indent-level: 8 -*- */ 2 | /* 3 | * Copyright (C) 2004 Anders Carlsson 4 | * 5 | * This program is free software; you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation; either version 2, or (at your option) 8 | * any later version. 9 | * 10 | * This program is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with this program; if not, write to the Free Software 17 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 18 | * 19 | */ 20 | 21 | #include 22 | #include "ev-document-thumbnails.h" 23 | #include "ev-document.h" 24 | 25 | G_DEFINE_INTERFACE (EvDocumentThumbnails, ev_document_thumbnails, 0) 26 | 27 | static void 28 | ev_document_thumbnails_default_init (EvDocumentThumbnailsInterface *klass) 29 | { 30 | } 31 | 32 | GdkPixbuf * 33 | ev_document_thumbnails_get_thumbnail (EvDocumentThumbnails *document, 34 | EvRenderContext *rc, 35 | gboolean border) 36 | { 37 | EvDocumentThumbnailsInterface *iface; 38 | 39 | g_return_val_if_fail (EV_IS_DOCUMENT_THUMBNAILS (document), NULL); 40 | g_return_val_if_fail (EV_IS_RENDER_CONTEXT (rc), NULL); 41 | 42 | iface = EV_DOCUMENT_THUMBNAILS_GET_IFACE (document); 43 | 44 | return iface->get_thumbnail (document, rc, border); 45 | } 46 | 47 | void 48 | ev_document_thumbnails_get_dimensions (EvDocumentThumbnails *document, 49 | EvRenderContext *rc, 50 | gint *width, 51 | gint *height) 52 | { 53 | EvDocumentThumbnailsInterface *iface; 54 | 55 | g_return_if_fail (EV_IS_DOCUMENT_THUMBNAILS (document)); 56 | g_return_if_fail (EV_IS_RENDER_CONTEXT (rc)); 57 | g_return_if_fail (width != NULL); 58 | g_return_if_fail (height != NULL); 59 | 60 | iface = EV_DOCUMENT_THUMBNAILS_GET_IFACE (document); 61 | iface->get_dimensions (document, rc, width, height); 62 | } -------------------------------------------------------------------------------- /libdocument/ev-document-transition.c: -------------------------------------------------------------------------------- 1 | /* ev-document-transition.c 2 | * this file is part of xreader, a mate document viewer 3 | * 4 | * Copyright (C) 2006 Carlos Garcia Campos 5 | * 6 | * Xreader is free software; you can redistribute it and/or modify it 7 | * under the terms of the GNU General Public License as published by 8 | * the Free Software Foundation; either version 2 of the License, or 9 | * (at your option) any later version. 10 | * 11 | * Xreader is distributed in the hope that it will be useful, but 12 | * WITHOUT ANY WARRANTY; without even the implied warranty of 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 14 | * General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU General Public License 17 | * along with this program; if not, write to the Free Software 18 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 19 | */ 20 | 21 | #include 22 | #include "ev-document-transition.h" 23 | 24 | G_DEFINE_INTERFACE (EvDocumentTransition, ev_document_transition, 0) 25 | 26 | static void 27 | ev_document_transition_default_init (EvDocumentTransitionInterface *klass) 28 | { 29 | } 30 | 31 | gdouble 32 | ev_document_transition_get_page_duration (EvDocumentTransition *document_trans, 33 | gint page) 34 | { 35 | EvDocumentTransitionInterface *iface = EV_DOCUMENT_TRANSITION_GET_IFACE (document_trans); 36 | 37 | if (iface->get_page_duration) 38 | return iface->get_page_duration (document_trans, page); 39 | 40 | return -1; 41 | } 42 | 43 | EvTransitionEffect * 44 | ev_document_transition_get_effect (EvDocumentTransition *document_trans, 45 | gint page) 46 | { 47 | EvDocumentTransitionInterface *iface = EV_DOCUMENT_TRANSITION_GET_IFACE (document_trans); 48 | EvTransitionEffect *effect = NULL; 49 | 50 | if (iface->get_effect) 51 | effect = iface->get_effect (document_trans, page); 52 | 53 | if (!effect) 54 | return ev_transition_effect_new (EV_TRANSITION_EFFECT_REPLACE, NULL); 55 | 56 | return effect; 57 | } 58 | -------------------------------------------------------------------------------- /libdocument/ev-document-type-builtins.c.template: -------------------------------------------------------------------------------- 1 | /*** BEGIN file-header ***/ 2 | #include 3 | 4 | #include "ev-document-type-builtins.h" 5 | 6 | /*** END file-header ***/ 7 | 8 | /*** BEGIN file-production ***/ 9 | /* enumerations from "@filename@" */ 10 | #include "@filename@" 11 | /*** END file-production ***/ 12 | 13 | 14 | /*** BEGIN value-header ***/ 15 | GType 16 | @enum_name@_get_type (void) 17 | { 18 | static gsize g_define_type_id__volatile = 0; 19 | 20 | if (g_once_init_enter (&g_define_type_id__volatile)) { 21 | static const G@Type@Value values[] = { 22 | /*** END value-header ***/ 23 | 24 | /*** BEGIN value-production ***/ 25 | { @VALUENAME@, "@VALUENAME@", "@valuenick@" }, 26 | /*** END value-production ***/ 27 | 28 | /*** BEGIN value-tail ***/ 29 | { 0, NULL, NULL } 30 | }; 31 | GType g_define_type_id = \ 32 | g_@type@_register_static (g_intern_static_string ("@EnumName@"), values); 33 | 34 | g_once_init_leave (&g_define_type_id__volatile, g_define_type_id); 35 | } 36 | 37 | return g_define_type_id__volatile; 38 | } 39 | 40 | /*** END value-tail ***/ 41 | 42 | /*** BEGIN file-tail ***/ 43 | 44 | /*** END file-tail ***/ 45 | -------------------------------------------------------------------------------- /libdocument/ev-document-type-builtins.h.template: -------------------------------------------------------------------------------- 1 | /*** BEGIN file-header ***/ 2 | 3 | #if !defined (__EV_XREADER_DOCUMENT_H_INSIDE__) && !defined (XREADER_COMPILATION) 4 | #error "Only can be included directly." 5 | #endif 6 | 7 | #ifndef EV_DOCUMENT_TYPE_BUILTINS_H 8 | #define EV_DOCUMENT_TYPE_BUILTINS_H 9 | 10 | #include 11 | 12 | G_BEGIN_DECLS 13 | /*** END file-header ***/ 14 | 15 | /*** BEGIN file-production ***/ 16 | 17 | /* enumerations from "@filename@" */ 18 | /*** END file-production ***/ 19 | 20 | /*** BEGIN value-header ***/ 21 | GType @enum_name@_get_type (void) G_GNUC_CONST; 22 | #define EV_TYPE_@ENUMSHORT@ (@enum_name@_get_type ()) 23 | /*** END value-header ***/ 24 | 25 | /*** BEGIN file-tail ***/ 26 | G_END_DECLS 27 | 28 | #endif /* !EV_DOCUMENT_TYPE_BUILTINS_H */ 29 | /*** END file-tail ***/ 30 | -------------------------------------------------------------------------------- /libdocument/ev-init.h: -------------------------------------------------------------------------------- 1 | /* this file is part of xreader, a mate document viewer 2 | * 3 | * Copyright © 2009 Christian Persch 4 | * 5 | * Xreader is free software; you can redistribute it and/or modify it 6 | * under the terms of the GNU Lesser General Public License as published by 7 | * the Free Software Foundation; either version 2.1 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * Xreader is distributed in the hope that it will be useful, but 11 | * WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser 13 | * General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU Lesser General Public License 16 | * along with this program; if not, write to the Free Software 17 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 18 | */ 19 | 20 | #if !defined (__EV_XREADER_DOCUMENT_H_INSIDE__) && !defined (XREADER_COMPILATION) 21 | #error "Only can be included directly." 22 | #endif 23 | 24 | #ifndef EV_INIT_H 25 | #define EV_INIT_H 26 | 27 | #include 28 | 29 | G_BEGIN_DECLS 30 | 31 | gboolean ev_init (void); 32 | 33 | void ev_shutdown (void); 34 | 35 | gboolean _ev_is_initialized (void); 36 | 37 | G_END_DECLS 38 | 39 | #endif /* EV_INIT_H */ 40 | -------------------------------------------------------------------------------- /libdocument/ev-layer.c: -------------------------------------------------------------------------------- 1 | /* this file is part of xreader, a mate document viewer 2 | * 3 | * Copyright (C) 2008 Carlos Garcia Campos 4 | * 5 | * Xreader is free software; you can redistribute it and/or modify it 6 | * under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation; either version 2 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * Xreader is distributed in the hope that it will be useful, but 11 | * WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | * General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with this program; if not, write to the Free Software 17 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 18 | */ 19 | 20 | #include 21 | 22 | #include "ev-layer.h" 23 | 24 | struct _EvLayerPrivate { 25 | gboolean is_parent; 26 | gint rb_group; 27 | }; 28 | 29 | G_DEFINE_TYPE_WITH_PRIVATE (EvLayer, ev_layer, G_TYPE_OBJECT) 30 | 31 | static void 32 | ev_layer_class_init (EvLayerClass *klass) 33 | { 34 | } 35 | 36 | static void 37 | ev_layer_init (EvLayer *layer) 38 | { 39 | layer->priv = ev_layer_get_instance_private (layer); 40 | } 41 | 42 | EvLayer * 43 | ev_layer_new (gboolean is_parent, 44 | gint rb_group) 45 | { 46 | EvLayer *layer; 47 | 48 | layer = EV_LAYER (g_object_new (EV_TYPE_LAYER, NULL)); 49 | layer->priv->is_parent = is_parent; 50 | layer->priv->rb_group = rb_group; 51 | 52 | return layer; 53 | } 54 | 55 | gboolean 56 | ev_layer_is_parent (EvLayer *layer) 57 | { 58 | g_return_val_if_fail (EV_IS_LAYER (layer), FALSE); 59 | 60 | return layer->priv->is_parent; 61 | } 62 | 63 | gint 64 | ev_layer_get_rb_group (EvLayer *layer) 65 | { 66 | g_return_val_if_fail (EV_IS_LAYER (layer), 0); 67 | 68 | return layer->priv->rb_group; 69 | } 70 | -------------------------------------------------------------------------------- /libdocument/ev-layer.h: -------------------------------------------------------------------------------- 1 | /* this file is part of xreader, a mate document viewer 2 | * 3 | * Copyright (C) 2008 Carlos Garcia Campos 4 | * 5 | * Xreader is free software; you can redistribute it and/or modify it 6 | * under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation; either version 2 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * Xreader is distributed in the hope that it will be useful, but 11 | * WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | * General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with this program; if not, write to the Free Software 17 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 18 | */ 19 | 20 | #if !defined (__EV_XREADER_DOCUMENT_H_INSIDE__) && !defined (XREADER_COMPILATION) 21 | #error "Only can be included directly." 22 | #endif 23 | 24 | #ifndef __EV_LAYER_H__ 25 | #define __EV_LAYER_H__ 26 | 27 | #include 28 | 29 | G_BEGIN_DECLS 30 | 31 | typedef struct _EvLayer EvLayer; 32 | typedef struct _EvLayerClass EvLayerClass; 33 | typedef struct _EvLayerPrivate EvLayerPrivate; 34 | 35 | #define EV_TYPE_LAYER (ev_layer_get_type()) 36 | #define EV_LAYER(object) (G_TYPE_CHECK_INSTANCE_CAST((object), EV_TYPE_LAYER, EvLayer)) 37 | #define EV_LAYER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass), EV_TYPE_LAYER, EvLayerClass)) 38 | #define EV_IS_LAYER(object) (G_TYPE_CHECK_INSTANCE_TYPE((object), EV_TYPE_LAYER)) 39 | #define EV_IS_LAYER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass), EV_TYPE_LAYER)) 40 | #define EV_LAYER_GET_CLASS(object) (G_TYPE_INSTANCE_GET_CLASS((object), EV_TYPE_LAYER, EvLayerClass)) 41 | 42 | struct _EvLayer { 43 | GObject base_instance; 44 | 45 | EvLayerPrivate *priv; 46 | }; 47 | 48 | struct _EvLayerClass { 49 | GObjectClass base_class; 50 | }; 51 | 52 | GType ev_layer_get_type (void) G_GNUC_CONST; 53 | EvLayer *ev_layer_new (gboolean is_parent, 54 | gint rb_group); 55 | gboolean ev_layer_is_parent (EvLayer *layer); 56 | gint ev_layer_get_rb_group (EvLayer *layer); 57 | 58 | G_END_DECLS 59 | 60 | #endif /* __EV_LAYER_H__ */ 61 | -------------------------------------------------------------------------------- /libdocument/ev-link.h: -------------------------------------------------------------------------------- 1 | /* this file is part of xreader, a mate document viewer 2 | * 3 | * Copyright (C) 2005 Red Hat, Inc. 4 | * 5 | * Xreader is free software; you can redistribute it and/or modify it 6 | * under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation; either version 2 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * Xreader is distributed in the hope that it will be useful, but 11 | * WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | * General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with this program; if not, write to the Free Software 17 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 18 | */ 19 | 20 | #if !defined (__EV_XREADER_DOCUMENT_H_INSIDE__) && !defined (XREADER_COMPILATION) 21 | #error "Only can be included directly." 22 | #endif 23 | 24 | #ifndef EV_LINK_H 25 | #define EV_LINK_H 26 | 27 | #include 28 | #include "ev-document.h" 29 | #include "ev-link-action.h" 30 | 31 | G_BEGIN_DECLS 32 | 33 | typedef struct _EvLink EvLink; 34 | typedef struct _EvLinkClass EvLinkClass; 35 | typedef struct _EvLinkPrivate EvLinkPrivate; 36 | 37 | #define EV_TYPE_LINK (ev_link_get_type()) 38 | #define EV_LINK(object) (G_TYPE_CHECK_INSTANCE_CAST((object), EV_TYPE_LINK, EvLink)) 39 | #define EV_LINK_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass), EV_TYPE_LINK, EvLinkClass)) 40 | #define EV_IS_LINK(object) (G_TYPE_CHECK_INSTANCE_TYPE((object), EV_TYPE_LINK)) 41 | #define EV_IS_LINK_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass), EV_TYPE_LINK)) 42 | #define EV_LINK_GET_CLASS(object) (G_TYPE_INSTANCE_GET_CLASS((object), EV_TYPE_LINK, EvLinkClass)) 43 | 44 | GType ev_link_get_type (void) G_GNUC_CONST; 45 | 46 | EvLink *ev_link_new (const gchar *title, 47 | EvLinkAction *action); 48 | 49 | const gchar *ev_link_get_title (EvLink *self); 50 | EvLinkAction *ev_link_get_action (EvLink *self); 51 | 52 | G_END_DECLS 53 | 54 | #endif /* !EV_LINK_H */ 55 | -------------------------------------------------------------------------------- /libdocument/ev-macros.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright © 2012 Christian Persch 3 | * 4 | * This library is free software; you can redistribute it and/or modify it 5 | * under the terms of the GNU Lesser General Public License as published by the 6 | * Free Software Foundation; either version 2.1 of the License, or (at your 7 | * option) any later version. 8 | * 9 | * This library is distributed in the hope that it will be useful, but 10 | * WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 12 | * Lesser General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU Lesser General Public License along 15 | * with this program; if not, write to the Free Software Foundation, Inc., 16 | * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 17 | */ 18 | 19 | #ifndef EV_MACROS_H 20 | #define EV_MACROS_H 21 | 22 | #if defined(EV_DISABLE_DEPRECATION_WARNINGS) || defined(EVINCE_COMPILATION) 23 | #define EV_DEPRECATED 24 | #define EV_DEPRECATED_FOR(f) 25 | #define EV_UNAVAILABLE(maj,min) 26 | #else 27 | #define EV_DEPRECATED G_DEPRECATED 28 | #define EV_DEPRECATED_FOR(f) G_DEPRECATED_FOR(f) 29 | #define EV_UNAVAILABLE(maj,min) G_UNAVAILABLE(maj,min) 30 | #endif 31 | 32 | #endif /* #ifndef EV_MACROS_H */ 33 | -------------------------------------------------------------------------------- /libdocument/ev-page.c: -------------------------------------------------------------------------------- 1 | /* this file is part of xreader, a mate document viewer 2 | * 3 | * Copyright (C) 2008 Carlos Garcia Campos 4 | * 5 | * Xreader is free software; you can redistribute it and/or modify it 6 | * under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation; either version 2 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * Xreader is distributed in the hope that it will be useful, but 11 | * WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | * General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with this program; if not, write to the Free Software 17 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 18 | */ 19 | 20 | #include 21 | 22 | #include "ev-page.h" 23 | 24 | G_DEFINE_TYPE (EvPage, ev_page, G_TYPE_OBJECT) 25 | 26 | static void 27 | ev_page_init (EvPage *page) 28 | { 29 | } 30 | 31 | static void 32 | ev_page_finalize (GObject *object) 33 | { 34 | EvPage *page = EV_PAGE (object); 35 | 36 | if (page->backend_destroy_func) { 37 | page->backend_destroy_func (page->backend_page); 38 | page->backend_destroy_func = NULL; 39 | } 40 | page->backend_page = NULL; 41 | 42 | (* G_OBJECT_CLASS (ev_page_parent_class)->finalize) (object); 43 | } 44 | 45 | static void 46 | ev_page_class_init (EvPageClass *klass) 47 | { 48 | GObjectClass *object_class = G_OBJECT_CLASS (klass); 49 | 50 | object_class->finalize = ev_page_finalize; 51 | } 52 | 53 | EvPage * 54 | ev_page_new (gint index) 55 | { 56 | EvPage *page; 57 | 58 | page = EV_PAGE (g_object_new (EV_TYPE_PAGE, NULL)); 59 | page->index = index; 60 | 61 | return page; 62 | } 63 | -------------------------------------------------------------------------------- /libdocument/ev-page.h: -------------------------------------------------------------------------------- 1 | /* this file is part of xreader, a mate document viewer 2 | * 3 | * Copyright (C) 2008 Carlos Garcia Campos 4 | * 5 | * Xreader is free software; you can redistribute it and/or modify it 6 | * under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation; either version 2 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * Xreader is distributed in the hope that it will be useful, but 11 | * WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | * General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with this program; if not, write to the Free Software 17 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 18 | */ 19 | 20 | #if !defined (__EV_XREADER_DOCUMENT_H_INSIDE__) && !defined (XREADER_COMPILATION) 21 | #error "Only can be included directly." 22 | #endif 23 | 24 | #ifndef EV_PAGE_H 25 | #define EV_PAGE_H 26 | 27 | #include 28 | 29 | G_BEGIN_DECLS 30 | 31 | #define EV_TYPE_PAGE (ev_page_get_type()) 32 | #define EV_PAGE(object) (G_TYPE_CHECK_INSTANCE_CAST((object), EV_TYPE_PAGE, EvPage)) 33 | #define EV_PAGE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass), EV_TYPE_PAGE, EvPageClass)) 34 | #define EV_IS_PAGE(object) (G_TYPE_CHECK_INSTANCE_TYPE((object), EV_TYPE_PAGE)) 35 | #define EV_IS_PAGE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass), EV_TYPE_PAGE)) 36 | #define EV_PAGE_GET_CLASS(object) (G_TYPE_INSTANCE_GET_CLASS((object), EV_TYPE_PAGE, EvPageClass)) 37 | 38 | typedef struct _EvPage EvPage; 39 | typedef struct _EvPageClass EvPageClass; 40 | 41 | typedef gpointer EvBackendPage; 42 | typedef GDestroyNotify EvBackendPageDestroyFunc; 43 | 44 | struct _EvPage { 45 | GObject base_instance; 46 | 47 | gint index; 48 | 49 | EvBackendPage backend_page; 50 | EvBackendPageDestroyFunc backend_destroy_func; 51 | }; 52 | 53 | struct _EvPageClass { 54 | GObjectClass base_class; 55 | }; 56 | 57 | GType ev_page_get_type (void) G_GNUC_CONST; 58 | 59 | EvPage *ev_page_new (gint index); 60 | 61 | G_END_DECLS 62 | 63 | #endif /* EV_PAGE_H */ 64 | -------------------------------------------------------------------------------- /libdocument/ev-version.h.in: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright © 2009 Christian Persch 3 | * 4 | * This library is free software; you can redistribute it and/or modify it 5 | * under the terms of the GNU Lesser General Public License as published by the 6 | * Free Software Foundation; either version 2.1 of the License, or (at your 7 | * option) any later version. 8 | * 9 | * This library is distributed in the hope that it will be useful, but 10 | * WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 12 | * Lesser General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU Lesser General Public License along 15 | * with this program; if not, write to the Free Software Foundation, Inc., 16 | * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 17 | */ 18 | 19 | #ifndef EV_VERSION_H 20 | #define EV_VERSION_H 21 | 22 | /** 23 | * SECTION:ev-version 24 | * @short_description: Library version checks 25 | * 26 | * These macros enable compile time checks of the library version. 27 | */ 28 | 29 | /** 30 | * EV_MAJOR_VERSION: 31 | * 32 | * The major version number of the EV library 33 | * (e.g. in version 3.1.4 this is 3). 34 | */ 35 | 36 | #define EV_MAJOR_VERSION (@EV_MAJOR_VERSION@) 37 | 38 | /** 39 | * EV_MINOR_VERSION: 40 | * 41 | * The minor version number of the EV library 42 | * (e.g. in version 3.1.4 this is 1). 43 | */ 44 | #define EV_MINOR_VERSION (@EV_MINOR_VERSION@) 45 | 46 | /** 47 | * EV_MICRO_VERSION: 48 | * 49 | * The micro version number of the EV library 50 | * (e.g. in version 3.1.4 this is 4). 51 | */ 52 | #define EV_MICRO_VERSION (@EV_MICRO_VERSION@) 53 | 54 | /** 55 | * EV_CHECK_VERSION: 56 | * @major: required major version 57 | * @minor: required minor version 58 | * @micro: required micro version 59 | * 60 | * Macro to check the library version at compile time. 61 | * It returns 1 if the version of EV is greater or 62 | * equal to the required one, and 0 otherwise. 63 | */ 64 | #define EV_CHECK_VERSION(major,minor,micro) \ 65 | (EV_MAJOR_VERSION > (major) || \ 66 | (EV_MAJOR_VERSION == (major) && EV_MINOR_VERSION > (minor)) || \ 67 | (EV_MAJOR_VERSION == (major) && EV_MINOR_VERSION == (minor) && EV_MICRO_VERSION >= (micro))) 68 | 69 | #endif /* #ifndef EV_VERSION_H */ 70 | -------------------------------------------------------------------------------- /libmisc/ev-page-action-widget.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2003, 2004 Marco Pesenti Gritti 3 | * Copyright (C) 2003, 2004 Christian Persch 4 | * 5 | * This program is free software; you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation; either version 2, or (at your option) 8 | * any later version. 9 | * 10 | * This program is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with this program; if not, write to the Free Software 17 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 18 | * 19 | */ 20 | 21 | #include 22 | 23 | #include 24 | 25 | #define EV_TYPE_PAGE_ACTION_WIDGET (ev_page_action_widget_get_type ()) 26 | #define EV_PAGE_ACTION_WIDGET(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), EV_TYPE_PAGE_ACTION_WIDGET, EvPageActionWidget)) 27 | 28 | typedef struct _EvPageActionWidget EvPageActionWidget; 29 | typedef struct _EvPageActionWidgetClass EvPageActionWidgetClass; 30 | 31 | struct _EvPageActionWidgetClass 32 | { 33 | GtkToolItemClass parent_class; 34 | 35 | void (* activate_link) (EvPageActionWidget *page_action, 36 | EvLink *link); 37 | }; 38 | 39 | GType ev_page_action_widget_get_type (void) G_GNUC_CONST; 40 | 41 | void ev_page_action_widget_update_links_model (EvPageActionWidget *proxy, 42 | GtkTreeModel *model); 43 | 44 | void ev_page_action_widget_set_model (EvPageActionWidget *action_widget, 45 | EvDocumentModel *doc_model); 46 | void ev_page_action_widget_grab_focus (EvPageActionWidget *proxy); 47 | -------------------------------------------------------------------------------- /libmisc/meson.build: -------------------------------------------------------------------------------- 1 | libmisc_sources = [ 2 | 'ev-page-action.c', 3 | 'ev-page-action.h', 4 | 'ev-page-action-widget.c', 5 | 'ev-page-action-widget.h', 6 | libdoc_enums, 7 | libview_enums, 8 | ] 9 | 10 | libmisc_deps = [ 11 | libdocument_dep, 12 | glib, 13 | gtk, 14 | ] 15 | 16 | libmisc = static_library( 17 | 'misc', 18 | libmisc_sources, 19 | link_with: libview, 20 | include_directories: include_dirs, 21 | dependencies: libmisc_deps, 22 | ) 23 | 24 | libmisc_dep = declare_dependency( 25 | link_with: libmisc, 26 | include_directories: include_dirs, 27 | dependencies: libmisc_deps, 28 | ) 29 | -------------------------------------------------------------------------------- /libview/ev-job-scheduler.h: -------------------------------------------------------------------------------- 1 | /* ev-job-scheduler.h 2 | * this file is part of xreader, a mate document viewer 3 | * 4 | * Copyright (C) 2008 Carlos Garcia Campos 5 | * 6 | * Xreader is free software; you can redistribute it and/or modify it 7 | * under the terms of the GNU General Public License as published by 8 | * the Free Software Foundation; either version 2 of the License, or 9 | * (at your option) any later version. 10 | * 11 | * Xreader is distributed in the hope that it will be useful, but 12 | * WITHOUT ANY WARRANTY; without even the implied warranty of 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 14 | * General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU General Public License 17 | * along with this program; if not, write to the Free Software 18 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 19 | */ 20 | 21 | #if !defined (__EV_XREADER_VIEW_H_INSIDE__) && !defined (XREADER_COMPILATION) 22 | #error "Only can be included directly." 23 | #endif 24 | 25 | #ifndef EV_JOB_SCHEDULER_H 26 | #define EV_JOB_SCHEDULER_H 27 | 28 | #include 29 | #include "ev-jobs.h" 30 | 31 | G_BEGIN_DECLS 32 | 33 | typedef enum { 34 | EV_JOB_PRIORITY_URGENT, /* Rendering current page range */ 35 | EV_JOB_PRIORITY_HIGH, /* Rendering current thumbnail range */ 36 | EV_JOB_PRIORITY_LOW, /* Rendering pages not in current range */ 37 | EV_JOB_PRIORITY_NONE, /* Any other job: load, save, print, ... */ 38 | EV_JOB_N_PRIORITIES 39 | } EvJobPriority; 40 | 41 | void ev_job_scheduler_push_job (EvJob *job, 42 | EvJobPriority priority); 43 | void ev_job_scheduler_update_job (EvJob *job, 44 | EvJobPriority priority); 45 | EvJob *ev_job_scheduler_get_running_thread_job (void); 46 | 47 | G_END_DECLS 48 | 49 | #endif /* EV_JOB_SCHEDULER_H */ 50 | -------------------------------------------------------------------------------- /libview/ev-link-accessible.h: -------------------------------------------------------------------------------- 1 | /* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8; c-indent-level: 8 -*- */ 2 | /* this file is part of atril, a mate document viewer 3 | * 4 | * Copyright (C) 2013 Carlos Garcia Campos 5 | * 6 | * Evince is free software; you can redistribute it and/or modify it 7 | * under the terms of the GNU General Public License as published by 8 | * the Free Software Foundation; either version 2 of the License, or 9 | * (at your option) any later version. 10 | * 11 | * Evince is distributed in the hope that it will be useful, but 12 | * WITHOUT ANY WARRANTY; without even the implied warranty of 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 14 | * General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU General Public License 17 | * along with this program; if not, write to the Free Software 18 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 19 | */ 20 | 21 | #if !defined (XREADER_COMPILATION) 22 | #error "This is a private header." 23 | #endif 24 | 25 | #ifndef __EV_LINK_ACCESSIBLE_H__ 26 | #define __EV_LINK_ACCESSIBLE_H__ 27 | 28 | #include 29 | #include "ev-view-accessible.h" 30 | #include "ev-link.h" 31 | 32 | #define EV_TYPE_LINK_ACCESSIBLE (ev_link_accessible_get_type ()) 33 | #define EV_LINK_ACCESSIBLE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), EV_TYPE_LINK_ACCESSIBLE, EvLinkAccessible)) 34 | #define EV_IS_LINK_ACCESSIBLE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), EV_TYPE_LINK_ACCESSIBLE)) 35 | 36 | typedef struct _EvLinkAccessible EvLinkAccessible; 37 | typedef struct _EvLinkAccessibleClass EvLinkAccessibleClass; 38 | typedef struct _EvLinkAccessiblePrivate EvLinkAccessiblePrivate; 39 | 40 | struct _EvLinkAccessible { 41 | AtkObject parent; 42 | 43 | EvLinkAccessiblePrivate *priv; 44 | }; 45 | 46 | struct _EvLinkAccessibleClass { 47 | AtkObjectClass parent_class; 48 | }; 49 | 50 | GType ev_link_accessible_get_type (void); 51 | EvLinkAccessible *ev_link_accessible_new (EvViewAccessible *view, 52 | EvLink *link, 53 | EvRectangle *area); 54 | 55 | #endif /* __EV_LINK_ACCESSIBLE_H__ */ 56 | 57 | -------------------------------------------------------------------------------- /libview/ev-loading-window.h: -------------------------------------------------------------------------------- 1 | /* ev-loading-window.h 2 | * this file is part of xreader, a mate document viewer 3 | * 4 | * Copyright (C) 2010 Carlos Garcia Campos 5 | * 6 | * Xreader is free software; you can redistribute it and/or modify it 7 | * under the terms of the GNU General Public License as published by 8 | * the Free Software Foundation; either version 2 of the License, or 9 | * (at your option) any later version. 10 | * 11 | * Xreader is distributed in the hope that it will be useful, but 12 | * WITHOUT ANY WARRANTY; without even the implied warranty of 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 14 | * General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU General Public License 17 | * along with this program; if not, write to the Free Software 18 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 19 | */ 20 | 21 | #ifndef EV_LOADING_WINDOW_H 22 | #define EV_LOADING_WINDOW_H 23 | 24 | #include 25 | 26 | G_BEGIN_DECLS 27 | 28 | typedef struct _EvLoadingWindow EvLoadingWindow; 29 | typedef struct _EvLoadingWindowClass EvLoadingWindowClass; 30 | 31 | #define EV_TYPE_LOADING_WINDOW (ev_loading_window_get_type()) 32 | #define EV_LOADING_WINDOW(object) (G_TYPE_CHECK_INSTANCE_CAST((object), EV_TYPE_LOADING_WINDOW, EvLoadingWindow)) 33 | #define EV_LOADING_WINDOW_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass), EV_TYPE_LOADING_WINDOW, EvLoadingWindowClass)) 34 | #define EV_IS_LOADING_WINDOW(object) (G_TYPE_CHECK_INSTANCE_TYPE((object), EV_TYPE_LOADING_WINDOW)) 35 | #define EV_IS_LOADING_WINDOW_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass), EV_TYPE_LOADING_WINDOW)) 36 | #define EV_LOADING_WINDOW_GET_CLASS(object) (G_TYPE_INSTANCE_GET_CLASS((object), EV_TYPE_LOADING_WINDOW, EvLoadingWindowClass)) 37 | 38 | GType ev_loading_window_get_type (void) G_GNUC_CONST; 39 | GtkWidget *ev_loading_window_new (GtkWindow *parent); 40 | void ev_loading_window_get_size (EvLoadingWindow *window, 41 | gint *width, 42 | gint *height); 43 | void ev_loading_window_move (EvLoadingWindow *window, 44 | gint x, 45 | gint y); 46 | 47 | G_END_DECLS 48 | 49 | #endif /* EV_LOADING_WINDOW_H */ 50 | -------------------------------------------------------------------------------- /libview/ev-stock-icons.h: -------------------------------------------------------------------------------- 1 | /* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */ 2 | /* Stock icons for Xreader 3 | * 4 | * Copyright (C) 2003 Martin Kretzschmar 5 | * 6 | * Author: 7 | * Martin Kretzschmar 8 | * 9 | * Xreader is free software; you can redistribute it and/or modify it 10 | * under the terms of the GNU General Public License as published by 11 | * the Free Software Foundation; either version 2 of the License, or 12 | * (at your option) any later version. 13 | * 14 | * Xreader is distributed in the hope that it will be useful, but WITHOUT 15 | * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY 16 | * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public 17 | * License for more details. 18 | * 19 | * You should have received a copy of the GNU General Public License 20 | * along with this program; if not, write to the Free Software 21 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 22 | */ 23 | 24 | #if !defined (__EV_XREADER_VIEW_H_INSIDE__) && !defined (XREADER_COMPILATION) 25 | #error "Only can be included directly." 26 | #endif 27 | 28 | #ifndef __EV_STOCK_ICONS_H__ 29 | #define __EV_STOCK_ICONS_H__ 30 | 31 | #include 32 | 33 | G_BEGIN_DECLS 34 | 35 | /* Xreader stock icons */ 36 | #define EV_STOCK_ZOOM "zoom" 37 | #define EV_STOCK_ZOOM_PAGE "zoom-fit-height" 38 | #define EV_STOCK_ZOOM_WIDTH "zoom-fit-width" 39 | #define EV_STOCK_VIEW_DUAL "view-page-facing" 40 | #define EV_STOCK_VIEW_CONTINUOUS "view-page-continuous" 41 | #define EV_STOCK_ROTATE_LEFT "object-rotate-left" 42 | #define EV_STOCK_ROTATE_RIGHT "object-rotate-right" 43 | #define EV_STOCK_RUN_PRESENTATION "x-office-presentation" 44 | #define EV_STOCK_VISIBLE "eye" 45 | #define EV_STOCK_RESIZE_SE "resize-se" 46 | #define EV_STOCK_RESIZE_SW "resize-sw" 47 | #define EV_STOCK_CLOSE "close" 48 | #define EV_STOCK_INVERTED_COLORS "inverted" 49 | #define EV_STOCK_ATTACHMENT "mail-attachment" 50 | 51 | void ev_stock_icons_init (void); 52 | void ev_stock_icons_shutdown (void); 53 | void ev_stock_icons_set_screen (GdkScreen *screen); 54 | 55 | G_END_DECLS 56 | 57 | #endif /* __EV_STOCK_ICONS_H__ */ 58 | -------------------------------------------------------------------------------- /libview/ev-view-accessible.h: -------------------------------------------------------------------------------- 1 | /* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8; c-indent-level: 8 -*- */ 2 | /* this file is part of xreader, a mate document viewer 3 | * 4 | * Copyright (C) 2004 Red Hat, Inc 5 | * 6 | * Xreader is free software; you can redistribute it and/or modify it 7 | * under the terms of the GNU General Public License as published by 8 | * the Free Software Foundation; either version 2 of the License, or 9 | * (at your option) any later version. 10 | * 11 | * Xreader is distributed in the hope that it will be useful, but 12 | * WITHOUT ANY WARRANTY; without even the implied warranty of 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 14 | * General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU General Public License 17 | * along with this program; if not, write to the Free Software 18 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 19 | */ 20 | 21 | #if !defined (XREADER_COMPILATION) 22 | #error "This is a private header." 23 | #endif 24 | 25 | #ifndef __EV_VIEW_ACCESSIBLE_H__ 26 | #define __EV_VIEW_ACCESSIBLE_H__ 27 | 28 | #include 29 | 30 | #define EV_TYPE_VIEW_ACCESSIBLE (ev_view_accessible_get_type ()) 31 | #define EV_VIEW_ACCESSIBLE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), EV_TYPE_VIEW_ACCESSIBLE, EvViewAccessible)) 32 | #define EV_IS_VIEW_ACCESSIBLE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), EV_TYPE_VIEW_ACCESSIBLE)) 33 | 34 | typedef struct _EvViewAccessible EvViewAccessible; 35 | typedef struct _EvViewAccessibleClass EvViewAccessibleClass; 36 | typedef struct _EvViewAccessiblePrivate EvViewAccessiblePrivate; 37 | 38 | struct _EvViewAccessible 39 | { 40 | GtkContainerAccessible parent; 41 | 42 | EvViewAccessiblePrivate *priv; 43 | }; 44 | 45 | struct _EvViewAccessibleClass 46 | { 47 | GtkContainerAccessibleClass parent_class; 48 | }; 49 | 50 | GType ev_view_accessible_get_type (void); 51 | AtkObject *ev_view_accessible_new (GtkWidget *widget); 52 | 53 | #endif /* __EV_VIEW_ACCESSIBLE_H__ */ 54 | 55 | -------------------------------------------------------------------------------- /libview/ev-view-cursor.c: -------------------------------------------------------------------------------- 1 | /* this file is part of xreader, a mate document viewer 2 | * 3 | * Copyright (C) 2004 Red Hat, Inc 4 | * 5 | * Xreader is free software; you can redistribute it and/or modify it 6 | * under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation; either version 2 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * Xreader is distributed in the hope that it will be useful, but 11 | * WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | * General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with this program; if not, write to the Free Software 17 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 18 | */ 19 | 20 | #include "ev-view-cursor.h" 21 | 22 | GdkCursor * 23 | ev_view_cursor_new (GdkDisplay *display, 24 | EvViewCursor new_cursor) 25 | { 26 | GdkCursor *cursor = NULL; 27 | 28 | switch (new_cursor) { 29 | case EV_VIEW_CURSOR_NORMAL: 30 | break; 31 | case EV_VIEW_CURSOR_IBEAM: 32 | cursor = gdk_cursor_new_for_display (display, GDK_XTERM); 33 | break; 34 | case EV_VIEW_CURSOR_LINK: 35 | cursor = gdk_cursor_new_for_display (display, GDK_HAND2); 36 | break; 37 | case EV_VIEW_CURSOR_WAIT: 38 | cursor = gdk_cursor_new_for_display (display, GDK_WATCH); 39 | break; 40 | case EV_VIEW_CURSOR_HIDDEN: 41 | cursor = gdk_cursor_new_for_display (display, GDK_BLANK_CURSOR); 42 | break; 43 | case EV_VIEW_CURSOR_DRAG: 44 | cursor = gdk_cursor_new_for_display (display, GDK_FLEUR); 45 | break; 46 | case EV_VIEW_CURSOR_AUTOSCROLL: 47 | cursor = gdk_cursor_new_for_display (display, GDK_DOUBLE_ARROW); 48 | break; 49 | case EV_VIEW_CURSOR_ADD: 50 | cursor = gdk_cursor_new_for_display (display, GDK_PLUS); 51 | break; 52 | } 53 | 54 | return cursor; 55 | } 56 | -------------------------------------------------------------------------------- /libview/ev-view-cursor.h: -------------------------------------------------------------------------------- 1 | /* this file is part of xreader, a mate document viewer 2 | * 3 | * Copyright (C) 2004 Red Hat, Inc 4 | * 5 | * Xreader is free software; you can redistribute it and/or modify it 6 | * under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation; either version 2 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * Xreader is distributed in the hope that it will be useful, but 11 | * WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | * General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with this program; if not, write to the Free Software 17 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 18 | */ 19 | 20 | #if !defined (__EV_XREADER_VIEW_H_INSIDE__) && !defined (XREADER_COMPILATION) 21 | #error "Only can be included directly." 22 | #endif 23 | 24 | #ifndef __EV_VIEW_CURSOR_H__ 25 | #define __EV_VIEW_CURSOR_H__ 26 | 27 | #include 28 | 29 | G_BEGIN_DECLS 30 | 31 | typedef enum { 32 | EV_VIEW_CURSOR_NORMAL, 33 | EV_VIEW_CURSOR_IBEAM, 34 | EV_VIEW_CURSOR_LINK, 35 | EV_VIEW_CURSOR_WAIT, 36 | EV_VIEW_CURSOR_HIDDEN, 37 | EV_VIEW_CURSOR_DRAG, 38 | EV_VIEW_CURSOR_AUTOSCROLL, 39 | EV_VIEW_CURSOR_ADD 40 | } EvViewCursor; 41 | 42 | GdkCursor *ev_view_cursor_new (GdkDisplay *display, 43 | EvViewCursor cursor); 44 | 45 | G_END_DECLS 46 | 47 | #endif /* __EV_VIEW_CURSOR_H__ */ 48 | -------------------------------------------------------------------------------- /libview/ev-view-marshal.list: -------------------------------------------------------------------------------- 1 | VOID:ENUM,BOOLEAN 2 | VOID:INT,INT 3 | -------------------------------------------------------------------------------- /libview/ev-view-type-builtins.c.template: -------------------------------------------------------------------------------- 1 | /*** BEGIN file-header ***/ 2 | #include 3 | 4 | #include "ev-view-type-builtins.h" 5 | 6 | /*** END file-header ***/ 7 | 8 | /*** BEGIN file-production ***/ 9 | /* enumerations from "@filename@" */ 10 | #include "@filename@" 11 | /*** END file-production ***/ 12 | 13 | 14 | /*** BEGIN value-header ***/ 15 | GType 16 | @enum_name@_get_type (void) 17 | { 18 | static gsize g_define_type_id__volatile = 0; 19 | 20 | if (g_once_init_enter (&g_define_type_id__volatile)) { 21 | static const G@Type@Value values[] = { 22 | /*** END value-header ***/ 23 | 24 | /*** BEGIN value-production ***/ 25 | { @VALUENAME@, "@VALUENAME@", "@valuenick@" }, 26 | /*** END value-production ***/ 27 | 28 | /*** BEGIN value-tail ***/ 29 | { 0, NULL, NULL } 30 | }; 31 | GType g_define_type_id = \ 32 | g_@type@_register_static (g_intern_static_string ("@EnumName@"), values); 33 | 34 | g_once_init_leave (&g_define_type_id__volatile, g_define_type_id); 35 | } 36 | 37 | return g_define_type_id__volatile; 38 | } 39 | 40 | /*** END value-tail ***/ 41 | 42 | /*** BEGIN file-tail ***/ 43 | 44 | /*** END file-tail ***/ 45 | -------------------------------------------------------------------------------- /libview/ev-view-type-builtins.h.template: -------------------------------------------------------------------------------- 1 | /*** BEGIN file-header ***/ 2 | 3 | #if !defined (__EV_XREADER_VIEW_H_INSIDE__) && !defined (XREADER_COMPILATION) 4 | #error "Only can be included directly." 5 | #endif 6 | 7 | #ifndef EV_VIEW_TYPE_BUILTINS_H 8 | #define EV_VIEW_TYPE_BUILTINS_H 9 | 10 | #include 11 | 12 | G_BEGIN_DECLS 13 | /*** END file-header ***/ 14 | 15 | /*** BEGIN file-production ***/ 16 | 17 | /* enumerations from "@filename@" */ 18 | /*** END file-production ***/ 19 | 20 | /*** BEGIN value-header ***/ 21 | GType @enum_name@_get_type (void) G_GNUC_CONST; 22 | #define EV_TYPE_@ENUMSHORT@ (@enum_name@_get_type ()) 23 | /*** END value-header ***/ 24 | 25 | /*** BEGIN file-tail ***/ 26 | G_END_DECLS 27 | 28 | #endif /* !EV_VIEW_TYPE_BUILTINS_H */ 29 | /*** END file-tail ***/ 30 | -------------------------------------------------------------------------------- /makepot: -------------------------------------------------------------------------------- 1 | cd po 2 | INTLTOOL_EXTRACT="/usr/bin/intltool-extract" XGETTEXT="/usr/bin/xgettext" srcdir=. /usr/bin/intltool-update --gettext-package xreader --pot 3 | mv xreader.pot .. 4 | 5 | -------------------------------------------------------------------------------- /po/LINGUAS: -------------------------------------------------------------------------------- 1 | ab 2 | af 3 | am 4 | ar 5 | as 6 | ast 7 | az 8 | be 9 | be@latin 10 | ber 11 | bg 12 | bn 13 | bn_IN 14 | br 15 | ca 16 | ca@valencia 17 | cmn 18 | cs 19 | cy 20 | da 21 | de 22 | dz 23 | el 24 | en@shaw 25 | en_AU 26 | en_CA 27 | en_GB 28 | eo 29 | es 30 | es_CO 31 | es_VE 32 | et 33 | eu 34 | fa 35 | fi 36 | fr 37 | fr_CA 38 | ga 39 | gl 40 | gu 41 | he 42 | hi 43 | hr 44 | hu 45 | hy 46 | ia 47 | id 48 | ie 49 | is 50 | it 51 | ja 52 | jv 53 | ka 54 | kab 55 | kk 56 | kn 57 | ko 58 | ks 59 | ku 60 | ky 61 | la 62 | lt 63 | lv 64 | mai 65 | mg 66 | mk 67 | ml 68 | mn 69 | mr 70 | ms 71 | nb 72 | nds 73 | ne 74 | nl 75 | nn 76 | oc 77 | or 78 | pa 79 | pl 80 | ps 81 | pt 82 | pt_BR 83 | ro 84 | ru 85 | rw 86 | sc 87 | si 88 | sk 89 | sl 90 | sq 91 | sr 92 | sr@latin 93 | sv 94 | ta 95 | te 96 | th 97 | tr 98 | tt 99 | uk 100 | ur 101 | uz 102 | vi 103 | wa 104 | zgh 105 | zh_CN 106 | zh_HK 107 | zh_TW 108 | -------------------------------------------------------------------------------- /po/POTFILES.in: -------------------------------------------------------------------------------- 1 | # List of source files containing translatable strings. 2 | # Please keep this file sorted alphabetically. 3 | [encoding: UTF-8] 4 | backend/comics/comics-document.c 5 | [type: gettext/ini] backend/comics/comicsdocument.xreader-backend.in 6 | backend/djvu/djvu-document.c 7 | [type: gettext/ini] backend/djvu/djvudocument.xreader-backend.in 8 | backend/dvi/dvi-document.c 9 | [type: gettext/ini] backend/dvi/dvidocument.xreader-backend.in 10 | backend/epub/epub-document.c 11 | [type: gettext/ini] backend/epub/epubdocument.xreader-backend.in 12 | backend/pdf/ev-poppler.cc 13 | [type: gettext/ini] backend/pdf/pdfdocument.xreader-backend.in 14 | backend/ps/ev-spectre.c 15 | [type: gettext/ini] backend/ps/psdocument.xreader-backend.in 16 | backend/tiff/tiff-document.c 17 | libdocument/ev-attachment.c 18 | libdocument/ev-document-factory.c 19 | libdocument/ev-file-helpers.c 20 | cut-n-paste/smclient/eggdesktopfile.c 21 | cut-n-paste/smclient/eggsmclient.c 22 | cut-n-paste/zoom-control/ephy-zoom.h 23 | data/xreader.appdata.xml.in 24 | data/xreader.desktop.in.in 25 | previewer/ev-previewer.c 26 | previewer/ev-previewer-window.c 27 | libmisc/ev-page-action.c 28 | libmisc/ev-page-action-widget.c 29 | libview/ev-loading-window.c 30 | libview/ev-print-operation.c 31 | libview/ev-jobs.c 32 | libview/ev-view-accessible.c 33 | libview/ev-view-presentation.c 34 | libview/ev-view.c 35 | shell/eggfindbar.c 36 | shell/ev-annotation-properties-dialog.c 37 | shell/ev-annotations-toolbar.c 38 | shell/ev-application.c 39 | shell/ev-history.c 40 | shell/ev-history-action.c 41 | shell/ev-history-action-widget.c 42 | shell/ev-keyring.c 43 | shell/ev-open-recent-action.c 44 | shell/ev-password-view.c 45 | shell/ev-preferences-dialog.c 46 | [type: gettext/glade]shell/ev-preferences-dialog.ui 47 | shell/ev-properties-dialog.c 48 | shell/ev-properties-fonts.c 49 | shell/ev-properties-license.c 50 | shell/ev-sidebar-annotations.c 51 | shell/ev-sidebar-attachments.c 52 | shell/ev-sidebar-bookmarks.c 53 | shell/ev-sidebar-layers.c 54 | shell/ev-sidebar-links.c 55 | shell/ev-sidebar-thumbnails.c 56 | shell/ev-toolbar.c 57 | shell/ev-window.c 58 | shell/ev-window-title.c 59 | shell/ev-utils.c 60 | shell/main.c 61 | -------------------------------------------------------------------------------- /po/POTFILES.skip: -------------------------------------------------------------------------------- 1 | data/xreader.desktop.in 2 | backend/dvi/mdvi-lib/dviread.c 3 | backend/dvi/mdvi-lib/font.c 4 | backend/dvi/mdvi-lib/fontmap.c 5 | backend/dvi/mdvi-lib/gf.c 6 | backend/dvi/mdvi-lib/pagesel.c 7 | backend/dvi/mdvi-lib/paper.c 8 | backend/dvi/mdvi-lib/pk.c 9 | backend/dvi/mdvi-lib/sp-epsf.c 10 | backend/dvi/mdvi-lib/special.c 11 | backend/dvi/mdvi-lib/t1.c 12 | backend/dvi/mdvi-lib/tfm.c 13 | backend/dvi/mdvi-lib/tfmfile.c 14 | backend/dvi/mdvi-lib/tt.c 15 | backend/dvi/mdvi-lib/util.c 16 | backend/dvi/mdvi-lib/vf.c 17 | -------------------------------------------------------------------------------- /po/meson.build: -------------------------------------------------------------------------------- 1 | i18n.gettext(meson.project_name(), 2 | preset: 'glib' 3 | ) 4 | -------------------------------------------------------------------------------- /previewer/meson.build: -------------------------------------------------------------------------------- 1 | previewer_sources = [ 2 | 'ev-previewer.c', 3 | 'ev-previewer-window.h', 4 | 'ev-previewer-window.c', 5 | libdoc_enums, 6 | libview_enums, 7 | ] 8 | 9 | previewer_sources += gnome.compile_resources( 10 | 'previewer-resources', 'previewer.gresource.xml', 11 | source_dir: ['.', join_paths(meson.source_root(), 'data')], 12 | c_name: 'ev_previewer' 13 | ) 14 | 15 | previewer_deps = [ 16 | libdocument_dep, 17 | gio, 18 | gtk, 19 | gtk_unix_print 20 | ] 21 | 22 | executable( 23 | 'xreader-previewer', 24 | previewer_sources, 25 | dependencies: previewer_deps, 26 | link_with: [libview, libmisc], 27 | include_directories: include_dirs, 28 | install: true, 29 | ) 30 | 31 | install_data( 32 | 'xreader-previewer.1', 33 | install_dir : join_paths(prefix, get_option('mandir'), 'man1') 34 | ) 35 | -------------------------------------------------------------------------------- /previewer/previewer-ui.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | -------------------------------------------------------------------------------- /previewer/previewer.gresource.xml: -------------------------------------------------------------------------------- 1 | 2 | 18 | 19 | 20 | previewer-ui.xml 21 | xreader-previewer.css 22 | thumbnail-frame.png 23 | 24 | 25 | -------------------------------------------------------------------------------- /previewer/xreader-previewer.1: -------------------------------------------------------------------------------- 1 | .TH xreader\-previewer 1 2007\-01\-15 2 | .SH NAME 3 | xreader\-previewer \- show print preview for a document 4 | .SH SYNOPSIS 5 | \fBxreader\-previewer\fR \fB[file]\fR 6 | .SH DESCRIPTION 7 | xreader\-previewer is a program to 8 | show print preview dialog for files supported by xreader. 9 | .SH OPTIONS 10 | xreader\-previewer obeys all normal GTK+ 11 | command line options. 12 | .SH "SEE ALSO" 13 | \fBxreader\fR(1), 14 | \fBgtk\-options\fR(7). 15 | .PP 16 | https://www.github.com/linuxmint/xreader/ 17 | -------------------------------------------------------------------------------- /previewer/xreader-previewer.css: -------------------------------------------------------------------------------- 1 | evview { 2 | background-color: @theme_bg_color; 3 | } 4 | 5 | evview.document-page { 6 | background-color: @theme_bg_color; 7 | border-style: solid; 8 | border-width: 3px 3px 6px 4px; 9 | border-image: url("resource:///org/x/reader/previewer/ui/thumbnail-frame.png") 3 3 6 4; 10 | } 11 | 12 | evview.document-page.inverted { 13 | background-color: black; 14 | } 15 | -------------------------------------------------------------------------------- /shell/ev-annotations-toolbar.h: -------------------------------------------------------------------------------- 1 | /* ev-annotations-toolbar.h 2 | * this file is part of evince, a gnome document viewer 3 | * 4 | * Copyright (C) 2015 Carlos Garcia Campos 5 | * 6 | * Evince is free software; you can redistribute it and/or modify it 7 | * under the terms of the GNU General Public License as published by 8 | * the Free Software Foundation; either version 2 of the License, or 9 | * (at your option) any later version. 10 | * 11 | * Evince is distributed in the hope that it will be useful, but 12 | * WITHOUT ANY WARRANTY; without even the implied warranty of 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 14 | * General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU General Public License 17 | * along with this program; if not, write to the Free Software 18 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA. 19 | */ 20 | 21 | #ifndef __EV_ANNOTATIONS_TOOLBAR_H__ 22 | #define __EV_ANNOTATIONS_TOOLBAR_H__ 23 | 24 | #include 25 | 26 | G_BEGIN_DECLS 27 | 28 | #define EV_TYPE_ANNOTATIONS_TOOLBAR (ev_annotations_toolbar_get_type()) 29 | #define EV_ANNOTATIONS_TOOLBAR(object) (G_TYPE_CHECK_INSTANCE_CAST((object), EV_TYPE_ANNOTATIONS_TOOLBAR, EvAnnotationsToolbar)) 30 | #define EV_IS_ANNOTATIONS_TOOLBAR(object) (G_TYPE_CHECK_INSTANCE_TYPE((object), EV_TYPE_ANNOTATIONS_TOOLBAR)) 31 | #define EV_ANNOTATIONS_TOOLBAR_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass), EV_TYPE_ANNOTATIONS_TOOLBAR, EvAnnotationsToolbarClass)) 32 | #define EV_IS_ANNOTATIONS_TOOLBAR_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass), EV_TYPE_ANNOTATIONS_TOOLBAR)) 33 | #define EV_ANNOTATIONS_TOOLBAR_GET_CLASS(object) (G_TYPE_INSTANCE_GET_CLASS((object), EV_TYPE_ANNOTATIONS_TOOLBAR, EvAnnotationsToolbarClass)) 34 | 35 | typedef struct _EvAnnotationsToolbar EvAnnotationsToolbar; 36 | typedef struct _EvAnnotationsToolbarClass EvAnnotationsToolbarClass; 37 | 38 | GType ev_annotations_toolbar_get_type (void) G_GNUC_CONST; 39 | GtkWidget *ev_annotations_toolbar_new (void); 40 | void ev_annotations_toolbar_add_annot_finished (EvAnnotationsToolbar *toolbar); 41 | 42 | G_END_DECLS 43 | 44 | #endif /* __EV_ANNOTATIONS_TOOLBAR_H__ */ 45 | -------------------------------------------------------------------------------- /shell/ev-bookmark-action.h: -------------------------------------------------------------------------------- 1 | /* ev-bookmark-action.h 2 | * this file is part of evince, a gnome document viewer 3 | * 4 | * Copyright (C) 2010 Carlos Garcia Campos 5 | * 6 | * Evince is free software; you can redistribute it and/or modify it 7 | * under the terms of the GNU General Public License as published by 8 | * the Free Software Foundation; either version 2 of the License, or 9 | * (at your option) any later version. 10 | * 11 | * Evince is distributed in the hope that it will be useful, but 12 | * WITHOUT ANY WARRANTY; without even the implied warranty of 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 14 | * General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU General Public License 17 | * along with this program; if not, write to the Free Software 18 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 19 | */ 20 | 21 | #ifndef EV_BOOKMARK_ACTION_H 22 | #define EV_BOOKMARK_ACTION_H 23 | 24 | #include 25 | #include 26 | 27 | #include "ev-bookmarks.h" 28 | 29 | G_BEGIN_DECLS 30 | 31 | #define EV_TYPE_BOOKMARK_ACTION (ev_bookmark_action_get_type()) 32 | #define EV_BOOKMARK_ACTION(object) (G_TYPE_CHECK_INSTANCE_CAST((object), EV_TYPE_BOOKMARK_ACTION, EvBookmarkAction)) 33 | #define EV_BOOKMARK_ACTION_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass), EV_TYPE_BOOKMARK_ACTION, EvBookmarkActionClass)) 34 | #define EV_IS_BOOKMARK_ACTION(object) (G_TYPE_CHECK_INSTANCE_TYPE((object), EV_TYPE_BOOKMARK_ACTION)) 35 | 36 | typedef struct _EvBookmarkAction EvBookmarkAction; 37 | typedef struct _EvBookmarkActionClass EvBookmarkActionClass; 38 | 39 | GType ev_bookmark_action_get_type (void) G_GNUC_CONST; 40 | GtkAction *ev_bookmark_action_new (EvBookmark *bookmark); 41 | guint ev_bookmark_action_get_page (EvBookmarkAction *action); 42 | 43 | G_END_DECLS 44 | 45 | #endif /* EV_BOOKMARK_ACTION_H */ 46 | -------------------------------------------------------------------------------- /shell/ev-bookmarks.h: -------------------------------------------------------------------------------- 1 | /* ev-bookmarks.h 2 | * this file is part of evince, a gnome document viewer 3 | * 4 | * Copyright (C) 2010 Carlos Garcia Campos 5 | * 6 | * Evince is free software; you can redistribute it and/or modify it 7 | * under the terms of the GNU General Public License as published by 8 | * the Free Software Foundation; either version 2 of the License, or 9 | * (at your option) any later version. 10 | * 11 | * Evince is distributed in the hope that it will be useful, but 12 | * WITHOUT ANY WARRANTY; without even the implied warranty of 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 14 | * General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU General Public License 17 | * along with this program; if not, write to the Free Software 18 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 19 | */ 20 | 21 | #ifndef EV_BOOKMARKS_H 22 | #define EV_BOOKMARKS_H 23 | 24 | #include 25 | 26 | #include "ev-metadata.h" 27 | 28 | G_BEGIN_DECLS 29 | 30 | #define EV_TYPE_BOOKMARKS (ev_bookmarks_get_type()) 31 | #define EV_BOOKMARKS(object) (G_TYPE_CHECK_INSTANCE_CAST((object), EV_TYPE_BOOKMARKS, EvBookmarks)) 32 | #define EV_BOOKMARKS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass), EV_TYPE_BOOKMARKS, EvBookmarksClass)) 33 | #define EV_IS_BOOKMARKS(object) (G_TYPE_CHECK_INSTANCE_TYPE((object), EV_TYPE_BOOKMARKS)) 34 | 35 | typedef struct _EvBookmarks EvBookmarks; 36 | typedef struct _EvBookmarksClass EvBookmarksClass; 37 | 38 | typedef struct _EvBookmark { 39 | guint page; 40 | gchar *title; 41 | } EvBookmark; 42 | 43 | GType ev_bookmarks_get_type (void) G_GNUC_CONST; 44 | EvBookmarks *ev_bookmarks_new (EvMetadata *metadata); 45 | GList *ev_bookmarks_get_bookmarks (EvBookmarks *bookmarks); 46 | void ev_bookmarks_add (EvBookmarks *bookmarks, 47 | EvBookmark *bookmark); 48 | void ev_bookmarks_delete (EvBookmarks *bookmarks, 49 | EvBookmark *bookmark); 50 | void ev_bookmarks_update (EvBookmarks *bookmarks, 51 | EvBookmark *bookmark); 52 | 53 | 54 | 55 | G_END_DECLS 56 | 57 | #endif /* EV_BOOKMARKS_H */ 58 | -------------------------------------------------------------------------------- /shell/ev-daemon-gdbus.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | -------------------------------------------------------------------------------- /shell/ev-file-monitor.h: -------------------------------------------------------------------------------- 1 | /* ev-file-monitor.h 2 | * this file is part of xreader, a mate document viewer 3 | * 4 | * Copyright (C) 2008 Carlos Garcia Campos 5 | * 6 | * Xreader is free software; you can redistribute it and/or modify it 7 | * under the terms of the GNU General Public License as published by 8 | * the Free Software Foundation; either version 2 of the License, or 9 | * (at your option) any later version. 10 | * 11 | * Xreader is distributed in the hope that it will be useful, but 12 | * WITHOUT ANY WARRANTY; without even the implied warranty of 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 14 | * General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU General Public License 17 | * along with this program; if not, write to the Free Software 18 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 19 | */ 20 | 21 | #ifndef EV_FILE_MONITOR_H 22 | #define EV_FILE_MONITOR_H 23 | 24 | #include 25 | 26 | G_BEGIN_DECLS 27 | 28 | typedef struct _EvFileMonitor EvFileMonitor; 29 | typedef struct _EvFileMonitorClass EvFileMonitorClass; 30 | typedef struct _EvFileMonitorPrivate EvFileMonitorPrivate; 31 | 32 | #define EV_TYPE_FILE_MONITOR (ev_file_monitor_get_type()) 33 | #define EV_FILE_MONITOR(object) (G_TYPE_CHECK_INSTANCE_CAST((object), EV_TYPE_FILE_MONITOR, EvFileMonitor)) 34 | #define EV_FILE_MONITOR_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass), EV_TYPE_FILE_MONITOR, EvFileMonitorClass)) 35 | #define EV_IS_FILE_MONITOR(object) (G_TYPE_CHECK_INSTANCE_TYPE((object), EV_TYPE_FILE_MONITOR)) 36 | #define EV_IS_FILE_MONITOR_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass), EV_TYPE_FILE_MONITOR)) 37 | #define EV_FILE_MONITOR_GET_CLASS(object) (G_TYPE_INSTANCE_GET_CLASS((object), EV_TYPE_FILE_MONITOR, EvFileMonitorClass)) 38 | 39 | struct _EvFileMonitor { 40 | GObject base_instance; 41 | 42 | EvFileMonitorPrivate *priv; 43 | }; 44 | 45 | struct _EvFileMonitorClass { 46 | GObjectClass base_class; 47 | 48 | /* Signals */ 49 | void (*changed) (EvFileMonitor *ev_monitor); 50 | }; 51 | 52 | GType ev_file_monitor_get_type (void) G_GNUC_CONST; 53 | EvFileMonitor *ev_file_monitor_new (const gchar *uri); 54 | 55 | G_END_DECLS 56 | 57 | #endif /* EV_FILE_MONITOR_H */ 58 | -------------------------------------------------------------------------------- /shell/ev-gdbus.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | -------------------------------------------------------------------------------- /shell/ev-history-action-widget.h: -------------------------------------------------------------------------------- 1 | /* ev-history-action-widget.h 2 | * this file is part of xreader, a document viewer 3 | * 4 | * Copied and modified from evince/shell/ev-history-action-widget.h 5 | */ 6 | 7 | #ifndef EV_HISTORY_ACTION_WIDGET_H 8 | #define EV_HISTORY_ACTION_WIDGET_H 9 | 10 | #include 11 | 12 | #include "ev-history.h" 13 | 14 | G_BEGIN_DECLS 15 | 16 | #define EV_TYPE_HISTORY_ACTION_WIDGET (ev_history_action_widget_get_type()) 17 | #define EV_HISTORY_ACTION_WIDGET(object) (G_TYPE_CHECK_INSTANCE_CAST((object), EV_TYPE_HISTORY_ACTION_WIDGET, EvHistoryActionWidget)) 18 | #define EV_IS_HISTORY_ACTION_WIDGET(object) (G_TYPE_CHECK_INSTANCE_TYPE((object), EV_TYPE_HISTORY_ACTION_WIDGET)) 19 | #define EV_HISTORY_ACTION_WIDGET_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass), EV_TYPE_HISTORY_ACTION_WIDGET, EvHistoryActionWidgetClass)) 20 | #define EV_IS_HISTORY_ACTION_WIDGET_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass), EV_TYPE_HISTORY_ACTION_WIDGET)) 21 | #define EV_HISTORY_ACTION_WIDGET_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS((obj), EV_TYPE_HISTORY_ACTION_WIDGET, EvHistoryActionWidgetClass)) 22 | 23 | typedef struct _EvHistoryActionWidget EvHistoryActionWidget; 24 | typedef struct _EvHistoryActionWidgetClass EvHistoryActionWidgetClass; 25 | typedef struct _EvHistoryActionWidgetPrivate EvHistoryActionWidgetPrivate; 26 | 27 | struct _EvHistoryActionWidget 28 | { 29 | GtkToolItem parent_object; 30 | 31 | EvHistoryActionWidgetPrivate *priv; 32 | }; 33 | 34 | struct _EvHistoryActionWidgetClass 35 | { 36 | GtkToolItemClass parent_class; 37 | }; 38 | 39 | GType ev_history_action_widget_get_type (void); 40 | 41 | void ev_history_action_widget_set_history (EvHistoryActionWidget *history_widget, 42 | EvHistory *history); 43 | 44 | G_END_DECLS 45 | 46 | #endif 47 | -------------------------------------------------------------------------------- /shell/ev-history-action.h: -------------------------------------------------------------------------------- 1 | /* ev-history-action.h 2 | * this file is part of xreader, a document viewer 3 | * 4 | * Copied and modified from evince/shell/ev-history-action.h 5 | */ 6 | 7 | #ifndef EV_HISTORY_ACTION_H 8 | #define EV_HISTORY_ACTION_H 9 | 10 | #include 11 | 12 | #include "ev-history.h" 13 | 14 | G_BEGIN_DECLS 15 | 16 | #define EV_TYPE_HISTORY_ACTION (ev_history_action_get_type ()) 17 | #define EV_HISTORY_ACTION(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), EV_TYPE_HISTORY_ACTION, EvHistoryAction)) 18 | #define EV_IS_HISTORY_ACTION(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), EV_TYPE_HISTORY_ACTION)) 19 | #define EV_HISTORY_ACTION_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), EV_TYPE_HISTORY_ACTION, EvHistoryActionClass)) 20 | #define EV_IS_HISTORY_ACTION_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((obj), EV_TYPE_HISTORY_ACTION)) 21 | #define EV_HISTORY_ACTION_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS((obj), EV_TYPE_HISTORY_ACTION, EvHistoryActionClass)) 22 | 23 | typedef struct _EvHistoryAction EvHistoryAction; 24 | typedef struct _EvHistoryActionClass EvHistoryActionClass; 25 | typedef struct _EvHistoryActionPrivate EvHistoryActionPrivate; 26 | 27 | struct _EvHistoryAction 28 | { 29 | GtkAction parent; 30 | 31 | EvHistoryActionPrivate *priv; 32 | }; 33 | 34 | struct _EvHistoryActionClass 35 | { 36 | GtkActionClass parent_class; 37 | }; 38 | 39 | GType ev_history_action_get_type (void); 40 | 41 | void ev_history_action_set_history (EvHistoryAction *action, 42 | EvHistory *history); 43 | gboolean ev_history_action_get_popup_shown (EvHistoryAction *action); 44 | 45 | G_END_DECLS 46 | 47 | #endif 48 | -------------------------------------------------------------------------------- /shell/ev-keyring.h: -------------------------------------------------------------------------------- 1 | /* ev-keyring.h 2 | * this file is part of xreader, a mate document viewer 3 | * 4 | * Copyright (C) 2008 Carlos Garcia Campos 5 | * 6 | * Xreader is free software; you can redistribute it and/or modify it 7 | * under the terms of the GNU General Public License as published by 8 | * the Free Software Foundation; either version 2 of the License, or 9 | * (at your option) any later version. 10 | * 11 | * Xreader is distributed in the hope that it will be useful, but 12 | * WITHOUT ANY WARRANTY; without even the implied warranty of 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 14 | * General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU General Public License 17 | * along with this program; if not, write to the Free Software 18 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 19 | */ 20 | 21 | #ifndef __EV_KEYRING_H__ 22 | #define __EV_KEYRING_H__ 23 | 24 | #include 25 | #include 26 | 27 | G_BEGIN_DECLS 28 | 29 | gboolean ev_keyring_is_available (void); 30 | gchar *ev_keyring_lookup_password (const gchar *uri); 31 | gboolean ev_keyring_save_password (const gchar *uri, 32 | const gchar *password, 33 | GPasswordSave flags); 34 | 35 | G_END_DECLS 36 | 37 | #endif /* __EV_KEYRING_H__ */ 38 | -------------------------------------------------------------------------------- /shell/ev-marshal.list: -------------------------------------------------------------------------------- 1 | VOID:STRING,STRING 2 | -------------------------------------------------------------------------------- /shell/ev-open-recent-action.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2007, Carlos Garcia Campos 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2, or (at your option) 7 | * any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.. 17 | * 18 | */ 19 | 20 | #ifndef EV_OPEN_RECENT_ACTION_H 21 | #define EV_OPEN_RECENT_ACTION_H 22 | 23 | #include 24 | 25 | G_BEGIN_DECLS 26 | 27 | #define EV_TYPE_OPEN_RECENT_ACTION (ev_open_recent_action_get_type ()) 28 | #define EV_OPEN_RECENT_ACTION(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), EV_TYPE_OPEN_RECENT_ACTION, EvOpenRecentAction)) 29 | #define EV_OPEN_RECENT_ACTION_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), EV_TYPE_OPEN_RECENT_ACTION, EvOpenRecentActionClass)) 30 | #define EV_IS_OPEN_RECENT_ACTION(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), EV_TYPE_OPEN_RECENT_ACTION)) 31 | #define EV_IS_OPEN_RECENT_ACTION_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((obj), EV_TYPE_OPEN_RECENT_ACTION)) 32 | #define EV_OPEN_RECENT_ACTION_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS((obj), EV_TYPE_OPEN_RECENT_ACTION, EvOpenRecentActionClass)) 33 | 34 | typedef struct _EvOpenRecentAction EvOpenRecentAction; 35 | typedef struct _EvOpenRecentActionClass EvOpenRecentActionClass; 36 | 37 | struct _EvOpenRecentAction { 38 | GtkAction parent; 39 | }; 40 | 41 | struct _EvOpenRecentActionClass { 42 | GtkActionClass parent_class; 43 | 44 | void (* item_activated) (EvOpenRecentAction *action, 45 | const gchar *uri); 46 | }; 47 | 48 | GType ev_open_recent_action_get_type (void) G_GNUC_CONST; 49 | 50 | G_END_DECLS 51 | 52 | #endif /* EV_OPEN_RECENT_ACTION_H */ 53 | -------------------------------------------------------------------------------- /shell/ev-preferences-dialog.h: -------------------------------------------------------------------------------- 1 | #ifndef __EV_PREFERENCES_DIALOG_H__ 2 | #define __EV_PREFERENCES_DIALOG_H__ 3 | 4 | #include 5 | 6 | #include "ev-window.h" 7 | 8 | G_BEGIN_DECLS 9 | 10 | void 11 | ev_preferences_dialog_show (EvWindow *parent); 12 | 13 | G_END_DECLS 14 | 15 | #endif /* __EV_PREFERENCES_DIALOG_H__ */ 16 | 17 | -------------------------------------------------------------------------------- /shell/ev-properties-fonts.h: -------------------------------------------------------------------------------- 1 | /* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8; c-indent-level: 8 -*- */ 2 | /* this file is part of xreader, a mate document viewer 3 | * 4 | * Copyright (C) 2005 Red Hat, Inc 5 | * 6 | * Xreader is free software; you can redistribute it and/or modify it 7 | * under the terms of the GNU General Public License as published by 8 | * the Free Software Foundation; either version 2 of the License, or 9 | * (at your option) any later version. 10 | * 11 | * Xreader is distributed in the hope that it will be useful, but 12 | * WITHOUT ANY WARRANTY; without even the implied warranty of 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 14 | * General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU General Public License 17 | * along with this program; if not, write to the Free Software 18 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 19 | */ 20 | 21 | #ifndef __EV_PROPERTIES_FONTS_H__ 22 | #define __EV_PROPERTIES_FONTS_H__ 23 | 24 | #include "ev-document.h" 25 | 26 | #include 27 | 28 | G_BEGIN_DECLS 29 | 30 | typedef struct _EvPropertiesFonts EvPropertiesFonts; 31 | typedef struct _EvPropertiesFontsClass EvPropertiesFontsClass; 32 | typedef struct _EvPropertiesFontsPrivate EvPropertiesFontsPrivate; 33 | 34 | #define EV_TYPE_PROPERTIES_FONTS (ev_properties_fonts_get_type()) 35 | #define EV_PROPERTIES_FONTS(object) (G_TYPE_CHECK_INSTANCE_CAST((object), EV_TYPE_PROPERTIES_FONTS, EvPropertiesFonts)) 36 | #define EV_PROPERTIES_FONTS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass), EV_TYPE_PROPERTIES_FONTS, EvPropertiesFontsClass)) 37 | #define EV_IS_PROPERTIES(object) (G_TYPE_CHECK_INSTANCE_TYPE((object), EV_TYPE_PROPERTIES_FONTS)) 38 | #define EV_IS_PROPERTIES_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass), EV_TYPE_PROPERTIES_FONTS)) 39 | #define EV_PROPERTIES_FONTS_GET_CLASS(object) (G_TYPE_INSTANCE_GET_CLASS((object), EV_TYPE_PROPERTIES_FONTS, EvPropertiesFontsClass)) 40 | 41 | GType ev_properties_fonts_get_type (void); 42 | GtkWidget *ev_properties_fonts_new (void); 43 | void ev_properties_fonts_set_document (EvPropertiesFonts *properties, 44 | EvDocument *document); 45 | 46 | G_END_DECLS 47 | 48 | #endif /* __EV_PROPERTIES_FONTS_H__ */ 49 | -------------------------------------------------------------------------------- /shell/ev-properties-view.h: -------------------------------------------------------------------------------- 1 | /* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8; c-indent-level: 8 -*- */ 2 | /* this file is part of xreader, a mate document viewer 3 | * 4 | * Copyright (C) 2005 Red Hat, Inc 5 | * 6 | * Xreader is free software; you can redistribute it and/or modify it 7 | * under the terms of the GNU General Public License as published by 8 | * the Free Software Foundation; either version 2 of the License, or 9 | * (at your option) any later version. 10 | * 11 | * Xreader is distributed in the hope that it will be useful, but 12 | * WITHOUT ANY WARRANTY; without even the implied warranty of 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 14 | * General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU General Public License 17 | * along with this program; if not, write to the Free Software 18 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 19 | */ 20 | 21 | #ifndef __EV_PROPERTIES_VIEW_H__ 22 | #define __EV_PROPERTIES_VIEW_H__ 23 | 24 | #include 25 | 26 | #include 27 | 28 | G_BEGIN_DECLS 29 | 30 | typedef struct _EvPropertiesView EvPropertiesView; 31 | typedef struct _EvPropertiesViewClass EvPropertiesViewClass; 32 | typedef struct _EvPropertiesViewPrivate EvPropertiesViewPrivate; 33 | 34 | #define EV_TYPE_PROPERTIES (ev_properties_view_get_type()) 35 | #define EV_PROPERTIES_VIEW(object) (G_TYPE_CHECK_INSTANCE_CAST((object), EV_TYPE_PROPERTIES, EvPropertiesView)) 36 | #define EV_PROPERTIES_VIEW_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass), EV_TYPE_PROPERTIES, EvPropertiesViewClass)) 37 | #define EV_IS_PROPERTIES_VIEW(object) (G_TYPE_CHECK_INSTANCE_TYPE((object), EV_TYPE_PROPERTIES)) 38 | #define EV_IS_PROPERTIES_VIEW_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass), EV_TYPE_PROPERTIES)) 39 | #define EV_PROPERTIES_VIEW_GET_CLASS(object) (G_TYPE_INSTANCE_GET_CLASS((object), EV_TYPE_PROPERTIES, EvPropertiesViewClass)) 40 | 41 | GType ev_properties_view_get_type (void); 42 | void ev_properties_view_register_type (GTypeModule *module); 43 | 44 | GtkWidget *ev_properties_view_new (const gchar *uri); 45 | void ev_properties_view_set_info (EvPropertiesView *properties, 46 | const EvDocumentInfo *info); 47 | 48 | G_END_DECLS 49 | 50 | #endif /* __EV_PROPERTIES_VIEW_H__ */ 51 | -------------------------------------------------------------------------------- /shell/ev-toolbar.h: -------------------------------------------------------------------------------- 1 | /* ev-toolbar.h 2 | * this file is part of xreader, a document viewer 3 | */ 4 | 5 | #ifndef __EV_TOOLBAR_H__ 6 | #define __EV_TOOLBAR_H__ 7 | 8 | #include 9 | #include "ev-window.h" 10 | 11 | G_BEGIN_DECLS 12 | 13 | #define EV_TYPE_TOOLBAR (ev_toolbar_get_type()) 14 | #define EV_TOOLBAR(object) (G_TYPE_CHECK_INSTANCE_CAST((object), EV_TYPE_TOOLBAR, EvToolbar)) 15 | #define EV_IS_TOOLBAR(object) (G_TYPE_CHECK_INSTANCE_TYPE((object), EV_TYPE_TOOLBAR)) 16 | #define EV_TOOLBAR_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass), EV_TYPE_TOOLBAR, EvToolbarClass)) 17 | #define EV_IS_TOOLBAR_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass), EV_TYPE_TOOLBAR)) 18 | #define EV_TOOLBAR_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS((obj), EV_TYPE_TOOLBAR, EvToolbarClass)) 19 | 20 | typedef struct _EvToolbar EvToolbar; 21 | typedef struct _EvToolbarClass EvToolbarClass; 22 | typedef struct _EvToolbarPrivate EvToolbarPrivate; 23 | 24 | struct _EvToolbar 25 | { 26 | GtkToolbar parent_object; 27 | 28 | EvToolbarPrivate *priv; 29 | }; 30 | 31 | struct _EvToolbarClass 32 | { 33 | GtkToolbarClass parent_class; 34 | }; 35 | 36 | GType ev_toolbar_get_type (void); 37 | GtkWidget *ev_toolbar_new (EvWindow *window); 38 | 39 | void ev_toolbar_set_style (EvToolbar *ev_toolbar, 40 | gboolean is_fullscreen); 41 | 42 | void ev_toolbar_set_preset_sensitivity (EvToolbar *ev_toolbar, 43 | gboolean sensitive); 44 | 45 | void ev_toolbar_activate_reader_view (EvToolbar *ev_toolbar); 46 | void ev_toolbar_activate_page_view (EvToolbar *ev_toolbar); 47 | 48 | gboolean ev_toolbar_zoom_action_get_focused (EvToolbar *ev_toolbar); 49 | void ev_toolbar_zoom_action_select_all (EvToolbar *ev_toolbar); 50 | 51 | G_END_DECLS 52 | 53 | #endif /* __EV_TOOLBAR_H__ */ 54 | -------------------------------------------------------------------------------- /shell/ev-utils.h: -------------------------------------------------------------------------------- 1 | /* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8; c-indent-level: 8 -*- */ 2 | /* 3 | * Copyright (C) 2004 Anders Carlsson 4 | * 5 | * This program is free software; you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation; either version 2, or (at your option) 8 | * any later version. 9 | * 10 | * This program is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with this program; if not, write to the Free Software 17 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 18 | * 19 | */ 20 | 21 | #ifndef __EV_UTILS_H__ 22 | #define __EV_UTILS_H__ 23 | 24 | #include 25 | #include 26 | 27 | G_BEGIN_DECLS 28 | 29 | void ev_gui_menu_position_tree_selection (GtkMenu *menu, 30 | gint *x, 31 | gint *y, 32 | gboolean *push_in, 33 | gpointer user_data); 34 | 35 | void file_chooser_dialog_add_writable_pixbuf_formats (GtkFileChooser *chooser); 36 | GdkPixbufFormat* get_gdk_pixbuf_format_by_extension (gchar *uri); 37 | 38 | G_END_DECLS 39 | 40 | #endif /* __EV_VIEW_H__ */ 41 | -------------------------------------------------------------------------------- /shell/ev-window-title.h: -------------------------------------------------------------------------------- 1 | /* this file is part of xreader, a mate document viewer 2 | * 3 | * Copyright (C) 2005 Red Hat, Inc 4 | * 5 | * Xreader is free software; you can redistribute it and/or modify it 6 | * under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation; either version 2 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * Xreader is distributed in the hope that it will be useful, but 11 | * WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | * General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with this program; if not, write to the Free Software 17 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 18 | */ 19 | 20 | #ifndef __EV_WINDOW_TITLE_H__ 21 | #define __EV_WINDOW_TITLE_H__ 22 | 23 | #include "ev-window.h" 24 | #include "ev-document.h" 25 | 26 | G_BEGIN_DECLS 27 | 28 | typedef struct _EvWindowTitle EvWindowTitle; 29 | 30 | typedef enum 31 | { 32 | EV_WINDOW_TITLE_DOCUMENT, 33 | EV_WINDOW_TITLE_PASSWORD, 34 | EV_WINDOW_TITLE_RECENT 35 | } EvWindowTitleType; 36 | 37 | EvWindowTitle *ev_window_title_new (EvWindow *window); 38 | void ev_window_title_set_type (EvWindowTitle *window_title, 39 | EvWindowTitleType type); 40 | void ev_window_title_set_document (EvWindowTitle *window_title, 41 | EvDocument *document); 42 | void ev_window_title_set_uri (EvWindowTitle *window_title, 43 | const char *uri); 44 | void ev_window_title_free (EvWindowTitle *window_title); 45 | 46 | G_END_DECLS 47 | 48 | #endif /* __EV_WINDOW_TITLE_H__ */ 49 | -------------------------------------------------------------------------------- /shell/xreader.css: -------------------------------------------------------------------------------- 1 | .view.content-view { 2 | background-color: @theme_bg_color; 3 | } 4 | 5 | .view.content-view:selected { 6 | background-color: @theme_selected_bg_color; 7 | color: @theme_selected_fg_color; 8 | } 9 | 10 | evview { 11 | background-color: @theme_bg_color; 12 | } 13 | 14 | evsidebarthumbnails.page-thumbnail { 15 | background-color: @theme_bg_color; 16 | border: 1px solid black; 17 | } 18 | 19 | evsidebarthumbnails.page-thumbnail.inverted { 20 | background-color: black; 21 | border: 1px solid white; 22 | } 23 | 24 | evview.document-page { 25 | background-color: @theme_bg_color; 26 | border-style: solid; 27 | border-width: 3px 3px 6px 4px; 28 | border-image: url("resource:///org/x/reader/shell/ui/thumbnail-frame.png") 3 3 6 4; 29 | } 30 | 31 | evview.document-page.inverted { 32 | background-color: black; 33 | } 34 | 35 | #ev-loading-message { 36 | background-color: @theme_selected_bg_color; 37 | color: @theme_selected_fg_color; 38 | border-radius: 3px; 39 | padding: 8px; 40 | } 41 | 42 | evpresentationview { 43 | background-color: black; 44 | } 45 | 46 | evpresentationview.white-mode { 47 | background-color: white; 48 | } 49 | -------------------------------------------------------------------------------- /shell/xreader.gresource.xml: -------------------------------------------------------------------------------- 1 | 2 | 18 | 19 | 20 | xreader-ui.xml 21 | xreader.css 22 | ev-preferences-dialog.ui 23 | thumbnail-frame.png 24 | 25 | 26 | -------------------------------------------------------------------------------- /test/meson.build: -------------------------------------------------------------------------------- 1 | test_cases = [ 2 | 'testFileMenu.py', 3 | 'testEditMenu.py', 4 | 'testHelpMenu.py', 5 | 'testZoom.py', 6 | 'testGoMenu.py', 7 | 'testBookmarksMenu.py', 8 | 'testEncryptedFile.py', 9 | 'testFileReloading.py', 10 | 'testWrongFileExtension.py' 11 | ] 12 | 13 | foreach case : test_cases 14 | test_script = find_program(case) 15 | 16 | test( 17 | case, 18 | test_script, 19 | args: [xreader.full_path()], 20 | is_parallel: false, 21 | depends: xreader, 22 | workdir: join_paths(prefix, bindir), 23 | timeout: 120, 24 | ) 25 | endforeach 26 | -------------------------------------------------------------------------------- /test/test-encrypt.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/test/test-encrypt.pdf -------------------------------------------------------------------------------- /test/test-links.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/test/test-links.pdf -------------------------------------------------------------------------------- /test/test-mime.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/test/test-mime.bin -------------------------------------------------------------------------------- /test/test-page-labels.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/xreader/35591440f2d17d5a106791eaf8fb7d67785316ea/test/test-page-labels.pdf -------------------------------------------------------------------------------- /test/testBookmarksMenu.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python3 2 | 3 | # This test opens the Bookmarks menu. 4 | 5 | from testCommon import run_app, bail 6 | 7 | from dogtail.procedural import * 8 | 9 | try: 10 | run_app(file='test-links.pdf') 11 | 12 | focus.frame('test-links.pdf') 13 | click('Bookmarks', roleName='menu') 14 | click('Add Bookmark', roleName='menu item') 15 | 16 | click('Bookmarks', roleName='menu') 17 | click('Page 1', roleName='menu item') 18 | 19 | # Close 20 | click('File', roleName='menu') 21 | click('Close', roleName='menu item') 22 | 23 | except: 24 | bail() 25 | -------------------------------------------------------------------------------- /test/testCommon.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python3 2 | 3 | import os 4 | import sys 5 | import signal 6 | 7 | os.environ['LANG'] = 'C' 8 | 9 | from dogtail.config import config 10 | config.logDebugToStdOut = True 11 | config.logDebugToFile = False 12 | 13 | import dogtail.procedural as dt 14 | 15 | def run_app(file=None): 16 | global pid 17 | 18 | if file is not None: 19 | arguments = os.path.join(os.path.dirname(__file__), file) 20 | else: 21 | arguments = '' 22 | pid = dt.run(sys.argv[1], arguments=arguments, appName='xreader') 23 | 24 | def bail(): 25 | os.kill(pid, signal.SIGTERM) 26 | sys.exit(1) 27 | -------------------------------------------------------------------------------- /test/testEditMenu.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python3 2 | 3 | # This test opens the Edit menu and runs through the menu items. 4 | 5 | from testCommon import run_app, bail 6 | 7 | from dogtail.procedural import * 8 | 9 | try: 10 | run_app(file='test-links.pdf') 11 | 12 | # Begin to run through Edit options 13 | focus.frame('test-links.pdf') 14 | click('Edit', roleName='menu') 15 | 16 | click('Select All', roleName='menu item') 17 | 18 | click('Edit', roleName='menu') 19 | click('Find…', roleName='menu item') 20 | 21 | focus.frame('test-links.pdf') 22 | type('link') 23 | click('Find Previous', roleName='push button') 24 | 25 | click('Edit', roleName='menu') 26 | click('Find Next', roleName='menu item') 27 | 28 | click('Edit', roleName='menu') 29 | click('Find Previous', roleName='menu item') 30 | 31 | click('Edit', roleName='menu') 32 | click('Rotate Left', roleName='menu item') 33 | 34 | click('Edit', roleName='menu') 35 | click('Rotate Right', roleName='menu item') 36 | 37 | click('Edit', roleName='menu') 38 | click('Save Current Settings as Default', roleName='menu item') 39 | 40 | click('Edit', roleName='menu') 41 | click('Preferences', roleName='menu item') 42 | 43 | focus.frame('Preferences') 44 | click('Close', roleName='push button') 45 | 46 | focus.frame('test-links.pdf') 47 | click('File', roleName='menu') 48 | click('Close', roleName='menu item') 49 | 50 | except: 51 | bail() 52 | -------------------------------------------------------------------------------- /test/testEncryptedFile.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python3 2 | 3 | # Test opening a password encrypted file and unlocking it. 4 | 5 | from testCommon import run_app, bail 6 | 7 | from dogtail.procedural import * 8 | 9 | try: 10 | 11 | run_app(file='test-encrypt.pdf') 12 | 13 | # Try an incorrect password first 14 | focus.dialog('Enter password') 15 | type('wrong password') 16 | click('Unlock Document', roleName='push button') 17 | focus.dialog('Enter password') 18 | click('Cancel', roleName='push button') 19 | 20 | # Try again with the correct password 21 | focus.frame('test-encrypt.pdf — Password Required') 22 | click('Unlock Document', roleName='push button') 23 | type('Foo') 24 | focus.dialog('Enter password') 25 | click('Unlock Document', roleName='push button') 26 | 27 | # Close xreader 28 | focus.frame('test-encrypt.pdf — Dokument1') 29 | click('File', roleName='menu') 30 | click('Close', roleName='menu item') 31 | 32 | except: 33 | bail() 34 | -------------------------------------------------------------------------------- /test/testFileMenu.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python3 2 | 3 | # Test that the File menu and menu items work correctly. 4 | 5 | from testCommon import run_app, bail 6 | 7 | from dogtail.procedural import * 8 | 9 | try: 10 | run_app(file='test-links.pdf') 11 | 12 | # Open a file 13 | click('File', roleName='menu') 14 | click('Open…', roleName='menu item') 15 | click('Cancel', roleName='push button') 16 | 17 | # Save a Copy 18 | focus.frame('test-links.pdf') 19 | click('File', roleName='menu') 20 | click('Save a Copy…', roleName='menu item') 21 | click('Cancel', roleName='push button') 22 | 23 | # Print 24 | focus.frame('test-links.pdf') 25 | click('File', roleName='menu') 26 | click('Print…', roleName='menu item') 27 | focus.dialog('Print') 28 | click('Cancel', roleName='push button') 29 | 30 | # Properties 31 | focus.frame('test-links.pdf') 32 | click('File', roleName='menu') 33 | click('Properties', roleName='menu item') 34 | click('Fonts', roleName='page tab') 35 | click('General', roleName='page tab') 36 | focus.dialog('Properties') 37 | click('Close', roleName='push button') 38 | 39 | # Close All Windows 40 | focus.frame('test-links.pdf') 41 | click('File', roleName='menu') 42 | click('Close All Windows', roleName='menu item') 43 | 44 | except: 45 | bail() 46 | -------------------------------------------------------------------------------- /test/testFileReloading.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python3 2 | 3 | # Test reloading a document. 4 | 5 | from testCommon import run_app, bail 6 | 7 | from dogtail.procedural import * 8 | 9 | try: 10 | 11 | run_app(file='test-page-labels.pdf') 12 | 13 | focus.widget('page-label-entry') 14 | focus.widget.text = "iii" 15 | activate() 16 | 17 | if focus.widget.text != "III": 18 | click('File', roleName='menu') 19 | click('Close', roleName='menu item') 20 | exit (1) 21 | 22 | # Close xreader 23 | click('File', roleName='menu') 24 | click('Close', roleName='menu item') 25 | 26 | except: 27 | bail() 28 | -------------------------------------------------------------------------------- /test/testGoMenu.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python3 2 | 3 | # This test opens the Go menu and test menu items. 4 | 5 | from testCommon import run_app, bail 6 | 7 | from dogtail.procedural import * 8 | 9 | try: 10 | run_app(file='test-links.pdf') 11 | 12 | focus.frame('test-links.pdf') 13 | click('Go', roleName='menu') 14 | click('Next Page', roleName='menu item') 15 | 16 | click('Go', roleName='menu') 17 | click('Previous Page', roleName='menu item') 18 | 19 | click('Go', roleName='menu') 20 | click('Last Page', roleName='menu item') 21 | 22 | click('Go', roleName='menu') 23 | click('First Page', roleName='menu item') 24 | 25 | # Close 26 | click('File', roleName='menu') 27 | click('Close', roleName='menu item') 28 | 29 | except: 30 | bail() 31 | -------------------------------------------------------------------------------- /test/testHelpMenu.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python3 2 | 3 | # This test opens the Help menu and runs through the menu items. 4 | 5 | from testCommon import run_app, bail 6 | 7 | from dogtail.procedural import * 8 | 9 | try: 10 | run_app() 11 | 12 | click('Help', roleName='menu') 13 | click('About', roleName='menu item') 14 | focus.dialog('About Xreader') 15 | click('License', roleName='toggle button') 16 | click('Close', roleName='push button') 17 | 18 | focus.frame('Recent Documents') 19 | click('Help', roleName='menu') 20 | click('Contents', roleName='menu item') 21 | 22 | keyCombo('w') 23 | 24 | focus.frame('Recent Documents') 25 | click('File', roleName='menu') 26 | click('Close', roleName='menu item') 27 | except: 28 | bail() 29 | -------------------------------------------------------------------------------- /test/testWrongFileExtension.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python3 2 | 3 | # Test opening a file with wrong extenstion. 4 | 5 | from testCommon import run_app, bail 6 | 7 | from dogtail.procedural import * 8 | 9 | try: 10 | 11 | run_app(file='test-mime.bin') 12 | 13 | # Close xreader 14 | click('File', roleName='menu') 15 | click('Close', roleName='menu item') 16 | 17 | except: 18 | bail() 19 | -------------------------------------------------------------------------------- /test/testZoom.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python3 2 | 3 | # This test opens the View menu and test zoom features. 4 | 5 | from testCommon import run_app, bail 6 | 7 | from dogtail.procedural import * 8 | 9 | try: 10 | run_app(file='test-links.pdf') 11 | 12 | # Zoom In 13 | focus.frame('test-links.pdf') 14 | click('View', roleName='menu') 15 | click('Zoom In', roleName='menu item') 16 | 17 | # Zoom Out 18 | click('View', roleName='menu') 19 | click('Zoom Out', roleName='menu item') 20 | 21 | # Close 22 | click('File', roleName='menu') 23 | click('Close', roleName='menu item') 24 | 25 | except: 26 | bail() 27 | -------------------------------------------------------------------------------- /thumbnailer/meson.build: -------------------------------------------------------------------------------- 1 | thumbnailer_sources = [ 2 | 'xreader-thumbnailer.c', 3 | ] 4 | 5 | thumbnailer_deps = [ 6 | libdocument_dep, 7 | glib, 8 | gtk, 9 | ] 10 | 11 | executable( 12 | 'xreader-thumbnailer', 13 | thumbnailer_sources, 14 | include_directories: include_dirs, 15 | dependencies: thumbnailer_deps, 16 | install: true, 17 | ) 18 | 19 | install_data( 20 | 'xreader-thumbnailer.1', 21 | install_dir : join_paths(prefix, get_option('mandir'), 'man1') 22 | ) 23 | 24 | mime_conf = configuration_data() 25 | mime_conf.set('THUMBNAILER_MIME_TYPES', thumbnailer_mime_types) 26 | 27 | mime_file = configure_file( 28 | input: 'xreader.thumbnailer.in', 29 | output: 'xreader.thumbnailer', 30 | configuration: mime_conf, 31 | install_dir: join_paths(datadir, 'thumbnailers') 32 | ) 33 | -------------------------------------------------------------------------------- /thumbnailer/xreader-thumbnailer.1: -------------------------------------------------------------------------------- 1 | .TH xreader\-thumbnailer 1 2007\-01\-15 2 | .SH NAME 3 | xreader\-thumbnailer \- create png thumbnails from xreader supported documents 4 | .SH SYNOPSIS 5 | \fBxreader\-thumbnailer\fR [\-s \fBsize\fR] \fBinput\fR \fBoutput\fR 6 | .SH DESCRIPTION 7 | xreader\-thumbnailer is a MATE program to 8 | create thumbnails from files supported by xreader. 9 | .SH OPTIONS 10 | xreader\-thumbnailer obeys all normal GTK+ 11 | command line options. The only option \-s \fIsize 12 | \fRmakes it possible to choose the vertical size 13 | of the created thumbnail. 14 | .SH "SEE ALSO" 15 | \fBxreader\fR(1), 16 | \fBgtk\-options\fR(7). 17 | .PP 18 | http://www.mate-desktop.org// 19 | -------------------------------------------------------------------------------- /thumbnailer/xreader.thumbnailer.in: -------------------------------------------------------------------------------- 1 | [Thumbnailer Entry] 2 | TryExec=xreader-thumbnailer 3 | Exec=xreader-thumbnailer -s %s %u %o 4 | MimeType=@THUMBNAILER_MIME_TYPES@ 5 | 6 | 7 | -------------------------------------------------------------------------------- /xreader-document.pc.in: -------------------------------------------------------------------------------- 1 | prefix=@prefix@ 2 | exec_prefix=@exec_prefix@ 3 | libdir=@libdir@ 4 | includedir=@includedir@/xreader/@EV_API_VERSION@ 5 | backenddir=@libdir@/xreader/@EV_BINARY_VERSION@/backends 6 | 7 | Name: Xreader Document 8 | Description: Xreader document viewer backend library 9 | Version: @VERSION@ 10 | Requires: gio-2.0 >= @GLIB_REQUIRED@ gtk+-@GTK_API_VERSION@ >= @GTK_REQUIRED@ 11 | Libs: -L${libdir} -lxreaderdocument 12 | Cflags: -I${includedir} 13 | -------------------------------------------------------------------------------- /xreader-view.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright © 2009 Christian Persch 3 | * 4 | * This program is free software; you can redistribute it and/or modify it 5 | * under the terms of the GNU Lesser General Public License as published by the 6 | * Free Software Foundation; either version 2.1 of the License, or (at your 7 | * option) any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, but 10 | * WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser 12 | * General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU Lesser General Public License along 15 | * with this program; if not, write to the Free Software Foundation, Inc., 16 | * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 17 | */ 18 | 19 | #ifndef XREADER_VIEW_H 20 | #define XREADER_VIEW_H 21 | 22 | #define __EV_XREADER_VIEW_H_INSIDE__ 23 | 24 | #include 25 | #include 26 | #include 27 | #include 28 | #include 29 | #include 30 | #include 31 | #include 32 | 33 | #undef __EV_XREADER_VIEW_H_INSIDE__ 34 | 35 | #endif /* !XREADER_VIEW_H */ 36 | -------------------------------------------------------------------------------- /xreader-view.pc.in: -------------------------------------------------------------------------------- 1 | prefix=@prefix@ 2 | exec_prefix=@exec_prefix@ 3 | libdir=@libdir@ 4 | includedir=@includedir@/xreader/@EV_API_VERSION@ 5 | 6 | Name: Xreader View 7 | Description: MATE document viewer view library 8 | Version: @VERSION@ 9 | Requires: xreader-document-@EV_API_VERSION@ = @VERSION@ gthread-2.0 10 | Libs: -L${libdir} -lxreaderview 11 | Cflags: -I${includedir} 12 | --------------------------------------------------------------------------------