Search the web
Sign In
New User? Sign Up
pdflib · PDFlib users
? Already a member? Sign in to Yahoo!

Yahoo! Groups Tips

Did you know...
Show off your group to the world. Share a photo of your group with us.

Best of Y! Groups

   Check them out and nominate your group.
Having problems with message search? Fill out this form to ensure your group is one of the first to be migrated to the new message search system.

Messages

  Messages Help
Advanced
Messages 19963 - 20012 of 20065   Newest  |  < Newer  |  Older >  |  Oldest
Messages: Show Message Summaries   (Group by Topic) Sort by Date v  
#20012 From: "bontjerate" <a.bontjer@...>
Date: Thu Nov 19, 2009 2:54 pm
Subject: Transparency causes color change in print
bontjerate
Offline Offline
Send Email Send Email
 
Hi,

I'm creating a transparent rectangle in my code but some printers messes up this
page with transparency. The page with transparency is darker then the page
without transparency.

On our screens the colors are perfect and when I meassure these colors they all
are the same (cmyk 0, 75, 0, 100).

Is there a way the prevent the colors from changing while printing?

Thanks

Not sure if it's needed but here is my code for generating the transparency:
if($p->pcos_get_string($indoc, "type:pages[".($pageNumber -
1)."]/blocks/pagina1NaamLijsttrekkerBlock") != "null")
{
	 $llx = $p->pcos_get_number($indoc, "pages[".($pageNumber -
1)."]/blocks/pagina1NaamLijsttrekkerBlock/Rect[0]");
	 $lly = $p->pcos_get_number($indoc, "pages[".($pageNumber -
1)."]/blocks/pagina1NaamLijsttrekkerBlock/Rect[1]");
	 $urx = $p->pcos_get_number($indoc, "pages[".($pageNumber -
1)."]/blocks/pagina1NaamLijsttrekkerBlock/Rect[2]");
	 $ury = $p->pcos_get_number($indoc, "pages[".($pageNumber -
1)."]/blocks/pagina1NaamLijsttrekkerBlock/Rect[3]");

	 $p->save();
	 $gstate = $p->create_gstate("opacityfill=.8");
	 $p->set_gstate($gstate);
	 $p->setcolor("fill", "cmyk", 0, 0, 0, 0);
	 $p->rect($llx, $lly, $urx-$llx, $ury-$lly);
	 $p->fill();
	 $p->restore();
}

#20011 From: "kodexe77@..." <per@...>
Date: Wed Nov 18, 2009 1:14 pm
Subject: Re: .NET x64 "Bad image format"
kodexe77...
Offline Offline
Send Email Send Email
 
Thomas Merz <tm@...> wrote:
>
> kodexe77@... wrote:
> >
> > I am using the public PDFLib 8 beta for .NET and Visual
> > Studio 2008 on Windows 7 x64.
> >
> > If I compile against "AnyCPU" or "x64", I get an image
> > loading error at runtime:
> >
> > [...]
>
> We support our products on Windows x64 platforms since a long
> time. The fact is simply that a Windows x64 version of Beta 1
> has not been produced. We will release PDFlib 8 Beta 2 in a
> few days, and will add x64 binaries for your testing.

That's good news. Since the download page for beta 8 didn't mention anything
about x86/x64/AnyCPU for .NET I misunderstood.

Thanks, looking forward to the new beta!

#20010 From: Thomas Merz <tm@...>
Date: Wed Nov 18, 2009 12:03 pm
Subject: Re: .NET x64 "Bad image format"
thomasmerz1
Offline Offline
Send Email Send Email
 
kodexe77@... wrote:
> I am using the public PDFLib 8 beta for .NET and Visual Studio 2008 on Windows
7 x64.
>
> If I compile against "AnyCPU" or "x64", I get an image loading error at
runtime:
>
> Unhandled Exception: System.BadImageFormatException: Could not load file or
assembly 'PDFlib_dotnet, Version=8.0.0.0, Culture=neutral,
PublicKeyToken=af0805f2b25bb299' or one of its dependencies. An attempt was made
to load a program with an incorrect format.
> File name: 'PDFlib_dotnet, Version=8.0.0.0, Culture=neutral,
PublicKeyToken=af0805f2b25bb299'
>
> If I compile against "x86", it works. So my questions now are;
>
> 1. Is this because the .NET DLL is compiled specifically against x86?
>
> 2. Does this mean IIS on Windows x64 will need to run in explicit x86 mode
(which has a performance hit) for PDFLib to work?
>
> (Please note that the Windows Server operating system series is *discontinued*
for x86, so PDFLib should seriously consider upgrading itself to either AnyCPU
or x64.)

We support our products on Windows x64 platforms since a long
time. The fact is simply that a Windows x64 version of Beta 1
has not been produced. We will release PDFlib 8 Beta 2 in a
few days, and will add x64 binaries for your testing.

Thomas

_______________________________________________________________
Thomas Merz             tm@...            www.pdflib.com
    PDFlib GmbH, Franziska-Bilek-Weg 9, 80339 München,  Germany
    Amtsgericht München HRB 129497, Geschäftsführer Thomas Merz
---------------------------------------------------------------
PDFlib 7:  Create PDF/A for archiving, format tables, and more!
_______PDFlib - a library for generating PDF on the fly________

#20009 From: "kodexe77@..." <per@...>
Date: Wed Nov 18, 2009 10:13 am
Subject: .NET x64 "Bad image format"
kodexe77...
Offline Offline
Send Email Send Email
 
Hello,

I am using the public PDFLib 8 beta for .NET and Visual Studio 2008 on Windows 7
x64.

If I compile against "AnyCPU" or "x64", I get an image loading error at runtime:

Unhandled Exception: System.BadImageFormatException: Could not load file or
assembly 'PDFlib_dotnet, Version=8.0.0.0, Culture=neutral,
PublicKeyToken=af0805f2b25bb299' or one of its dependencies. An attempt was made
to load a program with an incorrect format.
File name: 'PDFlib_dotnet, Version=8.0.0.0, Culture=neutral,
PublicKeyToken=af0805f2b25bb299'

If I compile against "x86", it works. So my questions now are;

1. Is this because the .NET DLL is compiled specifically against x86?

2. Does this mean IIS on Windows x64 will need to run in explicit x86 mode
(which has a performance hit) for PDFLib to work?

(Please note that the Windows Server operating system series is *discontinued*
for x86, so PDFLib should seriously consider upgrading itself to either AnyCPU
or x64.)

Best regards from Sweden,

#20008 From: "devkumar13" <devkumar13@...>
Date: Tue Nov 17, 2009 8:08 pm
Subject: Re: Chinese strings
devkumar13
Offline Offline
Send Email Send Email
 
Thanks Kurt. I will test and let you know if I have any questions. Do you have a
simple c++ sample which prints any of these chinese string to pdf. Thant will
help a lot.

Thanks,

Dev


