RFR: JDK-8290469: Add new positioning options to PassFailJFrame test framework [v8]

Harshitha Onkar honkar at openjdk.org
Mon Aug 22 19:35:36 UTC 2022


On Sun, 21 Aug 2022 22:00:09 GMT, Phil Race <prr at openjdk.org> wrote:

>> Harshitha Onkar has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   review changes
>
> test/jdk/java/awt/regtesthelpers/PassFailJFrame.java line 278:
> 
>> 276:      *                  center and the test window (if not null) is placed to
>> 277:      *                  the right of the instruction frame.
>> 278:      *
> 
> "vertical center" means half way between the top and the bottom which is absolutely not what you mean, is it ?
> 
> horizontal center surely ?
> 
> But what if the test window is > 0.5 the width of the screen ? Now it is off the edge .. wouldn't it be better
> to move the instruction window to the left to accommodate it ?
> Although that might be tricky if we don't know its size yet ..

@prrace @aivanov-jdk For Horizontal position, the frame and window are positioned as follows - 

![image](https://user-images.githubusercontent.com/95945681/185998431-93adcced-cef9-4c04-bd2a-4511b6f34210.png). 

I intended to convey that the right edge of the instruction frame aligns with the yellow line, the line that runs vertically and divides the screen into right and left halves (vertical center - probably not the right term, as Phil mentioned horizontal center might be correct word here. Updated it in the latest commit.


> But what if the test window is > 0.5 the width of the screen ? Now it is off the edge .. wouldn't it be better
> to move the instruction window to the left to accommodate it ?
> Although that might be tricky if we don't know its size yet ..

Yes I agree, can we take it up as a separate issue while redesigning the framework as @aivanov-jdk suggested?

-------------

PR: https://git.openjdk.org/jdk/pull/9525



More information about the client-libs-dev mailing list