Giter Club home page Giter Club logo

tos-desktop-environment's Introduction

Build Status repo Contributors Forks Stargazers Issues GPL License


Logo

TOS Desktop Environment

A desktop environment build ontop of awesome wm
Explore the docs »

View wiki · Report Bug · Request Feature

Donate with PayPal

Table of Contents

About The Project

Built By

Getting Started

To get a local copy up and running follow these simple steps.

Prerequisites

TDE depends on a lot of different tools and projects. A list can be found here

desktop

Installation

  1. Install dependencies
tos -S tde xorg-server-xephyr
# For unit tests
tos -S lua53-busted

if you are using an arch based distro that is not tos add the following repo to /etc/pacman.conf

[tos]
Server = https://repo.odex.be
  1. Clone the repo
git clone https://github.com/ODEX-TOS/tos-desktop-environment.git
  1. Set the required files in the appropriate locations
sudo mkdir -p /etc/xdg/tde
sudo cp -r tos-desktop-environment/tde/* /etc/xdg/tde
  1. Use wm-debug for easier development
git clone https://github.com:ODEX-TOS/wm-debug.git
cd wm-debug
# prepare the wm-launch settings etc
sudo ./wm-launch -i

# you can now access wm-launch from everywhere
# the -r 100x720 will create a screen of that size with TDE inside of it
wm-launch -r 1080x720

Usage

TDE has an entire wiki which explains most in detail. It can be found here The README helps you into figuring out how to help and how to get started

We have three major directories

  • tos contains the configuration files of TDE - this directory contains example conf files (the real once are stored in ~/.config/tos)
  • plugins contains example plugins for TDE (the real once are stored in ~/.config/tde)
  • tde the source code of the desktop environment

Unit Test

You can run unit tests by executing the following command in the root project directory

bash test-runner.sh

You can also get the JUNIT output by executing the following (t will be saved in result.xml)

bash test-runner.sh result.xml

Alternative unit testing output is also available

RUNNER="tap" bash test-runner.sh

Docker

You can also run the test suite using the tos docker image We have provided an image on top of that located in `tests/Dockerfile`` You can build and run it like this:

# build the image
docker build -t "tde-test-suite" tests

# run the test suite
docker run -v "$(pwd):/data" tde-test-suite

Alternatively we have provided a docker-compose file that does this all for you

docker-compose up

Profiling

When developing you can also perform some profiling. The TDE profiler listens for function calls and counts how many times the happen. For each function call we measure the time it took. This way we can have educated guesses where the time gets spent the most. Thus improving performance in the most critical parts of the system.

Profiling can be done by executing the following command:

bash profiler.sh --help
# for example profile tde (for 10 seconds) and return the top 100 functions (in terms of cpu time)
bash profiler.sh -t 10 -F 100
# Same as above but use realtime instead of cpu time
bash profiler.sh -t 10 -F 100 -r

# Save the result to tde-functions.result
bash profiler.sh -t 10 -o tde-functions.result

# Run the profiler on a file
bash profiler.sh -f tests/scripts/full

Hot Reload Widgets

You can also quickly develop widgets for tde this can be done through the hot-reload-widget.sh file Note that you need to have inotify-tools installed. If you are using the TOS operating system, this script will auto download it for you.

Development using this script is as followed:

  1. create a .lua file in our example we will use hello.lua
  2. The bare minimum for this file should be the following:
local wibox = require("wibox")
return wibox.widget.textbox("hello")
  1. Run the script on this file
bash scripts/hot-reload-widget.sh hello.lua # replace hello.lua with your file
  1. develop your widget/plugin

NOTE: The file you are developing on needs to return a wibox.widget object Otherwise TDE doesn't know how to display it

Second NOTE: the script listens for filesystem event and reloads your widget each time it is changed

Some people don't like that the hot-reloaded widget consumes the entire space. If that is the case then use the -s option this will make the widget consume 50% of the screen instead of everything. (This issue is not present with multi monitor setups)

closing the widget

We don't use the Escape key to close the widget This is because we would need to consume the Escape key. This would result it the underlying widget from not being able to capture this event. Thus we decided to strictly use the backdrop/close button to close the widget.

Commit hooks

Before creating commits you need to setup commit hooks. These commit hooks perform a series of checks to make sure you didn't forget something important

This ranges from linting, license checks, correct usage of branching etc

It is not mandatory to use this feature, however it will make it more likely to be allowed.

Setting the commit hooks is as easy as executing the following commands from the project root:

ln -s "$PWD"/hooks/pre-commit .git/hooks/pre-commit
ln -s "$PWD"/hooks/commit-msg .git/hooks/commit-msg
ln -s "$PWD"/hooks/pre-push .git/hooks/pre-push
ln -s "$PWD"/hooks/prepare-commit-msg .git/hooks/prepare-commit-msg

Roadmap

See the open issues for a list of proposed features (and known issues).

Contributing

Contributions are what make the open source community such an amazing place to be learn, inspire, and create. Any contributions you make are greatly appreciated. First ensure you have read the wiki especially the style guide page

  1. Fork the Project
  2. Create your Feature Branch (git checkout -b feature/AmazingFeature)
  3. Commit your Changes (git commit -m 'Add some AmazingFeature')
  4. Push to the Branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

License

Distributed under the MIT License. See LICENSE for more information.

Contact

Tom Meyers - [email protected]

Project Link: https://github.com/ODEX-TOS/tos-desktop-environment

Acknowledgments

tos-desktop-environment's People

Contributors

actionless avatar aignas avatar aire-one avatar anrxc avatar asido avatar blueyed avatar calmarc avatar cortesi avatar dodo avatar ebfe avatar elv13 avatar f0xedb avatar farhaven avatar fmorency avatar jd avatar juw avatar koniu avatar lucas7211 avatar lukash avatar madcoder avatar madman2003 avatar mergify[bot] avatar ndim avatar ntarmos avatar psychon avatar restyled-commits avatar sclu1034 avatar sigprof avatar veratil avatar yeban avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

tos-desktop-environment's Issues

Settings application allow disconnecting from bluetooth device

Currently we can connect to a bluetooth device.
However when we are connected there is currently no way to know that we are connected.
There should be an indication in the ui that we are connected and also allow for the possibility to disconnect from the device.
Without removing/unpairing it like the current option.

Add ip address information

In the connections tab of the settings app add a new field that tells you your IP address with perhaps the gateway information. This way you can quickly find your local IP address

Memory leak in the music widget

The music widget tries to fetch the cover art from a given url and generates an image based on that.
Each time this image is added a bit of memory gets consumed.
Once the image updates the previous still remains in memory.

That image should get garbagecollected (ps running garbagecollect("collect") doesn't work)

LIB-TDE: Add i18n support

Develop a new package in lib-tde that implements i18n support.

The API could look something like this (keep in mind that plugins could also use this API, so an extensible translation layer must be present):

-- requiring auto detects the current system language
local i18n = require("lib-tde.i18n")

-- default language is English (in case no language or match is found)
-- The path as a second argument holds the directory containing all translations
i18n.init("en", "/etc/xdg/awesome/translations")

-- translation happen like this
i18n.translate("This is some text in English") -- If the locale is dutch it becomes -> Dit is wat text in het Nederlands


i18n.translate("day") -- If the locale is dutch it becomes -> day (because it doesn't exist yet in the translations)


-- A plugin could add custom translations if they want
i18n.custom_translations({
hello = "hallo",
day = "dag",
})

i18n.translate("day") -- If the locale is dutch it becomes -> dag

Imagine the language is dutch (nl_be)
The file describing all translation could be named /etc/xdg/awesome/translations/nl_be.lua
With the following content

local translations = {}

-- translate from the base language to dutch
translations["This is some text in English"] = "Dit is wat text in het Nederlands"
translations["Working"] = "Werken"
translations["Calculator"] = "Rekenmachine"

return translations

The i18n library would look something like this:

local filehandle = require("lib-tde.file")

local system_language = "en"
local translations = {}

local function detect_system_language()
    - TODO: perform dynamic detection
    system_language = "en"
end

local init(default, path)
   -- TODO: notify API user that the init was invalid
   if not filehandle.dir_exists(path) then return end

   detect_system_language()
   local translation_file = path .. "/" .. system_language

   -- TODO: notify API user that the init was invalid
   if not filehandle.exists(translation_file) then return end

   -- TODO: require doesn't take a path as input -> it needs to be converted using package.path and the file itself
   translations = require(translation_file)
end

function translate(str)
   if translations then
       return translations[str] or str
  end
  return str
end

-- The plugin authors can add custom translations
function custom_translations(table)
    for k,v in pairs(table) do 
        translations[k] = v 
    end
end

-- This function is needed so plugin authors can require the correct language translations
local function getLanguage()
    return system_language
end

return {
   init = init,
   translate = translate,
   custom_translations = custom_translations,
   system_language = getLanguage
}

Plugin authors would use i18n as followed

-- i18n is exposed to the plugin authors without needing to redeclare it
-- They can already use default translations
i18n.translate("Calculator")

-- They can also add custom translations to the current language
if i18n.system_language() == "nl_be" then
    i18n.custom_translations({
    hello = "hallo",
    day = "dag",
    })
else if i18n.system_language() == "fr"
    i18n.custom_translations({
    hello = "bonjour",
    day = "journée",
    })
end

-- If the locale is dutch it becomes -> dag
-- If the locale is french it becomes -> journée
-- If it is any other language it becomes -> day (default)
i18n.translate("day") 

Decreasing the screen amount crashes some wiboxs

When using either Mod+R or going into the settings application -> display settings -> Screen Layout
You can select multi monitor setup (not duplicate) for example eDP + DisplayPort-1
Then multiple screens appear and everything seems to work.

Now revert back to a single screen (for example eDP)
Then all wiboxes attached to the second screen no longer have a place to be drawn from.
These should be removed and cleaned up so we no longer throw any more errors

Error: Error during a protected call: /home/zeus/.config/awesome/module/titlebar/init.lua:232: invalid o...

Sentry Issue: TDE-3Q

Error: Error during a protected call: /home/zeus/.config/awesome/module/titlebar/init.lua:232: invalid object

  ?, in __index
  File "/home/zeus/.config/awesome/module/titlebar/init.lua", line 232, in get_dominant_color
    local content = gsurface(client.content)
  File "/home/zeus/.config/awesome/module/titlebar/init.lua", line 1001
    c._nice_base_color = untransparant(get_dominant_color(c))
  ?, in xpcall
  ?, in xpcall
...
(7 additional frame(s) were not displayed)

Error during a protected call: /home/zeus/.config/awesome/module/titlebar/init.lua:232: invalid object

Add new general.conf option to disable desktop logic

Add an option called, desktop_rendering or something like that.
It would enable/disable the module.mousedrag and module.desktop files.

The functionality that should be altered:

  • desktop icons
  • file event listener for desktop changes
  • selection on the desktop
  • cached file to store desktop state (~/.cache/tde/desktop.conf)

Resize widget on screen change events

Currently when the screen changes size (through autorandr, xrandr or something else)
The layout doesn't change size and the wallpaper also doesn't update.

We should listen to screen events and update the widgets on screen

TDE creates a lot of directories in /tmp

Every time we restart TDE it creates new directories in /tmp
The old ones don't get cleaned properly.
We should clean them up when exiting TDE and when force exiting TDE

Error: timer not started

Sentry Issue: TDE-49

Error: timer not started

  File "/home/zeus/.config/awesome/widget/break-timer/init.lua", line 213, in stopSlider
    countdownSlider:stop()
  File "/home/zeus/.config/awesome/module/break-timer.lua", line 83, in stop
    _G.pause.stopSlider()
  File "/home/zeus/.config/awesome/module/break-timer.lua", line 97, in func
    _G.pause.stop()
  ?, in xpcall
...
(4 additional frame(s) were not displayed)

timer not started

Error: /home/zeus/.config/awesome/collision/focus.lua:245: attempt to call a nil value (method 'swap')

Sentry Issue: TDE-2P

Error: /home/zeus/.config/awesome/collision/focus.lua:245: attempt to call a nil value (method 'swap')
  File "/home/zeus/.config/awesome/collision/focus.lua", line 245, in bydirection
    c:swap(other)
  File "/home/zeus/.config/awesome/collision/focus.lua", line 278, in global_bydirection
    bydirection(dir, c or capi.client.focus, swap,max)
  File "/home/zeus/.config/awesome/collision/init.lua", line 134, in move
    module._focus.global_bydirection(direction,c,true,max)
  File "/home/zeus/.config/awesome/collision/init.lua", line 188, in on_press
    aw[#aw+1] = awful.key({ modkey, "Shift"                      }, key_name, function () module.move  (k          ) end,

/home/zeus/.config/awesome/collision/focus.lua:245: attempt to call a nil value (method 'swap')

[Refactor] reduce the lines of SVG files

There are quite a few SVG files that are not minified.

To get a list of SVG files with their length run the following script:

#!/usr/bin/env bash

shopt -s globstar
for svg in **/*.svg; do
    length="$length\n$(wc -l "$svg")"
