This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 76012 - Group move produces unexpected results
Summary: Group move produces unexpected results
Status: NEW
Alias: None
Product: guibuilder
Classification: Unclassified
Component: Natural Layout (show other bugs)
Version: 5.x
Hardware: All All
: P3 blocker (vote)
Assignee: issues@guibuilder
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-05-05 20:26 UTC by Rochelle Raccah
Modified: 2008-04-29 13:31 UTC (History)
0 users

See Also:
Issue Type: ENHANCEMENT
Exception Reporter:


Attachments
screenshot before changes (142.27 KB, image/jpeg)
2006-05-05 20:27 UTC, Rochelle Raccah
Details
screenshot prepared to drag (94.69 KB, image/jpeg)
2006-05-05 20:27 UTC, Rochelle Raccah
Details
screenshot during drag (91.54 KB, image/jpeg)
2006-05-05 20:28 UTC, Rochelle Raccah
Details
screenshot after dragging (94.38 KB, image/jpeg)
2006-05-05 20:28 UTC, Rochelle Raccah
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Rochelle Raccah 2006-05-05 20:26:38 UTC
Pick up EntityClassesPanel.form & .java from
<http://www.netbeans.org/source/browse/j2ee/persistence/src/org/netbeans/modules/j2ee/persistence/wizard/fromdb/?only_with_tag=release55>

I'll attach a screenshot of the form before changes.  The goal is to slightly
shorten the class names scroll pane/jtable area, then move everything underneath
it upwards. However, I can demonstrate the problem without shortening the class
names area.

In the second screenshot, I show the items to be moved ctrl-clicked and ready
for dragging.

The third screenshot shows during drag just before letting go - I expect it to
end up like this, but see what happens when I let go in the fourth screenshot.
Comment 1 Rochelle Raccah 2006-05-05 20:27:29 UTC
Created attachment 30284 [details]
screenshot before changes
Comment 2 Rochelle Raccah 2006-05-05 20:27:56 UTC
Created attachment 30285 [details]
screenshot prepared to drag
Comment 3 Rochelle Raccah 2006-05-05 20:28:21 UTC
Created attachment 30286 [details]
screenshot during drag
Comment 4 Rochelle Raccah 2006-05-05 20:28:47 UTC
Created attachment 30287 [details]
screenshot after dragging
Comment 5 Jan Stola 2006-09-05 14:21:55 UTC
This behaviour may be unexpected to you, but it is as designed. Note that 
almost every gesture can have more meanings and we don't have an API (like 
java.io.mind.* ;-) ) to recognize what you expect in the given situation.

Let me explain this test case in detail - when you select several components 
and move them then they are removed from the layout and a new group is created 
from them. This group is then placed according to your gestures. In your test 
case you aligned the group with the right side of the JScrolPane (as it is 
shown on the third screenshot) => the whole group is aligned to the right with 
the JScrollPane.

If you want to shorten the height of the JScrollPane, then it is sufficient (in 
this form) to drag the bottom edge of the container up. If you want to shorten 
the gap below JScrollPane, you should select it and invoke Space Around 
Component from its contextual menu.
Comment 6 Rochelle Raccah 2006-09-12 23:56:43 UTC
When I "drag the bottom edge of the container up" as you suggested, it didn't
behave the way I wanted either.  But, the point is that when I let go, I expect
it to look like screenshot 3.  Otherwise, it should look like screenshot 4
during the dragging.  The end result is unexpected.

Adding Tomas to the cc because he is the one who told me to file it.  Tomas, do
you think it's a bug or expected behavior?
Comment 7 Tomas Pavek 2006-09-13 09:24:20 UTC
Not sure if it is a bug :) It is definitely unexpected. The group is dropped 
into the second column, which corresponds to how it is implemented. But perhaps 
in this particular case we could handle it better - by improving the group 
moving in one dimension only. We might also revisit the rule of keeping 
(preferring) the columns. This is a good example for both cases.