xforms-development
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [XForms] New prerelease xforms-1.0.94pre13


From: Paul
Subject: Re: [XForms] New prerelease xforms-1.0.94pre13
Date: Tue, 25 Dec 2012 17:46:39 +0000
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.2.28) Gecko/20120313 Thunderbird/3.1.20


Jens wrote:
> I'll take a look at it shortly...

I find more problems with further testing, affecting
scrollbars and labelframes.  Sometimes after calling
fl_set_object_geometry() they are not redrawn properly.

For example, sometimes a scrollbar is redrawn without
arrows, but they appear on mouse-over.  Other times the
scrollbar is not redrawn at all.   Sometimes the scrollbar
is redrawn twice with the correct one overlapping a
slightly displaced false one.

All these problem go away if I comment-out the freeze/unfreeze
from my application.

Following code demos a case where the scrollbar is not
redrawn at all after a fl_set_object_geometry().

#include <stdio.h>
#include <forms.h>

int main( int argc, char *argv[])
{
   fl_initialize( &argc, argv, "xftest", 0, 0);

   FL_FORM *form = fl_bgn_form( FL_NO_BOX, 400, 300);
   fl_add_box( FL_UP_BOX, 0, 0, 400, 300, "");

   FL_OBJECT *sb =
      fl_add_scrollbar( FL_HOR_SCROLLBAR, 5, 100, 200, 15, "" );
   fl_set_object_boxtype( sb, FL_UP_BOX);

   fl_end_form();

   fl_show_form( form, FL_PLACE_FREE, FL_FULLBORDER, "xftest");

   XSync( fl_get_display(), 0);

   printf( "scrollbar displayed\n");
   printf( "paused, press ENTER to continue\n");
   getchar();

   // Now resize and move the scrollbar
   fl_freeze_form( form);
   fl_set_object_geometry( sb, 10, 150, 250, 15);
   fl_unfreeze_form( form);
   XSync( fl_get_display(), 0);

   // With 94pre12 and pre13, scrollbar is not redrawn at all
   // Works fine with pre11
   printf( "scrollbar resized and moved\n");
   printf( "paused, press ENTER to continue\n");
   getchar();

   return 0;
}

Try the above with pre11 and it works ok, but with pre13 the
scrollbar does not move.

I have to conclude that there is something deeper wrong with
the redraw() after a freeze/unfreeze. All problems occurred
with the changes 94pre11 to 94pre12.  My fix to the canvas
object only hid the problem for that particular object.
--
Paul Nicholson
--



reply via email to

[Prev in Thread] Current Thread [Next in Thread]