Commit Graph

6683 Commits

Author SHA1 Message Date
Florian Bruhin
778832a813 Set path when redirecting qute:* URLs
Fixes #2513
2017-04-08 23:04:10 +02:00
Jacob Sword
45dff6c0c8 update usage of debug-flag arguments 2017-04-08 16:54:08 -04:00
Jacob Sword
dadbf7657f Merge remote-tracking branch 'upstream/master' 2017-04-07 21:21:01 -04:00
Jacob Sword
3b87e7c297 Add --debug-exit argument and validity check 2017-04-07 21:12:42 -04:00
Florian Bruhin
fd9b86a340 Remove unused imports 2017-04-06 21:40:26 +02:00
Florian Bruhin
871504d91b Fix undefined names 2017-04-06 21:37:23 +02:00
Florian Bruhin
4ec5700cbf Redirect qute:foo to qute://foo
Before, we just returned the same data for both, but then we'll run into
same-origin restrictions as qute:history and qute:history/data are not the same
host.
2017-04-06 21:18:58 +02:00
Florian Bruhin
3cc9f9f073 Don't use from-import 2017-04-06 20:36:54 +02:00
Florian Bruhin
760dca475e Merge commit 'be254be13a61171d4109224450db9e67d1076080' into imransobir/fix-webkit-history 2017-04-06 20:34:49 +02:00
Martin Tournoij
e7755f5d9f
Add :debug-log-filter none
This allows us to clear any filters. Useful for users, and needed for
the tests.
2017-04-04 20:51:14 +01:00
Martin Tournoij
200e439a30
Fix crash of :debug-log-filter when --filter wasn't given
There was no `LogFilter`. The fix is to always initialize a
`LogFilter()` with `None`. as the "filter".

Fixes #2303.
2017-04-04 17:45:23 +01:00
Imran Sobir
be254be13a Use new history page on webkit-ng. 2017-04-04 19:21:25 +05:00
Martin Tournoij
c5427a0127
Fix display of errors while reading the key config file
Also catch `cmdexc.CommandError` on startup to show these errors in the
alert dialog on startup.

Fixes #1340
2017-04-04 09:50:12 +01:00
Florian Bruhin
0de3b5460e Only disable the cache on Qt 5.7.1
I ended up bisecting it, and https://codereview.qt-project.org/#/c/153977/
causes this, which is not in 5.7.0.
2017-04-04 08:24:50 +02:00
Florian Bruhin
2eb365b146 Also disable cache on Qt 5.7 2017-04-03 20:22:54 +02:00
Florian Bruhin
b6642e66fa Fix cache tests on Qt 5.8 2017-04-03 19:41:37 +02:00
Florian Bruhin
1b0ea19ca4 Disable QtNetwork cache on Qt 5.8
See #2427
2017-04-03 17:49:13 +02:00
Florian Bruhin
cb4c64eec9 Remove null argument for QtValueError 2017-04-03 10:18:56 +02:00
Florian Bruhin
2c3fcda18e Remove qtutils.ensure_not_null
It's not used anymore.
2017-04-03 09:32:13 +02:00
Florian Bruhin
3b1b325711 Fix logging 2017-04-03 09:04:28 +02:00
Florian Bruhin
a11356bb99 Don't require working icon to start 2017-04-03 08:32:39 +02:00
Florian Bruhin
35181ff84e Merge commit '4004d5adf09e6d22dae5d781a02c5fc2bbd26724' into Carpetsmoker/unwritable-keyconf 2017-04-03 06:55:01 +02:00
Martin Tournoij
4004d5adf0
Don't crash when trying to write an unwritable keyconf.
Also change the logic in _load_default a wee bit so that it won't try to
write the keys.conf on startup.

Fixes #1235
2017-04-03 01:48:39 +01:00
Florian Bruhin
248ff09624 Merge commit '5efca155948bc467e4fb7b19dafd98d47e33745b' into Carpetsmoker/config-comments 2017-04-02 19:14:00 +02:00
Florian Bruhin
b20267b57d Merge commit '7f13c9a3c31aa719144ca3afcad7af305dd2f6ed' into Carpetsmoker/relax-cmdline 2017-04-02 18:47:00 +02:00
Florian Bruhin
338307ac24 Add #noqa for Quitter._shutdown 2017-04-02 18:35:10 +02:00
Martin Tournoij
79a22f1f47
Allow pressing ^C when there's an unknown setting
All of it is just converting `objreg.get('xxx')` to `objreg.get('xxx',
None)` and adding a `if xxx is not None` check.

Fixes #1170
2017-04-01 21:14:35 +01:00
Martin Tournoij
7f13c9a3c3
Relax commandline parsing a bit
Problem 1: Entering a command of `:::save` gives an error.
Problem 2: Entering a command of `:save\n` gives an error.

Both scenarios may seem a bit silly at first, but I encountered both by
copy/pasting a command:

1. Enter `:` in qutebrowser.
2. Copy a full line from a terminal starting with `:`.
3. You will now have both of the above problems.

