The current tox build will not pull in a recent enough setuptools
version, causing test failures in Travis. Explicitly require and
install a newer version of setuptools.
All of the tests can be run through an environment configured with
setuptools. This has the advantage of also ensuring that the setup.cfg
is properly configured to allow us to run all of the tests.
When the battery widget was flipped from using manual ticking to using
the threadedpolltext base, the `update_delay` parameter that the battery
widget had been using was not updated to the correct value of
`update_interval`.
`setup.py` is creating qtile's man pages and trying to copy them to /usr/man, requiring root permissions. This breaks installing qtile inside a virtualenv for isolation or testing.
In my opinion, putting the files inside /usr/man should be done by the operating system package manager or by a during `make install`.
The battery widget was not properly calling the correct super class
init function. This is actually a pretty good example of why we might
want to change all of these by-hand super calls over to actually use
super. For now, just fix the call.
Change the type annotations to a Python 3.5 supported syntax. This is
currently all that is needed to be Python 3.5 compatible. If there are
more substantive changes that we want to make in the future that are
Python 3.5 incompatible, we can look at those going forward.
Fixes: #1292
Previously, the battery widget had been using its own logic to do
polling and rescheduling. Move the battery widget over to using the
built-in ThreadedPollText behavior instead.
Rewrite of the battery monitoring widget to provide a clear interface
for battery monitoring. This should simplify adding support for other
operating systems.
This also adds support for FreeBSD.
With the changes to use the default config, we were pulling in
`follow_mouse_focus`, which was changing the focusing behavior when
running the tests. Explicitly set this value to False in the effected
tests.
Similar to the previous commit, let's copy over the default attributes.
Somehow this one is a one-off that doesn't use any of the typical
infrastructure.
Signed-off-by: Tycho Andersen <tycho@tycho.ws>
The recent cursor_warp fix meant that now some of the test code configs
need cursor_warp. It's a pain in the ass to add unrelated variables to the
test configs every time we add a new config variable, and it trips a lot of
people up.
Instead, let's just copy everything that doesn't already exist over from
the default config, so nobody has to mess around with this any more.
Signed-off-by: Tycho Andersen <tycho@tycho.ws>
In the case of a screen change, we're changing the window focus, so we should
warp the cursor to the middle of the newly selected window.
Signed-off-by: Tycho Andersen <tycho@tycho.ws>
Seems like this one slipped under the radar, but let's also convert this to
snake_case, since we did it everywhere else and broke things :)
Signed-off-by: Tycho Andersen <tycho@tycho.ws>
/home/travis/build/qtile/qtile/test/test_bar.py:242:10: N806 variable 'DBar' in function should be lowercase
we could change this one if we wanted, but given that it's a class, it
seems reasonable to leave it. feel free to change this if you want :)
Signed-off-by: Tycho Andersen <tycho@tycho.ws>