Thanks Zac, 

My first patch

it does this:

24-03-2005 Rafael Teixeira <[EMAIL PROTECTED]>
        sample/TestGtkSpell.cs
        -- added a delete event handler to end the application when
closing the window
        -- now accepts an optional command line argument to specify locale.
           Ex: "mono TestGtkSpell.exe pt-br", defaults to en-us as before

may I commit.

Fun,

On Thu, 24 Mar 2005 11:41:37 -0600, Zac Bowling <[EMAIL PROTECTED]> wrote:
> I already commited to the svn last night :-) Its under
> sources/trunk/gtkspell-sharp
> 
> I've updated it and regenerated with gapi so the api is different now.
> (Sorry, but I messed up on a few things before and it was a prerelease).
> I fixed the makefile so it didn't staticly call aclocal-1.7 and
> automake-1.7, and I fixed the casing of the namespace and updated a few
> things in the sample. I have to add code to allow it to disconnect
> destruction of the textview. You can do it on your own by saving the
> variable for the SpellCheck object or calling the function to return the
> instance of SpellCheck attached and call detach manually. I should have
> a fix for that soon. :-)
> 
> If you have any patches, email the list and I will apply them (since I'm
> maintaining a version since its sort of beta right now) unless its a new
> sample then if you have SVN access then feel free to add it the sample
> directory (don't forget to update the Makefile, hehe). You can also tell
> me any issues in #mono on irc.gimp.org if you catch me (user zbowling).
> Later when its stable, we can pretty much go by house rules.
> 
> If anyone is interested I'll start making a wrapper for libgnomeprint
> (not libgnomeprintUI). libgnomeprint works on Windows on Linux but
> libgnomeprintUI doesn't (bonobo/orbit dependencies). We can also work on
> a C# replacement in then SVN for the printing dialogs. I only want to do
> that one if I find interest because right now I'm using it side my app
> and I'm to lazy to rip it out without interest. Its really nice for
> cross platform printing. :-)
> 
> Anyways, have fun!
> Zac
> 
> MAY THE CODE BE WITH YOU!
> 
> On Thu, 2005-03-24 at 11:54 -0300, Rafael Teixeira wrote:
> > Can I or someone of a higher cast, create a gtkspell-sharp module in
> > the SVN repo to house it? From there we can help to fix the few issues
> > Zac hints about...
> >
> > Also Zac, can you list specifically what the issues are?
> >
> > :)
> >
> >
> > On Wed, 23 Mar 2005 22:57:51 +0100, Martin Willemoes Hansen
> > <[EMAIL PROTECTED]> wrote:
> > > ons, 23 03 2005 kl. 15:17 -0600, skrev Zac Bowling:
> > > > If anyone has seen gaim or tomboy knows about GtkSpell. It basically
> > > > creates the Word, or Evolution type marks on your misspelled words, and
> > > > with a quick right mouse click you can fix your mistake. It only takes
> > > > one line of code and you have spell check on any of your TextViews :-)
> > > >
> > > > http://www.polystimulus.com/gtkspell-sharp.tar.bz2
> > >
> > > Cool, it would probably be nice to have in gnome or mono cvs.
> > >
> > > Happy hacking!
> > > --
> > > Martin Willemoes Hansen
> > >
> > > _______________________________________________
> > > Mono-devel-list mailing list
> > > Mono-devel-list@lists.ximian.com
> > > http://lists.ximian.com/mailman/listinfo/mono-devel-list
> > >
> >
> >
> 
> 


-- 
Rafael "Monoman" Teixeira
---------------------------------------
I'm trying to become a "Rosh Gadol" before my own eyes. 
See http://www.joelonsoftware.com/items/2004/12/06.html for enlightment.
It hurts!
Index: sample/TestGtkSpell.cs
===================================================================
--- sample/TestGtkSpell.cs	(revision 42226)
+++ sample/TestGtkSpell.cs	(working copy)
@@ -4,7 +4,7 @@
 
 public class GtkHelloWorld {
  
-  public static void Main() {
+  public static void Main(string[] args) {
     Application.Init();
 
     //Create the Window
@@ -14,8 +14,13 @@
     //Create a TextView 
     TextView myTextView = new TextView();
     
+    SpellCheck mySpellCheck;
+    
     //Bind GtkSpell to our textview
-    SpellCheck mySpellCheck = new SpellCheck(myTextView, "en-us");
+    if (args.Length > 0)
+	    mySpellCheck = new SpellCheck(myTextView, args[0]);
+	else    
+	    mySpellCheck = new SpellCheck(myTextView, "en-us");
 
     //spellCheck.Detach();
     //spellCheck.();
@@ -26,6 +31,13 @@
     //Show Everything     
     myWin.ShowAll();
     
+ 	myWin.DeleteEvent += new DeleteEventHandler(delete);
+    
     Application.Run();   
    }
+   
+   static void delete(object o, DeleteEventArgs args)
+   {
+    Application.Quit();
+   }
 }
Index: ChangeLog
===================================================================
--- ChangeLog	(revision 42226)
+++ ChangeLog	(working copy)
@@ -0,0 +1,5 @@
+24-03-2005 Rafael Teixeira <[EMAIL PROTECTED]>
+	sample/TestGtkSpell.cs
+	-- added a delete event handler to end the application when closing the window
+	-- now accepts an optional command line argument to specify locale. 
+	   Ex: "mono TestGtkSpell.exe pt-br", defaults to en-us as before

Reply via email to