mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2025-12-22 15:27:58 +01:00
escape literal & with the HTML entity in :set help string
This commit is contained in:
@@ -1060,7 +1060,7 @@ function Commands() //{{{
|
||||
"<code class=\"command\">:set option?</code> or <code class=\"command\">:set option</code>(for string and list options) shows the current value of an option.<br/>" +
|
||||
"<code class=\"command\">:set option&</code> resets an option to its default value.<br/>" +
|
||||
"<code class=\"command\">:set option+={value}</code> and <code class=\"command\">:set option-={value}</code> will add/subtract {value} to a number option and append/remove {value} to a string option.<br/>" +
|
||||
"<code class=\"command\">:set all</code> will show the current value of all options and <code class=\"command\">:set all&</code> will reset all options to their default values.<br/>",
|
||||
"<code class=\"command\">:set all</code> will show the current value of all options and <code class=\"command\">:set all&</code> will reset all options to their default values.<br/>",
|
||||
completer: function(filter) { return vimperator.completion.get_options_completions(filter); }
|
||||
}
|
||||
));
|
||||
|
||||
@@ -61,6 +61,7 @@ vimperator.help = function(section, easter) //{{{
|
||||
//usage = usage.replace(/[^b][^r][^\/]>/g, ">");
|
||||
usage = usage.replace(/</g, "<");
|
||||
usage = usage.replace(/>/g, ">");
|
||||
usage = usage.replace(/&/g, "&");
|
||||
usage = usage.replace(/\\n/g, "<br/>");
|
||||
// color [count], [!], {arg} and [arg] in the usage, not nice and error prone but the regexp work (for now)
|
||||
usage = usage.replace(/({[^}]+})/g, "<span class=\"argument\">$1</span>"); // required args
|
||||
|
||||
Reference in New Issue
Block a user