diff options
author | anekos | 2010-05-05 12:56:54 +0000 |
---|---|---|
committer | anekos | 2010-05-05 12:56:54 +0000 |
commit | df30098287b97320b83adc64785b42753df2ab07 (patch) | |
tree | c047ca86cad89258dd794eca2cbc60515eb622d8 /yetmappings.js | |
parent | 0d69989345f78087cbad6e87f9c0982769894125 (diff) | |
download | vimperator-plugins-df30098287b97320b83adc64785b42753df2ab07.tar.bz2 |
未使用ヒントモードを表示するコマンド(ymode)を追加
git-svn-id: http://svn.coderepos.org/share/lang/javascript/vimperator-plugins/trunk@37381 d0d07461-0603-4401-acd4-de1884942a52
Diffstat (limited to 'yetmappings.js')
-rw-r--r-- | yetmappings.js | 22 |
1 files changed, 19 insertions, 3 deletions
diff --git a/yetmappings.js b/yetmappings.js index 4d68252..97c23a6 100644 --- a/yetmappings.js +++ b/yetmappings.js @@ -38,17 +38,19 @@ let PLUGIN_INFO = <name>Yet Mappings</name> <description>Display the keys that are not mapped yet.</description> <description lang="ja">まだマップされていないキーを表示する</description> - <version>1.0.1</version> + <version>1.1.0</version> <author mail="anekos@snca.net" homepage="http://d.hatena.ne.jp/nokturnalmortum/">anekos</author> <license>new BSD License (Please read the source code comments of this plugin)</license> <license lang="ja">修正BSDライセンス (ソースコードのコメントを参照してください)</license> <updateURL>http://svn.coderepos.org/share/lang/javascript/vimperator-plugins/trunk/yetmappings.js</updateURL> - <minVersion>2.0</minVersion> - <maxVersion>2.1pre</maxVersion> + <minVersion>2.3</minVersion> + <maxVersion>2.4</maxVersion> <detail><![CDATA[ == Usage == :yetmap[pings] [<KEYS>] :ymap [<KEYS>] + :yethintmodes + :ymode == Links == http://d.hatena.ne.jp/nokturnalmortum/20081109/1226223461 ]]></detail> @@ -59,6 +61,7 @@ let PLUGIN_INFO = const other = '! @ # $ % ^ & * ( ) _ + | ~ { } : " < > ? - = \\ ` [ ] ; \' , . /'.split(/\s/); const special = 'Esc Return Tab Del BS Home Insert End Left Right Up Down PageUp PageDown F1 F2 F3 F4 F5 F6 F7 F8 F9 F10 F11 F12'.split(/\s/).map(function (it) ("<" + it + ">")); const alpha = 'a b c d e f g h i j k l m n o p q r s t u v w x y z'.split(/\s/); + const number = '0 1 2 3 4 5 6 7 8 9'.split(/\s/); const keys = alpha.concat(alpha.map(String.toUpperCase)).concat(other).concat(special); function exists (modes, key) @@ -79,6 +82,19 @@ let PLUGIN_INFO = true ); + commands.addUserCommand( + ['yethintmodes', 'ymode'], + 'display the hint-modes that are not mapped yet.', + function (arg) { + const keys = alpha.concat(alpha.map(String.toUpperCase)).concat(other).concat(number); + liberator.echo(keys.filter(function (m) !hints._hintModes[m]).join(' ')); + }, + { + argCount: '0' + }, + true + ); + liberator.plugins.yet_mappgins = { get: getYetMappings }; |