Commit Graph

8060 Commits

Author SHA1 Message Date
Florian Bruhin
2fc4f408cd Fix src2asciidoc 2016-05-18 06:55:17 +02:00
Florian Bruhin
1d5fc4a140 Update @cmdutils.argument docs 2016-05-18 06:55:17 +02:00
Florian Bruhin
2370793f38 Make win_id/count mutually exclusive for ArgInfo 2016-05-18 06:55:17 +02:00
Florian Bruhin
35135c4b0d Use @cmdutils.argument for win_id/count 2016-05-18 06:55:17 +02:00
Florian Bruhin
04367851c3 Refactor how cmdutils.ArgInfo works
It's now a real class, and some other aspects about how it's handled
were cleaned up as well.
2016-05-18 06:55:17 +02:00
Florian Bruhin
9eeaeb95c3 Make sure @cmdutils.argument after @register fails 2016-05-18 06:55:17 +02:00
Florian Bruhin
3c586f34ff Add a @cmdutils.argument decorator
For now the only available keyword argument is 'flag' which customizes
the flag an argument will get.

See #637.
2016-05-18 06:55:17 +02:00
Florian Bruhin
965a012db7 Name strip_whitespace.sh correctly 2016-05-18 06:54:14 +02:00
Florian Bruhin
ee579b4bc3 Add a script to strip trailing whitespace
Obsoletes #1498
2016-05-18 06:37:26 +02:00
Liam BEGUIN
f689cca101 Added missing All group 2016-05-17 23:57:36 -04:00
Liam BEGUIN
c3dfd62172 broke line to fit properly 2016-05-17 23:39:24 -04:00
Ryan Roden-Corrent
52641e25f5 Show currently bound keys in command completion.
The command completion menu now uses the misc colum to show a
comma-separated list of normal-mode keybindings for each command.
2016-05-17 20:25:09 -04:00
Ryan Roden-Corrent
acdeb0f57c Bump default for partial-timeout to 5000ms.
Give more time to read the keyhint widget.
2016-05-17 20:13:25 -04:00
Ryan Roden-Corrent
e810317057 Restore bottom padding of keyhint widget.
Previously, negative bottom padding was used (probably to compensate
for a trailing <br>). With the table format, this is no longer
necessary and causes the last line to be drawn too low.
2016-05-17 20:10:52 -04:00
Liam BEGUIN
ce0d23bd10 Added tests for the inputs group 2016-05-17 19:58:48 -04:00
Liam BEGUIN
b66d5e1ce9 Fixed indentations 2016-05-17 19:58:27 -04:00
Ryan Roden-Corrent
822d148713 Update key hint tests for new format.
Change the unit tests to expect the new tabular format.
Also generally clean up the tests -- refactor from a class to
module-level functions as there was no need for a class here.
2016-05-17 07:04:53 -04:00
Panagiotis Ktistakis
959f777f92 Assert that hovered link generates a valid QUrl 2016-05-17 10:28:33 +03:00
Liam BEGUIN
531a5071f6 updated inputs-group 2016-05-17 00:38:23 -04:00
Ryan Roden-Corrent
86f95c302d Explain timeout vs partial-timeout better in docs. 2016-05-16 21:40:30 -04:00
Felix Van der Jeugt
acb60a1bf4 align using a table 2016-05-16 07:14:34 -04:00
Liam BEGUIN
3b0354518b Added basic inputs-group to :hint 2016-05-15 22:46:12 -04:00
Ryan Roden-Corrent
3cd252ef82 Clean up html for keyhint text.
The \t was behaving the same as a space and the <b> was doing nothing.
2016-05-15 22:33:53 -04:00
Ryan Roden-Corrent
8eee5def5d Add unit tests for the keyhint widget.
- validate keyhint text for a partial keychain
- ensure special keybindings are not suggested
- ensure it is not visible when disabled
- ensure changes to the suffix color are picked up
2016-05-15 22:20:52 -04:00
Ryan Roden-Corrent
581a521b4d Allow setting mock keybindings for unit tests.
Implement mock_key_config.set_bindings_for to set bindings that will be
retrieved by mock_key_config.get_bindings_for.
This is useful for testing the new keyhint ui.
2016-05-15 22:18:16 -04:00
Ryan Roden-Corrent
d506d7793f Further clean up keyhints.
Don't show special keys in the keyhint window as these currently cannot
be part of keychains.
Use a rounded border on the top-right corner and square on the rest.
2016-05-15 12:32:36 -04:00
Panagiotis Ktistakis
224c877fec Hide passwords in hovering URLs 2016-05-15 19:07:10 +03:00
Florian Bruhin
0c1e82a103 Fix lint 2016-05-15 11:53:58 +02:00
Florian Bruhin
6fc2217b07 Merge branch 'rcorre-messages' 2016-05-15 11:51:20 +02:00
Florian Bruhin
76a755634b Update changelog 2016-05-15 11:51:09 +02:00
Florian Bruhin
9b28d90543 Improve output if :messages is used without errors 2016-05-15 11:50:29 +02:00
Florian Bruhin
b704c911ae Fix running qute:log and qute:plainlog
This failed because dict.get('level') returned None with no level
parameter, and the subsequent [0] raised:

    Traceback (most recent call last):
      File ".../qutebrowser/utils/utils.py", line 624, in wrapper
        return func(*args, **kwargs)
      File ".../qutebrowser/browser/network/networkmanager.py", line 445, in createRequest
        op, req, outgoing_data)
      File ".../qutebrowser/browser/network/qutescheme.py", line 107, in createRequest
        data = handler(self._win_id, request)
      File ".../qutebrowser/browser/network/qutescheme.py", line 189, in qute_log
        level = urllib.parse.parse_qs(request.url().query()).get('level')[0]
    TypeError: 'NoneType' object is not subscriptable
