make clearer what we do
This commit is contained in:
		
							parent
							
								
									2f503fa7bf
								
							
						
					
					
						commit
						4c2f8d9400
					
				
					 3 changed files with 6 additions and 8 deletions
				
			
		|  | @ -906,7 +906,7 @@ class ChatControl(ChatControlBase): | |||
| 		status = contact.status | ||||
| 		if status is not None: | ||||
| 			banner_name_label.set_ellipsize(pango.ELLIPSIZE_END) | ||||
| 			status = gtkgui_helpers.reduce_chars_newlines(status, 0, 2) | ||||
| 			status = gtkgui_helpers.reduce_chars_newlines(status, max_lines = 2) | ||||
| 		status_escaped = gtkgui_helpers.escape_for_pango_markup(status) | ||||
| 
 | ||||
| 		#FIXME: uncomment me when we support sending messages to specific resource | ||||
|  |  | |||
|  | @ -553,7 +553,7 @@ class GroupchatControl(ChatControlBase): | |||
| 		self.subject = subject | ||||
| 
 | ||||
| 		self.name_label.set_ellipsize(pango.ELLIPSIZE_END) | ||||
| 		subject = gtkgui_helpers.reduce_chars_newlines(subject, 0, 2) | ||||
| 		subject = gtkgui_helpers.reduce_chars_newlines(subject, max_lines = 2) | ||||
| 		subject = gtkgui_helpers.escape_for_pango_markup(subject) | ||||
| 		font_attrs, font_attrs_small = self.get_font_attrs() | ||||
| 		text = '<span %s>%s</span>' % (font_attrs, self.room_jid) | ||||
|  |  | |||
|  | @ -1,11 +1,8 @@ | |||
| ##	tooltips.py | ||||
| ## | ||||
| ## Copyright (C) 2005-2006 Gajim Team | ||||
| ##  | ||||
| ## Contributors for this file: | ||||
| ##	- Dimitur Kirov <dkirov@gmail.com> | ||||
| ##	- Yann Le Boulanger <asterix@lagaule.org> | ||||
| ##	- Nikos Kouremenos <kourem@gmail.com> | ||||
| ## Copyright (C) 2005-2006 Dimitur Kirov <dkirov@gmail.com> | ||||
| ## Copyright (C) 2005-2006 Nikos Kouremenos <kourem@gmail.com> | ||||
| ## Copyright (C) 2005-2006 Yann Le Boulanger <asterix@lagaule.org> | ||||
| ## | ||||
| ## This program is free software; you can redistribute it and/or modify | ||||
| ## it under the terms of the GNU General Public License as published | ||||
|  | @ -185,6 +182,7 @@ class StatusTable: | |||
| 				# make sure 'status' is unicode before we send to to reduce_chars | ||||
| 				if isinstance(status, str): | ||||
| 					status = unicode(status, encoding='utf-8') | ||||
| 				# reduce to 200 chars, 1 line | ||||
| 				status = gtkgui_helpers.reduce_chars_newlines(status, 200, 1) | ||||
| 				str_status += ' - ' + status | ||||
| 		return gtkgui_helpers.escape_for_pango_markup(str_status) | ||||
|  |  | |||
		Loading…
	
	Add table
		
		Reference in a new issue