--- In pdflib@yahoogroups.com, Kurt Stützer <kurt@...> wrote:
>
> Hi Dev,
>
> see below!
>
> devkumar13 wrote:
> >
> >
> > Hi Kurt,
> >
> > Thanks for your suggestions. I took the chinese string from
> > http://gb.chinatimes.com/gate/gb/news.chinatimes.com/
> > <http://gb.chinatimes.com/gate/gb/news.chinatimes.com/>
> >
> > And still it shows ??????. In browser it looks good but in PDF it is all
> > ????. Do you think it is related to something else I might be missing. I
> > did the build as Unicode. Here is how the code looks like now. All the
> > strings are taken from china times.
> >
> > std::string str="&#22269;&#23478;&#21457;&#23637;&#25913;&#38761;&#22996;";
> > p.SetFont(font);
>
> What is it?
>
> > int chFont=p.load_font("AdobeSongStd-Light", "GB-EUC-H", "");
>
> As I told you if you supply Unicode text strings you must supply
> a Unicode CMap (see PDFlib Tutorial Manual):
>
> chFont=p.load_font("STSong-Light", "UniGB-UTF16-H", "keepnative=false");
>
> > p.setfont(chFont,12);
> > p.show_xy(str,50,30);
> >
p.show_xy("&#22269;&#23478;&#21457;&#23637;&#25913;&#38761;&#22996;",50,150);
>
> If you set "encoding=UniGB-UTF16-H" PDFlib expects UTF-16 formatted
> strings. But you supply single byte strings with ASCII characters like
> '&', '#' etc. Therefore you must set
>
> p.set_parameter("textformat", "bytes");
>
> Because you are using character references to express Unicode values
> you must enable character references by
>
> p.set_parameter("charref", "true");
>
> in order that PDFlib can substitute Unicode values for the character
> references.
>
> Kurt
>
> >
p.show_xy("&#20013;&#20449;&#37329;&#25511;&#20170;&#22825;&#19982;&#20013;&#315\
74;&#38598;&#22242;",
> > 50, 80);
> >
p.show_xy("&#20013;&#20449;&#37329;&#25511;&#20170;&#22825;&#19982;&#20013;&#315\
74;&#38598;&#22242;",
> > 50, 100);
> >
> > Any ideas?
> >
> > Thanks,
> > Dev
> >
> > --- In pdflib@yahoogroups.com <mailto:pdflib%40yahoogroups.com>, Kurt
> > Stützer <kurt@> wrote:
> >  >
> >  > Hi Dev,
> >  >
> >  > if the desired text is given as Unicode string
> >  > you can use the corresponding Unicode CMap for
> >  > Simplified Chinese and you can supply the Unicode text
> >  > immediately for the text output function:
> >  >
> >  > chFont=p.load_font("STSong-Light", "UniGB-UTF16-H", "keepnative=false");
> >  > p.setfont(chFont,12);
> >  > p.show_xy("\x80\x7B\x53\x4F\x2D\x4E\x87\x65", 20, 30);
> >  >
> >  > where the literal char array is a Unicode string in little endian byte
> >  > ordering. If the char array contains binary zeros you must specify the
> >  > length of the character array:
> >  >
> >  >
> >
p.show_xy(string("\x41\x00\x42\x00\x43\x00\x20\x00\x80\x7B\x53\x4F\x2D\x4E\x87\x\
65",
> >
> >  >
> >  > 16), 20, 30);
> >  >
> >  > But you can work independently on byte ordering if you are using
> >  > unsigned short arrays:
> >  >
> >  > const unsigned short unitext[] =
> >  > {0x0041, 0x0042, 0x0043, 0x0020, 0x7B80, 0x4F53, 0x4E2D, 0x6587};
> >  > p.show_xy(string((const char *)unitext, 16), 20, 30);
> >  >
> >  > Sorry, but I didn't understand the string L"¹ú¼Ò·¢Õ¹¸Ä¸ïί" (Unicode?).
> >  > Therefore I took an own sample text. Please keep in mind that PDFlib
> >  > doesn't support wstring in the C++ language binding.
> >  >
> >  > If the desired text is given as Simplified Chinese string
> >  > according "GB-EUC-H" (or "cp936" resp.) you can supply the text
> >  > immediately as Simplified Chinese string:
> >  >
> >  > int chFont=p.load_font("STSong-Light", "GB-EUC-H", "keepnative=false");
> >  > p.setfont(chFont,12);
> >  > p.show_xy("\x41\x42\x43\x20\xBC\xF2\xCC\xE5\xD6\xD0\xCE\xC4", 20, 30);
> >  >
> >  > where str is the text as Simplified Chinese string which doesn't
> >  > contain any binary zeros. Conversions are not necessary.
> >  >
> >  > Kurt
> >  >
> >  >
> >  > devkumar13 wrote:
> >  > >
> >  > >
> >  > > Hi,
> >  > >
> >  > > I am new to UNICODE and multi-language. I am struggling with creating
> >  > > pdf doc with chinese. Here is a sample code in C++. I am using
> > pdflib 7.0.3.
> >  > >
> >  > > std::wstring wstr=L"¹ú¼Ò·¢Õ¹¸Ä¸ïί";
> >  > > string strTitle;
> >  > >
> >  > > p.SetFont(font);
> >  > > int chFont=p.load_font("STSong-Light", "GB-EUC-H", "keepnative=false");
> >  > > p.setfont(chFont,12);
> >  > > char *szTo = new char[wstr.length() + 1];
> >  > > szTo[wstr.size()] = '\0';
> >  > > WideCharToMultiByte(CP_ACP, 0, wstr.c_str(), -1, szTo,
> >  > > (int)wstr.length(), NULL, NULL);
> >  > > strTitle = szTo;
> >  > > p.show_xy(strTitle,20,30);
> >  > >
> >  > > It shows ????? instead of the chinese string. I will be grateful
> > for all
> >  > > the help in this regard.
> >  > >
> >  > > Thanks,
> >  > > Dev
> >  > >
> >  > >
> >  >
> >  > --
> >  > __________________________________________________________
> >  > Kurt Stützer kurt@ http://www.pdflib.com <http://www.pdflib.com>
> >  > PDFlib GmbH, Franziska-Bilek-Weg 9, 80339 München, Germany
> >  > Amtsgericht München HRB 129497, Geschäftsführer Thomas Merz
> >  > ----------------------------------------------------------
> >  > PDFlib 7: Create PDF/A for archiving, format tables, and more!
> >  > _______PDFlib - a library for generating PDF on the fly________
> >  >
> >
> >
>
> --
> _______________________________________________________________
> Kurt Stützer       kurt@...        http://www.pdflib.com
>     PDFlib GmbH, Franziska-Bilek-Weg 9, 80339 München, Germany
>    Amtsgericht München HRB 129497, Geschäftsführer Thomas Merz
> ---------------------------------------------------------------
> PDFlib 7:  Create PDF/A for archiving, format tables, and more!
> _______PDFlib - a library for generating PDF on the fly________
>

#20007 From: "devkumar13" <devkumar13@...>
Date: Tue Nov 17, 2009 8:08 pm
Subject: Re: Chinese strings
devkumar13
Offline Offline
Send Email Send Email
 
Thanks Kurt. I will test and let you know if I have any questions. Do you have a
simple c++ sample which prints any of these chinese string to pdf. Thant will
help a lot.

Thanks,

Dev


--- In pdflib@yahoogroups.com, Kurt Stützer <kurt@...> wrote:
>
> Hi Dev,
>
> see below!
>
> devkumar13 wrote:
> >
> >
> > Hi Kurt,
> >
> > Thanks for your suggestions. I took the chinese string from
> > http://gb.chinatimes.com/gate/gb/news.chinatimes.com/
> > <http://gb.chinatimes.com/gate/gb/news.chinatimes.com/>
> >
> > And still it shows ??????. In browser it looks good but in PDF it is all
> > ????. Do you think it is related to something else I might be missing. I
> > did the build as Unicode. Here is how the code looks like now. All the
> > strings are taken from china times.
> >
> > std::string str="&#22269;&#23478;&#21457;&#23637;&#25913;&#38761;&#22996;";
> > p.SetFont(font);
>
> What is it?
>
> > int chFont=p.load_font("AdobeSongStd-Light", "GB-EUC-H", "");
>
> As I told you if you supply Unicode text strings you must supply
> a Unicode CMap (see PDFlib Tutorial Manual):
>
> chFont=p.load_font("STSong-Light", "UniGB-UTF16-H", "keepnative=false");
>
> > p.setfont(chFont,12);
> > p.show_xy(str,50,30);
> >
p.show_xy("&#22269;&#23478;&#21457;&#23637;&#25913;&#38761;&#22996;",50,150);
>
> If you set "encoding=UniGB-UTF16-H" PDFlib expects UTF-16 formatted
> strings. But you supply single byte strings with ASCII characters like
> '&', '#' etc. Therefore you must set
>
> p.set_parameter("textformat", "bytes");
>
> Because you are using character references to express Unicode values
> you must enable character references by
>
> p.set_parameter("charref", "true");
>
> in order that PDFlib can substitute Unicode values for the character
> references.
>
> Kurt
>
> >
p.show_xy("&#20013;&#20449;&#37329;&#25511;&#20170;&#22825;&#19982;&#20013;&#315\
74;&#38598;&#22242;",
> > 50, 80);
> >
p.show_xy("&#20013;&#20449;&#37329;&#25511;&#20170;&#22825;&#19982;&#20013;&#315\
74;&#38598;&#22242;",
> > 50, 100);
> >
> > Any ideas?
> >
> > Thanks,
> > Dev
> >
> > --- In pdflib@yahoogroups.com <mailto:pdflib%40yahoogroups.com>, Kurt
> > Stützer <kurt@> wrote:
> >  >
> >  > Hi Dev,
> >  >
> >  > if the desired text is given as Unicode string
> >  > you can use the corresponding Unicode CMap for
> >  > Simplified Chinese and you can supply the Unicode text
> >  > immediately for the text output function:
> >  >
> >  > chFont=p.load_font("STSong-Light", "UniGB-UTF16-H", "keepnative=false");
> >  > p.setfont(chFont,12);
> >  > p.show_xy("\x80\x7B\x53\x4F\x2D\x4E\x87\x65", 20, 30);
> >  >
> >  > where the literal char array is a Unicode string in little endian byte
> >  > ordering. If the char array contains binary zeros you must specify the
> >  > length of the character array:
> >  >
> >  >
> >
p.show_xy(string("\x41\x00\x42\x00\x43\x00\x20\x00\x80\x7B\x53\x4F\x2D\x4E\x87\x\
65",
> >
> >  >
> >  > 16), 20, 30);
> >  >
> >  > But you can work independently on byte ordering if you are using
> >  > unsigned short arrays:
> >  >
> >  > const unsigned short unitext[] =
> >  > {0x0041, 0x0042, 0x0043, 0x0020, 0x7B80, 0x4F53, 0x4E2D, 0x6587};
> >  > p.show_xy(string((const char *)unitext, 16), 20, 30);
> >  >
> >  > Sorry, but I didn't understand the string L"¹ú¼Ò·¢Õ¹¸Ä¸ïί" (Unicode?).
> >  > Therefore I took an own sample text. Please keep in mind that PDFlib
> >  > doesn't support wstring in the C++ language binding.
> >  >
> >  > If the desired text is given as Simplified Chinese string
> >  > according "GB-EUC-H" (or "cp936" resp.) you can supply the text
> >  > immediately as Simplified Chinese string:
> >  >
> >  > int chFont=p.load_font("STSong-Light", "GB-EUC-H", "keepnative=false");
> >  > p.setfont(chFont,12);
> >  > p.show_xy("\x41\x42\x43\x20\xBC\xF2\xCC\xE5\xD6\xD0\xCE\xC4", 20, 30);
> >  >
> >  > where str is the text as Simplified Chinese string which doesn't
> >  > contain any binary zeros. Conversions are not necessary.
> >  >
> >  > Kurt
> >  >
> >  >
> >  > devkumar13 wrote:
> >  > >
> >  > >
> >  > > Hi,
> >  > >
> >  > > I am new to UNICODE and multi-language. I am struggling with creating
> >  > > pdf doc with chinese. Here is a sample code in C++. I am using
> > pdflib 7.0.3.
> >  > >
> >  > > std::wstring wstr=L"¹ú¼Ò·¢Õ¹¸Ä¸ïί";
> >  > > string strTitle;
> >  > >
> >  > > p.SetFont(font);
> >  > > int chFont=p.load_font("STSong-Light", "GB-EUC-H", "keepnative=false");
> >  > > p.setfont(chFont,12);
> >  > > char *szTo = new char[wstr.length() + 1];
> >  > > szTo[wstr.size()] = '\0';
> >  > > WideCharToMultiByte(CP_ACP, 0, wstr.c_str(), -1, szTo,
> >  > > (int)wstr.length(), NULL, NULL);
> >  > > strTitle = szTo;
> >  > > p.show_xy(strTitle,20,30);
> >  > >
> >  > > It shows ????? instead of the chinese string. I will be grateful
> > for all
> >  > > the help in this regard.
> >  > >
> >  > > Thanks,
> >  > > Dev
> >  > >
> >  > >
> >  >
> >  > --
> >  > __________________________________________________________
> >  > Kurt Stützer kurt@ http://www.pdflib.com <http://www.pdflib.com>
> >  > PDFlib GmbH, Franziska-Bilek-Weg 9, 80339 München, Germany
> >  > Amtsgericht München HRB 129497, Geschäftsführer Thomas Merz
> >  > ----------------------------------------------------------
> >  > PDFlib 7: Create PDF/A for archiving, format tables, and more!
> >  > _______PDFlib - a library for generating PDF on the fly________
> >  >
> >
> >
>
> --
> _______________________________________________________________
> Kurt Stützer       kurt@...        http://www.pdflib.com
>     PDFlib GmbH, Franziska-Bilek-Weg 9, 80339 München, Germany
>    Amtsgericht München HRB 129497, Geschäftsführer Thomas Merz
> ---------------------------------------------------------------
> PDFlib 7:  Create PDF/A for archiving, format tables, and more!
> _______PDFlib - a library for generating PDF on the fly________
>

