コード例 #1
0
ファイル: show_text.py プロジェクト: tuxcanfly/kupfer
	def activate(self, leaf):
		title, body = textutils.extract_title_body(leaf.object)
		if body:
			uiutils.show_notification(title, body,
					icon_name=self.get_icon_name())
		else:
			uiutils.show_notification(title)
コード例 #2
0
ファイル: gtg.py プロジェクト: CharString/kupfer
	def activate(self, leaf):
		interface, apiver = _create_dbus_connection(True)
		title, body = textutils.extract_title_body(leaf.object)
		if apiver == 1:
			interface.open_new_task(title, body)
		else:
			interface.OpenNewTask(title, body)
コード例 #3
0
ファイル: notes.py プロジェクト: pbx/kupfer
def _prepare_note_text(text):
    ## split the text into a title + newline + rest of the text
    ## if we only get the title, put in two helpful newlines
    title, body = textutils.extract_title_body(text)
    if body.lstrip():
        return u"%s\n%s" % (title, body)
    else:
        return u"%s\n\n" % (title, )
コード例 #4
0
ファイル: notes.py プロジェクト: guns/kupfer
def _prepare_note_text(text):
    ## split the text into a title + newline + rest of the text
    ## if we only get the title, put in two helpful newlines
    title, body = textutils.extract_title_body(text)
    if body.lstrip():
        return "%s\n%s" % (title, body)
    else:
        return "%s\n\n" % (title, )
コード例 #5
0
ファイル: gtg.py プロジェクト: jablan/kupfer
 def activate(self, leaf):
     interface = _create_dbus_connection(True)
     title, body = textutils.extract_title_body(leaf.object)
     interface.open_new_task(title, body)
コード例 #6
0
ファイル: gtg.py プロジェクト: DarwinAwardWinner/kupfer
	def activate(self, leaf):
		interface = _create_dbus_connection(True)
		title, body = textutils.extract_title_body(leaf.object)
		interface.open_new_task(title, body)
コード例 #7
0
ファイル: notes.py プロジェクト: cjparsons74/kupfer
def _prepare_note_text(text):
	title, body = textutils.extract_title_body(text)
	if body.lstrip():
		return u"%s\n%s" % (title, body)
	return title