Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: makuke1234/PdfiumView
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: Release_0_7
Choose a base ref
...
head repository: makuke1234/PdfiumView
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: master
Choose a head ref
  • 13 commits
  • 34 files changed
  • 2 contributors

Commits on Jan 27, 2022

  1. Update 0.8 pre1

    makuke1234 committed Jan 27, 2022
    Copy the full SHA
    d4a7aa1 View commit details

Commits on Feb 25, 2022

  1. Create CODE_OF_CONDUCT.md

    makuke1234 authored Feb 25, 2022
    Copy the full SHA
    844e2ef View commit details
  2. Update issue templates

    makuke1234 authored Feb 25, 2022
    Copy the full SHA
    70e050b View commit details
  3. Create CONTRIBUTING.md

    makuke1234 authored Feb 25, 2022
    Copy the full SHA
    0a14271 View commit details

Commits on Mar 10, 2022

  1. Time badge

    makuke1234 committed Mar 10, 2022
    Copy the full SHA
    335f4fe View commit details
  2. Copy the full SHA
    631ee56 View commit details

Commits on Jun 6, 2022

  1. Copy the full SHA
    f478f0b View commit details
  2. Copy the full SHA
    9af56ad View commit details
  3. Copy the full SHA
    847d5b2 View commit details
  4. Update version + screen

    makuke1234 committed Jun 6, 2022
    Copy the full SHA
    e82cec5 View commit details
  5. Update plans

    makuke1234 committed Jun 6, 2022
    Copy the full SHA
    c7f4860 View commit details
  6. Add info

    makuke1234 committed Jun 6, 2022
    Copy the full SHA
    4be7fe6 View commit details
  7. Add version info

    makuke1234 committed Jun 6, 2022
    Copy the full SHA
    906099f View commit details
31 changes: 31 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
---
name: Bug report
about: Create a report to help us improve
title: "[BUG] This really bugs me :/"
labels: bug
assignees: makuke1234

---

**Describe the bug**
A clear and concise description of what the bug is.

**To Reproduce**
Steps to reproduce the behavior:
1. Go to '...'
2. Click on '....'
3. Scroll down to '....'
4. See error

**Expected behavior**
A clear and concise description of what you expected to happen.

**Screenshots**
If applicable, add screenshots to help explain your problem.

**Desktop (please complete the following information):**
- OS: [e.g. Windows 10 21H1] **OSes other than Windows won't be accepted (yet)!**
- Version [e.g. 0.8 pre-release1] **Please use the latest release when testing for bugs! Than you. :)**

**Additional context**
Add any other context about the problem here.
20 changes: 20 additions & 0 deletions .github/ISSUE_TEMPLATE/feature_request.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
---
name: Feature request
about: Suggest an idea for this project
title: "[FEATURE] This could be much better..."
labels: enhancement
assignees: makuke1234

---

**Is your feature request related to a problem? Please describe.**
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]

**Describe the solution you'd like**
A clear and concise description of what you want to happen.

**Describe alternatives you've considered**
A clear and concise description of any alternative solutions or features you've considered.

**Additional context**
Add any other context or screenshots about the feature request here.
128 changes: 128 additions & 0 deletions CODE_OF_CONDUCT.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,128 @@
# Contributor Covenant Code of Conduct

## Our Pledge

We as members, contributors, and leaders pledge to make participation in our
community a harassment-free experience for everyone, regardless of age, body
size, visible or invisible disability, ethnicity, sex characteristics, gender
identity and expression, level of experience, education, socio-economic status,
nationality, personal appearance, race, religion, or sexual identity
and orientation.

We pledge to act and interact in ways that contribute to an open, welcoming,
diverse, inclusive, and healthy community.

## Our Standards

Examples of behavior that contributes to a positive environment for our
community include:

* Demonstrating empathy and kindness toward other people
* Being respectful of differing opinions, viewpoints, and experiences
* Giving and gracefully accepting constructive feedback
* Accepting responsibility and apologizing to those affected by our mistakes,
and learning from the experience
* Focusing on what is best not just for us as individuals, but for the
overall community

Examples of unacceptable behavior include:

* The use of sexualized language or imagery, and sexual attention or
advances of any kind
* Trolling, insulting or derogatory comments, and personal or political attacks
* Public or private harassment
* Publishing others' private information, such as a physical or email
address, without their explicit permission
* Other conduct which could reasonably be considered inappropriate in a
professional setting

## Enforcement Responsibilities

Community leaders are responsible for clarifying and enforcing our standards of
acceptable behavior and will take appropriate and fair corrective action in
response to any behavior that they deem inappropriate, threatening, offensive,
or harmful.

