Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions MANIFEST.in
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ include src/freetype/include/freetype/config/*.h
include src/freetype/include/freetype/internal/*.h
include src/freetype/include/freetype/internal/*/*.h
include src/xpydf/*
include src/xpdf-4.04/**
include src/xpdf-4.04/**/*.cc
include src/xpdf-4.04/**/*.h
include src/xpdf-4.06/**
include src/xpdf-4.06/**/*.cc
include src/xpdf-4.06/**/*.h
include src/xpydf/*.pyi
10 changes: 6 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
PROGNAME = a.out
OBJDIR = obj/
XDIR = src/xpdf-4.06/

CC = g++ -std=c++17
C = gcc -pedantic -std=c99
WARNFLAGS = -Wall
# -Wno-deprecated-declarations -Wno-writable-strings
CCFLAGS = -O3 $(WARNFLAGS) -MD -Isrc/xpdf-4.04 -Isrc/xpdf-4.04/goo -Isrc/xpdf-4.04/splash -Isrc/xpdf-4.04/xpdf -Isrc/xpdf-4.04/fofi -I/usr/local/include -Isrc/freetype/include -Isrc/freetype/include/freetype
CCFLAGS = -O3 $(WARNFLAGS) -MD -I$(XDIR) -I$(XDIR)/goo -I$(XDIR)/splash -I$(XDIR)/xpdf -I$(XDIR)/fofi -I/usr/local/include -Isrc/freetype/include -Isrc/freetype/include/freetype
CFLAGS = -O3 $(WARNFLAGS) -MD -pthread -DFT_CONFIG_CONFIG_H="<ftconfig.h>" -DFT_CONFIG_MODULES_H="<ftmodule.h>" -DFT_CONFIG_OPTIONS_H="<ftoption.h>" -DFT2_BUILD_LIBRARY -Isrc/freetype/include -Isrc/freetype/include/freetype -Isrc/freetype/include/freetype/config -Isrc/freetype/include/freetype/internal

PYDIR = src/xpydf/

XDIR = src/xpdf-4.04/
SPLASH_DIR = $(XDIR)splash/
FOFI_DIR = $(XDIR)fofi/
GOO_DIR = $(XDIR)goo/
Expand Down Expand Up @@ -163,8 +163,10 @@ clean:
cleanft:
rm -fv $(PROGNAME) $(FREE_OBJ)

install:
pip install .

test:
$(info $(FREE_DIRS))
$(info $(SKIP_DIRS))
python -m unittest -v

-include $(OBJFILES:.o=.d)
12 changes: 7 additions & 5 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,13 @@
from setuptools.command.build_ext import build_ext
from setuptools import Extension, setup

xpdf_src_dir = "src/xpdf-4.06"

python_dir = Path("src/xpydf")
xpdf_dir = Path("src/xpdf-4.04/xpdf")
splash_dir = Path("src/xpdf-4.04/splash")
fofi_dir = Path("src/xpdf-4.04/fofi")
goo_dir = Path("src/xpdf-4.04/goo")
xpdf_dir = Path(f"{xpdf_src_dir}/xpdf")
splash_dir = Path(f"{xpdf_src_dir}/splash")
fofi_dir = Path(f"{xpdf_src_dir}/fofi")
goo_dir = Path(f"{xpdf_src_dir}/goo")

python_src = glob(str(python_dir / "*.cc"))
splash_src = glob(str(splash_dir / "*.cc"))
Expand Down Expand Up @@ -137,7 +139,7 @@
"cXpdfPython",
sources = python_src + xpdf_src + splash_src + goo_src + fofi_src + freetype_sources,
include_dirs = [
"src/xpdf-4.04",
str(xpdf_src_dir),
str(xpdf_dir),
str(fofi_dir),
str(splash_dir),
Expand Down
37 changes: 0 additions & 37 deletions src/xpdf-4.04/ANNOUNCE

This file was deleted.

41 changes: 0 additions & 41 deletions src/xpdf-4.04/aconf2.h

This file was deleted.

53 changes: 53 additions & 0 deletions src/xpdf-4.06/ANNOUNCE
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
Subject: ANNOUNCE: Xpdf 4.06 - a PDF viewer and related tools

Glyph & Cog, LLC is pleased to announce a new version of Xpdf, the
open source Portable Document Format (PDF) viewer. The Xpdf project
also includes a PDF text extractor, PDF-to-PostScript converter, and
various other utilities.

Xpdf uses the Qt toolkit and runs on Linux and Windows. The
non-graphical components (pdftops, pdftotext, etc.) run on Linux,
Unix, Windows, MacOSX, and pretty much any other system with a decent
C++ compiler.

4.06 is primarily a bug fix release. There are some new features:

* New command line options/features:
- Added the '-listonly' flag to pdfimages.
- Added the '-u' option to pdfimages.
- Added the '-J' option to pdfimages to dump JPEG 2000 images.
- Modified pdftohtml to generate a nicer index page; add the
'-noframe' option to generate the previous-style index page.

* New configuration options:
- Added the 'initialMaximized' xpdfrc setting.
- Added the 'discardCoveredText' xpdfrc setting.
- Added the 'preferXFAFieldValues' xpdfrc setting.

* XpdfReader improvements:
- Added the reverseVideoMode, normalVideoMode, and toggleVideoMode
commands; added the view -> reverse video menu item.
- Added a '%t' escape to include the currently selected text in the
argument to xpdf's 'run' command.
- Use the XDG config and state file directories on Linux.
- Added a file:close menu item to Xpdf.

* Misc changes:
- Changed the default from Level 2 to Level 3 PostScript.
- Added support to pdftohtml for internal links (i.e., links to
pages in the same document).

See the `CHANGES' file for a complete list of changes.

Source (C++ and C) is available, and it should be fairly easy to
compile for Linux and Windows.

More information, source code, and precompiled binaries are on the
xpdf web page:

http://www.xpdfreader.com/

For information on commercial licensing and consulting, please see the
Glyph & Cog web site:

http://www.glyphandcog.com/
Loading