![]() |
N900 keyboard friendly, second thread.
This is the second thread for my project in which I aim to make the N900 usable without touching the screen.
The programs are now installable by packages which are available in my repository. You can install the keyboard shortcuts package by using this install file. If you want to add the repository manually, add the line Code:
deb http://my.arava.co.il/~matan/repo/binary/ ./ The repository includes modified-hildon-desktop (see description of this package on the wiki page) and keyboard-shortcuts. Keyboard shortcuts are still only configurable by editing the python script /usr/bin/keyboard-shortcut, but I hope looking at the file will make it easy for anyone to configure it as they want. The default shortcuts in the package include: ctrl+shift+
|
Re: N900 keyboard friendly, second thread.
Massive thanks for your work on this Matan, I’ve only installed the base Modified Hildon Desktop package and seems really useful already.
I’m just a little confused how to implement the other custom tweaks to this from the Wiki page. Apologies if this is a very basic question, I’ve no previous linux experience and I only opened the x-terminal for the first time yesterday so somewhat of a beginner. I have since done a few of the other simple MODs from the MOD thread (LED colour change, swapping Shift/Fn keys etc.) though so I can follow instructions if explained simply. It’s the first paragraph from the wiki page that I’m not quite sure about... Quote:
Cheers |
Re: N900 keyboard friendly, second thread.
I added gconftool-2 examples to the wiki page. I hope they clarify the issue.
|
Re: N900 keyboard friendly, second thread.
Is it possible to have a target the size of an icon square that can be moved like on normal Symbian and other non-touch OS's? Kinda like how the Blackberry Storm lets you select without activating until actually pressed. This way we could use the arrow keys to highlight things and a button like enter/space/ctrl etc as select. It would have to be different on the homescreen, perhaps an intelligent highlight that cycles through what's on the screen with up and down, and left and right to change desktop screens.
Ok I'm probably thinking of something way too complicated... as it would only be active with the keyboard open. |
Re: N900 keyboard friendly, second thread.
Quote:
But Maemo 6 will also have desktops above and below. I think up, down, left, right to move from icon to icon and add shift to arrow to change desktops. I would also like to be able to use arrow keys to fine tune icon placement. Put desktop in icon location change mode, tap icon to select, then each arrow key press moves the icon 1 pixel. |
Re: N900 keyboard friendly, second thread.
Quote:
Thanks again. |
Re: N900 keyboard friendly, second thread.
I have also set up the keyboard-shortcuts app now but due to another MOD I've put in reversing the mapping of the Shift and Fn keys to make shortcuts like Ctrl+Shift+X (open X-terminal) and Ctrl+Shift+H (Go to homescreen) easy to do without a stretch all the following shortcuts:
Quote:
Quote:
Or if not, is it possible to change what's in the /usr/bin/keyboard-shortcut script so the all of those shortcuts are meant to work with Ctrl+Fn+<other key> (and consequently, as the mapping is reversed, the easier combination of Ctrl+Shift+<other key> ? Sorry if this sounds convoluted, basically what I am trying to achieve is to have all the shortcuts that require 3 keys to be pressed to be done using the actual Shift + Fn buttons. Cheers |
Re: N900 keyboard friendly, second thread.
/apps/osso/hildon-desktop/key-actions/dbus_shortcuts_use_fn is only read at startup time, so you need to reboot (or simply "killall hildon-desktop", but that does not always work).
|
Re: N900 keyboard friendly, second thread.
Perfect, thanks :)
|
Re: N900 keyboard friendly, second thread.
I think you do great work. But let me tell you about user friendly keyboard.
I don't know what layout you have on your keyboard. On my Swiss keyboard Shift - all the way to the left on bottom row Strg - all the way to the left on top row. I just dont find a way to press these two buttons with two fingers of the same hand without making strange faces. I guess my fingers are just to wide. And if I use fingers of both hands I miss my third hand to hit the extra key. Am I the only one with this problem. Markus |
Re: N900 keyboard friendly, second thread.
I used to exchange shift and fn, so shift and ctrl were next to each other and could be pressed by a single finger. There is also the option dbus_shortcuts_use_fn (discussed above in this thread) which makes shortcuts use ctrl+fn, which are next to each other by default, so you get the same effect. It might conflict with fn+ctrl for opening special virtual keyboard, so you have to make sure you press ctrl first and fn second.
|
Re: N900 keyboard friendly, second thread.
I'm trying to change the keyboard shortcuts to launch different application with Ctrl + Shift + <Letter Key> combinations but as yet have not been successful. I'm editing the /usr/bin/keyboard-shortcut script in leafpad and I used the existing "FBReader" shortcut as a template to try to get it to work for other apps.
Under the section “# CTRL + SHIFT + KEY” I replaced the lines: If key == ‘F’: osso_exec(“FBReader”) With: If key == ‘F’: osso_exec(“Media player”) I then saved and rebooted but nothing happened when I pressed Ctrl + Shift + <F> I tried to do the same but instead putting in the line: If key == ‘F’: osso_exec(“Firefox”) but again nothing when pressing Ctrl + Shift + <F>. The original shortcuts from the script like Ctrl + Shift + <A> - Control panel work fine. Can anyone see what I am doing wrong here? Is the way in which app names are displayed in the launcher different to the app name that this script looks for? Also, does it require a different command for native apps like Media player to installed apps like Firefox? |
Re: N900 keyboard friendly, second thread.
Quote:
|
Re: N900 keyboard friendly, second thread.
Thanks, how do I find out the name of applications that the script looks for?
|
Re: N900 keyboard friendly, second thread.
I've tried again using:
If key == ‘F’: osso_exec(“mediaplayer”) and then If key == ‘F’: osso_exec(“browser”) and rebooting after each edit but still no luck. I can only assume I am either editing the section incorrectly or need to make edits somewhere else as well. Anyone have any ideas please? |
Re: N900 keyboard friendly, second thread.
Find the names by examining the files in /usr/share/dbus-1/services/. You need to look at the line Name= in each file and ignore the com.nokia at the start.
fennec is called mozilla.fennec, so it cannot be executed by the osso_exec function. You need to copy the four lines in osso_exec definition and replace com.nokia.+name and /com/nokia/name with mozilla.fennec. mediaplayer is another issue, since executing it just runs the background process. You still need to find out how to make it open a window. You don't need to reboot after editing the script, since it is executed at each key press. Note that it is a python script, so white space is important, etc. You can debug your changes by running from the command line /usr/bin/keyboard-shortcuts a b c d 198 where a b c d are any four parameters (ignored by the script) and 198 is 192+ the letter you wish to emulate (198 being f). |
Re: N900 keyboard friendly, second thread.
Hi, I have a little problem. I used Ctrl + Space to change hardware keyboard layout from Russian to English and back. Now after I installed the application this shortcut is replaced by
Quote:
Do you have any ideas how to fix this? |
Re: N900 keyboard friendly, second thread.
Thanks a lot for this, I've been using an older version for a while and now after upgrading to the newest one I'm loving the ctrl-backspace alt-tab functionality, along with network disconnect shortcut.. now I just need to remember to use them. Still using the hack you posted earlier to swap Fn and shift, I'm used to it but anyone else who tries the device seems to get slightly confused :)
Any idea if the default mail client can be launched using osso_exec (or some other way)? Also, finding a way to either a) reconnect to the last used connection or b) connect to a certain (3G) connection would be great. edit:Found a way to launch default email: Code:
if key == 'm': |
Re: N900 keyboard friendly, second thread.
Ok, since there is no answer I guess I'll have to reflash the device :(
Maybe it's just not the right thread for reporting this? |
Re: N900 keyboard friendly, second thread.
Just throwing random thoughts around, but did you try changing the state of /apps/osso/hildon-desktop/key-actions/dbus_ctrl_shortcuts?
first do: gconftool-2 -g /apps/osso/hildon-desktop/key-actions/dbus_ctrl_shortcuts then set it to the other one with: gconftool-2 -s /apps/osso/hildon-desktop/key-actions/dbus_ctrl_shortcuts -t bool true/false |
Re: N900 keyboard friendly, second thread.
Thanks for response
I got this: Quote:
|
Re: N900 keyboard friendly, second thread.
Quote:
As you have been told, setting the key /apps/osso/hildon-desktop/key-actions/dbus_ctrl_shortcuts to false disables capturing of ctrl-space. But should default to false. Are you sure you did not set it to true? Your gconftool-2 error seems to be like there is some hidden character. This might happen if you type a 2 byte char (a Cyrillic letter) and then delete it. Please try to retype the command. Remember also that this key is only read once when hildon-desktop starts, so for this change to take effect you need to restart hildon-desktop, by running killall hildon-desktop, or rebooting. If you want to return to standard hildon-desktop you certainly don't need to reflash the device. You can reinstall the hildon-desktop package. Download it from here: http://repository.maemo.org/pool/fre...+0m5_armel.deb And install it with dpkg -i . |
Re: N900 keyboard friendly, second thread.
I remember being able to close apps by tapping shift and then the relevant key (q, w, e, etc.), now it seems to require me to press both keys at the same time.. is this the intended behaviour? I liked the old way, made it easy to close apps quickly using just one hand.
The ctrl-backspace is set to alt-tab behaviour, if that makes any difference. |
Re: N900 keyboard friendly, second thread.
shift and then q works for me. Are you using the latest version? Does the cogwheel appear when you press shift (or fn)?
|
Re: N900 keyboard friendly, second thread.
Yeah I'm using the latest version, and now that I tried it again seems that it works if I first hold shift done for a while - a second or so, but not if I tap it quickly (like I do when I type capital letters). The cogwheel also appears if I hold shift down for a while and then release it, not if I just tap it quickly.
|
Re: N900 keyboard friendly, second thread.
Hey Matan
Just to let you know, and in case anyone else installs it: I had a modified-hildon-desktop update come through today - the update itself seemed to go fine, but hildon-desktop didn't start again correctly afterwards, and trying to re-start it from the console seemed to hang too. After a reboot everything was fine, it seemed to start as usual. |
Re: N900 keyboard friendly, second thread.
Yes it seems to happen from time to time. Usually disabling and then enabling compositing mode (with ctrl-shift-n) fixes the issue, but rarely it does not.
My guess is that it is a problem with the graphics driver, as the issue also happens when both the stopped and the started hildon-desktop are the original ones. |
Re: N900 keyboard friendly, second thread.
I've bumped into a problem again..
I made ctrl+shift+i launch an SSH connection using X-term with the following line: os.system("/usr/bin/osso-xterm 'ssh user@server'") The shortcut works, with the right key combination launching an SSH connection. However, further ctrl+shift combinations don't work until I close the terminal with SSH in it, and after closing it all the ctrl+shift presses I've used while it's open seem to be executed (so I do ctrl+shift+b 5 times when SSH is open, nothing happens, but when I close the SSH terminal I get 5 empty browser windows). If I copy the text printing part from ctrl+shift+d function, that text is also printed when closing the SSH window, not as it's opened. What makes this interesting, however, is that if I have another terminal window (just an idle terminal, doesn't need to have an SSH connection or anything) open before I use the SSH connection shortcut, everything seems to work as it should, the text is printed when I use the shortcut and ctrl+shift key press functions are executed as expected. The shortcuts also work if I open the SSH connection from my desktop shortcut pointing to "osso-xterm 'ssh user@server'". Is os.system() the wrong way to do this, or is it just something I'll need to get used to? It's only a minor annoyance, since I can do ctrl+shift+x before ctrl+shift+i and it works fine, but would be great if someone knew how to do this right. |
Re: N900 keyboard friendly, second thread.
os.system indeed blocks, so the script does not run again.
Use something like (an example will be in the script in the next version): Code:
if key == 'i': |
Re: N900 keyboard friendly, second thread.
If someone installs PR1.2 (when it becomes available) and wished to try, the packages (only tested on X86 PR1.2 SDK) are:
http://my.arava.co.il/~matan/770/n90..._2.0_armel.deb http://my.arava.co.il/~matan/770/n90...+0m5_armel.deb (the second is only needed for more than 4 desktops). |
Re: N900 keyboard friendly, second thread.
So, I've another question: Is it possible to have a keyboard shortcut to close the current active window the same way it'd be closed when clicking the 'x' in the task switcher? What happens after this I don't really care about, being left in the task switcher would be ok.
Would launching task switcher and then sending the signal to close newest window do the trick? I'll have a go at this later tonight myself if no one can answer and report my progress. |
Re: N900 keyboard friendly, second thread.
"Launching task switcher and then sending the signal to close newest window" does appear to work.
It should be easy to implement a keyboard shortcut for this using keyboard-shortcuts package. Note also that a few programs still have the old behaviour of closing on long press of Escape key. You just need to remap the hardware keyboard to have such a key. |
Re: N900 keyboard friendly, second thread.
Yeah it does seem to work, great. Used time.sleep() to wait a while before sending the signal to close newest window (I'm guessing this is the best way to do it?), other than that it's just a couple of dbus-signals.. easy enough. Here's my script in keyboard-shortcut:
Code:
import time |
Re: N900 keyboard friendly, second thread.
The package http://my.arava.co.il/~matan/770/n90...+0m5_armel.deb adds a dbus signal for opening status menu. To use:
Code:
bus-send --type=signal --session /com/nokia/hildon_desktop com.nokia.hildon_desktop.open_status_menu |
Re: N900 keyboard friendly, second thread.
Matan Hello, I greatly admired your work.
I have tried in various ways, but I can not run shortcuts such as ctrl + shift + f for FBReader, and even hot keys k, or l, h I installed your Hildon that works well, and keyboard-shortcut. This is the result of the command gconftool-2 -R /apps/osso/hildon-desktop/key-actions dbus_shortcuts_use_fn = true launcher_navigator_accel = true home_contacts_phone = false dbus_launcher_navigator = true dbus_shift_ctrl = true preset_shift_ctrl = true disable_edit = false ctrl_backspace = true ctrl_backspace_in_tasknav = 5 dbus_ctrl_shortcuts = true I hope to use your great work, thanks |
All times are GMT. The time now is 21:06. |
vBulletin® Version 3.8.8