Now everything works. Nearly.

E.g. a ResetButtonWidget:

        wid_x = x() + xx;
        wid_y = y() + yy - textsize_;

        if(ResetButtonWidget == NULL)
    {
        int wid_h;

        wid_h = textsize_ + BUTTON_DH;

        ResetButtonWidget = new Button(wid_x, wid_y, ww, wid_h);
        ResetButtonWidget->textsize(textsize_);
        ResetButtonWidget->callback(ResetButtonWidget_cb);
        ResetButtonWidget->copy_label(val);
        ResetButtonWidget->labelsize(textsize_ - 1);

        browser_win->add_widget(ResetButtonWidget);

    }
        else
    {
        ResetButtonWidget->hide();
        ResetButtonWidget->x(wid_x - scroll_x_);
        ResetButtonWidget->y(wid_y - scroll_y_);
        ResetButtonWidget->show();
    }

The 'else' clause makes problems.

The canvas is a group that is clipped. Normal text is clipped
correctly. But the widget is not clipped correctly: when it is
scrolled into the visible area, it becomes visible on the grey
border of the canvas.

The border is outside the clip region of the group.

And that part of the widget that was visible on the border
remains to be visible on the border.

The question is now: how can I clip a widget so that only
that part of it is visible that is visible in the clip
region of the group ?

Or: [how] can I redraw the grey border of the canvas?

I suppose I must clip the widget. Is this possible? My clip test
failed. I had the wrong pair of scissors.

winfried
_______________________________________________
fltk mailing list
fltk@easysw.com
http://lists.easysw.com/mailman/listinfo/fltk

Reply via email to