done

echo -e "$length" | sort -n

This outputs the following:

0 plugins/hello-world-widget/icons/world.svg
0 plugins/jira-widget/jira-mark-gradient-blue.svg
0 plugins/settings-app-widget/icons/world.svg
0 tde/configuration/rofi/sidebar/icons/suggestion.svg
0 tde/theme/icons/bios.dark.svg
0 tde/theme/icons/bios.svg
0 tde/theme/icons/brightness-7.dark.svg
0 tde/theme/icons/brightness-7.svg
0 tde/theme/icons/chart-areaspline.dark.svg
0 tde/theme/icons/chart-areaspline.svg
0 tde/theme/icons/close.dark.svg
0 tde/theme/icons/close.svg
0 tde/theme/icons/forum.dark.svg
0 tde/theme/icons/forum.svg
0 tde/theme/icons/harddisk.dark.svg
0 tde/theme/icons/harddisk.svg
0 tde/theme/icons/lan.dark.svg
0 tde/theme/icons/lock.dark.svg
0 tde/theme/icons/lock.svg
0 tde/theme/icons/logout.dark.svg
0 tde/theme/icons/logout.svg
0 tde/theme/icons/magnify.dark.svg
0 tde/theme/icons/magnify.svg
0 tde/theme/icons/memory.dark.svg
0 tde/theme/icons/memory.svg
0 tde/theme/icons/microphone.dark.svg
0 tde/theme/icons/microphone.svg
0 tde/theme/icons/minus.black.svg
0 tde/theme/icons/minus.svg
0 tde/theme/icons/plus.dark.svg
0 tde/theme/icons/plus.svg
0 tde/theme/icons/power.dark.svg
0 tde/theme/icons/power-sleep.dark.svg
0 tde/theme/icons/power-sleep.svg
0 tde/theme/icons/power.svg
0 tde/theme/icons/qr_code.dark.svg
0 tde/theme/icons/qr_code.svg
0 tde/theme/icons/restart.dark.svg
0 tde/theme/icons/restart.svg
0 tde/theme/icons/settings.dark.svg
0 tde/theme/icons/settings.svg
0 tde/theme/icons/ship-wheel.dark.svg
0 tde/theme/icons/ship-wheel.svg
0 tde/theme/icons/themes/original/code-braces.svg
0 tde/theme/icons/themes/original/flask.svg
0 tde/theme/icons/themes/original/folder.svg
0 tde/theme/icons/themes/original/google-chrome.svg
0 tde/theme/icons/themes/original/google-controller.svg
0 tde/theme/icons/themes/original/menu.svg
0 tde/theme/icons/themes/original/music.svg
0 tde/theme/icons/themes/tos/code-braces.dark.svg
0 tde/theme/icons/themes/tos/code-braces.svg
0 tde/theme/icons/themes/tos/terminal.dark.svg
0 tde/theme/icons/themes/tos/terminal.svg
0 tde/theme/icons/thermometer.dark.svg
0 tde/theme/icons/thermometer.svg
0 tde/theme/icons/user.dark.svg
0 tde/theme/icons/user.svg
0 tde/theme/icons/volume-high.dark.svg
0 tde/theme/icons/volume-high.svg
0 tde/theme/icons/wifi_off.dark.svg
0 tde/theme/icons/wifi_off.svg
0 tde/widget/notification-center/icons/boo.dark.svg
0 tde/widget/notification-center/icons/boo.svg
0 tde/widget/notification-center/icons/new-notif.dark.svg
0 tde/widget/notification-center/icons/new-notif.svg
0 tde/widget/screen-recorder/icons/close-screen.dark.svg
0 tde/widget/screen-recorder/icons/close-screen.svg
0 tde/widget/search/icons/search.dark.svg
0 tde/widget/search/icons/search.svg
1 plugins/docker-widget/icons/docker.svg
1 plugins/hello-world-widget/icons/world.dark.svg
1 plugins/settings-app-widget/icons/world.dark.svg
1 tde/theme/icons/brush.dark.svg
1 tde/theme/icons/brush.svg
1 tde/theme/icons/calendar.dark.svg
1 tde/theme/icons/calendar.svg
1 tde/theme/icons/lan_off.dark.svg
1 tde/theme/icons/lan_off.svg
1 tde/theme/icons/lan.svg
1 tde/theme/icons/mouse.dark.svg
1 tde/theme/icons/mouse.svg
1 tde/theme/icons/warning.dark.svg
1 tde/theme/icons/warning.svg
2 tde/widget/notification-center/icons/dont-disturb.dark.svg
2 tde/widget/notification-center/icons/dont-disturb.svg
2 tde/widget/social-media/icons/reddit.dark.svg
2 tde/widget/social-media/icons/reddit.svg
2 tde/widget/weather/icons/moon_icon.dark.svg
2 tde/widget/weather/icons/moon_icon.svg
2 tde/widget/weather/icons/snow_icon.dark.svg
2 tde/widget/weather/icons/snow_icon.svg
4 tde/theme/icons/themes/original/art.svg
4 tde/widget/music/icons/music.dark.svg
4 tde/widget/music/icons/music.svg
4 tde/widget/music/icons/play.dark.svg
4 tde/widget/music/icons/play.svg
4 tde/widget/social-media/icons/facebook.dark.svg
4 tde/widget/social-media/icons/facebook.svg
5 tde/theme/icons/bluetooth.dark.svg
5 tde/theme/icons/bluetooth-off.dark.svg
5 tde/theme/icons/bluetooth-off.svg
5 tde/theme/icons/bluetooth.svg
5 tde/widget/battery/icons/battery-10.dark.svg
5 tde/widget/battery/icons/battery-10.svg
5 tde/widget/battery/icons/battery-20.dark.svg
5 tde/widget/battery/icons/battery-20.svg
5 tde/widget/battery/icons/battery-30.dark.svg
5 tde/widget/battery/icons/battery-30.svg
5 tde/widget/battery/icons/battery-40.dark.svg
5 tde/widget/battery/icons/battery-40.svg
5 tde/widget/battery/icons/battery-50.dark.svg
5 tde/widget/battery/icons/battery-50.svg
5 tde/widget/battery/icons/battery-60.dark.svg
5 tde/widget/battery/icons/battery-60.svg
5 tde/widget/battery/icons/battery-70.dark.svg
5 tde/widget/battery/icons/battery-70.svg
5 tde/widget/battery/icons/battery-80.dark.svg
5 tde/widget/battery/icons/battery-80.svg
5 tde/widget/battery/icons/battery-90.dark.svg
5 tde/widget/battery/icons/battery-90.svg
5 tde/widget/battery/icons/battery-alert.dark.svg
5 tde/widget/battery/icons/battery-alert.svg
5 tde/widget/battery/icons/battery-charging-100.dark.svg
5 tde/widget/battery/icons/battery-charging-100.svg
5 tde/widget/battery/icons/battery-charging-10.dark.svg
5 tde/widget/battery/icons/battery-charging-10.svg
5 tde/widget/battery/icons/battery-charging-20.dark.svg
5 tde/widget/battery/icons/battery-charging-20.svg
5 tde/widget/battery/icons/battery-charging-30.dark.svg
5 tde/widget/battery/icons/battery-charging-30.svg
5 tde/widget/battery/icons/battery-charging-40.dark.svg
5 tde/widget/battery/icons/battery-charging-40.svg
5 tde/widget/battery/icons/battery-charging-50.dark.svg
5 tde/widget/battery/icons/battery-charging-50.svg
5 tde/widget/battery/icons/battery-charging-60.dark.svg
5 tde/widget/battery/icons/battery-charging-60.svg
5 tde/widget/battery/icons/battery-charging-70.dark.svg
5 tde/widget/battery/icons/battery-charging-70.svg
5 tde/widget/battery/icons/battery-charging-80.dark.svg
5 tde/widget/battery/icons/battery-charging-80.svg
5 tde/widget/battery/icons/battery-charging-90.dark.svg
5 tde/widget/battery/icons/battery-charging-90.svg
5 tde/widget/battery/icons/battery-charging.dark.svg
5 tde/widget/battery/icons/battery-charging-outline.dark.svg
5 tde/widget/battery/icons/battery-charging-outline.svg
5 tde/widget/battery/icons/battery-charging.svg
5 tde/widget/battery/icons/battery.dark.svg
5 tde/widget/battery/icons/battery-fully-charged-90.dark.svg
5 tde/widget/battery/icons/battery-fully-charged-90.svg
5 tde/widget/battery/icons/battery-fully-charged.dark.svg
5 tde/widget/battery/icons/battery-fully-charged.svg
5 tde/widget/battery/icons/battery-minus.dark.svg
5 tde/widget/battery/icons/battery-minus.svg
5 tde/widget/battery/icons/battery-negative.dark.svg
5 tde/widget/battery/icons/battery-negative.svg
5 tde/widget/battery/icons/battery-outline.dark.svg
5 tde/widget/battery/icons/battery-outline.svg
5 tde/widget/battery/icons/battery-plus.dark.svg
5 tde/widget/battery/icons/battery-plus.svg
5 tde/widget/battery/icons/battery-positive.dark.svg
5 tde/widget/battery/icons/battery-positive.svg
5 tde/widget/battery/icons/battery-standard.dark.svg
5 tde/widget/battery/icons/battery-standard.svg
5 tde/widget/battery/icons/battery.svg
5 tde/widget/battery/icons/battery-unknown.dark.svg
5 tde/widget/battery/icons/battery-unknown.svg
5 tde/widget/music/icons/next.dark.svg
5 tde/widget/music/icons/next.svg
5 tde/widget/music/icons/pause.dark.svg
5 tde/widget/music/icons/pause.svg
5 tde/widget/music/icons/prev.dark.svg
5 tde/widget/music/icons/prev.svg
5 tde/widget/package-updater/icons/package.dark.svg
5 tde/widget/package-updater/icons/package-sec.svg
5 tde/widget/package-updater/icons/package.svg
5 tde/widget/package-updater/icons/package-up.svg
5 tde/widget/wifi/icons/wifi.dark.svg
5 tde/widget/wifi/icons/wifi-off.dark.svg
5 tde/widget/wifi/icons/wifi-off.svg
5 tde/widget/wifi/icons/wifi-strength-1-alert.dark.svg
5 tde/widget/wifi/icons/wifi-strength-1-alert.svg
5 tde/widget/wifi/icons/wifi-strength-1.dark.svg
5 tde/widget/wifi/icons/wifi-strength-1-lock.dark.svg
5 tde/widget/wifi/icons/wifi-strength-1-lock.svg
5 tde/widget/wifi/icons/wifi-strength-1.svg
5 tde/widget/wifi/icons/wifi-strength-2-alert.dark.svg
5 tde/widget/wifi/icons/wifi-strength-2-alert.svg
5 tde/widget/wifi/icons/wifi-strength-2.dark.svg
5 tde/widget/wifi/icons/wifi-strength-2-lock.dark.svg
5 tde/widget/wifi/icons/wifi-strength-2-lock.svg
5 tde/widget/wifi/icons/wifi-strength-2.svg
5 tde/widget/wifi/icons/wifi-strength-3-alert.dark.svg
5 tde/widget/wifi/icons/wifi-strength-3-alert.svg
5 tde/widget/wifi/icons/wifi-strength-3.dark.svg
5 tde/widget/wifi/icons/wifi-strength-3-lock.dark.svg
5 tde/widget/wifi/icons/wifi-strength-3-lock.svg
5 tde/widget/wifi/icons/wifi-strength-3.svg
5 tde/widget/wifi/icons/wifi-strength-4-alert.dark.svg
5 tde/widget/wifi/icons/wifi-strength-4-alert.svg
5 tde/widget/wifi/icons/wifi-strength-4.dark.svg
5 tde/widget/wifi/icons/wifi-strength-4-lock.dark.svg
5 tde/widget/wifi/icons/wifi-strength-4-lock.svg
5 tde/widget/wifi/icons/wifi-strength-4.svg
5 tde/widget/wifi/icons/wifi-strength-alert-outline.dark.svg
5 tde/widget/wifi/icons/wifi-strength-alert-outline.svg
5 tde/widget/wifi/icons/wifi-strength-lock-outline.dark.svg
5 tde/widget/wifi/icons/wifi-strength-lock-outline.svg
5 tde/widget/wifi/icons/wifi-strength-off.dark.svg
5 tde/widget/wifi/icons/wifi-strength-off-outline.dark.svg
5 tde/widget/wifi/icons/wifi-strength-off-outline.svg
5 tde/widget/wifi/icons/wifi-strength-off.svg
5 tde/widget/wifi/icons/wifi-strength-outline.dark.svg
5 tde/widget/wifi/icons/wifi-strength-outline.svg
5 tde/widget/wifi/icons/wifi.svg
6 tde/widget/social-media/icons/instagram.dark.svg
6 tde/widget/social-media/icons/instagram.svg
6 tde/widget/social-media/icons/twitter.dark.svg
6 tde/widget/social-media/icons/twitter.svg
6 tde/widget/weather/icons/cloud_icon.dark.svg
6 tde/widget/weather/icons/cloud_icon.svg
8 plugins/docker-widget/icons/play-btn.svg
9 plugins/docker-widget/icons/pause-btn.svg
9 plugins/docker-widget/icons/unpause-btn.svg
9 tde/theme/icons/themes/tos/music.dark.svg
9 tde/theme/icons/themes/tos/music.svg
10 plugins/docker-widget/icons/stop-btn.svg
10 tde/theme/icons/themes/original/terminal.svg
12 tde/theme/icons/themes/tos/code.dark.svg
12 tde/theme/icons/themes/tos/code.svg
12 tde/theme/icons/themes/tos/flask.dark.svg
12 tde/theme/icons/themes/tos/flask.svg
12 tde/theme/icons/themes/tos/google-controller.dark.svg
12 tde/theme/icons/themes/tos/google-controller.svg
12 tde/widget/weather/icons/ncloud_icon.dark.svg
12 tde/widget/weather/icons/ncloud_icon.svg
14 plugins/docker-widget/icons/play.svg
14 plugins/docker-widget/icons/square.svg
14 tde/widget/screen-recorder/icons/start-recording-button.dark.svg
14 tde/widget/screen-recorder/icons/start-recording-button.svg
14 tde/widget/weather/icons/dcloud_icon.dark.svg
14 tde/widget/weather/icons/dcloud_icon.svg
15 plugins/docker-widget/icons/pause.svg
15 tde/widget/weather/icons/rain_icon.dark.svg
15 tde/widget/weather/icons/rain_icon.svg
16 tde/theme/icons/themes/tos/art.dark.svg
16 tde/theme/icons/themes/tos/art.svg
16 tde/widget/weather/icons/sun_icon.dark.svg
16 tde/widget/weather/icons/sun_icon.svg
18 tde/widget/weather/icons/mist_icon.dark.svg
18 tde/widget/weather/icons/mist_icon.svg
22 tde/theme/icons/themes/tos/folder.dark.svg
22 tde/theme/icons/themes/tos/folder.svg
40 tde/theme/icons/volume-mute.dark.svg
40 tde/theme/icons/volume-mute.svg
49 tde/widget/user-profile/icons/user.dark.svg
49 tde/widget/user-profile/icons/user.svg
50 tde/widget/weather/icons/storm_icon.dark.svg
50 tde/widget/weather/icons/storm_icon.svg
55 tde/theme/icons/themes/tos/firefox.dark.svg
55 tde/theme/icons/themes/tos/firefox.svg
57 tde/configuration/rofi/sidebar/icons/result.svg
57 tde/widget/screen-recorder/icons/back.dark.svg
57 tde/widget/screen-recorder/icons/back.svg
57 tde/widget/screen-recorder/icons/settings.dark.svg
57 tde/widget/screen-recorder/icons/settings.svg
58 tde/theme/icons/download.dark.svg
58 tde/theme/icons/download.svg
58 tde/theme/icons/network.dark.svg
58 tde/theme/icons/network.svg
58 tde/theme/icons/upload.dark.svg
58 tde/theme/icons/upload.svg
58 tde/theme/icons/wifi.dark.svg
58 tde/theme/icons/wifi.svg
59 tde/widget/calculator/icons/kb.dark.svg
59 tde/widget/calculator/icons/kb-off.dark.svg
59 tde/widget/calculator/icons/kb-off.svg
59 tde/widget/calculator/icons/kb.svg
60 plugins/icon_button/icons/info.dark.svg
60 tde/theme/icons/info.dark.svg
60 tde/theme/icons/info.svg
60 tde/widget/about/icons/info.dark.svg
61 tde/widget/battery/icons/battery-alert-red.dark.svg
61 tde/widget/battery/icons/battery-alert-red.svg
61 tde/widget/notification-center/icons/toggled-off.dark.svg
61 tde/widget/notification-center/icons/toggled-off.svg
61 tde/widget/notification-center/icons/toggled-on.dark.svg
61 tde/widget/notification-center/icons/toggled-on.svg
63 tde/widget/screen-recorder/icons/recorder-off.dark.svg
63 tde/widget/screen-recorder/icons/recorder-off.svg
67 plugins/icon_button/icons/info.svg
67 tde/theme/icons/laptop.dark.svg
67 tde/theme/icons/laptop.svg
67 tde/widget/about/icons/info.svg
68 tde/widget/screen-recorder/icons/recorder-countdown.dark.svg
68 tde/widget/screen-recorder/icons/recorder-countdown.svg
70 tde/widget/screen-recorder/icons/audio.dark.svg
70 tde/widget/screen-recorder/icons/audio.svg
71 tde/widget/screen-recorder/icons/recorder-on.dark.svg
71 tde/widget/screen-recorder/icons/recorder-on.svg
74 tde/widget/notification-center/icons/notification.dark.svg
74 tde/widget/notification-center/icons/notification.svg
75 tde/configuration/rofi/sidebar/icons/history.svg
82 tde/widget/xdg-folders/icons/no.dark.svg
82 tde/widget/xdg-folders/icons/no.svg
82 tde/widget/xdg-folders/icons/yes.dark.svg
82 tde/widget/xdg-folders/icons/yes.svg
85 tde/widget/screen-recorder/icons/recording-button.dark.svg
85 tde/widget/screen-recorder/icons/recording-button.svg
90 tde/theme/icons/themes/drops/folder.svg
97 tde/theme/icons/themes/drops/terminal.svg
107 tde/theme/barthemes/main/titlebar/minimize_focus_hover.svg
107 tde/theme/barthemes/main/titlebar/minimize_focus.svg
107 tde/theme/barthemes/main/titlebar/minimize_normal_hover.svg
108 tde/theme/barthemes/main/titlebar/floating_normal_active.svg
108 tde/theme/barthemes/main/titlebar/floating_normal_inactive.svg
110 tde/widget/xdg-folders/icons/open-folder.dark.svg
110 tde/widget/xdg-folders/icons/open-folder.svg
113 tde/theme/barthemes/main/titlebar/maximized_normal_active.svg
113 tde/theme/barthemes/main/titlebar/maximized_normal_inactive.svg
114 tde/theme/barthemes/main/titlebar/close_normal.svg
116 tde/theme/barthemes/main/titlebar/close_focus_hover.svg
116 tde/theme/barthemes/main/titlebar/close_focus.svg
116 tde/theme/barthemes/main/titlebar/close_normal_hover.svg
117 tde/theme/barthemes/main/titlebar/maximized_focus_active_hover.svg
117 tde/theme/barthemes/main/titlebar/maximized_focus_active.svg
117 tde/theme/barthemes/main/titlebar/maximized_focus_inactive_hover.svg
117 tde/theme/barthemes/main/titlebar/maximized_focus_inactive.svg
117 tde/theme/barthemes/main/titlebar/maximized_normal_active_hover.svg
117 tde/theme/barthemes/main/titlebar/maximized_normal_inactive_hover.svg
119 tde/theme/barthemes/main/titlebar/minimize_normal.svg
124 tde/widget/sars-cov-2/icons/corona.dark.svg
124 tde/widget/sars-cov-2/icons/corona.svg
126 tde/widget/xdg-folders/icons/folder-documents.dark.svg
126 tde/widget/xdg-folders/icons/folder-documents.svg
126 tde/widget/xdg-folders/icons/folder-videos.dark.svg
126 tde/widget/xdg-folders/icons/folder-videos.svg
126 tde/widget/xdg-folders/icons/user-home.dark.svg
126 tde/widget/xdg-folders/icons/user-home.svg
127 tde/widget/xdg-folders/icons/folder-pictures.dark.svg
127 tde/widget/xdg-folders/icons/folder-pictures.svg
130 tde/theme/barthemes/main/titlebar/floating_focus_active_hover.svg
130 tde/theme/barthemes/main/titlebar/floating_focus_active.svg
130 tde/theme/barthemes/main/titlebar/floating_focus_inactive_hover.svg
130 tde/theme/barthemes/main/titlebar/floating_focus_inactive.svg
130 tde/theme/barthemes/main/titlebar/floating_normal_active_hover.svg
130 tde/theme/barthemes/main/titlebar/floating_normal_inactive_hover.svg
134 tde/widget/xdg-folders/icons/folder-download.dark.svg
134 tde/widget/xdg-folders/icons/folder-download.svg
160 tde/widget/xdg-folders/icons/user-trash-empty.dark.svg
160 tde/widget/xdg-folders/icons/user-trash-empty.svg
169 tde/theme/icons/themes/drops/music.svg
178 tde/theme/icons/themes/drops/google-chrome.svg
192 tde/widget/dpi/icons/search.dark.svg
192 tde/widget/dpi/icons/search.svg
218 tde/theme/icons/themes/drops/google-controller.svg
220 tde/theme/icons/themes/drops/art.svg
243 tde/theme/icons/themes/drops/code-braces.svg
256 tde/theme/icons/themes/drops/flask.svg
329 tde/theme/icons/themes/drops/menu.svg
342 tde/widget/weather/icons/whatever_icon.dark.svg
342 tde/widget/weather/icons/whatever_icon.svg
365 tde/configuration/rofi/sidebar/icons/google.svg
395 tde/theme/icons/logo.svg
395 tde/theme/icons/themes/tos/logo.dark.svg
395 tde/theme/icons/themes/tos/logo.svg
395 tos/TOS_logo.svg
540 tde/theme/icons/themes/tos/computer.dark.svg
540 tde/theme/icons/themes/tos/computer.svg
615 tde/configuration/rofi/sidebar/icons/ddg.svg
721 tde/theme/icons/themes/tos/menu.dark.svg
721 tde/theme/icons/themes/tos/menu.svg
979 tde/widget/xdg-folders/icons/user-trash-full.dark.svg
979 tde/widget/xdg-folders/icons/user-trash-full.svg
3521 tde/widget/music/icons/vinyl.dark.svg
3521 tde/widget/music/icons/vinyl.svg

Try to reduce as much as possible.
(Perhaps even rewrite a few as minified version could still be to large)

For example tde/widget/music/icons/vinyl.svg has over 3521 lines of code (250 KB) which is way too massive.
Consider creating an alternative version that is significantly smaller (e.g. less than 5 KB)

This is a major undertaking as a lot of icons need to be changed.
Consider creating either one massive PR (with a lot of commits)
Or a few small ones

Feel free to ask any more questions if needed

Error: awful: function getidx is deprecated. Use t.index instead of awful.tag.getidx.

Sentry Issue: TDE-44

Error: awful: function getidx is deprecated. Use t.index instead of awful.tag.getidx.

  File "/home/zeus/.config/awesome/collision/max.lua", line 309, in change_tag
    local cur_idx,count = awful.tag.getidx(t),#capi.screen[s].tags
  File "/home/zeus/.config/awesome/collision/max.lua", line 327
    change_tag(s,direction,is_swap)
  File "/home/zeus/.config/awesome/collision/init.lua", line 93
    if not event_callback[current_mode](mod,key,event,k,is_swap,is_max) then
...
(1 additional frame(s) were not displayed)

awful: function getidx is deprecated. Use t.index instead of awful.tag.getidx.

Change the way config files are parsed

Currently, we need to suffix the config file with numbers e.g. float_1 and float_2 which is rather bizarre.

