Skip to main content
Known Participant
July 20, 2009
Question

SubParagraphGroupElement can not be instantiated

  • July 20, 2009
  • 1 reply
  • 1118 views
I was trying to instantiate the class SubParagraphGroupElement and got this error - "Main Thread (Suspended: Error: Attempted construct of invalid FlowElement subclass)"

Exemple:
var subP:SubParagraphGroupElement = new SubParagraphGroupElement();

This is a bug?,  if not how should I proceed to instantiate this class. Thanks.




This topic has been closed for replies.

1 reply

Participating Frequently
July 20, 2009

Hi,

SubParagraphGroupElement is effectively an abstract class. You can only instantiate one of its concrete subclasses. Currently, these are TCYElement or LinkElement.

Could you share how you intended to use an instance of SubParagraphGroupElement if it could be created?

Thanks,

Abhishek

(Adobe Systems Inc.)


Known Participant
July 20, 2009
Hi, Abhishek, thanks for the reply.

I would like to create a group of elements within a paragraph, and thus can handle them, like this

Imaginary exemple:

<TextFlow fontFamily="Trebuchet MS" fontSize="20" lineBreak="toFit" whiteSpaceCollapse="preserve" xmlns="http://ns.adobe.com/textLayout/2008">
     <p>
          <group id='my_group'>
                    <span color="0x99cc">Lorem</span>
                    <span> Ipsum </span>        
          </group>
          <span color="0x3399">other text</span>         
     </p>
</TextFlow>

This is only a hypothetic exemple.

Thanks.
Known Participant
July 23, 2009
Help me, please
I stopped here because this situation, needed to solve the previous post, I wonder know if the above example is possible, Thanks