#20006 From: Kurt Stützer <kurt@...>
Date: Tue Nov 17, 2009 4:12 pm
Subject: Re: Re: Chinese strings
kurt@...
Send Email Send Email
 
Hi Dev,

see below!

devkumar13 wrote:
>
>
> Hi Kurt,
>
> Thanks for your suggestions. I took the chinese string from
> http://gb.chinatimes.com/gate/gb/news.chinatimes.com/
> <http://gb.chinatimes.com/gate/gb/news.chinatimes.com/>
>
> And still it shows ??????. In browser it looks good but in PDF it is all
> ????. Do you think it is related to something else I might be missing. I
> did the build as Unicode. Here is how the code looks like now. All the
> strings are taken from china times.
>
> std::string str="&#22269;&#23478;&#21457;&#23637;&#25913;&#38761;&#22996;";
> p.SetFont(font);

What is it?

> int chFont=p.load_font("AdobeSongStd-Light", "GB-EUC-H", "");

As I told you if you supply Unicode text strings you must supply
a Unicode CMap (see PDFlib Tutorial Manual):

chFont=p.load_font("STSong-Light", "UniGB-UTF16-H", "keepnative=false");

> p.setfont(chFont,12);
> p.show_xy(str,50,30);
> p.show_xy("&#22269;&#23478;&#21457;&#23637;&#25913;&#38761;&#22996;",50,150);

If you set "encoding=UniGB-UTF16-H" PDFlib expects UTF-16 formatted
strings. But you supply single byte strings with ASCII characters like
'&', '#' etc. Therefore you must set

p.set_parameter("textformat", "bytes");

Because you are using character references to express Unicode values
you must enable character references by

p.set_parameter("charref", "true");

in order that PDFlib can substitute Unicode values for the character
references.

Kurt

>
p.show_xy("&#20013;&#20449;&#37329;&#25511;&#20170;&#22825;&#19982;&#20013;&#315\
74;&#38598;&#22242;",
> 50, 80);
>
p.show_xy("&#20013;&#20449;&#37329;&#25511;&#20170;&#22825;&#19982;&#20013;&#315\
74;&#38598;&#22242;",
> 50, 100);
>
> Any ideas?
>
> Thanks,
> Dev
>
> --- In pdflib@yahoogroups.com <mailto:pdflib%40yahoogroups.com>, Kurt
> Stützer <kurt@...> wrote:
>  >
>  > Hi Dev,
>  >
>  > if the desired text is given as Unicode string
>  > you can use the corresponding Unicode CMap for
>  > Simplified Chinese and you can supply the Unicode text
>  > immediately for the text output function:
>  >
>  > chFont=p.load_font("STSong-Light", "UniGB-UTF16-H", "keepnative=false");
>  > p.setfont(chFont,12);
>  > p.show_xy("\x80\x7B\x53\x4F\x2D\x4E\x87\x65", 20, 30);
>  >
>  > where the literal char array is a Unicode string in little endian byte
>  > ordering. If the char array contains binary zeros you must specify the
>  > length of the character array:
>  >
>  >
>
p.show_xy(string("\x41\x00\x42\x00\x43\x00\x20\x00\x80\x7B\x53\x4F\x2D\x4E\x87\x\
65",
>
>  >
>  > 16), 20, 30);
>  >
>  > But you can work independently on byte ordering if you are using
>  > unsigned short arrays:
>  >
>  > const unsigned short unitext[] =
>  > {0x0041, 0x0042, 0x0043, 0x0020, 0x7B80, 0x4F53, 0x4E2D, 0x6587};
>  > p.show_xy(string((const char *)unitext, 16), 20, 30);
>  >
>  > Sorry, but I didn't understand the string L"¹ú¼Ò·¢Õ¹¸Ä¸ïί" (Unicode?).
>  > Therefore I took an own sample text. Please keep in mind that PDFlib
>  > doesn't support wstring in the C++ language binding.
>  >
>  > If the desired text is given as Simplified Chinese string
>  > according "GB-EUC-H" (or "cp936" resp.) you can supply the text
>  > immediately as Simplified Chinese string:
>  >
>  > int chFont=p.load_font("STSong-Light", "GB-EUC-H", "keepnative=false");
>  > p.setfont(chFont,12);
>  > p.show_xy("\x41\x42\x43\x20\xBC\xF2\xCC\xE5\xD6\xD0\xCE\xC4", 20, 30);
>  >
>  > where str is the text as Simplified Chinese string which doesn't
>  > contain any binary zeros. Conversions are not necessary.
>  >
>  > Kurt
>  >
>  >
>  > devkumar13 wrote:
>  > >
>  > >
>  > > Hi,
>  > >
>  > > I am new to UNICODE and multi-language. I am struggling with creating
>  > > pdf doc with chinese. Here is a sample code in C++. I am using
> pdflib 7.0.3.
>  > >
>  > > std::wstring wstr=L"¹ú¼Ò·¢Õ¹¸Ä¸ïί";
>  > > string strTitle;
>  > >
>  > > p.SetFont(font);
>  > > int chFont=p.load_font("STSong-Light", "GB-EUC-H", "keepnative=false");
>  > > p.setfont(chFont,12);
>  > > char *szTo = new char[wstr.length() + 1];
>  > > szTo[wstr.size()] = '\0';
>  > > WideCharToMultiByte(CP_ACP, 0, wstr.c_str(), -1, szTo,
>  > > (int)wstr.length(), NULL, NULL);
>  > > strTitle = szTo;
>  > > p.show_xy(strTitle,20,30);
>  > >
>  > > It shows ????? instead of the chinese string. I will be grateful
> for all
>  > > the help in this regard.
>  > >
>  > > Thanks,
>  > > Dev
>  > >
>  > >
>  >
>  > --
>  > __________________________________________________________
>  > Kurt Stützer kurt@... http://www.pdflib.com <http://www.pdflib.com>
>  > PDFlib GmbH, Franziska-Bilek-Weg 9, 80339 München, Germany
>  > Amtsgericht München HRB 129497, Geschäftsführer Thomas Merz
>  > ----------------------------------------------------------
>  > PDFlib 7: Create PDF/A for archiving, format tables, and more!
>  > _______PDFlib - a library for generating PDF on the fly________
>  >
>
>

--
_______________________________________________________________
Kurt Stützer       kurt@...        http://www.pdflib.com
     PDFlib GmbH, Franziska-Bilek-Weg 9, 80339 München, Germany
    Amtsgericht München HRB 129497, Geschäftsführer Thomas Merz
