Esempio n. 1
0
 def save(self,path,image_type):
     w,h = self.GetSizeTuple()
     bitmap = wx.wxEmptyBitmap(w,h)
     dc = wx.wxMemoryDC()
     dc.SelectObject(bitmap)
     #self.update()
     # The background isn't drawn right without this cluge.
     #fill_color = get_color(self.background_color)
     fill_color = get_color('white')
     dc.SetPen(wx.wxPen(fill_color))
     dc.SetBrush(wx.wxBrush(fill_color)) #how to handle transparency???
     dc.DrawRectangle(0,0,w,h)
     dc.SetPen(wx.wxNullPen)
     dc.SetBrush(wx.wxNullBrush)
     # end cluge
     self.draw(dc)
     image = wx.wxImageFromBitmap(bitmap)
     wx.wxInitAllImageHandlers()
     image.SaveFile(path,image_type_map[image_type])
Esempio n. 2
0
def getGetMinusImage():
    return wxImageFromBitmap(getGetMinusBitmap())
Esempio n. 3
0
def getGetHandImage():
    return wxImageFromBitmap(getGetHandBitmap())
Esempio n. 4
0
def getProjectImage():
    return wxImageFromBitmap(getProjectBitmap())
Esempio n. 5
0
def getPlusImage():
    return wxImageFromBitmap(getPlusBitmap())
Esempio n. 6
0
def getLogoBigImage():
    return wxImageFromBitmap(getLogoBigBitmap())
Esempio n. 7
0
def getFile1Image():
    return wxImageFromBitmap(getFile1Bitmap())
Esempio n. 8
0
def getLogoSmallImage():
    return wxImageFromBitmap(getLogoSmallBitmap())
Esempio n. 9
0
def getFile1Image():
    return wxImageFromBitmap(getFile1Bitmap())
Esempio n. 10
0
def getProjectImage():
    return wxImageFromBitmap(getProjectBitmap())
Esempio n. 11
0
def getLogoBigImage():
    return wxImageFromBitmap(getLogoBigBitmap())
Esempio n. 12
0
def getPlusImage():
    return wxImageFromBitmap(getPlusBitmap())
Esempio n. 13
0
def getLogoSmallImage():
    return wxImageFromBitmap(getLogoSmallBitmap())