With with NetBeans?

General discussion on RText.

Moderator: robert

With with NetBeans?

Postby meersguitarman@yahoo.com » Mon Jan 12, 2009 8:43 pm

I use NetBeans for all my GUI development. I would like to use your synax coloring package, but I've run across an issue with the RTextScrollPane class.

In Netbeans, when I add a JScrollPane, NetBeans instantiates the default constructor. Unfortuantely, RTextScrollPane doesn't have a default constructor.

Then, in the generated code, NetBeans calls the 'setViewportView(component)' method to tie the TextArea field to the scroll pane. For example:

jScrollPane1 = new javax.swing.JScrollPane();
scriptEditorPane = new com.dotomi.common.ui.components.DotomiEditorPane();

This methodology won't work with the RTextScrollPane class. If you could change the RTextScrollPane class to work with NetBeans, that would definitely make me a believer.

Dennis Meers

Re: With with NetBeans?

Postby robert » Tue Jan 13, 2009 4:09 am

Thanks for the bug report!

This is fixed in revision 54 in SVN. Grab it there if you want to test it out. There will also be a minor release a little later this week that will include this fix if you just want to wait for a jar.
User avatar
Posts: 852
Joined: Sat May 10, 2008 5:16 pm

Re: With with NetBeans?

Postby phaniram » Wed Apr 11, 2012 12:18 pm

I'm using rsyntaxtextarea , i've added it to Netbeans palette, here it has two components,

An RSyntaxTextArea is the main text editor class. It extends JTextArea, so it has all the standard methods you'd expect from a Swing text component, plus more specific to handling syntax highlighting.

An RTextScrollPane is an extension of JScrollPane that supports line numbers. You can use a standard JScrollPane if you want, but when editing source code, it is often nice to have line numbering enabled.

I can actually add RSyntaxTextArea by dragging and dropping it from palette, but i cannot do that for RTextScrollPane (it is necessary for RSyntaxTextArea to feel better than existing scroll panel). The error message says that the component cannot be instantiated and that you should make sure it is a JavaBean

i've added it through tools->palette->Swing/AWT Components
even if i've added it to palette, i can't add it through drag & drop, i've added RSyntaxTextArea though, even i've added RTextScrollPane through custom code in it, but i couldn't see that in Inspector or in Application ..

How can i add these two components in netbeans through drag & drop ?

from above post i've seen that it is fixed in some revision, now i've download the latest one , but i can still see the error,

can anyone help me please?
Thanks in advance
Posts: 3
Joined: Wed Apr 11, 2012 12:02 pm

Re: With with NetBeans?

Postby robert » Mon Apr 16, 2012 10:02 pm

This should be fixed in the upcoming 2.0.3, as verified by another user in this thread. So you can either wait for the next release or grab the latest from the SVN repository if you are anxious.
User avatar
Posts: 852
Joined: Sat May 10, 2008 5:16 pm

Return to Open Discussion

Who is online

Users browsing this forum: No registered users and 2 guests