It would be better and more useful (both from a dev and a user perspective) to support a config as such:

float = "a"
float = "b"
float = "c"

And generate the following lua representation:

local config_value = config.parse("your_config_file")
for floating in config_value["float"] do
    print(floating)
done

Which prints out all values (a, b, c)

By treating every unique element in the config as a list we can omit manual numbering (which is annoying when reordering things like plugins)

Some notifications don't contain a body

Some notifications don't contain a body.
Applications that I detected to have this issue are:

  1. Discord
  2. Udiskie
  3. TOS Tutorial

It looks like the notification center is showing these correctly, however, the popup has this issue.

I'm not able to reproduce this using notify-send

If I get more information I will update this issue

Create pre-commit hooks

Create some pre-commit hooks that do the following:

  1. Run the unit test suite
  2. Run the lua-linter

If any of the above creates an error then don't allow the commit

Support TDE on other systems than TOS

TDE is highly integrated into TOS, resulting in a direct dependency.

It would be nice if TDE could also run on for example ubuntu, plain arch etc.

This can be done by adding specific checks, having more optional dependencies etc

Add new dev-tool to make writing widgets easier

Add some sort of dev tool to auto load widgets into tde to easily test if they work or not.

We could then listen for filesystem event (save) to update the widget in tde as a quick way to test if it works

