mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2025-12-20 07:07:59 +01:00
Update TODO, add :colo default (== :hi clear)
This commit is contained in:
@@ -155,10 +155,11 @@ const modes = (function () //{{{
|
||||
// show the current mode string in the command line
|
||||
show: function ()
|
||||
{
|
||||
if (!options["showmode"])
|
||||
return;
|
||||
let msg = "";
|
||||
if (options["showmode"])
|
||||
msg = getModeMessage();
|
||||
|
||||
commandline.echo(getModeMessage(), "ModeMsg", commandline.FORCE_SINGLELINE);
|
||||
commandline.echo(msg, "ModeMsg", commandline.FORCE_SINGLELINE);
|
||||
},
|
||||
|
||||
// add/remove always work on the extended mode only
|
||||
|
||||
@@ -127,6 +127,7 @@ function Highlights(name, store, serial)
|
||||
Highlight.prototype.toString = function () "Highlight(" + this.class + ")\n\t" + [k + ": " + util.escapeString(v || "undefined") for ([k, v] in this)].join("\n\t");
|
||||
|
||||
function keys() [k for ([k, v] in Iterator(highlight))].sort();
|
||||
|
||||
this.__iterator__ = function () (highlight[v] for ([k, v] in Iterator(keys())));
|
||||
|
||||
this.get = function (k) highlight[k];
|
||||
@@ -173,6 +174,12 @@ function Highlights(name, store, serial)
|
||||
return "[liberator|highlight~=" + hl + "]" + rest
|
||||
};
|
||||
|
||||
this.clear = function ()
|
||||
{
|
||||
for (let [k, v] in Iterator(highlight))
|
||||
this.set(k, null, true);
|
||||
};
|
||||
|
||||
this.reload = function ()
|
||||
{
|
||||
this.CSS.replace(/\{((?:.|\n)*?)\}/g, function (_, _1) _1.replace(/\n\s*/g, " "))
|
||||
@@ -453,10 +460,11 @@ liberator.registerObserver("load_commands", function ()
|
||||
{
|
||||
let scheme = args[0];
|
||||
|
||||
if (io.sourceFromRuntimePath(["colors/" + scheme + ".vimp"]))
|
||||
autocommands.trigger("ColorScheme", { name: scheme });
|
||||
else
|
||||
liberator.echoerr("E185: Cannot find color scheme " + scheme);
|
||||
if (scheme == "default")
|
||||
highlight.clear();
|
||||
else if (!io.sourceFromRuntimePath(["colors/" + scheme + ".vimp"]))
|
||||
return liberator.echoerr("E185: Cannot find color scheme " + scheme);
|
||||
autocommands.trigger("ColorScheme", { name: scheme });
|
||||
},
|
||||
{
|
||||
argCount: "1",
|
||||
@@ -581,11 +589,7 @@ liberator.registerObserver("load_commands", function ()
|
||||
return;
|
||||
}
|
||||
if (!key && clear)
|
||||
{
|
||||
for (let h in highlight)
|
||||
highlight.set(h.class, null, true);
|
||||
return;
|
||||
}
|
||||
return highlight.clear();
|
||||
let error = highlight.set(key, css, clear, "-append" in args);
|
||||
if (error)
|
||||
liberator.echoerr(error);
|
||||
|
||||
@@ -941,6 +941,7 @@ function CommandLine() //{{{
|
||||
if (!keepCommand || this.silent)
|
||||
{
|
||||
outputContainer.collapsed = true;
|
||||
commandline.updateMorePrompt();
|
||||
this.hide();
|
||||
}
|
||||
if (!outputContainer.collapsed)
|
||||
@@ -1390,6 +1391,9 @@ function CommandLine() //{{{
|
||||
|
||||
updateMorePrompt: function updateMorePrompt(force, showHelp)
|
||||
{
|
||||
if (outputContainer.collapsed)
|
||||
return echoLine("", this.HL_NORMAL);
|
||||
|
||||
let win = multilineOutputWidget.contentWindow;
|
||||
function isScrollable() !win.scrollMaxY == 0;
|
||||
function atEnd() win.scrollY / win.scrollMaxY >= 1;
|
||||
|
||||
@@ -22,16 +22,11 @@ BUGS:
|
||||
|
||||
(recent CVS regressions):
|
||||
- visual caret mode is broken
|
||||
- Form elements in iframes must be selected twice, whether by tabbing or
|
||||
clicking.
|
||||
- :regressions is broken
|
||||
- :set noshowmode | :echo "foobar\n"<ESC> doesn't clear the more prompt
|
||||
|
||||
FEATURES:
|
||||
9 fix local options
|
||||
9 adaptive timeout for auto-completions, :set completions can be updated more often than
|
||||
:open foo
|
||||
9 :colorscheme default
|
||||
9 use the storage module for autocommands
|
||||
8 :redir and 'verbosefile'
|
||||
8 middleclick in content == p, and if command line is open, paste there the clipboard buffer
|
||||
|
||||
Reference in New Issue
Block a user