Chinaunix首页 | 论坛 | 博客
  • 博客访问: 713069
  • 博文数量: 112
  • 博客积分: 10010
  • 博客等级: 上将
  • 技术积分: 1192
  • 用 户 组: 普通用户
  • 注册时间: 2008-03-12 16:46
文章分类

全部博文(112)

文章存档

2009年(4)

2008年(108)

我的朋友

分类: 系统运维

2008-04-16 10:53:44

How to add tcl support in Source Insight for NS2?
2007-10-17 09:06
How to add tcl support in Source Insight?

Author: Weiwei (fangvv at gmail dot com)

I use Source Insight (SI) to analyze the source code of NS-2. Unfortunately, I found it didn't support tcl/tk parsing in default application settings. So I tried to add the support to the tcl/tk code for SI.

First, choose Options->Preferences->Languages, add a new language called "TCL Language". Double click that new defined language line to edit its settings. In the opened "TCL Language Properties" dialogue , add "#" in the "Comments and Ranges" tab; click "keywords" button in the "Options" tab, add the tcl/tk keywords, you can just import the keywords from predefined files , the syntax is like the following:

elseif, Keyword

SYNTAX: the_keyword+", Keyword" [Return]

I add the keywords as those defined in Editplus tcl/tk user file. It can be downloaded from

Then, choose Options->Document Options. In the opened dialogue, add a new type called "TCL Source File", the filter is :*.tcl. Remember to select the "Include when adding to projects" to make tcl file imported into your source code in SI next time. Choose the Language as "TCL Language" you defined in the above step, you can try to verify it by clicking the button "Language..".

After that, Re-import your NS-2 source code and check if the tcl files have been imported into the analysis project.

Any problem, email me:)
阅读(1392) | 评论(1) | 转发(0) |
给主人留下些什么吧!~~

chinaunix网友2008-05-07 10:43:12

This way has some limitation. Now you can use the legacy support from Source Insight website. Search tcl.CLF and you will get it.