On 17-Apr-2002 Andre Poenitz wrote:
>
> When I mark some paasge of text by pressing shift-down and the cursor
> crosses a math inset it gets stuck there. Formerly the whole inset was
> selected or not as some monolithic object, which is much better in my
> opinion. We can't do much with half formulas anyway.
Ok I fixed this (this was due to my comit yesterday)!
> Looks like the outside world sees the same problems as mathed as
> it starts to get 'smart' ;-}
I don't understand!
> Next problem: Enter math in tables with the cursor from behind. THe cursor
> goes to the first position.But this could be my fault somehow...
Well let's say yes it's your fault, but I don't understand are you never
debugging code? I't just a simple break in the FormulaBase::edit() and see
what they do!
What happens! When inside a insettext a cursor-Left move enters the inset
from behind. Instead of using the "new" edit(bv, front) call it still used
the edit(bv, x, y, button) call with x=inset::width() and y=inset::asc + desc.
Normally with such x/y values we should enter the inset at the bottom left!
I now simplified that function and use the edit(bv, front) call so it should
be fixed for you, but IMO you should check your function first (before
updating after my next commit) as it seems your algorithm in
MathCursor::bruteFind() is wrong (heed that x/y values are relative to the
inset as you see by the values they are set too!). Also why do you use
while(1) and a break; instead of do { ... } while, or for() there?
(the for only if you don't care that your iterator is already the_end
iterator and as much as I know end iterators do not have any good values
in them, do they?)
Jug
--
-._-._-._-._-._-._-._-._-._-._-._-._-._-._-._-._-._-._-._-._-._-._-._
Dr. J�rgen Vigna E-Mail: [EMAIL PROTECTED]
Italienallee 13/N Tel/Fax: +39-0471-450260 / +39-0471-450253
I-39100 Bozen Web: http://www.sad.it/~jug
-._-._-._-._-._-._-._-._-._-._-._-._-._-._-._-._-._-._-._-._-._-._-._
Sometimes you get an almost irresistible urge to go on living.