Community leaders have the right and responsibility to remove, edit, or reject
comments, commits, code, wiki edits, issues, and other contributions that are
not aligned to this Code of Conduct, and will communicate reasons for moderation
decisions when appropriate.

## Scope

This Code of Conduct applies within all community spaces, and also applies when
an individual is officially representing the community in public spaces.
Examples of representing our community include using an official e-mail address,
posting via an official social media account, or acting as an appointed
representative at an online or offline event.

## Enforcement

Instances of abusive, harassing, or otherwise unacceptable behavior may be
reported to the community leaders responsible for enforcement at
makuke1234@gmail.com.
All complaints will be reviewed and investigated promptly and fairly.

All community leaders are obligated to respect the privacy and security of the
reporter of any incident.

## Enforcement Guidelines

Community leaders will follow these Community Impact Guidelines in determining
the consequences for any action they deem in violation of this Code of Conduct:

### 1. Correction

**Community Impact**: Use of inappropriate language or other behavior deemed
unprofessional or unwelcome in the community.

**Consequence**: A private, written warning from community leaders, providing
clarity around the nature of the violation and an explanation of why the
behavior was inappropriate. A public apology may be requested.

### 2. Warning

**Community Impact**: A violation through a single incident or series
of actions.

**Consequence**: A warning with consequences for continued behavior. No
interaction with the people involved, including unsolicited interaction with
those enforcing the Code of Conduct, for a specified period of time. This
includes avoiding interactions in community spaces as well as external channels
like social media. Violating these terms may lead to a temporary or
permanent ban.

### 3. Temporary Ban

**Community Impact**: A serious violation of community standards, including
sustained inappropriate behavior.

**Consequence**: A temporary ban from any sort of interaction or public
communication with the community for a specified period of time. No public or
private interaction with the people involved, including unsolicited interaction
with those enforcing the Code of Conduct, is allowed during this period.
Violating these terms may lead to a permanent ban.

### 4. Permanent Ban

**Community Impact**: Demonstrating a pattern of violation of community
standards, including sustained inappropriate behavior, harassment of an
individual, or aggression toward or disparagement of classes of individuals.

**Consequence**: A permanent ban from any sort of public interaction within
the community.

## Attribution

This Code of Conduct is adapted from the [Contributor Covenant][homepage],
version 2.0, available at
https://www.contributor-covenant.org/version/2/0/code_of_conduct.html.

