Giter Club home page Giter Club logo

pressbooks-mpdf's People

Contributors

alex-418 avatar bdolor avatar marclaporte avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

pressbooks-mpdf's Issues

Missing table in export

Description

Table is not appearing in an mPDF export.

Pressbooks version
screen shot 2018-11-15 at 12 57 06 pm

text editor
screen shot 2018-11-15 at 3 34 38 pm

mPDF version
screen shot 2018-11-15 at 12 56 44 pm

System Information

  • mPDF for Pressbooks: 3.2.1
  • Pressbooks: 5.5.6
  • WordPress: 4.9.8

inquiry for debug setting

Is there a debug setting to view the mPDF process?
I have found an inconsistency in TOC generation between different functioning Pressbooks instances and I am trying to narrow down why TOC is not being generated with the same content on different servers,

Regards,
Steve

SVG scrambled

WP 4.4.1, PB 3.1.2, PBT 2.1.2, PmPDF 1.0.1

SVG in Webpage:
before
SVG in mPDF Export
after

Not exporting all chapters in Table of Contents

Description

When exporting PDFs, Table of contents is coming in incomplete. Some but not all chapters are not being displayed.

screen shot 2018-02-26 at 7 44 03 pm

Expected behaviour

I would expect all the chapter titles in the table of contents.
screen shot 2018-02-26 at 7 45 12 pm

Actual behaviour

I can't make out a pattern in the behavior. Some books have no chapter titles at all, some books have some but not all.

screen shot 2018-02-27 at 8 09 57 am

Steps to reproduce the problem

I network disabled all plugins except Pressbooks, Pressbooks Aldine, Pressbooks McLuhan, Pressbooks-MPDF

Export a book to PDF and PDF only.

System Information

  • mPDF for Pressbooks: 3.1.0-rc.1
  • Pressbooks: 5.0.0-rc.1
  • WordPress: 4.9.4

Images and captions would not centre on PDF export

Description

The images and its captions are not centred when exporting to PDF.

Expected behaviour

I expected the images and their captions be centred.

Actual behaviour

Images and captions are on the left-hand side of the page.

Steps to reproduce the problem

Export to PDF using mPDF on Pressbooks. mPDF Theme options are set to A5, left margin 15 and right margin 30.

System Information

  • mPDF for Pressbooks: Version 3.1.1
  • Pressbooks: Version 5.1.0

Call to htmLawed results in errors in recent Pressbooks

Running Pressbooks 3.9.8 (dev code as of 23 March), the version of htmLawed available is the one loaded by:

if ( file_exists( PB_PLUGIN_DIR . 'symbionts/htmLawed/htmLawed.php' ) ) {
        require_once( PB_PLUGIN_DIR . 'symbionts/htmLawed/htmLawed.php' );
}

The later call to \htmlawed::filter() then fails; the current version of htmLawed expects to be called just as htmLawed(). I’m not submitting a pull request because I’m not sure how to test this to work flexibly with the “vanilla” version of htmlawed too.

Can't meet PHP ^7.1 dep requirements

Description

Given our hosting solution, we are unable to upgrade beyond PHP 7.0, making the PHP ^7.1 requirement for installing dependencies impossible for us.

Expected behaviour

composer install should install all of the dependencies

Actual behaviour

We get an error in the console as follows:

Your requirements could not be resolved to an installable set of packages.

  Problem 1
    - Installation request for doctrine/instantiator 1.1.0 -> satisfiable by doctrine/instantiator[1.1.0].
    - doctrine/instantiator 1.1.0 requires php ^7.1 -> your PHP version (7.0.19) does not satisfy that requirement.
  Problem 2
    - Installation request for symfony/yaml v4.0.1 -> satisfiable by symfony/yaml[v4.0.1].
    - symfony/yaml v4.0.1 requires php ^7.1.3 -> your PHP version (7.0.19) does not satisfy that requirement.
  Problem 3
    - doctrine/instantiator 1.1.0 requires php ^7.1 -> your PHP version (7.0.19) does not satisfy that requirement.
    - phpunit/phpunit-mock-objects 3.4.4 requires doctrine/instantiator ^1.0.2 -> satisfiable by doctrine/instantiator[1.1.0].
    - Installation request for phpunit/phpunit-mock-objects 3.4.4 -> satisfiable by phpunit/phpunit-mock-objects[3.4.4].

