comparison src/conversation.c @ 3209:265a3c9d0557

[gaim-migrate @ 3226] If gtkspell can't use ispell, it tries aspell; Thanks Andrew Sayman committer: Tailor Script <tailor@pidgin.im>
author Sean Egan <seanegan@gmail.com>
date Sun, 05 May 2002 01:16:45 +0000
parents 332df87cf3d6
children 0970eabdd8df
comparison
equal deleted inserted replaced
3208:2215aa4fabdb 3209:265a3c9d0557
63 #include "pixmaps/mrt.xpm" 63 #include "pixmaps/mrt.xpm"
64 #include "pixmaps/download.xpm" 64 #include "pixmaps/download.xpm"
65 #include "pixmaps/farted.xpm" 65 #include "pixmaps/farted.xpm"
66 66
67 static gchar *ispell_cmd[] = { "ispell", "-a", NULL }; 67 static gchar *ispell_cmd[] = { "ispell", "-a", NULL };
68 static gchar *aspell_cmd[] = { "aspell", "--sug-mode=fast","-a", NULL };
68 69
69 int state_lock = 0; 70 int state_lock = 0;
70 71
71 GdkPixmap *dark_icon_pm = NULL; 72 GdkPixmap *dark_icon_pm = NULL;
72 GdkBitmap *dark_icon_bm = NULL; 73 GdkBitmap *dark_icon_bm = NULL;
2897 GSList *cht; 2898 GSList *cht;
2898 struct conversation *c; 2899 struct conversation *c;
2899 GSList *con = connections; 2900 GSList *con = connections;
2900 struct gaim_connection *gc; 2901 struct gaim_connection *gc;
2901 2902
2902 if (convo_options & OPT_CONVO_CHECK_SPELLING) 2903 if (convo_options & OPT_CONVO_CHECK_SPELLING){
2903 gtkspell_start(NULL, ispell_cmd); 2904 /*If ispell fails to start, start aspell. This is the way that
2905 Gabber does it. -- lorien420@myrealbox.com */
2906 if (gtkspell_start(NULL, ispell_cmd)<0){
2907 debug_printf("gtkspell failed to start when using ispell\n");
2908 if (gtkspell_start(NULL, aspell_cmd)<0){
2909 debug_printf("gtkspell failed to start when using aspell\n");
2910 } else
2911 debug_printf("gtkspell started with aspell\n");
2912 } else {
2913 debug_printf("gtkspell started with ispell\n");
2914 }
2915 }
2904 2916
2905 while (cnv) { 2917 while (cnv) {
2906 c = (struct conversation *)cnv->data; 2918 c = (struct conversation *)cnv->data;
2907 if (convo_options & OPT_CONVO_CHECK_SPELLING) 2919 if (convo_options & OPT_CONVO_CHECK_SPELLING)
2908 gtkspell_attach(GTK_TEXT(c->entry)); 2920 gtkspell_attach(GTK_TEXT(c->entry));