---------------------------------------------------------------
PDFlib 7:  Create PDF/A for archiving, format tables, and more!
_______PDFlib - a library for generating PDF on the fly________

#20005 From: "devkumar13" <devkumar13@...>
Date: Tue Nov 17, 2009 2:41 pm
Subject: Re: Chinese strings
devkumar13
Offline Offline
Send Email Send Email
 
Hi Kurt,

Thanks for your suggestions. I took the chinese string from
http://gb.chinatimes.com/gate/gb/news.chinatimes.com/

And still it shows ??????. In browser it looks good but in PDF it is all ????.
Do you think it is related to something else I might be missing. I did the build
as Unicode. Here is how the code looks like now. All the strings are taken from
china times.

	 std::string str="&#22269;&#23478;&#21457;&#23637;&#25913;&#38761;&#22996;";
	 p.SetFont(font);
	 int chFont=p.load_font("AdobeSongStd-Light", "GB-EUC-H", "");
	 p.setfont(chFont,12);
  	 p.show_xy(str,50,30);
	 p.show_xy("&#22269;&#23478;&#21457;&#23637;&#25913;&#38761;&#22996;",50,150);
	
p.show_xy("&#20013;&#20449;&#37329;&#25511;&#20170;&#22825;&#19982;&#20013;&#315\
74;&#38598;&#22242;", 50, 80);
	
p.show_xy("&#20013;&#20449;&#37329;&#25511;&#20170;&#22825;&#19982;&#20013;&#315\
74;&#38598;&#22242;", 50, 100);


Any ideas?

Thanks,
Dev

--- In pdflib@yahoogroups.com, Kurt Stützer <kurt@...> wrote:
>
> Hi Dev,
>
> if the desired text is given as Unicode string
> you can use the corresponding Unicode CMap for
> Simplified Chinese and you can supply the Unicode text
> immediately for the text output function:
>
> chFont=p.load_font("STSong-Light", "UniGB-UTF16-H", "keepnative=false");
> p.setfont(chFont,12);
> p.show_xy("\x80\x7B\x53\x4F\x2D\x4E\x87\x65", 20, 30);
>
> where the literal char array is a Unicode string in little endian byte
> ordering. If the char array contains binary zeros you must specify the
> length of the character array:
>
>
p.show_xy(string("\x41\x00\x42\x00\x43\x00\x20\x00\x80\x7B\x53\x4F\x2D\x4E\x87\x\
65",
>
>                   16), 20, 30);
>
> But you can work independently on byte ordering if you are using
> unsigned short arrays:
>
> const unsigned short unitext[] =
>      {0x0041, 0x0042, 0x0043, 0x0020, 0x7B80, 0x4F53, 0x4E2D, 0x6587};
> p.show_xy(string((const char *)unitext, 16), 20, 30);
>
> Sorry, but I didn't understand the string L"¹ú¼Ò·¢Õ¹¸Ä¸ïί" (Unicode?).
> Therefore I took an own sample text. Please keep in mind that PDFlib
> doesn't support wstring in the C++ language binding.
>
> If the desired text is given as Simplified Chinese string
> according "GB-EUC-H" (or "cp936" resp.) you can supply the text
> immediately as Simplified Chinese string:
>
> int chFont=p.load_font("STSong-Light", "GB-EUC-H", "keepnative=false");
> p.setfont(chFont,12);
> p.show_xy("\x41\x42\x43\x20\xBC\xF2\xCC\xE5\xD6\xD0\xCE\xC4", 20, 30);
>
> where str is the text as Simplified Chinese string which doesn't
> contain any binary zeros. Conversions are not necessary.
>
> Kurt
>
>
> devkumar13 wrote:
> >
> >
> > Hi,
> >
> > I am new to UNICODE and multi-language. I am struggling with creating
> > pdf doc with chinese. Here is a sample code in C++. I am using pdflib 7.0.3.
> >
> > std::wstring wstr=L"¹ú¼Ò·¢Õ¹¸Ä¸ïί";
> > string strTitle;
> >
> > p.SetFont(font);
> > int chFont=p.load_font("STSong-Light", "GB-EUC-H", "keepnative=false");
> > p.setfont(chFont,12);
> > char *szTo = new char[wstr.length() + 1];
> > szTo[wstr.size()] = '\0';
> > WideCharToMultiByte(CP_ACP, 0, wstr.c_str(), -1, szTo,
> > (int)wstr.length(), NULL, NULL);
> > strTitle = szTo;
> > p.show_xy(strTitle,20,30);
> >
> > It shows ????? instead of the chinese string. I will be grateful for all
> > the help in this regard.
> >
> > Thanks,
> > Dev
> >
> >
>
> --
> _______________________________________________________________
> Kurt Stützer       kurt@...        http://www.pdflib.com
>     PDFlib GmbH, Franziska-Bilek-Weg 9, 80339 München, Germany
>    Amtsgericht München HRB 129497, Geschäftsführer Thomas Merz
> ---------------------------------------------------------------
> PDFlib 7:  Create PDF/A for archiving, format tables, and more!
> _______PDFlib - a library for generating PDF on the fly________
>

#20004 From: Kurt Stützer <kurt@...>
Date: Tue Nov 17, 2009 9:51 am
Subject: Re: Chinese strings
kurt@...
Send Email Send Email
 
Kurt Stützer wrote:

> .... Please keep in mind that PDFlib
> doesn't support wstring in the C++ language binding.
>

I must rectify:  PDFlib 7.0 doesn't support wstring in the C++ language
binding. But PDFlib 8.0, the new major release for which a beta version
is available, supports wide character strings in the C++ language binding.

Kurt

_______________________________________________________________
Kurt Stützer       kurt@...        http://www.pdflib.com
     PDFlib GmbH, Franziska-Bilek-Weg 9, 80339 München, Germany
    Amtsgericht München HRB 129497, Geschäftsführer Thomas Merz
---------------------------------------------------------------
PDFlib 7:  Create PDF/A for archiving, format tables, and more!
_______PDFlib - a library for generating PDF on the fly________

#19991 From: "mulveyraa2" <lists@...>
Date: Mon Nov 16, 2009 10:02 pm
Subject: Re: 6.0.2 to 7.0.4 migration (shrinklimit)
mulveyraa2
Offline Offline
Send Email Send Email
 
I had exactly this same problem, though IIRC, I was going from 7.01 to 7.03. 
Suddenly, there was no text shrinking occuring.

I added the "alignment=justify" option, and all was well.

--- In pdflib@yahoogroups.com, tolga ceylan <tolgaceylanus@...> wrote:
>
>  
> Please understand that I'm trying to minimize the amount of code changes
> required for this migration. We have thousands of lines of code that
> produced different output before 7.0.4 using 6.0.2.
>  
> As an example to clarify, the text "date reported" (in 6.0.2) used to span 1
line for the
> given space. This was achieved by 'alignment=center' and the default
> line break algorithm ("auto" but using "nofitlimit=15"). The words used to be
shrunk in this example.
>  
> Now, with 7.0.4, the same text is spanning 2 lines since the words are no
longer
> being shrunk.
>  
> Do you have any recommendations? Do I need to go through the code and modify
the
> code to use 'alignment=justify'?
>
> --- On Wed, 11/4/09, tolga ceylan <tolgaceylanus@...> wrote:
>
>
> From: tolga ceylan <tolgaceylanus@...>
> Subject: Re: [pdflib] 6.0.2 to 7.0.4 migration (shrinklimit)
> To: pdflib@yahoogroups.com
> Date: Wednesday, November 4, 2009, 11:48 AM
>
>
>  
>
>
>
>
>
>
>
>
> Thanks Kurt, is this a change that was introduced after release 6.0.2?
>
> With 6.0.2, using alignment=center, the text used to fit 1 line. Now, it is
> getting a line break and spanning 2 lines.
>
> Do I need to make code changes and make 'alignment=justify' to fix the
> issue?
>
> --- On Wed, 11/4/09, Kurt Stützer <kurt@pdflib. com> wrote:
>
>
> From: Kurt Stützer <kurt@pdflib. com>
> Subject: Re: [pdflib] 6.0.2 to 7.0.4 migration (shrinklimit)
> To: pdflib@yahoogroups. com
> Date: Wednesday, November 4, 2009, 5:34 AM
>
>
>  
>
> Hi,
>
> the options nofitlimit and shrinklimit you mentioned have only an effect
> if you set alignment=justify. Please show us what you want to achieve
> with which text.
>
> Kurt
>
> tolgaceylanus wrote:
> >
> >
> >
> > Hello;
> >
> > Are there any open issues regarding 'shrinklimit' ?
> >
> > In 6.0.2, I was using;
> >
> > fontname=Helvetica fontsize=8 glyphwarning= false encoding=iso8859- 1
> > alignment=center nofitlimit=15
> >
> > for create_textflow. This used to shrink the text properly and make it
> > fit into the specified space.
> >
> > Now, in 7.0.4, the text doesn't seem to be shrinking at all. I've tried
> > various shrinklimit values (10,50,90, etc.) and it doesn't seem to
> > take any effect.
> >
> > Can you please help?
> >
> > Regards,
> >
> > Tolga Ceylan
> >
> >
>
> --
> ____________ _________ _________ _________ _________ _________ _
> Kurt Stützer kurt@pdflib. com http://www.pdflib. com
> PDFlib GmbH, Franziska-Bilek- Weg 9, 80339 München, Germany
> Amtsgericht München HRB 129497, Geschäftsführer Thomas Merz
> ------------ --------- --------- --------- --------- --------- -
> PDFlib 7: Create PDF/A for archiving, format tables, and more!
> _______PDFlib - a library for generating PDF on the fly________
>

