Commit Graph

891 Commits

Author SHA1 Message Date
Florian Bruhin
10d7d887ec Pass keypresses to statusbar correctly 2014-04-24 15:47:38 +02:00
Florian Bruhin
b3418cae5d Improve _is_editable() 2014-04-24 13:13:58 +02:00
Florian Bruhin
ff887c647d Don't append mode to mode stack if it's already 2014-04-24 07:44:54 +02:00
Florian Bruhin
b9d845180e Better logging for ModeManager 2014-04-24 07:44:47 +02:00
Florian Bruhin
a82ab6d707 Go to insert mode when plugin clicked 2014-04-24 07:41:20 +02:00
Florian Bruhin
5b84848ad9 s/leaved/left/g 2014-04-24 07:01:27 +02:00
Florian Bruhin
95691e1e11 Show passthrough modes in statusbar 2014-04-24 06:59:39 +02:00
Florian Bruhin
afa9c47867 Lint cleanups 2014-04-24 06:45:38 +02:00
Florian Bruhin
3d292fbc27 Use a stack for current modes 2014-04-24 06:44:58 +02:00
Florian Bruhin
f3db29c010 Enter normal mode when clicking non-editable elem 2014-04-23 23:26:02 +02:00
Florian Bruhin
b4b9b6c69d Enter/leave command mode for Command widget 2014-04-23 23:25:06 +02:00
Florian Bruhin
cd5f2562aa Adjust eventFilter to use new features 2014-04-23 23:24:46 +02:00
Florian Bruhin
e56d33badc Check if handler is available for new mode 2014-04-23 23:23:30 +02:00
Florian Bruhin
5385307582 Register modes explicitely with modemanager. 2014-04-23 23:23:04 +02:00
Florian Bruhin
fc11021c08 Add a passthrough argument to modemanager register() 2014-04-23 23:22:34 +02:00
Florian Bruhin
522a703863 Remove module-level modemanager register() 2014-04-23 23:21:29 +02:00
Florian Bruhin
8f44b56923 Start implementing eventFilter in ModeManager 2014-04-23 23:20:39 +02:00
Florian Bruhin
a33c9827d6 Check for editable fields in mousePressEvent 2014-04-23 21:18:05 +02:00
Florian Bruhin
ce48ed9b8e Add entered/leaved signals to modemanager 2014-04-23 21:15:47 +02:00
Florian Bruhin
8b5daad367 Add ModeManager 2014-04-23 21:15:47 +02:00
Florian Bruhin
387d0e3be6 Document hint lastChild() hack 2014-04-23 14:34:00 +02:00
Florian Bruhin
a67ed4d054 Override mousePressEvent instead of event 2014-04-23 07:34:23 +02:00
Florian Bruhin
2c5bb6a413 cmdutils.register: Support functions with no docstring 2014-04-23 07:32:00 +02:00
Florian Bruhin
7acd32a5d7 Display error when there's nothing to undo 2014-04-23 06:17:36 +02:00
Florian Bruhin
61802725a6 Actually use message.error for errors 2014-04-23 06:17:29 +02:00
Florian Bruhin
46f1a2a0d0 Add log_events decorator 2014-04-22 23:50:56 +02:00
Florian Bruhin
21bb9840d9 Simplify padding in Qt-CSS 2014-04-22 23:02:51 +02:00
Florian Bruhin
06ff2e00e9 Always draw categories correctly in completion 2014-04-22 21:38:06 +02:00
Florian Bruhin
fb9ac1bc4c Restyle tabbar 2014-04-22 20:49:16 +02:00
Florian Bruhin
55e3aca702 linting cleanup 2014-04-22 17:53:27 +02:00
Florian Bruhin
2bef265a89 Remove fixed FIXME 2014-04-22 17:24:21 +02:00
Florian Bruhin
dea80b3b54 Fix complete() of BaseType 2014-04-22 17:23:35 +02:00
Florian Bruhin
0f29526f91 Refactor keyparser 2014-04-22 17:21:29 +02:00
Florian Bruhin
aedf1889dd Support ambiguous keybindings 2014-04-22 16:50:37 +02:00
Florian Bruhin
f38871c9c9 Remove FIXME 2014-04-22 16:12:53 +02:00
Florian Bruhin
97578df7a5 Use QHostInfo instead of socket to resolve 2014-04-22 16:09:41 +02:00
Florian Bruhin
8dfc44da59 Remove another FIXME 2014-04-22 15:58:44 +02:00
Florian Bruhin
76f4917ae9 Implement wrapping/message when switching tabs 2014-04-22 15:57:38 +02:00
Florian Bruhin
3ab3e9394d Bind backspace to back 2014-04-22 15:48:38 +02:00
Florian Bruhin
87dda6dca6 Return no data on invalid qute:* handlers 2014-04-22 15:46:46 +02:00
Florian Bruhin
786404add4 HTML-escape qutescheme texts 2014-04-22 15:28:48 +02:00
Florian Bruhin
abb5c06ee6 Remove import FIXMEs 2014-04-22 15:22:50 +02:00
Florian Bruhin
94cef5ea22 Remove FIXME for keybindingname validation 2014-04-22 15:19:28 +02:00
Florian Bruhin
a87163b213 Complete commands 2014-04-22 15:19:18 +02:00
Florian Bruhin
1638823fb3 Add a complete() method to config types 2014-04-22 15:19:01 +02:00
Florian Bruhin
7758289f8b Register :nextsearch command. 2014-04-22 15:05:12 +02:00
Florian Bruhin
963066b4bd Remove some old FIXMEs 2014-04-22 14:45:24 +02:00
Florian Bruhin
a1650579e9 Reword FIXME comments 2014-04-22 14:35:56 +02:00
Florian Bruhin
70e1a0300c Add explicit types for editable hinting 2014-04-22 14:33:40 +02:00
Florian Bruhin
b167f1f8d8 Clarify QTBUG comment 2014-04-22 14:26:07 +02:00
Florian Bruhin
0de249e904 Support frames correctly in HintManager 2014-04-22 14:23:55 +02:00
Florian Bruhin
ebd3ab778f Make scrolling work with multiple frames 2014-04-22 14:17:17 +02:00
Florian Bruhin
26124920cd Display warnings if at beginning/end of history 2014-04-22 14:06:32 +02:00
Florian Bruhin
10acc854c4 Don't reopen opened URLs after crash 2014-04-22 14:02:29 +02:00
Florian Bruhin
b794739d94 Remove unneeded assignment 2014-04-22 13:56:25 +02:00
Florian Bruhin
5d95c7e19c Remove unused import 2014-04-22 12:10:27 +02:00
Florian Bruhin
9b5cf6ee7d Update appdirs.py 2014-04-22 12:07:57 +02:00
Florian Bruhin
ce274aa9c8 Fix printing 2014-04-22 11:16:45 +02:00
Florian Bruhin
af1ba0edf6 Re-sort some functions 2014-04-22 10:45:07 +02:00
Florian Bruhin
1a68bdb9a9 Clean up signal connections 2014-04-22 10:40:33 +02:00
Florian Bruhin
78060fc879 Get rid of temp_message signal 2014-04-22 10:08:56 +02:00
Florian Bruhin
e1b7305e40 Get rid of unneeded text slots in statusbar 2014-04-22 10:00:43 +02:00
Florian Bruhin
1e27f5537d Filter javascript-links from hinting 2014-04-22 09:53:21 +02:00
Florian Bruhin
fec353809b Nicer statusbar texts when hinting 2014-04-22 09:41:43 +02:00
Florian Bruhin
233289228b Reposition hints if contents size changed 2014-04-22 09:35:59 +02:00
Florian Bruhin
8d891bf168 Hints style fixes 2014-04-22 09:35:49 +02:00
Florian Bruhin
ee5e066d86 Display message when hinting. 2014-04-22 09:06:38 +02:00
Florian Bruhin
d700d962af Add the ability to display persistent messages. 2014-04-22 09:06:17 +02:00
Florian Bruhin
1740d4c60f Ignore empty js statusbar messages. 2014-04-22 09:05:53 +02:00
Florian Bruhin
7e2b590da1 Spelling fix 2014-04-22 08:46:21 +02:00
Florian Bruhin
21abfa10a4 Improve config section comments 2014-04-22 08:42:58 +02:00
Florian Bruhin
27f88ffa47 Don't break https:// urls 2014-04-22 08:42:47 +02:00
Florian Bruhin
7645f4fdea Revert "Use "Monospace" only as monospace font"
This reverts commit 1442b1e35f.

