Skip to content

Commit

Permalink
Merge pull request #120 from Fdawgs/feat/win32-bin-0.90.1
Browse files Browse the repository at this point in the history
update poppler win32 binaries from 0.90.0 to 0.90.1
  • Loading branch information
Fdawgs committed Jul 26, 2020
2 parents 3632bc9 + cb8c013 commit 9708a9d
Show file tree
Hide file tree
Showing 62 changed files with 154 additions and 171 deletions.
2 changes: 1 addition & 1 deletion src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ class Poppler {
__dirname,
'lib',
'win32',
'poppler-0.90.0',
'poppler-0.90.1',
'bin'
);
break;
Expand Down
2 changes: 1 addition & 1 deletion src/index.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ switch (platform) {
__dirname,
'lib',
'win32',
'poppler-0.90.0',
'poppler-0.90.1',
'bin'
);
break;
Expand Down
Binary file removed src/lib/win32/poppler-0.90.0/bin/liblzma.dll
Binary file not shown.
Binary file removed src/lib/win32/poppler-0.90.0/bin/zstd.dll
Binary file not shown.
File renamed without changes.
Binary file added src/lib/win32/poppler-0.90.1/bin/liblzma.dll
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
File renamed without changes.
File renamed without changes.
Binary file added src/lib/win32/poppler-0.90.1/bin/zstd.dll
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -22,14 +22,14 @@

#include "poppler-global.h"

