tableofcontentsevopdf

EvoHtmlToPdf - gap between item and number in auto generated table of content


I am trying to create lines between items and numbers in a table of contents generated automatically by EVO HTML to Pdf. My current approach is via CSS and the TableOfContentsOptions:

converter.TableOfContentsOptions.SetItemStyle(1, "border-bottom:1px solid #000000)

and

converter.TableOfContentsOptions.SetPageNumberStyle(1, "border-bottom:1px solid #000000)

The result looks pretty good. However, there is a gap between item and number which unfortunately bothers our customers...

enter image description here

Is there a way to close the gap?

(EVO HTML to PDF version 9.0)


Solution

  • EvoHtmlToPdfs table of contents is indeed a "real" HTML table:

    enter image description here

    Using CSS, you can hide the 3rd-last column:

        converter.TableOfContentsOptions.GlobalStyle = 
                """
                    td:nth-last-child(3){
                        display:None;
                    }
                """