user defined idl_catalog.xml [message #50252] |
Fri, 22 September 2006 08:01  |
sebinjapan
Messages: 14 Registered: June 2004
|
Junior Member |
|
|
Hello,
I use idldoc package developed by M. Galloy and the emacs mode IDLWAVE
developed by JD Smith.
- The first one allowed me to create a nice documentation of my routine
that can be browsed with the idl_assistant.
- The second one has the ability to automatically load the online help for
the nearby IDL routine [M-?]. To do this, it uses the file idl_catalog.xml
provided with IDL (in .../idl/help/online_help).
It would be great if IDLWAVE was able to load the idl_assistant pages I
created with idldoc when looking at my files in emacs. To do this I guess
it would be necessary to create an idl_catalog.xml for my own files. Does
anyone know how to do that?
Thank you for your help,
Sebastien
|
|
|
Re: user defined idl_catalog.xml [message #50316 is a reply to message #50252] |
Tue, 26 September 2006 03:19  |
sebinjapan
Messages: 14 Registered: June 2004
|
Junior Member |
|
|
> Very nice. When you merge your ADP files, do your HTML files go in
> !DIR/help/online_help too? How do you use things if you don't merge
> your ADP files? How does the assistant know where to find your HTML
> files?
I don't move any html files. I create the directory ~/.assistant/src in
which I put only the merged adp file (the directory ~/.assistant is
automatically created by idl_assistant).
To merge the adp files provided by ITTVIS and by IDLDoc, I do
1) for the adp files provided by ITTVIS
- I copy idl.adp from !DIR/help/online_help to ~/.assistant/src/part1.adp
- I change the header part (between <profile> and </profile>) to give my
own name, title, startpage ...
- I define the full path in links by changing all ref=" by
ref="$DIR/help/online_help/ (with $DIR the full path contained in !DIR)
- I suppress the last line containing </assistantconfig>
2) for the adp files provided by IDLDoc
- I copy idl.adp from my own package directory to
~/.assistant/src/part2.adp
- I suppress the header lines until </profile>
- I define the full path in links by changing all ref=" by
ref="$MyPackgageDir (with $MyPackgageDir the full path to IDLDoc)
3) I concatenate part1.adp and part2.adp into ~/.assistant/src/idl.adp
By default, the command "IDL> ?" load the file called "idl.adp" located in
!help_path. So if you call the merged file idl.adp and you define !hep_path
to ~/.assistant/src, "IDL> ?" will automatically launch you own adp file
instead of the default one.
Note: If you don't merge the adp files, you can call the adp file created
by IDLDoc by using the keyword book of online_help. But in that case you
load only one of the adp files. A great solution would be that BOOK accept
string arrays to load several books at the same time. In that case the
merge of the adp file would be useless.
> Right now IDLWAVE only anticipates loading and caching a single XML
> file (the one provided with IDL), but it would be fairly easy to
> extend the framework to look for user-available ones. The question
> is, how to find them, and then how to locate the HTML/ADP files they
> reference? You'll note that the syntax doesn't say anything about
> where the files are:
>
> <ROUTINE name="OPLOT" link="OPLOT.html">
> IDLWAVE simply assumes they are in !DIR/help/online_help. For random
> user XML catalogs, the easiest might be some convention, perhaps an
> additional tag in the XML file, which specifies the default location
> to root the selected files. Perhaps IDLDoc even has a de facto
> convention of this sort already (I haven't used it yet)?
Well... one solution would be do do similar work that I do with the adp
files.
Merge the xml provided by ITTVIS and IDLDoc, define the full path for the
links and put the resulting file in the directory used to define
!help_path.
In that case IDLWAVE should look for files located in !help_path instead
of !DIR/help/online_help
> The other place we could hook this type of information in would be the
> "user catalog", which you may have seen as a bunch of .idlwave_catalog
> files in directories (e.g. AstroLib, etc.). As I alluded, this would
> be easy to do if there was only one URL associated with a given
> routine (e.g. no separate URL for keywords, etc.). Then we'd just
> need to tag that in some way in the file (either with the IDLDoc, or
> separately), and let idlwave_catalog strip that out. This is nice in
> a sense because (from IDLWAVE's point of view), the .idlwave_catalog
> file(s) would then be one stop shopping for routine and associated
> help info.
I know the .idlwave_catalog files because I use them for my own package
:-)
It is true, if Michael do not manage to get back the source of IDLDoc to
be able to create the xml file assocoated to IDLDoc adp file, using the
user catalog" could be a good solution (even if it is not perfect as
keywords will not have their own link).
Another solution would be to make (or get from ITTVIS?) a tool that could
produce the xml file directly from the adp file.
|
|
|
Re: user defined idl_catalog.xml [message #50317 is a reply to message #50252] |
Tue, 26 September 2006 02:22  |
sebinjapan
Messages: 14 Registered: June 2004
|
Junior Member |
|
|
> Very nice. When you merge your ADP files, do your HTML files go in
> !DIR/help/online_help too? How do you use things if you don't merge
> your ADP files? How does the assistant know where to find your HTML
> files?
I don't move any html files. I create the directory ~/.assistant/src in
which I put only the merged adp file (the directory ~/.assistant is
automatically created by idl_assistant).
To merge the adp files provided by ITTVIS and by IDLDoc, I do
1) for the adp files provided by ITTVIS
- I copy idl.adp from !DIR/help/online_help to ~/.assistant/src/part1.adp
- I change the header part (between <profile> and </profile>) to give my
own name, title, startpage ...
- I define the full path in links by changing all ref=" by
ref="$DIR/help/online_help/ (with $DIR the full path contained in !DIR)
- I suppress the last line containing </assistantconfig>
2) for the adp files provided by IDLDoc
- I copy idl.adp from my own package directory to
~/.assistant/src/part2.adp
- I suppress the header lines until </profile>
- I define the full path in links by changing all ref=" by
ref="$MyPackgageDir (with $MyPackgageDir the full path to IDLDoc)
3) I concatenate part1.adp and part2.adp into ~/.assistant/src/idl.adp
By default, the command "IDL> ?" load the file called "idl.adp" located in
!help_path. So if you call the merged file idl.adp and you define !hep_path
to ~/.assistant/src, "IDL> ?" will automatically launch you own adp file
instead of the default one.
Note: If you don't merge the adp files, you can call the adp file created
by IDLDoc by using the keyword book of online_help. But in that case you
load only one of the adp files. A great solution would be that BOOK accept
string arrays to load several books at the same time. In that case the
merge of the adp file would be useless.
> Right now IDLWAVE only anticipates loading and caching a single XML
> file (the one provided with IDL), but it would be fairly easy to
> extend the framework to look for user-available ones. The question
> is, how to find them, and then how to locate the HTML/ADP files they
> reference? You'll note that the syntax doesn't say anything about
> where the files are:
>
> <ROUTINE name="OPLOT" link="OPLOT.html">
> IDLWAVE simply assumes they are in !DIR/help/online_help. For random
> user XML catalogs, the easiest might be some convention, perhaps an
> additional tag in the XML file, which specifies the default location
> to root the selected files. Perhaps IDLDoc even has a de facto
> convention of this sort already (I haven't used it yet)?
Well... one solution would be do do similar work that I do with the adp
files.
Merge the xml provided by ITTVIS and IDLDoc, define the full path for the
links and put the resulting file in the directory used to define
!help_path.
In that case IDLWAVE should look for files located in !help_path instead
of !DIR/help/online_help
> The other place we could hook this type of information in would be the
> "user catalog", which you may have seen as a bunch of .idlwave_catalog
> files in directories (e.g. AstroLib, etc.). As I alluded, this would
> be easy to do if there was only one URL associated with a given
> routine (e.g. no separate URL for keywords, etc.). Then we'd just
> need to tag that in some way in the file (either with the IDLDoc, or
> separately), and let idlwave_catalog strip that out. This is nice in
> a sense because (from IDLWAVE's point of view), the .idlwave_catalog
> file(s) would then be one stop shopping for routine and associated
> help info.
I know the .idlwave_catalog files because I use them for my own package
:-)
It is true, if Michael do not manage to get back the source of IDLDoc to
be able to create the xml file assocoated to IDLDoc adp file, using the
user catalog" could be a good solution (even if it is not perfect as
keywords will not have their own link).
Another solution would be to make (or get from ITTVIS?) a tool that could
produce the xml file directly from the adp file.
|
|
|