MATLAB Answers

Force doc command to open a specified reference HTML page

2 views (last 30 days)
Sam Roberts
Sam Roberts on 2 May 2012
Say I've written a class in a package, called mypackage.myclass.
I've written my own HTML documentation for the package and the class, and have included this within the MATLAB help browser as described in the MATLAB documentation.
I can display this HTML documentation by using the help browser to navigate directly to it, but typing
doc mypackage.myclass
does not display it; instead it displays some HTML documentation that is auto-generated by helpwin (which is a nice feature, but not what I want - the auto-generated documentation is too techy for my users).
How can I force doc to display my documentation, rather than the auto-generated documentation?
When you run
doc docTopic
inside the doc command, the Java class
gets called. If a reference page for docTopic exists, it displays it and returns a success value. If a reference page doesn't exist, it returns a failure value, which then causes helpwin(docTopic) to get called. Somewhere there must be some catalog, used by the Java class, that connects values of the string docTopic with individual reference HTML files. How can I fiddle with that catalog - or can I create one for my package?
MathWorkers and Yair, please give me enough undocumented rope to hang myself with :)


Sign in to comment.

Answers (0)


Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!