[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Patch for ruler-guides
From: |
Bernhard Herzog |
Subject: |
Re: Patch for ruler-guides |
Date: |
08 Jan 2003 22:15:23 +0100 |
User-agent: |
Gnus/5.0808 (Gnus v5.8.8) Emacs/21.2 |
Ralf Engels <address@hidden> writes:
> diff -Nur Sketch.old/UI/mainwindow.py Sketch/UI/mainwindow.py
> --- Sketch.old/UI/mainwindow.py Wed Dec 25 21:50:35 2002
> +++ Sketch/UI/mainwindow.py Mon Jan 6 18:47:15 2003
> @@ -69,7 +74,7 @@
> else:
> self.ContextChanged()
>
> +# for corresponding code see gimp source code display/gimpdisplayshell.c
> class SketchMainWindow(Publisher):
>
> def __init__(self, application, document = None, editor = None):
> @@ -135,9 +140,17 @@
> table.attach(menubutton, 0, 1, 0, 1, FILL, FILL)
>
> self.hruler = gtk.GtkHRuler()
> + self.hruler.set_events( gtk.GDK.BUTTON_PRESS_MASK |
> gtk.GDK.BUTTON_RELEASE_MASK );
> + self.hruler.connect('button_press_event', self.hruler_button_press)
> + self.hruler.connect('button_release_event',
> self.hruler_button_release)
> + self.hruler.connect('motion_notify_event', self.hruler_motion_notify)
> table.attach(self.hruler, 1, 2, 0, 1, EXPAND|FILL, 0)
>
> self.vruler = gtk.GtkVRuler()
> + self.vruler.set_events( gtk.GDK.BUTTON_PRESS_MASK |
> gtk.GDK.BUTTON_RELEASE_MASK );
> + self.vruler.connect('button_press_event', self.vruler_button_press)
> + self.vruler.connect('button_release_event',
> self.vruler_button_release)
> + self.vruler.connect('motion_notify_event', self.vruler_motion_notify)
> table.attach(self.vruler, 0, 1, 1, 2, 0, EXPAND|FILL)
>
> hadjust = gtk.GtkAdjustment()
> 5ler['position'] = pos.x
> self.vruler['position'] = pos.y
>
> +
> + def hruler_button_press(self, widget, event):
There seems to be missing something here. Probably where the 5 is in the
first colum (now the third due to quoting).
Plus, some of the lines above were wrapped. Keeping the lines shorter
than 80 columns might help with that.
Other than this the patch applied fine. I didn't have time to make it
work though.
One more thing if you want to make it even easier for me: A suitable
ChangeLog entry would be nice.
Bernhard
--
Intevation GmbH http://intevation.de/
Sketch http://sketch.sourceforge.net/
MapIt! http://www.mapit.de/