Uploaded image for project: 'FOP'
  1. FOP
  2. FOP-1898

KnuthSequence documentation?

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Resolution: Unresolved
    • 2.5
    • None
    • layout/unqualified
    • None
    • Operating System: All
      Platform: All
    • 50725

    Description

      Attached is a patch against fop.layoutmgr.KnuthSequence, which takes care of a TODO (Do not extend ArrayList) by implementing the List interface via proxy methods to a member list.

      Reason this is not committed yet, is that I wanted to go a step further and add type safety to this class, but noticed that this is currently impossible.
      The explanation is also added in a new TODO: there is an inconsistency (or at least incongruency) between block-layout and inline-layout. Block-layout works mainly with KnuthSequences as List<ListElement> where inline-layout seems to expect List<KnuthSequence>...

      Suggestions? Ideas? I would like to see those aligned, and in theory, once KnuthSequence implements List, it is free to extend ListElement, if that would be appropriate. The other way around could also make sense: consider each ListElement as a KnuthSequence of a single element. Although that would require some more refactoring, since we have to extract the KnuthSequence/List interface before ListElement can implement it.

      Attachments

        1. KnuthSequence.diff
          5 kB
          Andreas L. Delmelle

        Activity

          People

            Unassigned Unassigned
            adelmelle@apache.org Andreas L. Delmelle
            Votes:
            1 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: