Using (Java) Eclipse abilities in other programming language - eclipse

I use Eclipse mainly for LSL (linden Scripting language). The plug-in for this language does not provide things like templates or task-tag recognition. Is there any way that these kind of features in LSL-files (or any other generic file/code for that matter) can be used?

Take look at the XText project. If you can define the grammar of LSL there it will generate full Eclipse plugin for it, complete with syntax Highlighting, code Completion, validation and quick Fixes and more.

Another one to try (one i use myself) is LSL Editor
Full Syntax highlighting, code suggest, and even a off world run time environment. plus able to test multiple scripts by building test objects with prims.
Take a Look :)

LSLForge is being actively maintained, and has most of what you describe. If there's something missing, the developer is always looking for new challenges.

Related

How to setup a new language IDE

At work we are using a proprietary language and to program we are using Notepad++ with a simple code highlight. That is really annoying so, what I want to do is to invest some time to setup a text editor or an existing IDE to support my language.
I've googled a lot and there are so many options and before starting to work I wanna ask to you what is the best choice.
What I want to do is to have, like an IDE, a syntax highlight, a window with the function list tree, with the local function variables inside the same subtree, maybe text autocomplete (if I type "pro" I would like to see the suggestion "procedure" and if I press enter it will write for me something like
procedure "name" {
--code--
}
with the cursor on "name" ready to change it.
etc etc...
Can you suggest me the right path to follow?
Is it to keep using Notepad++? With sourcecookifier? functionlist?
Or I have to change to another text editor?
Or there is some famous IDE like Eclipse, NetBeans etc that allow to easily add my own language?
PS. my language is pretty simple, I don't have complex structures, is Pascal-like. Something like that:
variable int xyz
PROCEDURE asd
BEGIN
END PROCEDURE asd
I would recommend you to stay with Notepad++ and extend it with some plugins and configuration. This would be fairly quick and easy to set up and still give a big win, even though you might not be able to get all the nice features of something like Eclipse. But since you already know the Notepad++ it wouldn't require learning an entirely new tool.
Some plugins that I have found useful
Function List
Light Explorer
XBrackets Lite
There are probably a lot more that can be useful to you.
Notepad++ also got some built in auto-completion functionality that can be enabled in the settings.
Have you evaluated Eclipse XTEXT ?
What is Xtext?
Xtext is a framework for development of programming languages and domain specific languages.
The only IDE I have used for the last few years is Eclipse. There are lots of other IDEs available, also notable and popular is Netbeans. There are many others. It's important to note that all IDEs have their fans, but I can only speak to Eclipse.
Eclipse is a platform, which means it is an application on which you can build other applications. Eclipse provides a framework which you can customize and extend to produce a working application. It takes care of the user interface, preferences storage, modularisation using OSGi, and lots of other things.
Eclipse has facilities to support what you're looking for:
Syntax highlighting in the editor.
The Outline View provides function and variable listing in a tree
Autocompletion and Suggestions (activated by hitting ctrl-space)
Code Templates to fill out files and procedures etc.
The disadvantage is that customising and extending Eclipse to do what you want isn't trivial. Having written a language debugger for Eclipse, I can tell you that leveraging Eclipse's platform helped enormously, but there's a learning curve. You'd essentially have to be coming up with a new set of plugins to provide your highlighting, outlining, autocomplete suggestions and templates (I'm not sure if template support is built into the platform or not).
So I would say, unless you can find some sort of extensible editor for Eclipse - I know Aptana is extensible for tag-based markup - you are probably as well staying with your existing tooling.
Do explore the other IDEs though - I've heard good things about IDEA as well as Netbeans. :)
Good luck!
I can recommend SynWrite editor. Good support for external languages, fully customizable. (Editor of new lexers is there)

Creating a plugin for code hinting

I'm working with an internally-developed scripting language that some prof and his team have created for an academic project. There's documentation that show function signatures of the existing classes, but for outsiders like me, I'm constantly referring to documentation. Also, in the summer, more helpers will join and I bet they will all suffer from the same problem. So I'd like to write something in Eclipse to help with code hinting and completion, like many languages have.
I haven't programmed eclipse add-ons before, so can someone give me hints how I would generally take the function signatures from their documentation and get code hinting from it. I realize I may need to make changes to the documentation to use it for what I need. But any hints or sample projects would be appreciated. I'm not sure how to get started.
You should have a look at Xtext. With Xtext you can define a domain specific language and generate an editor for it. Here you can find a brief tutorial.

perl editor/IDE similar to source insight for C

I have recently started working with Perl. Googling reveals a number of editors but I am unable to find an editor that will help me navigate a large body of Perl source code. One of the features that I am looking for is the ability of the IDE to integrate with different modules and allow me to jump from one to another. If possible, it will also help if one can see the which function calls what.
I used source insight for C programming and it provides these very useful features. Am looking for similar features in perl.
Help appreciated
Have you looked at Padre? It is a Perl IDE developed by the Perl community.
I'm just giving EPIC a chance.
http://www.epic-ide.org/
Its an Eclipse plugin utilizing a mighty IDE. The advantage I see in using EPIC over Padre is the fact that eclipse can do all sorts of languages and I don't have to get used to multiple different editors every time.
Another great aproach for Perl programming is using emacs. Yes ... its old but I had quite some joy while getting into Perl.
cu
Roman
Komodo IDE, from Active State is also quite good. I haven't used any other Perl IDEs so cannot make comparisons. Most of the features that you are looking for I believe are available in Komodo.
On a side note: The feature that I most appreciated in Komodo was visual debugging.
I mainly use jEdit for Perl programming.
The PerlSideKick plugin, allows you to navigate huge Perl modules (mainly just a plugin for the SideKick plugin).
But there's not much to give you that easy Shift+click navigation you get from Eclipse. jEdit is 100% programmable through Beanshell macros (and JavaScript and Python and JRuby...). So, you can do some of this yourself. So there would be work involved.
For example, it been close enough for me to create "Selection macros" that will allow certain actions on the package or name either highlighted or at the caret. For example, open up the module indicated by the package name.
The Navigator plugin will at least remember where you were last across files.
You might be able to do cross-module navigation through one of the tags plugins
So this won't get you all the way you'd want to go, but it will get you some of the way, and for $0.
It has the most configurable source highlighting this side of writing Emacs-LISP.
It does FTP and remote editing cleaner than most editors I've used.
You can build up a library of Beanshell (shorthand Java) scripts that really help you get what you want done.
Just remember that this recommendation comes with caveats. I have found EPIC quite sub-standard for my use.

Is it a good idea to develop an IDE for scala?

I have to choose a sizable (but not too sizable!) project for my next & last term in university. I thought maybe a nice IDE for scala is what the world might need right now :).
Would you like to see an IDE specifically made for scala? Or are you more comfortable using (the already available) plugins for popular (mainly java) IDEs & editors?
What do you think about the whole idea?
P.s. I'd make it open source & would add features one by one, so if it doesn't end in one semester, it won't be a problem from the university perspective.
Actually, not anymore. IntelliJ, Netbeans and Eclipse all have Scala-specific efforts that have more man-hours in it than you could possible start to begin putting in at a last term. And there's two very interesting efforts that were results of projects like that, both of which were made to contribute to any IDE effort: ENSIME and Scala Refactoring.
And, beyond these efforts, most programming editors, such as jEdit or TextMate, also have some Scala support to one degree or another.
So, really, contributing to one of these projects might be a good idea, but making a Scala IDE is not.
For his Masters thesis, Mirko Stocker contributed the refactoring functionality to the Eclipse Scala plugin, see:
http://misto.ch/scala-refactoring-talk-at-scala-days-2010/
Instead of creating an IDE from scratch, why not contribute a major piece of functionality to the Eclipse plugin, all contributions are welcome. For ideas, see tickets.
Or instead of reinventing the wheel.. you can contribute..
http://wiki.netbeans.org/Scala
But I am not sure if it will be somehow enough for your university work. At the same time, as you see, those plug-ins still require a lot of work.
While writing your own IDE you will just trying to solve problems that were already solved and tested. Besides, even if - what kind of IDE is that, which allows you to do
Scala (even if its great) only. So just for simple xml edit of ant file or whatever you will need another tool.
I think Brian Clapper already summed it up nicely.
I'd suggest something like CheckStyle but for Scala might go down well and be reasonable to tackle as a project.
Not a Scala developer but an Eclipse plug-in would probably be a worthy senior project.
Concur. Operating systems, text editors, and IDEs...does the world really need more of them? No. But everyone wants to write one.
If you want to do something useful, as opposed to simply academic, develop an extension for an existing IDE. Eclipse, NetBeans, Komodo, etc. are all nicely extensible through plugins.

Customizability of the IDEs

I am thinking of modifying an existing IDE (Ex : By developing a plugin) to provide support for a proprietary scripting language. I just need to implement few features like syntax highlighting, Autocompleting etc. (i.e the requirements are really simple). What would be the best IDE or Text editor to integrate the feature. As an example if I think to develop an eclipse plugin for that it would be a pain.
What do you think about Notepad ++?
You might want to give the NetBeans Generic Language Framework a try.
NetBeans project called Generic Languages Framework allows you to define a programming language and integrate it to NetBeans IDE. In the first step you should describe the language - lexical part (define tokens using regular expressions) and syntax (grammar rules). In the second step you can define how to visualize this language in NetBeans. You can define colors for tokens (syntax coloring) or folding (based on grammar rules). You can define what parts of this language should be displayed in the navigator, and how to indent this language plus many other features.
This tutorial should guide you through the process of creating new NetBeans module, adding languages support into it, describing lexical and syntax structure of your language and adding support for all standard editor # features for your language.
Notepad++ allows you to define custom syntax highlight files in a very easy way, but it's not a very good solution for auto-completion (look at this SO question).
If you want a real IDE to extend, I suggest you to use Eclipse.
Update: Tutorial on how to develop an Eclipse plugin.
In vim you can easily add your custom syntax highlighting rules by adding another file in the syntax folder; for the details it is best to look at the help.
If I remember correctly notepad++ also allows defining custom syntax files.