コード例 #1
0
ファイル: widgets.py プロジェクト: bjura/pisak
 def _init_text(self):
     self.box = Mx.BoxLayout()
     self.box.set_orientation(Mx.Orientation.VERTICAL)
     self.box.set_scroll_to_focused(True)
     self.text = widgets.Label()
     self.margin = Clutter.Margin.new()
     self.margin.top = 20
     self._lines_quantity = 0
     self.margin.left = self.margin.right = 10
     self.text.set_margin(self.margin)
     self.box.add_actor(self.text, 0)
     self.clutter_text = self.text.get_clutter_text()
     self.connect("notify::mapped", self._init_setup)
     self._set_text_params()
     self.add_actor(self.box)
コード例 #2
0
ファイル: widgets.py プロジェクト: Sasza/pisak
 def _init_text(self):
     self.box = Mx.BoxLayout()
     self.box.set_orientation(Mx.Orientation.VERTICAL)
     self.box.set_scroll_to_focused(True)
     self.text = Mx.Label()
     self.margin = Clutter.Margin.new()
     self.margin.top = 20
     self.margin.left = self.margin.right = 10
     self.text.set_margin(self.margin)
     self.box.add_actor(self.text, 0)
     self.clutter_text = self.text.get_clutter_text()
     self.connect("notify::mapped", self._check_to_resize)
     self.clutter_text.connect("text-changed", self._check_to_resize)
     self.clutter_text.connect("cursor-changed", self._scroll_to_view)
     self._set_text_params()
     self.add_actor(self.box)
コード例 #3
0
ファイル: mx_box_app.py プロジェクト: karolaug/pisak
 def create_box_mx(self):
     return Mx.BoxLayout()