1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2025-12-24 00:52:27 +01:00

add new 'helpfile' option

This commit is contained in:
Doug Kearns
2008-09-06 05:04:34 +00:00
parent cc292e8541
commit 5a19d43bdc
4 changed files with 30 additions and 10 deletions

1
NEWS
View File

@@ -1,6 +1,7 @@
<pre>
2008-XX-XX:
* version 2.0 (probably)
* add 'helpfile' option
* add 'wildignore' option
* add :finish command
* new events BookmarkPost, ShellCmdPost, QuitPre

View File

@@ -76,6 +76,10 @@ const liberator = (function () //{{{
}
});
liberator.options.add(["helpfile", "hf"],
"Name of the main help file",
"string", "intro.html");
liberator.options.add(["loadplugins", "lpl"],
"Load plugin scripts when starting up",
"boolean", true);
@@ -757,6 +761,18 @@ const liberator = (function () //{{{
liberator.options["newtab"].split(",").indexOf("help") != -1)) ?
liberator.NEW_TAB : liberator.CURRENT_TAB;
if (!topic)
{
var helpFile = liberator.options["helpfile"];
if (liberator.config.helpFiles.indexOf(helpFile) != -1)
liberator.open("chrome://" + liberator.config.name.toLowerCase() + "/locale/" + helpFile, where);
else
liberator.echo("Sorry, help file \"" + helpFile + "\" not found");
return;
}
function jumpToTag(file, tag)
{
liberator.open("chrome://" + liberator.config.name.toLowerCase() + "/locale/" + file, where);
@@ -770,14 +786,9 @@ const liberator = (function () //{{{
}, 500);
}
if (!topic)
{
liberator.open("chrome://" + liberator.config.name.toLowerCase() + "/locale/intro.html", where);
return;
}
var [, items] = getHelpCompletions(topic);
var partialMatch = -1;
for (var i = 0; i < items.length; i++)
{
if (items[i][0] == topic)

View File

@@ -319,6 +319,14 @@ You can also hide the tab bar with [c]:set showtabline=0[c].
____
|\'hf'| |\'helpfile'|
||'helpfile' 'hf'|| string (default: "intro.html")
____
Name of the main help file. This is the tail component of the chrome URL as
displayed in the status line when viewing the page.
____
|\'hm'| |\'hintmatching'|
||'hintmatching' 'hm'|| string (default: contains)
____

View File

@@ -1,7 +1,7 @@
" Vim syntax file
" Language: VIMperator configuration file
" Maintainer: Doug Kearns <dougkearns@gmail.com>
" Last Change: 2008 Sep 04
" Last Change: 2008 Sep 06
if exists("b:current_syntax")
finish
@@ -41,9 +41,9 @@ syn match vimperatorCommandWrapper "\%(^\s*:\=\)\@<=\%(!\|\h\w*\>\)" contains=vi
syn region vimperatorSet matchgroup=vimperatorCommand start="\%(^\s*:\=\)\@<=\<set\=\>" end="$" keepend oneline contains=vimperatorOption
syn keyword vimperatorOption activate act activelinkfgcolor alfc activelinkbgcolor albc cdpath cd complete cpt defsearch ds editor
\ extendedhinttags eht eventignore ei focuscontent fc nofocuscontent nofc fullscreen fs nofullscreen nofs guioptions go
\ hintmatching hm hintstyle hs hinttags ht hinttimeout hto history hi hlsearch hls nohlsearch nohls hlsearchstyle hlss
\ incsearch is noincsearch nois ignorecase ic noignorecase noic insertmode im noinsertmode noim laststatus ls linkbgcolor lbc
\ linkfgcolor lfc linksearch lks nolinksearch nolks loadplugins noloadplugins lpl nolpl more newtab nextpattern nomore
\ helpfile hf hintmatching hm hintstyle hs hinttags ht hinttimeout hto history hi hlsearch hls nohlsearch nohls hlsearchstyle
\ hlss incsearch is noincsearch nois ignorecase ic noignorecase noic insertmode im noinsertmode noim laststatus ls linkbgcolor
\ lbc linkfgcolor lfc linksearch lks nolinksearch nolks loadplugins noloadplugins lpl nolpl more newtab nextpattern nomore
\ pageinfo pa popups pps preload nopreload previewheight pvh previouspattern online noonline scroll scr shell sh shellcmdflag
\ shcf showmode smd noshowmode nosmd showstatuslinks ssli showtabline stal smartcase scs nosmartcase noscs suggestengines
\ titlestring usermode um nousermode noum urlseparator verbose vbs visualbell vb novisualbell novb visualbellstyle wildignore