Steps to reproduce the problem

Install PHP version 7.0.x and attempt to install dependencies for the plugin via composer install

System Information

  • Pressbooks mPDF: 3.0.0
  • Pressbooks: 4.5.0
  • WordPress: 4.9.1

Compress Images

Description

Why we do not have an option like the ebook options about the compression of images?

captura de pantalla 2018-03-05 a las 19 40 58

Expected behaviour

To have a new feature: Compress Images | Reduce image size and quality.

I think in a soft way, nothing really agresive, as it would decrease too much the quality of the images some times.

Actual behaviour

Just ebook export have such feature.

Steps to reproduce the problem

To publish a book, export the book and the images are compress..

System Information

  • mPDF for Pressbooks: [3.1]
  • Pressbooks: [5.0]
  • WordPress: [4.9.4]

update base requirements check and notification

Description

Using Mpdf > 7.0 requires certain things to be in place, including a minimum php version, certain php modules, and minimum PB version

Expected behaviour

User should be notified if any of these dependencies are missing and will prevent them from accessing the functionality.

Actual behaviour

The requirements have changed, notifications are no longer relevant, out of date. https://mpdf.github.io/about-mpdf/requirements-v7.html

depends on #30

TOC question

What are the possible reasons why a table of contents will not be generated even though the rest of the PDF is complete?

update mPDF theme option defaults

If you create a new book and export an mPDF, it won't include the table of contents in the body of the PDF. However, if you then browse to mPDF options, you will notice that the checkbox for including the ToC is checked. If you simply click 'save' for the settings, the table of contents will show on next export.

Problem while exporting to pdf

I get a fatal error with the version 1.6.2.1 of Pressbooks mPDF while trying to export on pdf. I'm curretly using Pressbooks Version 3.9.8.1 and Wordpress version 4.7.3.

Fatal error: Cannot redeclare htmLawed() (previously declared in /var/www/vhosts/.../wp-content/plugins/pressbooks/symbionts/htmLawed/htmLawed.php:12) in /var/www/vhosts/.../wp-content/plugins/pressbooks/vendor/vanilla/htmlawed/src/htmLawed/htmLawed.php on line 147

issue on the exportation

Description

If i export a PDF i get a warming

captura de pantalla 2018-01-02 a las 12 36 15

Expected behaviour

Just to export

Actual behaviour

Export the book, and looks lik it works the pdf, but I have the warming in the exporting page

Steps to reproduce the problem

Just export the book

System Information

  • Pressbooks mPDF: [3.0]
  • Pressbooks: [4.5]
  • WordPress: [4.9.1]

Feature request: To export all the book as superadmin

Description

To have a way of exporting all the books in the superadmin dashboard.

Expected behaviour

At once, we export all the book of the site (and maybe download too)

Actual behaviour

We have to open site by site.

Steps to reproduce the problem

System Information

  • mPDF for Pressbooks: [3.1]
  • Pressbooks: [5x]
  • WordPress: [4.9.x]

Readme statement needs modification

Readme.txt (/pressbooks-mpdf/symbionts/mpdf/README.txt):

To test the installation, point your browser to the basic example file : [path_to_mpdf_folder]/mpdf/examples/example01_basic.php

Examples folder does not exist

Feature request

Description

To create a form of ex libris, passive watermark, for free output.

To have an option that by activate, each new site or old site that have activate mPDF will have a watermar.
To have an option for each book that can be independent activated or not as superadmin for each book (that would be the first step, so in the future, we can create if we wish an automatic way to have or not watermarks after the payment)

Expected behaviour

To have or not watermarks upon request

Actual behaviour

we have not watermarks

Steps to reproduce the problem

System Information

  • mPDF for Pressbooks: [3.1.1]
  • Pressbooks: [5.2]
  • WordPress: [4.9.4]

chmod() operation not permitted

We are using Pressbooks and the Pressbooks mPDF plugin on a hosting provider that does not allow the use of PHP's chmod() function and has a single dedicated place where plugins can write files to.

