R. Lahaye wrote:
> R. Lahaye wrote:
> 
>>
>> Something is not working properly here!
> 
> 
> Another problem with the spellingchecker (with ispell installed):
> 
> The progress slider gets values updated from controller().getProgress().
> This function should return a value between 0 and 100, which it does
> only inside regular text; inside insets the return value is far above 100.
> 

A temporary hack could be following:

Index: src/frontends/xforms/FormSpellchecker.C
===================================================================
RCS file: /cvs/lyx/lyx-devel/src/frontends/xforms/FormSpellchecker.C,v
retrieving revision 1.19
diff -u -r1.19 FormSpellchecker.C
--- src/frontends/xforms/FormSpellchecker.C     2002/08/12 14:28:43     1.19
+++ src/frontends/xforms/FormSpellchecker.C     2002/09/02 22:51:26
@@ -109,9 +121,11 @@
  void FormSpellchecker::partialUpdate(int id)
  {
        switch (id) {
-       case 0:
+       case 0:
                // set progress bar
-               fl_set_slider_value(dialog_->slider,
+               // temporary hack; progress inside insets returns value >> 100
+               if (controller().getProgress() <= 100.0)
+                       fl_set_slider_value(dialog_->slider,
                                    controller().getProgress());
                break;
        case 1:


=======================================================

Another spellingchecker bug:

When I move the cursor to the end of the document, start the spellingchecker,
the spellingchecker does nothing. While leaving the spellingchecker dialog
open, I move the cursor to the top of the document and click on [Start] in
the spellingchecker dialog. Bang: SIGSEGV.

The dbg backtrace is:

Program received signal SIGSEGV, Segmentation fault.
0x836797f in ControlSpellchecker::check (this=0x85e7674) at ControlSpellchecker.C:106
106                     if (!speller_->alive()) {
(gdb) bt
#0  0x836797f in ControlSpellchecker::check (this=0x85e7674) at 
ControlSpellchecker.C:106
#1  0x830cdbe in FormSpellchecker::input (this=0x85e7730, obj=0x8751600, val=0)
     at FormSpellchecker.C:89
#2  0x829c4f8 in FormBase::InputCB (this=0x85e7730, ob=0x8751600, data=0) at 
FormBase.C:153
#3  0x829c65a in C_FormBaseInputCB (ob=0x8751600, d=0) at FormBase.C:204
#4  0x28576d5b in fl_object_qread () at events.c:206
#5  0x285870ff in fl_check_forms () at forms.c:2109
#6  0x832c041 in lyx_gui::start (batch=@0xbfbffac4, files=0xbfbff92c) at lyx_gui.C:310
#7  0x8108096 in LyX::LyX (this=0xbfbffac0, argc=@0xbfbffaf0, argv=0xbfbffb3c)
     at ../src/lyx_main.C:159
#8  0x8156362 in main (argc=1, argv=0xbfbffb3c) at ../src/main.C:31
#9  0x8050781 in _start ()

The problem is that "(SpellBase *) speller_" is NULL, so that "speller_->alive()" in
ControlSpellchecker.C:106 explodes!

Does the spellchecker not get the updated cursor movement?
Any ideas what's going wrong here?

Regards,
Rob.

Reply via email to