New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Print output html page to pdf file not working? #729

Closed
Jianru-Lin opened this Issue Nov 15, 2016 · 6 comments

Comments

Projects
None yet
4 participants
@Jianru-Lin

Jianru-Lin commented Nov 15, 2016

Hello, everyone. I'm sorry to ask such an question. But I'm just wondering why I can't print the output html page to pdf file? I can build the output html file successfully and open it with my web browser without any problem. But when I try to print it, I got an pdf file with only one page. I found if I modify the css style of the output html file, I can walk around this problem and generate an correct pdf file with all the pages.

I modified the out/ecmarkup.css to:

body {
    display: flex;
    font-size: 18px;
    line-height: 1.5;
    font-family: Cambria, Palatino Linotype, Palatino, Liberation Serif, serif;
    padding: 0;
    color: #111;
    margin: 0;
    overflow: hidden;                       /* I deleted this line */
    height: 100%;                           /* I deleted this line */
    position:absolute;                      /* I deleted this line */
    top:0; left: 0; bottom: 0; right: 0;    /* I deleted this line */
}

#spec-container {
    height: 100%;                           /* I deleted this line */
    overflow-y: auto;                       /* I deleted this line */
    overflow-x: hidden;                     /* I deleted this line */
    display: block;
    padding-left: 20px;
    flex-basis: 66%;
    flex-shrink: 0;
    flex-grow: 1;
    box-sizing: border-box;
    will-change: transform;
}

/* I added belows */
#menu,
#menu-toggle {
  display: none !important;
}

I can print the page now. However the output pdf file does not have any bookmark of the contents.

Thanks.

@littledan

This comment has been minimized.

Show comment
Hide comment
@littledan

littledan Nov 15, 2016

Member

Maybe this bug would be better in the repository https://github.com/bterlson/ecmarkup cc @bterlson

Member

littledan commented Nov 15, 2016

Maybe this bug would be better in the repository https://github.com/bterlson/ecmarkup cc @bterlson

@bterlson

This comment has been minimized.

Show comment
Hide comment
@bterlson

bterlson Nov 15, 2016

Member

Looks like my recent updates broke printing. I will fix it. A bug over at ecmarkup would be appreciated (although a bug here is appropriate - I'll have to make sure printing works in time to produce ES2017 PDFs :-P)

Member

bterlson commented Nov 15, 2016

Looks like my recent updates broke printing. I will fix it. A bug over at ecmarkup would be appreciated (although a bug here is appropriate - I'll have to make sure printing works in time to produce ES2017 PDFs :-P)

@Jianru-Lin

This comment has been minimized.

Show comment
Hide comment
@Jianru-Lin

Jianru-Lin Nov 16, 2016

@littledan @bterlson Thanks for your reply. 😄

Jianru-Lin commented Nov 16, 2016

@littledan @bterlson Thanks for your reply. 😄

@michaelficarra

This comment has been minimized.

Show comment
Hide comment
@michaelficarra

michaelficarra Jul 8, 2017

Member

@bterlson This can be closed now, right? ES2017 PDF has been created from print-to-pdf of the HTML document, so it must be fixed.

Member

michaelficarra commented Jul 8, 2017

@bterlson This can be closed now, right? ES2017 PDF has been created from print-to-pdf of the HTML document, so it must be fixed.

@bterlson

This comment has been minimized.

Show comment
Hide comment
@bterlson

bterlson Jul 9, 2017

Member

It works (although the font size is too big with the latest pdf I generated)

Member

bterlson commented Jul 9, 2017

It works (although the font size is too big with the latest pdf I generated)

@bterlson

This comment has been minimized.

Show comment
Hide comment
@bterlson

bterlson Jul 9, 2017

Member

Feel free to reopen if this is still an issue.

Member

bterlson commented Jul 9, 2017

Feel free to reopen if this is still an issue.

@bterlson bterlson closed this Jul 9, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment