Bethan Palmer Bethan is a Java developer and a Java Champion. She has spoken at conferences including JavaOne/Code One, DevFest and NetBeans days. She has a degree in English Literature.

Hacking the NetBeans IDE – 5. Overview for making a Combined Local History

1 min read

To help us prepare for our talks for our talks at Oracle CodeOne – “Writing Better Code (Faster) in the Apache NetBeans IDE [BOF4759]” and “Hacking the NetBeans IDE [BOF4760]”, we have been writing some blog posts on NetBeans. We hope you find them useful…

Displaying multiple Views in a single window

In this part, I am going to pick up from where my colleague Mark Stephens left off and cover the sections we need to change to make a single display with multiple history work.

Last time Mark improved the performAction method in ShowHistoryAction to recursively open multiple files (lines 77-83 in the screenshot below). This is interesting, but I would really like all the changes to appear in a single window. Something like this

NetBeans local history

 

This requires us to make changes in 2 modules:-

Local History

We have already covered editing ShowHistoryAction. We just need to ensure that this will accept multiple nodes and open the display. It does not usually use the HistoryTopComponent for this.

LocalHistoryProvider defines the actions so we will need to change the way RevertFile works and add any new actions. I would like a RevertAll action so I can role all the selected files back to this point (not just one file).

Versioning UI

Because NetBeans abstracts and modularizes its functionality, LocalHistory also makes use of code in this package. The HistoryComponent is the GUI display and contains HistoryFIleView. This is the list and display you see in NetBeans. We need to change the way this works to combine the histories from all selected files into one single list.

We will put all this together in future posts OR we look forward to seeing you at our “Hacking the NetBeans IDE [BOF4760]” next week at CodeOne. Our session is Monday, Oct 22, 8:30 p.m. – 9:15 p.m. | Moscone West – Room 2009



Our software libraries allow you to

Convert PDF files to HTML
Use PDF Forms in a web browser
Convert PDF Documents to an image
Work with PDF Documents in Java
Read and write HEIC and other Image formats in Java
Bethan Palmer Bethan is a Java developer and a Java Champion. She has spoken at conferences including JavaOne/Code One, DevFest and NetBeans days. She has a degree in English Literature.

Creating a WordPress Plugin Part 3: Adding Shortcodes

Recently, I’ve been working on a proof of concept project which integrates our JPDF2HTML5 web service with the popular blogging platform WordPress. This series of...
Simon Lissack
1 min read