Solution: Trim all whitespace and `:` of a command. This is also what
Vim does, by the way.
2017-03-31 17:14:11 +01:00
Florian Bruhin
1eda2b0ea4 Fallback to clipboard when primary selection is unsupported 2017-03-31 13:05:34 +02:00
Florian Bruhin
64feb62fb1 Paste clipboard when using shift-insert in prompts 2017-03-31 13:05:34 +02:00
Florian Bruhin
708b46d6c0 Fix text with empty primary selection 2017-03-31 13:03:40 +02:00
Florian Bruhin
2c4e549d80 Close temporary download file for QtWebEngine
Otherwise, Chromium won't be able to write on it on Windows - and we only
need the name anyways.
2017-03-31 13:03:18 +02:00
Florian Bruhin
a55d1b1ee8 Save old socket for IPC
At least on Windows with Qt 5.8, we get readyRead notifications *after*
disconnect...
2017-03-31 13:03:17 +02:00
Martin Tournoij
5efca15594
Put option comments right above the option value
Problem: I like to edit `~/.config/qutebrowser/qutebrowser.conf`
manually with Vim. This works great, except that the current format is a
bit of a pain to deal with:

	[section-name]
	# section description
	#
	# [ Description of all the options]

	actual options

So if I want to know the description or what the default value is, I
need to scroll up and back down.

Solution: change the order of the comments to:

	# section description
	[section-name]

	# Option description
	option = value

	# Option description two
	optiontwo = value

	# Hello, world!
	[section-two]
	...

Which is much more convenient (and also what almost any other program
does).

(This patch changes much less code than it looks in the diff; I just
de-looped and moved `_str_option_desc` below `_str_items` as that makes
more sense since it gets called by `_str_items`).
2017-03-30 18:45:28 +01:00
Florian Bruhin
6939f81de7 Merge commit '563a5431e35831cb0a8c418835c54d0264d92c78' into Kingdread/windows-drive-cwd 2017-03-30 10:48:39 +02:00
Florian Bruhin
2377235c14 Merge commit 'caf0a87e16cf930f67ce9fc64ea94e17cae6269d' into amosbird/master 2017-03-30 10:48:32 +02:00
Florian Bruhin
6a144ef7bd Merge branch 'Kingdread/windows-drive-cwd' 2017-03-30 10:41:58 +02:00
Daniel Schadt
563a5431e3 fixup! use message.error instead of a tooltip 2017-03-29 18:32:07 +02:00
Daniel Schadt
186eab8eb1 use message.error instead of a tooltip 2017-03-29 17:07:53 +02:00
Daniel Schadt
99f7bfa712 show messages on top of the prompt
Otherwise, errors are hidden behind the prompt, which makes it hard to
use them in the filename prompt.
2017-03-29 16:44:29 +02:00
Imran Sobir
3aaebe83fb Remove noscript message from history.html. 2017-03-29 14:22:58 +05:00
Amos Bird
caf0a87e16 Fix #2476, recognize SOCKS5, SOCKS4 in proxy. 2017-03-29 14:22:37 +08:00
Imran Sobir
4a4c7b96d1 Add nojs history page. 2017-03-28 18:34:47 +05:00
Florian Bruhin
bcb4649235 Fix crash when window_ids change during init 2017-03-27 08:00:19 +02:00
Florian Bruhin
b98d34b29c Handle None-tab in get_tab_fields
I can't reproduce this but I got a crash report about it.
2017-03-27 07:57:43 +02:00
Florian Bruhin
bcee6d295c Handle None-widget in tabbedbrowser.widgets()
I can't reproduce this, but got a crash report about it.
2017-03-27 07:52:33 +02:00
Florian Bruhin
f6906512dc Merge commit 'df93e30ec20dd1b2b4fe163bdb5a69c232fb8c71' into Al-Caveman/master 2017-03-27 07:00:53 +02:00
Florian Bruhin
37d22a7cfd Merge commit '9dccd00ebb2483fd0bb6c6447f57c76a4b40d335' into Kingdread/windows-drive-cwd 2017-03-26 22:14:47 +02:00
Florian Bruhin
39b09f7822 Improve messageview hide code 2017-03-26 15:03:44 +02:00
Florian Bruhin
2181e1ddc4 Merge commit '13677d3563dbd01ae188a2b1a79c7dd840a5dc5e' into pkill-nine/upstream-master-close_message_on_click 2017-03-26 14:59:08 +02:00
pkill9
5e1c530d71 Add docstring to MessageView.mousePressEvent 2017-03-25 21:03:21 +00:00
pkill9
67034273f7 Move criteria into a list and add middle mouse button. 2017-03-25 15:58:37 +00:00
caveman
df93e30ec2 fixes #2468 2017-03-25 11:44:36 +04:00
Daniel Schadt
9dccd00ebb fix unused import 2017-03-24 14:49:30 +01:00
Daniel Schadt
df83f7aa99 also add path transformations to :download 2017-03-24 12:30:29 +01:00
Daniel Schadt
07b3a7db7c add integration tests for reserved filenames 2017-03-24 11:57:05 +01:00
Daniel Schadt
bc4430e5d9 prevent reserved filenames on Windows
Fixes #82

