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 175582 - Code formating shifts class name
Summary: Code formating shifts class name
Status: VERIFIED FIXED
Alias: None
Product: javafx
Classification: Unclassified
Component: Editor (show other bugs)
Version: 6.x
Hardware: All All
: P2 blocker (vote)
Assignee: Anton Chechel
URL:
Keywords:
: 175652 (view as bug list)
Depends on:
Blocks: 173487
  Show dependency tree
 
Reported: 2009-10-28 12:00 UTC by Alexandr Scherbatiy
Modified: 2009-11-18 03:17 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Alexandr Scherbatiy 2009-10-28 12:00:41 UTC
Product Version         = NetBeans IDE Dev (Build 200910271401) (#32576b20b4bb)
  Operating System        = Windows XP version 5.1 running on x86
  Java; VM; Vendor        = 1.6.0_15; Java HotSpot(TM) Client VM 14.1-b02; Sun Microsystems Inc.

Steps to reproduce:
- Copy the code to the editor:
----------------------------------------------------
import javafx.stage.Stage;
import javafx.scene.Node;
import javafx.scene.Scene;
import javafx.scene.text.Text;
import javafx.scene.text.Font;

class MyFrame extends Stage {

    public var content:Node[];

    init{
        scene = Scene{
            content:content
        }
    }
}


MyFrame{
    content: [
        Text {
                font : Font { size: 24   }
                x: 10   , y: 30
                content : "Hello World!"
        }
    ]
}
----------------------------------------------------

- Format the code

The result is
----------------------------------------------------
         class MyFrame extends Stage {

    public var content:Node[];

    init{
        scene = Scene{
            content:content
        }
    }
}
----------------------------------------------------

There are spaces before the 'class MyFrame extends Stage {' line
Comment 1 Anton Chechel 2009-10-31 17:31:11 UTC
This bug caused by http://javafx-jira.kenai.com/browse/JFXC-3581
Compiler scans first javafx$run$() method in which MyFrame is instantiated.
Comment 2 Anton Chechel 2009-11-02 14:24:20 UTC
*** Issue 175652 has been marked as a duplicate of this issue. ***
Comment 3 Anton Chechel 2009-11-11 11:00:20 UTC
fixed by http://hg.netbeans.org/javafx/rev/2e6affd7a86e
Comment 4 Alexandr Scherbatiy 2009-11-18 03:17:23 UTC
verified in Build 200911170201