Our workaround for this was to comment out the chmod() line in pressbooks-mpdf.php and to symlink the ttfontdata, graph_cache, and tmp directories (in both vendor and symbionts/mpdf) to the directory our hosting provider allows write access to. All of this is to say that it works, but the solution we've implemented isn't ideal because it means we have to hack stuff in your code to make it work, and in the future when this plugin updates, we'll have to reimplement our changes.

My question is, why do the folders listed above need to be writable? What are they used for? Is there a way this plugin can work its magic without requiring write access to any files?

Feature request: superadmin settings sync across all books

Description

To be able of make the settings for superadmin

Expected behaviour

Some times, we need to have all the books in the same format. Like one school o publishing company with some style guides. Such situation requires to have all the boooks following the same settings.

As super admin, to be able to change the settings and sync across all books would help.

Examples of RCP for multisite: http://docs.restrictcontentpro.com/article/1584-using-restrict-content-pro-with-wordpress-multisite

Actual behaviour

Each book have independent settings. We need to open book by book and to change the settings

System Information

  • Pressbooks mPDF: 2.0
  • Pressbooks: 4.5
  • WordPress: 4.9.1

mPDF not working

PB 3.9.6 / PBT 3.0.1 / mPDF 1.0.1
Clicking on mPDF in Export initiates a white screen with title of book in upper left-hand side of webpage. No emailed errors.
No mPDF output.

This issue also occurs with other themes than PBT.

update configuration options

Description

mpdf > v7.0 has different configuration options than mpdf < 7.0. Ref https://mpdf.github.io/configuration/configuration-v7-x.html

Expected behaviour

User defined options from global configurations and mpdf configurations passed to the Mpdf class need to be reflected in the output.

Actual behaviour

Since these options are handled differently in the latest version, and there may be more configuration options available in 7.0+ these options will need to be handled differently as they're passed onto the Mpdf class.

depends on #30

tocs won't export

mPDF won’t export my table of contents when creating a PDF.

Will you be able to help point me in the right direction as to how to rectify this?

I have tried looking this up on the internet, but there has been no solution.

I’m using Pressbooks Version 4.5.1 and Pressbooks mPDF Version 3.0.0. and Wordpress Version 4.9.4.

I have ticked Display table of contents in the mPDF options tab in Theme Options.

The chapters have names and the parts are not hidden.

Thank you in advance.

System Information

  • mPDF for Pressbooks: 3.0
  • Pressbooks: 4.5.1
  • WordPress: 4.9.4

Languages exported as strange character

Description

Languages other than English exported as strange character. Example Language: Tamil

The book exporting properly in other options prince, ebook etc.

Expected behaviour

exporting actual unicode language

Actual behaviour
Strange characters exported

ss

Steps to reproduce the problem

System Information

  • mPDF for Pressbooks: Version 3.2.1
  • Pressbooks: Version 5.4.5
  • WordPress: [Enter WP Version number here]

Request for the ability to control font size in mPDF theme options

Description

In Prince PDF formats, there is the option to increase the font size of all text via PDF theme options. This feature is often used in language-learning texts where people are learning to read, and larger text can increase the accessibility of a text for people with visual impairments.
changefontsize

Request: Add the ability to increase font size and line height of all text to mPDF theme options.

mPDF export fails on Pressbooks dev

Description

When I try to export a book as a mPDF on pressbooksdev, the export fails and I get the following message:

This page isn’t working
pressbooksdev.bccampus.ca is currently unable to handle this request.
HTTP ERROR 500

Expected behaviour

When I select mPDF as an export option and try to export a book, Pressbooks creates an mPDF file for download.

Actual behaviour

When I try to export a book as an mPDF, I am shown a page with the following error message and no mPDF file is created:

This page isn’t working
pressbooksdev.bccampus.ca is currently unable to handle this request.
HTTP ERROR 500

Steps to reproduce the problem

  1. Select mPDF as an export option for a book in pressbooks dev.
  2. Try to export the book as an mPDF.
  3. You are redirected to the error message.

System Information

pressbooksdev

  • mPDF for Pressbooks: [Enter PBmPDF Version here]