Prevents filenames like COM1, ...
2017-03-24 11:36:19 +01:00
Daniel Schadt
9d905ebb5c disallow filenames like E:filename
Per-drive working directories are not really supported.
2017-03-24 11:04:20 +01:00
Daniel Schadt
3da21a32d2 treat E: and E:\ the same when downloading
Fixes #2305
2017-03-23 18:16:15 +01:00
Ryan Roden-Corrent
a68f997d95 Make keyhint delay configurable.
ui.keyhint-delay controls the time from starting a keychain to showing the
keyhint dialog. Resolves #2462.
2017-03-22 21:50:26 -04:00
Florian Bruhin
042ffeca91 Merge commit '631936361405d812f353b4108246c883cdf48100' into Kingdread/issue-2304 2017-03-22 22:50:28 +01:00
Florian Bruhin
4d65abfcc6 Check if widget is deleted in _on_webkit_icon_changed 2017-03-22 06:32:09 +01:00
Daniel Schadt
ebc70f66e5 Check for None-reply in _do_die
Fixes #2304

In some cases, the finished handler fired before the error handler, e.g.
when downloading a 500 error page that is sent as attachment:

    HTTP/1.1 500 Internal Server Error
    Content-Type: application/octet-stream
    Content-Disposition: inline; filename="attachment.jpg"

here we downloaded 0 bytes, fired the finished handler and after that
fired the error handler because of the 500 - but the finished handler
had already set our reply to None (and displayed the error message).
2017-03-21 18:54:21 +01:00
Florian Bruhin
f8e043214a Update WORKAROUND comments 2017-03-21 10:29:31 +01:00
Florian Bruhin
081abde9cd Fix indent 2017-03-20 22:06:05 +01:00
Florian Bruhin
3fbb9a14e0 Fix continuing a search after clearing it
Fixes #2438
2017-03-20 21:34:33 +01:00
Florian Bruhin
c996245012 Fix line length 2017-03-20 16:48:21 +01:00
Florian Bruhin
98f17a03bb Prevent page without history from being serialized
Fixes #2458
2017-03-20 11:50:04 +01:00
Florian Bruhin
6888ac04e1 Fix handling of failed downloads with QtWebEngine 2017-03-20 09:44:07 +01:00
Florian Bruhin
3e2ba32240 Fix retrying downloads with QtWebEngine
Fixes #2298
2017-03-20 09:35:53 +01:00
Florian Bruhin
7652b6ae03 Merge commit '724e6b29c38a55f722f17997379f1ebe190fa6db' 2017-03-20 09:11:47 +01:00
thuck
650b1de3b6 Merge branch 'master' of https://github.com/The-Compiler/qutebrowser into pintab 2017-03-19 14:26:48 +01:00
thuck
02bf0401ab Last pinned to pinned_count 2017-03-19 14:05:21 +01:00
thuck
2eb07fc9cc Fix line size 2017-03-19 14:03:24 +01:00
Florian Bruhin
99c7301fb4 Update IPC atime once all 3h
See #996
2017-03-16 09:24:49 +01:00
Imran Sobir
724e6b29c3 Make session interval configurable. 2017-03-16 12:11:16 +05:00
Imran Sobir
fb97c6dffc Send history item atime in milliseconds. 2017-03-16 12:03:40 +05:00
Florian Bruhin
d33e590ce5 Fix lint 2017-03-15 22:15:52 +01:00
Florian Bruhin
85fff35eef Merge branch 'gl-workaround' 2017-03-15 19:52:33 +01:00
Florian Bruhin
0877092cea Add workaround for black screen with QtWebEngine
Fixes #2441
2017-03-15 19:52:21 +01:00
Florian Bruhin
84d2e9adc6 Improve documentation around scrolling
Fixes #2447
2017-03-14 16:58:33 +01:00
Florian Bruhin
8d9030ec47 Use debug log for on_timeout message 2017-03-13 07:01:21 +01:00
pkill9
b1771a13c9 Removed setting. 2017-03-12 16:48:57 +00:00
pkill9
87c4c143bf Clear notification messages in a window when they're clicked. 2017-03-11 20:45:12 +00:00
Imran Sobir
ccbf8572c3 Check for null when receiving history. 2017-03-09 22:16:46 +05:00
Imran Sobir
19b7f779ef Fix ambiguity in history table ID. 2017-03-09 21:41:57 +05:00
Imran Sobir
3fbeecbec2 Hide 'Show more' when Javascript is disabled. 2017-03-09 21:35:22 +05:00
Florian Bruhin
eb2888a957 Merge commit 'd3b16bbd075f9e8c8656a402975d776088c2dab8' into pkill-nine/upstream-master-close_messages 2017-03-08 19:19:30 +01:00
Florian Bruhin
4278cd5e3e Remove unused operator imports 2017-03-08 19:10:29 +01:00
pkill9
d3b16bbd07 Add command to clear messages - cleaner 2017-03-08 10:49:15 +00:00
Florian Bruhin
7ba01e6764 Get rid of utils.actute_warning
Only Ubuntu Trusty still uses Qt < 5.3, and the issue seems to be fixed there by
now.
2017-03-08 09:25:46 +01:00
Florian Bruhin
f86f9cd92a Refactor qtutils.version_check API
Fixes #2423
2017-03-08 08:41:18 +01:00
Florian Bruhin
dfb4374ae1 Release v0.10.1 2017-03-08 06:26:22 +01:00
Florian Bruhin
7c9d004bbc Fix compiled version check
Fixes #2412
2017-03-07 22:05:17 +01:00
Florian Bruhin
4c3c86081f Refactor adblock parsing 2017-03-07 21:46:04 +01:00
Florian Bruhin
c45019f0a0 Handle invalid UTF8 data in hostblock lists
Fixes #2301
2017-03-07 20:25:13 +01:00
Florian Bruhin
d42dff67f2 Reorder initialization
marcos.init() really belongs into _init_modules, and we need to do _process_args
after everything has been initialized.

