{ "info": { "author": "Denis Darii", "author_email": "denis.darii@gmail.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 3 - Alpha", "Intended Audience :: Developers", "License :: OSI Approved :: BSD License", "Operating System :: OS Independent", "Programming Language :: Python", "Topic :: Software Development", "Topic :: Software Development :: Libraries :: Python Modules" ], "description": "=========================\nDjango-keyboard-shortcuts\n=========================\n\n**Helps to use the keyboard inside your web project**\n\nThe project code and bugtracker is hosted on\n`Bitbucket `_ and `Github `_.\n\nDon't uses any javascript framework!\n------------------------------------\n\nOn the client side you will have only pure javascript code that receives all pre-elaborated and optimized data directly from django.\n\nThe only dependency is Django itself\n------------------------------------\nJust **install**, **configure**, and you are ready to **dominate the world** with your website keyboard shortcuts.\n\n============\nInstallation\n============\n\nThere are a few different ways to install keyboard_shortcus:\n\nUsing pip\n---------\nIf you have pip install available on your system, just type::\n\n pip install django-keyboard-shortcuts\n\nIf you've already got an old version of keyboard_shortcus, and want to upgrade, use::\n\n pip install -U django-keyboard-shortcuts\n\nInstalling from a directory\n---------------------------\nIf you've obtained a copy of keyboard_shortcus using either Mercurial or a downloadable\narchive, you'll need to install the copy you have system-wide. Try running::\n\n python setup.py develop\n\nIf that fails, you don't have ``setuptools`` or an equivalent installed;\neither install them, or run::\n\n python setup.py install\n\n\n==============================\nHow to use keyboard_shortcuts?\n==============================\n\nIf you have already installed keyboard_shortcus, you must proceed with the\nconfiguration of your project.\n\nConfiguration\n-------------\nvery simple, in three steps:\n\n#. Add **keyboard_shortcuts** To INSTALLED_APPS\n\n#. Modify Your settings.py, declare your **HOTKEYS** settings.\n\n#. Add **{% load hotkeys %}{% setup_hotkeys %}** in your template.\n\nBelow the long explanation of each step...\n\nAdd keyboard_shortcuts To INSTALLED_APPS\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\nAs with most Django applications, you should add **keyboard_shortcuts** to the INSTALLED_APPS within your settings file (usually *settings.py*).\n\nExample::\n\n INSTALLED_APPS = [\n 'django.contrib.admin',\n 'django.contrib.auth',\n 'django.contrib.contenttypes',\n 'django.contrib.sessions',\n 'django.contrib.sites',\n\n # Added.\n 'keyboard_shortcuts',\n ]\n\nModify Your settings.py\n^^^^^^^^^^^^^^^^^^^^^^^\n\nWithin your *settings.py*, you\u2019ll need to add some settings in order to assign to desired keyboard shortcuts some actions and to personalize the **django-keyboard-shortcuts** behaviour for your project.\n\nYou can define:\n\n- **HOTKEYS** - a list containing the desired keyboard combinations and some settings for each (*default:* **list()**)\n- **SPECIAL_DISABLED** - a bool, to disable shortcuts in some \"**special cases**\", when an input, a textarea or a select is active (*default:* **True**)\n\nExample::\n\n # START keyboard_shortcuts settings #\n HOTKEYS = [\n {'keys': 'g + h', # go home\n 'link': '/'},\n ]\n SPECIAL_DISABLED = True\n # END keyboard_shortcuts settings #\n\nMore about HOTKEYS setting?\n\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\n\nHOTKEYS is a list of dictioanaries. Each dictionary contains the attributes for a particular keyboard combination. HOTKEYS dist must have a key called \"**keys**\" and one of \"**link**\" or \"**js**\".\n\nExamples of \"**keys**\" value:\n\n- \"CTRL + R\"\n\n- \"Z + R + P\"\n\n- \"3 (NUMPAD)\"\n\n- \"CTRL + \\*\"\n\n- \"=\"\n\nExamples of \"**link**\" value:\n\n- \"/about/\"\n\n- \"http://google.com\"\n\nExamples of \"**js**\" value:\n\n- \"alert('HELLO!');\"\n\nif for a keyboard combination we have both \"**link**\" and \"**js**\" declared, only \"**link**\" will be condidered.\n\nAnother advanced examples for **HOTKEYS** list::\n\n HOTKEYS = [\n {'keys': 'ctrl+h', # home\n 'link': '/',\n },\n {'keys': 'alt+w',\n 'link': '/workspace/',\n },\n {'keys': 'shift+j',\n 'js': 'js_function();', # javascript code here\n },\n {'keys': 'a+j',\n 'js': 'alert(\\'A+J Pressed!\\');', # javascript code here\n },\n {'keys': '1+2+3',\n 'link': '/secret-url/',\n },\n ]\n\nAvailable keys for your combinations:\n\n- BACKSPACE\n- TAB\n- ENTER\n- SHIFT\n- CTRL\n- ALT\n- PAUSE\n- CAPSLOCK\n- ESC\n- PAGE UP\n- PAGE DOWN\n- END\n- HOME\n- LEFT ARROW\n- UP ARROW\n- RIGHT ARROW\n- DOWN ARROW\n- INSERT\n- DELETE\n- 0\n- 1\n- 2\n- 3\n- 4\n- 5\n- 6\n- 7\n- 8\n- 9\n- A\n- B\n- C\n- D\n- E\n- F\n- G\n- H\n- I\n- J\n- K\n- L\n- M\n- N\n- O\n- P\n- Q\n- R\n- S\n- T\n- U\n- V\n- W\n- X\n- Y\n- Z\n- 0 (NUMPAD)\n- 1 (NUMPAD)\n- 2 (NUMPAD)\n- 3 (NUMPAD)\n- 4 (NUMPAD)\n- 5 (NUMPAD)\n- 6 (NUMPAD)\n- 7 (NUMPAD)\n- 8 (NUMPAD)\n- 9 (NUMPAD)\n- \\*\n- \\+\n- \\-\n- .\n- /\n- F1\n- F2\n- F3\n- F4\n- F5\n- F6\n- F7\n- F8\n- F9\n- F10\n- F11\n- F12\n- NUMLOCK\n- SCROLL\n- =\n- COMMA\n- SLASH /\n- BACKSLASH \\\\\n- META\n\nSetup Hotkeys In Your Template\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\nNow all you need to do is to add **{% load hotkeys %}** and **{% setup_hotkeys %}** in yout template, and *django-keyboard-shortcuts* will do the rest for you... add event listeners and attend for any keypress.\n\nThe easiest way to do this is to load hotkeys **{% load hotkeys %}** at the **top** of your \"base\" template and to setup **{% setup_hotkeys %}** the in your **** section.\n\nExample of \"base.html\" template::\n\n {% load hotkeys %}\n \n \n My title\n {% setup_hotkeys %}\n \n \n my content...\n \n \n\n==============================\nHow to test keyboard_shortcus?\n==============================\n\nVery simple::\n\n $ ./manage.py test keyboard_shortcus\n\n\n==========================\nDo you need some examples?\n==========================\n\nFurther a list of the most useful keyboard shortcuts of our favorite web services.\nSo, if you need a suggestion about which key combination use on your site,\nthis is where you find it:\n\nGmail\n-----\n\n **c** \u2013 compose a new mail\n\n **/** \u2013 puts your cursor in the search box\n\n **k** \u2013 move to newer conversation\n\n **j** \u2013 Move to older conversation\n\n **n** \u2013 next message\n\n **p** \u2013 previous message\n\n **o or Enter** \u2013 open a conversation\n\n **u** \u2013 return to conversation list\n\n **y** \u2013 archive a conversation\n\n **m** \u2013 mute (archive and make all future messages from this conversation\n skip the inbox)\n **x** \u2013 select conversation\n\n **s** \u2013 star a message or conversation\n\n **!** \u2013 report spam\n\n **r** \u2013 reply to a mail\n\n **a** \u2013 reply to all recepients\n\n **f** \u2013 forward message\n\n **Esc** \u2013 escape from input field\n\n **ctrl+s** \u2013 save draft\n\n\nkey combos\n^^^^^^^^^^\n\n **tab then Enter** \u2013 send message\n\n **y then o** \u2013 archive your conversation and move to the next one.\n\n **g then a** \u2013 go to all mail\n\n **g then s** \u2013 go to starred conversations\n\n **g then c** \u2013 go to contacts list.\n\n **g then d** \u2013 go to drafts\n\n **g then i** \u2013 go to inbox\n\nGoogle Reader\n-------------\n\n **j/k** \u2013 selects the next/previous item in the list\n\n **space/shift-space** \u2013 moves the page down/up\n\n **n/p** \u2013 in list view, selects the next item without opening it\n\n **o** \u2013 in list view, expands or collapses the selected item\n\n **enter** \u2013 in list view, expands or collapses the selected item\n\n **s** \u2013 stars the selected item\n\n **shift-s** \u2013 shares the selected item\n\n **m** \u2013 switches the read state of the selected item\n\n **t** \u2013 opens the tagging field for the selected item\n\n **v** \u2013 opens the original source for this article in a new window\n\n **shift-a** \u2013 marks all items in the current view as read\n\n **1** \u2013 displays the subscription as expanded items\n\n **2** \u2013 displays the subscription as a list of headlines\n\n **r** \u2013 refreshes the unread counts in the navigation\n\n **shift-n/p** \u2013 selects the next/previous subscription or folder in the\n navigation\n\n **shift-x** \u2013 expand or collapse a folder selected in the navigation\n\n **shift-o** \u2013 opens the item currently selected in the navigation\n\n **gh** \u2013 goes to the Google Reader homepage\n\n **ga** \u2013 goes to the \u201cAll items\u201d view\n\n **gs** \u2013 goes to the \u201cStarred items\u201d view\n\n **gt** \u2013 allows you to navigate to a tag by entering the tag name\n\n **gu** \u2013 allows you to navigate to a subscription by entering the\n subscription name\n\n **u** \u2013 hides and shows the list of subscriptions\n\n **?** \u2013 displays a quick guide to all of Reader\u2019s shortcuts\n\nWikipedia\n---------\n\n **+** \u2013 add a new section (talk pages only)\n\n **.** \u2013 opens your user page if logged in\n\n **=** \u2013 protect/unprotect the current page (sysops only)\n\n **c** \u2013 shows the content page associated with the current article\n\n **d** \u2013 delete/undelete the current page (sysops only)\n\n **e** \u2013 edit this page/show source of current page\n\n **f** \u2013 search Wikipedia\n\n **h** \u2013 current page\u2019s history\n\n **j** \u2013 shows all of the pages that link to the current one\n\n **k** \u2013 shows recent changes in pages linked to the current one\n\n **l** \u2013 opens your watchlist (logged \u2013 in users only)\n\n **m** \u2013 move the current page and its talk page (non \u2013 move \u2013 protected pages only)\n\n **n** \u2013 opens your user\u2019s or IP\u2019s talk page\n\n **p** \u2013 shows a preview of your changes (on edit pages)\n\n **q** \u2013 shows a list of all special pages\n\n **r** \u2013 shows a list of recent changes to the Wikipedia\n\n **s** \u2013 saves the changes that you have made (on edit pages)\n\n **t** \u2013 opens the current article\u2019s talk page\n\n **u** \u2013 allows you to upload images or media files\n\n **v** \u2013 shows what changes you made to the text (on edit pages)\n\n **w** \u2013 adds the current page to your watchlist (logged \u2013 in users only)\n\n **x** \u2013 loads a random article\n\n **y** \u2013 opens a list of your user\u2019s or IP\u2019s contributions\n\n **z** \u2013 goes to the Main Page\n\n\nYahoo! Mail\n-----------\n\n **m** \u2013 check mail\n\n **Shift+m** \u2013 check all mail\n\n **Ctrl+** \u2013 close current tab\n\n **n** \u2013 new message\n\n **Shift+n** \u2013 new message in its own window\n\n **r** \u2013 reply\n\n **Shift+r** \u2013 reply in a new window\n\n **a** \u2013 reply all\n\n **Shift+a** \u2013 reply all in a new window\n\n **f** \u2013 forward message\n\n **Shift+f** \u2013 forward in a new window\n\n **k** \u2013 mark as read\n\n **Shift+k** \u2013 mark as unread\n\n **l** \u2013 flag\n\n **Shift+l** \u2013 clear flag\n\n **del** \u2013 delete item\n\n **p/Ctrl+p** \u2013 print\n\n **Ctrl+s** \u2013 save draft\n\n **Ctrl+Enter** \u2013 send message\n\n **v** \u2013 turn reading pane on/off\n\n **Ctrl+[** \u2013 navigate through tabs\n\n **Ctrl+]** \u2013 navigate through tabs\n\n **Enter** \u2013 open message in its own tab (when message is selected)\n\n **Enter** \u2013 edit contact info (when contact is selected)\n\n **Ctrl+f** \u2013 find a word or phrase in message\n\n **F11** \u2013 expand window to max height\n\n **Ctrl+.** \u2013 next message (in message tab)\n\n **Ctrl+,** \u2013 previous message (in message tab)\n\n **Ctrl+Alt+Shift+up arrow/down arrow** \u2013 next/previous message\n\n **Ctrl+Shift+End** \u2013 skip to oldest unread message\n\n **d** \u2013 move message to folder\n\n **Esc** \u2013 close read** \u2013 message tab\n\n **Ctrl+Shift+End** \u2013 start a new chat\n\n\n=======\nCredits\n=======\n\nSpecial thanks to the authors of this resources:\n\nhttp://www.w3.org/2002/09/tests/keys.html\n\nhttp://www.quirksmode.org/js/keys.html#t00\n\nhttp://unixpapa.com/js/key.html\n\nhttp://www.openjs.com/scripts/events/keyboard_shortcuts/\n\nhttps://github.com/jeresig/jquery.hotkeys/\n\nhttp://mashable.com/2007/06/29/keyboard-shortcuts/\n\n\n=========\nChangelog\n=========\n\n0.0.7\n-----\n\n* added support for \"js\" action for your shortcuts\n* covered with tests the new functionality\n* improved documentation\n\n0.0.6\n-----\n\n* you can now configure in your settings.py the behaviour in \"special cases\"\n* updated the documentation\n* improved tests\n\n0.0.5\n-----\n\n* disabled hotkeys in selet and text type inputs\n\n0.0.4\n-----\n\n* now you can add multiple key combinations\n* improved tests\n* updated the documentation\n\n0.0.3\n-----\n\n* included \"keyboard_shortcuts/templates \\*\" in MANIFEST.in\n* documentation updated\n* templatetags and utils are now tested\n\n0.0.2\n-----\n\n* added hotkeys templatetag\n* added an example project for testing purposes\n\n0.0.1\n-----\n\n* initial structure", "description_content_type": null, "docs_url": null, "download_url": "UNKNOWN", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://bitbucket.org/DNX/django-keyboard-shorcuts/", "keywords": null, "license": "BSD License", "maintainer": null, "maintainer_email": null, "name": "django-keyboard-shortcuts", "package_url": "https://pypi.org/project/django-keyboard-shortcuts/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/django-keyboard-shortcuts/", "project_urls": { "Download": "UNKNOWN", "Homepage": "https://bitbucket.org/DNX/django-keyboard-shorcuts/" }, "release_url": "https://pypi.org/project/django-keyboard-shortcuts/0.0.7/", "requires_dist": null, "requires_python": null, "summary": "Helps to use the keyboard inside your web project.", "version": "0.0.7" }, "last_serial": 789936, "releases": { "0.0.1": [ { "comment_text": "", "digests": { "md5": "5c06aaf550e3a5ae6c5519bce29d9692", "sha256": "19b0d49c7808476830edaa664bd517ad7604834ce08fc2b96ec1e999acfd3d4c" }, "downloads": -1, "filename": "django-keyboard-shortcuts-0.0.1.tar.gz", "has_sig": false, "md5_digest": "5c06aaf550e3a5ae6c5519bce29d9692", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 5426, "upload_time": "2012-03-17T13:57:11", "url": "https://files.pythonhosted.org/packages/ea/76/9138405a3e40d9c3b11d83b27019c4853836ece0d52b789d28c0f205209a/django-keyboard-shortcuts-0.0.1.tar.gz" } ], "0.0.2": [ { "comment_text": "", "digests": { "md5": "e9f49d9526e4f2e487ac73ef9139c098", "sha256": "27ca9ea661c1c1672c010c3efb42c66a7bd0c2859e56f75605834e8eb5d2176d" }, "downloads": -1, "filename": "django-keyboard-shortcuts-0.0.2.tar.gz", "has_sig": false, "md5_digest": "e9f49d9526e4f2e487ac73ef9139c098", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 5425, "upload_time": "2012-03-17T14:00:48", "url": "https://files.pythonhosted.org/packages/e0/af/8d111d657b8e51b80e4bd0ad75d0f1a841aa135609c87a167c9c55ccd02b/django-keyboard-shortcuts-0.0.2.tar.gz" } ], "0.0.3": [ { "comment_text": "", "digests": { "md5": "a5dc3af37201d9273be916eb0a55527d", "sha256": "f84950ca5f2448519916381a3c90e0a8e5c550f16c9a08e8bc878cb668a2f656" }, "downloads": -1, "filename": "django-keyboard-shortcuts-0.0.3.tar.gz", "has_sig": false, "md5_digest": "a5dc3af37201d9273be916eb0a55527d", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 5813, "upload_time": "2012-03-17T20:46:08", "url": "https://files.pythonhosted.org/packages/ab/d0/db401f22f564cf22827f75ca78f863e300ab74a3ebc6ee3c0a3742217d09/django-keyboard-shortcuts-0.0.3.tar.gz" } ], "0.0.4": [ { "comment_text": "", "digests": { "md5": "fc051c49ab605dc528886c4965390218", "sha256": "518e9da5c7b3a4d7da6842bd1e035fcfd3be3c053e8c9bc9b6d3345fd20b2bd8" }, "downloads": -1, "filename": "django-keyboard-shortcuts-0.0.4.tar.gz", "has_sig": false, "md5_digest": "fc051c49ab605dc528886c4965390218", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7322, "upload_time": "2012-03-18T23:30:45", "url": "https://files.pythonhosted.org/packages/a6/9b/1840ce8b685bf9c6786f152ead78bfc3f031dc26e30701a63708b4166ad6/django-keyboard-shortcuts-0.0.4.tar.gz" } ], "0.0.5": [ { "comment_text": "", "digests": { "md5": "1f9d43bde70b40633ecce3ae2be65d7c", "sha256": "e308069840a8a2eb54467cf6fab927b54fdfc8602ac7afea0f3d93639b1421c6" }, "downloads": -1, "filename": "django-keyboard-shortcuts-0.0.5.tar.gz", "has_sig": false, "md5_digest": "1f9d43bde70b40633ecce3ae2be65d7c", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7500, "upload_time": "2012-03-19T15:20:05", "url": "https://files.pythonhosted.org/packages/fa/f1/472ee831b152a28248ed2614ba1118e02c2388dc3167cec68bf4e668797c/django-keyboard-shortcuts-0.0.5.tar.gz" } ], "0.0.6": [ { "comment_text": "", "digests": { "md5": "27cab4daa30ae4be1b9331a208e68904", "sha256": "2cf8f557cb1f170a96d30e9f08e2a2444ce90b014dabe11ce2e46a283c7b24a5" }, "downloads": -1, "filename": "django-keyboard-shortcuts-0.0.6.tar.gz", "has_sig": false, "md5_digest": "27cab4daa30ae4be1b9331a208e68904", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 9145, "upload_time": "2012-03-19T17:54:08", "url": "https://files.pythonhosted.org/packages/09/85/8938ecb6c50b5e36f400606bcd0312c66c2b3f4251570e6b8c0a14c4d7b9/django-keyboard-shortcuts-0.0.6.tar.gz" } ], "0.0.7": [ { "comment_text": "", "digests": { "md5": "a2f3d473bc57fc907d69c9d3193e8af4", "sha256": "acc4de404e06efb6a55970fb18243a842f1db85a65772c80bc3b040b511a8c4a" }, "downloads": -1, "filename": "django-keyboard-shortcuts-0.0.7.tar.gz", "has_sig": false, "md5_digest": "a2f3d473bc57fc907d69c9d3193e8af4", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 12515, "upload_time": "2012-03-20T13:26:40", "url": "https://files.pythonhosted.org/packages/b9/00/743c60d56a50cab02ca8c2a2177b63e5b4548f3ce4293604422ad6651f67/django-keyboard-shortcuts-0.0.7.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "a2f3d473bc57fc907d69c9d3193e8af4", "sha256": "acc4de404e06efb6a55970fb18243a842f1db85a65772c80bc3b040b511a8c4a" }, "downloads": -1, "filename": "django-keyboard-shortcuts-0.0.7.tar.gz", "has_sig": false, "md5_digest": "a2f3d473bc57fc907d69c9d3193e8af4", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 12515, "upload_time": "2012-03-20T13:26:40", "url": "https://files.pythonhosted.org/packages/b9/00/743c60d56a50cab02ca8c2a2177b63e5b4548f3ce4293604422ad6651f67/django-keyboard-shortcuts-0.0.7.tar.gz" } ] }