changeset 950:1bb0780f1036

Add more border line to frameline and frameruler
author Thinker K.F. Li <thinker@codemud.net>
date Wed, 17 Nov 2010 02:29:47 +0800
parents c9bf47cc621f
children e06a8d90592c
files pyink/frameline.py
diffstat 1 files changed, 11 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/pyink/frameline.py	Wed Nov 17 02:16:32 2010 +0800
+++ b/pyink/frameline.py	Wed Nov 17 02:29:47 2010 +0800
@@ -72,10 +72,10 @@
             mark_x = (i + 1) * self._frame_width
             win.draw_line(gc, mark_x, 0, mark_x, mark_h)
             win.draw_line(gc, mark_x, w_h - mark_h - 1, mark_x, w_h - 1)
-            if (i % 5) == 4:
-                pass
             pass
 
+        win.draw_line(gc, 0, w_h - 1, w_w, w_h -1)
+
         #
         # Set color of frame number
         #
@@ -200,6 +200,7 @@
     
     def _draw_frames(self):
         win = self.window
+        w_x, w_y, w_w, w_h, depth = win.get_geometry()
         gc = gtk.gdk.GC(win)
         self._gc = gc
         
@@ -237,6 +238,12 @@
                 i = i + 1
                 pass
             pass
+
+        border_rgb = color_to_rgb(self._normal_border)
+        border_color = gtk.gdk.Color(*border_rgb)
+        gc.set_rgb_fg_color(border_color)
+        stop_x = num_frames * self._frame_width
+        win.draw_line(gc, 0, w_h - 1, stop_x, w_h - 1)
         pass
 
     def _draw_keyframes(self):
@@ -276,6 +283,8 @@
 
         win.draw_line(gc, line_x1, 0, line_x1, w_h)
         win.draw_line(gc, line_x2, 0, line_x2, w_h)
+        win.draw_line(gc, line_x1, w_h - 1, line_x2, w_h - 1)
+        win.draw_line(gc, line_x1, 0, line_x2, 0)
         pass
     
     def update(self):