Community Impact Guidelines were inspired by [Mozilla's code of conduct
enforcement ladder](https://github.com/mozilla/diversity).

[homepage]: https://www.contributor-covenant.org

For answers to common questions about this code of conduct, see the FAQ at
https://www.contributor-covenant.org/faq. Translations are available at
https://www.contributor-covenant.org/translations.
7 changes: 7 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# Contributing

This project is by no means perfect. Feel free to report any bugs, that you may find, under
**[Issues](https://github.com/makuke1234/PdfiumView/issues)**.
Also feel free to make any feature requests that come into your mind. Currently our end goal
is to achieve a PDF viewer that's super fast and lightweight. It should be **sooo** much better
than the competition. That's the philosophy here...
14 changes: 11 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -3,10 +3,13 @@
[![Release version](https://img.shields.io/github/v/release/makuke1234/PdfiumView?display_name=release&include_prereleases)](https://github.com/makuke1234/PdfiumView/releases/latest)
[![Total downloads](https://img.shields.io/github/downloads/makuke1234/PdfiumView/total)](https://github.com/makuke1234/PdfiumView/releases)
![C++ version](https://img.shields.io/badge/version-C++20-blue.svg)
[![wakatime](https://wakatime.com/badge/github/makuke1234/PdfiumView.svg)](https://wakatime.com/badge/github/makuke1234/PdfiumView)

A small and compact PDF viewer for Windows, written in C++ utilising [PDFium library](https://pdfium.googlesource.com/pdfium/).<br>
*Binaries for PDFium can be obtained [here](https://github.com/bblanchon/pdfium-binaries).*

As of 6th June 2022 the binaries are compiled with GCC 12.1.0 and use PDFium version 104.0.5104.0


# Obtaining

@@ -30,10 +33,15 @@ The x86 (32-bit) Windows binaries can be downloaded [here](https://github.com/ma

# Changelog

* 0.8 (planned)
* [ ] Fully get rid of flickering (as much as possible anyways)
* 0.9 (planned)
* [ ] Add more status bar functionality
* [ ] Add zooming capability
* [ ] Add zooming capability itself

* 0.8
* Fully get rid of flickering (as much as possible anyways)
* Reset zoom on page change
* Make zooming less aggressive (+- 10% at a time)
* Fix that annoying bug that when the current tab is closed and there are more tabs open after the closed one, the renderer would still render the closed page that is cached.

* 0.7
* Fix bugs with command-line usage
Binary file modified bin/libgcc_s_dw2-1.dll
Binary file not shown.
Binary file modified bin/libstdc++-6.dll
Binary file not shown.
Binary file modified bin/libwinpthread-1.dll
Binary file not shown.
Binary file modified bin/pdfium.dll
Binary file not shown.
Binary file modified images/screen1.PNG
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
12 changes: 12 additions & 0 deletions pdfium/include/fpdf_doc.h
Original file line number Diff line number Diff line change
@@ -98,6 +98,18 @@ FPDFBookmark_GetTitle(FPDF_BOOKMARK bookmark,
void* buffer,
unsigned long buflen);

// Experimental API.
// Get the number of chlidren of |bookmark|.
//
// bookmark - handle to the bookmark.
//
// Returns a signed integer that represents the number of sub-items the given
// bookmark has. If the value is positive, child items shall be shown by default
// (open state). If the value is negative, child items shall be hidden by
// default (closed state). Please refer to PDF 32000-1:2008, Table 153.
// Returns 0 if the bookmark has no children or is invalid.
FPDF_EXPORT int FPDF_CALLCONV FPDFBookmark_GetCount(FPDF_BOOKMARK bookmark);

// Find the bookmark with |title| in |document|.
//
// document - handle to the document.
32 changes: 32 additions & 0 deletions pdfium/include/fpdf_edit.h
Original file line number Diff line number Diff line change
@@ -1242,6 +1242,38 @@ FPDF_EXPORT FPDF_FONT FPDF_CALLCONV FPDFTextObj_GetFont(FPDF_PAGEOBJECT text);
FPDF_EXPORT unsigned long FPDF_CALLCONV
FPDFFont_GetFontName(FPDF_FONT font, char* buffer, unsigned long length);

// Experimental API.
// Get the decoded data from the |font| object.
//
// font - The handle to the font object. (Required)
// buffer - The address of a buffer that receives the font data.
// buflen - Length of the buffer.
// out_buflen - Pointer to variable that will receive the minimum buffer size
// to contain the font data. Not filled if the return value is
// FALSE. (Required)
//
// Returns TRUE on success. In which case, |out_buflen| will be filled, and
// |buffer| will be filled if it is large enough. Returns FALSE if any of the
// required parameters are null.
//
// The decoded data is the uncompressed font data. i.e. the raw font data after
// having all stream filters applied, when the data is embedded.
//
// If the font is not embedded, then this API will instead return the data for
// the substitution font it is using.
FPDF_EXPORT FPDF_BOOL FPDF_CALLCONV FPDFFont_GetFontData(FPDF_FONT font,
uint8_t* buffer,
size_t buflen,
size_t* out_buflen);

// Experimental API.
// Get whether |font| is embedded or not.
//
// font - the handle to the font object.
//
// Returns 1 if the font is embedded, 0 if it not, and -1 on failure.
FPDF_EXPORT int FPDF_CALLCONV FPDFFont_GetIsEmbedded(FPDF_FONT font);

// Experimental API.
// Get the descriptor flags of a font.
//
12 changes: 9 additions & 3 deletions pdfium/include/fpdf_formfill.h
Original file line number Diff line number Diff line change
@@ -307,7 +307,9 @@ typedef struct _IPDF_JsPlatform {
int length);

/*
* Pointer to FPDF_FORMFILLINFO interface.
* Pointer for embedder-specific data. Unused by PDFium, and despite
* its name, can be any data the embedder desires, though traditionally
* a FPDF_FORMFILLINFO interface.
*/
void* m_pFormfillinfo;

@@ -637,8 +639,9 @@ typedef struct _FPDF_FORMFILLINFO {
* Return value:
* None.
* Comments:
* See the named actions description of <<PDF Reference, version 1.7>>
* for more details.
* See ISO 32000-1:2008, section 12.6.4.11 for descriptions of the
* standard named actions, but note that a document may supply any
* name of its choosing.
*/
void (*FFI_ExecuteNamedAction)(struct _FPDF_FORMFILLINFO* pThis,
FPDF_BYTESTRING namedAction);
@@ -1480,6 +1483,9 @@ FPDF_EXPORT FPDF_BOOL FPDF_CALLCONV FORM_OnKeyDown(FPDF_FORMHANDLE hHandle,
* flag values).
* Return Value:
* True indicates success; otherwise false.
* Comments:
* Currently unimplemented and always returns false. PDFium reserves this
* API and may implement it in the future on an as-needed basis.
*/
FPDF_EXPORT FPDF_BOOL FPDF_CALLCONV FORM_OnKeyUp(FPDF_FORMHANDLE hHandle,
FPDF_PAGE page,
Loading