[fpc-pascal]RE: force redraw on hscale
M.Santhoff at t-online.de
Tue Apr 27 17:07:02 CEST 2004
Am Di, den 27.04.2004 schrieb Jeff Pohlmeyer um 07:58:
> > My question: how can I force a redraw on selected
> > widgets or the whole window when needed?
> Maybe this will help:
> procedure UpdateWidget(w:pGtkWidget);
> update_rect: tGdkRectangle;
> gtk_widget_draw(w, @update_rect);
I think it does work, but the color on the GtkHScale does not really
change, only after changing the value at the slider, as before.
I added (hint from the gtk mailing list) this:
while (gtk_events_pending()=gtk_true) do gtk_main_iteration ();
to process all pending draw event afterwards, but no luck. :(
Must be a bug or some plan I do not get.
Has anyone ever managed to change a GtkHScales color on the fly?
I can do it at startup from the ressource file, but changing afterwards
is not possible. But it does work when i minimize the window and restore
it! And it is colorizing the whole bar, not only the places where the
slider steps ...
Any further hints?
More information about the fpc-pascal