Fixes #2408.
2017-03-07 06:46:35 +01:00
pkill9
74be2fa4b9 Add command to close all messages. 2017-03-05 14:55:28 +00:00
Florian Bruhin
ec42d2fd2a Merge branch 'fast-open-download' of https://github.com/Kingdread/qutebrowser into Kingdread-fast-open-download 2017-03-05 15:50:38 +01:00
Florian Bruhin
a585015d9d Merge branch 'hide_adblock_message' of https://github.com/TomRiddle01/qutebrowser into TomRiddle01-hide_adblock_message 2017-03-05 15:18:43 +01:00
Florian Bruhin
a1c7d179e3 Only call QApplication::sync() with QtWebEngine 2017-03-05 15:16:14 +01:00
Florian Bruhin
c422897abb Make sure to process history after the rest of init is done
Otherwise, with 5ccafd62d4 the history starts
processing before the webview opened, and opening it is delayed until the whole
history is read.

Instead, call _process_args directly (I'm not even sure why it was using a 0ms
QTimer...) and schedule _init_late_modules after everything is really done.
2017-03-04 18:24:44 +01:00
Florian Bruhin
5ccafd62d4 Fix initial keyboard focus with QtWebEngine
Fixes #2321.
2017-03-04 18:11:34 +01:00
Florian Bruhin
e81edc8224 ipc: Delay deleting of QLocalSocket on disconnect
Fixes #2396.

See https://bugreports.qt.io/browse/QTBUG-59297 and
https://github.com/qutebrowser/qutebrowser/issues/2321#issuecomment-284024213
2017-03-04 18:11:34 +01:00
Yannis Rohloff
7984643365 flake8 fails fixed 2017-03-04 17:16:52 +01:00
Yannis Rohloff
5d5652a24b always read the host file 2017-03-04 17:08:53 +01:00
Yannis Rohloff
6219b37c39 adblock: Don't show message if host-blocking-enabled is true
Fixes #2364
2017-03-04 16:39:44 +01:00
Imran Sobir
0092b18c44 Fix qute:javascript on Windows. 2017-03-04 19:37:48 +05:00
Daniel Schadt
90f12a1d5a return fast from DownloadItem.open_file
Fixes #2296

By using a singleshot timer, we return fast from DownloadItem.open_file,
which in turn closes the prompt fast, which in turn doesn't allow a
second Ctrl-x to be registered, which in turn doesn't want to set the
filename twice.
2017-03-04 11:30:41 +01:00
Florian Bruhin
0186a9bde5 Fix lint 2017-03-02 21:10:31 +01:00
Florian Bruhin
75bc400e74 Add Chromium version to version output
This also restructures things a bit to show the backend version together with
the backend.

Fixes #2380
2017-03-02 20:22:17 +01:00
Imran Sobir
96e81f595f Fix a case where 'next' is not correctly returned. 2017-03-02 23:14:00 +05:00
Florian Bruhin
56ab02f54d Set tab as parent for print dialogs
Fixes #2366
2017-03-02 18:44:07 +01:00
Imran Sobir
895620b536 Don't assume 'next' appears last. 2017-03-02 22:40:24 +05:00
Florian Bruhin
81a36ffd7d Strip QtWebEngine download suffixes properly
Fixes #2386
2017-03-01 23:43:04 +01:00
Florian Bruhin
f4490fb90c Fix WebKitElement._move_text_cursor with old PyQt 2017-03-01 20:19:40 +01:00
Florian Bruhin
1f12b4c1c1 Relax validation of QssColor values
Fixes #2370
2017-03-01 18:11:53 +01:00
Florian Bruhin
65f407e926 Remove webelem.style_property()
It's not used anymore, and not possible to support with QtWebEngine without a
massive performance hit when serializing elements.
2017-03-01 17:54:27 +01:00
Florian Bruhin
03f1e0913d Add _js_call to WebEngineElement 2017-03-01 17:34:21 +01:00
Florian Bruhin
bc0a9cd94d Move cursor to end with input elements on QtWebEngine 2017-03-01 17:30:48 +01:00
Florian Bruhin
1e1ba34b60 Fix selecting text fields with QtWebKit
Using focus() in JS there means that existing text in the field gets selected.
Move the cursor to the end after focusing it to prevent that.

