Sign In  Sign Up Live-Chat

Trouble with CSMTextSettings and DefineFont3

Last post 11-23-2008, 12:24 PM by msfaiz. 1 replies.
Sort Posts: Previous Next
  •  06-18-2008, 7:05 PM 131995

    Trouble with CSMTextSettings and DefineFont3

    I am using Aspose.Flash v1.5.8.0. I have had some troubles with text:

    To enable FlashType, I need to use the CSMTextSettings tag. When I create an instance of CSMTextSettings, the field Type is set to 0 (instead of BaseObjectType.CSMTextSettings). Since the field is read-only, I am not able to change it manually. With the DefineFont3 tag, there's a FlashException thrown every time I set the values for FontAscent, FontDescent, or FontLeading fields. Also when the FontBoundsTable or FontAdvanceTable are non-empty.

    I am using a complete source DefineFont3 instance (from an SWF created in Flash) and my aim is to embed a subset as required. I am copying over the fields from one DefineFont3 object to another. Am I doing something incorrectly?

     

    Thanks.

     

    Update:

    The exception was due to me not initializinf the FontKerningTable. Now there's no problem writing the SWF File, but the player crashes (it doesn't crash when the fields I mentioned earlier and the FontKerningTable are either 0 or empty - but I don't get any text!). I tried using the DefineFont2 tag, and everything works fine. Any ideas?

     

    Thanks again!

     
  •  11-23-2008, 12:24 PM 153793 in reply to 131995

    Re: Trouble with CSMTextSettings and DefineFont3

    You will get a better idea, if you will observe the relationships of these tags inside debugger after creating some sample swf with Flash 8 (or some other tool) and then reading it with Aspose.Flash.

     


    Many Thanks and Kind Regards,

    Shakeel Faiz
    Support Engineer
    Aspose Tyumen Team
     
View as RSS news feed in XML