Jan Verbeek
c7c5a98506
Allow {url} and {url:pretty} as parts of arguments
...
This makes commands like `:open web.archive.org/web/{url}` possible.
This commit also adds a no_replace_variables command register argument
that stops the replacement from happening, which is important for
commands like `:bind` and `:spawn` that take a command as an argument.
2016-08-04 02:43:02 +02:00
Daniel Schadt
71102cceb0
docstring & documentation fixes
2016-08-03 18:06:28 +02:00
Daniel Schadt
fa6c552d7b
add an application param for prompt-open-download
2016-08-03 17:59:32 +02:00
Ryan Roden-Corrent
e8f73b0fe6
Break up MainWindow.__init__.
...
Split out initialization of a few areas into private functions so
pylint won't complain about a long method.
2016-07-28 12:20:24 -04:00
Ryan Roden-Corrent
f31e890862
Move completion_item_{next,prev} to CompletionView.
...
These commands are more closely tied to the CompletionView than
Completer. This removes the need for an extra signal tying the
CompletionView to the Completer.
The call to _open_completion_if_needed was moved to
on_selection_changed, as this will already be called when a new item is
selected.
2016-07-28 12:20:24 -04:00
Ryan Roden-Corrent
b9cf9d180b
Decouple Completer and CompletionView.
...
Rather than having a CompletionView instantiate and register a
Completer, instantiate both in MainWindow. The CompletionView is the
parent of the Completer, and communicates by emitting
selection_changed, meaning it no longer needs to contain a reference to
the Completer.
2016-07-28 12:20:24 -04:00
Florian Bruhin
3ccb691e9f
tab API: Rename scroll to scroller
...
The scroll attribute did overwrite QWidget.scroll which is unfortunate.
2016-07-26 13:19:07 +02:00
Florian Bruhin
70d6f90f08
Display key hint for :prompt-download-open
...
This also splits up _display_question into one method per mode.
2016-07-26 11:08:03 +02:00
Florian Bruhin
f4f6a3dac1
Merge branch 'open-download' of https://github.com/Kingdread/qutebrowser into Kingdread-open-download
2016-07-26 10:32:34 +02:00
Florian Bruhin
76eab7617b
Remove @pyqtSlot for functions and non-QObjects
...
Fixes #1669
2016-07-23 11:42:50 +02:00
Daniel Schadt
940b124253
switch set literal to list literal
...
See PR #1642 .
😗 🎶
2016-07-12 22:31:43 +02:00
Jan Verbeek
bbc46d28ff
Use lists instead of tuples for comparing
...
Per one of the diff comments on #1597 :
> I used to use a tuple for constant things, but nowadays I'd actually
> prefer a list as a tuple is something more heterogeneous (i.e. it
> makes sense to have a `(x, y)` point as a tuple, but a list of points
> would be a list).
> At some point I should probably change it to a list everywhere 😉
2016-07-12 22:05:32 +02:00
Daniel Schadt
a088f238e5
usertypes: remove Frankenstein's enum
...
This approach is not as weird in Python and still works.
DownloadTarget.OpenDownload has been renamed to OpenFileDownloadTarget,
since OpenDownloadDownloadTarget didn't look as nice.
2016-07-12 17:10:36 +02:00
Daniel Schadt
d42d980dda
downloads: introduce target= param for .get/.fetch
...
This parameter replaces the filename and fileobj parameters. This makes
it easier to add more download targets, since only one may be "chosen".
With the OPEN_DOWNLOAD special case added, handling of filename got a
bit ugly, since it may be either None, OPEN_DOWNLOAD or a str with the
file path, and we had to make sure only one target was chosen.
With the new target enum, this handling can be simplified and we
automatically get the guarantee that only one target is chosen.
2016-07-12 17:06:40 +02:00
Daniel Schadt
81b2688c70
downloads: use global TempDownloadManager
...
This way, all temporary downloads will end up in the same directory and
everything is cleaned up at program exit, not when the corresponding
window is closed.
2016-07-12 16:52:01 +02:00
Daniel Schadt
c060f9e5c2
allow downloads to be openened directly
...
The file is saved in a temporary directory, which is cleaned up when the
window is closed.
2016-07-12 16:52:01 +02:00
Florian Bruhin
ed5af29ac9
Fix lint
2016-07-11 16:43:06 +02:00
Florian Bruhin
e80475ed57
Remove support for showing JS statusbar messages
...
Closes #1579 .
2016-07-11 16:19:44 +02:00
Florian Bruhin
f46d6cbe27
Fix url_text, take 3
2016-07-11 15:06:36 +02:00
Florian Bruhin
a470bfc3f3
Get rid of url_text_changed signal
...
Instead we simply use url_changed which (similar to Qt's urlChanged)
simply has a QUrl argument.
2016-07-11 14:28:51 +02:00
Florian Bruhin
8567fffdad
Merge branch 'qtwebengine'
2016-07-11 10:56:20 +02:00
Florian Bruhin
b791095324
Rename browser.tab module and classes
2016-07-10 17:27:02 +02:00
Florian Bruhin
cc11af5e28
Fix lint
2016-07-08 11:21:00 +02:00
Florian Bruhin
55784f9783
Add tab.create() helper function
2016-07-08 10:38:52 +02:00
Florian Bruhin
09f4c2199e
Rename widget to tab in some places
...
This also fixes the cur_url access.
2016-07-08 10:08:44 +02:00
Florian Bruhin
2befebaf3a
Don't use properties for AbstractTab
...
Otherwise exceptions in there could be hidden by Python/PyQt.
Some places are not changed yet, as there are also other renames in the
next commits.
2016-07-08 10:05:46 +02:00
Jan Verbeek
a8c55ffe08
Stop downloads bar from pushing away status bar
2016-07-07 23:11:08 +02:00
Florian Bruhin
09f025628f
Use tab.AbstractTab for signals/slots
2016-07-07 18:32:52 +02:00
Florian Bruhin
7444f83dbf
Fix importing of QtWebEngine specific code
2016-07-07 18:32:52 +02:00
Florian Bruhin
17466b4f26
Fix some lint
2016-07-07 18:32:52 +02:00
Florian Bruhin
7b37d85150
Pass modeman as argument to AbstractTab
2016-07-07 18:32:52 +02:00
Florian Bruhin
9c5143786c
Implement scroll.pos_perc for QtWebEngine
2016-07-07 18:32:52 +02:00
Florian Bruhin
78f425c98b
Add AbstractTab.data
2016-07-07 18:32:52 +02:00
Florian Bruhin
a62e2a0c27
Fix :undo
2016-07-07 18:32:52 +02:00
Florian Bruhin
09c3528585
Fix loading of marks
...
This probably broke when merging from master.
2016-07-07 18:32:52 +02:00
Florian Bruhin
86f63e1ae6
Add tab.new_tab_requested signal
2016-07-07 18:32:52 +02:00
Florian Bruhin
b0ba2125a3
Fix :undo
2016-07-07 18:32:52 +02:00
Florian Bruhin
0b88c5d413
Re-implement searching for QtWebKit
2016-07-07 18:32:52 +02:00
Florian Bruhin
90614d1fe3
Initial caret browsing support
2016-07-07 18:32:52 +02:00
Florian Bruhin
34d3d2cda6
Full scrolling implementation
2016-07-07 18:32:52 +02:00
Florian Bruhin
363f3d7ea7
Replace scroll_pos by scroll_pos_px()/_perc()
2016-07-07 18:32:52 +02:00
Florian Bruhin
5b9ae8bc85
Initial history implementation
2016-07-07 18:32:52 +02:00
Florian Bruhin
115021b8ea
Get QtWebEngine to start and work somewhat
2016-07-07 18:32:52 +02:00
Florian Bruhin
b0a391932a
Get qutebrowser to run
2016-07-07 18:32:52 +02:00
Florian Bruhin
048f7dcaf5
Refactor signals
2016-07-07 18:32:52 +02:00
Florian Bruhin
794a275383
Merge branch 'status-position' of https://github.com/blyxxyz/qutebrowser into blyxxyz-status-position
2016-07-06 13:56:55 +02:00
Florian Bruhin
70117265d6
Fix some a/an misspellings
...
Thanks to https://github.com/jwilk/anorack
2016-07-05 08:34:03 +02:00
Jan Verbeek
965459ab36
Add status-position option
...
See #1257 .
I can't think of a good way to do widget-packing because tabs can be on
the left or right.
2016-07-04 18:21:09 +02:00
Florian Bruhin
4ae3df62c5
Handle invalid URLs in :jump-mark
2016-06-30 20:59:18 +02:00
Florian Bruhin
4fccc89d7d
Split browser into browser/browser.webkit
2016-06-13 11:18:21 +02:00
Daryl Finlay
bf32c544a2
Refactor tab and window title update methods
2016-06-10 23:36:43 +01:00
Daryl Finlay
054e9ab439
Add host placeholder to window and tab title formats
2016-06-10 21:59:43 +01:00
Florian Bruhin
4a7a2e61d3
Only do partial matching with main CommandParser
2016-06-06 15:56:56 +02:00
Florian Bruhin
ec869686c2
Get rid of TabbedBrowser.got_cmd
...
Seems like it's not used anywhere anymore
2016-06-06 15:53:33 +02:00
Florian Bruhin
afcb018ee2
Fix some spelling mistakes
...
Found via http://jwilk.net/software/mwic
2016-05-27 12:07:00 +02:00
Nick Ginther
c70accda22
restructure code
2016-05-25 13:46:31 -05:00
Nick Ginther
8c487e9a5f
fix tabindex statusbar not updating ( #1247 )
2016-05-24 15:18:22 -05:00
Stefan Tatschner
1c238152f7
Fix crash when hovering over an invalid URL
2016-05-18 16:20:03 +02:00
Florian Bruhin
d0af80fbd5
Merge branch 'keystring' of https://github.com/rcorre/qutebrowser into rcorre-keystring
2016-05-18 07:33:17 +02:00
Florian Bruhin
02cbc2f986
Merge branch 'pretty-hover-url' of https://github.com/forkbong/qutebrowser into forkbong-pretty-hover-url
2016-05-18 07:27:30 +02:00
Panagiotis Ktistakis
959f777f92
Assert that hovered link generates a valid QUrl
2016-05-17 10:28:33 +03:00
Panagiotis Ktistakis
224c877fec
Hide passwords in hovering URLs
2016-05-15 19:07:10 +03:00
Florian Bruhin
0c1e82a103
Fix lint
2016-05-15 11:53:58 +02:00
Florian Bruhin
a9ab6abafd
Document {url} and {url:pretty} for :set-cmd-text
2016-05-15 11:09:16 +02:00
Panagiotis Ktistakis
c88883fcb3
Decode URL in statusbar when hovering over it
2016-05-14 19:52:24 +03:00
Ryan Roden-Corrent
e7ff717d52
Show key hints for all modes, not just normal.
2016-05-14 12:50:26 -04:00
Ryan Roden-Corrent
8406746889
Show possible keychains from current input.
...
When the current keystring is a partial match for one or more bindings,
show the possible bindings in a small overlay.
The overlay is partially transparent by default, but the background
color is configurable as ui->keystring.bg.
2016-05-14 12:50:26 -04:00
Panagiotis Ktistakis
bb45392c1b
Use the right split function
2016-05-13 19:32:35 +03:00
Panagiotis Ktistakis
ecfa6cfc63
Split arguments using qutebrowser.utils.split
2016-05-13 18:59:24 +03:00
Panagiotis Ktistakis
7488f2a5cb
Remove unused imports
2016-05-13 18:58:42 +03:00
Panagiotis Ktistakis
38edb1b16d
Properly replace variables in set-cmd-text command
...
This fixes #123 and allows variables like {url:pretty} to be used with
set-cmd-text
2016-05-13 18:12:53 +03:00
Daniel Schadt
643d2cc6dd
fix confirm-quit=downloads with finished downloads
...
Issue #846
.rowCount() returns all downloads, even the finished ones that have not
yet been removed from the list. For confirming the quit event, we should
only consider downloads that are still running.
2016-05-08 23:36:31 +02:00
Florian Bruhin
f90776f75c
Add documentation for default_window_icon
2016-05-07 21:37:01 +02:00
Florian Bruhin
2ea76c282e
Merge branch 'feature-#1349' of https://github.com/haitaka/qutebrowser into haitaka-feature-#1349
2016-05-07 21:32:05 +02:00
Florian Bruhin
24cde47881
Merge branch 'marks_invalid_url' of https://github.com/rcorre/qutebrowser into rcorre-marks_invalid_url
2016-04-27 21:00:21 +02:00
Florian Bruhin
2a343cb3a1
Various code style improvements
2016-04-27 20:25:27 +02:00
Ryan Roden-Corrent
88f66874a1
Don't crash when setting mark on invalid url.
2016-04-27 08:10:53 -04:00
Florian Bruhin
37b5f49c85
Fix types in @pyqtSlot decorations
...
PyQt 5.5 enforces correct type signatures, and there were a lot of
places where we were simply wrong, causing qutebrowser to not start at
all...
2016-04-26 20:34:38 +02:00
Florian Bruhin
32d64b1a9a
Merge branch 'undo_crash' of https://github.com/rcorre/qutebrowser into rcorre-undo_crash
2016-04-25 19:19:08 +02:00
Ryan Roden-Corrent
ccd04ca548
Don't crash when undoing twice on default page.
...
Avoid a crash when undoing twice on the default page with last-close set to
default-page.
This was caused by logic to reuse the current tab if it is on the default page
and has no history. The fix is using openurl rather than removeTab/tabopen.
2016-04-21 08:04:20 -04:00
Ryan Roden-Corrent
ae267c466f
Small fixes for marks.
...
Mark two callbacks with pyqtSlot as appropriate.
Return False instead of raising NotImplementedException to avoid pylint
identifying MarkKeyParser as abstract.
2016-04-19 08:28:02 -04:00
Ryan Roden-Corrent
4b00a17d71
Fix MarkKeyParser crash when changing keyconfig.
...
Ensure MarkKeyParser implements on_keyconfig_changed, so it doesn't fail when
rebinding a key. It doesn't have keybindings, so the implementation is just
`pass`.
This also fixes a few flake8 style errors.
2016-04-17 21:04:08 -04:00
Ryan Roden-Corrent
be6308534f
Store both x and y position for marks.
...
Previously only stored/used y.
2016-04-17 21:04:08 -04:00
Ryan Roden-Corrent
49b2f6e967
Move jump_mark logic to TabbedBrowser.
...
This simplifies the MarkKeyParser by removing its dependency on the
commandrunner. It also removes the need for a new exception type.
2016-04-17 21:04:08 -04:00
Ryan Roden-Corrent
e684cfa03f
Trivial fixes for marks based on code review.
...
- Fix a docstring copy-paste
- Add own name/copyright date to new file
- Simplify a bdd expression (no need for regex)
- Scroll to a pixel position in a single operation
2016-04-17 21:04:08 -04:00
Ryan Roden-Corrent
540f4af225
Set the ' mark after following a link.
...
This moves mark storage from CommandDispatcher to TabbedBrowser, so it can also
be accessed by the HintManager.
2016-04-17 21:04:08 -04:00
Alexey Glushko
2645334425
Indent fixing
2016-04-14 17:20:34 +00:00
haitaka
d61ee2681f
set back to the qutebrowser logo in on_load_started
2016-04-14 20:26:00 +06:00
haitaka
de93e6c7ee
remove trailing whitespace
2016-04-13 19:15:01 +06:00
haitaka
b10c1b063d
Site favicon as window icon when 'tabs-are-windows' is enabled
2016-04-13 19:08:50 +06:00
Jimmy
1c10a1aecf
Adds new buffer command with completion.
...
`buffer` takes either a tab index or a string and focuses the specified
tab. The index can be of the form [0-9]+ which will switch to the
relevant tab in the current window or [0-9]+/[0-9]+ (that is
win_id/index) which will focus the specified window before switching
tabs. If a string is passed the list of open tabs across all windows is
sorted based on title and url (just like in the completion widget) and
the top result is selected.
2016-03-31 14:00:36 +13:00
Jimmy
42160335dc
Improve performance when scrolling with many tabs.
...
Closes #1278 .
2016-02-02 07:33:07 +01:00
Florian Bruhin
289891a828
flake8: Check W503 (line break before binary op)
2016-01-22 17:33:58 +01:00
Florian Bruhin
3c625790cc
Don't crash if JS tab is closed twice.
...
Fixes #906 .
2016-01-20 21:24:51 +01:00
Florian Bruhin
9720d879ad
Remove dead code.
2016-01-06 17:52:11 +01:00
Florian Bruhin
a5f2ac5f03
Adjust copyright years.
2016-01-04 07:12:39 +01:00
dylan araps
1bc8d10ac7
Added config option to change tab title alignment
2015-12-07 19:43:43 +11:00
Florian Bruhin
150a83d8f4
pylint: Remove unneeded supressions.
2015-12-01 22:03:58 +01:00
Florian Bruhin
7e6be517e3
Simplify indicator_width code.
2015-11-30 07:09:02 +01:00
Florian Bruhin
7701bf602a
Add --append argument to :set-cmd-text.
2015-11-10 19:21:54 +01:00
Jonas Schürmann
a4aacde88f
Undo: Fix issues with url comparison
2015-10-29 09:36:42 +01:00
Jonas Schürmann
618d9ceabf
Fix PEP 257 violation
2015-10-29 00:52:44 +01:00
Jonas Schürmann
ebe9835e5a
Remove unused tab on undo
2015-10-29 00:22:54 +01:00
Daniel
7a413ad6d5
Remove unneeded functions from TabBar.
...
addTab() and insertTab() are not called and if they were called would
raise an exception (self.set_page_title not defined).
2015-10-23 19:52:56 +02:00
Daniel
8d88dd9d75
Fix crash with small icons
...
Fixes #1015
2015-10-23 19:52:56 +02:00
Nathan Isom
6391da4f6f
Forgot font changes.
2015-10-16 12:02:57 -05:00
Nathan Isom
869e2d9127
missed one.
2015-10-16 11:18:25 -05:00
Nathan Isom
2a11adc8ac
initial replace pass.
2015-10-16 10:52:02 -05:00
Florian Bruhin
743c3b1e26
Fix broken UrlType member.
2015-10-16 06:53:07 +02:00
Nathan Isom
4876bdf7ce
style.
2015-10-14 13:34:41 -05:00
Nathan Isom
d7d4c232d0
Initial shot at issue #691
2015-10-14 13:10:24 -05:00
Jonas Schürmann
1e8170d98b
Fixed lines which were too long
2015-10-06 23:18:04 +02:00
Jonas Schürmann
afc166a13e
Coding style fixes #1002
2015-10-06 22:59:49 +02:00
Jonas Schürmann
45c9768c16
Added --target command line argument #922
...
This argument is used to override the new-instance-open-target config
option.
2015-10-05 21:15:52 +02:00
Florian Bruhin
12a11a5931
Revert "Remove colors -> tabs.bg.bar setting."
...
This reverts commit 801d2ae8e6
.
This is still useful/needed for vertical tab bars.
2015-10-04 17:49:52 +02:00
Florian Bruhin
801d2ae8e6
Remove colors -> tabs.bg.bar setting.
...
This isn't needed anymore after the recent tab width fix, as the tabbar color
is invisible now.
2015-10-04 16:32:45 +02:00
Florian Bruhin
fbf6696e2a
Merge branch 'master' of https://github.com/daniel-lawrence-lu/qutebrowser into daniel-lawrence-lu-master
2015-10-04 16:30:17 +02:00
Florian Bruhin
d229e90724
Fix some splelling mistakes.
2015-10-04 15:41:42 +02:00
Daniel Lu
de5308cbbf
removes leftover space in tab bar when the window width is not divisible by the number of tabs
2015-10-02 23:24:44 -04:00
Florian Bruhin
afa7a1a9a0
Remove broken margin-left for progress bar.
...
Closes #125 (by obsoleting it).
2015-10-02 08:03:10 +02:00
Florian Bruhin
ae3497a3a1
Remove unnecessary str().
2015-09-30 21:26:41 +02:00
Alexey Nabrodov
75d53e2879
and again
2015-09-29 12:19:47 +03:00
Alexey Nabrodov
a98878dd8a
fix unused coords
2015-09-29 12:07:35 +03:00
Alexey Nabrodov
1b6860b748
add scroll_pos to window title && fix signals
2015-09-28 19:43:50 +03:00
Alexey Nabrodov
717298e423
add scroll_pos to title-format
2015-09-25 19:14:52 +03:00
Florian Bruhin
5ba7b5cf0f
Fix lint.
2015-09-19 22:03:56 +02:00
Florian Bruhin
f96de5a598
Add config for tab colors for odd/even sel. tabs.
2015-09-19 21:45:57 +02:00
Florian Bruhin
841e8fbbd1
Save search parameters in tabbed_browser.
2015-09-18 07:01:51 +02:00
Martin Tournoij
a80c61e78a
Use a single search term per-window
...
Previously, every tab had its own search term. This sets single search term per
window. using `/hello`, `gt`, and `n` will search for `hello` in the 2nd tab.
This fixes issue #940
2015-09-18 02:18:54 +02:00
Averrin
3904b7de58
Leave passthrough mode when change tab
2015-09-16 16:44:31 +03:00
Florian Bruhin
16e3bad7af
Hide scroll buttons in vertical tab bar.
2015-08-31 22:00:26 +02:00
Florian Bruhin
8d7249ebc6
Implement statusbar padding.
2015-08-27 22:12:39 +02:00
Florian Bruhin
124099ac4c
Fix docstrings.
2015-08-25 21:18:45 +02:00
Thorsten Wißmann
183a5910de
Fix progressbar height to statusbar height.
...
Formerly, the statusbar height changed when the progressbar was visible.
This was caused by the default font-size of the progressbar text (though
invisible). Overriding the minimumSizeHint() method ignores the
font-size of the hidden text and the statusbar height does not change
anymore.
This fixes the first issue of #886 .
2015-08-25 11:14:52 +02:00
Florian Bruhin
25b43d528c
Clear textbase text properly.
2015-08-12 07:41:06 +02:00
Florian Bruhin
8609663f40
statusbar.textbase: Fix broken text check.
2015-08-12 07:35:24 +02:00
Florian Bruhin
2ab7ad59ee
Fix lint.
2015-08-06 21:19:36 +02:00
Florian Bruhin
3f445ba6ca
Draw favicon at correct position/size.
2015-08-06 21:14:05 +02:00
Florian Bruhin
58a9677af8
Use QFontMetrics instead of QFontInfo.
2015-08-06 21:11:06 +02:00
Florian Bruhin
e1c2250690
Merge branch 'favicon-size-2' of git://github.com/Carpetsmoker/qutebrowser into Carpetsmoker-favicon-size-2
2015-08-06 21:10:11 +02:00
Florian Bruhin
61df5fcd7a
Skip confirm-quit checks when crashing.
...
Fixes #853 .
2015-08-06 21:08:20 +02:00
Florian Bruhin
c6c14e967d
Change Position conftypes to top/bottom/left/right.
2015-08-05 23:37:51 +02:00
Martin Tournoij
58aa1a738d
Favicon sizing is messed up with tabs -> orientation = west #847
...
Here's a patch which seems to work well in my initial testing. We now use the
font size rather than the tabbar size, since the tabbar size is the window
size when it's vertical.
This also works nicer with the new tabs.padding setting (which didn't exist when
I wrote the first patch).
2015-08-05 22:33:24 +02:00
Florian Bruhin
49f017c0dd
Fix mainwindow.statusbar.percentage tests.
2015-08-02 01:53:30 +02:00
Florian Bruhin
d5888fea89
100% coverage for mainwindow.statusbar.progress.
2015-08-02 01:49:33 +02:00
Florian Bruhin
43db9d4526
Fix wrong pyqtSlot type.
2015-08-02 01:42:16 +02:00
Florian Bruhin
6b98158d64
Fix lint.
2015-08-01 22:21:08 +02:00
Artur Shaik
e58735f1d7
'Tabs show' recommendations applied.
2015-08-01 22:21:08 +02:00
Artur Shaik
b4d5f9e7a6
Tabs->show option.
...
Issue #771
Implemted common option for tab bar show strategy.
Options: always, never, multiple, switching.
2015-08-01 22:21:08 +02:00
Florian Bruhin
d04848ac19
Remove unused import.
2015-08-01 00:34:09 +02:00
Florian Bruhin
22ae0c5bca
Don't call setIconSize if height doesn't change.
2015-08-01 00:26:37 +02:00
Florian Bruhin
2c716dbf6c
Merge branch 'favicon-size' of https://github.com/Carpetsmoker/qutebrowser into tabbar-height
2015-08-01 00:22:17 +02:00
Florian Bruhin
fdcb69f5d4
Fix indicator layout and make it configurable.
2015-07-31 18:52:31 +02:00
Florian Bruhin
3083eaa27b
Clean up TabBarStyle._tab_layout.
2015-07-31 18:06:01 +02:00
Florian Bruhin
41eb36148d
Clean up TabBarStyle.drawControl.
2015-07-31 17:59:38 +02:00
Florian Bruhin
f5725ec11e
Use a namedtuple for _tab_layout.
2015-07-31 17:49:18 +02:00
Florian Bruhin
754c31850b
Add configurable tab padding.
2015-07-31 17:24:35 +02:00
Florian Bruhin
041315b65f
Honour right-padding in tabs correctly.
2015-07-31 17:02:42 +02:00
Florian Bruhin
8dcf9fd963
Separate padding/icon padding for tab bar.
2015-07-31 16:55:48 +02:00
Florian Bruhin
776ace2d3f
Clean up comparison.
2015-07-31 16:41:02 +02:00
Florian Bruhin
87d8bfd7a7
Use an enum for custom PixelMetrics.
2015-07-31 16:40:06 +02:00
Florian Bruhin
94b0f92b75
Fix tabs -> last-close = ignore.
...
See #822 / 71fee12b5b
.
Fixes #834 .
2015-07-26 12:08:19 +02:00
Florian Bruhin
5f10a12be9
Use keyword argument for newtab.
2015-07-17 06:39:53 +02:00
Martin Tournoij
71fee12b5b
Always remove the last tab, instead of opening a new page in it.
...
IMHO this makes much more sense; for example, if you close the last tab but then
press u to "undo" it, you'll actually load the second-last tab. To undo you need
H for "back". Other things like gC, session save, etc. also behave in a way that
is, IMHO, unexpected...
I can also make a new option out of this, if you prefer. But I don't think that
many people would expect the current behaviour...
2015-07-16 15:26:15 +02:00
Martin Tournoij
aa909c0506
Fix warnings from tox
2015-07-02 21:07:38 +02:00
Florian Bruhin
7b8490b6c0
Fix 'an user' spelling.
2015-06-29 17:49:19 +02:00
Martin Tournoij
63dae3a885
Set favicon size to tabbar size.
...
Fixes #119 . Also see #754
2015-06-28 00:03:53 +02:00
Franz Fellner
534a85cf8f
Create a new QStyleOptionTab object for each tab.
...
It seems under some circumstances (on Gentoo?), the existing QStyleOptionTab
object was reused, causing subsequent tabs to have the same title as the first
one.
Fixes #778 .
2015-06-24 21:27:37 +02:00
Florian Bruhin
0350d19bd3
Load geometry after completion is initialized.
...
Fixes #766 .
2015-06-18 10:32:07 +02:00
Florian Bruhin
f17131f6c2
Change Qt links to point to qt.io.
2015-06-12 16:59:33 +02:00
Austin Anderson
599f582c20
More specific statusbar styling: resolves #750 .
2015-06-11 08:07:59 -04:00
Florian Bruhin
ab27612139
Merge branch 'more-color-settings' of https://github.com/ProtractorNinja/qutebrowser into ProtractorNinja-more-color-settings
2015-06-10 20:05:23 +02:00
Austin Anderson
34d4c08374
Significantly reduced the size of the bar stylesheet.
2015-06-07 20:13:52 -04:00
Austin Anderson
ebc013ac2a
Removed redundant setter.
2015-06-07 20:13:52 -04:00
Florian Bruhin
def41e70bf
Fix some spelling mistakes.
2015-06-07 01:24:02 +02:00
Florian Bruhin
b55e22b5c3
Refactor key mode/parser handling in modeman.
2015-06-05 15:29:09 +02:00
Martin Tournoij
e22ef776f9
Fix crash when executing "qutebrowser :set".
...
Fixes #720 .
See #721 .
2015-06-01 19:04:21 +02:00
Austin Anderson
5c599879f8
Fixed a line-length error.
2015-05-30 16:03:36 -04:00
Austin Anderson
b59dc8e89b
Merge branch 'master' into more-color-settings
2015-05-30 15:56:11 -04:00
Tobias Patzl
b858b6ac75
call e.ignore()
when the event is not handled
2015-05-26 10:24:32 +02:00
Tobias Patzl
61519e6383
move part of the logic to TabbedBrowser
2015-05-25 20:21:37 +02:00
Tobias Patzl
45dea54e3c
Add setting to disable mousewheel tab switching.
...
See #374 .
2015-05-25 15:23:14 +02:00
Florian Bruhin
f2e2748c59
Fix quotes.
2015-05-18 22:32:17 +02:00
Florian Bruhin
8941b5dc96
Merge branch 'visual'
2015-05-18 21:43:25 +02:00
Florian Bruhin
dd292b0781
Don't depend on objreg for CommandDispatcher.
...
See #640 .
2015-05-18 21:34:00 +02:00
Florian Bruhin
d992caf8fc
Clean up statusbar caret handling.
2015-05-13 22:44:37 +02:00
Florian Bruhin
a728704cce
toggle-selection cleanup
2015-05-13 21:52:42 +02:00
Florian Bruhin
e62ba57291
Always save last window session.
...
len(objreg.window_registry) can actually lag behind because single-shot QTimers
are used to remove the windows from the registry - but actually it doesn't even
matter if this is the last window or not. We just always save to
SessionManager._last_window_session, and it gets used in SessionManager.save.
Fixes #650 .
2015-05-12 21:04:18 +02:00
Austin Anderson
229733f1b0
Properly distinguish between statusbar modes when styling line input.
2015-05-11 22:46:26 -04:00
Austin Anderson
14c1332017
Reordered statusbar stylesheet to match configuration ordering.
2015-05-11 22:28:12 -04:00
Austin Anderson
1a2a57d59e
Added command mode color configuration options.
...
Including necessary tracker variable _command_active.
2015-05-11 22:27:21 -04:00
Florian Bruhin
a36c0fcd4c
Fix lint.
2015-05-11 20:32:27 +02:00
Florian Bruhin
d3c6ebcf15
Rename caret_selection to caret-selection.
2015-05-11 20:21:01 +02:00
Austin Anderson
69f729dbe5
Added foreground color settings for statusbar messages.
2015-05-09 18:07:40 -04:00
Artur Shaik
778ad5df3a
Comment clean.
2015-05-07 12:23:33 +06:00
Florian Bruhin
deb3c31f2f
Merge branch 'refactor'
2015-05-06 21:51:04 +02:00
Florian Bruhin
024549e3b0
Use a namedtuple for authentication prompts.
2015-05-06 11:05:17 +02:00
Artur Shaik
489c913e58
Implement caret selection and positioning
...
Added option to webview for selection enabled caret mode.
In status bar checking value of this option to identificate about it.
Added bindings: <Space> for toggle selection mode, <Ctrl+Space> drop
selection and keep selection mode enabled.
In webview added javascript snippet to position caret at top of the
viewport after caret enabling. This code mostly was taken from cVim sources.
2015-05-05 12:21:48 +06:00
Florian Bruhin
d3a7b2e4ca
Big refactoring of app.py.
2015-04-30 07:37:25 +02:00
Florian Bruhin
32562c6878
Fix lint.
2015-04-28 16:50:42 +02:00
Florian Bruhin
640f758605
Merge branch 'master' into visual
...
Conflicts:
qutebrowser/browser/commands.py
2015-04-28 15:54:26 +02:00
Florian Bruhin
844473e47a
Fix /-foo searches.
2015-04-24 17:25:53 +02:00
Florian Bruhin
6c8e073dc8
Merge branch 'caret_visual_mode' of https://github.com/artur-shaik/qutebrowser into visual
...
Conflicts:
qutebrowser/browser/commands.py
qutebrowser/browser/webview.py
qutebrowser/config/configdata.py
2015-04-21 21:29:00 +02:00
Florian Bruhin
42577b454b
Fix download view popping up as window on start.
...
This is a regression introduced in cc2c7c09ea
as
show() was called before the downloadview was added to the mainwindow vbox.
See #575 .
2015-04-19 17:30:58 +02:00
Florian Bruhin
4436941d97
Clean up unused imports.
2015-04-17 08:00:56 +02:00
Florian Bruhin
ffd1e673b3
Get rid of SearchRunner.
...
A SearchRunner was per-mainwindow, which caused bugs when searching in a tab
and in another before clearing the search.
Instead we now split it between WebView/CommandDispatcher.
Fixes #638 .
2015-04-17 07:51:21 +02:00
Artur Shaik
a6443231e5
Add statusbar coloring for caret and visual modes
2015-04-13 19:50:27 +06:00
Florian Bruhin
c071bcbec8
Clean up loggers.
2015-04-13 08:49:04 +02:00
Florian Bruhin
f77ba5744b
Add a ui -> hide-mouse-cursor option.
2015-04-09 19:59:16 +02:00
Artur Shaik
695712e50c
Basic caret and visual modes implementation
...
Allow user switch in caret mode for browsing with caret, and visual mode
for select and yank text with keyboard.
Default keybindings is c or v for caret mode, and again v for visual mode. All
basic movements provided by WebAction enum implemened with vim-like
bindings. Yanking with y and Y for selection and clipboard respectively.
There is bug/feature in WebKit that after caret enabled, caret doesn't
show until mouse click (or sometimes Tab helps). So I add some workaround
for that with mouse event. I think should be better aproach.
Signed-off-by: Artur Shaik <ashaihullin@gmail.com>
2015-04-09 22:55:42 +06:00
Joel Torstensson
12c83b721f
Fixed some style errors.
2015-04-09 12:49:32 +02:00
Joel Torstensson
cc2c7c09ea
Changing position without restart now possible.
2015-04-09 11:47:35 +02:00
Joel Torstensson
2fa66ba250
Added option for downloadview placement.
2015-04-09 11:44:59 +02:00
Florian Bruhin
1345a13a71
Add startpage/default-page to tabs -> last-close.
2015-04-07 17:36:19 +02:00
Florian Bruhin
46d1760798
Keep progress bar height fix on multiline text.
...
See #364 and #63 .
2015-04-06 14:27:41 +02:00
Florian Bruhin
25fca03dca
Don't double ampersands in window title.
...
Fixes #599 .
2015-04-03 20:04:44 +02:00
Florian Bruhin
6917c3b32d
set-cmd-text: Add -s/--space argument.
...
We need this because quotes are ignored now, so there'd be no way to set the
text to ":open -t " for example.
2015-04-03 19:07:29 +02:00
Florian Bruhin
7e51addeb0
Fix :set-cmd-text with empty argument.
2015-04-03 14:42:19 +02:00
Florian Bruhin
84b9d34a7f
Fix lint.
2015-04-02 11:57:56 +02:00
Franz Fellner
3d3324ccfa
Add TabIndex label to the statusbar.
...
It shows the current tab index and the number of tabs of the windows it
sits in.
2015-04-02 11:55:42 +02:00
Florian Bruhin
8ebac8d38c
Various spelling fixes.
2015-03-31 21:11:47 +02:00
Florian Bruhin
74892ac8e4
Initialize completions lazily and only once.
...
Before, we initialized the completions once for every window spawned, which was
a waste of CPU-time and RAM.
Now we only initialize them once, when the user uses the completion for the
first time.
2015-03-13 16:25:13 +01:00
Florian Bruhin
e8e6d8409b
Adjust pylint exceptions.
2015-03-11 20:14:39 +01:00
Florian Bruhin
596bff0772
Don't try to add tab repr in TabDeletedError.
...
This will always fail with another RuntimeError...
2015-03-10 22:16:41 +01:00
Florian Bruhin
8307b546b7
Adjust prompt size hint based on content.
...
See #26 .
Fixes #506 .
Related to 06cc982ab5
.
2015-03-09 19:35:50 +01:00
Florian Bruhin
2c9b5f24fc
Use _shutting_down instead of disconnecting signal
...
This will most likely cause less pain than disconnecting the signal, which
seems to be broken on OS X.
2015-03-06 16:29:04 +01:00
Florian Bruhin
7c125642b9
Hide "Error while shutting down tabs" message.
...
This makes no sense at all, yet seems to happen when closing qutebrowser on OS
X via Cmd+Q.
2015-03-05 21:46:56 +01:00
Florian Bruhin
801f6b2667
Fix handling of signals with deleted tabs.
2015-03-03 23:22:29 +01:00
Florian Bruhin
5b33f6c5fe
Re-add save-session setting.
2015-02-17 07:45:06 +01:00
Florian Bruhin
56b0ae2b6e
Get rid of mainwindow.MainWindow.spawn.
2015-02-16 22:56:12 +01:00
Florian Bruhin
8f1d81a644
Add session support.
...
Closes #12 .
See #499 .
See #11 .
This adds PyYAML as a new dependency.
It adds the following new commands:
:session-delete <name>
Delete a session.
:session-load <name>
Load a session.
:session-save [<name>]
Save a session.
:wq [<name>]
Save open pages and quit.
And the following new settings:
general -> save-session:
Whether to always save the open pages.
2015-02-16 20:26:09 +01:00
Florian Bruhin
66d3ec1c08
Make it possible to configure tab titles.
2015-02-13 23:57:31 +01:00
Florian Bruhin
a38a77b16b
Fix searching for terms starting with a slash.
...
Fixes #507 .
2015-02-13 22:27:21 +01:00
Florian Bruhin
44b21374cb
Fix :tab-clone.
...
We checked for None when getting the QColor, but now with the Python dict
instead of a QVariant that's a KeyError.
This is a regression introduced in 3cf9768f21
.
2015-02-13 19:33:53 +01:00
Florian Bruhin
3cf9768f21
Use a dict for tab data instead of a single value.
2015-02-13 18:59:59 +01:00
Florian Bruhin
43c5dc3bf6
Refactor saving logic, only save stuff if modified.
...
Fixes #113 .
See #11 .
2015-02-01 00:43:07 +01:00
Florian Bruhin
6bf87dd1d7
Fix statusbar quickly popping up as window.
2015-01-30 11:36:07 +01:00
Florian Bruhin
66ec4f0599
Resize completion when it's shown, and only then.
...
Before this, we always resized the completion when the mainwindow was resized.
If the statusbar is hidden during the resize (ui -> hide-statusbar is true), we
got an invalid calculated QRect for the completion, causing the update to be
not applied at all - so the completion showed up incorrectly.
With this change, another resize is done when the completion is shown - at this
point it's certain the statusbar is visible. Also we only update it while it's
shown - it doesn't make sense to always adjust its size when it's hidden
anyways.
2015-01-28 22:16:22 +01:00
Florian Bruhin
81b91888f4
Add logging to completion resizing.
2015-01-28 22:15:57 +01:00
Florian Bruhin
b9f16804f7
Make the window title configurable.
...
Closes #489 .
2015-01-28 08:40:16 +01:00
Florian Bruhin
d90814aabe
Fix restoring of cmd widget after an error.
...
We accidentally restored the prompt widget instead of the command widget when
an immediate error message interrupted command mode.
Fixes #487 .
2015-01-27 21:18:24 +01:00
Florian Bruhin
ab2d2d79ca
Clone text/icon as well when cloning tabs.
...
Closes #316 .
2015-01-26 07:18:07 +01:00
Florian Bruhin
cd39be62ee
Show loading percentage in window title.
2015-01-25 23:25:08 +01:00
Florian Bruhin
fe90b153ed
Add new option ui->hide-statusbar to hide the bar.
...
Closes #486 .
2015-01-25 22:41:19 +01:00
Florian Bruhin
8ffc1a3966
Change tabwidget calls from autohide to _tabhide.
2015-01-25 22:29:20 +01:00
Florian Bruhin
0d93d1eaff
Minor style fixes.
2015-01-24 18:10:24 +01:00
ZDarian
62adc5ffe3
remove extra newline
2015-01-23 20:46:52 -07:00
ZDarian
a08b814e5f
Accidentally left in print() used for testing
2015-01-23 06:35:06 -07:00
ZDarian
00f67135ae
Fixed tabbar visibility update
2015-01-23 06:34:01 -07:00
ZDarian
ef5412f596
tab *-hide -> tab hide-*
2015-01-21 20:50:30 -07:00
ZDarian
335f72a93f
perm-hide -> always-hide
2015-01-21 07:27:08 -07:00
ZDarian
52afa1a479
Added permanent (count-independent) tab hide according to perm-hide variable.
2015-01-18 07:39:26 -07:00
Florian Bruhin
223f8f243e
Make it possible to display warnings in the bar.
...
Closes #114 .
2015-01-15 22:29:00 +01:00
Florian Bruhin
a412814dee
Enter KeyMode.normal directly in ModeManager.
...
We used to enter KeyMode.none and then with a zero-time singleShot QTimer enter
the normal mode. This doesn't really make sense, and caused an exception if a
keypress was processed before the timer fired.
Fixes #433 .
2015-01-09 21:49:39 +01:00
Florian Bruhin
dda54a2cc9
Merge branch 'download-quit-confirm' of https://github.com/peterlvilim/qutebrowser into peterlvilim-download-quit-confirm
2015-01-06 11:28:16 +01:00
Peter Vilim
f828e554f7
misc fixes
2015-01-06 04:03:21 -06:00
Peter Vilim
0305dedbfb
Use multiple lines for quit messages
2015-01-05 01:01:22 -06:00
Florian Bruhin
b8a04f5309
Don't raise CommandError in TabbedBrowser.current_url.
...
TabbedBrowser.current_url used to process the qtutils.QtValueError exception
and raise a cmdexc.CommandError based on it. While this was useful for some
callers, it made handling it in others weird, and it doesn't really belong
there - so now the caller handles this.
2015-01-04 20:13:25 +01:00
Peter Vilim
8a3aca63b0
Confirm quit if downloads running
2015-01-04 04:35:27 -06:00
Florian Bruhin
450d1ab70d
Update copyright years
2015-01-03 15:51:31 +01:00
Florian Bruhin
ad6065605a
Merge branch 'master' of https://github.com/oed/qutebrowser into oed-master
2014-12-29 21:58:51 +01:00
Florian Bruhin
73d08cb60c
Fix mode handling with multiple javascript prompts.
...
This fixes a regression introduced in 03ac8874ff
.
2014-12-28 01:28:35 +01:00
Florian Bruhin
89c7f3ecfe
Re-focus web view when leaving prompt/yesno mode.
2014-12-28 00:41:50 +01:00
Florian Bruhin
03ac8874ff
Rewrite keymode handling to use only one mode.
...
Fixes #417 .
Fixes #418 .
See 4ab5d2df28
.
2014-12-28 00:01:27 +01:00
Florian Bruhin
0c5aed284b
Fix popping of a dead question in prompter.
...
This happens when a question for a file path for an already cancelled download
gets popped.
Fixes #415 .
2014-12-26 12:46:53 +01:00
Joel Torstensson
8746715bf0
Moved fullscreen method.
2014-12-22 22:56:52 +01:00
Florian Bruhin
42890b8a7f
Force tabs to be focused on :undo.
...
Closes #394 .
2014-12-21 13:06:24 +01:00
Florian Bruhin
06ec1a3885
Big file tree reorganisation.
...
Closes #255 .
Should make a lot more sense now ;)
2014-12-13 17:28:50 +01:00