当前位置: 首页>>代码示例>>Python>>正文


Python imageutils.spBitmap函数代码示例

本文整理汇总了Python中wxgui.cutils.imageutils.spBitmap函数的典型用法代码示例。如果您正苦于以下问题:Python spBitmap函数的具体用法?Python spBitmap怎么用?Python spBitmap使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了spBitmap函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: _create_toolbar

    def _create_toolbar(self):
        """ Creates a toolbar panel. """

        # Define the size of the icons and buttons
        iconSize = (TB_ICONSIZE, TB_ICONSIZE)
        self.toolbar = wx.ToolBar( self, -1, style=wx.TB_TEXT)

        # Set the size of the buttons
        self.toolbar.SetToolBitmapSize(iconSize)
        self.toolbar.SetFont( self.preferences.GetValue('M_FONT') )

        self.toolbar.AddLabelTool(ID_ADD_LABEL, 'Label Filter',
                             spBitmap(FILTER_ADD_LABEL,TB_ICONSIZE,theme=self.preferences.GetValue('M_ICON_THEME')),
                             shortHelp="Add a filter on the content of each annotation of the tier")
        self.toolbar.AddLabelTool(ID_ADD_TIME, 'Time Filter',
                             spBitmap(FILTER_ADD_TIME,TB_ICONSIZE,theme=self.preferences.GetValue('M_ICON_THEME')),
                             shortHelp="Add a filter to fix the time to start or to end to filter")
        self.toolbar.AddLabelTool(ID_ADD_DURATION, 'Duration Filter',
                             spBitmap(FILTER_ADD_DURATION,TB_ICONSIZE,theme=self.preferences.GetValue('M_ICON_THEME')),
                             shortHelp="Add a filter on the duration of each annotations of the tier")
        self.toolbar.AddSeparator()
        self.toolbar.AddLabelTool(ID_CLEAR, 'Remove Filter',
                             spBitmap(FILTER_REMOVE,TB_ICONSIZE,theme=self.preferences.GetValue('M_ICON_THEME')),
                             shortHelp="Remove checked filters of the list")
        self.toolbar.Realize()

        # events
        eventslist = [ ID_ADD_LABEL, ID_ADD_TIME, ID_ADD_DURATION, ID_CLEAR ]
        for event in eventslist:
            wx.EVT_TOOL(self, event, self.ProcessEvent)
开发者ID:drammock,项目名称:sppas,代码行数:30,代码来源:singlefilter.py

示例2: __init__

    def __init__(self, parent, prefsIO):
        """ Create a new instance. """

        wx.Panel.__init__(self, parent, style=wx.NO_BORDER)
        sizer = wx.BoxSizer( wx.HORIZONTAL )

        # members
        self._prefsIO  = prefsIO
        self._display  = None
        self._trsctrl  = None
        self._buttons  = {}
        self._search    = None

        # create the buttons bar
        theme = self._prefsIO.GetValue('M_ICON_THEME')
        bgcolour = self._prefsIO.GetValue('M_BG_COLOUR')
        self._buttons['tiercheck'] = CreateButton( self, spBitmap(TIER_CHECK_DISABLED,TB_ICONSIZE,theme),  self.onTierCheck,sizer, colour=bgcolour)
        self._buttons['tierinfo']  = CreateButton( self, spBitmap(TIER_INFO_DISABLED,TB_ICONSIZE,theme),   self.onTierInfo, sizer, colour=bgcolour)
        self._buttons['search']    = CreateButton( self, spBitmap(TIER_SEARCH_DISABLED,TB_ICONSIZE,theme), self.onSearch,   sizer, colour=bgcolour)

        # sizer
        sizer.Add(self._buttons['tiercheck'], 1, flag=wx.ALL, border=2)
        sizer.Add(self._buttons['tierinfo'],  1, flag=wx.ALL, border=2)
        sizer.Add(self._buttons['search'],    1, flag=wx.ALL, border=2)

        self.Bind(spEVT_SEARCHED, self.onSearched)
        self.SetBackgroundColour( self._prefsIO.GetValue('M_BG_COLOUR') )

        self.SetSizer( sizer )
        self.SetAutoLayout( True )
        self.Layout()
开发者ID:brigittebigi,项目名称:sppas,代码行数:31,代码来源:sppaseditclient.py

示例3: on_link

 def on_link(self, evt):
     self.linked = not self.linked
     if self.linked:
         b=spBitmap(LINK_ICON, size=24, theme=self._prefsIO.GetValue('M_ICON_THEME'))
     else:
         b=spBitmap(UNLINK_ICON, size=24, theme=self._prefsIO.GetValue('M_ICON_THEME'))
     self.link_btn.SetBitmapLabel(b)
开发者ID:brigittebigi,项目名称:sppas,代码行数:7,代码来源:aannotations.py

示例4: _create_toolbar

    def _create_toolbar(self):
        """
        Creates the default toolbar.

        """

        toolbar = self.CreateToolBar(style=wx.TB_TEXT|wx.TB_FLAT|wx.TB_DOCKABLE|wx.TB_NODIVIDER)

        toolbar.AddLabelTool(wx.ID_EXIT, 'Exit', spBitmap(EXIT_ICON, TB_ICONSIZE, theme=self._prefsIO.GetValue('M_ICON_THEME')))
        toolbar.AddSeparator()
        toolbar.AddLabelTool(wx.ID_PREFERENCES, 'Settings', spBitmap(SETTINGS_ICON, TB_ICONSIZE, theme=self._prefsIO.GetValue('M_ICON_THEME')))
        toolbar.AddLabelTool(ID_FRAME_PLUGIN, 'Plug-in', spBitmap(PLUGIN_ICON, TB_ICONSIZE, theme=self._prefsIO.GetValue('M_ICON_THEME')), shortHelp="Import a plugin")
        toolbar.AddLabelTool(wx.ID_ABOUT, 'About', spBitmap(ABOUT_ICON, TB_ICONSIZE, theme=self._prefsIO.GetValue('M_ICON_THEME')))
        toolbar.AddLabelTool(wx.ID_HELP,  'Help', spBitmap(HELP_ICON, TB_ICONSIZE, theme=self._prefsIO.GetValue('M_ICON_THEME')))

        toolbar.SetToolSeparation(5)
        self.SetToolBar(toolbar)

        # Must be AFTER SetToolBar because wx can not apply a SetForeground / SetBackground to an un-attached toolbar!
        toolbar.SetBackgroundColour(self._prefsIO.GetValue('M_BG_COLOUR'))
        toolbar.SetForegroundColour(self._prefsIO.GetValue('M_FG_COLOUR'))
        #toolbar.SetFont(self._prefsIO.GetValue('M_FONT'))
        toolbar.Realize()

        # events
        eventslist = [ wx.ID_NEW, wx.ID_EXIT, wx.ID_PREFERENCES, wx.ID_ABOUT, wx.ID_HELP, ID_FRAME_PLUGIN ]
        for event in eventslist:
            wx.EVT_TOOL(self, event, self.ProcessEvent)
开发者ID:drammock,项目名称:sppas,代码行数:28,代码来源:mainframe.py

示例5: _create_toolbar

    def _create_toolbar(self):
        self.toolbar_layout = wx.BoxSizer(wx.HORIZONTAL)
        font = self.preferences.GetValue('M_FONT')
        sep_label = wx.StaticText(self, label="Time group separators:", style=wx.ALIGN_CENTER)
        sep_label.SetFont( font )
        self.septext = wx.TextCtrl(self, -1, size=(150,24))
        self.septext.SetInsertionPoint(0)
        self.septext.SetBackgroundColour(wx.SystemSettings_GetColour(wx.SYS_COLOUR_WINDOW))
        self.septext.SetForegroundColour(wx.Colour(128,128,128))
        self.septext.SetValue(DEFAULT_SEP)
        self.septext.Bind(wx.EVT_TEXT, self.OnTextChanged)
        self.septext.Bind(wx.EVT_SET_FOCUS, self.OnTextClick)

        broomb = wx.BitmapButton(self, bitmap=spBitmap(BROOM_ICON, 24, theme=self.preferences.GetValue('M_ICON_THEME')), style=wx.NO_BORDER)
        broomb.Bind(wx.EVT_BUTTON, self.OnTextErase)
        applyb = wx.BitmapButton(self, bitmap=spBitmap(APPLY_ICON, 24, theme=self.preferences.GetValue('M_ICON_THEME')), style=wx.NO_BORDER)
        applyb.Bind(wx.EVT_BUTTON, self.OnSeparatorChanged)

        font.SetPointSize(font.GetPointSize() - 2)
        durlist = ['Use only Midpoint value', 'Add the Radius value', 'Deduct the Radius value']
        withradiusbox = wx.RadioBox(self, -1, label="Annotation durations:", choices=durlist, majorDimension=1, style=wx.RA_SPECIFY_COLS)
        withradiusbox.SetFont( font )
        self.Bind(wx.EVT_RADIOBOX, self.OnWithRadius, withradiusbox)

        sepsizer = wx.BoxSizer(wx.HORIZONTAL)
        sepsizer.Add(sep_label,    0, flag=wx.ALL, border=5)
        sepsizer.Add(broomb,       0, flag=wx.ALL, border=5)
        sepsizer.Add(self.septext, 1, flag=wx.EXPAND|wx.ALL, border=5)
        sepsizer.Add(applyb,       0, flag=wx.ALL, border=5)

        self.toolbar_layout.Add(sepsizer, 1, flag=wx.LEFT|wx.ALIGN_CENTER_VERTICAL, border=5)
        self.toolbar_layout.AddStretchSpacer()
        self.toolbar_layout.Add(withradiusbox, flag=wx.RIGHT, border=5)
开发者ID:drammock,项目名称:sppas,代码行数:33,代码来源:tga.py

示例6: __init__

 def __init__(self, bmptype, label, preferences):
     if preferences:
         self.bmp = spBitmap(bmptype, 32, theme=preferences.get_theme())
     else:
         self.bmp = spBitmap(bmptype, 32, theme=None)
     self.label = label
     self.preferences = preferences
开发者ID:drammock,项目名称:sppas,代码行数:7,代码来源:viewsutils.py

示例7: _create_toolbar

    def _create_toolbar(self):
        """
        Creates the default toolbar.

        """
        toolbar = self.CreateToolBar(style=wx.TB_TEXT|wx.TB_FLAT|wx.TB_DOCKABLE|wx.TB_NODIVIDER)

        toolbar.AddLabelTool(id=wx.ID_EXIT, label="Exit", bitmap=spBitmap(EXIT_ICON,TB_ICONSIZE),bmpDisabled=wx.NullBitmap, kind=wx.ITEM_NORMAL, shortHelp="Quit the application")
        toolbar.AddSeparator()

        toolbar.AddLabelTool(id=wx.ID_ADD,   label="Import", bitmap=spBitmap(IMPORT_EXPORT_ICON, TB_ICONSIZE), bmpDisabled=wx.NullBitmap, kind=wx.ITEM_NORMAL, shortHelp="Import data from a file")
        toolbar.AddLabelTool(id=wx.ID_OPEN,  label="Open",   bitmap=spBitmap(OPEN_ICON, TB_ICONSIZE),  bmpDisabled=wx.NullBitmap, kind=wx.ITEM_NORMAL, shortHelp="Open a new directory")
        toolbar.AddLabelTool(id=wx.ID_SAVE,  label="Save",   bitmap=spBitmap(SAVE_ICON, TB_ICONSIZE),  bmpDisabled=wx.NullBitmap, kind=wx.ITEM_NORMAL, shortHelp="Save into CSV files")
        toolbar.AddLabelTool(id=wx.ID_APPLY, label="Check",  bitmap=spBitmap(CHECK_ICON, TB_ICONSIZE), bmpDisabled=wx.NullBitmap, kind=wx.ITEM_NORMAL, shortHelp="Check the data")
        toolbar.AddLabelTool(id=ID_GENERATE, label="Export", bitmap=spBitmap(EXPORT_ICON, TB_ICONSIZE),bmpDisabled=wx.NullBitmap, kind=wx.ITEM_NORMAL, shortHelp="Export as PDF files")
        toolbar.AddSeparator()

        toolbar.AddLabelTool(id=wx.ID_NEW,   label="Add",    bitmap=spBitmap(ADD_ICON, TB_ICONSIZE),   bmpDisabled=wx.NullBitmap, kind=wx.ITEM_NORMAL, shortHelp="Create a new entry")
        toolbar.AddLabelTool(id=wx.ID_EDIT,  label="Edit",   bitmap=spBitmap(EDIT_ICON, TB_ICONSIZE),  bmpDisabled=wx.NullBitmap, kind=wx.ITEM_NORMAL, shortHelp="Modify the selected entry")
        toolbar.AddLabelTool(id=wx.ID_DELETE,label="Delete", bitmap=spBitmap(DELETE_ICON, TB_ICONSIZE),bmpDisabled=wx.NullBitmap, kind=wx.ITEM_NORMAL, shortHelp="Delete the selected entry")
        toolbar.AddSeparator()

        toolbar.AddLabelTool(id=wx.ID_ABOUT, label="About", bitmap=spBitmap(ABOUT_ICON, TB_ICONSIZE),  bmpDisabled=wx.NullBitmap, kind=wx.ITEM_NORMAL, shortHelp="About this application")

        # events
        eventslist = [ wx.ID_EXIT, wx.ID_ABOUT, wx.ID_HELP, wx.ID_OPEN, wx.ID_SAVE, wx.ID_NEW, ID_GENERATE, wx.ID_APPLY, wx.ID_EDIT, wx.ID_DELETE ]
        for event in eventslist:
            wx.EVT_TOOL(self, event, self.ProcessEvent)

        toolbar.Realize()
        self.SetToolBar(toolbar)
开发者ID:brigittebigi,项目名称:proceed,代码行数:31,代码来源:manager.py

示例8: _create_toolbar

    def _create_toolbar(self):
        """ Simulate a toolbar."""
        font = self.preferences.GetValue('M_FONT')
        font.SetPointSize(font.GetPointSize() - 2)

        sep_label = wx.StaticText(self, label="Time group separators:", style=wx.ALIGN_CENTER)
        sep_label.SetFont( font )

        self.septext = wx.TextCtrl(self, -1, size=(150,24))
        self.septext.SetFont( font )
        self.septext.SetInsertionPoint(0)
        self.septext.SetBackgroundColour(wx.SystemSettings_GetColour(wx.SYS_COLOUR_WINDOW))
        self.septext.SetForegroundColour(wx.Colour(128,128,128))
        self.septext.SetValue(DEFAULT_SEP)

        broomb = wx.BitmapButton(self, bitmap=spBitmap(BROOM_ICON, 24, theme=self.preferences.GetValue('M_ICON_THEME')), style=wx.NO_BORDER)
        applyb = wx.BitmapButton(self, bitmap=spBitmap(APPLY_ICON, 24, theme=self.preferences.GetValue('M_ICON_THEME')), style=wx.NO_BORDER)

        durlist = ['Use only Midpoint value', 'Add the Radius value', 'Deduct the Radius value']
        withradiusbox = wx.RadioBox(self, -1, label="Annotation durations:", choices=durlist, majorDimension=1, style=wx.RA_SPECIFY_COLS)
        withradiusbox.SetFont( font )

        self.AddToolbar( [sep_label, broomb, self.septext, applyb],[withradiusbox] )

        self.septext.Bind(wx.EVT_TEXT, self.OnTextChanged)
        self.septext.Bind(wx.EVT_SET_FOCUS, self.OnTextClick)
        self.Bind(wx.EVT_BUTTON, self.OnTextErase, broomb)
        self.Bind(wx.EVT_BUTTON, self.OnSeparatorChanged, applyb)
        self.Bind(wx.EVT_RADIOBOX, self.OnWithRadius, withradiusbox)
开发者ID:brigittebigi,项目名称:sppas,代码行数:29,代码来源:tga.py

示例9: __create_sizer

    def __create_sizer(self):

        gbs = wx.GridBagSizer(hgap=5, vgap=5)

        # ---------- Background color

        txt_bg = wx.StaticText(self, -1, "Background color: ")
        gbs.Add(txt_bg, (0, 0), flag=wx.ALL | wx.ALIGN_CENTER_VERTICAL, border=5)

        self.btn_color_bg = wx.BitmapButton(
            self, -1, spBitmap(BG_COLOR_ICON, 24, theme=self.preferences.GetValue("M_ICON_THEME"))
        )
        self.btn_color_bg.Bind(wx.EVT_BUTTON, self.onColorDlg, self.btn_color_bg)
        gbs.Add(self.btn_color_bg, (0, 1), flag=wx.ALL | wx.ALIGN_CENTER_VERTICAL, border=5)

        # ---------- Foreground color

        txt_fg = wx.StaticText(self, -1, "Foreground color: ")
        gbs.Add(txt_fg, (1, 0), flag=wx.ALL | wx.ALIGN_CENTER_VERTICAL, border=5)

        self.btn_color_fg = wx.BitmapButton(
            self, -1, spBitmap(FG_COLOR_ICON, 24, theme=self.preferences.GetValue("M_ICON_THEME"))
        )
        self.btn_color_fg.Bind(wx.EVT_BUTTON, self.onColorDlg, self.btn_color_fg)
        gbs.Add(self.btn_color_fg, (1, 1), flag=wx.ALL | wx.ALIGN_CENTER_VERTICAL, border=5)

        # ---------- Font

        txt_font = wx.StaticText(self, -1, "Font: ")
        gbs.Add(txt_font, (2, 0), flag=wx.ALL | wx.ALIGN_CENTER_VERTICAL, border=5)

        btn_font = wx.BitmapButton(self, -1, spBitmap(FONT_ICON, 24, theme=None))
        self.Bind(wx.EVT_BUTTON, self.onSelectFont, btn_font)
        gbs.Add(btn_font, (2, 1), flag=wx.ALL | wx.ALIGN_CENTER_VERTICAL, border=5)

        # ---------- Sample text

        self.sampleText = stattext.GenStaticText(self, -1, u"  This is a sample text.?!§+={}[]#&$€%éèàù")
        self.sampleText.SetFont(self.preferences.GetValue("M_FONT"))
        self.sampleText.SetBackgroundColour(self.preferences.GetValue("M_BG_COLOUR"))
        self.sampleText.SetForegroundColour(self.preferences.GetValue("M_FG_COLOUR"))

        gbs.Add(self.sampleText, (3, 0), (1, 2), flag=wx.EXPAND | wx.ALIGN_CENTER_VERTICAL, border=5)

        # ---------- tips

        txt_tips = wx.StaticText(self, -1, "Show tips at start-up: ")
        gbs.Add(txt_tips, (4, 0), flag=wx.ALL | wx.ALIGN_CENTER_VERTICAL, border=5)

        btn_tips = wx.CheckBox(self, -1, "")
        btn_tips.SetValue(self.preferences.GetValue("M_TIPS"))
        self.Bind(wx.EVT_CHECKBOX, self.onTipsChecked, btn_tips)
        gbs.Add(btn_tips, (4, 1), flag=wx.ALL | wx.ALIGN_CENTER_VERTICAL, border=5)

        # ----------

        gbs.AddGrowableCol(1)

        return gbs
开发者ID:drammock,项目名称:sppas,代码行数:59,代码来源:settings.py

示例10: SetColour

    def SetColour(self, colour):
        """ Sets the indicator color (red, green or blue). """

        (r,g,b) = colour.Red(), colour.Green(), colour.Blue()
        if r >= g and r >= b:
            bmp = spBitmap( RULER_RED )
        elif g >= r and g >= b:
            bmp = spBitmap( RULER_GREEN )
        else:
            bmp = spBitmap( RULER_BLUE )
        self._img = wx.ImageFromBitmap(bmp)
开发者ID:drammock,项目名称:sppas,代码行数:11,代码来源:timerulerctrl.py

示例11: _set_notebook

    def _set_notebook(self):
        """ Create the notebook and set images. """

        self._notebook = wx.Notebook( self, style=wx.NB_TOP|wx.CLIP_CHILDREN|wx.NB_MULTILINE|wx.NB_NOPAGETHEME|wx.NO_BORDER )
        self._notebook.SetBackgroundColour( self._prefsIO.GetValue( 'M_BG_COLOUR' ) )
        self._notebook.SetForegroundColour( self._prefsIO.GetValue( 'M_FG_COLOUR' ) )
        self._notebook.SetFont( self._prefsIO.GetValue( 'M_FONT' ) )

        # assign images to the notebook
        il = wx.ImageList(16, 16)
        idx1 = il.Add(spBitmap(EMPTY_ICON, 16, theme=self._prefsIO.GetValue('M_ICON_THEME')))
        idx2 = il.Add(spBitmap(NON_EMPTY_ICON, 16, theme=self._prefsIO.GetValue('M_ICON_THEME')))
        self._notebook.AssignImageList(il)
        self._notebookimages = { EMPTY_ICON:idx1, NON_EMPTY_ICON:idx2 }
开发者ID:brigittebigi,项目名称:sppas,代码行数:14,代码来源:baseclient.py

示例12: _create_content

    def _create_content(self):
        label = wx.StaticText(self, label="Search for:", pos=wx.DefaultPosition, size=wx.DefaultSize)
        label.SetBackgroundColour( self.preferences.GetValue('M_BG_COLOUR') )
        label.SetForegroundColour( self.preferences.GetValue('M_FG_COLOUR') )

        self.text = wx.TextCtrl(self, size=(150, -1), validator=TextValidator())
        self.text.SetBackgroundColour(wx.SystemSettings_GetColour(wx.SYS_COLOUR_WINDOW))
        self.text.SetForegroundColour(wx.Colour(128,128,128))
        self.text.SetValue(DEFAULT_LABEL)
        self.text.Bind(wx.EVT_TEXT, self.OnTextChanged)
        self.text.Bind(wx.EVT_SET_FOCUS, self.OnTextClick)

        self.broom = wx.BitmapButton(self, bitmap=spBitmap(BROOM_ICON, 16, theme=self.preferences.GetValue('M_ICON_THEME')), style=wx.NO_BORDER)
        self.broom.Bind(wx.EVT_BUTTON, self.OnTextErase)

        self.pattern_layout = wx.BoxSizer(wx.HORIZONTAL)
        self.pattern_layout.Add(label, 0, wx.RIGHT|wx.ALIGN_CENTER_VERTICAL, border=5)
        self.pattern_layout.Add(self.text, 1, wx.EXPAND|wx.ALIGN_CENTER_VERTICAL)
        self.pattern_layout.Add(self.broom, 0, wx.LEFT|wx.ALIGN_CENTER_VERTICAL, border=5)

        self.tp = TierPanel(self, self._trs)
        self.lp = LabelPanel(self)
        self.sh_layout = wx.BoxSizer(wx.HORIZONTAL)
        self.sh_layout.Add(self.lp, 1, wx.EXPAND|wx.LEFT,  0)
        self.sh_layout.Add(self.tp, 2, wx.EXPAND|wx.RIGHT, 0)
开发者ID:drammock,项目名称:sppas,代码行数:25,代码来源:search.py

示例13: __init__

    def __init__(self, parent, preferences):
        """
        Constructor.
        """
        wx.lib.scrolledpanel.ScrolledPanel.__init__(self, parent, -1, size=wx.DefaultSize, style=wx.NO_BORDER)
        self.SetBackgroundColour(preferences.GetValue('M_BG_COLOUR'))

        # Members
        self.activated = []
        self.step_panels = []
        self.linked = False
        self.parameters  = sppasParam()
        self._prefsIO = preferences
        self.parameters.set_output_format( self._prefsIO.GetValue('M_OUTPUT_EXT') )

        _contentbox = self.__create_content()

        # Button to annotate
        runBmp = spBitmap(ANNOTATE_ICON, BUTTON_ICONSIZE, self._prefsIO.GetValue('M_ICON_THEME'))
        self._brun = CreateGenButton(self, RUN_ID, runBmp, text="  Perform annotations  ", tooltip="Automatically annotate selected files.", colour=wx.Colour(220,100,80), SIZE=BUTTON_ICONSIZE, font=self._prefsIO.GetValue('M_FONT'))

        _vbox = wx.BoxSizer(wx.VERTICAL)
        _vbox.Add(_contentbox, proportion=2, flag=wx.EXPAND | wx.ALL, border=4)
        _vbox.Add(self._brun, proportion=0, flag=wx.ALL|wx.ALIGN_CENTER_HORIZONTAL, border=20)

        self.Bind(wx.EVT_BUTTON, self.on_sppas_run, self._brun, RUN_ID)
        self.SetSizer(_vbox)
        self.SetupScrolling(scroll_x=True, scroll_y=True)
        self.SetMinSize(wx.Size(MIN_PANEL_W,MIN_PANEL_H))
开发者ID:brigittebigi,项目名称:sppas,代码行数:29,代码来源:aannotations.py

示例14: _create_send_other_button

 def _create_send_other_button(self):
     def on_click(evt):
         wx.MessageBox("Copy and paste this email into your favorite email client and send it from there.",
             "Other email client", wx.OK | wx.ICON_INFORMATION)
     bmp = spBitmap(MAIL_OTHER_ICON)
     self.btn_other = CreateGenButton(self,ID_OTHER, bmp, text=" Other", tooltip="Send with another email client.", colour=None)#wx.Colour(220,120,180))
     self.Bind(wx.EVT_BUTTON, on_click, self.btn_other, ID_OTHER)
开发者ID:brigittebigi,项目名称:proceed,代码行数:7,代码来源:feedback.py

示例15: __init__

    def __init__(self, parent, preferences=None, title=""):
        """
        Constructor.

        @param parent is a wx window.
        @param preferences (Preferences)

        """
        wx.Dialog.__init__(self, parent, -1, title=FRAME_TITLE+title, style=DIALOG_STYLE)

        if preferences is None:
            preferences = wxgui.structs.prefs.Preferences()
        self.preferences = preferences

        # menu and toolbar
        self.toolbar = None
        self.btncreator = ButtonCreator(self.preferences)

        # icon
        _icon = wx.EmptyIcon()
        _icon.CopyFromBitmap( spBitmap(APP_ICON) )
        self.SetIcon(_icon)

        # colors
        self.SetBackgroundColour( self.preferences.GetValue('M_BG_COLOUR'))
        self.SetForegroundColour( self.preferences.GetValue('M_FG_COLOUR'))
        self.SetFont( self.preferences.GetValue('M_FONT'))
开发者ID:brigittebigi,项目名称:sppas,代码行数:27,代码来源:basedialog.py


注:本文中的wxgui.cutils.imageutils.spBitmap函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。