namespace poppler
{
namespace poppler {
class destination_private;

class POPPLER_CPP_EXPORT destination : public poppler::noncopyable
{
public:
enum type_enum {
enum type_enum
{
unknown,
xyz,
fit,
Expand All @@ -55,7 +55,7 @@ class POPPLER_CPP_EXPORT destination : public poppler::noncopyable
bool is_change_top() const;
bool is_change_zoom() const;

destination& operator=(destination &&other) noexcept;
destination &operator=(destination &&other) noexcept;

private:
destination(destination_private *dd);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,7 @@

#include <map>

namespace poppler
{
namespace poppler {

class destination;
class document_private;
Expand All @@ -39,7 +38,8 @@ class toc;
class POPPLER_CPP_EXPORT document : public poppler::noncopyable
{
public:
enum page_mode_enum {
enum page_mode_enum
{
use_none,
use_outlines,
use_thumbs,
Expand All @@ -48,7 +48,8 @@ class POPPLER_CPP_EXPORT document : public poppler::noncopyable
use_attach
};

enum page_layout_enum {
enum page_layout_enum
{
no_layout,
single_page,
one_column,
Expand Down Expand Up @@ -100,13 +101,13 @@ class POPPLER_CPP_EXPORT document : public poppler::noncopyable
bool get_pdf_id(std::string *permanent_id, std::string *update_id) const;

int pages() const;
page* create_page(const ustring &label) const;
page* create_page(int index) const;
page *create_page(const ustring &label) const;
page *create_page(int index) const;

std::vector<font_info> fonts() const;
font_iterator* create_font_iterator(int start_page = 0) const;
font_iterator *create_font_iterator(int start_page = 0) const;

toc* create_toc() const;
toc *create_toc() const;

bool has_embedded_files() const;
std::vector<embedded_file *> embedded_files() const;
Expand All @@ -118,16 +119,9 @@ class POPPLER_CPP_EXPORT document : public poppler::noncopyable
bool save(const std::string &file_name) const;
bool save_a_copy(const std::string &file_name) const;

static document* load_from_file(const std::string &file_name,
const std::string &owner_password = std::string(),
const std::string &user_password = std::string());
static document* load_from_data(byte_array *file_data,
const std::string &owner_password = std::string(),
const std::string &user_password = std::string());
static document* load_from_raw_data(const char *file_data,
int file_data_length,
const std::string &owner_password = std::string(),
const std::string &user_password = std::string());
static document *load_from_file(const std::string &file_name, const std::string &owner_password = std::string(), const std::string &user_password = std::string());
static document *load_from_data(byte_array *file_data, const std::string &owner_password = std::string(), const std::string &user_password = std::string());
static document *load_from_raw_data(const char *file_data, int file_data_length, const std::string &owner_password = std::string(), const std::string &user_password = std::string());

private:
document(document_private &dd);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,7 @@

#include <vector>

namespace poppler
{
namespace poppler {

class embedded_file_private;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,16 +31,8 @@ using namespace poppler;
class poppler::font_info_private
{
public:
font_info_private()
: type(font_info::unknown)
, is_embedded(false)
, is_subset(false)
{
}
font_info_private(FontInfo *fi)
: type((font_info::type_enum)fi->getType())
, is_embedded(fi->getEmbedded())
, is_subset(fi->getSubset())
font_info_private() : type(font_info::unknown), is_embedded(false), is_subset(false) { }
font_info_private(FontInfo *fi) : type((font_info::type_enum)fi->getType()), is_embedded(fi->getEmbedded()), is_subset(fi->getSubset())
{
if (fi->getName()) {
font_name = fi->getName()->c_str();
Expand All @@ -63,19 +55,11 @@ class poppler::font_info_private
Ref emb_ref;
};


class poppler::font_iterator_private
{
public:
font_iterator_private(int start_page, document_private *dd)
: font_info_scanner(dd->doc, start_page)
, total_pages(dd->doc->getNumPages())
, current_page((std::max)(start_page, 0))
{
}
~font_iterator_private()
{
}
font_iterator_private(int start_page, document_private *dd) : font_info_scanner(dd->doc, start_page), total_pages(dd->doc->getNumPages()), current_page((std::max)(start_page, 0)) { }
~font_iterator_private() { }

FontInfoScanner font_info_scanner;
int total_pages;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,7 @@

#include <vector>

namespace poppler
{
namespace poppler {

class document;
class document_private;
Expand All @@ -36,7 +35,8 @@ class font_iterator_private;
class POPPLER_CPP_EXPORT font_info
{
public:
enum type_enum {
enum type_enum
{
unknown,
type1,
type1c,
Expand All @@ -61,7 +61,7 @@ class POPPLER_CPP_EXPORT font_info
bool is_subset() const;
type_enum type() const;

font_info& operator=(const font_info &fi);
font_info &operator=(const font_info &fi);

private:
font_info(font_info_private &dd);
Expand All @@ -71,7 +71,6 @@ class POPPLER_CPP_EXPORT font_info
friend class page;
};


class POPPLER_CPP_EXPORT font_iterator : public poppler::noncopyable
{
public:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,35 +23,34 @@
#define POPPLER_GLOBAL_H

#if defined(_WIN32)
# define LIB_EXPORT __declspec(dllexport)
# define LIB_IMPORT __declspec(dllimport)
# define LIB_EXPORT __declspec(dllexport)
# define LIB_IMPORT __declspec(dllimport)
#else
# define LIB_EXPORT
# define LIB_IMPORT
# define LIB_EXPORT
# define LIB_IMPORT
#endif

#if defined(poppler_cpp_EXPORTS)
# define POPPLER_CPP_EXPORT LIB_EXPORT
# define POPPLER_CPP_EXPORT LIB_EXPORT
#else
# define POPPLER_CPP_EXPORT LIB_IMPORT
# define POPPLER_CPP_EXPORT LIB_IMPORT
#endif

#include <iosfwd>
#include <string>
#include <vector>

namespace poppler
{
namespace poppler {

/// \cond DOXYGEN_SKIP_THIS
namespace detail
{
namespace detail {

class POPPLER_CPP_EXPORT noncopyable
{
public:
noncopyable(const noncopyable &) = delete;
const noncopyable& operator=(const noncopyable &) = delete;
const noncopyable &operator=(const noncopyable &) = delete;

protected:
noncopyable();
~noncopyable();
Expand All @@ -62,24 +61,49 @@ class POPPLER_CPP_EXPORT noncopyable
typedef detail::noncopyable noncopyable;
/// \endcond

enum rotation_enum { rotate_0, rotate_90, rotate_180, rotate_270 };
enum rotation_enum
{
rotate_0,
rotate_90,
rotate_180,
rotate_270
};

enum page_box_enum { media_box, crop_box, bleed_box, trim_box, art_box };
enum page_box_enum
{
media_box,
crop_box,
bleed_box,
trim_box,
art_box
};

enum permission_enum { perm_print, perm_change, perm_copy, perm_add_notes,
perm_fill_forms, perm_accessibility, perm_assemble,
perm_print_high_resolution };
enum permission_enum
{
perm_print,
perm_change,
perm_copy,
perm_add_notes,
perm_fill_forms,
perm_accessibility,
perm_assemble,
perm_print_high_resolution
};

enum case_sensitivity_enum { case_sensitive, case_insensitive };
enum case_sensitivity_enum
{
case_sensitive,
case_insensitive
};

typedef std::vector<char> byte_array;

typedef unsigned int /* time_t */ time_type;

// to disable warning only for this occurrence
#ifdef _MSC_VER
#pragma warning(push)
#pragma warning(disable: 4251) /* class 'A' needs to have dll interface for to be used by clients of class 'B'. */
# pragma warning(push)
# pragma warning(disable : 4251) /* class 'A' needs to have dll interface for to be used by clients of class 'B'. */
#endif
class POPPLER_CPP_EXPORT ustring : public std::basic_string<unsigned short>
{
Expand All @@ -98,19 +122,19 @@ class POPPLER_CPP_EXPORT ustring : public std::basic_string<unsigned short>
// forbid implicit std::string conversions
ustring(const std::string &);
operator std::string() const;
ustring& operator=(const std::string &);
ustring &operator=(const std::string &);
};
#ifdef _MSC_VER
#pragma warning(pop)
# pragma warning(pop)
#endif

POPPLER_CPP_EXPORT time_type convert_date(const std::string &date);

POPPLER_CPP_EXPORT std::ostream& operator<<(std::ostream& stream, const byte_array &array);
POPPLER_CPP_EXPORT std::ostream &operator<<(std::ostream &stream, const byte_array &array);

POPPLER_CPP_EXPORT bool set_data_dir(const std::string &new_data_dir);

typedef void(*debug_func)(const std::string &, void *);
typedef void (*debug_func)(const std::string &, void *);

POPPLER_CPP_EXPORT void set_debug_error_function(debug_func debug_function, void *closure);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,15 +23,15 @@
#include "poppler-global.h"
#include "poppler-rectangle.h"

namespace poppler
{
namespace poppler {

class image_private;

class POPPLER_CPP_EXPORT image
{
public:
enum format_enum {
enum format_enum
{
format_invalid,
format_mono,
format_rgb24,
Expand Down Expand Up @@ -60,7 +60,7 @@ class POPPLER_CPP_EXPORT image

static std::vector<std::string> supported_image_formats();

image& operator=(const image &img);
image &operator=(const image &img);

private:
void detach();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,7 @@
#include "poppler-global.h"
#include "poppler-image.h"

namespace poppler
{
namespace poppler {

typedef unsigned int argb;

Expand All @@ -34,13 +33,15 @@ class page_renderer_private;
class POPPLER_CPP_EXPORT page_renderer : public poppler::noncopyable
{
public:
enum render_hint {
enum render_hint
{
antialiasing = 0x00000001,
text_antialiasing = 0x00000002,
text_hinting = 0x00000004
};

enum line_mode_enum {
enum line_mode_enum
{
line_default,
line_solid,
line_shape
Expand All @@ -62,10 +63,7 @@ class POPPLER_CPP_EXPORT page_renderer : public poppler::noncopyable
line_mode_enum line_mode() const;
void set_line_mode(line_mode_enum mode);

image render_page(const page *p,
double xres = 72.0, double yres = 72.0,
int x = -1, int y = -1, int w = -1, int h = -1,
rotation_enum rotate = rotate_0) const;
image render_page(const page *p, double xres = 72.0, double yres = 72.0, int x = -1, int y = -1, int w = -1, int h = -1, rotation_enum rotate = rotate_0) const;

static bool can_render();

Expand Down
Loading

0 comments on commit 9708a9d

Please sign in to comment.