Commit Graph

3318 Commits

Author SHA1 Message Date
Florian Bruhin
8bad7c0e4c Use maxsplit=1 for :repeat and :later. 2014-12-11 21:27:44 +01:00
Florian Bruhin
451df7bbf4 Handle flags with args correctly with split=False. 2014-12-11 21:17:43 +01:00
Florian Bruhin
3579caf1ff Make mode a kwarg-only argument for :bind. 2014-12-11 21:17:22 +01:00
Florian Bruhin
1d6661f90b Set maxsplit=0 for :set-cmd-text.
See #233.
2014-12-11 20:35:04 +01:00
Florian Bruhin
db4ca495f2 Use maxsplit=1 for :bind.
See #233.
2014-12-11 20:34:38 +01:00
Florian Bruhin
b7ea8e7979 Support a maxsplit argument for commands. 2014-12-11 20:32:52 +01:00
Florian Bruhin
81bc5dae94 Remove quotes with split=False commands.
Fixes #313.
2014-12-11 20:04:29 +01:00
Florian Bruhin
8c4c465c91 Fix completion update when the length is unchanged.
Fixes #312.
2014-12-11 18:37:22 +01:00
Florian Bruhin
4e6cedb1f7 Don't treat page load as failed with blocked hosts.
Fixes #315.
2014-12-11 18:05:01 +01:00
Florian Bruhin
5eeb89ec86 Add a :quickmark-del command. 2014-12-10 23:30:04 +01:00
Florian Bruhin
d0b5f2087a Fix un-hiding of hints. 2014-12-10 23:22:25 +01:00
Florian Bruhin
b00e00db37 Add a "retry" entry to the download menu.
Closes #38.
2014-12-10 21:56:57 +01:00
Florian Bruhin
9553bd44c1 Add an open menu entry to downloads.
See #39.
2014-12-10 20:48:19 +01:00
Florian Bruhin
0ecf8661eb Create inexistent paths in standardpath.get.
See #25.
2014-12-10 18:05:42 +01:00
Florian Bruhin
ec07e4f8be Handle OSError exceptions where appropriate.
Fixes #25.
2014-12-10 18:00:49 +01:00
Florian Bruhin
ea76bdfb0f Replace all IOError by OSErrors.
Starting with Python 3.3, IOError is just an alias for OSError.
2014-12-10 16:48:23 +01:00
Florian Bruhin
206b5f548e Fix checking for errors when a page is loaded.
Because of the error page, we got loadFinished with ok=True even with errors.

Fixes #84.
2014-12-10 16:38:24 +01:00
Florian Bruhin
06cc982ab5 Dynamically calculate needed size for command.
Closes #26.
2014-12-10 15:35:13 +01:00
Florian Bruhin
db2d4a6bed tabwidget: Add text padding in minimumTabSizeHint.
See #283.
2014-12-10 14:45:00 +01:00
Florian Bruhin
ef12bde654 tabwidget: Fix ...-width in minimumTabSizeHint.
See #283.
2014-12-10 14:44:28 +01:00
Florian Bruhin
92b9dc08f4 tabwidget: Clean up and fix minimumTabSizeHint.
See #283.

The width now accounts for the indicator, and the wrong docstring has been
removed.
2014-12-10 14:29:14 +01:00
Florian Bruhin
bac30b9192 Set a minimum height for the statusbar widget.
Fixes #194.
2014-12-10 14:15:34 +01:00
Florian Bruhin
b30ca6bcb6 Don't record command history in private mode.
Fixes #43.
2014-12-10 13:19:42 +01:00
Florian Bruhin
76c5c8bf8e cookies/cache: Handle por^H^Hrivate browsing mode.
See #43.
2014-12-10 13:12:53 +01:00
Florian Bruhin
0b82fdb4d8 Fix text/newline handling with QSaveFile.
Fixes #309.

We use io.TextIOWrapper which already handles newline converting, so we
shouldn't open the QSaveFile with QIODevice.Text in the mode, as this lead to
double-converting newlines, which in turn produced this error message on
Windows.
2014-12-10 10:58:55 +01:00
Florian Bruhin
7e95401f02 Check if download reply is None when closing tab.
Fixes #311.
2014-12-09 17:37:57 +01:00
Florian Bruhin
bf24578dfd Use QSaveFile for saving files. Fixes #234. 2014-12-08 23:42:26 +01:00
Florian Bruhin
d611a37d7d Fix statusbar with nested passthrough modes.
Fixes #87.
2014-12-08 20:18:55 +01:00
Florian Bruhin
1d7f704804 Fix comment typo. 2014-12-08 20:06:40 +01:00
Florian Bruhin
2b41c13e8b Fix lint 2014-12-08 18:52:20 +01:00
Florian Bruhin
0c1420112c Fix config interpolation with non-default values.
Fixes #202.
2014-12-08 18:50:53 +01:00
Florian Bruhin
175d01f516 config: Don't escape <eq> specially anymore. 2014-12-08 18:16:21 +01:00
Florian Bruhin
4ab4ac3db6 downloads: Make sure read timer is stopped.
Hopefully fixes #307.
2014-12-08 16:16:03 +01:00
Florian Bruhin
07fed5a401 Don't nest function calls in on_read_timer_timeout.
This would have made it easier to diagnose #307.
2014-12-08 16:07:50 +01:00
Florian Bruhin
edfc0e24b2 Abort running questions when closing tab.
Fixes #306.
2014-12-08 16:04:56 +01:00
Florian Bruhin
4829aee767 Add a --no-crash-dialog debug option. 2014-12-06 00:39:33 +01:00
Florian Bruhin
24d21bfe98 I suck. 2014-12-05 21:15:11 +01:00
Florian Bruhin
9946b4b0f6 Really disable that damn pylint check 2014-12-05 21:14:18 +01:00
Florian Bruhin
7aa01802d9 Whoops, s/ignore/disable/ 2014-12-05 21:08:15 +01:00
Florian Bruhin
c80f83671f pylint: ignore pypeg2 import error 2014-12-05 21:03:23 +01:00
Florian Bruhin
98a384c167 Properly ignore distutils-bug in qtutils. 2014-12-05 12:56:32 +01:00
Florian Bruhin
653fbe81d0 pylint: Ignore distutils ImportError.
See https://bitbucket.org/logilab/pylint/issue/73/
2014-12-05 12:46:57 +01:00
Florian Bruhin
1fb24e45ff Newline fix in adblock.py 2014-12-04 21:35:32 +01:00
Florian Bruhin
1af7112ea4 Handle ampersands in tab titles correctly.
Fixes #301.
2014-12-03 21:31:59 +01:00
Florian Bruhin
95d919b5f6 Force opening in fg when opening a JS-window.
Fixes #174.
2014-12-03 19:31:00 +01:00
Florian Bruhin
3adb97e4d2 Merge branch 'master' of ssh://tonks/qutebrowser 2014-12-02 21:28:54 +01:00
Florian Bruhin
03fb21c476 Use scrollRequested signal instead of paintEvent.
Closes #300.
2014-12-02 21:27:11 +01:00
Florian Bruhin
d94f848c82 Ignore isNullError while handling label elements.
Fixes #295 (hopefully for real this time!)
2014-12-02 21:27:06 +01:00
Florian Bruhin
99fb516aa3 Never disconnect signal from destroyed frames.
Fixes #152 - hopefully really this time!
2014-12-02 21:09:03 +01:00
Florian Bruhin
0814811e2b Change default startpage to HTTPS. 2014-12-02 16:38:57 +01:00
Florian Bruhin
66a42512c6 adblock: Convert some methods to functions. 2014-12-02 12:26:13 +01:00
Florian Bruhin
cd5f77210c Add keybinding Ss to open qute:settings.
See #13.
2014-12-01 23:11:18 +01:00
Florian Bruhin
c86b1d0508 Open qute:settings if :set is given without arguments. 2014-12-01 23:09:01 +01:00
Florian Bruhin
9fa036ecce Remove logging for #152.
This reverts a1ba05ff08.
2014-12-01 22:29:32 +01:00
Florian Bruhin
51fcfa07b0 Fix setting ui->default-zoom to a level not in ui->zoom-levels.
Fixes #296.
See #115.
2014-12-01 20:24:04 +01:00
Florian Bruhin
e8a6238028 Clean up hint labels and frames before clicking link.
Fixes #152.
Hopefully fixes #295.
2014-12-01 19:15:17 +01:00
Florian Bruhin
cb67198f7d Fix download redirections and :adblock-update.
We called init_reply again which started read_timer even if the file object was
already set.

Fixes #294.
2014-12-01 07:40:36 +01:00
Florian Bruhin
316d5ff189 Check if replies are open in downloads. 2014-12-01 07:35:57 +01:00
Florian Bruhin
f22c00c64d Move MAX_REDIRECTS attribute back to DownloadItem.
Fixes #293.
2014-12-01 06:55:15 +01:00
Florian Bruhin
fea35156bc Set parent of QNetworkReplies in NetworkManager.
Closes #258.
2014-11-30 22:38:12 +01:00
Florian Bruhin
64e43c6e14 Ignore IPC in exception handler. Closes #262. 2014-11-30 22:30:26 +01:00
Florian Bruhin
d558155620 Simplify some config types by using valid_values. 2014-11-30 22:16:55 +01:00
Florian Bruhin
1ceb8ac74d Add an ssl-strict=ask option. Closes #16. 2014-11-30 21:57:37 +01:00
Florian Bruhin
e3dfaa6a4b Send cwd over IPC. Fixes #254. 2014-11-30 19:22:35 +01:00
Florian Bruhin
9327c2a9ae Remove trailing spaces in simple_split with keep=False.
Fixes #279.
2014-11-30 18:59:51 +01:00
Florian Bruhin
9d28c59a28 Fix downloading of qute:log. Closes #81. 2014-11-30 18:47:41 +01:00
Florian Bruhin
d54f06ea91 Reparent a page's QNAM if there are running downloads.
Fixes #289.
2014-11-30 18:47:40 +01:00
Florian Bruhin
6d419b8346 Avoid starting downloads before we know the filename.
Closes #278.
2014-11-30 18:47:40 +01:00
Florian Bruhin
302fcec3ed Merge branch 'master' of ssh://tonks/qutebrowser 2014-11-30 17:30:27 +01:00
Florian Bruhin
25a665e601 Abort download question on errors. Fixes #266. 2014-11-30 15:34:15 +01:00
Florian Bruhin
a00dd7b679 Slowly download while the user is entering a filename.
Closes #79.
Closes #270.
2014-11-30 15:30:15 +01:00
Florian Bruhin
60ef39b4d0 fixup 2014-11-30 15:30:15 +01:00
Florian Bruhin
ee0cb00428 First download cleanup. 2014-11-30 15:30:14 +01:00
Florian Bruhin
d32096495d Apply default zoom correctly.
Fixes #287.
2014-11-28 17:01:29 +01:00
Mathias Fussenegger
aeb6ceb942 correct search engine regex to match multiple search terms 2014-11-27 22:59:43 +01:00
Florian Bruhin
f6dffa74b6 Fix lint 2014-11-27 22:27:13 +01:00
Florian Bruhin
9bd8d3f2e5 Merge branch 'search-engine-syntax' of https://github.com/mfussenegger/qutebrowser into mfussenegger-search-engine-syntax 2014-11-27 22:19:07 +01:00
Mathias Fussenegger
68398035ef change search engine syntax to match that of dwb
as pointed out in
https://github.com/The-Compiler/qutebrowser/issues/14 this
commit changes the syntax so that DuckDuckGo bang syntax
works.
2014-11-27 21:57:51 +01:00
Florian Bruhin
68b9aaace4 Add utils.raises. Closes #274. 2014-11-27 20:44:48 +01:00
Florian Bruhin
c87fa34544 Use a QTime in widgets.statusbar.bar. Fixes #124. 2014-11-27 20:09:58 +01:00
Florian Bruhin
cb1df68153 Automatic config migration for renamed sections/options. 2014-11-27 07:07:28 +01:00
Florian Bruhin
bdbe284a56 Fix tabbar updating when changing fg colors. 2014-11-26 21:21:02 +01:00
Florian Bruhin
d34aefcfee Another round of config breakage (sorry!).
- Rename colors->tab.* to colors->tabs.*
- Rename permission section to content.
2014-11-26 21:16:27 +01:00
Florian Bruhin
e8966ec7bb Remove some shlex vdebug. 2014-11-26 21:02:20 +01:00
Florian Bruhin
cbac8bb330 Fix lint 2014-11-25 23:24:52 +01:00
Florian Bruhin
7e879c9312 Don't add javascript-bridge only once.
Otherwise, qute:settings will break when reloading it.
2014-11-25 23:21:49 +01:00
Florian Bruhin
e85e11310d Merge branch 'master' of https://github.com/iggy/qutebrowser into iggy-master 2014-11-25 23:03:09 +01:00
Brian Jackson
9cfb4b3431 Fix problem with qutesettings scope in pages
Fix to make sure the js bridge code is only enabled when qute: pages are shown.
Previously it would only be available to the first page (and before that it
was available to all pages).
2014-11-25 14:29:20 -06:00
Florian Bruhin
010efcee93 Don't treat floats as IPs either. 2014-11-25 21:19:24 +01:00
Florian Bruhin
683a306c51 Fix @log_signals with deleted objects. 2014-11-25 19:51:53 +01:00
Brian Jackson
4fd4376c6a Pass around win_id so we can use it in the error message handler
The message class needs a win_id to know where to send error messages. Just
pass it through the jinja->js->qtwebbridge as it's just a simple int.
2014-11-25 11:19:00 -06:00
Brian Jackson
bf37d16896 View/edit browser config in a special browser page
Add the ability to view/edit the browser's config settings via a special
browser page.