Fixes #2359
2017-03-01 17:13:02 +01:00
Florian Bruhin
deb59fc66e Don't strip info when loading PAC from a file 2017-03-01 14:19:23 +01:00
Florian Bruhin
9bb5c9fdab Remove UserInfo and path/query for PAC URLs 2017-03-01 14:19:13 +01:00
Florian Bruhin
1e42fd1319 Fix lint 2017-03-01 11:12:28 +01:00
Florian Bruhin
61e7d5883f Merge branch 'ZZ-and-ZQ' of https://github.com/wasamasa/qutebrowser into wasamasa-ZZ-and-ZQ 2017-02-28 21:22:55 +01:00
Florian Bruhin
47a9c8e17c Also check compiled Qt version in version checks 2017-02-28 21:01:47 +01:00
Florian Bruhin
67dfbc7e5f Don't create QWebEngine profile at import time
Fixes #2378
2017-02-28 17:24:48 +01:00
Imran Sobir
cb6c6b814e Fix pylint errors. 2017-02-28 20:11:51 +05:00
Imran Sobir
9e6b0240f6 Put javascript in module, fix lint errors 2017-02-28 19:23:31 +05:00
Imran Sobir
3e45f739fc Show message when Javascript is turned off. 2017-02-28 19:22:10 +05:00
Florian Bruhin
9be0e0d57d Clarify javascript-can-access-clipboard description
Fixes #2374.
2017-02-27 20:28:47 +01:00
Imran Sobir
e8db008671 Move qute:history javascript to own file. 2017-02-27 22:44:13 +05:00
Imran Sobir
3b3846c9dc Add qute:javascript to serve JS files. 2017-02-27 22:37:24 +05:00
Florian Bruhin
fb5377b710 Remove unnecessary code 2017-02-27 17:55:50 +01:00
Imran Sobir
783769d302 Load new history items from next item's time. 2017-02-27 21:44:23 +05:00
Imran Sobir
c4416c8ac0 Prevent crash with invalid start_time param. 2017-02-27 21:41:35 +05:00
Imran Sobir
c223f6c69d Style/misc fixes. 2017-02-27 21:39:51 +05:00
Florian Bruhin
94cabdb840 Use double dashes for --qt-arg/--qt-flag
Qt seems to not care about -style vs --style, but this way we can also pass
stuff to Chromium.
2017-02-27 13:33:12 +01:00
Florian Bruhin
c59b6bf02b Handle invalid layout in TabBarStyle.subElementRect 2017-02-27 09:05:40 +01:00
Imran Sobir
76bf8c0049 Convert history to list before converting to JSON. 2017-02-26 19:58:14 +05:00
Imran Sobir
845f21b275 New qute:history page. 2017-02-26 17:07:30 +05:00
Vasilij Schneidermann
ce433bd139 Add ZZ and ZQ keys to (save and) quit the session 2017-02-25 23:10:18 +01:00
Florian Bruhin
469445e816 Release v0.10.0 2017-02-25 21:47:56 +01:00
Florian Bruhin
fc2250b3b2 Merge branch 'session-save-only-active-window' of https://github.com/danfis/qutebrowser into danfis-session-save-only-active-window 2017-02-25 17:55:42 +01:00
Florian Bruhin
9656449545 Merge branch 'master' of https://github.com/kiryl/qutebrowser into kiryl-master 2017-02-25 17:53:05 +01:00
Florian Bruhin
496b70697b Merge branch 'newbmarkstyle' of https://github.com/imransobir/qutebrowser into imransobir-newbmarkstyle 2017-02-25 17:46:21 +01:00
Florian Bruhin
1eab108323 Merge branch 'upstream-master-jseval-file' of https://github.com/pkill-nine/qutebrowser into pkill-nine-upstream-master-jseval-file 2017-02-25 17:26:12 +01:00
pkill9
6cb48ba2b6 Adds a --file flag to :jseval 2017-02-25 13:11:53 +00:00
Florian Bruhin
48c9a4061b Also fix ACE hinting for QtWebKit 2017-02-24 18:36:15 +01:00
Florian Bruhin
23183bd918 Fix hinting in ACE editors 2017-02-24 15:12:35 +01:00
Florian Bruhin
3feb4211fe Don't show hints for opacity: 0 elements
Fixes #2347
2017-02-24 09:13:25 +01:00
Florian Bruhin
e832105dd5 Treat the Jupyter input line as editable 2017-02-23 17:43:22 +01:00
Imran Sobir
34abad27c4 Use jinja filter to set default title. 2017-02-23 19:29:49 +05:00
Imran Sobir
4b643f0b74 Extract common styling from bookmarks, history. 2017-02-23 19:23:18 +05:00
Florian Bruhin
91d3326a9e Show a warning when using private-browsing with QtWebKit-NG 2017-02-23 06:49:09 +01:00
Florian Bruhin
6004bfa72f Don't lose warnings shown in early init phases 2017-02-23 06:48:58 +01:00
Florian Bruhin
cd2c547b6b Don't show error if no autosave session exists 2017-02-22 23:17:59 +01:00
Daniel Fiser
6e1ac8be78 Fixed indentation of SessionManager.save() arguments. 2017-02-22 10:37:55 +01:00
Daniel Fiser
bb5825e043 session-save: in case of --only-active-window, the win-id is determined in session_save(). 2017-02-22 10:22:30 +01:00
Daniel Fiser
bb74b2703f session-save: doc generated from docstring. 2017-02-22 09:59:29 +01:00
Florian Bruhin
5379138c17 Merge branch 'pac+file' of https://github.com/kiryl/qutebrowser into kiryl-pac+file 2017-02-22 07:35:06 +01:00
Florian Bruhin
e8443241df Allow input -> mouse-zoom-divider to be 0 2017-02-22 05:15:57 +01:00
Florian Bruhin
5a87c9b6cb Re-add missing import 2017-02-21 19:44:15 +01:00
Florian Bruhin
b69d66e437 Actually check for Qt 5.7.1 2017-02-21 19:28:22 +01:00
Florian Bruhin
71f7b01ea7 Bring back PyQt (but not Qt) 5.7.0 support with QtWebEngine
This was originally removed in a86170f45, however Debian testing (Stretch) comes
with Qt 5.7.1, but PyQt 5.7.
2017-02-21 19:25:18 +01:00
Florian Bruhin
a179d6a738 Improve earlyinit Qt/PyQt version messages 2017-02-21 19:15:22 +01:00
Kirill A. Shutemov
ac3c8bb319 pac_utils.js: remove excessive escaping
Looks like the implementation was derived from Mozilla's
nsProxyAutoConfig.js, which is evaluated twice. It requires double
escaping.

