public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug AWT/16770] New: Incorrect behaviour when adding multiple components to same orientation in BorderLayout
@ 2004-07-27  1:15 gcc-bugzilla at gcc dot gnu dot org
  2004-07-27  1:21 ` [Bug AWT/16770] " fitzsim at redhat dot com
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: gcc-bugzilla at gcc dot gnu dot org @ 2004-07-27  1:15 UTC (permalink / raw)
  To: gcc-bugs

In Acunia test suite's layout.BorderLayoutPositions test, there are
too many buttons showing.  When you add more than one component to the
same orientation in a BorderLayout, the last component you add will
replace the older components, and the older components shouldn't show
up.  Currently, you'll see more than one component in the NORTH part
of the layout, but under Sun's implementation, you'll see only one
component in that spot.
------- Additional Comments From djee at redhat dot com  2004-02-17 15:00 -------
The problem was that in
jni/gtk-peer/gnu_java_awt_peer_gtk_GtkComponentPeer.c,
setNativeBounds() was using the deprecated method
gtk_widget_set_usize(), which apparently ignores size requests of
zero.  It should be using gtk_widget_set_size_request() instead, which
does respect zero sizes.

This is not fixed in java-gui-branch.  Please verify.
------- Additional Comments From fitzsim at redhat dot com  2004-05-18 16:42 -------
I just removed the last vestiges of gtk_widget_set_usize from
gnu_java_awt_peer_gtk_GtkComponentPeer.c.  I removed the
implementation of gtkWidgetSetUsize.  The declaration had already been
removed from GtkComponentPeer.

This test still isn't behaving correctly.  Did you mean to say "now
fixed in java-gui-branch"?
------- Additional Comments From djee at redhat dot com  2004-05-18 16:53 -------
Yes, I'm certain that the problem disappeared when I filed my last
comment.  It seems the problem is back.  Reopening and accepting bug.
------- Additional Comments From djee at redhat dot com  2004-05-19 16:19 -------
Oh, and yes, I meant to say "now fixed" instead of "not fixed."
------- Additional Comments From djee at redhat dot com  2004-05-21 12:38 -------
I narrowed down the regression to a patch that was submitted to
GtkComponentPeer, and here is the abbreviated ChangeLog entry for the
patch:

2004-05-06  Thomas Fitzsimmons  <fitzsim@redhat.com>

    * gnu/java/awt/peer/gtk/GtkComponentPeer.java
    (GtkComponentPeer): Only set the peer's bounds if its component
    is valid.

The problem is that some components are created with (0,0,0,0) bounds,
but this info does not get passed on to the GTK peer at creation time
because of the above patch.  As a result, components that are supposed
to have zero size are created with their default preferred size, as
determined by GTK.

I think I can work around it by passing on the correct size to the
peer at a later time, e.g. when we're validating the parent container.
 But first, I'd like to know why the above patch was necessary, to be
sure that such a workaround is a necessary and correct approach.
------- Additional Comments From fitzsim at redhat dot com  2004-05-21 12:59 -------
I made that change because otherwise, the updated GtkListPeer had a
size of 0x0.  Instead of this change, we may need to communicate the
list peer's size back to its awtComponent.  The isValid check is
probably wrong.  Can you try to come up with a fix that makes
layout.BorderLayoutPositions and that keeps TestList working?

------- Additional Comments From fitzsim at redhat dot com  2004-05-21 13:01 -------
Created an attachment (id=100426)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=100426&action=view)
test the default size of a list

------- Additional Comments From djee at redhat dot com  2004-05-25 11:35 -------
Ok. I reversed the patch mentioned above in comment #5, and fixed the
List peer's native getSize() method.  This bug is now fixed in
java-gui-branch.  The TestList example also works with the latest fix.
 Please verify.
------- Additional Comments From fitzsim at redhat dot com  2004-05-25 12:02 -------
Verified fixed on java-gui-branch.  Thanks!


-- 
           Summary: Incorrect behaviour when adding multiple components to
                    same orientation in BorderLayout
           Product: gcc
           Version: 3.5.0
            Status: UNCONFIRMED
          Severity: enhancement
          Priority: P1
         Component: AWT
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: djee at redhat dot com
                CC: djee at redhat dot com,gcc-bugs at gcc dot gnu dot org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16770


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug AWT/16770] Incorrect behaviour when adding multiple components to same orientation in BorderLayout
  2004-07-27  1:15 [Bug AWT/16770] New: Incorrect behaviour when adding multiple components to same orientation in BorderLayout gcc-bugzilla at gcc dot gnu dot org
@ 2004-07-27  1:21 ` fitzsim at redhat dot com
  2004-07-27  1:28 ` fitzsim at redhat dot com
                   ` (3 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: fitzsim at redhat dot com @ 2004-07-27  1:21 UTC (permalink / raw)
  To: gcc-bugs



-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
           Severity|enhancement                 |normal
           Priority|P1                          |P2


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16770


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug AWT/16770] Incorrect behaviour when adding multiple components to same orientation in BorderLayout
  2004-07-27  1:15 [Bug AWT/16770] New: Incorrect behaviour when adding multiple components to same orientation in BorderLayout gcc-bugzilla at gcc dot gnu dot org
  2004-07-27  1:21 ` [Bug AWT/16770] " fitzsim at redhat dot com
@ 2004-07-27  1:28 ` fitzsim at redhat dot com
  2004-07-27  2:10 ` fitzsim at redhat dot com
                   ` (2 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: fitzsim at redhat dot com @ 2004-07-27  1:28 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From fitzsim at redhat dot com  2004-07-27 01:12 -------
Created an attachment (id=6836)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=6836&action=view)
test the default size of a list

