Take the 2-minute tour ×
Electrical Engineering Stack Exchange is a question and answer site for electronics and electrical engineering professionals, students, and enthusiasts. It's 100% free, no registration required.

I want to set up my favorite editor in ModelSim. The default behavior is that ModelSim uses its own internal editor, which I don't like.

I've Googled and I've searched the ModelSim User Manual. I figured out that:

  • If you set the EDITOR environment variable, the TCL edit command will use your editor.
  • You can configure the project to execute a custom command when you double-click a file (I've set this custom command to edit %f which opens the file with my editor.

Still, when I double-click a compile error, the default (built-in) editor is opened. This is not what I want.

Is there a global setting so that the internal editor is not used, but my own editor is?

share|improve this question
    
Windows or Linux? –  Brian Carlton Sep 8 '11 at 17:20
    
@Brian I did this on Linux. –  Philippe Sep 9 '11 at 7:21
2  
Have you asked Mentor? –  Martin Thompson May 28 '12 at 14:22
1  
@AndrewKohlsmith: Lots of people use ModelSim for VHDL and Verilog work. –  Brian Carlton Oct 16 '12 at 21:35
1  
@AndrewKohlsmith: "It has nothing to do with electronics or engineering." - That would be true if ModelSim were accounting software or something that is actually unrelated to electronics or engineering. –  Chris Laplante Dec 15 '12 at 17:28
show 4 more comments

1 Answer

Put this in a tcl file somewhere:

proc external_editor {filename linenumber} {
 exec "youreditor" $linenumber $filename &   # edit as required
}
set PrefSource(altEditor) external_editor
share|improve this answer
    
Didn't work. Do you have any documentation on this? –  Philippe Jun 18 '12 at 11:58
    
@Philippe - What did you try? What was the error message? –  trygvis Oct 22 '12 at 0:39
    
I tried executing the Tcl command that Anon gave. No error messages, but no different default editor. It would be great so see some documentation on this "PrefSource" thing that Anon uses. –  Philippe Oct 22 '12 at 6:58
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.