[Refactor] LIB-WIDGET refactor common widgets into lib-widget

Currently we use the underlying widget system of awesomewm.
We should provide an api to easily make common widgets that can be integrated over the entire system, example widgets:

  • textbox
  • imagebox
  • iconbox (circular imagebox)
  • input field (including password)
  • slider
  • button
  • checkbox
  • card (title + body)
  • separator
  • scrollable box

And more...
This could contain a lot of abstractions such as:

  • translation (textbox)
  • keygrabber (inputfield)
  • theming
  • light/dark theme
  • etc

Regular screenshots size is way to big

When creating a screenshot it doesn't perform any compression.
This usually results in very large file sizes.
Averages around 7-8MB
We should wrap it in an imagemagick call to decrease the size to 1-2MB

Allow restarting pipewire

Sometimes pipewire hangs (beta software), it would be useful if we have some option to restart the audio server. To fix the audio not working

Add an icon to the desktop when when tos installer is present

Perform a check to see if tos installer is present.
If it is that means we can install tos on the system.
In that case show an icon on the desktop when clicked open the installer

-- check is performed like this:
if hardware-check.has_package_installed("installer") then
 -- TODO: show installer on the desktop
end 

Remove unnecessary hard depenencies on certain packages

TDE currently has hard dependencies towards certain packages, that I would like to see removed, so it can be used in an even more minimal distribution.