In our case excessive escaping is harmful.

In particular it makes ip-matching regexp in isInNet() invalid and makes
it really slow as we go to dnsResolve() all the time, even when it's not
needed.

Signed-off-by: Kirill A. Shutemov <kirill@shutemov.name>
2017-02-21 15:23:27 +03:00
Imran Sobir
7cb384aaf3 Update qute:bookmarks design. 2017-02-21 16:02:03 +05:00
Kirill A. Shutemov
de088c18b9 Allow pac+file proxy scheme to load PAC file from local filesystem
Signed-off-by: Kirill A. Shutemov <kirill@shutemov.name>
2017-02-21 12:57:18 +03:00
Kirill A. Shutemov
13213724b0 PAC: fix isPlainHostName()
Fix isPlainHostName() implementation and add test-case for it.

Signed-off-by: Kirill A. Shutemov <kirill@shutemov.name>
2017-02-21 12:16:46 +03:00
Florian Bruhin
25f217552c Remove unused import 2017-02-21 06:17:17 +01:00
Florian Bruhin
1708b38d7b Add SessionManager.{save,delete}_autosave 2017-02-20 07:43:41 +01:00
Florian Bruhin
ee25e900f8 Add error handling for autosave session 2017-02-20 06:44:23 +01:00
Florian Bruhin
cafff3e1b6 Merge branch 'session-autosave' of https://github.com/cosminadrianpopescu/qutebrowser into cosminadrianpopescu-session-autosave 2017-02-20 06:30:34 +01:00
Florian Bruhin
eb4d699be3 Add missing click_target arg to _click_editable 2017-02-19 20:46:43 +01:00
Florian Bruhin
389501deb9 Merge branch 'navigate-fix' of https://github.com/EliteTK/qutebrowser into EliteTK-navigate-fix 2017-02-19 20:22:27 +01:00
Florian Bruhin
f772ccb203 QtWebEngine: Fall back to events for hints if JS is broken
*cough* musl *cough*
2017-02-19 20:03:27 +01:00
Florian Bruhin
5b4b226186 Add Qt library/data paths to version info 2017-02-19 14:02:40 +01:00
Tomasz Kramkowski
5b7090e402 browser/navigate: _find_nextprev allow for space sep rel attribs
The _find_nextprev function of browser/navigate.py only checks to see if
the rell attribute equals 'prev', 'previous', or 'next'. This patch
changes this to check for a set intersection between {'prev',
'previous'} or {'next'} and the set of the space separated list of the
rel attribute.
2017-02-19 12:31:09 +00:00
Florian Bruhin
01db59ff36 Handle all uerscript errors when hinting with userscript-target 2017-02-19 13:15:15 +01:00
Florian Bruhin
4e74fff5e8 Test/lint fixes 2017-02-18 00:10:13 +01:00
Florian Bruhin
410b56447a Temporarily set JavascriptCanOpenWindows for hints
This partially reverts ba21fb3784.
Fixes #2311.
2017-02-17 22:08:46 +01:00
Florian Bruhin
a767e33f15 Re-add title setting code 2017-02-17 15:52:12 +01:00
Florian Bruhin
dcdfc116a4 Fix indent 2017-02-17 15:52:05 +01:00
Florian Bruhin
0deb422cfd Remove unused imports 2017-02-17 15:44:25 +01:00
Florian Bruhin
b5dd69f4a6 Add some logging for clicking 2017-02-17 15:43:25 +01:00
Florian Bruhin
a86170f45d Drop PyQt < 5.7.1 support for QtWebEngine 2017-02-17 14:42:57 +01:00
Florian Bruhin
7a4a34c374 Fix WebEngineElement.click on Qt 5.6 2017-02-17 14:32:45 +01:00
Florian Bruhin
ba21fb3784 webengine: Use _click_href for hinting target=_blank links
Fixes #2311
2017-02-17 06:57:31 +01:00
Florian Bruhin
40e1337e03 Adjust WebEngineEleement _js_dict in remove_blank_target
Otherwise, when checking later if the element has target=_blank set, we still
think it is.

