I decided to use your small framework for my project. I created a class which extends AbstracePluggableGUIApplication and I was ttrying to add a dockable window at startup but I don't no how to do that. I tried to call in the predisplazinit method ((DockableWindowPanel)mainContentPanel).addDockableWindow() but it doesn't changed anything. The dockable window which I gives the method as parameter has not been showed. Could you tell me how to add a window to the application?

Also I don't no how to write the code for savings ccommon properties of the window llike location and so oon. I subclassed GUIApllicationPreferences and I put the path into the getPreferencesClassName method of the aapplication but eac. Time I load the application it uses the default ones. Is that a bug?

Awesome, it's very cool that you're using this stuff! I'm not sure many people actually use the library framework in fife.common.jar besides me. Because of that, I'm sure it's way more difficult to use than it needs to be.

Glad you figured out how to add dockable windows. The AbstractPluggableGUIApplication only exposes an addPlugin() method, so you had to do some ugly casting to add just a dockable window. There's one example of something that should be doable via a simple method. Also I suppose DockableWindows should default to "active"?

Loading and saving preferences is one of the worst parts of the library. The loading of preferences is automatic, and the setting of all the built-in fields of GUIApplicationPreferences is also automatic - window location & size, LookAndFeel, etc. But any app-specific preferences you define in your GUIApplicationPreferences subclass must be set yourself, usually from your preDisplayInit override (cast the GUIApplicationPreferences to your concrete type and use it).

Saving of the preference values is not automatic, however. You have to create an instance of your concrete GUIApplicationPreferences subclass yourself and call its savePreferences() method. Probably the best thing to do is look at how RText does it:

Override the doExit() method and save your preferences there.

Have some sort of way to generate the preferences object, and use the Java Preferences API to actually save the stuff (see the RTextPreferences class, particularly the savePreferences() method)

Honestly though, I'd suggest forgoing this route and using the simpler org.fife.ui.app.Prefs class instead. It's what the RText plugins use (see e.g. SourceBrowserPlugin#loadPrefs()/savePreferences() and SourceBrowserPrefs). It's better (in my opinion) because it's simpler than the Java Preferences API, and loads/saves to a simple properties file (doesn't use the registry on Windows). I'm probably going to redo AbstractGUIApplication to use this class instead of what it currently does in the future because it's so much simpler.

I thought: I can use RCP, buts that'. To heavy for a <5MB project. So I just started RText(nice work^^) and tried the dockable window stuff and I was surprised how good it was working. So I decided to use that framework. Sure, it took a while to figure out how to use it but if you know it, it isn't as much complicated as thought.It's a good coded framework, not to heavy and it contains all needed things for a small application.

If you want I could improve the save mechanism, so it will do that automatically, probably I would than also redo the preferences part in AbstractGUIApplication

was working on a similar framework, but I could not create dockable windows, so i stopped working on it.

you ever worked with maven? I'm curious how user think about it... Is it easy to use? Or should I do not work with it?

How I wrote some lines before, if you want, I can improve the library for you. Just reply

Patches for features are always welcome; feel free to drop a patch in the Feature Request section of RText's SourceForge page (select Tracker -> Patches).

As for Maven, I haven't really used it, and I have someone else update RSyntaxTextArea in Maven since I'm too lazy to learn. I'm sure it's worthwhile, especially if you typically work on projects with lots of dependencies, but my personal projects usually aren't large enough to warrant the effort, and at work we use a different (internal) dependency manager.

Also im curious how you are adding syntax highlighting ro a jtextarea. I was looking into the source code but sis not understand much(probably the problem comes from my side).

understand that you create with jflex a parse, that parses the actual line fore you. The parser splittes the line into the the defined tokens. Ok but how are you highlighting them? Does this happen in the rsyntaxsocument with some plaindocument stuff?

ao I could not find the code were rsta knows which parser he should use.