For true CSS fonts (hints), we can use "Monospace" as generic family and
it'll work.

However, for Qt fonts, this will get us a non-monospace font on Windows.

Conflicts:
	qutebrowser/config/configdata.py
2014-04-22 08:26:53 +02:00
Florian Bruhin
03c1e1d896 cleanups 2014-04-21 23:53:13 +02:00
Florian Bruhin
65f2409d03 hints: Handle relative/javascript links correctly 2014-04-21 23:44:45 +02:00
Florian Bruhin
ba7f56f5e9 Add different hinting modes (yank, backtab, rapid) 2014-04-21 23:33:36 +02:00
Florian Bruhin
05e3fb8650 Add :backtabopen command 2014-04-21 23:33:19 +02:00
Florian Bruhin
6ce415fc5e Make hint-labels non-clickable. 2014-04-21 23:32:58 +02:00
Florian Bruhin
6bbb5fe598 Add emitted signals to hintmanager docstrings. 2014-04-21 23:32:44 +02:00
Florian Bruhin
73dfa30a49 Display error message when config validation failed 2014-04-21 22:29:57 +02:00
Florian Bruhin
f70fad650d Spelling fix 2014-04-21 21:11:01 +02:00
Florian Bruhin
1c5686f5e3 Handle crashes before config is loaded correctly 2014-04-21 21:09:15 +02:00
Florian Bruhin
695ab70d7c Style fixes 2014-04-21 21:05:39 +02:00
Florian Bruhin
b10c934e15 Validate length/bounds for config values 2014-04-21 21:04:19 +02:00
Florian Bruhin
a6789095b3 Fix paste when clipboard is empty 2014-04-21 20:29:58 +02:00
Florian Bruhin
4f58d067b4 Clear errors when key is pressed 2014-04-21 20:21:42 +02:00
Florian Bruhin
9caac26873 Handle no found elements to hint gracefully 2014-04-21 19:31:28 +02:00
Florian Bruhin
a11b14fd2d Implement more hinting modes 2014-04-21 19:29:11 +02:00
Florian Bruhin
0741326e5d Make it possible to open tabs in background 2014-04-21 19:03:04 +02:00
Florian Bruhin
67bf654d57 Handle scrolled frame correctly 2014-04-21 18:20:30 +02:00
Florian Bruhin
979685e37a Click topleft of elements 2014-04-21 17:41:51 +02:00
Florian Bruhin
20dd33fb7a Set focus on webview before processing click 2014-04-21 17:23:22 +02:00
Florian Bruhin
ee8ba55676 Support esc to abort hinting 2014-04-21 17:17:34 +02:00
Florian Bruhin
de0e96ab2d Add clicking on links 2014-04-21 16:59:03 +02:00
Florian Bruhin
c2aa9517ea Mark partial hint matches 2014-04-21 15:45:29 +02:00
Florian Bruhin
d7b87e09c9 Implement modes and hint input. 2014-04-21 15:24:19 +02:00
Florian Bruhin
5a3966ca82 Fix lint, add documentation 2014-04-21 11:03:43 +02:00
Florian Bruhin
98ed6c9812 Implement hint strings 2014-04-21 11:03:43 +02:00
Florian Bruhin
809e7e15b8 Document HINT_CSS 2014-04-21 11:03:43 +02:00
Florian Bruhin
6434dac680 Check element visibility before drawing 2014-04-21 11:03:43 +02:00
Florian Bruhin
a2deba68dc Check if hints are inside screen 2014-04-21 11:03:42 +02:00
Florian Bruhin
3b894580a2 Also check x on invalid rects 2014-04-21 11:03:42 +02:00
Florian Bruhin
293b38a92f Return on invalid rects 2014-04-21 11:03:42 +02:00
Florian Bruhin
5dd74d39fd Make hinting configurable 2014-04-21 11:03:42 +02:00
Florian Bruhin
3bd1470b20 Keep a reference to the labels 2014-04-21 11:03:42 +02:00
Florian Bruhin
41b0655ade Add stop() to HintManager 2014-04-21 11:03:42 +02:00
Florian Bruhin
c4731b6e7e Nicer hints CSS 2014-04-21 11:03:42 +02:00
Florian Bruhin
0b5f4d9fb5 Add some labels to hints 2014-04-21 11:03:42 +02:00
Florian Bruhin
e6569f946c Add proof-of-concept hinting 2014-04-21 11:03:41 +02:00
Florian Bruhin
1f66766e0a Add CssColor conftype 2014-04-21 11:03:09 +02:00
Florian Bruhin
0bbd128fca Add Float conftype 2014-04-21 11:03:09 +02:00
Florian Bruhin
9152e40bfb Implement validate() for String 2014-04-21 11:03:09 +02:00
Florian Bruhin
2da1f05326 Output better error when validate() isn't implemented 2014-04-21 11:03:09 +02:00
Florian Bruhin
1442b1e35f Use "Monospace" only as monospace font 2014-04-21 11:03:09 +02:00
Florian Bruhin
341481cd99 Allow bindings to be modified 2014-04-21 11:00:58 +02:00
Florian Bruhin
52c7376402 Split command-related stuff off from KeyParser 2014-04-21 10:45:57 +02:00
Florian Bruhin
406e115a07 Stop logging network requests 2014-04-18 11:03:02 +02:00
Florian Bruhin
c8795a21a6 Revert "Make it possible to not typecheck values in setv."
This reverts commit 152bcae618.
2014-04-18 11:01:02 +02:00
Florian Bruhin
a91dde8a26 Catch exceptions in get_wrapper 2014-04-17 19:11:31 +02:00
Florian Bruhin
152bcae618 Make it possible to not typecheck values in setv. 2014-04-17 19:08:57 +02:00
Florian Bruhin
abaec2f044 Remove __setitem__ for sections 2014-04-17 19:08:31 +02:00
Florian Bruhin
3089463a9a Remove FIXME 2014-04-17 19:04:04 +02:00
Florian Bruhin
5bd40e732c Do validation and reading from configparser correctly 2014-04-17 19:02:58 +02:00
Florian Bruhin
a5f8bdf7fc Add validation FIXME 2014-04-17 18:00:15 +02:00
Florian Bruhin
1282a211cf Add validation for search engine URLs and colors 2014-04-17 17:59:57 +02:00
Florian Bruhin
39f580d9f1 Cleanup 2014-04-17 17:44:27 +02:00
Florian Bruhin
975d83b50e Respect inspector height for completion 2014-04-17 15:58:09 +02:00
Florian Bruhin
dea30e3f4d Ensure developer extras are enabled for webinspector 2014-04-17 15:46:29 +02:00
Florian Bruhin
457e173592 More config cleanup.
This renames the config instance from "config" to "instance" and adds a
convenience get() function in the config module.
2014-04-17 15:26:27 +02:00
Florian Bruhin
a15461b5da Rename config.config dict to sections 2014-04-17 14:49:38 +02:00
Florian Bruhin
3728381643 Make dump_userconfig work correctly 2014-04-17 12:35:46 +02:00
Florian Bruhin
c6df785c41 Use common base class for config section 2014-04-17 12:21:22 +02:00
Florian Bruhin
3eca7d6847 Don't split value for set commands 2014-04-17 12:06:48 +02:00
Florian Bruhin
b323706f5f Use maxsplit (passed to str.split()) instead bool 2014-04-17 12:06:27 +02:00
Florian Bruhin
4421862b3e Don't use shlex for splitting anymore 2014-04-17 11:49:19 +02:00
Florian Bruhin
3ad4b447b4 Remove FIXME 2014-04-17 11:45:06 +02:00
Florian Bruhin
97bde402fb Add docstring 2014-04-17 11:40:19 +02:00
Florian Bruhin
72340575af Remove value from on_config_changed signal again.
Turns out this causes more trouble than it's worth, and it's unintuitive
from which layer we get the value.
2014-04-17 11:39:25 +02:00
Florian Bruhin
7c64e8846a Refresh keybinds when config changes 2014-04-17 11:23:01 +02:00
Florian Bruhin
16afba032f Remove warn logging 2014-04-17 11:10:08 +02:00
Florian Bruhin
00dc4d6bc4 Remove set_trace 2014-04-17 11:09:12 +02:00
Florian Bruhin
c0236b8d22 Use a proper separated model for cmd history 2014-04-17 11:08:14 +02:00
Florian Bruhin
90ddd26981 Handle the case where no history is present correctly 2014-04-17 11:07:57 +02:00
Florian Bruhin
a1a0325283 Use ChainMap for ValueList config section.
This also fixes the problem where no keybindings are loaded on the first
start.
2014-04-17 11:01:45 +02:00
Florian Bruhin
6b72c3dbdf Fix long line 2014-04-17 09:51:05 +02:00
Florian Bruhin
4b1dcbd82a Refactor tab/browser widgets 2014-04-17 09:44:26 +02:00
Florian Bruhin
58ae1f7441 Add comment about CurCommandDispatcher 2014-04-17 08:24:59 +02:00
Florian Bruhin
af94b9f212 Don't attempt to save if no data was read 2014-04-16 23:32:21 +02:00
Florian Bruhin
981ca7d18e Fix layer handling in dump_userconfig 2014-04-16 23:21:57 +02:00
Florian Bruhin
48ced03d57 Display config description in completion 2014-04-16 16:36:45 +02:00
Florian Bruhin
57baafbf30 Change configdata from function to attribute 2014-04-16 16:32:14 +02:00
Florian Bruhin
bc4a01faf3 Fix config importing 2014-04-16 16:32:06 +02:00
Florian Bruhin
517c9e6b69 Split config.py more 2014-04-16 16:16:17 +02:00
Florian Bruhin
fc24cb620c Move websettings to own file 2014-04-16 15:49:56 +02:00
Florian Bruhin
03227c2b41 Lint fixes 2014-04-16 14:14:37 +02:00
Florian Bruhin
2adcde1c89 Implement web inspector 2014-04-16 14:12:04 +02:00
Florian Bruhin
4c751d8081 Add webkit settings to config 2014-04-16 13:32:55 +02:00
Florian Bruhin
91e6f4c37d Better linting with config files 2014-04-16 11:05:58 +02:00
Florian Bruhin
e878fc538d Fix some checks 2014-04-16 10:02:34 +02:00
Florian Bruhin
4ca8cc9537 Add value to config.changed signal 2014-04-16 09:50:24 +02:00
Florian Bruhin
a410d56a78 Implement command history 2014-04-16 09:08:56 +02:00
Florian Bruhin
1d5b0ca9a6 Add save command 2014-04-15 17:28:14 +02:00
Florian Bruhin
73c319a1ec Add autosave option 2014-04-15 17:28:05 +02:00
Florian Bruhin
dad6451b7e style fixes 2014-04-15 17:21:12 +02:00
Florian Bruhin
88b522fa16 Only clear selection model if it exists 2014-04-15 17:16:28 +02:00
Florian Bruhin
f959c0c137 Add completion for settings values 2014-04-14 17:54:11 +02:00
Florian Bruhin
44ce804bdf Highlight all rows in completion 2014-04-13 23:06:41 +02:00
Florian Bruhin
24cdd88415 Fix weird 'no such command' message 2014-04-13 22:56:43 +02:00
Florian Bruhin
27046b5186 Give completion items a bit more space 2014-04-13 22:35:55 +02:00
Florian Bruhin
f59f8cac6c Clear completion model after an item is selected 2014-04-13 22:11:47 +02:00
Florian Bruhin
313d6e3967 Use slicing for getlayers for SettingsValue 2014-04-13 21:48:51 +02:00
Florian Bruhin
65b99dab45 Fix false-positive check 2014-04-11 19:37:49 +02:00
Florian Bruhin
ab31f2a289 Add set_temp command 2014-04-11 19:34:46 +02:00
Florian Bruhin
a3a81543a0 Don't write temp layer to config 2014-04-11 19:34:34 +02:00
Florian Bruhin
80ca9a8dd0 Whitespace fix 2014-04-11 19:33:11 +02:00
Florian Bruhin
e12531e766 Fix dict-change (change attibute to item access) 2014-04-11 19:32:20 +02:00
Florian Bruhin
b0792203a5 Change namedtuple to OrderedDict for conflayers 2014-04-11 17:49:15 +02:00
Florian Bruhin
e7c23312d7 Start implementing different config layers.
With a namedtuple though, which is pretty much a fail.
2014-04-11 07:16:16 +02:00
Florian Bruhin
575a934892 Move SettingValue to own file 2014-04-11 06:28:07 +02:00
Florian Bruhin
04807489b7 Update everything needed when config is changed 2014-04-10 23:30:45 +02:00
Florian Bruhin
aa616e5ac7 Start implementing config changed signal 2014-04-10 18:01:16 +02:00
Florian Bruhin
175eabdc80 Remove fallback values from config 2014-04-10 14:40:02 +02:00
Florian Bruhin
c5ca0e56be Remove blank lines before """ in docstrings.
pep257 has changed in this regard so we reflect this change.
2014-04-10 14:21:27 +02:00
Florian Bruhin
cba2d4d450 Basic validation for zoom values 2014-04-10 12:57:57 +02:00
Florian Bruhin
c845db4799 Refactor config and sectionproxy 2014-04-10 12:37:53 +02:00
Florian Bruhin
4ff86b660c Lint fixes 2014-04-10 12:24:41 +02:00
Florian Bruhin
33aa8bfa52 Fix checking of boolean states 2014-04-10 12:22:22 +02:00
Florian Bruhin
32ce8e6772 Print nice error messages on wrong setting values 2014-04-10 12:20:15 +02:00
Florian Bruhin
c05e66a9b9 Refactor ValueList 2014-04-10 12:09:32 +02:00
Florian Bruhin
21e628a1ba Add __setitem__ to ValueList 2014-04-10 12:05:32 +02:00
Florian Bruhin
1a20bbe7d0 Fix missing options when setting 2014-04-10 12:03:42 +02:00
Florian Bruhin
c1df7cd1fc Handle missing sections/options in :set 2014-04-10 12:01:02 +02:00
Florian Bruhin
237ff93908 Fix nargs handling 2014-04-10 11:58:05 +02:00
Florian Bruhin
e8f2698877 Improve argument count exception message 2014-04-10 09:56:06 +02:00
Florian Bruhin
6175f5c489 Use ConfigParser-like exceptions for config 2014-04-10 09:52:05 +02:00
Florian Bruhin
2442cf11ab Remove old logging 2014-04-10 09:40:16 +02:00
Florian Bruhin
60cb5ad85d Lint fixes 2014-04-10 07:42:21 +02:00
Florian Bruhin
763276a65f Make dump_userconfig work 2014-04-10 07:37:13 +02:00
Florian Bruhin
a0a8f5d025 Make :set work correctly 2014-04-10 07:09:12 +02:00
Florian Bruhin
e9317f807b Accept single int in register decorator for nargs 2014-04-10 07:04:02 +02:00