6. Maya code browser
A. What it does
Ever wanted a listing of all your global procedures in your script? And then list all the places where that procedure is used? How about a listing of all the string variables your script is using and where theyre used?
Well, using an existing jEdit plugin this is possible.
If you are writing Maya plugins with jEdit, you can also use this to display functions, macros, variables and Maya API objects.
B. What it needs
The plugin that makes this possible is called CodeBrowser (written by Gerd Knops). The plugin is available at www.jedit.org
CodeBrowser does it magic using another tool called Exuberant CTags available at https://ctags.sourceforge.net
As their site says:
Ctags generates an index (or tag) file of language objects found in source files that allows these items to be quickly and easily located by a text editor or other utility. A tag signifies a language object for which an index entry is available (or, alternatively, the index entry created for that object).
Tag generation is supported for the following languages:
Assembler, AWK, ASP, BETA, Bourne/Korn/Zsh Shell, C, C++, COBOL, Eiffel,
Fortran, Java, Lisp, Lua, Make, Pascal, Perl, PHP, Python, REXX, Ruby, S-Lang,
Scheme, Tcl, Vim, and YACC.
Youll notice that mel is not listed. There is another file included in the .zip file called ctags.cnf. This lists all the regular expressions that will recognize the syntax to make index tags for mel scripts. It also adds a regex for Maya plugin API objects.
C. How to set it upa. First, download the Exuberant Ctags archive file from their site. Unzip and place the directory somewhere. I put it inside the jEdit user settings directory to make finding it easier.
b. Put the CodeBrowser.jar in the jEdit/jars/ directory
c. Put the ctags.cnf in the jEdit user settings directory (Note: this is for Windows
machines. For Linux this could be different and the file might need to be renamed
to .ctags. See the Ctags docs.)
d. Now we need to tell CodeBrowser where Ctags is. Open jEdit and go to the plugin options page:
Plugins/Plugin Options/CodeBrowser
e. In the ctags Path: text field, fill in the path to the executable you remember where you put it?
f. Restart jEdit
D. How to usea. To bring up the window, start it from the /Plugins menu. I like to dock theM*.
window to the bottom of jEdit. Do this by going to:
Utilities/Global Options/Docking
Find the CodeBrowser entry and select bottom. While youre at it, look for
the HyperSearchResults entry and dock it to the right.
b. The Code Browser window has two split panes. The top one is a listing of
all the scripts that are currently open. Selecting one will switch to that buffer.
c. The bottom pane lists the tags for the current buffer. For mel scripts there
will be entries for:i. Global proceduresThe display is current as of the last save of the file. If the file is modified,
ii. Local procedures
iii. Var float
iv. Var integer
v. Var string
either press Parse or save the file to automatically update the listing.
d. Right-clicking on any entry will bring up several options. The most helpful is
the Hypersearch option. Bring up the Hypersearch window to the right. Now
by selecting Hypersearch on an entry, the results will be displayed to the right.
Here you can see what lines in the script reference that entry. Selecting an
entry in the Hypersearch window will put you to that place in the script.
e. Clicking on the True checkbox in the top right corner of the Hypersearch
window will turn on Multiple entry mode. This will keep all past searches
persistant.
f. For any Maya plugin files, CodeBrowser will display Functions, Macros and
Variables. There will also be a listing for Maya Api objects that begin with
Author: rbublitz
Submitted: 2007-05-16 13:58:35 UTC
Tags:
Software: Maya
Views: 45,141
Related Items
-
TTools - Pro - Professional Tools 7.0.0 for Maya (maya script)
$29.99 (USD) -
Curve Tools for Maya 1.3.0 (maya script)
$25.00 (USD) -
Willson Rig with advanced facial controls for Maya 0.1.0
$20.00 (USD) -
Animated Olympic Fire 2014 (Maya) 3D Model
$69.00 (USD) -
t-mobil G1 with android 3D Model
$130.00 (USD) -
Wash-bowl with mirror 3D Model
$20.00 (USD) -
Elephant 3d textured model 3ds max and maya scene files 3D Model
$30.00 (USD) -
Decorative jar with handle 3D Model
$23.00 (USD) -
Quick set panel for Maya 1.0.0 for Maya (maya script)
$20.00 (USD)