Quantcast

xmlWorker: problem with image size in table cells

classic Classic list List threaded Threaded
10 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

xmlWorker: problem with image size in table cells

roboboot
I have a very simple HTML table where every row can contain images. In my case, it contains only one image for cell. The problem is that the dimension of the image is not always resized well to fit the containing cell.

In particular in the last row the image is sized down instead to render it to a new page.

Probably is better to look at the screenshot of the PDF to have clear the problem.



The HTML is very simple:

<colgroup span="1">
</colgroup>
<colgroup span="1">
</colgroup>
                                                                                                   
          <p style="text-align:right;">
                Allegato A<br clear="none" />
                 <em>(art. 1, comma 2)</em>
          </p>
       
          <p style="text-align:right;">
                Allegato A<br clear="none" />
                 <em>(art. 1, comma 2)</em>
          </p>
       
          DDDD-001.png
       
       
          DDDD-002.png
       
       
          DDDD-003.png
       
       
          DDDD-004.png
       
       
                         
Note that changing the width attribute for the IMG tag doesn't change the behavior.

Please could xmlWorker author support me? It seems a bug...or not?

P.S. I use the latest version of xmlWorker (5.4.3)
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: xmlWorker: problem with image size in table cells

roboboot
Sorry guys...

Does anyone have some idea about it?

xmlWorker is very interesting but support is terrible. None use it?

thanks
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: xmlWorker: problem with image size in table cells

iText mailing list
On 9/4/2013 12:06 PM, roboboot wrote:
> xmlWorker is very interesting but support is terrible.

I've said it before and I'll say it again, we have grown in sales:
http://info.itextpdf.com/fast50_2013 and as we grow in sales, we also
get more tickets on our ticketing system for paying customers. These
tickets get priority.

Moreover, the (paid) group of iText developers working on XML Worker is
only active on the ticketing system for paying customers, not on the
iText mailing-list nor on StackOverflow. We don't have any XML Worker
developers on the "free" support channels.

Saying "support is terrible" isn't fair. You get what you pay for.

------------------------------------------------------------------------------
Learn the latest--Visual Studio 2012, SharePoint 2013, SQL 2012, more!
Discover the easy way to master current and previous Microsoft technologies
and advance your career. Get an incredible 1,500+ hours of step-by-step
tutorial videos with LearnDevNow. Subscribe today and save!
http://pubads.g.doubleclick.net/gampad/clk?id=58040911&iu=/4140/ostg.clktrk
_______________________________________________
iText-questions mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/itext-questions

iText(R) is a registered trademark of 1T3XT BVBA.
Many questions posted to this list can (and will) be answered with a reference to the iText book: http://www.itextpdf.com/book/
Please check the keywords list before you ask for examples: http://itextpdf.com/themes/keywords.php
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: xmlWorker: problem with image size in table cells

roboboot
When I say "support is terrible" I mean "open source community support", not "paying support". I like very much iText and if you release it as open source you should give some sort of support to the open source community. And you do this!

It is in your interest, as owners of this project, to gain people to your open source project, otherwise people could say that "open source" iText is buggy...

I know very well that you have to transform a part of your open source project in a biz model. This is very important for the life of the project (in general).

But, it's not enough saying "buy the book, or pay the support". Certain kinds of error could be confused or are bugs and I think this could be a negative image for your project.

Said that, and obviously IMHO, could you tell me if the problem I have is a bug or is something that I do in a wrong way?

regards

Roberto
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: xmlWorker: problem with image size in table cells

iText mailing list
On 9/4/2013 2:32 PM, roboboot wrote:
> if you release it as open
> source you should give some sort of support to the open source community.

Let me rephrase this assumption (because it's wrong):

if you release it as open
source the open source community should give some sort of support to the open source community.

Granted, this sentence doesn't sound correct either, but I hope you
understand why I changed it: the nature of an open source project is
that the community supports the project. Surely, you didn't mean to say
that I as an individual am obliged to give support? The last time I
checked, I lived in a free country. Nobody can force me to work for free.

> And you do this!

I'm part of the community, and therefore I give support whenever I can.

> Said that, and obviously IMHO, could you tell me if the problem I have is a
> bug or is something that I do in a wrong way?

I know iText core inside-out (and I fix bugs whenever I find them), but
I don't know anything about XML Worker (I didn't write it; I don't
currently use it). How could I tell if the problem you have is a bug or
something that you do in a wrong way?

I've seen tickets with the same question (both in XFA and XML Worker) on
the paid ticketing system. They've always been closed as "fixed" by the
customers, so... there must be a fix, but I don't know the details, nor
do I have the time to study the details.

------------------------------------------------------------------------------
Learn the latest--Visual Studio 2012, SharePoint 2013, SQL 2012, more!
Discover the easy way to master current and previous Microsoft technologies
and advance your career. Get an incredible 1,500+ hours of step-by-step
tutorial videos with LearnDevNow. Subscribe today and save!
http://pubads.g.doubleclick.net/gampad/clk?id=58040911&iu=/4140/ostg.clktrk
_______________________________________________
iText-questions mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/itext-questions

