Home   Free Applications   Code Snippets   Fun Stuff 
 
 You are here: Home > Free Applications > NetSpell > Discussion Forum
Register   Login  

 
Site Navigation


Print Print this page
Email E-mail this page
Bookmark Add to Favorites

  Discussion Forum

Author Thread: Got CheckAsYouType working
partnerinflight
Got CheckAsYouType working
Posted: Tuesday, December 06, 2005 9:22 PM (EST)
Hey guys: I've been working on CheckAsYouType for the past few months, and I think I've got it more or less working for RichTextBoxes. (using TOM). I'd like to post it somewhere on this board for people to take a look at, but I'm not sure where. Paul, do you have any objections to me posting the full code drop on my website and putting a link here? (can't seem to find his email anywhere on the site...) Thanks


Comments:

Author Thread:
?
Got CheckAsYouType working
Posted: Tuesday, January 03, 2006 4:01 AM (EST)
I'd be very interested to see that code. Could you post a link please?

partnerinflight
Got CheckAsYouType working
Posted: Thursday, January 05, 2006 11:21 AM (EST)

the link is http://www.partnerinflight.com/netspell.spellchecker.zip

Look inside the CheckAsYouType folder. There's a new RichTextBox override based on TOM; I recommend using that instead of RichTextBox. (However the code will work with RichTextBox as well.)

I've made a couple small changes to Speller.cs -- just windiff it to see what I did. Oh, I've also updated the code to C# 2.0. It shouldn't be too tough to go back to 1.1 if you really need to though.

Let me know if you run into any trouble. I know there are still a couple bugs in there, but none I can reliably reproduce so far. If anyone finds them I'd sure appreciate it.

?
Got CheckAsYouType working
Posted: Friday, January 06, 2006 7:02 AM (EST)
I don't have VS2005 installed (nore .NET2.0 sdk), so I can't compile your code. Do you have a compiled program example I could check out? Thanks

?
Got CheckAsYouType working
Posted: Friday, January 06, 2006 8:29 PM (EST)
http://www.writerslore.com/product/publish.htm

pwelter34
Got CheckAsYouType working
Posted: Saturday, January 07, 2006 11:33 PM (EST)

Hi,

Thanks for adding this support. I've done quite a bit of work to get as you type working as well.  I'll look at what you've done and see how we can merge them together to come up with the next official version of netspell.

thanks,
~ Paul

?
Got CheckAsYouType working
Posted: Sunday, January 08, 2006 11:52 AM (EST)
Sounds good, Paul. The only remaining wrinkle is how CheckAsYouType coexists with RichTextBox's builtin undo functionality. (underlining, even through TOM, is considered an undoable action, so that messes up the undo stack.) I think the only way around it is to draw the underlines ourselves. I tried this without much luck -- RichTextBox must call ScrollWindowContents (or whatever that function is that blits a certain region of a window offset) when you press Return. So the underlines I drew just get moved down once the user presses return. The solution to that is to refresh the whole window on every repaint, but that causes flicker... Sigh. Don't see a way around it. Do you?

?
Got CheckAsYouType working
Posted: Monday, January 09, 2006 4:36 AM (EST)
a bit off topic : Does anyone know how As-You-Type does underlining? It can do underlining in ANY window with text! ...it is crazy. google as-you-type and download trial to check out.

?
Got CheckAsYouType working
Posted: Monday, January 09, 2006 5:30 AM (EST)
Got this error while trying to download the example: What can be wrong? PLATFORM VERSION INFO Windows : 5.1.2600.131072 (Win32NT) Common Language Runtime : 2.0.50727.42 System.Deployment.dll : 2.0.50727.42 (RTM.050727-4200) mscorwks.dll : 2.0.50727.42 (RTM.050727-4200) dfdll.dll : 2.0.50727.42 (RTM.050727-4200) dfshim.dll : 2.0.50727.42 (RTM.050727-4200) SOURCES Deployment url : file:///C:/internet/dnloads/WritersLore.application IDENTITIES Deployment Identity : WritersLore.application, Version=0.0.1.8, Culture=en-US, PublicKeyToken=7ee307e9f8c581c7, processorArchitecture=msil APPLICATION SUMMARY * Installable application. ERROR SUMMARY Below is a summary of the errors, details of these errors are listed later in the log. * Activation of C:\internet\dnloads\WritersLore.application resulted in exception. Following failure messages were detected: + Downloading file:///C:/internet/dnloads/WritersLore_0_0_1_8/WritersLore.exe.manifest did not succeed. + Could not find a part of the path 'C:\internet\dnloads\WritersLore_0_0_1_8\WritersLore.exe.manifest'. + Could not find a part of the path 'C:\internet\dnloads\WritersLore_0_0_1_8\WritersLore.exe.manifest'. + Could not find a part of the path 'C:\internet\dnloads\WritersLore_0_0_1_8\WritersLore.exe.manifest'. COMPONENT STORE TRANSACTION FAILURE SUMMARY No transaction error was detected. WARNINGS There were no warnings during this operation. OPERATION PROGRESS STATUS * [09.01.2006 11:24:44] : Activation of C:\internet\dnloads\WritersLore.application has started. * [09.01.2006 11:24:45] : Processing of deployment manifest has successfully completed. * [09.01.2006 11:24:45] : Installation of the application has started. ERROR DETAILS Following errors were detected during this operation. * [09.01.2006 11:24:45] System.Deployment.Application.DeploymentDownloadException (Unknown subtype) - Downloading file:///C:/internet/dnloads/WritersLore_0_0_1_8/WritersLore.exe.manifest did not succeed. - Source: System.Deployment - Stack trace: at System.Deployment.Application.SystemNetDownloader.DownloadSingleFile(DownloadQueueItem next) at System.Deployment.Application.SystemNetDownloader.DownloadAllFiles() at System.Deployment.Application.FileDownloader.Download(SubscriptionState subState) at System.Deployment.Application.DownloadManager.DownloadManifestAsRawFile(Uri& sourceUri, String targetPath, IDownloadNotification notification, DownloadOptions options, ServerInformation& serverInformation) at System.Deployment.Application.DownloadManager.DownloadApplicationManifest(AssemblyManifest deploymentManifest, String targetDir, Uri deploymentUri, IDownloadNotification notification, DownloadOptions options, Uri& appSourceUri, String& appManifestPath) at System.Deployment.Application.ApplicationActivator.DownloadApplication(SubscriptionState subState, ActivationDescription actDesc, Int64 transactionId, TempDirectory& downloadTemp) at System.Deployment.Application.ApplicationActivator.InstallApplication(SubscriptionState subState, ActivationDescription actDesc) at System.Deployment.Application.ApplicationActivator.PerformDeploymentActivation(Uri activationUri, Boolean isShortcut) at System.Deployment.Application.ApplicationActivator.ActivateDeploymentWorker(Object state) --- Inner Exception --- System.Net.WebException - Could not find a part of the path 'C:\internet\dnloads\WritersLore_0_0_1_8\WritersLore.exe.manifest'. - Source: System - Stack trace: at System.Net.FileWebRequest.EndGetResponse(IAsyncResult asyncResult) at System.Net.FileWebRequest.GetResponse() at System.Deployment.Application.SystemNetDownloader.DownloadSingleFile(DownloadQueueItem next) --- Inner Exception --- System.Net.WebException - Could not find a part of the path 'C:\internet\dnloads\WritersLore_0_0_1_8\WritersLore.exe.manifest'. - Source: System - Stack trace: at System.Net.FileWebResponse..ctor(FileWebRequest request, Uri uri, FileAccess access, Boolean asyncHint) at System.Net.FileWebRequest.WrappedGetResponseCallback(Object state) --- Inner Exception --- System.IO.DirectoryNotFoundException - Could not find a part of the path 'C:\internet\dnloads\WritersLore_0_0_1_8\WritersLore.exe.manifest'. - Source: mscorlib - Stack trace: at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath) at System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy) at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, Boolean useAsync) at System.Net.FileWebStream..ctor(FileWebRequest request, String path, FileMode mode, FileAccess access, FileShare sharing, Int32 length, Boolean async) at System.Net.FileWebResponse..ctor(FileWebRequest request, Uri uri, FileAccess access, Boolean asyncHint) COMPONENT STORE TRANSACTION DETAILS No transaction information is available.

?
Got CheckAsYouType working
Posted: Monday, January 09, 2006 5:27 PM (EST)
Try clearing out your temp files in IE. That fixed it for me.

partnerinflight
Got CheckAsYouType working
Posted: Monday, January 09, 2006 5:40 PM (EST)

Posted an update to the code (some minor bug fixes), including a sample app (if you want to try a simpler app instead of using the WritersLore one). http://www.partnerinflight.com/NetSpell.zip

Didn't include the dictionaries there, so put the dic folder into the local directory with CheckAsYouTypeTest.exe. Let me know if you run into any problems.

Thanks!

Gene

?
Got CheckAsYouType working
Posted: Tuesday, January 10, 2006 5:08 AM (EST)
thanks. I got it working now. It looks good

?
Got CheckAsYouType working
Posted: Wednesday, January 11, 2006 11:08 AM (EST)

I also need to inplement a CheckAsYouType RichTextBox for a VS2003 solution could you please post/let me know how I can downlaod/alter the solution to work under 2003

Cheers

Steve

?
Got CheckAsYouType working
Posted: Wednesday, January 11, 2006 11:12 AM (EST)
It shouldn't be terribly tough. Just manually add the .cs files from the CheckAsYouType folder to the original NetSpell csproj file and try to compile. You'll get compilation errors because I used anonymous methods (and maybe some generics). So you'll have to modify the code to not use those... Why're you still bothering with .NET 2003 anyway?

?
Got CheckAsYouType working
Posted: Wednesday, January 11, 2006 2:07 PM (EST)

Unfortunatly the company I am working for will not make the move yet, a pain I know.

I will try do my best to convert it, and post you back with the result if I manage it.

Have you considerd auto-replace functionality? i.e. i -> I

Steve

?
Got CheckAsYouType working
Posted: Wednesday, January 11, 2006 5:19 PM (EST)

auto-correct would be really nice. Paul? ...

gick2007
Got CheckAsYouType working
Posted: Sunday, February 11, 2007 11:52 AM (EST)
hello, the download link for "as-you-type" does not work. Would you please give me a new link? thanks.

gick2007
Got CheckAsYouType working
Posted: Wednesday, February 21, 2007 8:58 PM (EST)
anyone knows where can I get it?



Top