本文整理汇总了Python中gui.widgets.create_task_base.CreateTaskBase.init_api方法的典型用法代码示例。如果您正苦于以下问题:Python CreateTaskBase.init_api方法的具体用法?Python CreateTaskBase.init_api怎么用?Python CreateTaskBase.init_api使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类gui.widgets.create_task_base.CreateTaskBase
的用法示例。
在下文中一共展示了CreateTaskBase.init_api方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: init_api
# 需要导入模块: from gui.widgets.create_task_base import CreateTaskBase [as 别名]
# 或者: from gui.widgets.create_task_base.CreateTaskBase import init_api [as 别名]
def init_api(self):
"""
In plate mode osciallation is start is in the middle of grid
"""
CreateTaskBase.init_api(self)
self._xray_imaging_parameters_widget.init_api()
api.detector_distance.connect(
"positionChanged",
self._xray_imaging_parameters_widget.set_detector_distance,
)
示例2: init_api
# 需要导入模块: from gui.widgets.create_task_base import CreateTaskBase [as 别名]
# 或者: from gui.widgets.create_task_base.CreateTaskBase import init_api [as 别名]
def init_api(self):
CreateTaskBase.init_api(self)
try:
self._periodic_table_widget.set_elements(api.energyscan.getElements())
max_transmission_value = api.energyscan.get_max_transmission_value()
self._adjust_transmission_cbox.setEnabled(True)
self._adjust_transmission_cbox.setChecked(True)
api.energyscan.adjust_transmission(True)
if max_transmission_value:
self._max_transmission_ledit.setText("%.2f" % max_transmission_value)
except BaseException:
pass
示例3: init_api
# 需要导入模块: from gui.widgets.create_task_base import CreateTaskBase [as 别名]
# 或者: from gui.widgets.create_task_base.CreateTaskBase import init_api [as 别名]
def init_api(self):
"""
In plate mode oscillation start is in the middle of the grid
"""
CreateTaskBase.init_api(self)
self._acq_widget.acq_widget_layout.osc_start_label.setText(
"Oscillation middle:"
)
hor_size, ver_size = api.beam_info.get_beam_size()
self.spacing[0] = hor_size
self.spacing[1] = ver_size
self._advanced_methods_widget.hor_spacing_ledit.setText(
"%.1f" % (hor_size * 1000)
)
self._advanced_methods_widget.ver_spacing_ledit.setText(
"%.1f" % (ver_size * 1000)
)
api.graphics.connect("shapeCreated", self.shape_created)
api.graphics.connect("shapeChanged", self.shape_changed)
api.graphics.connect("shapeDeleted", self.shape_deleted)