Bug 112479 - gcalctool the slash "/" key (division) is not taken into account.
Summary: gcalctool the slash "/" key (division) is not taken into account.
Keywords:
Status: CLOSED UPSTREAM
Alias: None
Product: Fedora
Classification: Fedora
Component: gnome-utils
Version: 1
Hardware: i686
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Havoc Pennington
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2003-12-20 17:34 UTC by marc frei
Modified: 2007-11-30 22:10 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2004-03-09 22:14:01 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
gnome-utils-2.4.0-shiftslash.patch (635 bytes, patch)
2004-02-24 21:24 UTC, Bart Martens
no flags Details | Diff

Description marc frei 2003-12-20 17:34:48 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.5)
Gecko/20031007 Firebird/0.7

Description of problem:
In gcalctool, the slash "/" key is not taken into account.

Works for all the other operator (+, -, * etc...)



Version-Release number of selected component (if applicable):
4.3.3

How reproducible:
Always

Steps to Reproduce:
1. in gcalctool, type (=keyboard) 10 / 2 [enter]
2. 
3.
    

Actual Results:  it displays 102

Expected Results:  5

Additional info:


I'm on a laptop, the "/" is obtained with [shift] + [7]   (Swiss
French keyboard)

Comment 1 marc frei 2003-12-20 17:40:26 UTC
I forgot :

My language/local is "French".

Comment 2 Bart Martens 2004-02-24 21:24:20 UTC
Created attachment 98014 [details]
gnome-utils-2.4.0-shiftslash.patch

I had exactly the same problem on my be-latin1 keyboard. So I fixed it by
adding shift-slash as a valid key combination.

Marc, I doubt that this patch solves your problem. I think you need the
combination of GDK_SHIFT_MASK with one of GDK_7, GDK_KP_7, GDK_KP_Home or
GDK_R7, or maybe even something else. Or can you tell me the key code of that
[7] key you use?

Some key codes from /usr/include/gtk-2.0/gdk/gdkkeysyms.h :
#define GDK_7 0x037
#define GDK_KP_7 0xFFB7
#define GDK_KP_Home 0xFF95
#define GDK_R7 0xFFD8

Comment 3 Bart Martens 2004-02-24 21:37:22 UTC
Marc, use xev (XFree86-tools) to find the key code. See the
hexadecimal code appearing next to the word "keysym".


Comment 4 marc frei 2004-02-25 19:50:45 UTC
Huuh ?

With xev, here is the key combination not taken into account :

KeyPress event, serial 23, synthetic NO, window 0x4400001,
    root 0x3b, subw 0x0, time 261877011, (171,-11), root:(715,75),
    state 0x0, keycode 62 (keysym 0xffe2, Shift_R), same_screen YES,
    XLookupString gives 0 bytes:  ""

KeyPress event, serial 23, synthetic NO, window 0x4400001,
    root 0x3b, subw 0x0, time 261878439, (171,-11), root:(715,75),
    state 0x1, keycode 16 (keysym 0x2f, slash), same_screen YES,
    XLookupString gives 1 bytes:  "/"

KeyRelease event, serial 23, synthetic NO, window 0x4400001,
    root 0x3b, subw 0x0, time 261878549, (171,-11), root:(715,75),
    state 0x1, keycode 16 (keysym 0x2f, slash), same_screen YES,
    XLookupString gives 1 bytes:  "/"

KeyRelease event, serial 23, synthetic NO, window 0x4400001,
    root 0x3b, subw 0x0, time 261879349, (171,-11), root:(715,75),
    state 0x1, keycode 62 (keysym 0xffe2, Shift_R), same_screen YES,
    XLookupString gives 0 bytes:  ""

Do you suggest to add this to a "xmodmap" file ?

Thanks.

M.

Comment 5 Bart Martens 2004-02-25 21:16:31 UTC
It surprises me that the 7-key on your keyboard has the 0x2f key code.
OK, then the patch I uploaded in comment #2 should solve your problem.
I will send you a patched rpm via e-mail. Please report your test
results here.


Comment 6 marc frei 2004-02-26 18:35:19 UTC
Thanks Bart !

The patch (gnome-utils-2.4.0-1.0.2.bartm.i386.rpm) that you sent me,
solved the problem.

No regression on this other operators ;-) 

Thanks for your help.

M.


Comment 7 Bart Martens 2004-02-26 19:10:48 UTC
Thanks for testing and reporting here, Marc. So the patch solves the
problem for both keyboard layouts.

Rich has used the patch upstream. It will be included in gcalctool
version 4.3.47.
http://bugzilla.gnome.org/show_bug.cgi?id=135328



Note You need to log in before you can comment on or make changes to this bug.