mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2025-12-21 22:17:59 +01:00
add initial implementation of :normal command
This commit is contained in:
1
NEWS
1
NEWS
@@ -1,6 +1,7 @@
|
||||
<pre>
|
||||
2007-08-*:
|
||||
* version 0.5
|
||||
* new :normal command
|
||||
* the command line keeps focus now, even when clicking outside of it
|
||||
* vimperator.events.feedkeys("2zi") support for scripts
|
||||
* Ctrl-U/Ctrl-D for scrolling the window up/down and the associated
|
||||
|
||||
@@ -588,7 +588,7 @@ function Commands() //{{{
|
||||
// 2 args -> map arg1 to arg*
|
||||
function(args)
|
||||
{
|
||||
if (args.length == 0)
|
||||
if (!args)
|
||||
{
|
||||
vimperator.mappings.list(vimperator.modes.NORMAL);
|
||||
return;
|
||||
@@ -694,6 +694,23 @@ function Commands() //{{{
|
||||
help: "If <code class=\"argument\">[arg]</code> is specified then limit the list to the those marks mentioned."
|
||||
}
|
||||
));
|
||||
addDefaultCommand(new Command(["norm[al]"],
|
||||
function(args)
|
||||
{
|
||||
if (!args)
|
||||
{
|
||||
vimperator.echoerr("E471: Argument required");
|
||||
return;
|
||||
}
|
||||
|
||||
vimperator.events.feedkeys(args);
|
||||
},
|
||||
{
|
||||
usage: ["norm[al][!] {commands}"],
|
||||
short_help: "Execute Normal mode commands",
|
||||
help: "TODO"
|
||||
}
|
||||
));
|
||||
// TODO: remove duplication in :map
|
||||
addDefaultCommand(new Command(["no[remap]"],
|
||||
// 0 args -> list all maps
|
||||
@@ -701,7 +718,7 @@ function Commands() //{{{
|
||||
// 2 args -> map arg1 to arg*
|
||||
function(args)
|
||||
{
|
||||
if (args.length == 0)
|
||||
if (!args)
|
||||
{
|
||||
vimperator.mappings.list(vimperator.modes.NORMAL);
|
||||
return;
|
||||
@@ -1133,7 +1150,7 @@ function Commands() //{{{
|
||||
addDefaultCommand(new Command(["unm[ap]"],
|
||||
function(args)
|
||||
{
|
||||
if (args.length == 0)
|
||||
if (!args)
|
||||
{
|
||||
vimperator.echoerr("E474: Invalid argument");
|
||||
return;
|
||||
@@ -1194,7 +1211,7 @@ function Commands() //{{{
|
||||
{
|
||||
var level;
|
||||
|
||||
if (args.length == 0)
|
||||
if (!args)
|
||||
{
|
||||
level = 100;
|
||||
}
|
||||
|
||||
@@ -69,7 +69,7 @@ function CommandLine() //{{{
|
||||
multiline_output_widget.collapsed = false;
|
||||
setTimeout(function() { multiline_output_widget.collapsed = true; }, 0);
|
||||
|
||||
// The widget used for multiline iutput
|
||||
// The widget used for multiline intput
|
||||
var multiline_input_widget = document.getElementById("vimperator-multiline-input");
|
||||
|
||||
// we need to save the mode which were in before opening the command line
|
||||
@@ -97,7 +97,7 @@ function CommandLine() //{{{
|
||||
function setMessageStyle()
|
||||
{
|
||||
prompt_widget.setAttribute("style", "font-family: monospace; color:magenta; font-weight: bold");
|
||||
command_widget.inputField.setAttribute("style","font-family: monospace;");
|
||||
command_widget.inputField.setAttribute("style", "font-family: monospace;");
|
||||
}
|
||||
function setErrorStyle()
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user