Running Eclipse as a Tcl IDE with the DLTK plugin.


Installation Instructions.

A.      Install Eclipse 3.2.

Download Eclipse 3.2 from www.eclipse.org and install to a local directory following the normal install procedures. 

B.      Install Eclipse Tcl Plugin.   

Download the Eclipse Tcl plugin from http://www.eclipsedltk.org/download and install into Eclipse.

Select Eclipse DLTK 0.7 Milestone 5.





Download eclipse-dltk-runtime-1.0M5.zip and eclipse-dltk-tcl-1.0M5.zip.

Unzip the files and copy the embedded eclipse directory over your Eclipse install directory.

E.G

copy C:\downloads\eclipse\dltk\eclipse-dltk-runtime-1.0M5\eclipse to C:\eclipse

copy C:\downloads\eclipse\dltk\eclipse-dltk-tcl-1.0M5\eclipse to C:\eclipse

Check that the plugin and features have been installed.

C:\eclipse\features>dir *dltk*

19/04/2007 18:41 <DIR> org.eclipse.dltk.runtime_1.0.0.v200701030716
19/04/2007 18:42 <DIR> org.eclipse.dltk.tcl_1.0.0.v200701030716

C:\eclipse\plugins>dir *dltk*

03/01/2007 07:18 40,200 org.eclipse.dltk.console.ui_1.0.0.v200701030716.jar
03/01/2007 07:18 17,981 org.eclipse.dltk.console_1.0.0.v200701030716.jar
03/01/2007 07:18 1,307,170 org.eclipse.dltk.core_1.0.0.v200701030716.jar
03/01/2007 07:18 264,086 org.eclipse.dltk.debug.ui_1.0.0.v200701030716.jar
03/01/2007 07:18 129,958 org.eclipse.dltk.debug_1.0.0.v200701030716.jar
03/01/2007 07:18 120,079 org.eclipse.dltk.launching_1.0.0.v200701030716.jar
03/01/2007 07:18 108,460 org.eclipse.dltk.tcl.core_1.0.0.v200701030716.jar
03/01/2007 07:18 63,402 org.eclipse.dltk.tcl.debug.ui_1.0.0.v200701030716.jar
03/01/2007 07:18 3,861 org.eclipse.dltk.tcl.debug_1.0.0.v200701030716.jar
03/01/2007 07:18 24,586 org.eclipse.dltk.tcl.launching_1.0.0.v200701030716.jar
03/01/2007 07:18 42,636 org.eclipse.dltk.tcl.tclchecker_1.0.0.v200701030716.jar
03/01/2007 07:18 179,442 org.eclipse.dltk.tcl.ui_1.0.0.v200701030716.jar
03/01/2007 07:18 2,748,528 org.eclipse.dltk.ui_1.0.0.v200701030716.jar

C. Setup Tcl DLTK.

Create a workspace.

mkdir
C:\home\patrick\eclipseWorkspace\DLTK
Start Eclipse.

C:\eclipse32TestDLTk\eclipse.exe -showlocation -data C:\eclipseworkspaces\DLTK

Select window--->> preferences.





Select DLTK Debug.



This shows the default ports and connection timeout for the debugger.

Select DLTK Tcl.




Select Debug in this dialog.





Enter the path to the DBGP debugger. Note that
the Active State Komodo dbgp_tcldebug.exe is the only currently supported debugger for DLTK and
you MUST have a commercial Komodo licence to use
dbgp_tcldebug.exe

C:\Program Files\ActiveState Komodo IDE 4.0\lib\support\tcl\dbgp_tcldebug.exe

Select "Man Pages Locations"

This option provides context sensitive help when in edit mode. Download the Tcl manual pages from http://tcl.activestate.com/man.

Enter the full path to the documentation for each command set.





Select Tcl Interpreters.







Enter the path or browse to your Tcl install directory and select the executable you want to use.

e.g C:\Tcl\bin\tclsh84.exe





DLTK searchs for library locations. The search is CPU instensive and can take a while.




 



Select OK.




Add more interpreters if you wish and select one as default. Later on you can select a default intepreter for each Tcl project in the workspace.

Select and enter a path to the TclChecker binary.





TclChecker comes with the Tcl Development Kit and you must have a licensed copy.


Usage.


Set up a new Tcl project.

file --->> new --->> project --->>

Select Tcl Project.





Select next.





Name the project TKCVS and use the default interpreter.





Select next.



Accept the defaults and select finish.





Select yes to associate the project with a Tcl perspective.  The project is created and the  Tcl  perspective opens.

Download  TKCVS from sourceforge :  http://sourceforge.net/search/?type_of_search=soft&words=tkcvs and install it using the supplied doinstall.tcl.

Select file --->> import.




Expand general and select file system.




Select next.




Select the directories for import and select finish.

Expand bin and select tkcvs.tcl.



Right click on tkcvs and select "open with "DLTK Tcl editor".





Features.

Code Outline.

DLTK displays a code outline in the right hand segment of the display which shows procedures and variables that can be used to navigate through the code.




Code Completion.

There is limited code completetion for the main Tcl commands.   "ctrl  space".




Open Declaration

Eclipse will navigate to the selected namespace or procedure when the item is highlighted.  Right click or PF3.

e.g open TkCVS.tcl and do a find on "::"

 

Highlight "::picklist::load" and select PF3.  Eclipse opens picklist.tcl in a new tab.





In picklist.tcl right click  "::picklist::load" and select call hierarchy.  Members in the workspace that call ::picklist::load are displayed.





TclChecker.

Enable TclChecker by right  clicking on the project and selecting "enable TclChecker".  TclChecker will then run through the whole project and display warnings and errors in the "problems" tab.   Right click on the warning or error and select "Go To".  Eclipse opens the file containing the error in a new tab. 


 

TclChecker checks the syntax of individual files when they are saved and displays an error indicator in the code. . 




Debugger.