本文整理汇总了Python中sublime.View.is_popup_visible方法的典型用法代码示例。如果您正苦于以下问题:Python View.is_popup_visible方法的具体用法?Python View.is_popup_visible怎么用?Python View.is_popup_visible使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类sublime.View
的用法示例。
在下文中一共展示了View.is_popup_visible方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: prepare_data_tooltip
# 需要导入模块: from sublime import View [as 别名]
# 或者: from sublime.View import is_popup_visible [as 别名]
def prepare_data_tooltip(
self, view: sublime.View, data: Dict[str, Any]) -> Any:
"""Prepare the returned data for tooltips
"""
merge_doc = get_settings(view, 'merge_signatures_and_doc')
if (data['success'] and 'No docstring' not
in data['doc'] and data['doc'] != 'list\n'):
try:
i = data['doc'].split('<br>').index("")
except ValueError:
self.signature = data['doc']
self.doc = ''
if self._signature_excluded(self.signature):
return
return self._show_popup(view)
if merge_doc:
self.doc = '<br>'.join(data['doc'].split('<br>')[i:]).replace(
" ", " ")
self.signature = '<br> '.join(
data['doc'].split('<br>')[0:i])
if self.signature is not None and self.signature != "":
if not self._signature_excluded(self.signature):
return self._show_popup(view)
if view.is_popup_visible():
view.hide_popup()
view.erase_status('anaconda_doc')