It's very simplistic for now, but a good starting point.

Future possibilities:
* Matching config types to html input types
  * colors = html colorpicker
  * options with valid_values = select/multi-select
  * plain text fallbacks where appropriate
  * multi-line text edits for long options (i.e. host-block-lists)

* Javascript option verification
  * switch from submitting changes onblur to onchange if an option passes basic
    verification, etc.
2014-11-25 10:34:06 -06:00
Florian Bruhin
6973050ccc Don't treat any valid int as IP 2014-11-24 21:49:48 +01:00
Florian Bruhin
7be32dd70c Don't handle hexadecimal numbers as IP addresses.
Fixes #269.
2014-11-24 21:47:22 +01:00
Florian Bruhin
186f292586 Remove unused import 2014-11-24 21:07:03 +01:00
Florian Bruhin
0134646c67 Basic host blocker implementation.
Squashed commit of the following:

commit 8d38e9c2f13778fe21cc2c1d61c5d26907b469ef
Author: Florian Bruhin <git@the-compiler.org>
Date:   Mon Nov 24 21:04:30 2014 +0100

    Fix default adblock lists.

commit a734b87e753daec28fa0c6643af8de088041179a
Author: Florian Bruhin <git@the-compiler.org>
Date:   Mon Nov 24 21:04:14 2014 +0100

    Fix error output on adblock errors.

commit 15bc10f605ebb86c12523bb81b55d1440fcacdbf
Author: Florian Bruhin <git@the-compiler.org>
Date:   Mon Nov 24 07:38:47 2014 +0100

    Update adblock docks

commit 475d530ee50f52295c2171208c6a0278750cf4b4
Author: Florian Bruhin <git@the-compiler.org>
Date:   Mon Nov 24 07:38:39 2014 +0100

    Remove adblock ram calculation

commit 0e52cc3ec93912fd3fa3ecf6de833aef0c540a60
Author: Florian Bruhin <git@the-compiler.org>
Date:   Mon Nov 24 07:03:11 2014 +0100

    Adjust docs for hosts-file.

commit 941df242d38300d7e42a26f2e67cfd668c6f8590
Author: Florian Bruhin <git@the-compiler.org>
Date:   Mon Nov 24 06:55:40 2014 +0100

    Add logging for host blocking.

commit 4ca1561ccf32affb8439113f4f1c222d7dee1e14
Author: Florian Bruhin <git@the-compiler.org>
Date:   Mon Nov 24 00:11:59 2014 +0100

    Don't do adblock updates automatically after changing config.

commit 26d4e86ca393d4a1a5fd8fac7729ce9c2e7cd240
Author: Florian Bruhin <git@the-compiler.org>
Date:   Thu Nov 20 19:58:32 2014 +0100

    adblock: Don't delete blocked hosts between files.

commit c7af08c68adf3c135d5a2fc746eb6d3c715b0711
Author: Florian Bruhin <git@the-compiler.org>
Date:   Thu Nov 20 19:58:22 2014 +0100

    adblock: Add comments for rewinding.

commit 9af87313088cd79ab8c022bcee9308511d6328f0
Author: Florian Bruhin <git@the-compiler.org>
Date:   Thu Nov 20 19:56:39 2014 +0100

    adblock: Rewind files properly.

commit 7f3dadc04ba68c92d6789ecf5822f7b2dfc367a0
Author: Florian Bruhin <git@the-compiler.org>
Date:   Thu Nov 20 19:40:18 2014 +0100

    Add untested file support.

commit 334c01867d510b599d94c9397097a1d789c0c64c
Author: Florian Bruhin <git@the-compiler.org>
Date:   Wed Nov 19 22:33:25 2014 +0100

    adblock: Handle download errors correctly

commit 3a9af4cd4a903386dc323640f1d52e03383b3aa7
Author: Florian Bruhin <git@the-compiler.org>
Date:   Wed Nov 19 22:23:04 2014 +0100

    adblock: Add error handling for invalid input.

commit 5934c3c027ff9205adb512aab396ca913b31e50d
Author: Florian Bruhin <git@the-compiler.org>
Date:   Wed Nov 19 22:22:47 2014 +0100

    adblock: Handle done_count correctly.

commit 3ba5e83fda9b7d764bfcf1e4b1aa479daae39791
Author: Florian Bruhin <git@the-compiler.org>
Date:   Wed Nov 19 21:18:10 2014 +0100

    Read adblock files when they finished downloading.

commit 86a5ecf194445e2ebe0cf22b59e24223387880c5
Author: Florian Bruhin <git@the-compiler.org>
Date:   Wed Nov 19 20:51:25 2014 +0100

    Add hosts-file.net to host-block-lists.

commit 121f0bff953497449c32e45e671b71d954beed4c
Author: Florian Bruhin <git@the-compiler.org>
Date:   Wed Nov 19 20:51:13 2014 +0100

    Add zip-file support to adblock.py.

commit f1c0e67cb9d890a44a1d1f545ace997f0a453f91
Author: Florian Bruhin <git@the-compiler.org>
Date:   Mon Nov 17 07:41:14 2014 +0100

    print line counts for debugging

commit 75dbb8964fd44862abc378ef26fb47f8cda6061e
Author: Florian Bruhin <git@the-compiler.org>
Date:   Fri Nov 14 19:22:20 2014 +0100

    Use statusbar messages for adblock

commit 74d9142d831496e02c5baae72c2723e320af1778
Author: Florian Bruhin <git@the-compiler.org>
Date:   Fri Nov 14 08:34:46 2014 +0100

    Add basic adblock functionality.
2014-11-24 21:05:09 +01:00
Florian Bruhin
f7fbf98667 downloads: Rewind file objects correctly on redirects. 2014-11-24 21:04:48 +01:00
Florian Bruhin
9333e92891 Remove download assertions. 2014-11-24 06:55:54 +01:00
Florian Bruhin
6856c49be9 Handle HTTP redirections in downloads. 2014-11-24 00:12:52 +01:00
Florian Bruhin
0a1bdd79da Split some functions into smaller ones. 2014-11-23 21:26:59 +01:00
Florian Bruhin
655115858c Handle OSError when using subprocess. 2014-11-23 18:07:05 +01:00
Florian Bruhin
8ec42908f1 Add a new option tabs->tabs-are-windows. 2014-11-21 06:22:52 +01:00
Florian Bruhin
615be2a4bc Update docs. 2014-11-20 06:36:08 +01:00
Florian Bruhin
9c180fd91b Add a dest-parameter to :download. 2014-11-20 06:24:15 +01:00
Florian Bruhin
7b1ea3ff40 Typo: s/similiar/similar/g 2014-11-19 22:46:52 +01:00
Florian Bruhin
2fe72d8087 Simplify utils.log.
The overcomplicated parsing with re didn't really give us much benefits, and
lead to exceptions and segfaults[1] (?) already, so it's best to just get rid
of it entirely.

[1] http://paste.the-compiler.org/view/26768694
2014-11-19 22:43:49 +01:00
Florian Bruhin
336bbc370e Ignore 'content-type missing' Qt warning. 2014-11-19 22:38:56 +01:00
Florian Bruhin
283cedff15 Never get downloads from the cache.
This is a workaround for corrupted files because Qt somehow reads them from the
cache wrongly. See https://bugreports.qt-project.org/browse/QTBUG-42757

This might fix a part of #78 - but we'll leave this open for now, since it
might also be another issue.
2014-11-19 19:43:07 +01:00
Florian Bruhin
b8b31fd914 downloads: default autoclose=True. Fixes #265. 2014-11-18 20:10:57 +01:00
Florian Bruhin
2a95533564 Add some assertions for 'successful'. 2014-11-18 19:56:57 +01:00
Florian Bruhin
b1d6e70c8b Check URL validity in :download. 2014-11-18 19:49:55 +01:00
Florian Bruhin
75d1f072c2 Add a raise_cmdexc_if_invalid to urlutils. 2014-11-18 19:49:31 +01:00
Florian Bruhin
41c3a59e81 Add a :download command. 2014-11-18 19:38:34 +01:00
Florian Bruhin
8c5bc67dd0 Recalculate geometry if data changed. 2014-11-18 07:47:28 +01:00
Florian Bruhin
40918bfc98 Use _die on QNetworkReply errors. 2014-11-18 07:47:28 +01:00
Florian Bruhin
406f7b3b84 Don't try to set fileobject on errors. 2014-11-18 07:47:28 +01:00
Florian Bruhin
c6deae36b1 Fix setting of successful flag. 2014-11-18 07:47:28 +01:00
Florian Bruhin
829b8df535 downloads: Return the created DownloadItem. 2014-11-18 07:47:28 +01:00
Florian Bruhin
6301c740d1 downloads: Add a generic NetworkManager. 2014-11-18 07:47:28 +01:00
Florian Bruhin
c8a1c979e8 downloads: Whitespace change. 2014-11-18 07:47:28 +01:00
Florian Bruhin
d31e8edffc downloads: Document _win_id. 2014-11-18 07:47:28 +01:00
Florian Bruhin
da49424836 downloads: Make it possible to set fileobj instead of name. 2014-11-18 07:47:28 +01:00
Florian Bruhin
5ad516a438 DownloadItem: Make fileobj public. 2014-11-18 07:47:28 +01:00
Florian Bruhin
f250cd41ad DownloadItem: Add an autoclose attribute. 2014-11-18 07:47:28 +01:00
Florian Bruhin
ab0dba3344 DownloadItem: add successful attribute. 2014-11-18 07:47:28 +01:00
Florian Bruhin
b0c8ca9e1a Escape regex correctly. 2014-11-18 07:34:50 +01:00
Florian Bruhin
cf1728de43 configtypes: Add more tests for List/UrlList. 2014-11-18 07:14:06 +01:00
Florian Bruhin
c29ae9e1d3 configtypes: Add new UrlList type. 2014-11-18 07:14:06 +01:00
Florian Bruhin
142e90cdd3 Move special network replies to their own file. 2014-11-18 07:14:06 +01:00
Florian Bruhin
c4da44e90c configtypes: Handle none_ok differently for List. 2014-11-18 07:14:06 +01:00
Florian Bruhin
2514e66028 Don't call processEvents in NetworkManager.
This caused the segfaults and memory corruption issues mentioned in #256.
2014-11-18 07:14:06 +01:00
Florian Bruhin
3622f35865 Hide 'load glyph failed' Qt warning. 2014-11-16 16:25:37 +01:00
Florian Bruhin
ecbebba9e9 hints: Ignore TypeError when disconnecting contentsSizeChanged.
Fixes #263.
2014-11-16 00:05:20 +01:00
Florian Bruhin
15ce2746eb Remove unneeded 'except RuntimeError' 2014-11-14 19:33:26 +01:00
Florian Bruhin
794df11b01 Add spacing to DownloadView. 2014-11-14 19:33:18 +01:00
Florian Bruhin
3f6a40aac9 Update cache size if storage->cache-size is changed. 2014-11-14 19:02:22 +01:00
Florian Bruhin
9bf776aee1 Fix TypeError when closing tabs with older PyQt-versions.
Fixes #257.

