本文整理汇总了Python中BaseCompanions.WindowDTC类的典型用法代码示例。如果您正苦于以下问题:Python WindowDTC类的具体用法?Python WindowDTC怎么用?Python WindowDTC使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
在下文中一共展示了WindowDTC类的13个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: __init__
def __init__(self, name, designer, parent, ctrlClass):
WindowDTC.__init__(self, name, designer, parent, ctrlClass)
self.editors['Default'] = BoolPropEdit
self.editors['Id'] = ButtonIdConstrPropEdit
self.windowStyles = ['wx.BU_LEFT', 'wx.BU_TOP', 'wx.BU_RIGHT',
'wx.BU_BOTTOM', 'wx.BU_EXACTFIT'] + self.windowStyles
self.customPropEvaluators['Default'] = self.EvalDefault
示例2: __init__
def __init__(self, name, designer, parent, ctrlClass):
WindowDTC.__init__(self, name, designer, parent, ctrlClass)
self.editors['DefaultFilter'] = IntConstrPropEdit
self.windowStyles = ['wx.DIRCTRL_DIR_ONLY', 'wx.DIRCTRL_SELECT_FIRST',
'wx.DIRCTRL_SHOW_FILTERS', 'wx.DIRCTRL_3D_INTERNAL',
'wx.DIRCTRL_EDIT_LABELS'] + self.windowStyles
self.compositeCtrl = True
示例3: __init__
def __init__(self, name, designer, parent, ctrlClass):
WindowDTC.__init__(self, name, designer, parent, ctrlClass)
self.editors.update(
{'BackSpaceUnIndents': BoolPropEdit,
'BufferedDraw': BoolPropEdit,
'CaretLineVisible': BoolPropEdit,
'EndAtLastLine': BoolPropEdit,
'IndentationGuides': BoolPropEdit,
'MouseDownCaptures': BoolPropEdit,
'Overtype': BoolPropEdit,
'ReadOnly': BoolPropEdit,
'UndoCollection': BoolPropEdit,
'UseHorizontalScrollBar': BoolPropEdit,
'UseTabs': BoolPropEdit,
'ViewEOL': BoolPropEdit,
'ViewWhiteSpace': BoolPropEdit,
'EOLMode': EnumPropEdit,
'EdgeMode': EnumPropEdit,
'Lexer': EnumPropEdit,
'PrintColourMode': EnumPropEdit,
'WrapMode': EnumPropEdit,
})
self.options.update({'EOLMode' : stcEOLMode,
'EdgeMode' : stcEdgeMode,
'Lexer': stcLexer,
'PrintColourMode': stcPrintColourMode,
'WrapMode': stcWrapMode,
})
self.names.update({'EOLMode' : stcEOLModeNames,
'EdgeMode' : stcEdgeModeNames,
'Lexer': stcLexerNames,
'PrintColourMode': stcPrintColourModeNames,
'WrapMode': stcWrapModeNames,
})
示例4: persistProp
def persistProp(self, name, setterName, value):
if setterName == 'SetImageList':
imgList, listType = value.split(',')
imgList, listType = imgList.strip(), listType.strip()
for prop in self.textPropList:
if prop.prop_setter == setterName and prop.params[1] == listType:
prop.params = [imgList, listType]
return
self.textPropList.append(methodparse.PropertyParse( None, self.name,
setterName, [imgList, listType], 'SetImageList'))
else:
WindowDTC.persistProp(self, name, setterName, value)
示例5: persistProp
def persistProp(self, name, setterName, value):
if name == 'Default':
for prop in self.textPropList:
if prop.prop_setter == setterName:
if value.lower() == 'true':
prop.params = []
else:
del self.textPropList[self.textPropList.index(prop)]
return
if value.lower() == 'true':
self.textPropList.append(methodparse.PropertyParse(
None, self.getCompName(), setterName, [], name))
else:
WindowDTC.persistProp(self, name, setterName, value)
示例6: notification
def notification(self, compn, action):
WindowDTC.notification(self, compn, action)
if action == 'delete':
for propName, typeName in (('ImageListSmall', 'wx.IMAGE_LIST_SMALL'),
('ImageListNormal', 'wx.IMAGE_LIST_NORMAL')):
imgLst, imgLstType = self.GetImageList(propName)
if imgLst and `imgLst` == `compn.control`:
self.SetImageList(propName, (None,))
idx = 0
while idx < len(self.textPropList):
prop = self.textPropList[idx]
if prop.prop_setter == 'SetImageList' and \
prop.params[1] == typeName:
del self.textPropList[idx]
else:
idx = idx + 1
示例7: properties
def properties(self):
props = WindowDTC.properties(self)
props.update({'Editable': ('CtrlRoute',
wx.grid.Grid.IsEditable, wx.grid.Grid.EnableEditing),
'GridLinesEnabled': ('CtrlRoute',
wx.grid.Grid.GridLinesEnabled, wx.grid.Grid.EnableGridLines)})
return props
示例8: writeImports
def writeImports(self):
return '\n'.join( (WindowDTC.writeImports(self),
'import wx.lib.buttons') )
示例9: events
def events(self):
return WindowDTC.events(self) + ['SpinEvent', 'CmdScrollEvent']
示例10: properties
def properties(self):
props = WindowDTC.properties(self)
props.update({'Bitmap': ('CtrlRoute', wx.BitmapButton.GetBitmapLabel,
wx.BitmapButton.SetBitmapLabel)})
return props
示例11: designTimeControl
def designTimeControl(self, position, size, args = None):
dtc = WindowDTC.designTimeControl(self, position, size, args)
dtc.Enable(False)
return dtc
示例12: events
def events(self):
return WindowDTC.events(self) + ['ComboCtrlEvent']
示例13: writeImports
def writeImports(self):
return '\n'.join( (WindowDTC.writeImports(self),
'from wx.lib.bcrtl.activex.%s import %s' % (
self.comModule, self.comImports)) )