Angus Leeming wrote:

> Jean-Marc Lasgouttes wrote:
>> The xforms patch seems reasonable enough. I do not know about the
>> LyX part. But doing that would be very very nice. In particular, I
>> think that would fix the bug with submenus staying on screen after
>> they are closed.
> 
> Try out the patches I posted in reply to John. It certainly does
> something. It almost does the right thing too ;-)

And if you patch the patch, so that the code in
XWorkArea::work_area_handler is changed to this, then all will work
perfectly.

Perhaps John could answer the Question?

        case FL_DRAW: {
                if (!area->work_area || !area->work_area->form->visible)
                        return 1;

                if (ev) {
                        // XScreen::expose posts XEvents with x, y relative
                        // to the top left corner of ob.
                        // However, X11 itself generates XEvents with
                        // x, y relative to the top left corner
                        // of the window.

                        // Question: should XScreen::expose always post
                        // with x, y relative to the top left corner
                        // of the window? The code below would continue
                        // to exist, but would no longer need to be wrapped
                        // in std::max.
                         int const x = std::max(0, ev->xexpose.x - ob->x);
                         int const y = std::max(0, ev->xexpose.y - ob->y);

                        area->paint(x, y,
                                    ev->xexpose.width, ev->xexpose.height);

                } ...


-- 
Angus

Reply via email to