[prev in list] [next in list] [prev in thread] [next in thread]
List: freedesktop-poppler
Subject: Re: [poppler] poppler-dump
From: Marco <ctxspi () gmail ! com>
Date: 2014-03-12 19:25:45
Message-ID: CAAVAo4NSu86Q=2yzjqpq-6RrUtBSPbjGEmKZhhJjEu3y_KA7rA () mail ! gmail ! com
[Download RAW message or body]
[Attachment #2 (multipart/alternative)]
Hi Albert
Command 'pdftotext -layout filename.pdf -' it is the same if I use
physical_layout in my small program, but if I have a pdf file with text
into tables (I am sorry for my bad description), and I use command
'pdftotext filename.pdf -', it give a results that I cannot display using
'raw_order_layout' or 'physical_layout' in my program.
2014-03-12 19:49 GMT+01:00 Marco <ctxspi@gmail.com>:
> Hi to all
>
> I am new user to poppler and I have a short question.
>
> In my small program I use these lines:
>
> for (int i = 0; i < pages; ++i) {
> cout << "Page " << (i + 1) << "/" << pages << ":" << endl;
> auto_ptr<poppler::page> p(doc->create_page(i));
> poppler::byte_array text_ba = p.get()->text(p->page_rect(),
> poppler::page::raw_order_layout).to_utf8();
> text_ba.push_back(0); // Add a NULL terminator for the C char *
> string text( text_ba.begin(), text_ba.end() );
> cout << text << endl;
> }
>
> to print text of file pdf, but using 'raw_order_layout' or
> 'physical_layout' the output is different if I use the command 'pdftotext
> filename.pdf -'.
>
>
> How I can show text (but written in a pointer of char) as command
> 'pdftotext filename.pdf -' ?
>
> Thank
>
>
>
>
>
--
E' meglio coltivare GNU/Linux... tanto Windows si pianta da solo!!
[Attachment #5 (text/html)]
<div dir="ltr"><div><div>Hi Albert<br><br></div>Command 'pdftotext -layout \
filename.pdf -' it is the same if I use physical_layout in my small program, but \
if I have a pdf file with text into tables (I am sorry for my bad description), and I \
use command 'pdftotext filename.pdf -', it give a results that I cannot \
display using 'raw_order_layout' or 'physical_layout' in my \
program.<br> <br></div><div class="gmail_extra"><br><br><div \
class="gmail_quote">2014-03-12 19:49 GMT+01:00 Marco <span dir="ltr"><<a \
href="mailto:ctxspi@gmail.com" \
target="_blank">ctxspi@gmail.com</a>></span>:<br><blockquote class="gmail_quote" \
style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"> <div \
dir="ltr"><div><div><div>Hi to all<br><br></div><div>I am new user to poppler and I \
have a short question.<br><br></div><div>In my small program I use these \
lines:<br><br>for (int i = 0; i < pages; ++i) {<br> cout << "Page \
" << (i + 1) << "/" << pages << ":" \
<< endl;<br>
auto_ptr<poppler::page> p(doc->create_page(i));<br> \
poppler::byte_array text_ba = p.get()->text(p->page_rect(), \
poppler::page::raw_order_layout).to_utf8();<br> text_ba.push_back(0); // Add a \
NULL terminator for the C char *<br>
string text( text_ba.begin(), text_ba.end() );<br> cout << text << \
endl;<br> }<br><br></div><div>to print text of file pdf, but using \
'raw_order_layout' or 'physical_layout' the output is different if I \
use the command 'pdftotext filename.pdf -'.<br>
<br></div><div><br></div>How I can show text (but written in a pointer of char) as \
command 'pdftotext filename.pdf -' \
?<br><br></div><div>Thank<br></div><div><br></div><div><br></div><br> </div></div> \
</blockquote></div><br><br clear="all"><br>-- <br>E' meglio coltivare \
GNU/Linux... tanto Windows si pianta da solo!!<br> </div></div>
_______________________________________________
poppler mailing list
poppler@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/poppler
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic