コード例 #1
0
ファイル: colorpicker.py プロジェクト: ShadowKyogre/mypaint
    def __init__(self, doc, tdw, x, y):
        """Initialize, attaching to the brush and to the tdw.

        Observer callbacks and canvas overlays are registered by this
        constructor, so cleanup() must be called when the owning mode leave()s.

        """
        Overlay.__init__(self)
        self._doc = doc
        self._tdw = tdw
        self._x = int(x)+0.5
        self._y = int(y)+0.5
        alloc = tdw.get_allocation()
        self._tdw_w = alloc.width
        self._tdw_h = alloc.height
        self._color = self._get_app_brush_color()
        app = doc.app
        app.brush.observers.append(self._brush_color_changed_cb)
        tdw.display_overlays.append(self)
        self._previous_area = None
        self._queue_tdw_redraw()
コード例 #2
0
ファイル: colorpicker.py プロジェクト: sjcalamia/mypaint
    def __init__(self, doc, tdw, x, y):
        """Initialize, attaching to the brush and to the tdw.

        Observer callbacks and canvas overlays are registered by this
        constructor, so cleanup() must be called when the owning mode leave()s.

        """
        Overlay.__init__(self)
        self._doc = doc
        self._tdw = tdw
        self._x = int(x) + 0.5
        self._y = int(y) + 0.5
        alloc = tdw.get_allocation()
        self._tdw_w = alloc.width
        self._tdw_h = alloc.height
        self._color = self._get_app_brush_color()
        app = doc.app
        app.brush.observers.append(self._brush_color_changed_cb)
        tdw.display_overlays.append(self)
        self._previous_area = None
        self._queue_tdw_redraw()
コード例 #3
0
ファイル: framewindow.py プロジェクト: kleopatra999/mypaint
 def __init__(self, doc):
     """Initialize overlay"""
     Overlay.__init__(self)
     self.doc = doc
     self.app = doc.app
コード例 #4
0
ファイル: framewindow.py プロジェクト: emfol/mypaint
 def __init__(self, doc):
     """Initialize overlay"""
     Overlay.__init__(self)
     self.doc = doc
     self.app = doc.app
     self._trash_icon_pixbuf = None
コード例 #5
0
ファイル: framewindow.py プロジェクト: Jehan/mypaint
 def __init__(self, doc):
     """Initialize overlay"""
     Overlay.__init__(self)
     self.doc = doc
     self.app = doc.app
     self._trash_icon_pixbuf = None
コード例 #6
0
 def __init__(self, doc):
     """Initialize overlay"""
     Overlay.__init__(self)
     self.doc = doc
     self.app = doc.app