Wednesday Apr 29, 2015

Node.js Express App in NetBeans IDE

The Visual Studio tutorial "Developing Node Applications" is... all about using the command line to set up a Node application. Here's the NetBeans IDE equivalent (using a development build, i.e., this is not in NetBeans IDE 8.0.2) of at least the first half of that tutorial, in screenshots, i.e., the whole process is automated, which is the point of tooling, i.e., to provide automation.

Click Finish after the above steps and you have a complete Express application, exactly the same as described in the Visual Studio tutorial above.

Then run it and you can use the many supporting tools in the IDE to tinker further with your application:

Sunday Apr 26, 2015

YouTube: How to Setup and Use Minecraft Forge

Quite impressed by Minecraft Forge, as well as how well it integrates via the Gradle plugin into NetBeans IDE:

Saturday Mar 07, 2015

Happy Birthday, Java!

\header {
  title = \markup { \italic "Happy Birthday, Java!" }

\paper {
  indent = #0

\score {
  \new PianoStaff = "pianostaff" <<
    \new Staff = "right" \relative c'' {
      \clef "treble"
      \time 3/4
      \tempo "Quick and snappy" 4 = 160
       r2 c8 c
       a'4 g f
       g2 e4
       f r f
       g2 c,4
       a' b c
       g2 e8 e
       f4 e d
       c2. r2. \bar "|."
    \addlyrics {
      Ha py birth -- day Ja va, 
      you are twen ty!
      For fun and for gain, 
      pub -- lic sta -- tic void main!
    \new Staff = "left" \relative c {
      \clef "bass"
       c4 <e g> <e g>
       f4 <a c> <a c>
       c,4 <e g> <e g>
       g,4 <b d> <b d>
       c4 <e g> <e g>
       f4 <a c> <a c>
       c,4 <e g> <e g>
       g,4 <b d> <b d>
       c4 <e g> <e g>
       c2. \bar "|."
  \layout { }
  \midi { }

Tuesday Jan 20, 2015

Free: Virtual Technology Summit by Oracle Technology Network

The Oracle Technology Network (OTN) is excited to invite you to the Virtual Technology Summit Series.  Four times a year come and join us to learn first hand from Oracle ACEs, Java Champions, and Oracle product experts, as they share their insight and expertise on using Oracle technologies to meet today‚Äôs IT challenges. Four main content areas covered will be Database, Java, Middleware and Systems.  

Are you struggling in being productive with Maven, HTML5 frameworks such as AngularJS, IoT hardware such as the Raspberry Pi, and Java EE? Do you want free, easy to use, out of the box tools for quickly and efficiently developing all kinds of applications? You really need to give NetBeans a whirl!

In the "Free Open Source Tools for Maven, HTML5, IoT, and Java EE" session, during the upcoming free Virtual Technology Summit by OTN (nice and simple URL we'll show you the latest enhancements and cool features of the free, open-source NetBeans IDE, which are used around the world, from engineers at Boeing and NASA to Java architects such as James Gosling and Stuart Marks!

If you haven't looked at the NetBeans IDE lately, you'll be blown away by the fast speed and performance enhancements. If you are completely new to the NetBeans IDE, see how easy it is to get started and be productive.

Tip: The full agenda is available here and notice that the session described above is in the Java Content Area:

The sessions are prerecorded, while the speakers and other experts will be available live, to answer questions. To give a sneak peak at what the site will look like, take a look at these two screenshots from the session described above.

Click below to register. Pick a date and time that matches your location:

  • Americas February 11th - 9am to 12:30 PT - click here.
  • EMEA February 25th - 9am to 12:30 GMT - click here.
  • APAC March 4th - 9:30am to 1pm IST - click here.

Spread the news to members of your JUGs, colleagues at your office, and fellow students at your schools, colleges, and universities!

Sunday Dec 21, 2014

Integrating Cloud Providers into NetBeans IDE (Part 5)

A small piece to add to the Cloud provider integration is... Git. Since you're able to display all the resources of interest that are made available by the Cloud provider, you should be able to let the user physically access the related sources:

Clicking the menu item above can directly open the Clone Repository dialog, which is part of the Git tools in NetBeans IDE: 

A few clicks later, you have the sources available locally, and you can then make changes to them and commit them, etc, using the range of Git tools made available by NetBeans IDE.

Friday Nov 07, 2014

JFX Fluidon in NetBeans IDE

Here's the new JFX Fluidon plugin by Gaurav Gupta in action in the Family Tree application described in step-by-step detail in "JavaFX Rich Client Programming on the NetBeans Platform". Click to enlarge the image to get the full effect.

It's pretty cool and here's a movie I made of it today:

Sunday Oct 19, 2014

NetBeans Translation Tip #2: Do Not Translate USE_MNEMONICS

So you're working on the NetBeans Translators project and you run the application, with its translated bundles, and then you see this error message:

WARNING [org.openide.awt.Toolbar]: Error in AWT task
	at org.openide.awt.Actions.setMenuText(
	at org.openide.awt.Actions$MenuBridge.updateState(
	at org.openide.awt.Actions$Bridge.prepare(
	at org.openide.awt.Actions$MenuBridge.prepare(
	at org.openide.awt.Actions.connect(
	at org.openide.awt.Actions$MenuItem.(
	at org.openide.awt.DynaMenuModel.loadSubmenu(

You also, assuming you're translating into French and have already translated the text in the error dialog below, see this dialog, once the application has started:

And you're unable to access any of the menu items in the menubar.

An error message that contains "setMenuText(" is one that can be figured out by thinking about where menus are defined, in the NetBeans Platform source code. This is done in the UI Utilities API module, which is org-openide-awt.jar.

When I went there, in "LocalizedNetBeans", I found that there are two translated bundle files there, both in French:

Notice the one in blue above. Through a process of trial and error, I discovered that the key "USE_MNEMONICS" should NOT be translated. If you translate USE_MNEMONICS, the error described above occurs. Simply do not include it in the bundle file shown in blue above, in the 'branding/modules/org-openide-awt.jar' folder. Delete it from there, as I did (which is why the file is shown in blue) if you have it there.

And then the problem is solved: the error message above is not shown and menu items can be accessed again, as normal.

PS: Also see tip #1.

Thursday Oct 09, 2014

YouTube: Quick Tips for AngularJS in NetBeans IDE 8.0.1

Assuming you're able to run Node and Bower from the command line, follow the steps in this screencast to get started with AngularJS in NetBeans IDE 8.0.1:

Tuesday Jun 10, 2014

Fosfor EPUB Reader

Instead of creating a fullblown NetBeans Platform application for doing WYSIWYG editing for EPUB, similar to Sigil, I decided to focus purely on the very narrow scope of EPUB reading. The scope is narrower and, since the application will be a lot less ambitious and smaller, a pure JavaFX implementation makes sense.

When you somehow get, e.g., buy, an EPUB file, you typically read it on a tablet or mobile device. However, some people in the world, e.g., me, still have laptops. Therefore, I'm creating a small JavaFX application that unzips EPUB files, into a temp directory, and then loads them into a JavaFX WebView.

Arabic support:

For an application like this, simplicity is the most important thing. Very few buttons, very few options, preferably no configuration of anything. Just let the user open the EPUB file and read it, that's it, nothing fancy.

CSS stylesheets and images are correctly read. It's exactly what it looks like, a reader for EPUB files. The back and forward buttons are working and you can also switch to the table of contents.

When it is complete, which it pretty much is right now, publishers of EPUB files can make this small app available from their site, to simplify life for their readers, since it will run easily and well on all operating systems.

Friday Feb 21, 2014

YouTube: JPA Model Code Generator for NetBeans IDE

Awesome new plugin for NetBeans IDE!

Get the plugin here:

Friday Feb 07, 2014

James Webb Space Telescope on NetBeans

Great screenshot by Sean Phillips, Duke's Choice Award winner, that provides a visualization of the James Webb Space Telescope Contact Analysis. It uses JavaFX 8 and NetBeans Platform 8 as its basis.

Saturday Dec 28, 2013

New Book: "JavaFX Rich Client Programming on the NetBeans Platform"

Now built into Java and closely integrated with the NetBeans Platform, JavaFX 8 is today's state-of-the-art Java-based toolkit for creating advanced user interfaces, manipulating media, generating graphical effects and animations, and much more. This guide covers everything you need to know to create industrial-strength business applications with JavaFX 8 and NetBeans -- including how JavaFX impacts user experience design, graphical design, and development processes.

Focusing on JavaFX as the front end for tomorrow's most powerful rich client applications, this is the first book to cover the version of JavaFX 8 incorporated into the Java APIs with the official release of Java SE8, instead of obsolete preview versions.

Gail and Paul Andersen fully explain both JavaFX 8 and its relationships with the NetBeans Platform architecture, and systematically show Java developers how to use them effectively together. To support sophisticated real-world business development, they also thoroughly address JavaFX 8 interactions with backend databases, JavaEE, RESTful web services, and the Jersey client.

Release date is September 2014. More info here!

Sunday Dec 15, 2013

Quick Browser for NetBeans IDE 7.4

The Quick Browser I created sometime ago is now available for NetBeans IDE 7.4:

It's pretty handy, e.g., open NetBeans projects by clicking on them in the browser. Open individual files too:

Get it here:

More details on this are here:

Still same open issue as before, unresolved so far:

Monday Oct 21, 2013

OrbitFX: JavaFX 8 3D & NetBeans Platform in Space!

Here is a collection of screenshots from a proof of concept tool being developed by Nickolas Sabey and Sean Phillips from a.i. solutions. Before going further, read a great new article here written on by Kevin Farnham, in light of the Duke's Choice Award (DCA) recently received at JavaOne 2013 by the a.i. solutions team. Here's Sean receiving the award on behalf of the a.i. solutions team, surrounded by the DCA selection committee and other officials:

They won the DCA for helping facilitate and deploy the 2014 launch of NASA's Magnetospheric Multiscale mission, using JDK 7, the NetBeans Platform, and JavaFX to create the GEONS Ground Support System, helping reduce software development time by approximately 35%.

The prototype tool that Nicklas and Sean are now working on uses JavaFX 3D with the NetBeans Platform and is nicknamed OrbitFX. Much of the early development is being done to experiment with different patterns, so that accuracy is currently not the goal. For example, you'll notice in the screenshots that the Earth is really close to the Sun, which is obviously not correct.

The screenshots are generated using Java 8 build 111, together with NetBeans Platform 7.4. Inspired by various JavaOne demos using JavaFX 3D, Nick began development integrating them into their existing NetBeans Platform infrastructure.

The 3D scene showing the Sun and Earth objects is all JavaFX 8 3D, demonstrating the use of Phong Material support, along with multiple light and camera objects. Each JavaFX component extends a JFXPanel type, so that each can easily be added to NetBeans Platform TopComponents. Right-clicking an item in the explorer view offers a context menu that animates and centers the 3D scene on the selected celestial body. 

With each JavaFX scene component wrapped in a JFXPanel, they can easily be integrated into a NetBeans Platform Visual Library scene.  In this case, Nick and Sean are using an instance of their custom Slipstream PinGraphScene, which is an extension of the NetBeans Platform VMDGraphScene.

Now, via the NetBeans Platform Visual Library, the OrbitFX celestial body viewer can be used in the same space as a WorldWind viewer, which is provided by a previously developed plugin.

"This is a clear demonstration of the power of the NetBeans Platform as an application development framework," says Sean Phillips. "How else could you have so much rich application support placed literally side by side so easily?"

Tuesday Oct 15, 2013

YouTube: Eye-Tracking Data Visualization on the NetBeans Platform

A very interesting (silent) screencast shared in the comments to this blog yesterday by Paul Orlov from St. Petersburg State Polytechnical University, shows the visualization of data in a NetBeans Platform application for an eye-tracking study. Related to that, read this very interesting PDF document in the same domain, i.e., investigating the role of peripheral vision in visual attention in programming.

Anyway, the screencast itself is too good not to share with the world:

Of course, the charts that you see in the screencast come from JavaFX.

Saturday Oct 12, 2013

Improve Office Productivity with JavaFX and the NetBeans Platform

CaseLnk Case Management System, by CaseForge Technology, is a brand new piece of software for improving office productivity, user collaboration, and customer satisfaction. It supports cases, documents, tasks, events, processes, and contacts.

The technologies used are Java 7 with NetBeans Platform 7.3 and JavaFX.

NetBeans Visual Library API is used to design workflows:

The Case Editor window to input case information:

A window integrated with JavaFX for displaying weekly tasks and events:

JavaFX chart is used in reporting:

Much more info, including free trial and YouTube movies:

Friday Oct 04, 2013

EPUB Tool Fosfor Lives On (Part 1)

There have been some questions recently about Fosfor, the open source EPUB tool that I started creating some time ago. Well, it's been rearchitected from scratch and now includes the WYSIWYG editor based on JavaFX that I blogged about over the past days:

I ended up abandoning the WebView and went with the HTMLEditor, despite its problems, e.g., problems displaying images within HTML. Hoping to workaround that somehow, right now hardcoded for the screenshot above, probably need a File Protocol URLStreamHandler.

More info about this in the coming days and I will be updating the open source repository as well with all the new code.

Wednesday Oct 02, 2013

Thanks JavaFX: WYSIWYG HTML Editor for NetBeans IDE

In this very short screencast (a mere 44 seconds), you see one of my personal holy grails has come along quite far. It shows an initial implementation of integration between the JavaFX HTMLEditor component and the NetBeans IDE HTML Source Editor. Two way editing, synchronized between the two views (visual and source) is successfully demonstrated.

However, rather than rewriting the entire source file when a change is made in the JavaFX HTMLEditor, which is what currently happens, and which explains the slight delay when switching to the source view, it would be better if only the change were to be written into the file. That's the next step in this integration and probably the most challenging one.

The key pieces of this solution, following on from my blog entry from yesterday, where "obj" is the FileObject that the MultiViewElement is viewing to the user:

public void componentDeactivated() {
    FileLock fileLock = null;
    OutputStreamWriter osw;
    try {
        fileLock = obj.lock();
        OutputStream fout = obj.getOutputStream(fileLock);
        OutputStream bout = new BufferedOutputStream(fout);
        osw = new OutputStreamWriter(bout, "UTF-8");
    } catch (IOException ex) {
    } finally {
        if (fileLock != null) {

The above writes the current content of the JavaFX HTMLEditor into the file when the user switches to the source view.

In addition, I have implemented org.openide.filesystems.FileChangeListener on the MultiViewElement, with this implementation of fileChanged:

public void fileChanged(final FileEvent fe) {
    Platform.runLater(new Runnable() {
        public void run() {
            try {
            } catch (IOException ex) {

Friday Aug 23, 2013

JavaFX 8 DatePicker with Lambdas in NetBeans IDE 7.4

The JavaFX 8 API, which is bundled with JDK 8, contains a new UI control known as the DatePicker. The video below by Jim Weaver demonstrates how to use NetBeans IDE 7.4 Beta to create a JavaFX application from scratch that contains a DatePicker. It also touches on using Java lambda expressions to simplify event handling. In addition, the new date/time API is discussed, and the JFXtras CalendarPicker is demonstrated.

The blog post associated with this video is located in Jim Weaver's Rich-Client Java Blog at the following URL:

Monday Aug 19, 2013

Yet Another NetBeans Platform Application: Oracle SQL Developer Data Modeler 4.0

Yup, there's another NetBeans Platform application in Oracle's software stable. And it is Oracle SQL Developer Data Modeler 4.0:

Interesting that one can create diagrams and then export them. Maybe someone should look at those export formats and see whether one or more of them could be imported into NetBeans IDE and then converted into Java classes, methods, and so forth. At least the CSV format looks promising.

The flexible window system, as with Oracle SQL Developer 4.0 and Oracle JDeveloper 12c, is the NetBeans Platform window system, made possible by the fact that Oracle SQL Developer Data Modeler 4.0 is now integrated into the NetBeans Platform too, as evidenced by the NetBeans artifacts that you'll find in the installation directory:


Geertjan Wielenga (@geertjanw) is a Principal Product Manager in the Oracle Developer Tools group living & working in Amsterdam. He is a Java technology enthusiast, evangelist, trainer, speaker, and writer. He blogs here daily.

The focus of this blog is mostly on NetBeans (a development tool primarily for Java programmers), with an occasional reference to NetBeans, and sometimes diverging to topics relating to NetBeans. And then there are days when NetBeans is mentioned, just for a change.


« May 2015