#19990 From: Kurt Stützer <kurt@...>
Date: Mon Nov 16, 2009 9:27 pm
Subject: Re: Chinese strings
kurt@...
Send Email Send Email
 
Hi Dev,

if the desired text is given as Unicode string
you can use the corresponding Unicode CMap for
Simplified Chinese and you can supply the Unicode text
immediately for the text output function:

chFont=p.load_font("STSong-Light", "UniGB-UTF16-H", "keepnative=false");
p.setfont(chFont,12);
p.show_xy("\x80\x7B\x53\x4F\x2D\x4E\x87\x65", 20, 30);

where the literal char array is a Unicode string in little endian byte
ordering. If the char array contains binary zeros you must specify the
length of the character array:

p.show_xy(string("\x41\x00\x42\x00\x43\x00\x20\x00\x80\x7B\x53\x4F\x2D\x4E\x87\x\
65",

                   16), 20, 30);

But you can work independently on byte ordering if you are using
unsigned short arrays:

const unsigned short unitext[] =
      {0x0041, 0x0042, 0x0043, 0x0020, 0x7B80, 0x4F53, 0x4E2D, 0x6587};
p.show_xy(string((const char *)unitext, 16), 20, 30);

Sorry, but I didn't understand the string L"¹ú¼Ò·¢Õ¹¸Ä¸ïί" (Unicode?).
Therefore I took an own sample text. Please keep in mind that PDFlib
doesn't support wstring in the C++ language binding.

If the desired text is given as Simplified Chinese string
according "GB-EUC-H" (or "cp936" resp.) you can supply the text
immediately as Simplified Chinese string:

int chFont=p.load_font("STSong-Light", "GB-EUC-H", "keepnative=false");
p.setfont(chFont,12);
p.show_xy("\x41\x42\x43\x20\xBC\xF2\xCC\xE5\xD6\xD0\xCE\xC4", 20, 30);

where str is the text as Simplified Chinese string which doesn't
contain any binary zeros. Conversions are not necessary.

Kurt


devkumar13 wrote:
>
>
> Hi,
>
> I am new to UNICODE and multi-language. I am struggling with creating
> pdf doc with chinese. Here is a sample code in C++. I am using pdflib 7.0.3.
>
> std::wstring wstr=L"¹ú¼Ò·¢Õ¹¸Ä¸ïί";
> string strTitle;
>
> p.SetFont(font);
> int chFont=p.load_font("STSong-Light", "GB-EUC-H", "keepnative=false");
> p.setfont(chFont,12);
> char *szTo = new char[wstr.length() + 1];
> szTo[wstr.size()] = '\0';
> WideCharToMultiByte(CP_ACP, 0, wstr.c_str(), -1, szTo,
> (int)wstr.length(), NULL, NULL);
> strTitle = szTo;
> p.show_xy(strTitle,20,30);
>
> It shows ????? instead of the chinese string. I will be grateful for all
> the help in this regard.
>
> Thanks,
> Dev
>
>

--
_______________________________________________________________
Kurt Stützer       kurt@...        http://www.pdflib.com
     PDFlib GmbH, Franziska-Bilek-Weg 9, 80339 München, Germany
    Amtsgericht München HRB 129497, Geschäftsführer Thomas Merz
---------------------------------------------------------------
PDFlib 7:  Create PDF/A for archiving, format tables, and more!
_______PDFlib - a library for generating PDF on the fly________

#19982 From: "bontjerate" <a.bontjer@...>
Date: Mon Nov 16, 2009 7:36 pm
Subject: Re: Chinese strings
bontjerate
Offline Offline
Send Email Send Email
 
I'm doing this in PHP but some fonts needs autocidfont=false and
unicodemap=false

$p = new PDFlib();

$p->set_parameter("errorpolicy", "return");
$p->set_parameter("textformat", "utf8");
$p->set_parameter("license", $config->pdflib['license']);

//... bunch of code

$p->load_font($config->pdf['fonts']."/SUNSC-BO", "winansi", "embedding");

//... bunch of code

$optlist = "fontname=".$config->pdf['fonts']."/SUNSC-BO "
		  ."fontsize=".$formaat->lijstnummerFontSize." "
		  ."fitmethod=nofit "
		  ."encoding=unicode "
		  ."alignment=right "
		  ."fillcolor={cmyk 0 0 0 0} "
		  ."textflow=true "
		  ."textrendering=2 "
		  ."strokecolor={cmyk 0.75 0 1 0} "
		  ."strokewidth=".$formaat->lijstnummerStrokeSize." "
		  ."firstlinedist=capheight "
		  ."verticalalign=top "
		  ."embedding=true "
		  ."fitmethod=clip "
		  //."autocidfont=false "
		  //."unicodemap=false "
		  ."";
$p->fill_textblock($page, "lijstnummer", $this->lijstnummer, $optlist);

Or is there a better method?

--- In pdflib@yahoogroups.com, "devkumar13" <devkumar13@...> wrote:
>
> Hi,
>
> I am new to UNICODE and multi-language. I am struggling with creating pdf doc
with chinese. Here is a sample code in C++. I am using pdflib 7.0.3.
>
> std::wstring wstr=L"¹ú¼Ò·¢Õ¹¸Ä¸ïί";
> string strTitle;
>
> p.SetFont(font);
> int chFont=p.load_font("STSong-Light", "GB-EUC-H", "keepnative=false");
> p.setfont(chFont,12);
> char *szTo = new char[wstr.length() + 1];
> szTo[wstr.size()] = '\0';
> WideCharToMultiByte(CP_ACP, 0, wstr.c_str(), -1, szTo, (int)wstr.length(),
NULL, NULL);
> strTitle = szTo;
> p.show_xy(strTitle,20,30);
>
> It shows ????? instead of the chinese string. I will be grateful for all the
help in  this regard.
>
> Thanks,
> Dev
>

#19981 From: "! Its Honey" <cnida66@...>
Date: Mon Nov 16, 2009 7:30 pm
Subject: Beautiful voluptous Misri aunty self made exposure video exclusive
cnida66
Offline Offline
Send Email Send Email
 

Beautiful voluptous Misri aunty self made exposure video exclusive!
Another hot fan of fsiblog self made video. This hot misri beauty is making a self made clip of her exposed beautiful skin trying the best to get her best shot! Nude content!

File Name : htmisrismv.wmv
Video Format : .wmv
File Size : 3.3 MB Approx


Click here to Download the Video Clip

If you wana more Videos you must click "Message in this Topic" at bottom of this Email.
After open new page you click any of Image show there.






#19979 From: "devkumar13" <devkumar13@...>
Date: Mon Nov 16, 2009 4:39 pm
Subject: Chinese strings
devkumar13
Offline Offline
Send Email Send Email
 
Hi,

I am new to UNICODE and multi-language. I am struggling with creating pdf doc
with chinese. Here is a sample code in C++. I am using pdflib 7.0.3.

std::wstring wstr=L"¹ú¼Ò·¢Õ¹¸Ä¸ïί";
string strTitle;

p.SetFont(font);
int chFont=p.load_font("STSong-Light", "GB-EUC-H", "keepnative=false");
p.setfont(chFont,12);
char *szTo = new char[wstr.length() + 1];
szTo[wstr.size()] = '\0';
WideCharToMultiByte(CP_ACP, 0, wstr.c_str(), -1, szTo, (int)wstr.length(), NULL,
NULL);
strTitle = szTo;
p.show_xy(strTitle,20,30);

It shows ????? instead of the chinese string. I will be grateful for all the
help in  this regard.

Thanks,
Dev

#19978 From: "bontjerate" <a.bontjer@...>
Date: Mon Nov 16, 2009 1:26 pm
Subject: Re: Resize or resample 300dpi image?
bontjerate
Offline Offline
Send Email Send Email
 
Can anyone please help me with this problem? I can't find the right solution...

I want to resize the image prior to adding it to the PDF file. The image must be
resized to the size (width) of the imageblock.

I'm using imagemagick.

