Skip to main content
Participant
June 9, 2011
Question

Can InlineGraphicElement be marked non-final?

  • June 9, 2011
  • 1 reply
  • 794 views

I desperately want to add some custom properties to InlineGraphicElement but I'm crippled by the fact that it is marked as final.  Is there a good reason for the class to be final?  Final classes and private properties/methods makes it very hard to extend the TLF without branching the core code, which make it annoying to keep up to date with the core TLF.

I get that the are potentially unexpected consequences if people extend some of these classes, but there are also valid and useful ways to extend them.  I would much prefer a non-final class, and notes in the comments saying that it is potentially dangerous to extend.

http://forums.adobe.com/thread/646563 <-- what he said

This topic has been closed for replies.

1 reply

Known Participant
June 10, 2011

I have to agree with ccapndave.  One benefit would be the ability to add some code that could handle ALT or TITLE descriptions for the images.  Doesn't seem like Adobe is going to try and add that feature.

Participating Frequently
June 10, 2011

Hi:

All the FlowElement subclass that can be new’ed are designed to be final.

The issues are long.

1)      What does it mean to use an operation?

2)      To move FlowElement’s from one TextFlow to the other

3)      To import/export such a thing.

4)      …. More than that since we haven’t tried to support or test it

I don't quite understand what you mean about ALT or title description. But I think there are many many different notification APIs in TLF and additional formatting and styling you can use userStyles to do the element extention. That's the way we recommend you to do.

Maybe, you can give us some underlying requirements and needs details you wanted. We can work together to find out a way to solve them.

Thanks

Known Participant
June 10, 2011

In real HTML, the ALT and TITLE attributes are used on 'img' tags to meet W3C 508 Accessibility Standards.  One key behavior is that assitive technologies will announce the ALT description or TITLE to a disabled user.

Here are some quick links:

ALT - http://www.w3.org/TR/2010/NOTE-WCAG20-TECHS-20101014/H37.html

TITLE - http://www.w3schools.com/tags/att_standard_title.asp