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

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...
Is there a way to close the gap?
(EVO HTML to PDF version 9.0)

EvoHtmlToPdfs table of contents is indeed a "real" HTML table:
Using CSS, you can hide the 3rd-last column:
converter.TableOfContentsOptions.GlobalStyle =
"""
td:nth-last-child(3){
display:None;
}
"""

Related

iTextSharp : block element like div?

today, i'm working with iTextSharp and I'm trying to create a PDF document with a specific structure. For that, I need to insert "blocks" (like a div in HTML) in my PDF document. This blocks have to have a border.
At the moment, i'm using PdfPTable element but I would like know if another block type exists. In my blocks, I will insert Paragraph elements, Table elements, ...
Thanx for your help

How do I remove <p> </p> tags in typo3 RTE text content elements?

Hello I'm getting crazy around a dummy problem: how to remove paragraph tags < p > that RTE (in Typo3 6.1.7) adds oafter saving some text contents. I wish to add some images here to better explain this funny thing but I can't since I've not (yet) enough reputation.
BTW I put the images on an external site:
http://s16.postimg.org/uqbu40fut/rte_ptags_1.jpg
http://s16.postimg.org/7q56roi11/rte_ptags_3.jpg
The first image is a text entered in RTE; the second image (not shown here for the same reputation matter) is the same text shown in the "<>" raw view; the last image is what I see in raw view AFTER saving the content element.
I think that I must do something in the template or in the Typoscritp settings to remove these < p > useless tags... But what ??
Those <p> tags are enabled by default because in most cases you want your Text wrapped in propper HTML markup. However, typing your question into google, gets me to this two lines of Typoscript, wich I just tested on a 6.1.7 and which seem to do the job:
tt_content.stdWrap.dataWrap >
lib.parseFunc_RTE.nonTypoTagStdWrap.encapsLines >
// Remove Class Of <p class="bodytext">
lib.parseFunc_RTE.nonTypoTagStdWrap.encapsLines.addAttributes.P.class =
// Remove P tag
tt_content.stdWrap.innerWrap >
lib.parseFunc_RTE.nonTypoTagStdWrap.encapsLines >
//Remove Extra Figure Tag of Image
tt_content.image.20.renderMethod = figure
tt_content.image.20.rendering.figure

Is posible to display html & css formatted static content in JasperReports?

I want to combine dynamically generated tables with a human created content formatted in html in the same document. The ultimate target will probably be PDF. The human generated content will generally consist of formatted text, tables and images. The formatting and layout requirements are generally fairly simple. This content will be specified in html, styled with css. The content itself will static in nature in that it will not be generated from data, but it could be sourced from files or a database. Is there a way to do this?
Static text and Text field element support html syntax (you just have to chose it in properties), but you have to use in line style formatting. Something like:
<span style="color: #999">Some gray text</span><span style="color: #000"> black text</span>

Change reading order of html form elements

I'm designing a form like this, where the bottom of the labels in that row align in straight line and the top of the input fields in that row align in straight line.
Owing to some restriction in CSS (we can't fix the height as it will vary), I've to place the labels of the form elements in first row and then place their respective input fields in the next row (such that the input fields are placed just below their labels).
I tested the keyboard & the tab order with this html structure, it works fine.
I'm wondering that the reading order in JAWS or any other screen reader is not going to be right.
Any recommendations for any method to change the reading order
or
is it ok to go ahead with this html structure since the tab order is anywys working ?
In the HTML structure each input should be preceded by its label, rather than having labels on one row and inputs on the next.
However, you have a very particular display you want, and you are supporting IE7 (without display: table), so I think you are best off actually using a table.
You can do this accessibly, if you take these things into account:
Use a basic layout table for your form, and include an extra attribute on the table tag:
<table role="presentation">
That means the table is not a table from an accessibility point of view. (I only ever recommend this when supporting IE7 layouts!) Do not use <th> tags either.
The main thing for screen readers when filling it in would be an explicit label-input relationship.
<label for="input_id">My label</label>
<input type="text" id="input_id">
You can tell if this works by clicking on the label, it should put the cursor in the input.
However, your reading view needs a different approach. When you've got a row of items at the top that relate to a row of items underneath, that is the definition of a data table. So when the page is saved (or however it converts to the reading view), use a data table e.g:
<table>
<tr>
<th>Customer account number</th>
[other <th>s]
</tr>
<tr>
<tr>
<td>023456353434</td>
...
When read out by a screen reader it will read the 'header' (e.g. customer account number) before the content (023...). So the changes are:
Remove the role
Convert the top row into <th>s
It has to be said this is a hack, it is not particularly robust, and I certainly wouldn't recommend it for a responsive site. It is purely the required layout and browser support that lead to this.
without viewing your markup its impossible to tell exactly, but it sounds like you have a tow of inputs and then a row of labels....that's not ideal for accessibility.
you could nest the form control inside the label element, setting the form control's display to block to achieve the same effect, while also increasing usability and clickability.

CSS multi-column layout of forms in Firefox

It looks like FireFox (my version is 19.0.2 - OSX) doesn't render forms properly using multicolumn layout. It renders normal paragraph text etc properly, but not forms.
The CSS:
fieldset {
-moz-column-count: 2;
column-count: 2;
-webkit-column-count: 2;
}
This is what it looks like in FireFox:
This is what it looks like in WebKit browsers:
Please view this sample code / live demo in FireFox to see that it doesn't render the multi-column layout for form elements.
Is this a bug, or is there something I can do to get it working in FireFox too?
Maybe the multi column attribute can't apply for the moment on this specific markup element that you use (namely fieldset).
Fieldset is dedicated to group some form fields, but I'm not sure it is already implemented to render in multi column...
So I should think that it is a bug that will be corrected in the future...
You can counter this by creating a simple div with flot left for the first form elements... Of course, with this option, you have to manually split the form elements that will be drawned on the left and on the right, you don't have the magic of equals length mutli-colmun anymore...
div#column1{
width : 400px;
float : left;
}
div#column2 {
float : left;
}
<div id="#column1">Your first fields</div>
<div id="#column2">Your second fields</div>