From a5c067fd932f8f67a41556929b59587d0cb48332 Mon Sep 17 00:00:00 2001 From: mathieui Date: Sun, 2 Oct 2011 00:12:22 +0200 Subject: /clear command in MUC --- src/tabs.py | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/src/tabs.py b/src/tabs.py index fbcfc597..8ddf60ad 100644 --- a/src/tabs.py +++ b/src/tabs.py @@ -414,6 +414,8 @@ class MucTab(ChatTab): self.commands['configure'] = (self.command_configure, _('Usage: /configure\nConfigure: Configure the current room, through a form.'), None) self.commands['version'] = (self.command_version, _('Usage: /version \nVersion: get the software version of the given JID or nick in room (usually its XMPP client and Operating System)'), None) self.commands['names'] = (self.command_names, _('Usage: /names\nNames: get the list of the users in the room, and the list of the people assuming the different roles.'), None) + self.commands['clear'] = (self.command_clear, + _("""Usage: /clear\nClear: clears the current buffer'"""), None) self.resize() def scroll_user_list_up(self): @@ -461,6 +463,15 @@ class MucTab(ChatTab): self.core.xmpp.plugin['xep_0045'].configureRoom(self.get_name(), form) self.core.close_tab() + def command_clear(self, args): + """ + /clear + """ + self._room.messages = [] + self.text_win.rebuild_everything(self._room) + self.refresh() + self.core.doupdate() + def command_cycle(self, arg): if self.get_room().joined: muc.leave_groupchat(self.core.xmpp, self.get_name(), self.get_room().own_nick, arg) -- cgit v1.2.3 From 4dfe2229da7052985736bef93c7b02c179780548 Mon Sep 17 00:00:00 2001 From: Florent Le Coz Date: Sat, 1 Oct 2011 22:47:47 +0200 Subject: remove white from the nick colors --- src/theming.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/theming.py b/src/theming.py index 382a3146..4bfdad42 100644 --- a/src/theming.py +++ b/src/theming.py @@ -118,7 +118,7 @@ class Theme(object): # A list of colors randomly attributed to nicks in MUCs # Setting more colors makes it harder to have two nicks with the same color, # avoiding confusions. - LIST_COLOR_NICKNAMES = [(1, -1), (2, -1), (3, -1), (4, -1), (5, -1), (6, -1), (7, -1), (8, -1), (9, -1), (10, -1), (11, -1), (12, -1), (13, -1), (14, -1), (23, -1), (23, -1), (88, -1), (99, -1), (100, -1), (154, -1), (213, -1), (216, -1), (227, -1)] + LIST_COLOR_NICKNAMES = [(1, -1), (2, -1), (3, -1), (4, -1), (5, -1), (6, -1), (8, -1), (9, -1), (10, -1), (11, -1), (12, -1), (13, -1), (14, -1), (23, -1), (23, -1), (88, -1), (99, -1), (100, -1), (154, -1), (213, -1), (216, -1), (227, -1)] # This is your own nickname COLOR_OWN_NICK = (254, -1) -- cgit v1.2.3