comparison frontends/sortilege/window.py @ 70:8f2ed279784b

i18n - gettext support added in frontends - first draft of frontends french translation
author Goffi <goffi@goffi.org>
date Fri, 05 Mar 2010 20:33:10 +1100
parents a5b5fb5fc9fd
children
comparison
equal deleted inserted replaced
69:86f1f7f6d332 70:8f2ed279784b
22 22
23 import curses 23 import curses
24 import os 24 import os
25 import pdb 25 import pdb
26 26
27
28 def echo(message):
29 return
30 os.system('echo "'+str(message)+'" >> /tmp/toto')
31 27
32 class Window(): 28 class Window():
33 def __init__(self, parent, height, width, y, x, border=False, title="", code="utf-8"): 29 def __init__(self, parent, height, width, y, x, border=False, title="", code="utf-8"):
34 self.__border=border 30 self.__border=border
35 self.__title=title 31 self.__title=title
91 87
92 # we check that coordinates are under limits 88 # we check that coordinates are under limits
93 self.__coordAdjust(self.__coords) 89 self.__coordAdjust(self.__coords)
94 height,width,y,x=self.__coords 90 height,width,y,x=self.__coords
95 91
96 echo ("newwin %d %d %d %d" % (height, width, y, x))
97 self.window = self.__parent.subwin(height, width, y, x) 92 self.window = self.__parent.subwin(height, width, y, x)
98 self.defInsideCoord() 93 self.defInsideCoord()
99 94
100 def __coordAdjust(self, coords): 95 def __coordAdjust(self, coords):
101 """Check that coordinates are under limits, adjust them else otherwise""" 96 """Check that coordinates are under limits, adjust them else otherwise"""