Languages

Pages

RTM Keyconfig: Change keyboard shortcuts of Remember The Milk

/* How does it work ? */

This Greasemonkey script add / modify / remove keyboard shortcuts of Remember The Milk you want.

Remember The Milk (RTM) is useful task management tool. It has keyboard shortcuts and you can execute all operations via keyboard. However we can’t customize keyboard shortcuts. I always push “Esc” key when I want to clear selection. So I created this Greasemonkey.

/* Install */

This script already uploaded to Userscripts.org. So please install it from this pase. rtmkeyconfig.user.js

/* Settings */

name description value type
keys A string of keyboard shortcut and function. An array contains an array of string of keyboard shortcut and function. Array(Array)
interval Retry interval. millisecond. I recommend default value. In usually, It has the range 100 to 5000. Number
Sample setting
var cfg = {
	keys: [
		["esc", "taskList.taskSelectNone()"],
		["space", "this.keyboardEntrySelect(ev)"],
		["j", function(){
			var list = view.getViewList();
			if(list.keyboardPosition + 1 != list.entries.length){
				list.keyboardDown();
			}
		}],
		["k", function(){
			var list = view.getViewList();
			if(list.keyboardPosition != 0){
				list.keyboardUp();
			}
		}],
		["ctrl+d", "pagedown", function(){
			var list = view.getViewList();
			for(var i = 0; i < 5; i++){
				if(list.keyboardPosition + 1 == list.entries.length){break}
				list.keyboardDown();
			}
		}],
		["ctrl+u", "pageup", function(){
			var list = view.getViewList();
			for(var i = 0; i < 5; i++){
				if(list.keyboardPosition == 0){break}
				list.keyboardUp();
			}
		}],
		["l", "tab", function(){
			var tabs = view.getViewTabs();
			if(tabs.selected != tabs.entries.length - 1){
				tabs.selectRight();
			}
		}],
		["h", "shift+tab", function(){
			var tabs = view.getViewTabs();
			if(tabs.selected != 0){
				tabs.selectLeft();
			}
		}],
		["u", "control.undoLastAction()"]
	],
	interval: 250
}

/* Conclusion */

enjoy Remember The Milk! ;)

5 Comments

Similar Posts:

Trackback URL:

Comments:

  1. Hi Yuki,

    I’ve been enjoying your RTM keyconfig script for a while now.
    Unfortunately, it doesn’t work for me on Firefox 3.
    I’m using the latest Greasemonkey version.

    Thanks,
    Ofer

  2. Hi Ofer,

    Thank you for using this script. ;)
    2 weeks ago, I found this issue and started to fix.
    However, I couldn’t pinpoint the cause yet now.
    Please wait for a little while.

  3. Hi Yuki, thanks a lot for making this script.

    However, when I enable the Ctrl+d key binding, it disables the ‘d’ key binding in RTM for due dates. Can you repro and fix this?

  4. Thank you for pointing out this bug, Jason.
    I fixed this bug and uploaded a new version (0.1.4) to userscripts.org.
    Please check it out.
    I didn’t enough test this version. If you get other issue, let me know again.

  5. Jason says;
    16 Nov 2008 - 9:44

    Thanks for the fix, put it to good use, here’s my setup:
    … ["j", function(){
    var list = view.getViewList();
    if(list.keyboardPosition + 1 != list.entries.length){
    list.keyboardDown();
    }
    if(!view.getMultiEditMode()) {
    taskList.taskSelectNone();
    this.keyboardEntrySelect(ev);
    }
    }],

    k, ctrl+d,u are similar. Since most of my changes are to a single task at any one time, this speeds up the interface automatically selecting a single task at a time.

Add a Comment