This is not perfect as remove_blank_target also removes it from sub-elements,
but it's a good start.
2017-02-17 06:56:12 +01:00
Florian Bruhin
3de2bfb277 Handle renderer process not starting at all 2017-02-13 11:23:29 +01:00
Florian Bruhin
2b76cca2b2 Improve earlyinit error messages 2017-02-12 21:19:58 +01:00
Florian Bruhin
d60e365e3c Don't use _click_js for target=_blank links
Fixes #2311
2017-02-12 01:06:56 +01:00
Florian Bruhin
a4f04db848 Cap scroll count to 5000
Fixes #1694
2017-02-11 22:26:37 +01:00
Florian Bruhin
b73cda22de Fix lint 2017-02-11 21:17:16 +01:00
Florian Bruhin
bd8ead2279 Detect rel-attributes on <a> elements for :navigate 2017-02-11 20:48:48 +01:00
Florian Bruhin
66cbb8aa31 Fix lint 2017-02-11 17:22:35 +01:00
Florian Bruhin
b15ae97444 Get timestamp of curr_date instead of today 2017-02-11 17:06:51 +01:00
Florian Bruhin
c3153273f5 Merge branch 'master' of https://github.com/imransobir/qutebrowser into imransobir-master 2017-02-11 17:05:57 +01:00
Imran Sobir
37c3b79b9b Add :history command. 2017-02-10 17:47:20 +05:00
Florian Bruhin
46752a2c24 Add some performance improvements for qute:history 2017-02-10 11:39:08 +05:00
Imran Sobir
9001ec079c Align history time to the right. 2017-02-09 18:37:33 +05:00
Imran Sobir
d21585f603 Add rel=prev, rel=next to pagination links. 2017-02-09 18:11:17 +05:00
Florian Bruhin
85d8d45e19 Ask for confirmation with :history-clear 2017-02-09 13:20:00 +01:00
Imran Sobir
a15aa9eade Hide next links to future. 2017-02-09 17:18:57 +05:00
Florian Bruhin
859974fa99 Don't crash without hint context in HintManager._start_cb 2017-02-08 22:49:25 +01:00
Florian Bruhin
b5ab3adc8c Fix sip.assign check 2017-02-08 22:27:49 +01:00
Florian Bruhin
0897e8e5ad Add pdfjs path for pdf.js in AUR 2017-02-08 22:17:34 +01:00
Florian Bruhin
3adcfddfff Handle LookupError when reading adblock zips 2017-02-08 22:17:30 +01:00
Florian Bruhin
4d08dc5ddb Point out QtWebKit-NG in version info 2017-02-08 18:34:50 +01:00
Florian Bruhin
df35c9138b Filter out uninteresting elements early in TabBarStyle
Otherwise we call _tab_layout on something which is not a QStyleOptionTab, which
might cause AttributeErrors. In a crash report I couldn't reproduce, it got
called with a QStyleOptionMenuItem when right-clicking on the page.
2017-02-08 16:53:03 +01:00
Florian Bruhin
36e2cc9628 Fix broken "if" when closing tab.
Combining the "add_undo" with "tab.url().isValid()" was a mistake as the "else"
meant something else then...
2017-02-08 12:45:09 +01:00
Florian Bruhin
6ae7960d9a Fix lint 2017-02-08 12:14:24 +01:00
Florian Bruhin
2501eed5f5 Re-add tab.deleteLater() call
This got removed in 1af951fd62 but
tab.layout().unwrap() only deletes the underlying widget, not the tab itself.
2017-02-08 12:12:36 +01:00
Florian Bruhin
0130866e89 Only do mhtml import in DownloadManager.get_mhtml
We also import qtnetworkdownloads on QtWebEngine without QtWebKit available, so
we can't be sure we can import mhtml.
2017-02-08 12:03:32 +01:00
Florian Bruhin
8226afd167 Hide more SSL warnings 2017-02-08 12:01:30 +01:00
Florian Bruhin
7c08444c37 Refuse to serialize chrome:// and view-source:// tabs
Fixes #2289
2017-02-08 11:40:00 +01:00
Florian Bruhin
1af951fd62 Work around crashes when opening URL after renderer crash
Fixes #2290
2017-02-08 10:56:44 +01:00
Florian Bruhin
2469d01ce7 Add renderer_process_terminated signal to tab API 2017-02-08 10:55:05 +01:00
Imran Sobir
ec0e95969e Add unit tests for qute://history. 2017-02-08 13:28:04 +05:00
Florian Bruhin
87d1a2c7a3 Fix lint 2017-02-08 09:14:54 +01:00
Florian Bruhin
12ed226ce6 Set COLUM_WIDTHS for :help completion
Fixes #2287
2017-02-08 09:11:58 +01:00
Florian Bruhin
c4a74c7a34 Make sure completion column widths never get negative
I discovered this because of #2287 but it doesn't actually change anything
there. When we don't have a third column, subtract the scrollbar width from the
second one.
2017-02-08 09:10:40 +01:00
Florian Bruhin
02198c4f65 Also check for QtWebKitWidgets in earlyinit 2017-02-08 00:57:47 +01:00
Florian Bruhin
8b9b49f180 Fix message on renderer process crash 2017-02-08 00:41:17 +01:00
Florian Bruhin
c198f3a6a3 Adjust descriptions and dependencies
See #1571
2017-02-07 23:27:44 +01:00
Florian Bruhin
3f1433dcf7 Merge branch 'webengine-mhtml' 2017-02-07 22:24:25 +01:00
Florian Bruhin
d13809089f Exclude socket notifier events during prompts
This helps with segfaults while the prompt is shown, like those which happened
during mhtml downloads with QtWebEngine.
2017-02-07 22:13:33 +01:00
Florian Bruhin
7aa0e900d7 Add mhtml support for QtWebEngine 2017-02-07 22:13:33 +01:00
Florian Bruhin
bae1f41599 Set user-agent for QtWebKit downloads
See #513
2017-02-07 22:00:03 +01:00
Imran Sobir
9a218256b7 Fix pylint complaints. 2017-02-07 19:25:01 +05:00
Imran Sobir
2c40be31a2 Prevent crash if invalid date is passed to qute:history. 2017-02-07 16:15:10 +05:00
Imran Sobir
be12b4cccf Use history item's url as title if no title. 2017-02-07 16:06:19 +05:00
Daniel Fiser
c092840c04 Add optional argument --only-active-window to :session-save.
The new optional argument --only-active-window makes :session-save to
save only the tabs in the currently active window.
2017-02-07 10:38:41 +01:00
Imran Sobir
f5e75ff870 Misc qute_history() fixes. 2017-02-07 11:56:51 +05:00
Imran Sobir
46a34a99f3 Use QUrlQuery to parse qute://history queries. 2017-02-07 11:22:04 +05:00
Florian Bruhin
e487fe441e Revert "Add a workaround to save cookies on exit"
This causes sqlite cookie errors from Chromium on shutdown...

