diff options
author | bptato <nincsnevem662@gmail.com> | 2024-02-28 21:48:44 +0100 |
---|---|---|
committer | bptato <nincsnevem662@gmail.com> | 2024-02-28 21:51:10 +0100 |
commit | 074e2089d909e4f7ef85df89698875ec2b8935c3 (patch) | |
tree | ea6d20ba741234a849542419359b3e52133197a0 /doc | |
parent | 7eeef1700eee50a2e80910ba0b07138ea1d39d55 (diff) | |
download | chawan-074e2089d909e4f7ef85df89698875ec2b8935c3.tar.gz |
pager: improve URL loading procs
Split up load into loadSubmit, gotoURL: loadSubmit is a replacement for load(s + '\n'), and gotoURL is a load that does no URL expansion. Also, fix a bug where load("\n") would crash the browser.
Diffstat (limited to 'doc')
-rw-r--r-- | doc/config.md | 22 |
1 files changed, 19 insertions, 3 deletions
diff --git a/doc/config.md b/doc/config.md index e0208e16..64ed6a44 100644 --- a/doc/config.md +++ b/doc/config.md @@ -879,13 +879,29 @@ from the document's last line.</td> <tr> <td>`pager.load(url)`</td> -<td>Go to the specified URL. Opens a prompt with the current URL when no -parameters are specified; otherwise, the string passed is displayed in -the prompt. If this string ends with a newline +<td>Put the specified address into the URL bar, and optionally load it.<br> +Note that this performs auto-expansion of URLs, so Chawan will expand any +matching omni-rules (e.g. search), try to open schemeless URLs with the default +scheme/local files, etc.<br> +Opens a prompt with the current URL when no parameters are specified; otherwise, +the string passed is displayed in the prompt. If this string ends with a newline (e.g. `pager.load("about:chawan\n")`), the URL is loaded directly.</td> </tr> <tr> +<td>`pager.loadSubmit(url)`</td> +<td>Act as if `url` had been input into the address bar.<br> +Same as `pager.load(url + "\n")`.</td> +</tr> + +<tr> +<td>`pager.gotoURL(url)`</td> +<td>Go to the specified URL immediately (without a prompt). This differs from +`load` and `loadSubmit` in that it *does not* try to correct the URL.<br> +Use this for loading automatically retrieved (i.e. non-user-provided) URLs.</td> +</tr> + +<tr> <td>`pager.dupeBuffer()`</td> <td>Duplicate the current buffer by loading its source to a new buffer.</td> </tr> |