manually reattach test case

-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16770


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug AWT/16770] Incorrect behaviour when adding multiple components to same orientation in BorderLayout
  2004-07-27  1:15 [Bug AWT/16770] New: Incorrect behaviour when adding multiple components to same orientation in BorderLayout gcc-bugzilla at gcc dot gnu dot org
                   ` (2 preceding siblings ...)
  2004-07-27  2:10 ` fitzsim at redhat dot com
@ 2004-07-27  2:10 ` fitzsim at redhat dot com
  2004-07-30 19:47 ` pinskia at gcc dot gnu dot org
  4 siblings, 0 replies; 6+ messages in thread
From: fitzsim at redhat dot com @ 2004-07-27  2:10 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From fitzsim at redhat dot com  2004-07-27 02:06 -------
Fixed.


-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                    |RESOLVED
         Resolution|                            |FIXED


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16770


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug AWT/16770] Incorrect behaviour when adding multiple components to same orientation in BorderLayout
  2004-07-27  1:15 [Bug AWT/16770] New: Incorrect behaviour when adding multiple components to same orientation in BorderLayout gcc-bugzilla at gcc dot gnu dot org
  2004-07-27  1:21 ` [Bug AWT/16770] " fitzsim at redhat dot com
  2004-07-27  1:28 ` fitzsim at redhat dot com
@ 2004-07-27  2:10 ` fitzsim at redhat dot com
  2004-07-27  2:10 ` fitzsim at redhat dot com
  2004-07-30 19:47 ` pinskia at gcc dot gnu dot org
  4 siblings, 0 replies; 6+ messages in thread
From: fitzsim at redhat dot com @ 2004-07-27  2:10 UTC (permalink / raw)
  To: gcc-bugs



-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
         AssignedTo|unassigned at gcc dot gnu   |djee at redhat dot com
                   |dot org                     |
             Status|UNCONFIRMED                 |ASSIGNED
     Ever Confirmed|                            |1
   Last reconfirmed|0000-00-00 00:00:00         |2004-07-27 02:06:26
               date|                            |


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16770


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug AWT/16770] Incorrect behaviour when adding multiple components to same orientation in BorderLayout
  2004-07-27  1:15 [Bug AWT/16770] New: Incorrect behaviour when adding multiple components to same orientation in BorderLayout gcc-bugzilla at gcc dot gnu dot org
                   ` (3 preceding siblings ...)
  2004-07-27  2:10 ` fitzsim at redhat dot com
@ 2004-07-30 19:47 ` pinskia at gcc dot gnu dot org
  4 siblings, 0 replies; 6+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2004-07-30 19:47 UTC (permalink / raw)
  To: gcc-bugs



-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|---                         |3.5.0


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16770


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2004-07-30 19:47 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-07-27  1:15 [Bug AWT/16770] New: Incorrect behaviour when adding multiple components to same orientation in BorderLayout gcc-bugzilla at gcc dot gnu dot org
2004-07-27  1:21 ` [Bug AWT/16770] " fitzsim at redhat dot com
2004-07-27  1:28 ` fitzsim at redhat dot com
2004-07-27  2:10 ` fitzsim at redhat dot com
2004-07-27  2:10 ` fitzsim at redhat dot com
2004-07-30 19:47 ` pinskia at gcc dot gnu dot org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).