GNOME Bugzilla – Bug 559570
The context menu in chat should be more consistent with other Gnome apps.
Last modified: 2010-10-04 08:05:32 UTC
The context menu when you right click in a chat window should have the following items (in that specific order): Copy ---- (separator) Select All Clear That would match Epiphany's context menu when you click on the address bar. If the user were to click on a link, the options should be (like in xchat-gnome): Open Link in Browser Copy Link Address ---- (separator) Select All Clear Other information:
Is there any guidelines in GNOME HIG about this?
There isn't specifically for context menu, but regular edit menus should look like that: http://library.gnome.org/devel/hig-book/stable/menus-standard.html.en#menu-standard-edit The suggestion I made happen to match this.
Marking Gnome-love
Hi, i'm trying to fix this. This is what i have already done: - add an entry to the context menu - write the callback function and the ConversationPanel member function - write a function inside GtkXText which selects all the entries It seems to work: it can be selected and deselected; but the last line always keep unselected, and i don't know why. I will investigate this more, but some help on where i can find the last line is welcome. Thank you very much.
Sorry, i mixed up tabs :(
Hi Juan and thanks for your interest in Empathy. :) Could you please attach a patch or upload a git branch with your work? That would be easier for us to help you.
Hi, i thought this bug was related to xchat-gnome, and i fixed what Pierre-Luc said in xchat-gnome... so i'm sorry. However, i'm an Empathy's user, and i can confirm what Pierre-Luc have said: in chat window's menu the order of entries is wrong, but clear option is implemented; and also i think there should be a clear option in the input text field (where you write), which, at least on my empathy, is missing. i will try to solve these issues in a few days, but i promise anything as i am a poor-experienced developer.
Created attachment 138487 [details] [review] This positions Clear entry in the right place.
Which menu is this meant to change?
There is a problem. EmpathyChatTextView is also used to display Previous Conversations, so the clear option will appear there, and i do not know if there it makes much sense... So the solution: check the type of the container of EmpathyChatTextView; but i do not know how to do that... So here is what i have been working on: -fix popup menu order in EmpathyChatTextView -add clear option to the input text field (which actually is a TextView) -iconify the Open Link option, matching Epiphany context menu I need, then, some help on determining which is the container of EmpathyChatTextView... Thank you very much
Davyd, the menu which appears when you right click in a conversation window, in the space reserved to the conversation itself.
That's what I thought. This patch doesn't seem to work for me at all.
Where does the clear item appears for you?
At the top.
Maybe (surely) the patch is bad-generated since i do not know how to create patches, sorry for this; i plan to read a git tutorial this afternoon. But if you change the code by hand, it should work. I have found how to get the parent of a widget; so, what should be the hierarchy of the conversation window?
Created attachment 138791 [details] [review] [NOTE: This is the poor patch] This first patch sets the Clear item in the right position, below the Select All item; and also adds an icon to the Open Link item, as Epiphany does. I have fixed this bug in two ways: - the first patch positions the Clear item below the Select All one, as it should be (as Pierre-Luc pointed out). However, i realized this option does not make sense in the logs window, so i did a few more changes (the second patch) - the second patch adds a new field to the EmpathyChatTextView class, which represent the need of displaying the Clear item; it is set to TRUE by default, and in the EmpathyLogWindow::empathy_log_window_show() function i set it to FALSE. This way, the Clear item is not displayed in the logs window. Finally, i have added a Clear item to the input text view in the EmpathyChat class, as i think it should have one. I made two patches because maybe you do not want to modify class' fields... but i encourage you to see the second patch: it works and solves this issue, and the other minor issues i told you a few lines up. Thank you for your help, i hope you like my work
Created attachment 138796 [details] [review] [NOTE: rich patch] This patch adds a new field to EmpathyChatTextView class; positions well the Clear item, and remove it on logs window; also, adds an icon to Open Link
No one has tried it?
Review of attachment 138796 [details] [review]: Thanks for your patch. Sorry for the late reply. I inlined a comment; except that your patch looks fine. ::: libempathy-gtk/empathy-chat-text-view.c @@ +271,2 @@ /* Clear menu item */ + g_object_get (view, "show-clear", &show_clear, NULL); You shouldn't get the property as you are already in the object. Just use priv->show_clear
Ok. I think last time I used Empathy this issue was already solved, so this solutions is outdated. But thank you very much! this was my first patch, and I learnt a lot looking in Empathy's code. And of course I agree with you: within the object I should use direct access to the property. Thank you!
I just check with master and the context menu in master is: Clear ----- Copy Select All or Open Link Copy Link Address ----- Clear ----- Select All According ot Pierre-Luc's initial report, in the first case "Copy" should be first and in the link case we shouldn't put a separator between "Clear" and "Select All".
*** Bug 621474 has been marked as a duplicate of this bug. ***
due to a bug in gtk i.e. it selects the first item when you right click. if you have a little mal-functioning left click you could easily remove the text by mistake. also reported at: https://bugs.launchpad.net/empathy/+bug/589974
This bug has been fixed, as a result of the fix for bug #629544 .
*** This bug has been marked as a duplicate of bug 629544 ***