iText(R) is a registered trademark of 1T3XT BVBA.
Many questions posted to this list can (and will) be answered with a reference to the iText book: http://www.itextpdf.com/book/
Please check the keywords list before you ask for examples: http://itextpdf.com/themes/keywords.php
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: xmlWorker: problem with image size in table cells

roboboot
iText Info wrote
On 9/4/2013 2:32 PM, roboboot wrote:
> if you release it as open
> source you should give some sort of support to the open source community.

Let me rephrase this assumption (because it's wrong):

if you release it as open
source the open source community should give some sort of support to the open source community.

Granted, this sentence doesn't sound correct either, but I hope you
understand why I changed it: the nature of an open source project is
that the community supports the project. Surely, you didn't mean to say
that I as an individual am obliged to give support? The last time I
checked, I lived in a free country. Nobody can force me to work for free.
You are free to do what you want, but if you are an owner, or to be clear, if you are involved in the biz of iText, you should support for certain kinds of "question" the community. If a product like xmlWorker is not well known by the OS community, it's better for you to give support because doing that you'll help the community to use your product and to build a KB. This is what I mean and what I guess.

I understand my english is not so good but please assume that I am an honest person and what I tell you and to other readers is that a sort of "public" support would/should (or any kind of word) given.

iText Info wrote
> And you do this!

I'm part of the community, and therefore I give support whenever I can.
Thank you sir.

iText Info wrote
> Said that, and obviously IMHO, could you tell me if the problem I have is a
> bug or is something that I do in a wrong way?

I know iText core inside-out (and I fix bugs whenever I find them), but
I don't know anything about XML Worker (I didn't write it; I don't
currently use it). How could I tell if the problem you have is a bug or
something that you do in a wrong way?
But this is an answer. Thank you

iText Info wrote
I've seen tickets with the same question (both in XFA and XML Worker) on
the paid ticketing system. They've always been closed as "fixed" by the
customers, so... there must be a fix, but I don't know the details, nor
do I have the time to study the details.
Ok, so I can assume that the issue is a bug and in the future will be fixed for the OS version too. I hope someone else could suggest me the fix.

Regards

Roberto
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: xmlWorker: problem with image size in table cells

iText mailing list
On 9/4/2013 4:16 PM, roboboot wrote:
> You are free to do what you want, but if you are an owner, or to be clear,
> if you are involved in the biz of iText, you should support for certain
> kinds of "question" the community. If a product like xmlWorker is not well
> known by the OS community, it's better for you to give support because doing
> that you'll help the community to use your product and to build a KB. This
> is what I mean and what I guess.

I increased the priority level on the (paid) ticketing system. I
received a "can't reproduce the problem" response. In attachment, you'll
find a zip file with an HTML file and some code that was used in an
attempt to reproduce the problem.

Please provide a SSCCE that reproduces the problem if you think there's
a bug in iText. (See http://sscce.org/ )

------------------------------------------------------------------------------
Learn the latest--Visual Studio 2012, SharePoint 2013, SQL 2012, more!
Discover the easy way to master current and previous Microsoft technologies
and advance your career. Get an incredible 1,500+ hours of step-by-step
tutorial videos with LearnDevNow. Subscribe today and save!
http://pubads.g.doubleclick.net/gampad/clk?id=58041391&iu=/4140/ostg.clktrk
_______________________________________________
iText-questions mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/itext-questions

iText(R) is a registered trademark of 1T3XT BVBA.
Many questions posted to this list can (and will) be answered with a reference to the iText book: http://www.itextpdf.com/book/
Please check the keywords list before you ask for examples: http://itextpdf.com/themes/keywords.php

xhtml2pdf.zip (2M) Download Attachment
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: xmlWorker: problem with image size in table cells

roboboot
Thanks so much for the test case. I'm running a more complex testcase where the problem happens. ASAP I'll attach the test.

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: xmlWorker: problem with image size in table cells

roboboot
In reply to this post by iText mailing list
I investigated a little bit more your testcase and I discovered that in my code I was using xmlWorker 5.4.3 with iText 5.4.1. Run your test with ONLY the Table works fine with my images too and no issues are there.

Running your testcase with the full text has two different behavior depending on:

1) xmlWorker 5.4.3 + iText 5.4.1 ==> the images in the Table have the issues raised with my initial post
2) xmlWorker 5.4.3 + iText 5.4.3 ==> the file is truncated many rows before the table in the final PDF

So I can conclude that something in the XHTML file is wrong for xmlWorker parser that raises a unrecoverable error truncating the final PDF.

I checked the File and the encoding is correct. There are some attributes which are not strict valid for the XHTML but I think the xmlWorker is not so strict for attributes...

It seems so strange to me that iText 5.4.1 worked better than newer version 5.4.3.

I attach the testcase where you can find the full version of the file and the "mod1" modified file, where the table has been removed". The final PDFs are the same, because the error happens in the first part of the file.

Any idea?

Do I have to post this as a bug?

Thanks a lot

Roberto

iTextTest.rar
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: xmlWorker: problem with image size in table cells

roboboot
I noted that the problem is related to a TABLE TAG inside a DIV. Only in this case the Table is truncated, otherwise it works fine.

Very strange!
Loading...