riadvice / AlivePDF

[Official AlivePDF] - AlivePDF is a client side AS3 PDF generation library for Adobe Flash, Flex and AIR
https://riadvice.github.io/AlivePDF/
32 stars 6 forks source link

Is this an active project? #384

Open jgrasmeder opened 5 years ago

jgrasmeder commented 5 years ago

I have been using Alive PDF 0.1.5 for many years now with great results. The reason for this inquiry is that I now have been given a new requirement to support localization. One of the first languages is Taiwanese Traditional Chinese. Currently, I am running into issues getting the class PDF() and or UnicodePDF() to work. I have downloaded the latest code base 0.1.7 RC but still no luck. I have not been able to locate any sample code that would help to get the method calls correct. I am using the following example with the output not looking good.

    public function Test()
    {
        try
        {
            pdf=new UnicodePDF();
            pdf.setDisplayMode(Display.FULL_PAGE, Layout.SINGLE_PAGE);
            pdf.addPage();
            pdf.setFont(new ArialUnicodeMS(CidInfo.CHINESE_TRADITIONAL),20);
            pdf.addText("Hello World!", 0, 10);
            pdf.addText("你好,世界", 0, 30);// zh_TW Taiwanese Traditional Chinese
        }
        catch (err:Error)
        {
            trace("Error found in PDF " + err.toString());
            //errorMsg = "Failed to create PDF file"; //todo get from resource
        }
    }

    public function save(method:String):ByteArray
    {
        var rtnValue:ByteArray=new ByteArray;
        rtnValue=pdf.save(method);
        return rtnValue;
    }

//////PDF output ////// Hello World! 你好| /////// /////// As you can see the Chinese pdf.addTest() call has been chopped ////// Do you have a better example of working code? Is this still an active project? I am not seeing much activity and 15 or so issues dealing with language support sitting for multiple years in the queue of issues.