Theme Parity

Description

The output of the PDF doesn't reflect the style choices defined by the theme.

Expected behaviour

There's a reasonable expectation that the output format would retain/reflect all or most of the styles determined by the chosen theme.

Actual behaviour

It resembles theme independence. There is very little (any?) relationship between a web theme and the look and feel of the PDF file

Style inconsistencies between Prince and mPDF

Description

I don't think any of these things are a priority, but there are a few style inconsistencies between the Prince PDFs and mPDF files. I'm writing them down so they don't get forgotten, but if we dicide to ignore then we can close this issue.

Page Numbers

Prince PDF uses Arabic numerals only, and page numbering runs uninterrupted from the first page of the front matter to the last page of the back matter. Page numbers do not start over at the beginning of the main body.

In mPDF, the front matter is numbered with Roman numerals. At the beginning of the main body, numbers switch to Arabic numerals and start at 1.

Line spacing

In Prince PDF, there are spaces inserted between items in a list.
princelistspace

In mPDF, there are no spaces between list items. This applies to both ordered and unordered lists.
mpdflistspace

Textbox colours

All of the textboxes appear without styling (shaded textboxes and all of the educational textboxes) in the mPDF format.

This means that all of these textboxes appear white, and the headings in educational textboxes are no longer set off from the rest of the textbox:

mpdf textboxes

Text wrapping and images

In Prince PDF, text wraps around images if they are right/left aligned.
princetextwrap

Text will not wrap around images that are left/right-aligned in mPDF.
mpdftextwrap

Bold table headings

In Prince formats, the captions for tables appear bolded and centred.

In mPDF format, table captions appear centred but not bolded.

Running headers

In Prince PDF, you can control what appears in running headers in PDF theme options. The default, however, is alternating author name and book title on each page.

In mPDF, only the book title appears in the running header (on each page), and there is not option to change running header options in mPDF theme options

Feature request: Export preview and Independent export

Description

To be able to see a preview of the PDF page for each chapter or part (by using the pdf settings for such preview).
To be able to export an independent chapter or part from the edit page.

Expected behaviour

To have in each page a buttom where we can see in a pop up how would be the exported current page.
Also a way to export just one chapter or part without export the full book.

Actual behaviour

Now, if we need to know how looks like a page, we need to export a full book and to take a look. Is important to know how looks like a PDF page, the current way is slow.
Also, some times we just need to give one chapter, to export each chapter as independent would give us more flexibility as in the current way, many settings are necesary for such purpose.

System Information

  • Pressbooks mPDF: [2.0.0.]
  • Pressbooks: [4.5]
  • WordPress: [4.9.1]

Feature request: To no export parts setting option

Description

Some times, we have so many parts. All of them are for organization behaviour. We do not use in web view. So, maybe is good idea to have an option and to not export as pdf.

Expected behaviour

To export a book. To not export the parts of the book.

Actual behaviour

We export parts and chapters

Steps to reproduce the problem

export a book as pdf and take a look.

System Information

  • mPDF for Pressbooks: [3.1.3]
  • Pressbooks: [5.4]
  • WordPress: [4.9.7]

Feature request: Optimice pdf after creation

Description

To be able to have a smaller file

Expected behaviour

To have an optimice fille

Actual behaviour

We have a file that is too big. No automatic proces for the optimization.

Steps to reproduce the problem

To export a file, then go to see the size (2.4mb my example) and after is created must be manually optimice (0,5mb my example).

System Information

  • mPDF for Pressbooks: [3.1.2]
  • Pressbooks: [5.3.3]
  • WordPress: [4.9.6]

Sidebar textboxes don't appear as sidebars

Description

Sidebar textboxes appear as regular textboxes in mPDF.

Expected behaviour

When I have a sidebar in my book, I expect that it will appear as a sidebar in mPDF format.

What the sidebar textbox looks like in Prince:
princesidebar

Actual behaviour

Textboxes that are added as sidebars appear as regular textboxes in mPDF.

What the sidebar textbox looks like in mPDF:
mpdfsidebar

