diff --git a/common/content/help.js b/common/content/help.js new file mode 100644 index 00000000..b25ecf51 --- /dev/null +++ b/common/content/help.js @@ -0,0 +1,8 @@ + +const liberator = Components.classes["@mozilla.org/embedcomp/window-watcher;1"] + .getService(Components.interfaces.nsIWindowWatcher) + .activeWindow + .liberator; + +liberator.help(decodeURIComponent(document.location.search.substr(1))); + diff --git a/common/content/help.xul b/common/content/help.xul new file mode 100644 index 00000000..16be6018 --- /dev/null +++ b/common/content/help.xul @@ -0,0 +1,7 @@ + + + + {doctitle} @@ -73,10 +74,10 @@ HEADER=
| key=
|
-option=| -option2='|' -command=| -mapping=| +option=| +option2='|' +command=| +mapping=| argument=| argument2={|} argument3=[|] diff --git a/vimperator/locale/en-US/browsing.txt b/vimperator/locale/en-US/browsing.txt index 97f43335..10ba2231 100644 --- a/vimperator/locale/en-US/browsing.txt +++ b/vimperator/locale/en-US/browsing.txt @@ -68,7 +68,7 @@ ________________________________________________________________________________ ||:tabopen[!] [arg1], [arg2], ...|| + ||t|| ________________________________________________________________________________ -Just like help::open[browsing.html#opening], but opens the resulting web page(s) +Just like [c]:open[c], but opens the resulting web page(s) in a new tab. When used with [!], the 'tabopen' value of the 'activate' option is negated. ________________________________________________________________________________ diff --git a/vimperator/locale/en-US/help.js b/vimperator/locale/en-US/help.js new file mode 100644 index 00000000..17a20a4e --- /dev/null +++ b/vimperator/locale/en-US/help.js @@ -0,0 +1,7 @@ + +document.addEventListener("click", function (event) { + let elem = event.target; + if (/^(option|mapping|command)$/.test(elem.className)) + elem.setAttribute("href", "chrome://liberator/content/help.xul?" + encodeURIComponent(elem.textContent.replace(/\s.*/, ""))); +}, true); + diff --git a/vimperator/locale/en-US/xhtml11.css b/vimperator/locale/en-US/xhtml11.css index 1ff321a5..194c0557 100644 --- a/vimperator/locale/en-US/xhtml11.css +++ b/vimperator/locale/en-US/xhtml11.css @@ -335,6 +335,14 @@ fieldset.paypal { font-weight: bold; color: #106326; } + +.option, .mapping, .command { + text-decoration: none; +} +.option:hover, .mapping:hover, .command:hover { + text-decoration: underline; +} + .quoteblock { margin-left: 140px; padding-bottom: 10px;