Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 200117

Summary: [api] support spell checking and hyperlink detection in the source editor of the Wiki Page Editor
Product: z_Archived Reporter: Xiaoyang Guan <xbugzilla>
Component: MylynAssignee: Xiaoyang Guan <xbugzilla>
Status: RESOLVED FIXED QA Contact:
Severity: enhancement    
Priority: P3 CC: robert.elves, steffen.pingel
Version: unspecified   
Target Milestone: 2.1   
Hardware: All   
OS: All   
Whiteboard:
Attachments:
Description Flags
add spell checking and hyperlinking to Wiki page editor
none
mylyn/context/zip
none
make RepositoryViewerConfig public API and rename to TaskTextViewerConfig
none
mylyn/context/zip none

Description Xiaoyang Guan CLA 2007-08-15 17:47:08 EDT
One easy way is to use the RepositoryViewerConfig for the SourceViewer in the editor. A problem is that RepositoryViewerConfig is defined in the org.eclipse.mylyn.internal.tasks.ui.editors package. Can we make it public API?
Comment 1 Robert Elves CLA 2007-08-16 15:28:43 EDT
I don't see why we can move it into tasks.ui.  I imagine we should have a better way of contributing rules to the RepositoryTextScanner though. Steffen what are your thoughts on this?
Comment 2 Eugene Kuleshov CLA 2007-08-16 16:57:14 EDT
that scanner thing need to be replaced with something that would use hyperlink detectors instead...
Comment 3 Steffen Pingel CLA 2007-08-19 15:53:26 EDT
Is the only purpose of RepositoryTextScanner to provide syntax highlighting for hyperlinks? It seems that we need to add a way for connectors to contribute rules if that is the case, optimally based on the existing hyperlink detectors as Eugene suggested.

I don't see any reason not to make RepositoryViewerConfig public API though (the class should probably be renamed to TaskSourceViewerConfiguration or something like that).
Comment 4 Eugene Kuleshov CLA 2007-08-19 20:44:01 EDT
What is the use case for making RepositoryViewerConfig API? currently it is only used internally by the TaskFormPage.
Comment 5 Steffen Pingel CLA 2007-08-19 22:57:25 EDT
It's needed for the wiki editor.
Comment 6 Robert Elves CLA 2007-08-20 17:13:37 EDT
 (In reply to comment #3)
> Is the only purpose of RepositoryTextScanner to provide syntax highlighting for
> hyperlinks? It seems that we need to add a way for connectors to contribute
> rules if that is the case, optimally based on the existing hyperlink detectors
> as Eugene suggested.

Agreed, at the moment it is a hard coded mess.
 
> I don't see any reason not to make RepositoryViewerConfig public API though (the
> class should probably be renamed to TaskSourceViewerConfiguration or something
> like that).
How about TaskTextViewerConfiguration?
Comment 7 Steffen Pingel CLA 2007-08-20 17:46:45 EDT
> Agreed, at the moment it is a hard coded mess.

I opened bug 200613.

> How about TaskTextViewerConfiguration?

Sounds good.
Comment 8 Xiaoyang Guan CLA 2007-08-21 15:02:25 EDT
Created attachment 76576 [details]
add spell checking and hyperlinking to Wiki page editor

This patch uses RepositoryViewerConfig, which should be replaced with the TaskTextViewerConfiguration as discussed above once it becomes public API.
Comment 9 Xiaoyang Guan CLA 2007-08-21 15:02:28 EDT
Created attachment 76577 [details]
mylyn/context/zip
Comment 10 Steffen Pingel CLA 2007-08-21 18:26:22 EDT
Created attachment 76588 [details]
make RepositoryViewerConfig public API and rename to TaskTextViewerConfig

Rob, please apply.
Comment 11 Steffen Pingel CLA 2007-08-21 18:26:24 EDT
Created attachment 76589 [details]
mylyn/context/zip
Comment 12 Steffen Pingel CLA 2007-08-21 18:47:24 EDT
Rob, please apply my patch and I'll refactor Xiaoyang's patch for the new API.

Xiaoyang, I'll assign all tasks to you that you have contributed to. It's the Mylyn way of recognizing contributions and earning responsibility.
Comment 13 Xiaoyang Guan CLA 2007-08-21 21:01:05 EDT
(In reply to comment #12)
> Xiaoyang, I'll assign all tasks to you that you have contributed to. It's the
> Mylyn way of recognizing contributions and earning responsibility.

Sure, and if you prefer, I could do the refactoring and update the patch.
Comment 14 Robert Elves CLA 2007-08-22 17:21:21 EDT
 (In reply to comment #12)
> Rob, please apply my patch and I'll refactor Xiaoyang's patch for the new API.
Patch applied.
Comment 15 Steffen Pingel CLA 2007-08-22 18:51:28 EDT
Committed spell checking and hyperlinking support to new wiki plug-in in CVS.