Details

    • Type: Bug Bug
    • Status: Open
    • Priority: Major Major
    • Resolution: Unresolved
    • Affects Version/s: current
    • Fix Version/s: unplanned
    • Component/s: general
    • Labels:
      None
    • Environment:

      Operating System: All
      Platform: All

    • Issuezilla Id:
      14

      Description

      Hello maxz1,

      I want to comment the next issue with Swing Explorer 1.4 under Netbeans 6.7.1. I
      don´t know if happens in other versions. I tested with JDK 1.5 and 1.6. The
      exception were the same.
      I have a JPanel with this piece of code under initComponent, (this is line 8
      reported by the exception)

      layout.setVerticalGroup(
      layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
      .add(layout.createSequentialGroup()
      .addContainerGap()

      .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.CENTER)
      .add(textoUsuario,
      org.jdesktop.layout.GroupLayout.PREFERRED_SIZE,
      org.jdesktop.layout.GroupLayout.DEFAULT_SIZE,
      org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
      .add(jLabel1))
      .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)

      .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.CENTER)
      .add(textoContrasena,
      org.jdesktop.layout.GroupLayout.PREFERRED_SIZE,
      org.jdesktop.layout.GroupLayout.DEFAULT_SIZE,
      org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
      .add(jLabel2))
      .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)

      .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
      .add(botonCancelar)
      .add(botonOk))
      .addContainerGap())
      );

      If I run the Panel without Swing Explorer there isn´t any exception. But If I
      run with Swing Explorer I got the next exception

      Exception in thread "AWT-EventQueue-1"
      com.lordjoe.csharp.Delegator$DelegateInvokeException:
      java.lang.IllegalArgumentException: Alignment must be one of:LEADING, TRAILING,
      CENTER or BASELINE
      at com.lordjoe.csharp.Delegator$DelegateProxy.invoke(Delegator.java:224)
      at com.lordjoe.csharp.Delegator$DelegateProxy.invoke(Delegator.java:168)
      at com.rsoft.mvc.Comando.ejecuta(Comando.java:61)
      at com.rsoft.mvc.Comando.actionPerformed(Comando.java:67)
      at
      javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1995)
      at
      javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2318)
      at
      javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:387)
      at
      javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:242)
      at javax.swing.AbstractButton.doClick(AbstractButton.java:357)
      at
      javax.swing.plaf.basic.BasicMenuItemUI.doClick(BasicMenuItemUI.java:1223)
      at
      javax.swing.plaf.basic.BasicMenuItemUI$Handler.mouseReleased(BasicMenuItemUI.jav
      a:1264)
      at java.awt.Component.processMouseEvent(Component.java:6263)
      at javax.swing.JComponent.processMouseEvent(JComponent.java:3255)
      at java.awt.Component.processEvent(Component.java:6028)
      at java.awt.Container.processEvent(Container.java:2041)
      at java.awt.Component.dispatchEventImpl(Component.java:4630)
      at java.awt.Container.dispatchEventImpl(Container.java:2099)
      at java.awt.Component.dispatchEvent(Component.java:4460)
      at
      java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4574)
      at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4238)
      at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4168)
      at java.awt.Container.dispatchEventImpl(Container.java:2085)
      at java.awt.Window.dispatchEventImpl(Window.java:2475)
      at java.awt.Component.dispatchEvent(Component.java:4460)
      at java.awt.EventQueue.dispatchEvent(EventQueue.java:599)
      at
      org.swingexplorer.edt_monitor.EDTDebugQueue.dispatchEvent(EDTDebugQueue.java:253
      )
      at
      java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:269
      )
      at
      java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:184)
      at
      java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:174
      )
      at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:169)
      at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:161)
      at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)
      Caused by: java.lang.IllegalArgumentException: Alignment must be one of:LEADING,
      TRAILING, CENTER or BASELINE
      at org.jdesktop.layout.GroupLayout.checkAlignment(GroupLayout.java:224)
      at org.jdesktop.layout.GroupLayout.access$100(GroupLayout.java:85)
      at
      org.jdesktop.layout.GroupLayout$ParallelGroup.<init>(GroupLayout.java:1744)
      at
      org.jdesktop.layout.GroupLayout.createParallelGroup(GroupLayout.java:498)
      at
      org.jdesktop.layout.GroupLayout.createParallelGroup(GroupLayout.java:472)
      at
      com.rsoft.componentes.login.LoginPanelView.initComponents(LoginPanelView.java:89
      )
      at
      com.rsoft.componentes.login.LoginPanelView.<init>(LoginPanelView.java:13)
      at
      com.rsoft.mvc.entorno.EntornoPresentador.mostrarConectar(EntornoPresentador.java
      :120)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at
      sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at
      sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.jav
      a:25)
      at java.lang.reflect.Method.invoke(Method.java:597)
      at com.lordjoe.csharp.Delegator$DelegateProxy.invoke(Delegator.java:217)
      ... 31 more

      It seems obvious that a constant which NetBeans entered in the autogenerated
      code is incorrect, but I don´t undestand why normal execution runs and Swing
      Explorer execution launches an exception.

      If you need more info to see if swing explorer works fine or not I will send you
      the java form.
      Thanks in advance.

        Activity

        Hide
        rlorenb added a comment -

        Created an attachment (id=4)
        NetBeans project to reproduce Issue 14

        Show
        rlorenb added a comment - Created an attachment (id=4) NetBeans project to reproduce Issue 14

          People

          • Assignee:
            maxz1
            Reporter:
            maxz1
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated: