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


Python wx.SUNKEN_BORDER属性代码示例

本文整理汇总了Python中wx.SUNKEN_BORDER属性的典型用法代码示例。如果您正苦于以下问题:Python wx.SUNKEN_BORDER属性的具体用法?Python wx.SUNKEN_BORDER怎么用?Python wx.SUNKEN_BORDER使用的例子?那么, 这里精选的属性代码示例或许可以为您提供帮助。您也可以进一步了解该属性所在wx的用法示例。


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

示例1: __init__

# 需要导入模块: import wx [as 别名]
# 或者: from wx import SUNKEN_BORDER [as 别名]
def __init__(self, parent):
        wx.Panel.__init__(self, parent, size=(-1, 25), style=wx.SUNKEN_BORDER)

        self._value = LEVEL_MIN
        self._threshold = LEVEL_MIN
        self._noise = None

        font = self.GetFont()
        font.SetFamily(wx.FONTFAMILY_MODERN)
        self.SetFont(font)

        self.SetMinSize((250, 25))

        self.Bind(wx.EVT_PAINT, self.__on_paint)
        self.Bind(wx.EVT_SIZE, self.__on_size)

        try:
            self.SetBackgroundStyle(wx.BG_STYLE_PAINT)
        except AttributeError:
            pass 
开发者ID:EarToEarOak,项目名称:RF-Monitor,代码行数:22,代码来源:widget_meter.py

示例2: __init__

# 需要导入模块: import wx [as 别名]
# 或者: from wx import SUNKEN_BORDER [as 别名]
def __init__(self, parent, gui_size):
        h = gui_size[0]
        w = gui_size[1]
        wx.Panel.__init__(self, parent, -1, style=wx.SUNKEN_BORDER, size=(h, w))

        ##         design the panel
        sizer = wx.GridBagSizer(10, 7)
        # Add image of DLC
        icon = wx.StaticBitmap(self, bitmap=wx.Bitmap(dlc))
        sizer.Add(icon, pos=(0, 0), span=(0, 8), flag=wx.EXPAND | wx.BOTTOM, border=10)
        line = wx.StaticLine(self)
        sizer.Add(line, pos=(1, 0), span=(1, 8), flag=wx.EXPAND | wx.BOTTOM, border=10)

        # if editing this text make sure you add the '\n' to get the new line. The sizer is unable to format lines correctly.
        description = "DeepLabCut™ is an open source tool for markerless\npose estimation of user-defined body parts with deep learning.\nA. and M.W. Mathis Labs | http://www.deeplabcut.org\n \nWelcome to the DeepLabCut Project Manager GUI!\nTo get started, please click on the 'Manage Project'\n tab to create or load an existing project. \n "

        self.proj_name = wx.StaticText(self, label=description, style=wx.ALIGN_CENTRE)
        sizer.Add(self.proj_name, pos=(2, 3), border=10)
        sizer.AddGrowableCol(2)
        self.SetSizer(sizer)
        sizer.Fit(self) 
开发者ID:DeepLabCut,项目名称:DeepLabCut,代码行数:23,代码来源:welcome.py

示例3: __init__

# 需要导入模块: import wx [as 别名]
# 或者: from wx import SUNKEN_BORDER [as 别名]
def __init__(self, parent, **kwds):
        super(PDFViewer, self).__init__(parent, **kwds)

        paneCont = self.GetContentsPane()
        self.buttonpanel = pdfButtonPanel(paneCont, wx.NewId(),
                                wx.DefaultPosition, wx.DefaultSize, 0)
        self.buttonpanel.SetSizerProps(expand=True)
        self.viewer = pdfViewer(paneCont, wx.NewId(), wx.DefaultPosition,
                                wx.DefaultSize,
                                wx.HSCROLL|wx.VSCROLL|wx.SUNKEN_BORDER)

        self.viewer.SetSizerProps(expand=True, proportion=1)

        # introduce buttonpanel and viewer to each other
        self.buttonpanel.viewer = self.viewer
        self.viewer.buttonpanel = self.buttonpanel 
开发者ID:pymupdf,项目名称:PyMuPDF-Utilities,代码行数:18,代码来源:pdfviewer(wx).py

示例4: __init__

# 需要导入模块: import wx [as 别名]
# 或者: from wx import SUNKEN_BORDER [as 别名]
def __init__(self, parent, label, title="", mesg="", imageString=None):
        self.title = title
        self.mesg = mesg
        self.imageString = imageString
        wx.Window.__init__(self, parent, -1)
        self.button = wx.Button(self, -1, label)
        self.imageBox = wx.StaticBitmap(
            self, -1, size=(10, 10), style=wx.SUNKEN_BORDER
        )
        self.SetValue(imageString)
        sizer = wx.BoxSizer(wx.HORIZONTAL)
        sizer.Add(self.button, 0, wx.RIGHT | wx.ALIGN_CENTER_VERTICAL, 5)
        sizer.Add(self.imageBox, 1, wx.EXPAND | wx.ALIGN_CENTER_VERTICAL)
        self.SetSizer(sizer)
        self.Bind(wx.EVT_BUTTON, self.OnButton)
        self.Bind(wx.EVT_SIZE, self.OnSize)
        self.Bind(wx.EVT_SET_FOCUS, self.OnSetFocus)
        self.Layout() 
开发者ID:EventGhost,项目名称:EventGhost,代码行数:20,代码来源:ImagePicker.py

示例5: __init__

# 需要导入模块: import wx [as 别名]
# 或者: from wx import SUNKEN_BORDER [as 别名]
def __init__(self, parent, html):
        wx.Panel.__init__(self, parent)
        htmlWindow = eg.HtmlWindow(
            self,
            style=wx.SUNKEN_BORDER | wx.html.HW_NO_SELECTION
        )
        htmlWindow.SetForegroundColour(eg.colour.windowText)
        htmlWindow.SetBackgroundColour(eg.colour.windowBackground)
        htmlWindow.SetPage(html)
        htmlWindow.SetMinSize((490, 270))
        htmlWindow.SetScrollbars(1, 1, 1000, 1000)
        self.SetSizerAndFit(
            eg.VBoxSizer(
                (htmlWindow, 1, wx.EXPAND, 5),
            )
        )
        self.htmlWindow = htmlWindow 
开发者ID:EventGhost,项目名称:EventGhost,代码行数:19,代码来源:AboutDialog.py

示例6: __init__

# 需要导入模块: import wx [as 别名]
# 或者: from wx import SUNKEN_BORDER [as 别名]
def __init__(self, *args, **kwds):
        # begin wxGlade: MainFrame.__init__
        kwds["style"] = wx.DEFAULT_FRAME_STYLE
        wx.Frame.__init__(self, *args, **kwds)
        
        # Menu Bar
        self.frame_2_menubar = wx.MenuBar()
        wxglade_tmp_menu = wx.Menu()
        self.opf = wx.MenuItem(wxglade_tmp_menu, wx.NewId(), "Open folder..", "", wx.ITEM_NORMAL)
        wxglade_tmp_menu.AppendItem(self.opf)

        self.opfi = wx.MenuItem(wxglade_tmp_menu, wx.NewId(), "Open file..", "", wx.ITEM_NORMAL)
        wxglade_tmp_menu.AppendItem(self.opfi)
        wxglade_tmp_menu.AppendSeparator()
        self.ana = wx.MenuItem(wxglade_tmp_menu, wx.NewId(), "Analyze", "", wx.ITEM_NORMAL)
        wxglade_tmp_menu.AppendItem(self.ana)
        self.frame_2_menubar.Append(wxglade_tmp_menu, "File")
        self.SetMenuBar(self.frame_2_menubar)
        # Menu Bar end
        self.list_ctrl_1 = wx.ListCtrl(self, -1, style=wx.LC_REPORT | wx.SUNKEN_BORDER)
        for i in range(512):
            self.list_ctrl_1.InsertColumn(i, str(i), width=30)
        self.__set_properties()
        self.__do_layout()

        self.Bind(wx.EVT_MENU, self.of, self.opf)
        self.Bind(wx.EVT_MENU, self.anlz, self.ana)
        self.Bind(wx.EVT_MENU, self.ofi, self.opfi)
        # end wxGlade 
开发者ID:c3c,项目名称:E-Safenet,代码行数:31,代码来源:esafenet_gui.py

示例7: __init__

# 需要导入模块: import wx [as 别名]
# 或者: from wx import SUNKEN_BORDER [as 别名]
def __init__(self, parent, height):
		wx.ListCtrl.__init__(self, parent, -1, style=wx.LC_REPORT | wx.SUNKEN_BORDER, size=(565, height))
		CheckListCtrlMixin.__init__(self)
		ListCtrlAutoWidthMixin.__init__(self) 
开发者ID:sailoog,项目名称:openplotter,代码行数:6,代码来源:NMEA_2000_generator.py

示例8: __init__

# 需要导入模块: import wx [as 别名]
# 或者: from wx import SUNKEN_BORDER [as 别名]
def __init__(self, parent, id=-1, title="Wfuzz", pos=wx.DefaultPosition,
                 size=wx.DefaultSize,
                 style=wx.DEFAULT_FRAME_STYLE | wx.SUNKEN_BORDER | wx.CLIP_CHILDREN
                 ):
        wx.Frame.__init__(self, parent, id, title, pos, size, style) 
开发者ID:xmendez,项目名称:wfuzz,代码行数:7,代码来源:guicontrols.py

示例9: __init__

# 需要导入模块: import wx [as 别名]
# 或者: from wx import SUNKEN_BORDER [as 别名]
def __init__(self, parent, config, gui_size, **kwargs):
        h = gui_size[0] / 2
        w = gui_size[1] / 3
        wx.Panel.__init__(self, parent, -1, style=wx.SUNKEN_BORDER, size=(h, w))

        self.figure = matplotlib.figure.Figure()
        self.axes = self.figure.add_subplot(1, 1, 1)
        self.canvas = FigureCanvas(self, -1, self.figure)
        self.sizer = wx.BoxSizer(wx.VERTICAL)
        self.sizer.Add(self.canvas, 1, wx.LEFT | wx.TOP | wx.GROW)
        self.SetSizer(self.sizer)
        self.Fit() 
开发者ID:DeepLabCut,项目名称:DeepLabCut,代码行数:14,代码来源:select_crop_parameters.py

示例10: __init__

# 需要导入模块: import wx [as 别名]
# 或者: from wx import SUNKEN_BORDER [as 别名]
def __init__(self, parent, gui_size, **kwargs):
        h = gui_size[0] / 2
        w = gui_size[1] / 3
        wx.Panel.__init__(self, parent, -1, style=wx.SUNKEN_BORDER, size=(h, w))

        self.figure = matplotlib.figure.Figure()
        self.axes = self.figure.add_subplot(1, 1, 1)
        self.canvas = FigureCanvas(self, -1, self.figure)
        self.sizer = wx.BoxSizer(wx.VERTICAL)
        self.sizer.Add(self.canvas, 1, wx.LEFT | wx.TOP | wx.GROW)
        self.SetSizer(self.sizer)
        self.Fit() 
开发者ID:DeepLabCut,项目名称:DeepLabCut,代码行数:14,代码来源:outlier_frame_extraction_toolbox.py

示例11: __init__

# 需要导入模块: import wx [as 别名]
# 或者: from wx import SUNKEN_BORDER [as 别名]
def __init__(self, parent):
        wx.Panel.__init__(self, parent, -1, style=wx.SUNKEN_BORDER) 
开发者ID:DeepLabCut,项目名称:DeepLabCut,代码行数:4,代码来源:refinement.py

示例12: __init__

# 需要导入模块: import wx [as 别名]
# 或者: from wx import SUNKEN_BORDER [as 别名]
def __init__(self, parent, config, gui_size, **kwargs):
        h = gui_size[0] / 2
        w = gui_size[1] / 3
        wx.Panel.__init__(self, parent, -1, style=wx.SUNKEN_BORDER, size=(h, w))

        self.figure = matplotlib.figure.Figure()
        self.axes = self.figure.add_subplot(1, 1, 1)
        self.canvas = FigureCanvas(self, -1, self.figure)
        self.orig_xlim = None
        self.orig_ylim = None
        self.sizer = wx.BoxSizer(wx.VERTICAL)
        self.sizer.Add(self.canvas, 1, wx.LEFT | wx.TOP | wx.GROW)
        self.SetSizer(self.sizer)
        self.Fit() 
