Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Platform - User Assistance (UA) » Adding html to search index but not TOC
Adding html to search index but not TOC [message #484552] Tue, 08 September 2009 08:29 Go to next message
Mohamed Hussein is currently offline Mohamed HusseinFriend
Messages: 76
Registered: July 2009
Member
Hello,

I want to add some html documents to the help index of my rcp application,
but I don't want them to appear in the toc.


I have found LuceneSearchProvider and implemented the getAllDocuments()
and since the documents are html, I just delegated the addition to the
index to the default index passed in addDocument()

This worked fine, and the documents appear in search results and not in
toc as expected, but I had issues in trying to open the pages.

1- [Resolved] the id passed to open() method was null.
After looking at the code I found that I need to add a "?id=<id>" to the
url of the documents to get that id back in open().

2- I don't know how to open the documents in the same window that had the
link (if using the internal view docked in eclipse).
I assumed from the javadoc of the open method that returning false will
let the help system try to open the document, but the return value is
ignored in ReusableHelpPart! Is this a bug?

I used PlatformUI.getWorkbench().getHelpSystem().displayHelpResourc e() to
display help, but this always opens the url in external window.

3- Is there a way to get the url associated with the id from the help
system, or do I need to have a map (or use the full url as the id as the
hack I am doing now :-))

4- The tooltip associated with the documents is "null", is there a way to
modify that?

Thanks in advance for your help :-)

Best Regards,
Mohamed.


Best Regards,
Mohamed.
Re: Adding html to search index but not TOC [message #484668 is a reply to message #484552] Tue, 08 September 2009 16:57 Go to previous messageGo to next message
Chris Goldthorpe is currently offline Chris GoldthorpeFriend
Messages: 815
Registered: July 2009
Senior Member
There is an easier way to do this - use the extradir attribute in a toc
entry.

See
http://help.eclipse.org/galileo/topic/org.eclipse.platform.d oc.isv/reference/extension-points/org_eclipse_help_toc.html

for more information.

Mohamed Hussein wrote:
> Hello,
>
> I want to add some html documents to the help index of my rcp
> application, but I don't want them to appear in the toc.
>
>
> I have found LuceneSearchProvider and implemented the getAllDocuments()
> and since the documents are html, I just delegated the addition to the
> index to the default index passed in addDocument()
>
> This worked fine, and the documents appear in search results and not in
> toc as expected, but I had issues in trying to open the pages.
>
> 1- [Resolved] the id passed to open() method was null.
> After looking at the code I found that I need to add a "?id=<id>" to the
> url of the documents to get that id back in open().
>
> 2- I don't know how to open the documents in the same window that had
> the link (if using the internal view docked in eclipse).
> I assumed from the javadoc of the open method that returning false will
> let the help system try to open the document, but the return value is
> ignored in ReusableHelpPart! Is this a bug?
>
> I used PlatformUI.getWorkbench().getHelpSystem().displayHelpResourc e()
> to display help, but this always opens the url in external window.
>
> 3- Is there a way to get the url associated with the id from the help
> system, or do I need to have a map (or use the full url as the id as the
> hack I am doing now :-))
>
> 4- The tooltip associated with the documents is "null", is there a way
> to modify that?
>
> Thanks in advance for your help :-)
>
> Best Regards,
> Mohamed.
>
Re: Adding html to search index but not TOC [message #484991 is a reply to message #484668] Thu, 10 September 2009 07:30 Go to previous message
Mohamed Hussein is currently offline Mohamed HusseinFriend
Messages: 76
Registered: July 2009
Member
THANKS a lot Chris, this worked perfectly.


"Chris Goldthorpe" <cgold@us.ibm.com> wrote in message
news:h862dd$2ve$1@build.eclipse.org...
> There is an easier way to do this - use the extradir attribute in a toc
> entry.
>
> See
> http://help.eclipse.org/galileo/topic/org.eclipse.platform.d oc.isv/reference/extension-points/org_eclipse_help_toc.html
>
> for more information.
>
> Mohamed Hussein wrote:
>> Hello,
>>
>> I want to add some html documents to the help index of my rcp
>> application, but I don't want them to appear in the toc.
>>
>>
>> I have found LuceneSearchProvider and implemented the getAllDocuments()
>> and since the documents are html, I just delegated the addition to the
>> index to the default index passed in addDocument()
>>
>> This worked fine, and the documents appear in search results and not in
>> toc as expected, but I had issues in trying to open the pages.
>>
>> 1- [Resolved] the id passed to open() method was null.
>> After looking at the code I found that I need to add a "?id=<id>" to the
>> url of the documents to get that id back in open().
>>
>> 2- I don't know how to open the documents in the same window that had the
>> link (if using the internal view docked in eclipse).
>> I assumed from the javadoc of the open method that returning false will
>> let the help system try to open the document, but the return value is
>> ignored in ReusableHelpPart! Is this a bug?
>>
>> I used PlatformUI.getWorkbench().getHelpSystem().displayHelpResourc e() to
>> display help, but this always opens the url in external window.
>>
>> 3- Is there a way to get the url associated with the id from the help
>> system, or do I need to have a map (or use the full url as the id as the
>> hack I am doing now :-))
>>
>> 4- The tooltip associated with the documents is "null", is there a way to
>> modify that?
>>
>> Thanks in advance for your help :-)
>>
>> Best Regards,
>> Mohamed.
>>


