From b61d3d3eb97abebfa4135919c8ed0efc91e00625 Mon Sep 17 00:00:00 2001 From: moculus Date: Sun, 17 Jun 2007 06:11:44 +0000 Subject: [PATCH] fix centering bug --HG-- branch : pmacs2 --- application.py | 8 ++++---- lex2_perl.py | 2 +- window2.py | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/application.py b/application.py index 4f7c1cd..c0fd2a0 100755 --- a/application.py +++ b/application.py @@ -645,10 +645,10 @@ class Application(object): # XYZ: we should actually use more of the 'state' variables - format = "----:%s-Fl %-18s (%s)--L%d--C%d--%s" - status = format % (modflag, name, w.mode.name(), cursor.y+1, cursor.x+1, perc) - #format = "----:%s-Fl %-18s (%s)--L%d--C%d--%s--%s--%s" - #status = format % (modflag, name, w.mode.name(), cursor.y+1, cursor.x+1, w.first, w.last, perc) + #format = "----:%s-Fl %-18s (%s)--L%d--C%d--%s" + #status = format % (modflag, name, w.mode.name(), cursor.y+1, cursor.x+1, perc) + format = "----:%s-Fl %-18s (%s)--L%d--C%d--%s--%s--%s" + status = format % (modflag, name, w.mode.name(), cursor.y+1, cursor.x+1, w.first, w.last, perc) status = status[:slot.width + 1] status += "-" * (slot.width - len(status) + 1) self.win.addnstr(slot.height + slot.offset, 0, status, slot.width + 1, diff --git a/lex2_perl.py b/lex2_perl.py index b0da620..f47f4bc 100755 --- a/lex2_perl.py +++ b/lex2_perl.py @@ -76,7 +76,7 @@ class PerlGrammar(Grammar): ), RegionRule( name=r'heredoc1', - start=r"<< *\"(?P[a-zA-Z0-9_]+)\" *;", + start=r'<< *"(?P[a-zA-Z0-9_]+)" *;', grammar=StringGrammar(), end=r'^%(heredoc)s$', ), diff --git a/window2.py b/window2.py index bcdca12..ee01f4c 100644 --- a/window2.py +++ b/window2.py @@ -190,7 +190,7 @@ class Window(object): (x, y) = (0, 0) break counter += 1 - self.first = Point(x, y) + self.first = Point(0, y) self.redraw() def assure_visible_cursor(self): if not self.cursor_is_visible():