Steps to reproduce the problem

  1. Add a sidebar textbox to your chapter.
  2. Export book as mPDF.
  3. Look at the textbox that is supposed to be a sidebar. See that it is not a sidebar and just a regular textbox. Sigh in defeat.

Request for automatic numbering of bookmarks to be turned off

Description

If the web book have Display part and chapter numbers deactivated,
captura de pantalla 2018-07-27 09 30 57

maybe we should match the table of contents of the pdf in the same way and not to show the numbers.

Expected behaviour

To not to have numbers in the left of the titles of the sidebar TOC

Actual behaviour
we have the numered TOC

captura de pantalla 2018-07-27 09 30 19

Steps to reproduce the problem

[First Step, Second Step, etc]

System Information

  • mPDF for Pressbooks: [3.2]
  • Pressbooks: [5.4.2]
  • WordPress: [4.9.7]

Table of Contents missing

WP 4.4.1, PB 3.1.2, PBT 2.1.2, PmPDF 1.0.1
Export to PDF does not create a TOC, even when Table of Contents > Display table of contents is enabled.
No errors generated.

Improve github to svn workflow for WP repo

Description

It's manual. It's time consuming. Smart people have created things to make this work better.

Expected behaviour

Posting to WP repo after a github release should be an integrated and/or semi-automatic process.

Actual behaviour

It's manual and time consuming.

Steps to reproduce the problem

Tag a release in Github. Then fiddle through an SVN release process.

Table of Contents missing when Part title is changed

Assuming "Set as ebook start-point" has been enabled for first item in Front Matter...

Modifying Main Body title to something else such as "Part I" will disable Table of Contents generation.

(Reproduced on fresh install instance of Pressbooks)

folder of fonts

Now we have two folders with fonts. The one of Pressbooks and another in Pressbooks mPDF.

90mb in Pressbooks mPDF
40mb in Pressbooks

As the fonts are not the same. Is necesary to have that duplicity? is not possible to load the fonts in Pressbooks mPDF from Pressbooks in order to have the same syle in web and in pdf? or just to have the same fonts in both folders for a better compatibility?

Are the fonts on Pressbooks selected for a specifical reason? a deep review of the fonts is necesary?

thanks

PDF (for print) PDF (for digital distribution)

Description

Each situation requires a different aproach.

  • PDF (for print) requires the url of the embeb pages, maybe to not to show the embebs of the videos and audios..
  • PDF (for digital distribution) requires the page name instead of the page url, the preview of some embebs..

Expected behaviour

to have two options of exportation. Even if curently do nothing different, as we allow us to modify our site with common standart, so in the future it will be easy to merge the work of the branches if necesary.

Actual behaviour

just one version.

Steps to reproduce the problem

[First Step, Second Step, etc]

System Information

  • mPDF for Pressbooks: [3.2.1]
  • Pressbooks: [5.5.5]
  • WordPress: [4.9.8]

update PB instance

Description

update our dev and production instance of PB to all the latest.

features request: paper size information

Description

To have more information about the sizes of the papers.

Expected behaviour

To have in the settings page an info buttom with the sizes of the papers. One for all or one for each (maybe as an external link).

As you did in the last 2 types of papers
captura de pantalla 2017-12-16 a las 9 46 08

Actual behaviour

We have just the name of the types of paper

other

The readme files I did, was with the wordpress.org format on my mind. I think, the == Frequently Asked Questions == should stay, not in the .md file but in the .txt file. if the information is not direct inside of the settings page

System Information

  • Pressbooks mPDF: [3]
  • Pressbooks: [4.5]
  • WordPress: [4.9.1]

Unable to change margins in mPDF theme options

Description

When I try to change the margins in mPDF theme options, my changes are removed after I click "Save."

Expected behaviour

I expect that when I change the margins in mPDF theme options, that my changes will be preserved and applied to the next mPDF export when I click save.

Actual behaviour

I open mPDF theme options. I change the left and right margins. I click save. The values in the left and right margins are reverted to their original values.

Steps to reproduce the problem

  1. Open mPDF theme options for a book.
  2. Change left margin to 20.
  3. Change right margin to 20.
  4. Click save.
  5. Watch the margins change back to 15 and 30.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.