See #2263
This reverts commit 8d55d093f2.
2017-02-06 22:16:39 +01:00
Florian Bruhin
2b6b18d7bf Fix lint 2017-02-06 21:33:08 +01:00
Florian Bruhin
df245dae48 Add support for general -> print-element-backgrounds with WebEngine 2017-02-06 21:08:32 +01:00
Florian Bruhin
a40db1735e Update QtWebEngine settings todo 2017-02-06 21:01:19 +01:00
Florian Bruhin
811bb84587 Clarify site-specific-quirks setting value 2017-02-06 20:43:25 +01:00
Florian Bruhin
8d55d093f2 Add a workaround to save cookies on exit
Fixes #2263
2017-02-06 20:43:23 +01:00
Florian Bruhin
b8b4611b4d Enable errors on renderer process crashes 2017-02-06 20:43:03 +01:00
Imran Sobir
748ec7e7a1 Add history page. 2017-02-07 00:04:32 +05:00
Florian Bruhin
52e3865367 Add support for the colors -> webpage.bg option with QtWebEngine 2017-02-06 17:18:36 +01:00
Florian Bruhin
29ffa3d134 Add a fullscreen notification overlay
From the spec:

  User agents should ensure, e.g. by means of an overlay, that the end user is
  aware something is displayed fullscreen. User agents should provide a means of
  exiting fullscreen that always works and advertise this to the user. This is
  to prevent a site from spoofing the end user by recreating the user agent or
  even operating system environment when fullscreen.

https://fullscreen.spec.whatwg.org/#security-and-privacy-considerations
2017-02-06 16:22:58 +01:00
Florian Bruhin
39508d984e Handle multiple commands in KeyConfigParser.get_reverse_bindings_for 2017-02-06 16:22:58 +01:00
Florian Bruhin
98e6ccf548 Add fullscreen support for QtWebEngine 2017-02-06 16:22:58 +01:00
Florian Bruhin
1209724f83 Fix lint 2017-02-06 13:42:31 +01:00
Florian Bruhin
dd9d6264c7 Fix search/replace fail 2017-02-06 13:09:39 +01:00