Commit Graph

632 Commits

Author SHA1 Message Date
Florian Bruhin
e33b87f713 sourcemodel and logging updates 2014-03-10 00:39:15 +01:00
Florian Bruhin
bd4dba1ed3 Broken setting completion 2014-03-10 00:39:15 +01:00
Florian Bruhin
1c43da163e Make this run again 2014-03-10 00:39:15 +01:00
Florian Bruhin
4f5b6040ad Implement ValidValues class 2014-03-10 00:39:15 +01:00
Florian Bruhin
4ea77c7ec2 Cleanups and bugfixes 2014-03-10 00:39:15 +01:00
Florian Bruhin
02b4f2fdda Remove templates.py 2014-03-10 00:39:15 +01:00
Florian Bruhin
f679a97efc Use OrderedDict for ValueList 2014-03-10 00:39:15 +01:00
Florian Bruhin
c67f0c6482 Don't inherit AutoSearch from bool 2014-03-10 00:39:15 +01:00
Florian Bruhin
8d726cb49e Drop whitespace when possible. 2014-03-10 00:39:15 +01:00
Florian Bruhin
3ce1388137 Use default_conf if it's available. 2014-03-10 00:39:15 +01:00
Florian Bruhin
d1054406c2 Remove qutebrowser.conf 2014-03-10 00:39:15 +01:00
Florian Bruhin
22506fd6f4 More config output improvments 2014-03-10 00:39:15 +01:00
Florian Bruhin
c74bfdef0e Print type and valid values 2014-03-10 00:39:15 +01:00
Florian Bruhin
7206dd674a Config cleanup 2014-03-10 00:39:14 +01:00
Florian Bruhin
7d3e8d940c More string output improvements 2014-03-10 00:39:14 +01:00
Florian Bruhin
301f952ccb Improve config output 2014-03-10 00:39:14 +01:00
Florian Bruhin
277f4d841d Add command descriptions to config file generation 2014-03-10 00:39:14 +01:00
Florian Bruhin
e4cd92a293 Make config printing work 2014-03-10 00:39:14 +01:00
Florian Bruhin
6c6a827bab Move configdata to own file 2014-03-10 00:39:14 +01:00
Florian Bruhin
5564e4365e Post-refactor bugfixes 2014-03-10 00:39:14 +01:00
Florian Bruhin
40d7fc6f14 Start refactoring new config to use types 2014-03-10 00:39:14 +01:00
Florian Bruhin
641efb5c18 Make NewConfig descriptions const 2014-03-10 00:39:14 +01:00
Florian Bruhin
4e78775d3c Fix checks 2014-03-10 00:39:14 +01:00
Florian Bruhin
cd29814ef3 Bugfix/improve config output 2014-03-10 00:39:14 +01:00
Florian Bruhin
2a7fca8652 Add more documentation 2014-03-10 00:39:14 +01:00
Florian Bruhin
b2b23e032a Implement __str__ for Config, delete unneeded __str__'s 2014-03-10 00:39:14 +01:00
Florian Bruhin
98d15de460 Fix style issues 2014-03-10 00:39:14 +01:00
Florian Bruhin
09d94bddfe Clean unused import 2014-03-10 00:39:14 +01:00
Florian Bruhin
758f75a106 Revert "Log config values."
This reverts commit f839b5bd9664a7473c25b5267d56d517e69f19cd.
2014-03-10 00:39:14 +01:00
Florian Bruhin
75481e6b13 Fix default values for fonts 2014-03-10 00:39:14 +01:00
Florian Bruhin
be4492216e Stop logging stylesheets 2014-03-10 00:39:14 +01:00
Florian Bruhin
de91985761 Log config values. 2014-03-10 00:39:14 +01:00
Florian Bruhin
d2fbbe0f6c Add logging for generated stylesheets. 2014-03-10 00:39:14 +01:00
Florian Bruhin
a49a486cef Fix config bugs 2014-03-10 00:39:14 +01:00
Florian Bruhin
ab40f59b2e Whoops, add sections.py 2014-03-10 00:39:14 +01:00
Florian Bruhin
369ee1f47e Config bugfixes.
Stylesheet still broken, but at least keybindings work.
2014-03-10 00:39:14 +01:00
Florian Bruhin
f079d6bf3b More config update/adoption 2014-03-10 00:39:14 +01:00
Florian Bruhin
54e2ba4de2 Add some new value types 2014-03-10 00:39:14 +01:00
Florian Bruhin
062e385028 Config update and cleanup 2014-03-10 00:39:14 +01:00
Florian Bruhin
4b3ae3f013 Style fixes 2014-03-10 00:39:14 +01:00
Florian Bruhin
265d8b7580 Avoid circular dependencies 2014-03-10 00:39:14 +01:00
Florian Bruhin
12b6dfc6b7 Fix syntax bugs 2014-03-10 00:39:14 +01:00
Florian Bruhin
5f6cc7b05a Fix namespace and continue config structure. 2014-03-10 00:39:14 +01:00
Florian Bruhin
395acffdc4 Start new config subsystem 2014-03-10 00:39:14 +01:00
Florian Bruhin
b6a28aba7b Add some documentation for decorators 2014-03-10 00:38:48 +01:00
Florian Bruhin
6f093d33c1 Fix paste command 2014-03-04 16:52:56 +01:00
Florian Bruhin
9ee4e93e0a Split browser.py into smaller files 2014-03-03 21:35:13 +01:00
Florian Bruhin
98fb1a0250 Remove unused imports 2014-03-03 21:24:33 +01:00
Florian Bruhin
eb2097772d Add utils/debug.py 2014-03-03 21:22:20 +01:00
Florian Bruhin
e30774e9d9 Fix variable name 2014-03-03 21:21:07 +01:00
Florian Bruhin
b75fc347dc Fix checks 2014-03-03 21:19:29 +01:00
Florian Bruhin
508d9e347c Swap q/quit for quit command 2014-03-03 21:11:02 +01:00
Florian Bruhin
af0b6901be First kinda working version 2014-03-03 21:06:10 +01:00
Florian Bruhin
97ae3adb4a Working towards using getattr instead 2014-03-03 18:47:42 +01:00
Florian Bruhin
032ccb8b43 Try some broken component register foo 2014-03-03 17:56:53 +01:00
Florian Bruhin
b22b19d881 Start using (broken) decorators 2014-03-03 06:09:23 +01:00
Florian Bruhin
2df9b57981 Continue developing register_command decorator 2014-02-28 17:55:17 +01:00
Florian Bruhin
dcc3993091 Start implementing decorator 2014-02-28 17:00:25 +01:00
Florian Bruhin
d4df78b75f Add settrace command 2014-02-26 22:29:53 +01:00
Florian Bruhin
66852aa736 Add FIXME for CompletionItemDelegate 2014-02-26 21:54:24 +01:00
Florian Bruhin
a9a4b2ac92 Add profile.py 2014-02-26 21:18:53 +01:00
Florian Bruhin
4925d25c36 Remove wrong 'cur.' for BrowserTab 2014-02-24 17:37:48 +01:00
Florian Bruhin
ad29867aa6 Remove unneccessary style globals 2014-02-23 18:20:24 +01:00
Florian Bruhin
76a627bb10 Move style related stuff to config.style 2014-02-23 18:15:08 +01:00
Florian Bruhin
3b648a4c0d Move config to config subfolder 2014-02-23 18:14:40 +01:00
Florian Bruhin
0bfe134828 Add first tests (for NeighborList) 2014-02-23 17:39:45 +01:00
Florian Bruhin
7da05b3fb9 Raise better error in NeighborList.curitem if no index is set 2014-02-23 17:39:29 +01:00
Florian Bruhin
b59f0e9a34 Rename types.py to usertypes.py 2014-02-23 16:30:07 +01:00
Florian Bruhin
5f78b96cb1 Move cur_* methods for TabbedBrowser to CurCommandDispatcher class 2014-02-21 22:00:41 +01:00
Florian Bruhin
b8b0d81ab3 Add command aliases 2014-02-21 20:19:01 +01:00
Florian Bruhin
42bac07e6b Whitespace adjustments 2014-02-21 20:07:40 +01:00
Florian Bruhin
e47d13d725 Fix initial tab opening 2014-02-21 20:06:42 +01:00
Florian Bruhin
5d32df1d54 Add :version command 2014-02-21 20:00:02 +01:00
Florian Bruhin
257e6cd67d QuteSchemeHandler cleanup 2014-02-21 19:51:04 +01:00
Florian Bruhin
a96261e7b8 Cleanup 2014-02-21 19:44:46 +01:00
Florian Bruhin
d975ec080d Add isFinished method to schemehandler 2014-02-21 19:24:58 +01:00
Florian Bruhin
61060f0796 Use singleShot QTimers for signals (FIXME: good?) 2014-02-21 07:39:21 +01:00
Florian Bruhin
51616937b8 Use python bytes instead of QByteArray methods. 2014-02-21 07:38:37 +01:00
Florian Bruhin
435f1f45e0 Emit finished at the right places. 2014-02-21 07:37:47 +01:00
Florian Bruhin
29c84f4f20 Add logging to custom requests. 2014-02-21 07:35:53 +01:00
Florian Bruhin
daa3808b7f Spelling fix in comment. 2014-02-21 07:34:49 +01:00
Florian Bruhin
aeb7e0c762 Don't default outgoingData to None 2014-02-21 07:34:21 +01:00
Florian Bruhin
bcd5120922 FIXME: Only destroy replies when they're not special.
Why does a normal destroy not work?
2014-02-21 07:33:32 +01:00
Florian Bruhin
bd6d2e6156 Store instances as scheme handlers, not classes. 2014-02-21 07:18:22 +01:00
Florian Bruhin
90e56e6477 Rename about:... to qute:... 2014-02-21 07:18:04 +01:00
Florian Bruhin
38ef8fe8c7 First attempt at proper AboutSchemeHandler 2014-02-20 23:08:27 +01:00
Florian Bruhin
ec1951c56c Move abouthandler to network subpackage 2014-02-20 22:26:25 +01:00
Florian Bruhin
65ae1882f0 Move NetworkManager to own file 2014-02-20 22:26:25 +01:00
Florian Bruhin
88b8b6ea4e Improve config save warning 2014-02-20 20:49:31 +01:00
Florian Bruhin
82f7e46459 Use NeighborList for history in statusbar. 2014-02-20 20:47:26 +01:00
Florian Bruhin
7fc45728a9 NeighborList: add firstitem() and lastitem() 2014-02-20 20:47:06 +01:00
Florian Bruhin
92b0024f25 NeighborList: Remove off-by-one error 2014-02-20 20:46:53 +01:00
Florian Bruhin
7d74e62696 NeighborList; Remove old FIXME 2014-02-20 20:46:43 +01:00
Florian Bruhin
858ff4a4f0 NeighborList: Ensure self.idx is always set 2014-02-20 20:46:29 +01:00
Florian Bruhin
e1fe6111ec NeighborList: Always cast items to list 2014-02-20 20:46:15 +01:00
Florian Bruhin
4f6e149289 Add logging to NeighborList 2014-02-20 20:46:05 +01:00
Florian Bruhin
7d11790d35 Make it possible to use NeighborList without items 2014-02-20 20:45:30 +01:00
Florian Bruhin
7d878fec7b version string cosmetic fixes 2014-02-20 19:59:22 +01:00
Florian Bruhin
7435a37f36 Style fixes in util.version 2014-02-20 19:56:34 +01:00
Florian Bruhin
cf2133bb96 Add zoomin/zoomout commands. 2014-02-20 19:55:35 +01:00
Florian Bruhin
dc179a65bb Add temp_message signal to BrowserTab 2014-02-20 19:55:35 +01:00
Florian Bruhin
ab8fef3cdb Add new NeighborList datatype 2014-02-20 19:55:35 +01:00
Florian Bruhin
2b820ec696 Add zoomlevels to config 2014-02-20 18:00:24 +01:00
Florian Bruhin
b3fa7bba98 Improve version info 2014-02-20 15:32:46 +01:00
Florian Bruhin
b91b6038c6 Emit dataChanged correctly for model 2014-02-20 11:24:24 +01:00
Florian Bruhin
561a7e1cdd Add workaround to keystring so it gets cleared properly. 2014-02-19 23:08:38 +01:00
Florian Bruhin
1c921a77f6 Set scroll percentage to 0 in __init__ 2014-02-19 16:25:15 +01:00
Florian Bruhin
21cf1cc700 Remove unnecessary lambda 2014-02-19 15:57:13 +01:00
Florian Bruhin
3a140b9a1c Split text to normal/error/tmp again, show text.
This splits the text shown in the statusbar into normal/error/temporary
text again, and shows the text when idle instead of the command.
2014-02-19 15:40:43 +01:00
Florian Bruhin
c2e3039702 Only hide temporary error message on non-modifiers 2014-02-19 14:57:31 +01:00
Florian Bruhin
cb47ae1b43 Fix pyqtSlot() decorations. 2014-02-19 14:57:16 +01:00
Florian Bruhin
b03932400f Simplify displaying text a lot.
This now only has one category of text, and displays it in a
QStackedWidget with the Command.
2014-02-19 14:44:40 +01:00
Florian Bruhin
ab87c8e8b9 Clear temporary text on keypress. 2014-02-19 14:44:38 +01:00
Florian Bruhin
c57e78b765 Display temporary messages in statusbar.
For some odd reason, old messages still don't get cleared properly.
2014-02-19 14:44:37 +01:00
Florian Bruhin
4b91915090 Bugfix: initialize _url_stack for Browser properly. 2014-02-19 14:44:00 +01:00
Florian Bruhin
d2b733ea7a Check if Exception is subclass of Exception properly 2014-02-19 13:37:42 +01:00
Florian Bruhin
f70ad71f9c Add error strings to exceptions 2014-02-19 11:11:21 +01:00
Florian Bruhin
93065188a7 All-caps constants 2014-02-19 11:11:19 +01:00
Florian Bruhin
d58ef3ff84 Fix CommandParser.run exit status. 2014-02-19 11:11:18 +01:00
Florian Bruhin
9a990d56d9 Nicer docstrings 2014-02-19 10:58:32 +01:00
Florian Bruhin
581f88fcce Avoid pylint maybe-no-member warnings for ConfigParser. 2014-02-18 19:32:00 +01:00
Florian Bruhin
6d709d9fd8 Allow completion widget height to be configured in % 2014-02-18 19:05:56 +01:00
Florian Bruhin
9318558eb6 Make completion height configurable 2014-02-18 18:42:43 +01:00
Florian Bruhin
9568be3d2a Use default geometry if no geometry was saved. 2014-02-18 18:38:48 +01:00
Florian Bruhin
96747c9d58 Reordering in widget submodules 2014-02-18 18:32:07 +01:00
Florian Bruhin
034f85b1d4 Use property for CompletionFilterModel.srcmodel 2014-02-18 17:57:58 +01:00
Florian Bruhin
5f83228c75 Reorder some methods, widgets not done yet 2014-02-18 17:54:17 +01:00
Florian Bruhin
0425ce7b48 Extend paintEvent instead of using an eventFilter 2014-02-18 17:26:26 +01:00
Florian Bruhin
2fe2ca85c2 Set WA_StyledBackground for statusbar instead of overriding paintEvent 2014-02-18 16:57:10 +01:00
Florian Bruhin
911d5d3b4a Refactor ALL the things 2014-02-18 16:51:01 +01:00
Florian Bruhin
6cd02ca368 utils.config docstring update 2014-02-18 14:37:49 +01:00
Florian Bruhin
2fcda0e67b Refactor Config.get() 2014-02-18 14:34:46 +01:00
Florian Bruhin
3d37b22fb0 Cleanup 2014-02-18 14:21:39 +01:00
Florian Bruhin
234d171483 Use Qt saveGeometry and restoreGeometry 2014-02-18 14:14:27 +01:00
Florian Bruhin
c9e4f2417d Add more shutdown debugging 2014-02-18 13:05:42 +01:00
Florian Bruhin
109906043e Add a trace_lines util function 2014-02-18 12:10:36 +01:00
Florian Bruhin
bbab0e7430 autosearch bugfix and debug output 2014-02-18 12:02:07 +01:00
Florian Bruhin
27d354633c Save/restore window geometry. 2014-02-18 11:57:35 +01:00
Florian Bruhin
96d01f8755 Improve fallback handling for Config. 2014-02-18 11:57:19 +01:00
Florian Bruhin
306371aa31 Better logging when shutdown fails. 2014-02-18 11:56:40 +01:00
Florian Bruhin
8ba4661838 bugfix: Fix command history 2014-02-18 10:50:41 +01:00
Florian Bruhin
df0e534a0b bugfix: Always handle about-URLs as URL. 2014-02-18 10:47:02 +01:00
Florian Bruhin
8fee32e6c4 Support multiple commands 2014-02-18 10:47:01 +01:00
Florian Bruhin
88ea6e62b1 Unify auto_search/addressbar_dns_lookup 2014-02-18 10:46:59 +01:00
Florian Bruhin
99aba6d9c0 Move default config to file 2014-02-18 10:33:57 +01:00
Florian Bruhin
d349a987c7 CrashDialog: add Stretch before buttons. 2014-02-18 08:52:37 +01:00
Florian Bruhin
8c1619236b CrashDialog: fix layout setting issue 2014-02-18 08:52:25 +01:00
Florian Bruhin
8d9280d1d8 Set more parents 2014-02-18 08:37:05 +01:00
Florian Bruhin
2779b2f42e Fix cur_scroll_page regression. 2014-02-17 22:24:17 +01:00
Florian Bruhin
ab89a3baf0 Cleanup 2014-02-17 22:21:11 +01:00
Florian Bruhin
57b2dc84fc More crash handling fixes. 2014-02-17 20:39:15 +01:00
Florian Bruhin
14a090c087 More shutdown/crashing improvments. 2014-02-17 20:30:09 +01:00
Florian Bruhin
1dc382e2b7 Process pending events before opening startpage.
We now call QApplication::processEvents before
QNetworkAccessManager::createRequest (which takes >1s) is run, so all
waiting GUI events get handled and the GUI is drawn for the first time.
2014-02-17 17:47:21 +01:00
Florian Bruhin
9c0f0e8ac5 Add last_close setting. 2014-02-17 16:50:41 +01:00
Florian Bruhin
01096b995c Store more Qt properties as class attributes. 2014-02-17 16:09:27 +01:00
Florian Bruhin
b90d402587 Fix comment typo. 2014-02-17 15:39:21 +01:00
Florian Bruhin
3d882897c0 Use singleShot QTimer to process init arguments.
This processes all init arguments after the startup has completely
finished, so that things like   qutebrowser ':quit'   work correctly.
2014-02-17 14:37:12 +01:00
Florian Bruhin
8c37e1c33a Make closing/crashing much more reliable. 2014-02-17 14:17:56 +01:00
Florian Bruhin
966ceba1e6 Import cleanup 2014-02-17 12:23:52 +01:00
Florian Bruhin
d5807169d1 Decorate slots with pyqtSlot.
This seems to reduce memory usage a bit and make things a bit faster.
2014-02-17 12:00:08 +01:00
Florian Bruhin
0abb5cf738 Try to shut down everything cleanly. 2014-02-17 10:20:57 +01:00
Florian Bruhin
63ee3f4efd Set Qt application name/version. 2014-02-17 08:56:33 +01:00
Florian Bruhin
9257f0c98a Don't keep static references to QPainter.
For some reason, this seems to cause a segfault.
2014-02-17 08:42:12 +01:00
Florian Bruhin
76a459f604 Add more hard references.
This should prevent some segfaults, as pointed out by [1].

 [1]: https://github.com/integricho/path-of-a-pyqter/tree/master/qttut02
