[patch] make TopGroup a PackedGroup
Hello, as I didn't get any feedback from Sebastian yet on my proposal to make the scrollbars part of UI instead of FltkViewport, I decided to split my initial patch. Below is a version that still uses a PackedGroup in UI, but leaves the scrollbars in FltkViewport. Here comes the details: * Make scrollbars really children of FltkViewport, as it was probabely intended. * Use widget local coordinates in FltkViewport::adjustScrollbarsAndGadgets. * Adjust draw() and handle() so that scrollbars work properly. * As a consequence replace() now works properly, so remove the workaround. * Make TopGroup a PackedGroup and let it do the layout. * Simplify fullscreen mode. This also fixes annoying problems with the statusbar when new windows are created in fullscreen mode. Cheers, Johannes
Hi, just noticed that child widgets where not redrawn properly with my patch. Attached is a fixed version against current cvs. Cheers, Johannes On Fri, Dec 28, 2007 at 05:26:19PM +0100, Johannes Hofmann wrote:
Hello,
as I didn't get any feedback from Sebastian yet on my proposal to make the scrollbars part of UI instead of FltkViewport, I decided to split my initial patch. Below is a version that still uses a PackedGroup in UI, but leaves the scrollbars in FltkViewport. Here comes the details:
* Make scrollbars really children of FltkViewport, as it was probabely intended. * Use widget local coordinates in FltkViewport::adjustScrollbarsAndGadgets. * Adjust draw() and handle() so that scrollbars work properly. * As a consequence replace() now works properly, so remove the workaround. * Make TopGroup a PackedGroup and let it do the layout. * Simplify fullscreen mode.
This also fixes annoying problems with the statusbar when new windows are created in fullscreen mode.
Cheers, Johannes
Hi, just noticed that child widgets where not redrawn properly with my patch. Attached is a fixed version against current cvs. Cheers, Johannes On Fri, Dec 28, 2007 at 05:26:19PM +0100, Johannes Hofmann wrote:
Hello,
as I didn't get any feedback from Sebastian yet on my proposal to make the scrollbars part of UI instead of FltkViewport, I decided to split my initial patch. Below is a version that still uses a PackedGroup in UI, but leaves the scrollbars in FltkViewport. Here comes the details:
* Make scrollbars really children of FltkViewport, as it was probabely intended. * Use widget local coordinates in FltkViewport::adjustScrollbarsAndGadgets. * Adjust draw() and handle() so that scrollbars work properly. * As a consequence replace() now works properly, so remove the workaround. * Make TopGroup a PackedGroup and let it do the layout. * Simplify fullscreen mode.
This also fixes annoying problems with the statusbar when new windows are created in fullscreen mode.
Cheers, Johannes
Johannes wrote:
just noticed that child widgets where not redrawn properly with my patch. Attached is a fixed version against current cvs.
If I switch to another screen and come back, the scrollbars aren't drawn. The viewport has damage 0xc0, and ?scrollbar->damage() is 0.
On Sat, Dec 29, 2007 at 07:00:05AM +0000, place wrote:
Johannes wrote:
just noticed that child widgets where not redrawn properly with my patch. Attached is a fixed version against current cvs.
If I switch to another screen and come back, the scrollbars aren't drawn. The viewport has damage 0xc0, and ?scrollbar->damage() is 0.
Ah yes, the widget specific damage is only set in the DAMAGE_CHILD case. Please try the patch below. This drawing stuff is really fragile. It's not much code though (FltkViewport::draw () and FltkViewBase::draw ()). Johannes --- a/dw/fltkviewport.cc Fri Dec 28 20:17:46 2007 +0100 +++ b/dw/fltkviewport.cc Sat Dec 29 08:45:03 2007 +0100 @@ -193,10 +193,13 @@ void FltkViewport::draw () if (d) { draw_area(this, cr); - if (hscrollbar->damage ()) + if (d == DAMAGE_CHILD) { + if (hscrollbar->damage ()) draw_child (*hscrollbar); + if (vscrollbar->damage ()) draw_child (*vscrollbar); + } else { draw_child (*hscrollbar); - if (vscrollbar->damage ()) draw_child (*vscrollbar); + } } scrollDX = 0;
_______________________________________________ Dillo-dev mailing list Dillo-dev@dillo.org http://lists.auriga.wearlab.de/cgi-bin/mailman/listinfo/dillo-dev
Johannes wrote:
On Sat, Dec 29, 2007 at 07:00:05AM +0000, place wrote:
Johannes wrote:
just noticed that child widgets where not redrawn properly with my patch. Attached is a fixed version against current cvs.
If I switch to another screen and come back, the scrollbars aren't drawn. The viewport has damage 0xc0, and ?scrollbar->damage() is 0.
Ah yes, the widget specific damage is only set in the DAMAGE_CHILD case. Please try the patch below. This drawing stuff is really fragile. It's not much code though (FltkViewport::draw () and FltkViewBase::draw ()).
Seems to be working well now. Thanks...
Hi Johannes, On Fri, Dec 28, 2007 at 05:26:19PM +0100, Johannes Hofmann wrote:
Hello,
as I didn't get any feedback from Sebastian yet on my proposal to make the scrollbars part of UI instead of FltkViewport, I decided to split my initial patch. Below is a version that still uses a PackedGroup in UI, but leaves the scrollbars in FltkViewport. Here comes the details:
* Make scrollbars really children of FltkViewport, as it was probabely intended. * Use widget local coordinates in FltkViewport::adjustScrollbarsAndGadgets. * Adjust draw() and handle() so that scrollbars work properly. * As a consequence replace() now works properly, so remove the workaround. * Make TopGroup a PackedGroup and let it do the layout. * Simplify fullscreen mode.
This also fixes annoying problems with the statusbar when new windows are created in fullscreen mode.
Reviewing the patch made me remember the struggle I had, to develop those workarounds to have the UI working. As you may intuit I'm more than willing to commit. ;-) The question is: Do you agree with commiting now or do you prefer to hold them for comment as the former patch? -- Cheers Jorge.-
Hi Jorge, On Tue, Jan 01, 2008 at 11:26:59AM -0300, Jorge Arellano Cid wrote:
Hi Johannes,
On Fri, Dec 28, 2007 at 05:26:19PM +0100, Johannes Hofmann wrote:
Hello,
as I didn't get any feedback from Sebastian yet on my proposal to make the scrollbars part of UI instead of FltkViewport, I decided to split my initial patch. Below is a version that still uses a PackedGroup in UI, but leaves the scrollbars in FltkViewport. Here comes the details:
* Make scrollbars really children of FltkViewport, as it was probabely intended. * Use widget local coordinates in FltkViewport::adjustScrollbarsAndGadgets. * Adjust draw() and handle() so that scrollbars work properly. * As a consequence replace() now works properly, so remove the workaround. * Make TopGroup a PackedGroup and let it do the layout. * Simplify fullscreen mode.
This also fixes annoying problems with the statusbar when new windows are created in fullscreen mode.
Reviewing the patch made me remember the struggle I had, to develop those workarounds to have the UI working. As you may intuit I'm more than willing to commit. ;-)
The question is: Do you agree with commiting now or do you prefer to hold them for comment as the former patch?
I think it can be commited, as this new patch does not include the reorganization of my initial patch that makes the scrollbars part of the UI and thereby obsoletes all the ScrollbarThickness stuff in dw. Cheers, Johannes
-- Cheers Jorge.-
_______________________________________________ Dillo-dev mailing list Dillo-dev@dillo.org http://lists.auriga.wearlab.de/cgi-bin/mailman/listinfo/dillo-dev
On Tue, Jan 01, 2008 at 04:41:49PM +0100, Johannes Hofmann wrote:
Hi Jorge,
On Tue, Jan 01, 2008 at 11:26:59AM -0300, Jorge Arellano Cid wrote:
Hi Johannes,
On Fri, Dec 28, 2007 at 05:26:19PM +0100, Johannes Hofmann wrote:
Hello,
as I didn't get any feedback from Sebastian yet on my proposal to make the scrollbars part of UI instead of FltkViewport, I decided to split my initial patch. Below is a version that still uses a PackedGroup in UI, but leaves the scrollbars in FltkViewport. Here comes the details:
* Make scrollbars really children of FltkViewport, as it was probabely intended. * Use widget local coordinates in FltkViewport::adjustScrollbarsAndGadgets. * Adjust draw() and handle() so that scrollbars work properly. * As a consequence replace() now works properly, so remove the workaround. * Make TopGroup a PackedGroup and let it do the layout. * Simplify fullscreen mode.
This also fixes annoying problems with the statusbar when new windows are created in fullscreen mode.
Reviewing the patch made me remember the struggle I had, to develop those workarounds to have the UI working. As you may intuit I'm more than willing to commit. ;-)
The question is: Do you agree with commiting now or do you prefer to hold them for comment as the former patch?
I think it can be commited, as this new patch does not include the reorganization of my initial patch that makes the scrollbars part of the UI and thereby obsoletes all the ScrollbarThickness stuff in dw.
Committed! -- Cheers Jorge.-
participants (3)
-
jcid@dillo.org
-
Johannes.Hofmann@gmx.de
-
place@gobigwest.com