--- In pdflib@yahoogroups.com, "bontjerate" <a.bontjer@...> wrote:
>
> Wait! I want to reduce the print size, suited for the image block in the A5
file:
> > - With these dimensions I want to resize the image. But should I resample,
keeping the print size the same (most plausible), or resize, reducing the print
size. (the goal is keeping the resolution of the image (300dpi) but reduce the
image size).
> So, keeping the print size, isn't the needed result.
>
> In result, the question becomes:
> - With these dimensions I want to resize the image but keep the resolution at
300dpi. But should I resample, keeping the print size the same, or resize,
reducing the print size (most plausible).
>
> --- In pdflib@yahoogroups.com, "bontjerate" <a.bontjer@> wrote:
> >
> > Hi,
> >
> > Maybe not the right place to ask but since al the DTP experts present here I
might get the right answer.
> >
> > I have a 300dpi tiff image suited for a A0 size billboard but the same image
can be used for a A5 sized flyer. To prevent a bloated PDF for the A5 sized
flyer I want to resize the image prior to embedding the image in the PDF.
> >
> > But I have a few questions:
> > - In what units are image block dimensions measured?
> > - With these dimensions I want to resize the image. But should I resample,
keeping the print size the same (most plausible), or resize, reducing the print
size. (the goal is keeping the resolution of the image (300dpi) but reduce the
image size).
> > - Is this the right way to go?
> >
> > Thanks!
> >
>

#19977 From: "bontjerate" <a.bontjer@...>
Date: Sun Nov 15, 2009 7:50 pm
Subject: Re: Resize or resample 300dpi image?
bontjerate
Offline Offline
Send Email Send Email
 
Wait! I want to reduce the print size, suited for the image block in the A5
file:
> - With these dimensions I want to resize the image. But should I resample,
keeping the print size the same (most plausible), or resize, reducing the print
size. (the goal is keeping the resolution of the image (300dpi) but reduce the
image size).
So, keeping the print size, isn't the needed result.

In result, the question becomes:
- With these dimensions I want to resize the image but keep the resolution at
300dpi. But should I resample, keeping the print size the same, or resize,
reducing the print size (most plausible).

--- In pdflib@yahoogroups.com, "bontjerate" <a.bontjer@...> wrote:
>
> Hi,
>
> Maybe not the right place to ask but since al the DTP experts present here I
might get the right answer.
>
> I have a 300dpi tiff image suited for a A0 size billboard but the same image
can be used for a A5 sized flyer. To prevent a bloated PDF for the A5 sized
flyer I want to resize the image prior to embedding the image in the PDF.
>
> But I have a few questions:
> - In what units are image block dimensions measured?
> - With these dimensions I want to resize the image. But should I resample,
keeping the print size the same (most plausible), or resize, reducing the print
size. (the goal is keeping the resolution of the image (300dpi) but reduce the
image size).
> - Is this the right way to go?
>
> Thanks!
>

#19976 From: "bontjerate" <a.bontjer@...>
Date: Sun Nov 15, 2009 7:33 pm
Subject: Resize or resample 300dpi image?
bontjerate
Offline Offline
Send Email Send Email
 
Hi,

Maybe not the right place to ask but since al the DTP experts present here I
might get the right answer.

I have a 300dpi tiff image suited for a A0 size billboard but the same image can
be used for a A5 sized flyer. To prevent a bloated PDF for the A5 sized flyer I
want to resize the image prior to embedding the image in the PDF.

But I have a few questions:
- In what units are image block dimensions measured?
- With these dimensions I want to resize the image. But should I resample,
keeping the print size the same (most plausible), or resize, reducing the print
size. (the goal is keeping the resolution of the image (300dpi) but reduce the
image size).
- Is this the right way to go?

Thanks!

#19975 From: Thomas Merz <tm@...>
Date: Fri Nov 13, 2009 9:00 pm
Subject: Re: PDFlib+PDI and Digital Signatures
thomasmerz1
Offline Offline
Send Email Send Email
 
sigchld wrote:
> Currently we're using PDFlib+PDI (Perl API on UNIX) to open submitted
> PDF files and apply a text overlay to the first page (similar to a
> watermark) and write out the data to a new PDF document.  It's been
> working like a champ for several years.  However, we've hit a snag with
> the current system; any time a user submits a PDF with a digital
> signature, the signature is missing from the output PDF.  The rest of
> the data appears to be fine in the output document, just the signature
> and associated elements are missing.  Are there extra steps I need to do
> to copy the signature to the new document?  (I realize that the text
> overlay will partially invalidate the signature)

First of all, PDI imports only the actual page contents, but not
any other elements such as signatures. Secondly, if you modify
the document, the signature will be invalidated - that's the
very purpose of signatures.

Thomas

_______________________________________________________________
Thomas Merz             tm@...            www.pdflib.com
    PDFlib GmbH, Franziska-Bilek-Weg 9, 80339 München,  Germany
    Amtsgericht München HRB 129497, Geschäftsführer Thomas Merz
---------------------------------------------------------------
PDFlib 7:  Create PDF/A for archiving, format tables, and more!
_______PDFlib - a library for generating PDF on the fly________

#19974 From: "sigchld" <dave.pfister@...>
Date: Fri Nov 13, 2009 7:56 pm
Subject: PDFlib+PDI and Digital Signatures
sigchld
Offline Offline
Send Email Send Email
 
Hi all,

Currently we're using PDFlib+PDI (Perl API on UNIX) to open submitted PDF files and apply a text overlay to the first page (similar to a watermark) and write out the data to a new PDF document.  It's been working like a champ for several years.  However, we've hit a snag with the current system; any time a user submits a PDF with a digital signature, the signature is missing from the output PDF.  The rest of the data appears to be fine in the output document, just the signature and associated elements are missing.  Are there extra steps I need to do to copy the signature to the new document?  (I realize that the text overlay will partially invalidate the signature)

Thanks,

Dave

#19973 From: Kurt Stützer <kurt@...>
Date: Wed Nov 11, 2009 1:14 pm
Subject: Re: Re: UTF-8 problems
kurt@...
Send Email Send Email
 
Hi,

if you enable the logging (see Reference manual, section 2.7)
you can see the text which enters in the text output function.

If the text is an invalid UTF-8 string an error message will occur.

You can check the validity of a UTF-8 text by
PDF_info_textline($p, text, "wellformed", optlist):

Kurt

bontjerate wrote:
>
>
> Hi,
>
> The data is pulled straight from a $_POST var. Is there a way to check
> if a string is UTF-8 or not?
>
> If I echo $this->pagina4Tekstblok2Tekst to the screen it does show the
> één instead of the strange e'e'n.
>
> Any idea?
>
> --- In pdflib@yahoogroups.com <mailto:pdflib%40yahoogroups.com>, guy@...
> wrote:
>  >
>  > Are you sure $this->pagina4Tekstblok2Tekst is emitting utf-8 encoded
> text?
>  >
>  > I've had trouble before where the problem was the database handle used
>  > to get the data from the db was stomping on the encoding. Perhaps
>  > that's what's happening to you too...?
>  >
>  > Guy
>  >
>  > Quoting bontjerate <a.bontjer@...>:
>  >
>  > > Hi,
>  > >
>  > > When I submit a utf-8 text to a php file, I don't get the expected
> result.
>  > >
>  > > This text:
>  > > Wij vinden een goed ondernemersklimaat belangrijk. Daarom moet er
>  > > één loket bij de gemeente komen. Wij vinden een goed
>  > > ondernemersklimaat belangrijk.
>  > >
>  > > Becomes this:
>  > > Wij vinden een goed ondernemersklimaat belangrijk. Daarom moet er
>  > > e'e'n loket bij de gemeente komen. Wij vinden een goed
>  > > ondernemersklimaat belangrijk.
>  > >
>  > > I initialize pdflib with:
>  > >
>  > > $p->set_parameter("textformat", "utf8");
>  > >
>  > > This is the text block:
>  > > $optlist = "fontname=".$config->pdf['fonts']."/SUN-REGU "
>  > > ."fontsize=9.5 "
>  > > ."encoding=unicode "
>  > > ."alignment=left "
>  > > ."firstlinedist=xheight "
>  > > ."verticalalign=center "
>  > > ."fillcolor={cmyk 0 0 0 1} "
>  > > ."textflow=true ";
>  > > $p->fill_textblock($page, "pagina4Tekstblok2Tekst",
>  > > $this->pagina4Tekstblok2Tekst, $optlist);
>  > >
>  > > I tried adding textformat=utf8 tho the optlist but that didn't help.
>  > >
>  > > What am I missing or what am I doing wrong?
>  > >
>  > > My htaccess file:
>  > >
>  > > AddCharset UTF-8 .utf8
>  > > AddDefaultCharset UTF-8
>  > >
>  > > php_value mbstring.func_overload On
>  > > php_value mbstring.language Neutral
>  > > php_value mbstring.internal_encoding UTF-8
>  > > php_value mbstring.encoding_translation On
>  > > php_value mbstring.http_input auto
>  > > php_value mbstring.http_output UTF-8
>  > > php_value mbstring.detect_order auto
>  > > php_value mbstring.substitute_character none
>  > > php_value default_charset UTF-8
>  > >
>  > > My html header:
>  > > <meta http-equiv="content-type" content="text/html; />
>  > >
>  > > Thanks!
>  > >
>  > >
>  >
>  >
>  >
>  > ----------------------------------------------------------
>  > This message was sent using IMP, the Internet Messaging Program.
>  >
>
>

--
_______________________________________________________________
Kurt Stützer       kurt@...        http://www.pdflib.com
     PDFlib GmbH, Franziska-Bilek-Weg 9, 80339 München, Germany
    Amtsgericht München HRB 129497, Geschäftsführer Thomas Merz