Best Regards,
Mohamed.
Re: Adding html to search index but not TOC [message #623548 is a reply to message #484552] Tue, 08 September 2009 16:57 Go to previous message
Chris Goldthorpe is currently offline Chris GoldthorpeFriend
Messages: 815
Registered: July 2009
Senior Member
There is an easier way to do this - use the extradir attribute in a toc
entry.

See
http://help.eclipse.org/galileo/topic/org.eclipse.platform.d oc.isv/reference/extension-points/org_eclipse_help_toc.html

for more information.

Mohamed Hussein wrote:
> Hello,
>
> I want to add some html documents to the help index of my rcp
> application, but I don't want them to appear in the toc.
>
>
> I have found LuceneSearchProvider and implemented the getAllDocuments()
> and since the documents are html, I just delegated the addition to the
> index to the default index passed in addDocument()
>
> This worked fine, and the documents appear in search results and not in
> toc as expected, but I had issues in trying to open the pages.
>
> 1- [Resolved] the id passed to open() method was null.
> After looking at the code I found that I need to add a "?id=<id>" to the
> url of the documents to get that id back in open().
>
> 2- I don't know how to open the documents in the same window that had
> the link (if using the internal view docked in eclipse).
> I assumed from the javadoc of the open method that returning false will
> let the help system try to open the document, but the return value is
> ignored in ReusableHelpPart! Is this a bug?
>
> I used PlatformUI.getWorkbench().getHelpSystem().displayHelpResourc e()
> to display help, but this always opens the url in external window.
>
> 3- Is there a way to get the url associated with the id from the help
> system, or do I need to have a map (or use the full url as the id as the
> hack I am doing now :-))
>
> 4- The tooltip associated with the documents is "null", is there a way
> to modify that?
>
> Thanks in advance for your help :-)
>
> Best Regards,
> Mohamed.
>
Re: Adding html to search index but not TOC [message #623551 is a reply to message #484668] Thu, 10 September 2009 07:30 Go to previous message
Mohamed Hussein is currently offline Mohamed HusseinFriend
Messages: 76
Registered: July 2009
Member
THANKS a lot Chris, this worked perfectly.


"Chris Goldthorpe" <cgold@us.ibm.com> wrote in message
news:h862dd$2ve$1@build.eclipse.org...
> There is an easier way to do this - use the extradir attribute in a toc
> entry.
>
> See
> http://help.eclipse.org/galileo/topic/org.eclipse.platform.d oc.isv/reference/extension-points/org_eclipse_help_toc.html
>
> for more information.
>
> Mohamed Hussein wrote:
>> Hello,
>>
>> I want to add some html documents to the help index of my rcp
>> application, but I don't want them to appear in the toc.
>>
>>
>> I have found LuceneSearchProvider and implemented the getAllDocuments()
>> and since the documents are html, I just delegated the addition to the
>> index to the default index passed in addDocument()
>>
>> This worked fine, and the documents appear in search results and not in
>> toc as expected, but I had issues in trying to open the pages.
>>
>> 1- [Resolved] the id passed to open() method was null.
>> After looking at the code I found that I need to add a "?id=<id>" to the
>> url of the documents to get that id back in open().
>>
>> 2- I don't know how to open the documents in the same window that had the
>> link (if using the internal view docked in eclipse).
>> I assumed from the javadoc of the open method that returning false will
>> let the help system try to open the document, but the return value is
>> ignored in ReusableHelpPart! Is this a bug?
>>
>> I used PlatformUI.getWorkbench().getHelpSystem().displayHelpResourc e() to
>> display help, but this always opens the url in external window.
>>
>> 3- Is there a way to get the url associated with the id from the help
>> system, or do I need to have a map (or use the full url as the id as the
>> hack I am doing now :-))
>>
>> 4- The tooltip associated with the documents is "null", is there a way to
>> modify that?
>>
>> Thanks in advance for your help :-)
>>
>> Best Regards,
>> Mohamed.
>>


Best Regards,
Mohamed.
Previous Topic:Context Sensitive Help problems
Next Topic:Add pdf files to search index
Goto Forum:
  


Current Time: Sun Dec 08 19:04:03 GMT 2024

Powered by FUDForum. Page generated in 0.03066 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top