fix centering bug

--HG--
branch : pmacs2
This commit is contained in:
moculus 2007-06-17 06:11:44 +00:00
parent 2eb04a22c1
commit b61d3d3eb9
3 changed files with 6 additions and 6 deletions

View File

@ -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,

View File

@ -76,7 +76,7 @@ class PerlGrammar(Grammar):
),
RegionRule(
name=r'heredoc1',
start=r"<< *\"(?P<heredoc>[a-zA-Z0-9_]+)\" *;",
start=r'<< *"(?P<heredoc>[a-zA-Z0-9_]+)" *;',
grammar=StringGrammar(),
end=r'^%(heredoc)s$',
),

View File

@ -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():