Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Platform - User Assistance (UA) » can i have several eclipse help files/archives into a single eclipse plugin(How can i have several eclipse help files/archives into one single plugin)
can i have several eclipse help files/archives into a single eclipse plugin [message #633028] Fri, 15 October 2010 03:24 Go to next message
xavier locquet vandenberghe is currently offline xavier locquet vandenberghe
Messages: 2
Registered: October 2010
Junior Member
goal
How can i have several eclipse help files/archives into one single plugin

Background
My current eclipse help system contains a single doc.zip file.
If several help files were required, i was either creating an other plugin with identical structure or i merged the several helps into a single doc.zip and having an enumeration of the several toc in the plugin.xml and the toc.xml
you can find extracts of the file below.

Lately i got several eclipsehelp files. They have their toc inside the archive itself and do not have to be named doc.zip.
Someone working on the infocenter mentionned their preferenceCustomization.
The help archives are dropped into a directory... and if order is important, then the helpData.xml is modified... but that's it.

I tried to modify my existing files so they would reflect the infocenter's one.
unfortunatly without much succcess.

Questions
I was wondering:
- does this preferenceCustomization working for eclipse desktop sdk or is it something reserved to infocenter?
- What are the difference to make something that is working on info center , working on eclipse desktop sdk
- ultimately, the idea is to have several eclipsehelp files in one plugin... is there an other way than preferenceCustomization

Regards,
Xavier

existing working files for the project are found in the directory
eclipse\dropins\plugins\myhelp

doc.zip
myhelptoc.xml
toc.xml
plugin.xml


plugin.xml
<?xml version="1.0" encoding="UTF-8"?>
<?eclipse version="3.0"?>
<plugin>
<extension point="org.eclipse.help.toc">
<toc file="toc.xml" primary="true" />
<toc file="myhelptoc.xml" primary="false" />
</extension>
</plugin>


toc.xml
<?xml version="1.0" encoding="utf-8"?>
<!--Arbortext, Inc., 1988-2004, v.4002-->
<?APT Element gi="toc" attrs="label"?>
<?APT Element gi="link" empty="yes" attrs="toc"?>
<?eclipse version="3.3"?>
<?NLS TYPE="org.eclipse.help.toc"?>
<toc label="My help">
<link toc="myhelptoc.xml"/>
<topic label="some other topic">
<link toc="../an.other.plugin/eclipsehelp/toc.xml"/>
</topic>
</toc>



myhelptoc.xml
<?xml version="1.0" encoding="utf-8"?>
<!--Arbortext, Inc., 1988-2004, v.4002-->
<?APT Element gi="toc" attrs="label"?>
<?APT Element gi="topic" attrs="label href"?>
<?eclipse version="3.0"?><?NLS TYPE="org.eclipse.help.toc"?>
<toc label="My Help">
<topic label="Overview" href="myhelptoc//docs/content0.htm">
<topic label="Description" href="myhelptoc//docs/content1.htm">

...
Re: can i have several eclipse help files/archives into a single eclipse plugin [message #634232 is a reply to message #633028] Wed, 20 October 2010 17:10 Go to previous messageGo to next message
Chris Goldthorpe is currently offline Chris Goldthorpe
Messages: 815
Registered: July 2009
Senior Member
First of all doc.zip is somewhat obsolete. It was useful in the days before plug-ins could be built as jar files as it was the only way to compress documentation but now if you want compression the best practice is to build plug-ins as jar files.

Second you can have as many books as you want in a single plug-in, you just have to make sure that there is a line like this for each top level table of contents:
<toc file="toc.xml" primary="true" />

You don't need preference customization to do this and it works the same way for an infocenter as for the Eclipse SDK.
Re: can i have several eclipse help files/archives into a single eclipse plugin [message #634527 is a reply to message #634232] Fri, 22 October 2010 02:36 Go to previous messageGo to next message
xavier locquet vandenberghe is currently offline xavier locquet vandenberghe
Messages: 2
Registered: October 2010
Junior Member
Hi,
I do suspect, that the single doc.zip file is somehow obsolete... but unfortunatly it does work.

Let's start from the working help. that contains the toc.xml (primary) and few other tocs (non primary)
If i extract the zip file in the plugin directory and remove the doc.zip file, then the help is still working.
moving the various tocs to their respective plugin directories, and chancing toc.xml and plugin.xml to reflect the new locations , still work.(strangely enough it doesn't requires to change the respective sub toc content)
However archiving each directories into their own archive. jar or zip, their toc inside or outside the archive, break thehelp and the file are not visible anymore.

- So eclipse can find the documents when they are in the file doc.zip but not their individual archives
- Someone showed me that info center could handle several archives with this introduction to customisation... but my tests to port it to eclise sdk didn't succeed.

So how could i have several archives, instead of a big doc.zip in the eclipse?
Thanks
Re: can i have several eclipse help files/archives into a single eclipse plugin [message #634740 is a reply to message #634527] Fri, 22 October 2010 18:20 Go to previous message
Chris Goldthorpe is currently offline Chris Goldthorpe
Messages: 815
Registered: July 2009
Senior Member
Looks like there are two different questions here - on about archives and one about splitting the content between plug-ins.

Help content can be read if it is one of three formats

1. As individual files within an uncompressed plugin
2. In doc.zip in an uncompressed plugin
3. As individual files within a plugin created using Export as Deployable Plug-in

Eclipse uses method #3 for the doc plug-ins that are shipped with the Eclipse SDK, such as org.eclipse.platform.doc.user

If you want to avoid creating one large zip ( method 2 ) file or one large jar file ( method 3 ) You need to split the documentation into multiple plug-ins. This works fine but you need to make sure that the syntax is correct in the link if it is to another plug-in, for example

<link toc="/org.eclipse.jdt.doc.user/toc.xml"/>

You had <link toc="../an.other.plugin/eclipsehelp/toc.xml"/> - I don't know if that will work.

Previous Topic:Open CheatSheet when eclipse starts
Next Topic:Infocenter (Tomcat) only locally available - SOLVED
Goto Forum:
  


Current Time: Thu Aug 28 05:24:51 EDT 2014

Powered by FUDForum. Page generated in 0.02134 seconds