Commit graph

105 commits

Author SHA1 Message Date
Colin Caine
1c8e88693c excmd: document new buffer functions 2017-11-27 19:59:43 +00:00
Colin Caine
9b68e94d94 excmd: arg to buffer is not optional 2017-11-27 19:59:43 +00:00
Robbie McMichael
53ee803bc9 Reduce code duplication in buffer function 2017-11-27 19:59:43 +00:00
Robbie McMichael
87aa3ee225 Add tabfirst and tablast commands 2017-11-27 19:59:43 +00:00
Oliver Blanthorn
f9ee2a3e9a
Add documentation for yankshort,canon 2017-11-27 19:15:04 +00:00
glacambre
dd1365f269 excmds.ts: Add yankshort and yankcanon. 2017-11-27 19:48:49 +01:00
glacambre
cb58814da3 excmds.ts: Add search urls.
This commit adds a Github, Searx, Cnrtl, OpenStreetMap, the Mozilla Dev Network
and the Gentoo wiki to the list of SEARCH_URLS.
2017-11-26 16:36:07 +01:00
Oliver Blanthorn
2ce1f9a64a
Fix #99: misleading help for bind 2017-11-26 14:56:09 +00:00
Oliver Blanthorn
1775e100ef
Make focus listener only store editable inputs 2017-11-26 12:27:54 +00:00
Oliver Blanthorn
38ff3f7ca4
Merge branch 'master' of github.com:cmcaine/tridactyl into johnbeard-focusinput 2017-11-26 12:18:14 +00:00
Oliver Blanthorn
8f49130c63
Add listener to store last focused element 2017-11-26 12:18:06 +00:00
Oliver Blanthorn
d65acf9f64
Fix #117: add :version command
:version currently fills the command line with the version number in
order to display it to the user (hacky) and copies it to the clipboard.
2017-11-26 00:06:02 +00:00
Oliver Blanthorn
c66ca2ab62
Merge branch 'master' of github.com:cmcaine/tridactyl into ollef-URIEncode 2017-11-25 16:14:05 +00:00
John Beard
221b94c8ff Add hint focus mode (;;)
This focuses the hinted element with excmd ":hint -;".

Includes VImperator binding to ";;"
2017-11-25 01:47:56 +00:00
John Beard
6a48990751 Add focusinput command (gi)
Can focus the nth input from the start or end of a page.

Also has some special modes:

  -l: last focussed input
  -p: first password input
  -b: the largest input by area
2017-11-25 01:41:38 +00:00
Olle Fredriksson
4870a967ff URI-encode search query string
This enables searching for e.g. 'C#'.

Also remove a now no longer valid comment.
2017-11-24 23:30:24 +01:00
chocolateboy
0953425cf5 improve pagination:
- prefer the canonical forms over fallback patterns
  (fixes rockpapershotgun.com, Discourse etc.):

  1) link[rel]
  2) a[rel]
  3) a::text(pattern)

- tighten fallback patterns (fixes Google, GitHub etc.)

- remove site-specific patterns
2017-11-23 15:07:48 +00:00
John Beard
a46934b2dd Add image hinting (;i, ;I)
This supports hinting of <img> tags, and will open the src attribute in
the current or BG tab.
2017-11-22 23:03:28 +00:00
Colin Caine
8a44732227 completions:
Done:
	Working completion for buffers
	Substitute values into command line
	Prepare for non-buffers completions
	Wrote too many classes and helper functions

Todo:
	Learn inferno and hopefully simplify
	If not, simplify the main functions so that people can actually
	build for it.
	Define an interface for tabbing through options
	Allow more than one CompletionSource per command
2017-11-22 21:43:29 +00:00
Colin Caine
8d771e578c completions 1 2017-11-22 21:30:37 +00:00
Koushien
f982233a49 completions: initial implementation
This commit squashes a load of work by @Koushien, a dozen hours from
@cmcaine and some CSS by @bovine3dom.

@cmcaine is writing this commit message, but the work was mostly by
Koushien so the author is set to them. Thanks Koushien!

The following issues need to be fixed:

 - The interface is over complicated (my fault)
 - commandline_frame is hard-coded to use BufferCompletionSource. This
   needs to be made more general
 - BufferCompletionSource should be generalised
 - completions.ts calls helper functions in commandline_frame. Should
   just use browser proxy. If that's too slow can define a
   completions_background.ts

After that's done, this should be fixed:

 - Completion hiding/unhiding is currently too messy.
2017-11-22 21:30:37 +00:00
Oliver Blanthorn
ea697464b3
Add text yank mode 2017-11-22 20:47:35 +00:00
Oliver Blanthorn
63a52e63c4
Add yank hint mode, allow messageActiveTab to be called from content 2017-11-22 19:09:52 +00:00
Oliver Blanthorn
c236ecdf7a
Add command to reload all pages at once 2017-11-22 16:59:58 +00:00
Oliver Blanthorn
8802a7f265
Revert "Add tabclosethenprev to switch to last accessed tab"
This is not needed as `composite tabclose | buffer #` has the same
affect.

