LittleBrotherTaskbar
is a simple application which can be installed into the tray of the window manager
to display the remaining play time of the current user.
The taskbar does not have a homepage of its own. It is sharing LittleBrother
's homepage. Visit the project
at Facebook or write comments to little-brother(at)web.de.
The following screenshots show the display of LittleBrotherTaskbar
when optional play time is not active.
These are the corresponding screenhots when optional play time is active.
See here
Status | Master | Release |
---|---|---|
CircleCI | ||
Test Coverage | ||
Snyk Vulnerability | not available | |
Snyk Package Health | not available | |
Codacy Code Quality | not available | |
Code Climate | not available |
Note: The vulnerability status is derived from the Python PIP packages found in requirements.txt
.
LittleBrotherTaskbar
has the following features:
-
Shows the status (remaining play time) of a user monitored by LittleBrother on Linux and Windows systems.
-
Plays spoken notifications about the status:
- Session length upon login
- Reason why login is denied
- Warnings about impending logout
- Reason why user will be logged out
-
As of version 0.1.18 (see feature issue):
- Shows the remaining "optional time" that a user can use to extend her time
- Provides buttons to extend the session time (that is to request a time extension)
LittleBrotherTaskbar
requires an active installation of LittleBrother.
The taskbar client will contact the master process of LittleBrother
. Also, some Linux packages have to be
installed to enable the compilation of the Python PIP package wxPython
. See the installation instructions below.
In case you want to use the MP3 speech generation for notification messages you have to install the PIP package python-google-speak.
Distribution | Version | Comments | Most Recent Test |
---|---|---|---|
Debian | testing | 15.AUG.2021 | |
Ubuntu | 19.3 | 08.AUG.2020 |
This guide will take you through the steps required to install, configure, and run the LittleBrotherTaskbar
application on your system.
There are more videos related to LittleBrother
and LittleBrotherTaskbar
available at
the LittleBrother homepage.
LittleBrotherTaskbar
is available as a Python3 PIP package. Make
sure you have the Debian packages
libgtk-3-dev
libpulse-dev
installed on your system. Also, the required library wxPython
cannot be compiled successfully with some versions of
the setuptools
. Version 40.8.0
seems to work fine. Issue
pip3 install setuptools==40.8.0
to install exactly this version. Then type
pip3 install little-brother-taskbar
to install the latest version of the taskbar. If you want to install a specific version use
pip3 install little-brother-taskbar==[VERSION]
instead with [VERSION]
replaced by the specific version.
Note: Compiling the wxPython
library takes a LONG time. Depending on the speed of your system, compilation
times of up to 15 minutes are not unusual. So, please, be patient!
In order to use the speech generation for notification messages, issue the command
pip3 install python-google-speak
and use the --speech-engine
command line option (see below). Also, install the Debian package mpg123
:
apt-get install mpg123
In its simplest setting the tool just needs to be started with the URL of the LittleBrother master API, e.g.
run_little_brother_taskbar --server-url=http://[HOSTNAME]:[PORT]
with [HOSTNAME]
being the host where the LittleBrother master process is running and [PORT]
being its port.
The tool recognizes the following extra options:
-
--username [NAME]
: Set the username to[NAME]
. If the option is not given the tool will try to derive the login name from the environment variableUSER
. If no user can be found, the tool will fail. -
--locale [LOCALE]
: Set the locale to[LOCALE]
, e.g.en_US
. Note that this locale is only used until the taskbar receives the first status from the LittleBrother master since status contains the locale configured for the user. -
--config [FILENAME]
: Read the configuration file[FILENAME]
. If this option is not given the tool will try to read the file~/.config/LittleBrotherTaskbar.conf
. See this file for an example. -
--loglevel [LEVEL]
: Set the log level toDEBUG
,INFO
,WARNING
, orERROR
. -
--speech-engine [ENGINE]
: Activate and select the speech engine to speak messages for the monitored user. Possible values for[ENGINE]
are:google
(preferred; which requires PIP package python-google-speak) orexternal
(which requires the Debian package festival and possibly some more configuration)
Once you have succeeded starting the tool on the command line (see above) it makes sense to install the tool as a startup application in your desktop environment. Most environments allow you to configure the applications which are automatically started upon logging into the desktop. Below you will find screenshots to guide you through the installation on a 19.3 Ubuntu system using the Mate Desktop.
-
From the main menu choose the entry
Control Center
. In the upcoming window click onStartup Applications
. -
Click on
Add
and enter your statement into theCommand
field. Chose a name and optionally set a comment. -
Click on
Add+
and and onClose
. -
Logout out of the desktop and login in again to test. If successful you should see the LittleTaskBar icon in the tray.
On a Windows system some additional configuration needs to be done most of which relates to the audio playback. Since
the tool mpg123
is not available and the default Windows Media player is a little difficult to handle from the command
line it is recommended to install the media player vlc.
If the file %userprofile/.config/LittleBrotherTaskbar.conf
does not exist yet, create it with a text editor and
add the following lines:
[AudioHandler]
audio_player=mpg123
mpg123_binary=C:\Program Files\VLC Plus Player\vlc.exe
play_command_pattern={binary} --intf dummy {filename}
We are abusing the mpg123
driver to configure the vlc
binary. The path in mpg123_binary
may have to be adapted
to your specific installation of vlc
. The option --intf dummy
will force vlc
to start without a GUI frontend.
As of June 2022, the module wxPython
is only available as a pre-compiled package for Python 3.9 and older. On a
Python 3.10 system you will have to compile the module yourself which can be a real nuisance on any system and
is definitely so on Windows. So, if you do not have any other need for a Python 3.10 interpreter it is strongly
recommended to use Python 3.9.
So, you went through all of the above but LittleBrotherTaskbar
does not seem to work? Maybe this
troubleshooting page can help you.
Most settings of the application can be configured using the configuration dialog which reached using the right mouse click on the tray icon:
The configuration will be saved to (and subsequently loaded from) the file ~/.config/LittleBrotherTaskbar.conf
.
The application LittleBrotherTaskbar
is far from perfect. Issues are listed on GitHub
(see here). Feel free to open new issues if you have
any trouble with installing and/or running the application.
The application little_brother_taskbar
uses the wxPython package to interact with the
XWindows system including
the system tray functionality. Unfortunately, the specification for the latter varies across the windows managers and
their versions. In modern versions of Gnome, for example, the tray icons provided by wxPython are no longer supported.
However, there is a Gnome extension called TopIcons Plus
which can be installed using a Debian package which shows all "old-fashioned"
tray icons in the modern Gnome toolbar at the top of the screen.
Follow these steps:
-
As
root
open a shell and install the extension:apt-get install gnome-shell-extension-top-icons-plus
-
Log out of the X session.
-
Log into a new X session as the monitored user using the Gnome Desktop.
-
Verify that there is at least the Little-Brother icon visible in the top center toolbar.
This extension may actually make other icons of installed applications visible which are using the old tray API. Be prepared for a surprise.
The application uses the PIP package Flask-Babel
to provide internationalization for the web frontend, Currently,
the following languages are supported/prepared (in the order they were made available):
Note that the spoken messages are provided by the LittleBrother
master process. Check
here for the availability of desired foreign language.
- Sample 1 in Dutch
- Sample 2 in Dutch
- Sample 1 in Italian
- Sample 2 in Italian
- Sample 1 in Finnish
- Sample 2 in Finnish
- Sample 1 in Turkish
- Sample 2 in Turkish
- Sample 1 in Russian
- Sample 2 in Russian
- Sample 1 in Japanese
- Sample 2 in Japanese
- Sample 1 in Bangla
- Sample 2 in Bangla
- Sample 1 in French
- Sample 2 in French
- Sample 1 in Thai
- Sample 2 in Thai
- Sample 1 in Danish
- Sample 2 in Danish
- Sample 1 in Spanish
- Sample 2 in Spanish
Your help with translations is greatly appreciated. Please, contact the author if you are interested in providing a translation. You do not necessarily have to clone this repository or be familiar with Python to do so.
-
Thanks to all the people maintaining the wonderful script language Python and the libraries on PyPi.
-
The country flags were taken from www.countryflags.com.
-
See the section about on internalization for credits regarding the translations.
-
The site www.mehr-schulferien.de maintains the vacation metadata for Germany.
-
The configuration dialog was generated using wxGlade.
-
People contributing by providing pull requests:
- Albano Battistella for providing Italian and French translations