开发者ID:DeepLabCut,项目名称:DeepLabCut,代码行数:16,代码来源:multiple_individuals_refinement_toolbox.py

示例13: new_sample

# 需要导入模块: import wx [as 别名]
# 或者: from wx import SUNKEN_BORDER [as 别名]
def new_sample(self, sample_class, value):
        sample = sample_class(self, size=wx.Size(-1, 20), style=wx.SUNKEN_BORDER)
        # I happen to know 200 is the right number because I looked.
        sample.SetValue(self.sample_value, 'running', (200, 0, self.sample_data))
        sample.Bind(wx.EVT_LEFT_DOWN, self.sample)
        sample.Bind(wx.EVT_CONTEXT_MENU, None)
        sample.value = value
        return sample 
开发者ID:kenorb-contrib,项目名称:BitTorrent,代码行数:10,代码来源:SettingsWindow.py

示例14: __init__

# 需要导入模块: import wx [as 别名]
# 或者: from wx import SUNKEN_BORDER [as 别名]
def __init__(self, parent, id=-1, label='', pos=(-1, -1), size=(-1, -1)):
        wx.PyWindow.__init__(
            self,
            parent,
            id,
            pos,
            size,
            style=wx.SUNKEN_BORDER
        )
        self.SetMinSize(self.GetSize())
        sizer = wx.BoxSizer(wx.VERTICAL)
        textCtrl = wx.TextCtrl(
            self,
            -1,
            label,
            style=(
                wx.TE_MULTILINE |
                wx.TE_NO_VSCROLL |
                wx.NO_BORDER |
                wx.TE_READONLY
            )
        )
        textCtrl.SetBackgroundColour(self.GetBackgroundColour())
        #sizer.Add((0,0), 1, wx.EXPAND)
        sizer.Add(textCtrl, 0, wx.EXPAND | wx.ALL, 3)
        sizer.Add((0, 0), 1, wx.EXPAND)
        self.SetSizer(sizer)
        self.Bind(wx.EVT_SIZE, self.OnSize)
        self.textCtrl = textCtrl 
开发者ID:EventGhost,项目名称:EventGhost,代码行数:31,代码来源:StaticTextBox.py

示例15: __init__

# 需要导入模块: import wx [as 别名]
# 或者: from wx import SUNKEN_BORDER [as 别名]
def __init__(
        self,
        parent=None,
        title=eg.APP_NAME,
        source="",
        icon=None,
        basePath=None,
        style=wx.OK
    ):
        eg.Dialog.__init__(
            self,
            parent,
            -1,
            title,
            style=wx.DEFAULT_DIALOG_STYLE | wx.RESIZE_BORDER
        )
        if icon:
            self.SetIcon(icon)
        htmlCtrl = eg.HtmlWindow(self, -1, style=wx.SUNKEN_BORDER)
        htmlCtrl.SetBorders(2)
        htmlCtrl.SetBasePath(basePath)
        htmlCtrl.SetPage(source)
        buttonIds = []
        if style & wx.OK:
            buttonIds.append(wx.ID_OK)
        if style & wx.CANCEL:
            buttonIds.append(wx.ID_CANCEL)
        self.buttonRow = eg.ButtonRow(self, buttonIds, True, True)
        mainSizer = eg.VBoxSizer(
            (htmlCtrl, 1, wx.EXPAND | wx.ALL, 5),
            (self.buttonRow.sizer, 0, wx.EXPAND),
        )
        self.SetSizerAndFit(mainSizer)
        if Config.position is not None:
            self.SetPosition(Config.position)
        self.SetSize(Config.size) 
开发者ID:EventGhost,项目名称:EventGhost,代码行数:38,代码来源:HtmlDialog.py


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