22 self.vscroll.y = 1 |
22 self.vscroll.y = 1 |
23 self.vscroll.connect('change', self.on_vscroll_change) |
23 self.vscroll.connect('change', self.on_vscroll_change) |
24 |
24 |
25 self.on_editbox_areasize() |
25 self.on_editbox_areasize() |
26 |
26 |
27 self.connect('draw', self.on_draw) |
|
28 |
|
29 |
|
30 def settext(self, text): |
27 def settext(self, text): |
31 self.editbox.set_text(text) |
28 self.editbox.set_text(text) |
32 |
29 |
33 |
30 |
34 def scrolltoend(self): |
31 def scrolltoend(self): |
35 self.editbox.move_pagelast() |
32 self.editbox.move_pagelast() |
36 |
33 |
37 |
34 |
38 def on_draw(self, screen, x, y): |
35 def on_draw(self, screen, x, y): |
|
36 super().on_draw(screen, x, y) |
39 screen.frame(x, y, self.width, self.height) |
37 screen.frame(x, y, self.width, self.height) |
40 |
38 |
41 |
39 |
42 def on_editbox_scroll(self): |
40 def on_editbox_scroll(self): |
43 self.vscroll.setpos(self.editbox.yofs) |
41 self.vscroll.setpos(self.editbox.yofs) |