It seems disconnecting a signal from a destroyed object gives us a
"TypeError: pyqtSignal must be bound to a QObject, not 'WebView'" instead of a
RuntimeError with older PyQt-versions (5.2.1).
2014-11-14 18:55:48 +01:00
Florian Bruhin
4925a3f36e Ignore new statusbar questions when we're shutting down.
Fixes #95.
2014-11-12 23:28:03 +01:00
Florian Bruhin
ac7b17be3a Describe _busy attribute for prompter. 2014-11-12 23:26:43 +01:00
Florian Bruhin
a10801ef21 Don't get prompter widget when restoring None context.
This basically did hide #95.
2014-11-12 20:53:47 +01:00
Florian Bruhin
812b100205 Invert background-tabs setting when Shift is pressed.
Closes #175.
2014-11-12 20:37:44 +01:00
Florian Bruhin
4c8ecbb40d Fix disconnecting from objreg for deleted objects. 2014-11-12 20:22:49 +01:00
Florian Bruhin
2419071b0f Disconnect destroyed signal of objects deleted in objreg.
Fixes #205.
2014-11-12 20:19:26 +01:00
Florian Bruhin
69803f5f87 Don't log exception during exception handling twice. 2014-11-12 20:18:36 +01:00
Florian Bruhin
e23360bb88 Don't open a new window if only commands are sent via IPC.
Fixes #237.
2014-11-11 22:42:45 +01:00
Florian Bruhin
d30ec95f72 Open new window if no existing window is found on IPC. 2014-11-11 22:29:44 +01:00
Florian Bruhin
ddb52b1e17 Leave insert mode when tab is changed. 2014-11-11 21:42:53 +01:00
Florian Bruhin
b70c3754e8 downloads: Check if reply is open when doing delayed write.
This fixes a "QIODevice::read: device not open" warning when closing the window
while a download is active.
2014-11-11 21:40:25 +01:00
Florian Bruhin
b502280c06 Make download-manager a per-window object.
Fixes #228.
2014-11-11 21:36:47 +01:00
Florian Bruhin
5fa1556588 Fix getting last main window when it was closed.
Fixes #242.
2014-11-10 23:21:31 +01:00
Florian Bruhin
2278d30187 Work around pylint bug in tests.
See:
https://bitbucket.org/logilab/astroid/issue/36/attributeerror-starred-object-has-no
2014-11-10 23:02:38 +01:00
Florian Bruhin
6310081ef5 Clean up simple_split. 2014-11-10 23:02:34 +01:00
Florian Bruhin
c70f6f534b Get rid of dotted_getattr. 2014-11-10 18:59:13 +01:00
Florian Bruhin
eaca891616 Log uncaught exceptions to debug log 2014-11-10 18:34:31 +01:00
Florian Bruhin
57212c8438 Fix "Exception ignored in:" warnings.
Fixes #245.
2014-11-10 18:00:44 +01:00
Florian Bruhin
398da22b54 Fix splitting with split=False and maxsplit=0.
Since re.split behaves differently from str.split with maxsplit=0,
4e9b9baeab broke things like ":open foo bar".
2014-11-10 10:38:19 +01:00
Florian Bruhin
96c72724ce Handle whitespace correctly when splitting with flags.
Fixes #248.
2014-11-10 08:14:45 +01:00
Florian Bruhin
1b46c96192 Fix completion when deleting command 2014-11-10 07:59:39 +01:00
Florian Bruhin
d71147898b Move completion logic from statusbar widget to completer.
Fixes #247.
2014-11-10 07:49:22 +01:00
Florian Bruhin
5e7ef5201c Move statusbar-cmd registering. 2014-11-10 07:05:57 +01:00
Florian Bruhin
10059ce70f Remove unneeded _get_object call. 2014-11-10 07:05:24 +01:00
Florian Bruhin
404e425a9e Clean up faulthandler import 2014-11-09 22:59:14 +01:00
Florian Bruhin
5f9c56bcdd Fix exception when logging Qt warning without function. 2014-11-09 22:57:39 +01:00
Florian Bruhin
bc009ae624 Fix lint in split.py 2014-11-09 22:15:44 +01:00
Florian Bruhin
326ce91eb7 Append hint elements inside body.
Fixes #226.
2014-11-09 22:02:08 +01:00
Florian Bruhin
40be804ee6 Don't handle "foo: bar" as URL.
Fixes #227.
2014-11-09 21:54:15 +01:00
Florian Bruhin
bf752f6ea4 Update pyPEG2 install instructions.
Fixes #243.
2014-11-09 21:48:33 +01:00
Florian Bruhin
b7c1f32922 Strip pattern when completing. 2014-11-09 20:47:39 +01:00
Florian Bruhin
f8dc2a9fb4 Add additional split test with flags. 2014-11-09 20:47:27 +01:00
Florian Bruhin
4e9b9baeab Split commands with split=False correctly.
Fixes #231.
2014-11-09 20:46:21 +01:00
Florian Bruhin
a86279df5e Set cursor part correctly if the cursor is at the end. 2014-11-09 20:45:47 +01:00
Florian Bruhin
f689c89316 Merge branch 'shlex'
Fixes #122.
Fixes #232.
2014-11-09 18:25:51 +01:00
Florian Bruhin
61943b5a77 Fix completion 2014-11-09 18:12:36 +01:00
Florian Bruhin
31ee458e56 Hide _GTK_LOAD_ICONTHEMES Qt error 2014-11-08 20:03:33 +01:00
Florian Bruhin
2b8d6c5dd7 Use a for loop 2014-11-06 09:02:21 +01:00
Florian Bruhin
5fe04a6aec Make completion work more or less 2014-11-06 08:26:01 +01:00
Florian Bruhin
ac61422059 Fix splitting of whitespace at EOL 2014-11-06 08:25:46 +01:00
Florian Bruhin
d730471fd7 Start using keep=True for commandline. 2014-11-06 07:15:02 +01:00
Florian Bruhin
76b72d3438 Try splitting with whitespace at next token. 2014-11-06 07:14:36 +01:00
Florian Bruhin
ca1ca7db36 shlexer cleanup 2014-11-06 07:13:58 +01:00
Florian Bruhin
77949c8d33 Get rid of continue 2014-11-06 06:46:21 +01:00
Florian Bruhin
cb24ec58cc Use yield 2014-11-06 06:44:23 +01:00
Florian Bruhin
9591e86054 cleanup state=None 2014-11-05 23:48:57 +01:00
Florian Bruhin
e6f4ac9b99 cleanup 2014-11-05 23:47:48 +01:00
Florian Bruhin
807e0944b6 Fix broken test case 2014-11-05 21:49:15 +01:00
Florian Bruhin
40a1c4a2d9 Remove newline test 2014-11-05 21:44:52 +01:00
Florian Bruhin
1d9b60d733 Fix some tests 2014-11-05 21:42:27 +01:00
Florian Bruhin
714ba530d3 Add tests for keep=True 2014-11-05 07:58:28 +01:00
Florian Bruhin
e68c28ebfc Adjust test case formatting 2014-11-05 07:46:28 +01:00
Florian Bruhin
ac355b1c7c Use vdebug level. 2014-11-05 07:42:21 +01:00
Florian Bruhin
22da17bbca Add a keep-mode to shlexer. 2014-11-05 07:41:17 +01:00
Florian Bruhin
9ed466b536 Add python shlex tests 2014-11-04 21:08:26 +01:00
Florian Bruhin
c308de95d1 Clean up tests 2014-11-04 21:06:50 +01:00
Florian Bruhin
82e95d82d1 cleanup 2014-11-04 21:06:43 +01:00
Florian Bruhin
84916448a9 Use iterator to read chars 2014-11-04 20:41:29 +01:00
Florian Bruhin
409eba76ca Handle safe parsing directly in ShellLexer 2014-11-04 20:24:42 +01:00
Florian Bruhin
95f7940996 Get rid of _get_lexer. 2014-11-04 20:13:38 +01:00
Florian Bruhin
430ef5c935 Whitespace cleanup 2014-11-04 20:13:31 +01:00
Florian Bruhin
89a2057cac Simplify eof handling 2014-11-04 20:09:45 +01:00
Florian Bruhin
cfafc2e235 Get rid of get_token 2014-11-04 20:08:14 +01:00
Florian Bruhin
9a5df13639 Use logging for debug 2014-11-04 20:06:58 +01:00
Florian Bruhin
cb76a100c2 Assume whitespace_split=True, get rid of wordchars/pushback 2014-11-03 21:48:10 +01:00
Florian Bruhin
9180a8b0bb shlex: Some lint cleanup 2014-11-03 21:43:34 +01:00
Florian Bruhin
b8d9f3b041 shlex: Remove lineno/commenters 2014-11-03 21:37:36 +01:00
Florian Bruhin
861705f655 shlex: Assume posix=True 2014-11-03 21:35:47 +01:00
Florian Bruhin
cab18c248c shlex: Remove unneeded stuff 2014-11-03 21:30:39 +01:00
Florian Bruhin
3fa8efc34b Initial shlex fork 2014-11-03 21:27:07 +01:00
Florian Bruhin
45bdf166f8 Add vdebug logging for getting completion part.
See #232.
2014-11-03 19:35:09 +01:00
Florian Bruhin
ef96cd9d02 Add workaround for hang on messages during QNAM init.
See http://www.riverbankcomputing.com/pipermail/pyqt/2014-November/035045.html
2014-11-02 22:03:13 +01:00
Florian Bruhin
f705194c00 Fix an exception related to handling IPC connections.
See http://paste.the-compiler.org/view/77f58b69
2014-11-02 21:53:12 +01:00
Florian Bruhin
8e713abadf Add some logging for #232 2014-11-02 20:30:00 +01:00
Florian Bruhin
c3a83bc412 Add hover description to docstring (#238) 2014-11-02 20:08:40 +01:00
Florian Bruhin
7b670b134d Small whitespace fix for #238 2014-11-02 20:04:41 +01:00
Florian Bruhin
07357a81e9 Merge branch 'master' of https://github.com/rikn00/qutebrowser into rikn00-master 2014-11-02 20:00:33 +01:00
rikn00
33b6e17772 Remove unneeded change to ClickTarget 2014-11-02 20:49:18 +02:00
Florian Bruhin
e911a2bd6d Fix lint 2014-11-02 19:16:13 +01:00
Florian Bruhin
6ede565ffd Merge branch 'new-crash-dialog'
Closes #56.
2014-11-02 19:09:57 +01:00
Florian Bruhin
2cb383a7d0 Handle URLs opened via QDesktopServices. 2014-11-02 19:09:36 +01:00
Florian Bruhin
adfd1e5b9d Add text about stacktrace.asciidoc in crash dialog.
Closes #140.
2014-11-02 19:06:43 +01:00
rikn00
4d101eea59 Improve hovering a hint 2014-11-02 16:37:34 +02:00
rikn00
84759a4928 Add support to hover mouse over a hint 2014-11-01 01:54:19 +02:00
Florian Bruhin
6e4759b65a Better paste metainfo 2014-10-31 07:57:50 +01:00
Florian Bruhin
1c32e72e37 Hide crash dialog before reporting.
This makes it feel snappier.
2014-10-31 07:36:35 +01:00
Florian Bruhin
589187ee6b Set some properties. 2014-10-31 07:13:32 +01:00
Florian Bruhin
a2809e76bb Handle --debug specially 2014-10-31 07:06:28 +01:00
Florian Bruhin
da0f433260 Start new crash dialog 2014-10-31 06:53:55 +01:00
Florian Bruhin
904d84db7e Set split=False for :quickmark-load.
See #231.

The completion still hides on the space and reappears on the first letter of
the second word, but it's a start.
2014-10-29 22:55:03 +01:00
Florian Bruhin
8e0e33e89a Use QWebElement API to set hint elem style.
See #225.
2014-10-29 22:50:29 +01:00
Florian Bruhin
2937fb9232 Use QWebElement API to set hint elem attributes.
Fixes #225.
2014-10-29 21:01:32 +01:00
Florian Bruhin
a1ba05ff08 Add some logging for #152 2014-10-29 07:09:43 +01:00
Florian Bruhin
0c8b9fe095 Add vdebug logging for hints.
This hopefully helps with #225.
2014-10-28 19:00:41 +01:00
Florian Bruhin
eb5527f897 Add some logging about keyboard focus.
This should help with debugging #218 if it occurs again.
2014-10-28 07:44:42 +01:00
Florian Bruhin
8d22d558e2 Fix tab closing with tabs->last-close = blank.
Fixes #220.
2014-10-27 20:46:35 +01:00
Florian Bruhin
afaba7bfdc Update tab fg colors when config changed.
Fixes #217.
2014-10-27 07:47:28 +01:00
rikn00
1245e08d7a More options to colorize tab foreground 2014-10-26 23:56:00 +02:00
Florian Bruhin
e639cdb117 Remove unused imports. 2014-10-26 22:08:59 +01:00
Florian Bruhin
2269d9a64b Split getting of completion model into multiple functions. 2014-10-26 22:08:36 +01:00
Florian Bruhin
0f550f696c Clean up Command. 2014-10-26 22:08:13 +01:00
Florian Bruhin
ae2284f4aa Fix multiple file QWebPage extension.
We accidentally broke that in 4c78b611eb.
2014-10-26 22:07:15 +01:00
Florian Bruhin
2d9425a0b7 Fix uppercase hint formatting. 2014-10-26 17:05:56 +01:00
Florian Bruhin
ef9e31c2d9 Merge branch 'master' of https://github.com/peterlvilim/qutebrowser into uppercase-hint 2014-10-26 19:50:54 +01:00
Peter Vilim
ee875ba895 hints: Show uppercase hint chars #73 2014-10-26 03:04:48 -05:00
Florian Bruhin
4c78b611eb Clean up QWebPage::extension handling. 2014-10-25 23:59:09 +02:00
Florian Bruhin
c79c1f950a Open unknown protocols with external viewer.
Closes #210.
2014-10-25 23:51:22 +02:00
Florian Bruhin
c2daadf0bd Fix exception when element has no web frame. 2014-10-22 20:18:58 +02:00
Florian Bruhin
6f3fde4450 Don't trigger completion update twice.
Fixes #206.
2014-10-21 16:45:04 +02:00
Florian Bruhin
7eba55459b Fix completion with flags.
Fixes #203.
2014-10-20 20:39:25 +02:00
Florian Bruhin
0b37ad4348 Don't pass unknown dict keys to argparse in function annotations. 2014-10-20 20:27:33 +02:00
Florian Bruhin
c7f6a747a8 Check flag length in function annotations. 2014-10-20 20:27:19 +02:00
Florian Bruhin
fd6e56d7af Convert all function annotations to dicts. 2014-10-20 17:20:39 +02:00
Florian Bruhin
a6f1bf29ae Revert "Remove unneeded invalidateFilter call."
This reverts commit b5781f0ed3.

For some reason this did break the "completion->shrink" setting.

Closes #204.
Makes #190 a bit worse again though.

Conflicts:
	qutebrowser/models/completionfilter.py
2014-10-20 12:01:48 +02:00
Florian Bruhin
0a5cee6ea2 Simplify text marking in completion.
Also improves performance, see #190.
2014-10-20 07:43:07 +02:00
Florian Bruhin
1917911dd8 Don't set marks data if the pattern is empty.
See #190.
2014-10-20 07:13:29 +02:00
Florian Bruhin
b5781f0ed3 Remove unneeded invalidateFilter call.
See #190.
2014-10-20 06:38:21 +02:00
Florian Bruhin
013a9ff216 Don't update completion twice when setting cmd text.
See #190.
2014-10-20 06:17:20 +02:00
Florian Bruhin
9f242cb907 Fix lint 2014-10-20 00:33:52 +02:00
Florian Bruhin
596c33fe1c Merge branch 'quickmark-completion' 2014-10-20 00:29:46 +02:00
Florian Bruhin
eb7d12445b Fix indent 2014-10-20 00:29:19 +02:00
Florian Bruhin
1b91cd61cd Fix long line 2014-10-20 00:28:14 +02:00
Florian Bruhin
4ae4d0c74b Simplify getting of quickmarks 2014-10-20 00:27:45 +02:00
Florian Bruhin
1238807745 Whitespace fixes. 2014-10-20 00:25:12 +02:00
Florian Bruhin
8e9836785f Remove unused import. 2014-10-20 00:25:10 +02:00
Claude
14d8d01d92 raising value error 2014-10-19 23:04:32 +02:00
Florian Bruhin
8dffceeb2a completion: Match case-insensitively. 2014-10-19 23:04:26 +02:00
Claude
ed51367bdd selfish parameters 2014-10-19 23:01:06 +02:00
Claude
ecbe5c071d match urls with open, names with quickmark-load 2014-10-19 22:25:21 +02:00
Florian Bruhin
e3e1382ccd Add missing faulthandler import. 2014-10-19 18:19:36 +02:00
Florian Bruhin
499f0767da Revert "Never delete crash log file."
This reverts commit dcad41c92e.

Shutdown segfaults still happen too often, and the crash log doesn't tell us
anything useful...
2014-10-18 23:46:24 +02:00
Claude
572a9857ec fixes 2014-10-18 22:00:28 +02:00
Florian Bruhin
f2dcb8f002 Don't update stylesheets of deleted objects.
Fixes #156.
2014-10-18 19:53:22 +02:00
Florian Bruhin
76de3d0c51 Use signals and decorators for configs again.
This basically rolls back 64a119afb2 and
b7f2a6d143.

Fixes #188.
Breaks #156 again but the next commit will fix this.
2014-10-18 19:50:10 +02:00
Claude
afe45f9970 puschschsch 2014-10-18 16:42:06 +02:00
Claude
36328a01a4 updating code
according to https://github.com/The-Compiler/qutebrowser/pull/189#issuecomment-59220531
2014-10-17 21:39:28 +02:00
Claude
9613cc0eab Merge remote-tracking branch 'florian/master' into quickmark-completion 2014-10-17 20:46:00 +02:00
Florian Bruhin
bff0efb4a4 Paste primary selection on Shift+Insert 2014-10-17 15:01:08 +02:00
Florian Bruhin
5a5ff70703 hints: fix replacing of {hint-url}.
Fixes #200.
2014-10-17 11:39:44 +02:00
Florian Bruhin
ee02f339d7 Draw hints correctly when page is zoomed.
Fixes #199.
2014-10-17 11:32:41 +02:00
Florian Bruhin
999474c751 Set title directly instead of using signals.
See #198, but this didn't fix it.
2014-10-15 23:25:21 +02:00
Florian Bruhin
b4c7669e64 Shut down TabbedBrowser in MainWindow closeEvent.
Hopefully fixes #197.
2014-10-15 23:15:27 +02:00
Florian Bruhin
0209382df4 Fix redrawing of downloadview if there are downloads added. 2014-10-15 21:30:04 +02:00
Florian Bruhin
7e820a0e82 Show error messages in downloads. 2014-10-15 21:22:53 +02:00
Florian Bruhin
dc8f156c21 Make srcmodel public in CompletionFilterModel. 2014-10-15 20:43:20 +02:00
Florian Bruhin
b54151f206 Use last focused window for download errors and other stuff.
When the event happens, it's possible we don't have any window focused yet, so
we display it in the window which was last focused.

Fixes #191.
2014-10-15 20:42:40 +02:00
Florian Bruhin
348bc7147f Don't clear page in WebView:shutdown. Fixes #99.
It seems Qt still wants to access the page (for the mousePressEvent) and
segfaults when we clear the page before that's finished.

We now try it inside __del__ like done in the link mentioned in the comment.
2014-10-15 18:03:48 +02:00
Florian Bruhin
74839d7aff Use a QObject for quickmarks and add a changed signal.
See #189.
2014-10-15 16:55:55 +02:00
Florian Bruhin
e8fa8fadce Fix completion tabbing.
I accidentally broke this in fb3682f5fa because
the variable gets reset before the slot is executed now.

See #189.
2014-10-15 13:00:56 +02:00
Claude
37023fe896 Improved qmarks model filling
thx to the fix from The-Compiler!
2014-10-15 12:16:05 +02:00
Claude
621388e5e0 init quickmark completion in init_static 2014-10-15 12:08:37 +02:00
Claude
f4c7c1d5a0 der Sensemann 2014-10-15 12:04:37 +02:00
Claude
167e01160c minor copy paste fails 2014-10-15 11:59:01 +02:00
Claude
777e93bd3f quickmarks completion
It works, but:
* terrible performance (5s for ~1600 marks)
* split and join operations in the loop - i want direct access to name +
  url in the marks dict! how?
2014-10-15 11:54:10 +02:00
Florian Bruhin
da0d81e700 Remove warning about crash log.
This was a leftover from dcad41c92e
2014-10-15 07:34:13 +02:00
Florian Bruhin
fb3682f5fa Load completion with a singleShot QTimer.
It still slows stuff down while typing, but at least it's a lot more responsive
for the initial load.

See #189.
2014-10-15 07:15:59 +02:00
Florian Bruhin
a8808aa3d4 Keep a reference to completion source model.
For some reason calling sourceModel() takes quite some time, which accounts for
about 1-2s of delay when showing the completion.

This matters for #189 for example.
2014-10-15 07:06:39 +02:00
Florian Bruhin
7cebc94b31 Merge branch 'master' of https://github.com/claudehohl/qutebrowser into claudehohl-master 2014-10-15 06:13:25 +02:00
Florian Bruhin
818d2cb9d3 Split quickmarks correctly (from the right).
This was discovered in #189.
2014-10-14 23:29:24 +02:00
Florian Bruhin
9c3650296c Add a simple wrapper around Qt's app.exec_().
This improves faulthandler tracebacks.
2014-10-14 21:25:21 +02:00
Florian Bruhin
fed1566370 Remove cookies when permissions->cookies-store was changed.
Fixes #116.
2014-10-14 21:24:09 +02:00
Florian Bruhin
1c6578d409 Save lineparser even if there is no data. 2014-10-14 21:23:46 +02:00
Florian Bruhin
7a1dfebc6a Remove unused faulthandler import. 2014-10-14 21:23:07 +02:00
Florian Bruhin
dcad41c92e Never delete crash log file.
We also want to log to the crash log when segfaults happen during exit.
2014-10-14 20:48:21 +02:00
Florian Bruhin
cf6d303ad1 Improve crash log handling because of single-instance. 2014-10-14 20:47:06 +02:00
Florian Bruhin
bfcb309460 Clear favicon correctly when loading a new page.
This was accidentally deleted in e608ccbe36
Fixes #187.
2014-10-14 18:54:28 +02:00
Florian Bruhin
1c551975c4 Check if currentWidget is None in tabbed_browser.on_mode_left.
Fixes #186.
2014-10-14 17:50:50 +02:00
Florian Bruhin
f9eec48414 Set urgent hint when opening IPC tab - closes #185 2014-10-14 11:51:17 +02:00
Florian Bruhin
cfc5e80d3e ipc: Fix opening of new empty window. 2014-10-14 10:10:24 +02:00
Florian Bruhin
2e2070ef6e Rename ipc-open-target to new-instance-open-target. 2014-10-14 09:59:01 +02:00
Florian Bruhin
f8d8e1507a Fix tests on windows 2014-10-14 08:18:06 +02:00
Florian Bruhin
bda3c9b1d0 Refactor Command._inspect_function. 2014-10-14 07:59:42 +02:00
Florian Bruhin
ef8873040a Add docstrings to signal debugging. 2014-10-14 07:59:07 +02:00
Florian Bruhin
bcf8040041 Whitespace fixes. 2014-10-14 07:58:50 +02:00
Florian Bruhin
7c0a23b1b7 Fix IPC when there's no main window available. 2014-10-14 07:58:16 +02:00
Florian Bruhin
0e9177eb4f Rename ipc param to process_args to via_ipc.
This prevents shadowing of the module.
2014-10-14 07:57:42 +02:00
Florian Bruhin
817259f4f5 Add ipc-open-target config option. 2014-10-14 07:37:12 +02:00
Florian Bruhin
ca85dde71f Merge branch 'ipc' 2014-10-13 23:19:04 +02:00
Florian Bruhin
191b1dd240 Open new window for IPC args. 2014-10-13 23:14:24 +02:00
Florian Bruhin
19be96b4a8 Better invalid data logging 2014-10-13 22:51:11 +02:00
Florian Bruhin
f9c2eb836f Adjust docstring 2014-10-13 22:48:37 +02:00
Florian Bruhin
6b07fd969a Add timeout to IPC server. 2014-10-13 22:47:32 +02:00
Florian Bruhin
4617aee317 Log all socket errors 2014-10-13 22:38:40 +02:00
Florian Bruhin
103ba3b8b0 Don't log PeerDisconnectedError. 2014-10-13 22:36:05 +02:00
Florian Bruhin
bdb7cc96b4 Handle multiple connections properly #2. 2014-10-13 22:35:10 +02:00
Florian Bruhin
de41dee0b5 Add ipc logging 2014-10-13 21:38:28 +02:00
Florian Bruhin
879cdf8904 Ignore invalid UTF-8 data. 2014-10-13 21:17:49 +02:00
Florian Bruhin
7d492d7556 Ignore invalid json data. 2014-10-13 21:16:38 +02:00
Florian Bruhin
c42fc53980 Handle multiple connections properly. 2014-10-13 21:12:15 +02:00
Florian Bruhin
9e2e684124 Whitespace 2014-10-13 20:38:40 +02:00
Florian Bruhin
795a6937ac Add missing @pyqtSlot decorators. 2014-10-13 20:37:09 +02:00
Florian Bruhin
5bc4f85dc5 Fix QLocalServer error checking. 2014-10-13 20:37:00 +02:00
Florian Bruhin
a849901693 Shut down IPC cleanly on exit. 2014-10-13 20:36:23 +02:00
Florian Bruhin
6dc0bfa2d2 Convert IPCServer to a class and handle connections async. 2014-10-13 20:11:13 +02:00
Florian Bruhin
46b15a1f11 userscripts: Remove invalid encoding param to os.open.
Fixes #182.

This was a regression introduced in 17dd4732ae.
2014-10-13 15:09:23 +02:00
Florian Bruhin
a3ee504c59 Add docstrings. 2014-10-13 07:59:03 +02:00
Florian Bruhin
93dd3d8d9d Fix check for QLocalSocket.UnknownSocketError 2014-10-13 07:49:26 +02:00
Florian Bruhin
8195f1875e Ignore QLocalSocket.ServerNotFoundError while connecting. 2014-10-13 07:49:01 +02:00
Florian Bruhin
2f0bbab635 Better IPC exceptions 2014-10-13 07:47:05 +02:00
Florian Bruhin
d861645d37 Remove wrong 'self' argument. 2014-10-13 07:43:22 +02:00
Florian Bruhin
5fc3332b6b Check errors correctly when connecting to socket. 2014-10-13 07:43:12 +02:00
Florian Bruhin
94b9bd42af Add missing "return True" when connected. 2014-10-13 07:42:15 +02:00
Florian Bruhin
476dd09534 Actually start IPC server. 2014-10-13 07:42:06 +02:00
Florian Bruhin
f759106a14 Error handling when writing to running instance. 2014-10-13 07:34:15 +02:00
Florian Bruhin
451a8be748 Small cleanup. 2014-10-13 07:31:56 +02:00
Florian Bruhin
4958da9c70 Error checking on connection. 2014-10-13 07:31:48 +02:00
Florian Bruhin
869fd4f752 Add an IPCError exception. 2014-10-13 07:11:45 +02:00
Florian Bruhin
ae61ca8af9 whitespace 2014-10-13 07:09:25 +02:00
Florian Bruhin
e351217740 Wait until socket bytes are written. 2014-10-13 07:09:16 +02:00
Florian Bruhin
fdb24ff597 Move IPC to its own file. 2014-10-13 07:06:57 +02:00
Claude
111f7b6e60 fixed a typo 2014-10-12 01:16:28 +02:00
Florian Bruhin
27fe73e1b8 Add debug function to log signals. 2014-10-11 11:40:15 +02:00
Florian Bruhin
86bb1f9890 Remove local server before connecting. 2014-10-11 11:39:02 +02:00
Florian Bruhin
1238f28833 Use a variable for socketname. 2014-10-11 11:38:03 +02:00
Florian Bruhin
f231f8815b QLocalsocket foo 2014-10-10 13:16:22 +02:00
Florian Bruhin
1761d98c1b Fix lint 2014-10-10 07:50:50 +02:00
Florian Bruhin
b42d701b0c debug-console: Only create when needed 2014-10-10 07:45:44 +02:00
Florian Bruhin
637ceb9bdd debug-console: Make objreg available by default. 2014-10-10 07:42:57 +02:00
Florian Bruhin
d9ffec7183 whitespace 2014-10-10 07:41:51 +02:00
Florian Bruhin
4edd2f7079 debug-console: Log completions. 2014-10-10 07:41:15 +02:00
Florian Bruhin
9dc72b4c37 debug-console: Use a sorted set for completions. 2014-10-10 07:38:14 +02:00
Florian Bruhin
8017dae75d debug console: refactoring 2014-10-10 07:34:34 +02:00
Florian Bruhin
2280250c16 debug console: Move prompt to output 2014-10-10 06:45:24 +02:00
Florian Bruhin
d08af6b8d8 debug-console: First attempt at completion. 2014-10-09 22:15:14 +02:00
Florian Bruhin
c6ccb56208 Handle exceptions while crash dialog is shown correctly. Fixes #168. 2014-10-09 06:56:04 +02:00
Florian Bruhin
0e771db7f1 Use annotation instead of special argument names.
Explicit is better than implicit.

Fixes #161.
2014-10-09 06:33:24 +02:00
Florian Bruhin
33043f0f6c Fix lint 2014-10-08 22:20:38 +02:00
Florian Bruhin
d9213ecf17 Prevent double-entering hint mode. Fixes #160. 2014-10-08 22:19:24 +02:00
Florian Bruhin
cbdade6518 Fix saving geometry if mainwindow is closed on shutdown. Fixes #159. 2014-10-08 22:03:12 +02:00
Florian Bruhin
cb951643b6 debug-console: Clean up appending of text. 2014-10-08 21:58:32 +02:00
Florian Bruhin
26d016b219 debug-console: Move cursor to end before inserting text. Fixes #162. 2014-10-08 21:54:25 +02:00
Florian Bruhin
b238149e1e Fix closing tabs with invalid URLs. Fixes #163. 2014-10-08 21:23:03 +02:00
Florian Bruhin
ffdc176d9d Make :set-cmd-text work without valid URL. Fixes #165. 2014-10-08 21:18:26 +02:00
Florian Bruhin
b1ed3a1106 Add bugs to download workaround comment. 2014-10-08 21:12:21 +02:00
Florian Bruhin
71308b45ac Add utils.qualname. Closes #169. 2014-10-08 21:11:04 +02:00
Florian Bruhin
b5b240c3f6 Add a workaround for deleted DownloadsView. Fixes #167. 2014-10-08 20:29:29 +02:00
Florian Bruhin
61a836fec5 Merge DownloadModel into DownloadManager. 2014-10-08 20:18:44 +02:00
Florian Bruhin
fe1215c74d Clean up selection model properly in completion.
http://qt-project.org/doc/qt-5/qabstractitemview.html#setModel :

This function will create and set a new selection model, replacing any model
that was previously set with setSelectionModel(). However, the old selection
model will not be deleted as it may be shared between several views. We
recommend that you delete the old selection model if it is no longer required.
2014-10-08 17:36:59 +02:00
Florian Bruhin
de86a26473 Fix DownloadView __repr__ if model is None. Fixes #170. 2014-10-08 17:19:51 +02:00
Florian Bruhin
b7f2a6d143 Use weakref for config.on_change. Fixes #156. 2014-10-08 10:40:46 +02:00
Florian Bruhin
7956f2b8e2 Clean up :later timers correctly on exceptions. 2014-10-08 07:52:49 +02:00
Florian Bruhin
50f7067d6c Add a :repeat command. 2014-10-08 07:46:21 +02:00
Florian Bruhin
d32a0c30c6 command: Remove unneeded has_count check. 2014-10-08 07:40:53 +02:00
Florian Bruhin
1a00d6168c command: Check for handlers with count and no default. 2014-10-08 07:40:39 +02:00
Florian Bruhin
e2763da8d6 Remove checks if standard dirs exist from unittests. 2014-10-08 07:17:34 +02:00
Florian Bruhin
704df6f619 Fix docstring. 2014-10-08 07:16:27 +02:00
Florian Bruhin
04b5c0e781 Add CACHEDIR.TAG to cache. Closes #19. 2014-10-08 07:16:00 +02:00
Florian Bruhin
ef0c72a99e Create standard dirs correctly. Fixes #20. 2014-10-08 07:11:25 +02:00
Florian Bruhin
b49b227c0d Add an init method for standarddir.
This is another preparation for #19 and #20.
2014-10-08 06:43:00 +02:00
Florian Bruhin
4abb5c8f36 Fix removing of eventfilter on shutdown if not present. 2014-10-08 06:38:03 +02:00
Florian Bruhin
f6695cac7d Small whitespace fix. 2014-10-08 06:22:20 +02:00
Florian Bruhin
0e7a60abf6 Move utils.get_standard_dir to its own file.
This is a preparation for #19 and #20 because there are too many functions
related to standarddir in utils.
2014-10-08 06:20:31 +02:00
Florian Bruhin
86f08a8536 Clean up overriding of javaScriptPrompt. 2014-10-08 05:20:56 +02:00
Florian Bruhin
596afab1ac Fix lint 2014-10-07 23:10:58 +02:00
Florian Bruhin
6349a6a213 Remove Emit:/Raise: from docstrings.
They got out-of-sync fast and provided no real benefit.
2014-10-07 23:08:37 +02:00
Florian Bruhin
f3ad1b71e6 Clean up objreg log text. This confused me in #159. 2014-10-07 22:21:51 +02:00
Florian Bruhin
4c29d1eafd Accept click focus in debug console. Fixes #142. 2014-10-07 21:42:45 +02:00
Florian Bruhin
a17017ca46 Add logging when closing window 2014-10-07 21:36:25 +02:00
Florian Bruhin
ab4a33f907 Remove per-window eventfilter. 2014-10-07 21:34:51 +02:00
Florian Bruhin
6202477db5 Add --left/--right arguments to :tab-only. Closes #46. 2014-10-07 20:56:47 +02:00
Florian Bruhin
4d092db114 Update outdated comment 2014-10-07 20:56:27 +02:00
Florian Bruhin
d8a917575d Add a cmdutils.check_exclusive function. 2014-10-07 20:39:02 +02:00
Florian Bruhin
8ca5c09e69 Add --left/--right/--opposite to :tab-close.
This fixes the updated version of #46.
2014-10-07 20:30:31 +02:00
Florian Bruhin
72a92c09dd Move config transforming of to Qt values to configtypes.
This is a preparation for #46.
2014-10-07 19:58:30 +02:00
Florian Bruhin
4092c48f92 Scroll debug console to bottom on output. Closes #158. 2014-10-07 18:01:20 +02:00
Florian Bruhin
6af33d0e85 Handle empty lines correctly in debug console. Fixes #157. 2014-10-07 17:56:39 +02:00
Florian Bruhin
12a72a4269 Revert "Disable line wrapping in debug console."
This reverts commit 179d108071.
2014-10-07 17:41:03 +02:00
Florian Bruhin
3e31e88921 Only close window (instead of quitting) when closing last tab.
This also renames the 'quit' value for tabs->last-close to 'close' to avoid
confusion.

Fixes #154.
2014-10-07 17:09:24 +02:00
Florian Bruhin
f9dc9f4acd Fix rapid hinting. Closes #148. 2014-10-07 07:45:29 +02:00
Florian Bruhin
068cc89458 Only start timer to process args if init was successful.
This fixes an exception when there is a config error (now displays normal error
box again).
2014-10-07 07:34:03 +02:00
Florian Bruhin
d2b3f89d78 Remove frame signal workaround for hints. See #152. 2014-10-07 07:15:14 +02:00
Florian Bruhin
f0990aec32 Fix loading of quickmarks with fuzzy URLs 2014-10-07 07:04:49 +02:00
Florian Bruhin
881e45d9eb Fix exception when saving quickmark (multiwin). 2014-10-07 07:02:29 +02:00
Florian Bruhin
1ad081a2db Fix lint 2014-10-06 22:30:37 +02:00
Florian Bruhin
ae44aa01a6 Set initial focused window correctly. 2014-10-06 22:29:18 +02:00
Florian Bruhin
dfc10a7d40 Revert "Fix opening of quickstart."
This reverts commit 202b5e2bb9.

window='current' really should work properly.
2014-10-06 22:24:29 +02:00
Florian Bruhin
12bbce2914 Spelling fix 2014-10-06 22:23:27 +02:00
Florian Bruhin
a19b6bf563 Fix :view-source 2014-10-06 22:23:12 +02:00
Florian Bruhin
15a2be877a Pass win_id correctly with invalid_url_error. 2014-10-06 22:22:59 +02:00
Florian Bruhin
202b5e2bb9 Fix opening of quickstart. 2014-10-06 22:16:52 +02:00
Florian Bruhin
572dc34c42 Fix url passed to url_invalid_error. 2014-10-06 22:15:35 +02:00
Florian Bruhin
08fdfebb50 Fix import of urlutils for url_invalid_error. 2014-10-06 22:15:26 +02:00
Florian Bruhin
fbb45953db Split parsing of initial args into three functions. 2014-10-06 22:15:11 +02:00
Florian Bruhin
dfb4e283e3 Remove unused import. 2014-10-06 22:14:57 +02:00
Florian Bruhin
105c25bc5f Merge branch 'multiwin'
Conflicts:
	qutebrowser/app.py
	qutebrowser/browser/commands.py
	qutebrowser/browser/hints.py
	qutebrowser/keyinput/modeman.py
	qutebrowser/network/networkmanager.py
	qutebrowser/widgets/mainwindow.py
	qutebrowser/widgets/statusbar/command.py
	qutebrowser/widgets/statusbar/prompt.py
	qutebrowser/widgets/statusbar/prompter.py
	qutebrowser/widgets/tabbedbrowser.py
2014-10-06 22:03:58 +02:00
Florian Bruhin
de37ed64ca Remove FIXME 2014-10-06 21:30:24 +02:00
Florian Bruhin
fd9a3fc5e7 Clean up mainwindow import mess. 2014-10-06 21:24:07 +02:00
Florian Bruhin
ecd31a6450 Add tab/window support to :help 2014-10-06 20:40:00 +02:00
Florian Bruhin
9281fa3992 Fix lint/bugs 2014-10-06 19:53:50 +02:00
Florian Bruhin
796dce86ae Remove go_back() and go_forward() from WebView.
If we use these in commands.py, we spawn a new window before checking if we can
go back/forward - but we want to check that before opening a new window.
2014-10-06 19:47:35 +02:00
Florian Bruhin
d2abd06513 Add missing keybindings for window actions. 2014-10-06 19:40:28 +02:00
Florian Bruhin
8eb0489357 Add rapid window hinting. 2014-10-06 19:39:48 +02:00
Florian Bruhin
52e72a8bec Fix window spawning with hints. 2014-10-06 18:47:55 +02:00
Florian Bruhin
6324751af6 More window support. 2014-10-06 17:58:40 +02:00
Florian Bruhin
2cd4642ece Pass window ID to scheme handlers. 2014-10-06 08:27:15 +02:00
Florian Bruhin
7e209dc285 Print tab registries in :debug-all-objects. 2014-10-06 07:41:34 +02:00
Florian Bruhin
d8cd599096 Fix wrong 'is' check. 2014-10-06 07:41:26 +02:00
Florian Bruhin
85ead4273b Register tab registry under window registry with ID. 2014-10-06 07:41:05 +02:00
Florian Bruhin
d3121034df Revert "Store window registries in objreg."
This reverts commit dfd3b3d9c4.

It turns out this makes it very hard to remove the window from the window
registry at the right time.
2014-10-05 23:09:35 +02:00
Florian Bruhin
180d6e45ef Fix closeEvent of MainWindow. 2014-10-05 23:09:04 +02:00
Florian Bruhin
d260b26105 Fix objreg._get_window_registry when non-mainwindow window is focused. 2014-10-05 22:41:44 +02:00
Florian Bruhin
dfd3b3d9c4 Store window registries in objreg. 2014-10-05 22:17:29 +02:00
Florian Bruhin
b6393a1841 Get rid of meta registry 2014-10-05 21:50:14 +02:00
Florian Bruhin
6dc997a971 Remove processEvent hack which doesn't help. See #147. 2014-10-05 21:29:01 +02:00
Florian Bruhin
0d2ce778f3 Ignore on_current_changed when last tab is closed. Fixes #146. 2014-10-05 19:47:12 +02:00
Florian Bruhin
4dcaa1fdec Be more forgiving when validating URLs. Fixes #141. 2014-10-03 16:58:30 +02:00
Florian Bruhin
18ff6ea06a Fix line breaking in debugging console. Fixes #144. 2014-10-03 12:37:32 +02:00
Florian Bruhin
179d108071 Disable line wrapping in debug console.
For some reason this does not fix #144.
2014-10-03 12:24:07 +02:00
Florian Bruhin
0a6a8b4b4a Don't parse HTML in debug console. Fixes #143. 2014-10-03 12:20:39 +02:00
Florian Bruhin
22b48ad248 Open quickstart page on first start.
Fixes #4.
2014-10-03 08:39:33 +02:00
Florian Bruhin
892b54e153 Fix saving of config. 2014-10-02 22:51:59 +02:00
Florian Bruhin
5eda621a7c Clean up KeyConfParser __init__ and make it work with None.
Fixes #137.
2014-10-02 22:49:58 +02:00
Florian Bruhin
ab5acdc3ad Clean up ConfigManager __init__ and make it work with None.
Fixes parts of #137.
2014-10-02 22:45:47 +02:00
Florian Bruhin
337574f40f Fix lint 2014-10-02 22:25:48 +02:00
Florian Bruhin
a8304d03ea Clean up get_standard_dir 2014-10-02 22:24:08 +02:00
Florian Bruhin
e74fa71a0a Seprate data/config dirs on Windows.
See #21.
2014-10-02 22:12:45 +02:00
Florian Bruhin
086de1b508 Rename cmd_history to cmd-history.
For consistency with the other stuff, why not.
Also we broke that file with the last commit anyways.
2014-10-02 22:12:24 +02:00
Florian Bruhin
d3c9bab01a Move state/cmd_history from config to data dir.
See #21.
2014-10-02 22:12:24 +02:00
Florian Bruhin
3a66937205 Clean up argument handling in get_standard_dir 2014-10-02 22:12:24 +02:00
Florian Bruhin
b20536d472 Move handling of --confdir into get_standard_dir 2014-10-02 21:54:42 +02:00
Florian Bruhin
e4e8d16ee8 Fix crash on error pages with URLs not encodable in latin1.
It seems PyQt does some implicit latin1 encoding when we set the content
attribute to a string rather than a bytes object.

Fixes #127.
2014-10-02 06:28:49 +02:00
Florian Bruhin
00949db2cf Add testcases for jinja.
This was an attempt to get a breaking test for #127 but it seems jinja isn't
actually the issue.
2014-10-02 06:22:06 +02:00
Florian Bruhin
c75563907a Fix getting URL in :view-source.
Fixes #128.
2014-10-02 06:06:08 +02:00
Florian Bruhin
d674b90240 Clean up FIXMEs and add github URLs 2014-10-01 22:23:27 +02:00
Florian Bruhin
2df276085c Process events before creating BrowserPage. 2014-09-30 08:07:45 +02:00
Florian Bruhin
85f8366028 Fix lint 2014-09-30 07:49:01 +02:00
Florian Bruhin
f5a4d3a184 Move show_prompt/hide_prompt signals from prompt to prompter. 2014-09-30 07:37:31 +02:00
Florian Bruhin
b958d07869 prompter: Show prompt when restoring context.
This fixes being locked in prompt mode with no prompt when a website asks a
javascript question while another one is still visible.
2014-09-30 07:14:14 +02:00
Florian Bruhin
6b8ad67558 statusbar: Ignore subsequent _show_prompt_widget.
If it's already shown, we don't want to mess with stuff again.
2014-09-30 07:13:37 +02:00
Florian Bruhin
52ea924cbe prompter: Override locked mode for questions.
This fixes a crash ([1], "ValueError: Mode KeyMode.yesno not on mode stack!")
when a website asks a second javascript question (prompt/alert/confirm) while
another one is still running.

[1] http://paste.the-compiler.org/view/8c39f5ea
2014-09-30 07:11:54 +02:00
Florian Bruhin
8864c042c8 modeman: Make it possible to override a locked mode. 2014-09-30 07:11:37 +02:00
Florian Bruhin
61ea26b7b2 Fix str() of ConfigValue 2014-09-30 06:32:51 +02:00
Florian Bruhin
ce8409feb2 Add multi window support to :restore/:restart. 2014-09-29 22:37:46 +02:00
Florian Bruhin
6aeecb3803 Fix lints/bugs 2014-09-29 20:36:53 +02:00
Florian Bruhin
686f82c5c6 webview: Remove dead search method. 2014-09-29 20:17:22 +02:00
Florian Bruhin
e031cc60c8 tabbedbrowser: Don't store a list of tabs. 2014-09-29 20:17:11 +02:00
Florian Bruhin
106ad9f4ed userscripts: Don't store a list of runners. 2014-09-29 20:16:54 +02:00
Florian Bruhin
865389bb34 Make CommandRunner a QObject. 2014-09-29 20:16:38 +02:00
Florian Bruhin
45ac2e4835 Fix getting URL for startup commands. 2014-09-29 19:56:37 +02:00
Florian Bruhin
42a1d7028d Move :later back from commands to utilcmds. 2014-09-29 19:56:25 +02:00
Florian Bruhin
0cf8abab7c Fix running of startup commands. 2014-09-29 19:56:13 +02:00
Florian Bruhin
714c9d8b01 Add win_id parameter to commands which need it. 2014-09-29 19:14:11 +02:00
Florian Bruhin
24c48df988 Open about:blank if opening startpage fails. 2014-09-29 19:13:31 +02:00
Florian Bruhin
6e61f4c586 Support opening multiple windows via init args. 2014-09-29 18:50:46 +02:00
Florian Bruhin
e6fe358d73 Clean up correctly when a window is closed. 2014-09-29 10:43:06 +02:00
Florian Bruhin
b84eb6aeb0 Add missing utilcmds import. 2014-09-29 08:52:00 +02:00
Florian Bruhin
26604a683b Fix lint 2014-09-29 07:47:32 +02:00
Florian Bruhin
cdb2e34513 Use collections.UserDict for LineConfigParser. 2014-09-29 07:41:39 +02:00
Florian Bruhin
75ba75a0d7 Check arguments against None in objreg. 2014-09-29 07:17:11 +02:00
Florian Bruhin
895f51083d Some more objreg fixes for multi-window. 2014-09-29 07:17:01 +02:00
Florian Bruhin
36f7ff6154 Fix some objreg.get calls. 2014-09-28 23:23:02 +02:00
Florian Bruhin
9533312e0d Fix event filter when a non-Mainwindow dialog has an event. 2014-09-28 22:53:24 +02:00
Florian Bruhin
16c067e32d Simplify showing of main windows. 2014-09-28 22:46:37 +02:00
Florian Bruhin
2dea47b162 Register prompt per window 2014-09-28 22:44:12 +02:00
Florian Bruhin
cc0e164dcf First attempt at adding a --window to commands. 2014-09-28 22:41:43 +02:00
Florian Bruhin
d87b0bf301 Fix pyqtSlot error for downloads. 2014-09-28 22:41:11 +02:00
Florian Bruhin
7e017e66a0 Fix basekeyparser tests. 2014-09-28 22:24:49 +02:00
Florian Bruhin
dc7b32e460 Fix lint 2014-09-28 22:23:37 +02:00
Florian Bruhin
fb6cb62f93 First attempt at multi-window support. 2014-09-28 22:13:14 +02:00
Florian Bruhin
64a119afb2 Don't use signals for on_config_changed. 2014-09-28 11:27:52 +02:00
Florian Bruhin
65d1d21d2e Always use a list for namedtuple. 2014-09-28 00:43:08 +02:00
Florian Bruhin
0fadf6b091 Use a list as items-argument for usertypes.enum 2014-09-28 00:42:53 +02:00
Florian Bruhin
8636562579 Move config init out of Application 2014-09-28 00:27:22 +02:00
Florian Bruhin
86fdf981e3 Refactor init 2014-09-28 00:18:57 +02:00
Florian Bruhin
c9d5928dce Fix lint 2014-09-27 23:21:13 +02:00
Florian Bruhin
8635dc8848 Make it possible to go back/forward in a new tab. 2014-09-27 23:14:39 +02:00
Florian Bruhin
17f2241bc0 Add a :tab-clone command. 2014-09-27 23:13:11 +02:00
Florian Bruhin
4410536f69 Refactor :undo and save/restore history. 2014-09-27 22:56:50 +02:00
Florian Bruhin
4e42ff1304 Move tab_id_gen and add tab_id to webview repr. 2014-09-26 16:44:41 +02:00
Florian Bruhin
36fd2e5c7f Improve __repr__ methods. 2014-09-26 15:48:24 +02:00
Florian Bruhin
1960cfe114 Really fix keyevent_to_string. 2014-09-26 07:31:59 +02:00
Florian Bruhin
27117246b7 Fix modifier tests on OS X 2014-09-26 07:15:54 +02:00
Florian Bruhin
99da7b697b Fix lint on OS X 2014-09-26 07:12:08 +02:00
Florian Bruhin
d4fdbf5190 Disable OS X focus rect for MinimalLineEditMixin 2014-09-25 22:58:04 +02:00
Florian Bruhin
f8f0c69d79 Fix shutdown before prompter is alive. 2014-09-25 22:56:22 +02:00
Florian Bruhin
f421b7174f Add Ctrl+C shortcut to delete line in debug console. 2014-09-25 22:48:49 +02:00
Florian Bruhin
d1fdd5e776 Bump up default font size on OS X 2014-09-25 22:46:25 +02:00
Florian Bruhin
cdb33a04cc Fix Ctrl-key on OS X 2014-09-25 22:46:25 +02:00
Florian Bruhin
538d467c8d Set default geometry properly on first run. 2014-09-25 22:46:25 +02:00
Florian Bruhin
01159bad86 Fix division by zero in tabSizeHint on OS X 2014-09-25 22:46:25 +02:00
Florian Bruhin
2ebb0063be Really fix version info on OS X 2014-09-25 22:46:25 +02:00
Florian Bruhin
66d36442d7 Fix version info on OS X 2014-09-25 21:33:03 +02:00
Florian Bruhin
9855ad6906 tabbedbrowser: Connect cur_load_started only once. 2014-09-25 19:08:15 +02:00
Florian Bruhin
c188c6986d Call on_mode_entered only once for hints. 2014-09-25 19:06:38 +02:00
Florian Bruhin
0494bc3763 Improve modeman.maybe_leave logging/exception. 2014-09-25 18:45:16 +02:00
Florian Bruhin
6b459f43f1 Improve :debug-all-objects output. 2014-09-25 18:17:52 +02:00
Florian Bruhin
1239efa615 Set application title to "qutebrowser" on tabs without title. 2014-09-25 17:39:56 +02:00
Florian Bruhin
7649dca2ef tabbedbrowser: Improve titleChanged logging. 2014-09-25 17:36:40 +02:00
Florian Bruhin
f294e28fca Remove change_title signal in QWebPage.
When emitting it inside acceptNaviationRequest we don't know if javascript will
open a new window, so we could end up setting the title for the *wrong*
(current) tab.

It seems there isn't any good solution to this problem - in
QWebView.createWindow we won't know what the URL is - so we currently just
leave it blank.
2014-09-25 17:34:55 +02:00
Florian Bruhin
7b8829286c Merge branch 'objreg' 2014-09-25 08:08:08 +02:00
Florian Bruhin
55e2ccabf5 Fix lint 2014-09-25 07:58:08 +02:00
Florian Bruhin
143fdc5b9f Register tab registry in meta registry. 2014-09-25 07:50:07 +02:00
Florian Bruhin
1e7861660e Add 'meta' scope to objreg. 2014-09-25 07:49:46 +02:00
Florian Bruhin
78949a8c1b Use object registry for hintmanager. 2014-09-25 07:49:45 +02:00
Florian Bruhin
e8ce45c440 Add a tab-scope object registry. 2014-09-25 07:49:45 +02:00
Florian Bruhin
4067b584ec Add a registry argument to objreg.register. 2014-09-25 07:43:14 +02:00
Florian Bruhin
e527db1560 Add scope argument to cmdutils.register/commands. 2014-09-25 07:41:51 +02:00
Florian Bruhin
df5ac3ab2f Use object registry for keyparsers. 2014-09-25 07:41:18 +02:00
Florian Bruhin
8421ff7ad0 Fix :restart when installed as Python egg with launcher 2014-09-25 07:07:27 +02:00
Florian Bruhin
e029139764 Fix exception when adding quickmark with empty name. 2014-09-25 06:56:25 +02:00
Florian Bruhin
c77057e88e Add a scope parameter to objreg functions. 2014-09-25 00:30:52 +02:00
Florian Bruhin
4783df8c32 Avoid download_get signal. 2014-09-25 00:29:29 +02:00
Florian Bruhin
c19b8fe982 Fix tests for object registry. 2014-09-24 23:11:17 +02:00
Florian Bruhin
34a5ad48b2 Don't pass prompt object to prompter. 2014-09-24 22:25:11 +02:00
Florian Bruhin
027e7e054e Remove obsolete EnumBase usertype. 2014-09-24 22:25:11 +02:00
Florian Bruhin
05ff908c4f Update attributes in docstrings. 2014-09-24 22:25:11 +02:00
Florian Bruhin
f2b46dc2e9 Remove srcmodel attribute from completionfilter. 2014-09-24 22:25:11 +02:00
Florian Bruhin
cb35452cf0 Remove unused flag for keyparser. 2014-09-24 22:25:11 +02:00
Florian Bruhin
62e55499eb Privatize all attributes which aren't needed from the outside. 2014-09-24 22:25:11 +02:00
Florian Bruhin
75da8a7f1b Add missing parent=None 2014-09-24 22:25:11 +02:00
Florian Bruhin
507354c8d1 Use object registry for Prompt in Prompter. 2014-09-24 22:25:10 +02:00
Florian Bruhin
8cb6ba01e3 Use object registry for TabbedBrowser in SignalFilter. 2014-09-24 22:25:10 +02:00
Florian Bruhin
59058361b8 Add missing objreg import in browser.webpage. 2014-09-24 22:25:10 +02:00
Florian Bruhin
aa5e1922ef Remove _view attribute in BrowserPage. 2014-09-24 22:25:10 +02:00
Florian Bruhin
6a5c9ba138 Use object registry for CompletionView. 2014-09-24 22:25:10 +02:00
Florian Bruhin
7e8e9ee21f Get rid of _page attribute of WebView 2014-09-24 22:25:10 +02:00
Florian Bruhin
9868721cc7 Use object registry for webview.tabbedbrowser. 2014-09-24 22:25:10 +02:00
Florian Bruhin
b119100321 Get rid of _tabs attribute in CommandDispatcher. 2014-09-24 20:21:43 +02:00
Florian Bruhin
5e8144fafa Move cntwidget to commands. 2014-09-24 19:53:31 +02:00
Florian Bruhin
fd9c4b860a Use object registry for url_stack. 2014-09-24 07:32:05 +02:00
Florian Bruhin
387622623d Detach meta object registry from application. 2014-09-24 07:27:32 +02:00
Florian Bruhin
b0a9ecf094 Detach object registry from application. 2014-09-24 07:13:53 +02:00
Florian Bruhin
aa646463b0 Also use objreg API in app 2014-09-24 07:10:17 +02:00
Florian Bruhin
3c2e584c2a Make pylint shut up with _UNSET object. 2014-09-24 07:07:31 +02:00
Florian Bruhin
3f02451828 Move object registry to its own file. 2014-09-24 07:06:45 +02:00
Florian Bruhin
b121ceef21 Use object registry for last focused tab. 2014-09-24 06:41:51 +02:00
Florian Bruhin
6090bf418d Add utils.delete_object() 2014-09-24 06:41:39 +02:00
Florian Bruhin
d32d6c9b28 Allow a default value for utils.get_object. 2014-09-24 06:41:22 +02:00
Florian Bruhin
a2d3ca6565 Make it possible to update an object in the object registry. 2014-09-24 06:25:08 +02:00
Florian Bruhin
908a69af18 Better __repr__s 2014-09-23 23:31:17 +02:00
Florian Bruhin
9aa65a2341 Fix lint and bugs 2014-09-23 23:17:36 +02:00
Florian Bruhin
2b60cdb64c Object names cleanup 2014-09-23 23:05:55 +02:00
Florian Bruhin
04be586bca Use object registry for keyconfig. 2014-09-23 22:37:41 +02:00
Florian Bruhin
fe5d9939b9 Move debug console from app to utilcmd 2014-09-23 22:31:26 +02:00
Florian Bruhin
90820126b4 Update comment 2014-09-23 22:29:03 +02:00
Florian Bruhin
953e50721c Use object registry for config. 2014-09-23 22:28:28 +02:00
Florian Bruhin
07dde5be80 Fix downloading (getting messagebrige object). 2014-09-23 22:22:44 +02:00
Florian Bruhin
b818bc5896 Use object registry for downloadmanager. 2014-09-23 22:22:03 +02:00
Florian Bruhin
7a7b397c15 Use object registry for cmd-history. 2014-09-23 22:17:25 +02:00
Florian Bruhin
8af8e3530f Use object registry for args. 2014-09-23 22:13:10 +02:00
Florian Bruhin
297e37fdf2 Remove legacy instance= parameter support. 2014-09-23 22:08:05 +02:00
Florian Bruhin
37dbfde6ac Use object registry for app. 2014-09-23 22:06:46 +02:00
Florian Bruhin
a32ed36ba6 Use object registry for mainwindow. 2014-09-23 22:05:00 +02:00
Florian Bruhin
a76c4c8ba5 Use object registry for tabbedbrowser. 2014-09-23 22:01:46 +02:00
Florian Bruhin
487300f926 Use object registry for prompter. 2014-09-23 21:56:29 +02:00
Florian Bruhin
ffaf4f0cb0 Use object registry for completion. 2014-09-23 21:50:34 +02:00
Florian Bruhin
40812f81b6 Use object registry for status-cmd. 2014-09-23 21:50:34 +02:00
Florian Bruhin
9a3ceebf2e Use object registry for completer. 2014-09-23 21:39:42 +02:00
Florian Bruhin
f5b1d3ce4d Use object registry for command-dispatcher. 2014-09-23 21:35:08 +02:00
Florian Bruhin
5f45d3de60 Use object registry for modeman. 2014-09-23 20:02:48 +02:00
Florian Bruhin
d441471a17 Use object registry for app._timers. 2014-09-23 19:53:48 +02:00
Florian Bruhin
184babbd84 Remove destroyed QObjects from ObjectRegistry. 2014-09-23 19:53:48 +02:00
Florian Bruhin
58be65f4f0 Use object registry for messagebridge. 2014-09-23 19:53:48 +02:00
Florian Bruhin
1d535ae300 Use object registry for stateconfig. 2014-09-23 19:53:48 +02:00
Florian Bruhin
21bdf517b7 Use object registry for searchrunner. 2014-09-23 19:53:48 +02:00
Florian Bruhin
68cfe499fc Use object registry for rl_bridge. 2014-09-23 19:53:48 +02:00
Florian Bruhin
ab95234dad Add object registry support to command handler. 2014-09-23 19:53:48 +02:00
Florian Bruhin
10eb849ae7 Fix lint 2014-09-23 19:53:47 +02:00
Florian Bruhin
10f3c47ae2 Add __repr__ for cookies/cache. 2014-09-23 19:53:47 +02:00
Florian Bruhin
aa681f5ad2 Merge get_all_widgets into get_all_objects. 2014-09-23 19:53:47 +02:00
Florian Bruhin
30209f531e Improve get_all_objects output. 2014-09-23 19:53:47 +02:00
Florian Bruhin
9e5d8b2480 Add a meta-registry. 2014-09-23 19:53:47 +02:00
Florian Bruhin
dce5289b69 Rename global registry from obj to registry. 2014-09-23 19:53:47 +02:00
Florian Bruhin
dc7ad3e2de Use a normal UserDict for ObjectRegistry. 2014-09-23 19:53:46 +02:00
Florian Bruhin
ca2be960df Use object registry for cache/cookiejar. 2014-09-23 19:53:20 +02:00
Florian Bruhin
3b3675d1af utils: Add helper functions get_object/register_object. 2014-09-23 19:53:15 +02:00
Florian Bruhin
2694ab2e80 app: Make commandrunner/debugconsole private. 2014-09-23 19:51:52 +02:00
Florian Bruhin
097645ae8e app: Support object registry in get_all_objects. 2014-09-23 19:51:52 +02:00
Florian Bruhin
981604fc8b Add initial object registry. 2014-09-23 19:51:52 +02:00
Florian Bruhin
1ce1c91d69 app: Refactor get_all_objects. 2014-09-23 19:51:52 +02:00
Florian Bruhin
698e4049d3 Fix :bind command. 2014-09-23 17:40:56 +02:00
Florian Bruhin
f4876c7f4f Split docutils from utils 2014-09-23 04:22:51 +02:00
Florian Bruhin
9954a08ea2 Fix commands with ignore_args=True (e.g. :restart) 2014-09-22 22:46:03 +02:00
Florian Bruhin
a4079bb39e Split :navigate into several functions 2014-09-22 22:36:31 +02:00
Florian Bruhin
d5a294ae55 commands: Move tab opening to _open functions. 2014-09-22 22:27:19 +02:00
Florian Bruhin
207bb00c50 Add increment/decrement to :navigate 2014-09-22 21:51:09 +02:00
Florian Bruhin
4213550206 Add :navigate up 2014-09-22 21:16:21 +02:00
Florian Bruhin
4615d22a5a browser.commands: Refactor :navigate. 2014-09-22 21:08:11 +02:00
Florian Bruhin
9145ba9656 Adjust comment 2014-09-22 21:03:01 +02:00
Florian Bruhin
51413094bf Merge prev-page/next-page into a navigate command. 2014-09-22 21:01:52 +02:00
Florian Bruhin
bc01f3a780 Fix spelling of temporarily 2014-09-22 20:44:07 +02:00
Florian Bruhin
e26606b0d6 Add /usr/bin/env to shebangs 2014-09-22 20:21:00 +02:00
Florian Bruhin
688b9a57cb Add missing is_visible check for hints. 2014-09-22 20:06:17 +02:00
Florian Bruhin
812a0fdd41 Merge branch 'newcmd'
Conflicts:
	.flake8
	pkg/PKGBUILD.qutebrowser-git
	qutebrowser/browser/commands.py
	qutebrowser/browser/hints.py
	qutebrowser/config/configdata.py
	qutebrowser/network/qutescheme.py
	qutebrowser/test/config/test_configtypes.py
	qutebrowser/utils/utils.py
2014-09-22 19:09:48 +02:00
Florian Bruhin
53b617590f Maybe fix segfault on download errors. 2014-09-22 17:56:23 +02:00
Florian Bruhin
7cf9989bff Fix text color in command right click menu 2014-09-22 13:24:00 +02:00
Florian Bruhin
def417b8a5 Check if docs are up to date if running from git repo. 2014-09-21 22:15:56 +02:00
Florian Bruhin
81b6a92183 Add error if help was not found 2014-09-21 21:21:41 +02:00
Florian Bruhin
84cdb30bcb webelem: Avoid unnecessary ::geometry calls 2014-09-19 17:39:37 +02:00
Florian Bruhin
658053842e hints: Wrap elements after checking is_visible.
Wrapping thousands of elements is really slow (>3 seconds for hinting on a
reddit page, because we wrap ~2500 elements with 50 methods each), so we try to
filter the elements first before wrapping them, as the visible elements will be
much less.
2014-09-19 12:32:28 +02:00
Florian Bruhin
2686278b48 webelem: Make it possible to use is_visible with unwrapped elements. 2014-09-19 12:30:38 +02:00
Florian Bruhin
bc884ed51e webelem: Refuse to wrap a wrapper in WebElementWrapper. 2014-09-19 12:28:23 +02:00
Florian Bruhin
a0cc55037e webelem: Get rid of functools.wraps/functools.update_wrapper. 2014-09-19 11:35:10 +02:00
Florian Bruhin
1eb9bb079c Hide scrollbars via CSS. 2014-09-19 00:37:55 +02:00
Florian Bruhin
1bc5160453 Make it possible to use CSS strings in ui->user-stylesheet. 2014-09-19 00:35:17 +02:00
Florian Bruhin
c3531de71a Clean up autohide and make it work on start. 2014-09-18 19:06:43 +02:00
Florian Bruhin
076ed43ec0 Add auto-hide option for tabs. 2014-09-18 18:15:37 +02:00
Florian Bruhin
906a049382 Fix lint 2014-09-18 17:25:48 +02:00
Florian Bruhin
7f76c3ba13 safe_shlex_split: cleanup and don't do double-lexing 2014-09-18 16:58:38 +02:00
Florian Bruhin
1c1534b5f6 safe_shlex_split: Use real lexer object and handle ' correctly. 2014-09-18 16:57:07 +02:00
Florian Bruhin
0c4d15ea5a safe_shlex_split: Fix broken \' in test. 2014-09-18 16:56:50 +02:00
Florian Bruhin
7de0b85dda safe_shlex_split: Adjust docstring 2014-09-18 16:15:57 +02:00
Florian Bruhin
6a86924e60 safe_shlex_split: Give up after 3 tries. 2014-09-18 16:15:37 +02:00
Florian Bruhin
2e35685fe1 safe_shlex_split: Don't split None. 2014-09-18 16:15:13 +02:00
Florian Bruhin
38108c68a2 Add tests for single quote with safe_shlex_split. 2014-09-18 16:14:31 +02:00
Florian Bruhin
b2340611f2 Allow - in font names. 2014-09-18 13:25:52 +02:00
Florian Bruhin
cef1dfe368 Remove exception handling code for qutescheme.
The exceptions now get handled by @prevent_exceptions on the createRequest
method of the NetworkManager, causing the exception handler to pop up properly.
2014-09-16 22:08:10 +02:00
Florian Bruhin
3bded60ba6 Prevent exceptions in NetworkManager::createRequest. 2014-09-16 22:08:00 +02:00
Florian Bruhin
644dfe53e2 Add a decorator to prevent Exceptions (to prevent segfaults). 2014-09-16 22:06:48 +02:00
Florian Bruhin
5eef6d422d Better exception formatting and handling. 2014-09-16 08:20:19 +02:00
Florian Bruhin
2e419d413b Catch exceptions in version.version() in CrashDialog. 2014-09-16 07:34:27 +02:00
Florian Bruhin
8f2ad91086 Fix lint 2014-09-16 07:34:07 +02:00
Florian Bruhin
c47fa840a0 network.qutescheme: Workaround for segfault on exceptions. 2014-09-16 07:16:30 +02:00