For example these are hard dependencies:

  1. playerctl
  2. arch-audit
  3. psi-notify
  4. maim
  5. pkgstats
  6. gvfs
  7. greenclip
  8. xidlehook
  9. ffmpeg (not really required, but is included in tos-base-desktop

They all provide useful features but shouldn't be hard dependencies.
Use lib-tde.hardware-check.has_package_installed() to create soft dependencies.

As a result TDE can be used in a smaller system, for example decrease the size of the tos-docker image

Error: /etc/xdg/tde/layout/init.lua:73: attempt to index a nil value (field 'bottom_panel')

Sentry Issue: TDE-BG

Error: /etc/xdg/tde/layout/init.lua:73: attempt to index a nil value (field 'bottom_panel')
  File "/etc/xdg/tde/layout/init.lua", line 73, in updateBarsVisibility
    s.bottom_panel.visible = not fullscreen
  File "/etc/xdg/tde/layout/init.lua", line 81
    updateBarsVisibility()
  ?, in __newindex
  File "/usr/share/tde/lib/awful/tag.lua", line 319, in add
    newtag[k] = v
  File "/etc/xdg/tde/configuration/tags/init.lua", line 158
    awful.tag.add(
...
(2 additional frame(s) were not displayed)

/etc/xdg/tde/layout/init.lua:73: attempt to index a nil value (field 'bottom_panel')

Animate wiboxes on the desktop

Currently we have some wiboxes applied on the desktop eg:

  • action center
  • notification center
  • notifications
  • settings menu

These can be animated (left panel appearing from the left, settings app fading in etc)
Create an animation framework and document/integrate it with our DE:

The snippet below uses this api: https://github.com/kikito/tween.lua
This saves us the trouble of implementing the tweening itself, and focusing on the implementation in TDE itself

Some example code:

animation.lua

local gears = require("gears")
local hardware = require("lib-tde.hardware-check")
local tween = require("lib-tde.animations.tween")

-- TODO: check if this is correct
local freq = 1 / hardware.getDisplayFreq()

function createAnimObject(duration, subject, target, easing, end_callback, delay, widget, tween_callback)
  widget = widget and widget or subject
  -- check if animation is running
  if widget.anim then
    widget:emit_signal("interrupt", widget)
  end
  -- create timer at display freq
  widget.timer = gears.timer({timeout = freq})
  -- create self-destructing animation-stop callback function
  cback = function(widget)
    if widget.timer and widget.timer.started then
      widget.timer:stop()
    end
    widget:disconnect_signal("interrupt", cback)
  end
  -- create tween
  local twob = tween.new(duration, subject, target, easing)
  -- create timeout signal
  widget.dt = 0
  widget.timer:connect_signal(
    "timeout",
    function()
      widget.dt = widget.dt + freq
      local complete = twob:update(widget.dt)
      if tween_callback == nil then
        widget:emit_signal("widget::redraw_needed")
      else
        tween_callback()
      end
      if complete then
        widget.timer:stop()
        cback(widget)
        widget.anim = false
        if end_callback then
          end_callback()
        end
      end
    end
  )
  -- start animation
  widget:connect_signal("interrupt", cback)
  widget.anim = true
  if delay ~= nil then
    gears.timer {
      autostart = true,
      single_shot = true,
      timeout = delay,
      callback = function()
        widget.timer:start()
      end
    }
  else
    widget.timer:start()
  end
end

return {
    createAnimObject = createAnimObject
}

Usage of the above code (left panel)

local createAnimObject = require("lib-tde.animations").createAnimObject

local function open()
    _G.left_panel.visible = true
    -- set the initial condition
    _G.left_panel.y = -100
    _G.left_panel.opacity = 0
   -- animate over one second, change the opacity and y position
   createAnimObject(1, _G.left_panel, {opacity = 1, y = 0}, "outCubic")
end 

Add an option to disable all network traffic

I have been investigating network usage by TDE
It seems we on average consume about 20 - 50 MB of data every hour.
This is network usage primarily comes from the package updater and from security checker.
We should have an option to disable these thus reducing idle network usage to less to 100KB an hour (network check from NetworkManager is the only idle check that then happens)

This option should take into account the following:

  • package updater (including in the settings app)
  • error sending

The reason for disabling that is to reduce consumption when using mobile data (eg (2|3|4|5)G)

Migrate the lua runtime to luajit

Currently we have a few c dependencies:

  • posix
  • cjson
  • socket

These should be migrated to luajit, for it to work + all invalid luajit statements should be converted
We can expect a roughly 2x performance boost in lua based code

The next step is to migrate as many of the poll-shell script to lua (to increase the efficiency to over 200 times)

A rough estimate would increase our performance overall to at least 2 to 5 times

This would be a massive game changer for lower end hardware

Note that we are talking about cpu improvement not ram or disk

Add filters

We should implement a map, reduce and filter api much like javascript, this way you can do easier operations on lists

Mouse dragging on the desktop should select multiple items

Currently, the mouse dragging doesn't do anything.
It should iterate over all items and check if any are under it, if that is the case they need to be selected.

Selection should enable ontop = true and unselection = optop = false
Together with highlighting the item.
If you then drag on item, all other selected items should move together with you.

Add smart connection manager to settings

The settings app should have submenu's added:

  • connect to bluetooth device wizard
  • connect to wifi network wizard

These options are a must for the settings app

Theme options should be changeable from the settings app

A new menu item should be added to the settings application.
Namely:
editing of configuration files (in the GUI)

  • keybindings are a must
  • general configuration (eg opt-in/out of features)
  • break timer
  • selection of the primary and accent colors

The new menu should have a button list at the top that also toggles which "submenu" to show eg keybindings, general, colors etc

Ability to change the user icon in the settings application

Currently we have a user picture api inplace where we can easily display the user icon.
We can also update the user icon using: tos -p picture.png that is compatible with accountservices
However, there is no gui for this.
I propose we add a new field in the settings application called account where we can change some properties
It should behave much like the display tab, some configurable options:

  • Change hostname
  • Change profile picture
  • Potentially add/remove groups (something in the style of the network tab)?

Music widget Escape doesn't animate it

The music widget has animations for both opening and closing.
However, when closing it using the ˋEscapeˋ key it isn't beeing animated
This should happen

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.