mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2025-12-22 05:07:59 +01:00
Add caret mode to help index.
This commit is contained in:
@@ -80,6 +80,7 @@ var Modes = Module("modes", {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
this.addMode("CARET", {
|
this.addMode("CARET", {
|
||||||
|
char: "caret",
|
||||||
description: "Active when the caret is visible in the web content",
|
description: "Active when the caret is visible in the web content",
|
||||||
bases: [this.NORMAL]
|
bases: [this.NORMAL]
|
||||||
}, {
|
}, {
|
||||||
|
|||||||
@@ -26,6 +26,8 @@ This file contains a list of all available commands, mappings and options.
|
|||||||
|
|
||||||
<h2 tag="n-map-index">Normal mode</h2>
|
<h2 tag="n-map-index">Normal mode</h2>
|
||||||
|
|
||||||
|
<h2 tag="caret-map-index">Caret mode</h2>
|
||||||
|
|
||||||
<h2 tag="v-map-index">Visual mode</h2>
|
<h2 tag="v-map-index">Visual mode</h2>
|
||||||
|
|
||||||
<h2 tag="c-map-index">Command-line editing</h2>
|
<h2 tag="c-map-index">Command-line editing</h2>
|
||||||
|
|||||||
@@ -261,7 +261,7 @@
|
|||||||
<description>
|
<description>
|
||||||
<p>
|
<p>
|
||||||
Start Caret mode. This mode resembles Vim's Normal mode where the
|
Start Caret mode. This mode resembles Vim's Normal mode where the
|
||||||
text cursor is visible on the web page. The <k link="false">v</k>
|
text cursor is visible on the web page. The <k mode="caret">v</k>
|
||||||
key enters Visual mode, where text is selected as the cursor moves.
|
key enters Visual mode, where text is selected as the cursor moves.
|
||||||
</p>
|
</p>
|
||||||
<p>
|
<p>
|
||||||
|
|||||||
@@ -1569,6 +1569,7 @@ var Buffer = Module("Buffer", {
|
|||||||
let file = io.File(filename.replace(/^>>\s*/, ""));
|
let file = io.File(filename.replace(/^>>\s*/, ""));
|
||||||
dactyl.assert(args.bang || file.exists() && file.isWritable(),
|
dactyl.assert(args.bang || file.exists() && file.isWritable(),
|
||||||
_("io.notWriteable", file.path.quote()));
|
_("io.notWriteable", file.path.quote()));
|
||||||
|
|
||||||
return buffer.viewSourceExternally(buffer.focusedFrame.document,
|
return buffer.viewSourceExternally(buffer.focusedFrame.document,
|
||||||
function (tmpFile) {
|
function (tmpFile) {
|
||||||
try {
|
try {
|
||||||
@@ -1580,7 +1581,7 @@ var Buffer = Module("Buffer", {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
let file = io.File(filename.replace(RegExp(File.PATH_SEP + "*$"), ""));
|
let file = io.File(filename);
|
||||||
|
|
||||||
if (filename.substr(-1) === File.PATH_SEP || file.exists() && file.isDirectory())
|
if (filename.substr(-1) === File.PATH_SEP || file.exists() && file.isDirectory())
|
||||||
file.append(Buffer.getDefaultNames(doc)[0][0]);
|
file.append(Buffer.getDefaultNames(doc)[0][0]);
|
||||||
|
|||||||
Reference in New Issue
Block a user