harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Alexey A. Ivanov (JIRA)" <j...@apache.org>
Subject [jira] Commented: (HARMONY-2915) [classlib][swing] j.s.text.BoxView incorrectly layouts where its child views are resizable
Date Thu, 28 Dec 2006 16:25:27 GMT
    [ http://issues.apache.org/jira/browse/HARMONY-2915?page=comments#action_12461215 ] 
Alexey A. Ivanov commented on HARMONY-2915:

Applying the patch to SizeRequirementsHelper makes org.apache.harmony.x.swing.SizeRequirementsHelperRTest
and javax.swing.text.BoxView_WithChildrenTest fail.

The first failed assertion at 44 is not critical: the order of computations was changed and
having in mind rounding errors, the value could change by 1.

BoxView_WithChildrenTest .testBaselineLayout01:
The expected value of the failed assertion differs from the actual one by 1. But if we change
the condition above
        if (i == 1 && isHarmony())
to simply
        if (i == 1)
the test will pass successfully.

All four assertions at the end of the test fail: the allocation strategy is to give as much
space to a child as possible. That's why both offsets are now 0, and both spans are now 200.

On the other hand, the previous values are not absolutely correct. The previous implementation
tried to proportionally distribute extra space. But I think it should have given span of 200
to the second child which was not the case.

> [classlib][swing] j.s.text.BoxView incorrectly layouts where its child views are resizable
> ------------------------------------------------------------------------------------------
>                 Key: HARMONY-2915
>                 URL: http://issues.apache.org/jira/browse/HARMONY-2915
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>            Reporter: Alexey A. Ivanov
>         Attachments: H2915-SizeRequirementsHelper.patch, HTest2915.java
> If one puts a resizable view into a javax.swing.ParagraphView row, the view will be layout
incorrectly where there's not enough of space to display the view reduces lower than its preferred

This message is automatically generated by JIRA.
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira


View raw message