本文整理汇总了Python中PM.PM_ComboBox.PM_ComboBox.clear方法的典型用法代码示例。如果您正苦于以下问题:Python PM_ComboBox.clear方法的具体用法?Python PM_ComboBox.clear怎么用?Python PM_ComboBox.clear使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类PM.PM_ComboBox.PM_ComboBox
的用法示例。
在下文中一共展示了PM_ComboBox.clear方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: DnaGeneratorPropertyManager
# 需要导入模块: from PM.PM_ComboBox import PM_ComboBox [as 别名]
# 或者: from PM.PM_ComboBox.PM_ComboBox import clear [as 别名]
#.........这里部分代码省略.........
<br>
A = Adenosine<br>
C = Cytosine<br>
G = Guanosine<br>
T = Thymidine<br>
N = aNy base<br>
X = Unassigned<br>
<br>
Other base letters currently recognized:<br>
<br>
B = C,G, or T<br>
D = A,G, or T<br>
H = A,C, or T<br>
V = A,C, or G<br>
R = A or G (puRine)<br>
Y = C or T (pYrimidine)<br>
K = G or T (Keto)<br>
M = A or C (aMino)<br>
S = G or C (Strong -3H bonds)<br>
W = A or T (Weak - 2H bonds)<br>
</p>""")
self.actionsComboBox.setWhatsThis("""<b>Action</b>
<p>Select an action to perform on the sequence.</p>""")
def conformationComboBoxChanged( self, inIndex ):
"""
Slot for the Conformation combobox. It is called whenever the
Conformation choice is changed.
@param inIndex: The new index.
@type inIndex: int
"""
self.basesPerTurnComboBox.clear()
conformation = self.conformationComboBox.currentText()
if conformation == "B-DNA":
self.basesPerTurnComboBox.insertItem(0, "10.0")
self.basesPerTurnComboBox.insertItem(1, "10.5")
self.basesPerTurnComboBox.insertItem(2, "10.67")
#10.5 is the default value for Bases per turn.
#So set the current index to 1
self.basesPerTurnComboBox.setCurrentIndex(1)
elif conformation == "Z-DNA":
self.basesPerTurnComboBox.insertItem(0, "12.0")
elif inIndex == -1:
# Caused by clear(). This is tolerable for now. Mark 2007-05-24.
conformation = "B-DNA" # Workaround for "Restore Defaults".
pass
else:
msg = redmsg("conformationComboBoxChanged(): \
Error - unknown DNA conformation. Index = "+ inIndex)
env.history.message(msg)
self.duplexLengthSpinBox.setSingleStep(
self.getDuplexRise(conformation) )
def modelComboBoxChanged( self, inIndex ):
"""
Slot for the Model combobox. It is called whenever the
Model choice is changed.