Do you own a Debenu Quick PDF Library version 7, 8, 9, 10, 11, 12, 13 or iSEDQuickPDF license? Upgrade to Debenu Quick PDF Library 14 today!

Debenu Quick PDF Library - PDF SDK Community Forum Homepage
Forum Home Forum Home > For Users of the Library > I need help - I can help
  New Posts New Posts RSS Feed - Not support Chinese and CMYK Color porblem
  FAQ FAQ  Forum Search   Register Register  Login Login

Not support Chinese and CMYK Color porblem

 Post Reply Post Reply
Author
Message
mitchellhu View Drop Down
Beginner
Beginner
Avatar

Joined: 11 Jul 13
Status: Offline
Points: 11
Post Options Post Options   Thanks (0) Thanks(0)   Quote mitchellhu Quote  Post ReplyReply Direct Link To This Post Topic: Not support Chinese and CMYK Color porblem
    Posted: 11 Jul 13 at 8:48AM
I download trail version 0914.
found 2 problems.
1. not support Chinese for function DrawText.
2. for function SetFillColorCMYK, 
    QP.SetFillColorCMYK(100,0,0,0) and QP.SetFillColorCMYK(50,0,0,0)
    shows no different , it looks same on pdf.

Is it right, trail version does not support full function?

Mitchell Hu


Back to Top
Ingo View Drop Down
Moderator Group
Moderator Group
Avatar

Joined: 29 Oct 05
Status: Offline
Points: 3524
Post Options Post Options   Thanks (0) Thanks(0)   Quote Ingo Quote  Post ReplyReply Direct Link To This Post Posted: 11 Jul 13 at 9:07AM
Hi Mitchell!
 
The trial version is only limited in time - not in functionality.
For your problem you should use the search function here
'cause there were similar posts in the past.
 
Cheers and welcome here,
Ingo
 
Back to Top
mitchellhu View Drop Down
Beginner
Beginner
Avatar

Joined: 11 Jul 13
Status: Offline
Points: 11
Post Options Post Options   Thanks (0) Thanks(0)   Quote mitchellhu Quote  Post ReplyReply Direct Link To This Post Posted: 11 Jul 13 at 10:11AM
Hi Ingo:

  Thanks for your answer.
  I set CMYK or Chinese as key work , then use Search function , but found not thing!

Mitchell Hu
Back to Top
Ingo View Drop Down
Moderator Group
Moderator Group
Avatar

Joined: 29 Oct 05
Status: Offline
Points: 3524
Post Options Post Options   Thanks (1) Thanks(1)   Quote Ingo Quote  Post ReplyReply Direct Link To This Post Posted: 11 Jul 13 at 10:25AM
Do the Advanced search and change time settings.
charset ... japanese ... japanese support ... unicode ... codepage ...
spread your mind ;-)
Using chinese font it's not enough simply using the drawing functions.
You have to add your font for example.
 
 
Back to Top
mitchellhu View Drop Down
Beginner
Beginner
Avatar

Joined: 11 Jul 13
Status: Offline
Points: 11
Post Options Post Options   Thanks (0) Thanks(0)   Quote mitchellhu Quote  Post ReplyReply Direct Link To This Post Posted: 11 Jul 13 at 3:33PM
Hi Ingo:
  Just do the Advanced search, found some answer and bring more question !!! Ha! Ha!
 1.AddSubsettedFont function can show Chinse words, but the function parameters squences is different Delphi and
   Debenu Quick PDF library 9.14 Referece Guide.pdf,
   Delphi xe2 : FontName:system.widestring
                SubSetChars:system.WideString
