Re: Can someone approve this patch?


Subject: Re: Can someone approve this patch?
From: sam th (sam@bur-jud-118-039.rh.uchicago.edu)
Date: Mon May 29 2000 - 17:44:16 CDT


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Thu, 18 May 2000, Robert Sievers wrote:

> The following came into patches a while ago, and I really am not sure
> whether this is the appropriate fix. Can someone verify this would be ok
> to apply and commit if appropriate?
>
>
> -----------------
> From: Peter Haight <peterh@sapros.com>
> Sender: peterh@wartch.sapros.com
>
> I'm on FreeBSD 4.0. This fixes a problem where the margin was being drawn
> outside the window. It is possible that this is some sort of GTK bug, but
> this fixes my problem and it makes sense not to draw the margin if it cannot
> be seen.
>
> ? margin-patch.patch
> Index: fv_View.cpp
> ===================================================================
> RCS file: /cvsroot/abi/src/text/fmt/xp/fv_View.cpp,v
> retrieving revision 1.253
> diff -u -u -r1.253 fv_View.cpp
> --- fv_View.cpp 2000/04/15 12:35:13 1.253
> +++ fv_View.cpp 2000/04/30 00:30:02
> @@ -3949,7 +3949,10 @@
> m_pG->drawLine(adjustedLeft, adjustedBottom, adjustedLeft, adjustedTop);
>
> // fill to right of page
> - m_pG->fillRect(clrMargin, adjustedRight + 1, adjustedTop,
> m_iWindowWidth - (adjustedRight + 1), iPageHeight + 1);
> + if (m_iWindowWidth - (adjustedRight + 1) > 0)
> + {
> + m_pG->fillRect(clrMargin, adjustedRight + 1, adjustedTop,
> m_iWindowWidth - (adjustedRight + 1), iPageHeight + 1);
> + }
>
> // fill separator below page
> m_pG->fillRect(clrMargin, adjustedLeft, adjustedBottom + 1,
> m_iWindowWidth - adjustedLeft, fl_PAGEVIEW_PAGE_SEP);

This patch is neccessary, but it doesn't work anymore. To see the bug,
type some text and then move the left margin off the edge of the page.
The text moves with it, which is totally the wrong behavior. You shouln't
even be able to set the margin over there. However, due to Alexey's
changes to the margin code, this won't apply. Alexey, can you figure out
how to fix this?
           
                                     sam th
                                     sam@uchicago.edu
                                http://sam.rh.uchicago.edu
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.1 (GNU/Linux)
Comment: For info see http://www.gnupg.org

iD8DBQE5MvLBt+kM0Mq9M/wRAtrOAJ9Qo067dJDV1yiZ56BU7Qmp6SztlQCgyevz
n56nH9os5VBHbLLA8yXTp6A=
=9UF3
-----END PGP SIGNATURE-----



This archive was generated by hypermail 2b25 : Mon May 29 2000 - 17:44:20 CDT