On Thursday 03 October 2002 9:40 am, Rob Lahaye wrote: > Angus Leeming wrote: > > Rob, here's an updated patch to replace what you have > > already. It incorporates some bugfixes, your suggestions and > > most of those made by Allan (off-list). > > > > It also gives you a checkLyXLength() function for ... well, > > you know. > > > > I suspect that you'll be able to simplify those input() > > methods considerably. > > Thanks Angus! > From now on, please don't send me patches pulled from your > previous ones, since I made modifications here and I'll have > difficulties to merge them.
I'll leave it in your tender care ;-) One thing I'd like you to change is: ButtonControllerBase.h: struct CheckedWidget { - virtual bool check() = 0; + virtual bool check() const = 0; You should also add a const to the declaration and definition of the check() methods in checkedwidgets.[Ch]. These methods do not alter the list that stores them and so should reflect that in their definition. It doesn't matter that they might (do) alter the objects pointed to. > My problem is: I can't see where the Paragraph and Graphics > differ. Do you know? I do. Oh, Ok. ControlParagraph derives from ControlDialog but ControlGraphics derives from ControlInset. You should add + + // The widgets may not be valid, so refresh the button controller + bc().refresh(); to the end of methods void ControlInset<Inset, Params>::show(Params const & params) void ControlInset<Inset, Params>::update() to be found in controllers/ControlInset.tmpl > Another thing I don't understand: I ran the debugger (gdb) > with a breakpoint at "CheckedGlueLength::check". Start LyX, do > "File->New". You can mouse-click anywhere on the canvas, no > problem. Now open a dialog that uses the length check and > close it again; you'll have to continue several times at the > breakpoint. Now all of a sudden the leftmouse and middlemouse > clicks on the canvas stop at the breakpoint; the middlemouse > click even more often than the leftmouse click. What's going > on here? Why does a canvas click need a length check? It > appears to me that the canvas click somehow is intertwined > with the dialog stuff, but only after a length-check-dialog > has been used. Any idea what's wrong here? None. ;-) Angus