2016-05-15 11:33:30 +02:00
Florian Bruhin
bb31787931 Regenerate docs 2016-05-15 11:21:02 +02:00
Florian Bruhin
e21039094d Merge branch 'messages' of https://github.com/rcorre/qutebrowser into rcorre-messages 2016-05-15 11:20:06 +02:00
Florian Bruhin
8193644a04 Merge branch 'forkbong-set-cmd-text-variables' 2016-05-15 11:09:37 +02:00
Florian Bruhin
a9ab6abafd Document {url} and {url:pretty} for :set-cmd-text 2016-05-15 11:09:16 +02:00
Florian Bruhin
3831dc38f7 Regenerate authors 2016-05-15 11:09:08 +02:00
Florian Bruhin
0888f676f3 Change go/gO/xO/wO bindings to use {url:pretty}
This is now possible with #1494.
See #1483.
2016-05-15 11:06:54 +02:00
Florian Bruhin
b75d1629a8 Merge branch 'set-cmd-text-variables' of https://github.com/forkbong/qutebrowser into forkbong-set-cmd-text-variables 2016-05-15 11:01:58 +02:00
Florian Bruhin
6b4efc1822 Fix log output in crash report
With the changes to get rid of colorlog, we broke this, as e.g. {green}
was an undefined key for the vanilla logging.Formatter used for the
in-RAM log. Now we instead use a ColoredFormatter with colors turned
off.
2016-05-15 10:46:46 +02:00
Florian Bruhin
33236b5314 Make tox -e mkenv work
This is a common typo, so let's just make things work. It does the exact
same thing as tox -e mkvenv.
2016-05-15 09:59:44 +02:00
Ryan Roden-Corrent
231950aa88 Increase default value for input.partial-timeout.
Increase from 500 to 2500.
This allows the user more time to read hints shown in the new keyhint
popup.
2016-05-14 19:30:39 -04:00
Ryan Roden-Corrent
d592a3e764 Clean up keyhint implementation.
From code review:

- escape all strings used in the keyhint html
- read the prefix color each time the hint is shown
- use show/hide instead of setVisible
- clean up pylint/flake8 errors
- use CssColor instead of QssColor for keyhint.fg.suffix
- add some padding to the keyhint popup
2016-05-14 19:30:28 -04:00
Florian Bruhin
a1bac9509b Merge branch 'ismail-s-patch-1' 2016-05-14 23:52:43 +02:00
Florian Bruhin
e476a21876 Regenerate authors 2016-05-14 23:52:36 +02:00
Florian Bruhin
827ad3fb13 Merge branch 'patch-1' of https://github.com/ismail-s/qutebrowser into ismail-s-patch-1 2016-05-14 23:52:22 +02:00
Panagiotis Ktistakis
c88883fcb3 Decode URL in statusbar when hovering over it 2016-05-14 19:52:24 +03:00
Ryan Roden-Corrent
e7ff717d52 Show key hints for all modes, not just normal. 2016-05-14 12:50:26 -04:00
Ryan Roden-Corrent
8406746889 Show possible keychains from current input.
When the current keystring is a partial match for one or more bindings,
show the possible bindings in a small overlay.

The overlay is partially transparent by default, but the background
color is configurable as ui->keystring.bg.
2016-05-14 12:50:26 -04:00
Ryan Roden-Corrent
fcd233a675 Clean up :messages implementation.
- Add log.LOG_LEVELS to map names to levels (instead of using
  logging._levelToName)
- Test that log pages do not contain messages below the requested level
- Use pythons urllib.parse.parse_qs instead of Qt's UrlQuery
- Document tab, bg, window args for :messages
- Clean up style
2016-05-14 12:45:22 -04:00