This reverts commit d448d10e27.
2017-11-22 13:20:54 +00:00
Oliver Blanthorn
b1a4c5db38
Add documentation for bmark 2017-11-22 12:24:37 +00:00
Oliver Blanthorn
1af85b293f
Add keybind documentation to help page, link to help from newtab 2017-11-22 12:24:37 +00:00
Oliver Blanthorn
00c02b454e
Add rudimentary bookmark support
Only covers the addition / removal of bookmarks.
2017-11-22 12:24:37 +00:00
Oliver Blanthorn
8f9fd34639
Merge pull request #104 from aplaice/master
Add reader excmd (toggle reader mode)
2017-11-22 10:29:50 +00:00
Oliver Blanthorn
d448d10e27
Add tabclosethenprev to switch to last accessed tab 2017-11-21 22:00:11 +00:00
Adam Plaice
895cfc6291 Add reader excmd (toggle reader mode)
It is already bound to "gr".

Unless and until the keyboard api is ready or Firefox allows
webextensions to inject scripts into the very security-sensitive
about:reader context, this will only switch on reader mode. One
can get out of reader mode, by pressing <Alt-←>.

Once one of the above conditions is met, the toggling should work
without any further changes.
2017-11-21 21:13:11 +00:00
Oliver Blanthorn
85d6eba2b5
Revert "Merge branch 'Koushien-completions'"
This reverts commit 0aa14bb754, reversing
changes made to eae9cd0dab.
2017-11-21 20:28:48 +00:00
Oliver Blanthorn
7d825146c5
Merge branch 'master' of github.com:cmcaine/tridactyl 2017-11-21 19:16:27 +00:00
Oliver Blanthorn
0aa14bb754
Merge branch 'Koushien-completions'
Currently doesn't support "tab" and has lots of dead code. Only
implemented for tabs right now.
2017-11-21 19:13:48 +00:00
John Beard
27116a3416 Add urlparent (gu) command
This command changes the URL to the parent URL.

Normal mode binding 'gu' added: same as Vimperator.
2017-11-21 12:12:25 +00:00
John Beard
44455692e8 Add urlroot (gU) command
Opens the root domain of the current tab's URL. E.g.
"https://example.com/page" -> "http://example.com/"

Includes 'gU' binding (same as Vimperator)
2017-11-21 12:12:15 +00:00
Oliver Blanthorn
eae9cd0dab
Change incrementurl to urlincrement and add bind 2017-11-21 11:05:40 +00:00
John Beard
8f8982cde1
Add incrementurl command
Increments the last number in a URL by a given step (positive or
negative)

Also includes a url_util helper module and some tests for it

Logic taken from vimperator browser.js:17
2017-11-21 11:05:40 +00:00
Koushien
cf620959ec Do not merge: quick WIP
In case I get hit by a bus or something.
Reminder to myself to rebase next commit on
previous patch for some coherency.
2017-11-21 05:15:52 +00:00
Koushien
5bbb133c5c Begin transitioning completions refactor
Start laying groundwork for buffersall excmd
2017-11-21 05:15:52 +00:00
Koushien
a389d6dde3 Move buffers to general completion system.
User shouldn't notice any difference besides:
* removing "buffer " from cli clears buffers
* retyping "buffer " repopulates buffers
* text after "buffer " filters with smartcase.

We no longer directly set completion's innerHTML.
2017-11-21 05:15:52 +00:00
Colin Caine
a0fc55fd9f fix race condition breaking quickmarks 2017-11-21 03:30:16 +00:00
Colin Caine
053d613527 excmd: document gobble, quickmarks 2017-11-20 23:32:24 +00:00
Colin Caine
9683e11f70 Tidy up gobble mode. Re-use key classification. 2017-11-20 23:23:25 +00:00
D.B
0a0c31230e add gobble mode and quickmarks 2017-11-20 23:23:25 +00:00
Colin Caine
d286e36c55
Merge branch 'master' into patch-1 2017-11-20 05:22:45 +00:00
Colin Caine
ba99fdaf80 excmd: x-www-form-urlencode query strings
Fixes #83.
2017-11-20 01:11:38 +00:00
Colin Caine
b2a35c090d excmd: fix wikipedia search url 2017-11-20 01:08:26 +00:00
Philipp
5b3699309c
Add startpage search engine
I added startpage, a very popular search engine,  to the list of search engines.
2017-11-19 21:00:58 +01:00
Colin Caine
de1cc83584 fix: Turn buffer completions back on again
I forgot we still used this old system!
2017-11-19 08:28:07 +00:00