I find the default Mathematica IDE lacking. I am missing a simple project file tree on the left (as in eclipse, visual studio etc.)
The following would be very cool:
All your files (in a given directory) would be displayed in a Mathematica Palette. Clicking them changes to the clicked file or opens it.
Has anyone seen something like this? Can anyone put together a quick proof of concept? It should not be that difficult ...
Answer
as J.M. mentions, the Workbench is an Eclipse plug-in (and is available as such).
Now, to display all files in some directory, you can do this:
SetDirectory["~/Documents/Projects/other/playing"]
(this is an arbitrarily selected directory on my machine). Then define
doSomething[fname_] := CreateWindow[
DialogNotebook[
{
TextCell[fname],
Button["open", NotebookOpen[fname]],
Button["beep", Beep[]],
DefaultButton[]
}
]
]
(this will take as an argument the file name and pop up a dialog asking what to do; I've put in placeholder actions here). Then
Grid[Partition[#, 2] &[
Button[#, doSomething[ToFileName[Directory[], #]]] & /@
FileNames[]]]
gives something like
and clicking on the names brings this up:
Of course this can be greatly elaborated.
Comments
Post a Comment