2014-02-17 08:19:30 +01:00
Florian Bruhin
933296f47f Move models to qutebrowser.models 2014-02-14 17:41:12 +01:00
Florian Bruhin
302736925b Clean up read_file(). 2014-02-14 16:43:41 +01:00
Florian Bruhin
434a904335 Add icon= to error html format() 2014-02-14 07:50:31 +01:00
Florian Bruhin
e56ed54102 Add broken error pages 2014-02-14 07:17:36 +01:00
Florian Bruhin
203fa3eb34 Docstring grammar fixes 2014-02-13 18:57:19 +01:00
Florian Bruhin
62f140cf88 Remove unneeded self.show()s 2014-02-13 18:47:39 +01:00
Florian Bruhin
176c1aa7d6 Use float() where applicable, not int() 2014-02-13 11:48:25 +01:00
Florian Bruhin
a7d52feb99 Add ga binding 2014-02-13 10:30:52 +01:00
Florian Bruhin
029813c8eb Implement page-wise scrolling. 2014-02-13 10:28:09 +01:00
Florian Bruhin
7deab20820 Cleanup, more checks 2014-02-13 09:10:53 +01:00
Florian Bruhin
963b90ae74 Disable pylint maybe-no-member in TabWidget._init_config 2014-02-13 09:00:07 +01:00
Florian Bruhin
5b0e24b799 Make tabbar configurable. 2014-02-13 08:56:01 +01:00
Florian Bruhin
d7f58015bb Set sizePolicy of Command to minimumExpanding. 2014-02-13 07:16:47 +01:00
Florian Bruhin
4271200846 Emit urlChanged immediately when opening a new tab. 2014-02-13 07:11:18 +01:00
Florian Bruhin
ca97a50820 Call tab.openurl _after_ connecting signals. 2014-02-13 07:10:41 +01:00
Florian Bruhin
0326a66758 Don't color progress bar anymore. 2014-02-13 07:06:34 +01:00
Florian Bruhin
6538dbbdf1 Colorize URLs in statusbar, fix hovering.
Before, when hovering from an URL to another URL, the old hover-URL was
saved as old-url. This is now fixed.
2014-02-13 06:58:17 +01:00
Florian Bruhin
76ba7921d4 Elide statusbar text/URLs correctly. 2014-02-12 23:56:23 +01:00
Florian Bruhin
7bfc1eb791 Add FIXME for color validation 2014-02-12 23:28:03 +01:00
Florian Bruhin
626b9fc3b8 Ignore StatusBar sizehint 2014-02-12 23:04:46 +01:00
Florian Bruhin
d343ea26af Don't use QMainWindow 2014-02-12 23:04:46 +01:00
Florian Bruhin
f893b11f1b Fix progress bar being red hopefully. 2014-02-12 17:13:31 +01:00
Florian Bruhin
5342b88519 linting update 2014-02-12 17:00:50 +01:00
Florian Bruhin
c0dc9f8622 Use Qt properties for condition coloring. 2014-02-12 17:00:39 +01:00
Florian Bruhin
002118953c Use separate QHBoxLayout elements for statusbar. 2014-02-12 08:48:54 +01:00
Florian Bruhin
c77589a821 Make SignalCache an own class. 2014-02-11 14:04:36 +01:00
Florian Bruhin
d4e69c955e Show hovered link in statusbar. 2014-02-11 13:33:33 +01:00
Florian Bruhin
1134461953 Make it possible to ignore signals for cache. 2014-02-11 13:27:26 +01:00
Florian Bruhin
0676508687 Add signal_name in utils.misc 2014-02-11 13:26:41 +01:00
Florian Bruhin
d37318b851 Immediately emit cur_url_changed when opening new tab. 2014-02-11 13:08:15 +01:00
Florian Bruhin
9aa49b7fe8 Pad scroll percentage. 2014-02-11 13:06:02 +01:00
Florian Bruhin
d89098582f Show URL in statusbar. 2014-02-11 11:50:37 +01:00
Florian Bruhin
7486cb628a Revert "Delete QWebViews when tabs are closed."
This reverts commit 83276b9576.

This causes lots of segfaults and other strange stuff when a tab is
closed.
2014-02-11 11:31:20 +01:00
Florian Bruhin
83276b9576 Delete QWebViews when tabs are closed. 2014-02-11 11:17:53 +01:00
Florian Bruhin
26787b0d30 Add custom set_trace for debugging. 2014-02-11 10:30:17 +01:00
Florian Bruhin
796cb0c7b6 Clean up style proxy to be much more concise. 2014-02-11 07:45:28 +01:00