---------------------------------------------------------------
PDFlib 7:  Create PDF/A for archiving, format tables, and more!
_______PDFlib - a library for generating PDF on the fly________

#19972 From: Thomas Merz <tm@...>
Date: Wed Nov 11, 2009 11:21 am
Subject: Re: PDF Lib repetitive blocks functionality
thomasmerz1
Offline Offline
Send Email Send Email
 
nihirporecha wrote:
> Hi,
> We are evaluating PDF lib developers kit for generating a PDF which will have
two rows layout for each of the transaction. We are planning to provide a PDF
template and replace the variables programmatically. As the number of
transactions are unknown, we would like to repeat the same transaction block for
the number of rows we receive from the database. Does PDF Lib support such kind
of functionality. To be more precise, we are looking for a .NET repeater control
kind of functionality, where we provide the layout template and it repeats the
same template for the number of rows available in the provided data source.

You have many options since programmatic controls and Blocks
can be combined in any manner. For example, you can create
a single Block with the Block Plugin and then fill it
repeatedly while modifying the original position on the page.
Alternatively you can create many Blocks on the page in
advance, and in your code decide which of the Blocks are
required for the current dataset. Or any mixture...

Thomas

_______________________________________________________________
Thomas Merz             tm@...            www.pdflib.com
    PDFlib GmbH, Franziska-Bilek-Weg 9, 80339 München,  Germany
    Amtsgericht München HRB 129497, Geschäftsführer Thomas Merz
---------------------------------------------------------------
PDFlib 7:  Create PDF/A for archiving, format tables, and more!
_______PDFlib - a library for generating PDF on the fly________

#19971 From: "bontjerate" <a.bontjer@...>
Date: Wed Nov 11, 2009 6:51 am
Subject: Re: UTF-8 problems
bontjerate
Offline Offline
Send Email Send Email
 
Hi,

The data is pulled straight from a $_POST var. Is there a way to check if a
string is UTF-8 or not?

If I echo $this->pagina4Tekstblok2Tekst to the screen it does show the één
instead of the strange e'e'n.

Any idea?

--- In pdflib@yahoogroups.com, guy@... wrote:
>
> Are you sure $this->pagina4Tekstblok2Tekst is emitting utf-8 encoded text?
>
> I've had trouble before where the problem was the database handle used
> to get the data from the db was stomping on the encoding. Perhaps
> that's what's happening to you too...?
>
> Guy
>
> Quoting bontjerate <a.bontjer@...>:
>
> > Hi,
> >
> > When I submit a utf-8 text to a php file, I don't get the expected result.
> >
> > This text:
> > Wij vinden een goed ondernemersklimaat belangrijk. Daarom moet er
> > één loket bij de gemeente komen. Wij vinden een goed
> > ondernemersklimaat belangrijk.
> >
> > Becomes this:
> > Wij vinden een goed ondernemersklimaat belangrijk. Daarom moet er
> > e'e'n loket bij de gemeente komen. Wij vinden een goed
> > ondernemersklimaat belangrijk.
> >
> > I initialize pdflib with:
> >
> > $p->set_parameter("textformat", "utf8");
> >
> > This is the text block:
> > $optlist = "fontname=".$config->pdf['fonts']."/SUN-REGU "
> > 		  ."fontsize=9.5 "
> > 		  ."encoding=unicode "
> > 		  ."alignment=left "
> > 		  ."firstlinedist=xheight "
> > 		  ."verticalalign=center "
> > 		  ."fillcolor={cmyk 0 0 0 1} "
> > 		  ."textflow=true ";
> > $p->fill_textblock($page, "pagina4Tekstblok2Tekst",
> > $this->pagina4Tekstblok2Tekst, $optlist);
> >
> > I tried adding textformat=utf8 tho the optlist but that didn't help.
> >
> > What am I missing or what am I doing wrong?
> >
> > My htaccess file:
> >
> > AddCharset UTF-8 .utf8
> > AddDefaultCharset UTF-8
> >
> > php_value mbstring.func_overload On
> > php_value mbstring.language Neutral
> > php_value mbstring.internal_encoding UTF-8
> > php_value mbstring.encoding_translation On
> > php_value mbstring.http_input auto
> > php_value mbstring.http_output UTF-8
> > php_value mbstring.detect_order auto
> > php_value mbstring.substitute_character none
> > php_value default_charset UTF-8
> >
> > My html header:
> > <meta http-equiv="content-type" content="text/html; charset=UTF-8" />
> >
> > Thanks!
> >
> >
>
>
>
> ----------------------------------------------------------------
> This message was sent using IMP, the Internet Messaging Program.
>

#19970 From: "nihirporecha" <nihirporecha@...>
Date: Wed Nov 11, 2009 5:56 am
Subject: PDF Lib repetitive blocks functionality
nihirporecha
Offline Offline
Send Email Send Email
 
Hi,
We are evaluating PDF lib developers kit for generating a PDF which will have
two rows layout for each of the transaction. We are planning to provide a PDF
template and replace the variables programmatically. As the number of
transactions are unknown, we would like to repeat the same transaction block for
the number of rows we receive from the database. Does PDF Lib support such kind
of functionality. To be more precise, we are looking for a .NET repeater control
kind of functionality, where we provide the layout template and it repeats the
same template for the number of rows available in the provided data source.

Hope, I am able to explain the requirement properly.

#19969 From: guy@...
Date: Wed Nov 11, 2009 2:44 am
Subject: Re: UTF-8 problems
guy_mmmmmm
Offline Offline
Send Email Send Email
 
Are you sure $this->pagina4Tekstblok2Tekst is emitting utf-8 encoded text?

I've had trouble before where the problem was the database handle used
to get the data from the db was stomping on the encoding. Perhaps
that's what's happening to you too...?

Guy

Quoting bontjerate <a.bontjer@...>:

> Hi,
>
> When I submit a utf-8 text to a php file, I don't get the expected result.
>
> This text:
> Wij vinden een goed ondernemersklimaat belangrijk. Daarom moet er
> één loket bij de gemeente komen. Wij vinden een goed
> ondernemersklimaat belangrijk.
>
> Becomes this:
> Wij vinden een goed ondernemersklimaat belangrijk. Daarom moet er
> e'e'n loket bij de gemeente komen. Wij vinden een goed
> ondernemersklimaat belangrijk.
>
> I initialize pdflib with:
>
> $p->set_parameter("textformat", "utf8");
>
> This is the text block:
> $optlist = "fontname=".$config->pdf['fonts']."/SUN-REGU "
> 		  ."fontsize=9.5 "
> 		  ."encoding=unicode "
> 		  ."alignment=left "
> 		  ."firstlinedist=xheight "
> 		  ."verticalalign=center "
> 		  ."fillcolor={cmyk 0 0 0 1} "
> 		  ."textflow=true ";
> $p->fill_textblock($page, "pagina4Tekstblok2Tekst",
> $this->pagina4Tekstblok2Tekst, $optlist);
>
> I tried adding textformat=utf8 tho the optlist but that didn't help.
>
> What am I missing or what am I doing wrong?
>
> My htaccess file:
>
> AddCharset UTF-8 .utf8
> AddDefaultCharset UTF-8
>
> php_value mbstring.func_overload On
> php_value mbstring.language Neutral
> php_value mbstring.internal_encoding UTF-8
> php_value mbstring.encoding_translation On
> php_value mbstring.http_input auto
> php_value mbstring.http_output UTF-8
> php_value mbstring.detect_order auto
> php_value mbstring.substitute_character none
> php_value default_charset UTF-8
>
> My html header:
> <meta http-equiv="content-type" content="text/html; charset=UTF-8" />
>
> Thanks!
>
>



----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.

#19968 From: "bontjerate" <a.bontjer@...>
Date: Wed Nov 11, 2009 12:45 am
Subject: UTF-8 problems
bontjerate
Offline Offline
Send Email Send Email
 
Hi,

When I submit a utf-8 text to a php file, I don't get the expected result.

This text:
Wij vinden een goed ondernemersklimaat belangrijk. Daarom moet er één loket bij
de gemeente komen. Wij vinden een goed ondernemersklimaat belangrijk.

Becomes this:
Wij vinden een goed ondernemersklimaat belangrijk. Daarom moet er e'e'n loket
bij de gemeente komen. Wij vinden een goed ondernemersklimaat belangrijk.

I initialize pdflib with:

$p->set_parameter("textformat", "utf8");

This is the text block:
$optlist = "fontname=".$config->pdf['fonts']."/SUN-REGU "
		   ."fontsize=9.5 "
		   ."encoding=unicode "
		   ."alignment=left "
		   ."firstlinedist=xheight "
		   ."verticalalign=center "
		   ."fillcolor={cmyk 0 0 0 1} "
		   ."textflow=true ";
$p->fill_textblock($page, "pagina4Tekstblok2Tekst",
$this->pagina4Tekstblok2Tekst, $optlist);

I tried adding textformat=utf8 tho the optlist but that didn't help.

What am I missing or what am I doing wrong?

My htaccess file:

AddCharset UTF-8 .utf8
AddDefaultCharset UTF-8