Options:System.Integer
   Referce Guide : AddSubsettedFont(FontName: WideString;
                                    CharsetIndex: Integer; 
SubsetChars: WideString): Integer;
   the other strnage thing is no matter how to chnage FontName ( same as the name in C:\Windows\Fonts\), the Chinese
   Word font only shows default font : '新細明體 標準' and the font id always same as 1476395012. 
   Why?
   Code:
   //ifontID2 := QP.AddTrueTypeSubsettedFont('新細明體 標準', '胡明元', 7); 
   //ifontID2 := QP.AddTrueTypeSubsettedFont('MS Gothic', '胡明元', 7);
   //ifontID2 := QP.AddTrueTypeSubsettedFont('微軟正黑體', '胡明元', 7);
   ifontID2 := QP.AddTrueTypeSubsettedFont('胡明元', 7);
   //CharsetIndex 7: Chinese Big 5
   if (QP.SelectFont(ifontID2) = 1) then
   begin
     QP.SetTextColorCMYK(100, 0, 0, 0);
     QP.SetTextSize(24);
     QP.DrawText(30, 30, '胡明元');
   end;   
  2.about CMYK color question, still found nothing!!!
   QP.SetFillColorCMYK(100,0,0,0) ===> Blue
   QP.SetFillColorCMYK(50,0,0,0) ===> Light Blue
   But the second one will show Blue color same as first one!
   Why?
   Code:
   QP.SetFillColorCMYK(100,0,0,0)
   QP.DrawBox( 10, 10, 10, 5, 2);
   QP.SetFillColorCMYK(50,0,0,0)
   QP.DrawBox( 30, 10, 10, 5, 2);
  3. I want to DrawText(10,10,'CMYK')
     letter 'C' set color to CMYK(100,0,0,0);
     letter 'M' set color to CMYK(0,100,0,0); 
     letter 'Y' set color to CMYK(0,0,100,0);  
     letter 'K' set color to CMYK(0,0,0,100);
    is there a function can extact a letter form text and set it's color?

 Thanks

Mitchell Hu
P.S: My English ability is poor, hope you could understand what I am say 
Back to Top
mitchellhu View Drop Down
Beginner
Beginner
Avatar

Joined: 11 Jul 13
Status: Offline
Points: 11
Post Options Post Options   Thanks (0) Thanks(0)   Quote mitchellhu Quote  Post ReplyReply Direct Link To This Post Posted: 12 Jul 13 at 2:40AM
for the point 2. I got answer:
the value for CMYK should be divided by 100.
QP.SetFillColorCMYK(100/100,0,0,0) ===> Blue
QP.SetFillColorCMYK(50/100,0,0,0) ===> Light Blue


Mitchell Hu
Back to Top
mitchellhu View Drop Down
Beginner
Beginner
Avatar

Joined: 11 Jul 13
Status: Offline
Points: 11
Post Options Post Options   Thanks (0) Thanks(0)   Quote mitchellhu Quote  Post ReplyReply Direct Link To This Post Posted: 12 Jul 13 at 4:02AM
the 3 point:
use function TDebenuPDFLibrary0914.GetTextWidth(Text: WideString): Double
code
  ifontID2 := QP.AddTrueTypeSubsettedFont('標楷體 標準','胡明元', 7);
  if (QP.SelectFont(ifontID2) = 1) then
  begin
      QP.SetTextColorCMYK(100, 0, 0, 0);
      QP.SetTextSize(48);
      QP.DrawText(30, 30, '胡明元');
      QP.SetTextColorCMYK(100, 0, 0, 0);
      QP.SetTextSize(48);
      QP.DrawText(100, 30, '胡明元');
      QP.SetTextColorCMYK(0, 100, 0, 0);
      QP.DrawText(100+QP.GetTextWidth('胡明元'),30,'胡');
      QP.SetTextColorCMYK(0, 0, 100, 0);
      QP.DrawText(100+QP.GetTextWidth('胡明元胡'),30,'明');
      QP.SetTextColorCMYK(0, 0, 0, 100);
      QP.DrawText(100+QP.GetTextWidth('胡明元胡明'),30,'元');
   end;

Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 11.01
Copyright ©2001-2014 Web Wiz Ltd.

Copyright © 2017 Debenu. Debenu Quick PDF Library is a PDF SDK. All rights reserved. AboutContactBlogSupportOnline Store