php_value mbstring.func_overload On
php_value mbstring.language Neutral
php_value mbstring.internal_encoding UTF-8
php_value mbstring.encoding_translation On
php_value mbstring.http_input auto
php_value mbstring.http_output UTF-8
php_value mbstring.detect_order auto
php_value mbstring.substitute_character none
php_value default_charset UTF-8

My html header:
<meta http-equiv="content-type" content="text/html; charset=UTF-8" />

Thanks!

#19967 From: Thomas Merz <tm@...>
Date: Tue Nov 10, 2009 8:01 pm
Subject: Re: Re: PDF file with 3D model insert
thomasmerz1
Offline Offline
Send Email Send Email
 
randall.toepfer wrote:
> Thanks Thomas.  If I used another appliation to create a PDF that
  > only contains a 3D annotation/poster, I should then be able to use the
  > pdflib merge functionality to incorporate the original 3D PDF page
  > into a new PDF page created by pdflib which may contain text, forms,
  > etc.?

No, this won't work since PDI imports only the actual page contents,
but not any interactive elements.

Thomas

_______________________________________________________________
Thomas Merz             tm@...            www.pdflib.com
    PDFlib GmbH, Franziska-Bilek-Weg 9, 80339 München,  Germany
    Amtsgericht München HRB 129497, Geschäftsführer Thomas Merz
---------------------------------------------------------------
PDFlib 7:  Create PDF/A for archiving, format tables, and more!
_______PDFlib - a library for generating PDF on the fly________

#19966 From: "randall.toepfer" <randall.toepfer@...>
Date: Tue Nov 10, 2009 7:51 pm
Subject: Re: PDF file with 3D model insert
randall.toepfer
Offline Offline
Send Email Send Email
 
Thanks Thomas.  If I used another appliation to create a PDF that only contains
a 3D annotation/poster, I should then be able to use the pdflib merge
functionality to incorporate the original 3D PDF page into a new PDF page
created by pdflib which may contain text, forms, etc.?

--- In pdflib@yahoogroups.com, Thomas Merz <tm@...> wrote:
>
> It's definitely post PDFlib 8.0 which we will release very
> soon. The priority of PRC support after PDFlib 8 depends
> on user inquiries, and so far we haven't received many.
>
> As a side note, we already implemented support for PRC
> sometime around PDFlib 7.0.2. However, testing with Acrobat
> showed that it didn't work as advertised in the PDF Reference,
> so we must double-check with Acrobat 8 and 9, and expect
> to run into unclear areas which need reverse engineering
> and experimentation - that will be the real effort for
> this new feature...
>
> Thomas
>
> randall.toepfer wrote:
> > Is there a rough estimate of the PRC implmentation date?
> >
> > --- In pdflib@yahoogroups.com, Thomas Merz <tm@> wrote:
> >> randall.toepfer wrote:
> >>> I found the cookbook example that shows how to embed a 3D file into a PDF.
PDF supports two native formats U3D and PRC.  The sample shows how to embed a
U3D file.  It seems U3D has not gained much support in the CAD industry.  How
can the same example be used to embed a PRC file?
> >> PRC is not yet supported in PDFlib (but we have it on the
> >> list).
> >>
> >> Thomas
>
>
> _______________________________________________________________
> Thomas Merz             tm@...            www.pdflib.com
>    PDFlib GmbH, Franziska-Bilek-Weg 9, 80339 München,  Germany
>    Amtsgericht München HRB 129497, Geschäftsführer Thomas Merz
> ---------------------------------------------------------------
> PDFlib 7:  Create PDF/A for archiving, format tables, and more!
> _______PDFlib - a library for generating PDF on the fly________
>

#19965 From: Thomas Merz <tm@...>
Date: Mon Nov 9, 2009 6:14 pm
Subject: Re: Re: PDF file with 3D model insert
thomasmerz1
Offline Offline
Send Email Send Email
 
It's definitely post PDFlib 8.0 which we will release very
soon. The priority of PRC support after PDFlib 8 depends
on user inquiries, and so far we haven't received many.

As a side note, we already implemented support for PRC
sometime around PDFlib 7.0.2. However, testing with Acrobat
showed that it didn't work as advertised in the PDF Reference,
so we must double-check with Acrobat 8 and 9, and expect
to run into unclear areas which need reverse engineering
and experimentation - that will be the real effort for
this new feature...

Thomas

randall.toepfer wrote:
> Is there a rough estimate of the PRC implmentation date?
>
> --- In pdflib@yahoogroups.com, Thomas Merz <tm@...> wrote:
>> randall.toepfer wrote:
>>> I found the cookbook example that shows how to embed a 3D file into a PDF. 
PDF supports two native formats U3D and PRC.  The sample shows how to embed a
U3D file.  It seems U3D has not gained much support in the CAD industry.  How
can the same example be used to embed a PRC file?
>> PRC is not yet supported in PDFlib (but we have it on the
>> list).
>>
>> Thomas


_______________________________________________________________
Thomas Merz             tm@...            www.pdflib.com
    PDFlib GmbH, Franziska-Bilek-Weg 9, 80339 München,  Germany
    Amtsgericht München HRB 129497, Geschäftsführer Thomas Merz
---------------------------------------------------------------
PDFlib 7:  Create PDF/A for archiving, format tables, and more!
_______PDFlib - a library for generating PDF on the fly________

#19964 From: "randall.toepfer" <randall.toepfer@...>
Date: Mon Nov 9, 2009 4:52 pm
Subject: Re: PDF file with 3D model insert
randall.toepfer
Offline Offline
Send Email Send Email
 
Is there a rough estimate of the PRC implmentation date?

--- In pdflib@yahoogroups.com, Thomas Merz <tm@...> wrote:
>
> randall.toepfer wrote:
> > I found the cookbook example that shows how to embed a 3D file into a PDF. 
PDF supports two native formats U3D and PRC.  The sample shows how to embed a
U3D file.  It seems U3D has not gained much support in the CAD industry.  How
can the same example be used to embed a PRC file?
>
> PRC is not yet supported in PDFlib (but we have it on the
> list).
>
> Thomas
>
> _______________________________________________________________
> Thomas Merz             tm@...            www.pdflib.com
>    PDFlib GmbH, Franziska-Bilek-Weg 9, 80339 München,  Germany
>    Amtsgericht München HRB 129497, Geschäftsführer Thomas Merz
> ---------------------------------------------------------------
> PDFlib 7:  Create PDF/A for archiving, format tables, and more!
> _______PDFlib - a library for generating PDF on the fly________
>

#19963 From: "Zahir Lalani" <zlalani@...>
Date: Sun Nov 8, 2009 6:28 pm
Subject: RE: Text Replacement
zlalani
Offline Offline
Send Email Send Email
 
Thx Thomas

Yes, I did see that example. But what I did not realize was the ability to
extract the font info and to replace the text in the original font. Your
clue below completes the circle - Thx

Zahir

-----Original Message-----
From: pdflib@yahoogroups.com [mailto:pdflib@yahoogroups.com] On Behalf Of
Thomas Merz
Sent: 08 November 2009 15:30
To: pdflib@yahoogroups.com
Subject: Re: [pdflib] Text Replacement

Zahir Lalani wrote:
> We already use the pdfblock tool and PPS to allow us to easily add
> custom data to a pdf. We now need to handle a different situation and I
> am not sure who we would do it with PDFlib.
>
> We will receive several documents that are prepared by third parties (so
> we have no control over their tools). They will encode certain parts of
> their text with “[[x1]]”, “[[x2]]” etc. We need to be able to search for
> these items in the document and replace them with our own text but
> keeping the original style of the font. Is this possible in pdflib?

First of all, you should consider whether you can gain more
control/cooperation regarding the PDF creation process. If
this is not possible you can achieve your goal with the
combination of PPS and our Text Extraction Toolkit (TET).
The TET cookbook contains an example which demonstrates how
to search for a particular text string on the PDF page, and
then use PDFlib+PDI or PPS to replace it with some other
text:

http://www.pdflib.com/en/developercookbook/tet-and-pdflib/search-and-replace
-text/

This sample uses a fixed font for the replacement text, but
you can easily modify the code to clone the existing
font since TET also gives you information about the font
and size of the text in the input document.

Thomas

_______________________________________________________________
Thomas Merz             tm@...            www.pdflib.com
    PDFlib GmbH, Franziska-Bilek-Weg 9, 80339 München,  Germany
    Amtsgericht München HRB 129497, Geschäftsführer Thomas Merz
---------------------------------------------------------------
PDFlib 7:  Create PDF/A for archiving, format tables, and more!
_______PDFlib - a library for generating PDF on the fly________


------------------------------------

------------------------------------------
Please see our cookbooks for sample code:
http://www.pdflib.com/developer/cookbook/
------------------------------------------

Yahoo! Groups Links




This e-mail has been scanned for all viruses by Star.

______________________________________________________________________
This email has been scanned by the MessageLabs Email Security System.
For more information please visit http://www.messagelabs.com/email
______________________________________________________________________

Messages 19963 - 20012 of 20065   Newest  |  < Newer  |  Older >  |  Oldest
Advanced
Add to My Yahoo!      XML What's This?

Copyright © 2009 Yahoo! Inc. All rights reserved.
Privacy Policy - Terms of Service - Guidelines - Help