A dart library to get and set backgrounds on multiple GUI linux platforms

Overview

A Dart library for linux platforms to get and set backgrounds, which supports multiple desktop environments and window managers

Features

  • Can automatically sense desktop environments and return the respective backend
  • Get list of wallpaper(s) set
  • Set a wallpaper
  • Provides a way to write your own custom backend and add it to lib/src/backends directory

Getting started

You just require a working GUI linux system, satisfy all the dependencies and then see the usage.

Usage

If you dont wanna read any documentation and just want to use this package, just headup to example/example.dart and just copy-paste required code from there. Otherwise, you can read the following documentation.

First, import the wallman library.

import 'package:wallman/wallman.dart';
  • Auto detect backend (this is what you would generally want to do):
var wall = getBackend();
  • Specifically use a backend (if you want it to use it for specific desktop/WM):
var wall = GnomeBackend();

The wallman library exposes a variable (property) called "availableBackends" which returns list of names of available backends.

The Backend object exposes a 'name' property of String type which gives the name of backend currently in use.

print(wall.name)

You can use getWall and setWall functions as given:

print(await wall.getWall());

wall.setWall("/usr/share/backgrounds/xfce/xfce-teal.jpg");

The getWall function returns a Future > .

The setWall function is of Future type.

Additional information

  • The library code during execution would return empty values if any error occurs and would not fail, but would write warnings, information to STDERR. So, if you are using it in some program, be sure to discard STDERR or redirect it to /dev/null.
  • setWall of WlrootsBackend is currently unusable. Although I implemented it, still I can't figure out how can I detach swaybg process. Current implementation uses 'setsid'.
  • To create your own custom backend, see documentation or source of Backend class (present in lib/src/generic_backend.dart). To see examples of backends and analyse how they are created, analyse the code of lib/src/backends. The simplest to understand would be backman.dart. Understanding gsettings.dart would help a lot.
  • If your custom backend would anyhow utilise gsettings, better check gsettings.dart and analyse the implementation of MateBackend in lib/src/backends/gsettings.dart and implement your own taking it as example, instead of creating your backend from scratch. You can also use gsettings without implementing new backend class, you can just use Gsettings class and set interface, key, and value type in your program itself in which you are gonna use this library; for doing that see example/custom_gsettings.dart
  • Pull requests adding new backends are welcome.
  • Any general pull requests are also welcome.
  • Pull requests are accepted at https://github.com/securearth/wallman

Todo:

  • Write warnings
  • Fix backgroundExec in utils.dart which is making setWall of WlrootsBackend unusable.
  • Check if the user has set solid color instead of picture and return the colour
You might also like...

Cowin smart print - A GUI based CoWIN Certificate to Smart Card Converter

Cowin smart print - A GUI based CoWIN Certificate to Smart Card Converter

CoWIN Smart Print A GUI based CoWIN Certificate to Smart Card Converter. Feature

Mar 9, 2022

Open source Flutter-based GUI application that enables you to interact with Amphitheatre

Open source Flutter-based GUI application that enables you to interact with Amphitheatre

Amphitheatre Desktop Amphitheatre Desktop is an open source Flutter-based application that enables you to interact with Amphitheatre using a GUI inste

Dec 16, 2022

Lovely Real-ESRGAN GUI Wrapper

Lovely Real-ESRGAN GUI Wrapper

Real-ESRGAN-GUI Real-ESRGAN の NCNN (Vulkan) 実装である、realesrgan-ncnn-vulkan という CLI ツールのかんたんな GUI ラッパーです。 Flutter on Desktop を使って突貫で合計5~6時間くらいで作りました。 かんた

Jan 8, 2023

Real-CUGAN GUI tool

Real-CUGAN GUI tool

Real-CUGAN-GUI English version 日本語 | English This is a simple GUI wrapper for a CLI tool realcugan-ncnn-vulkan, which is the NCNN (Vulkan) implementat

Nov 25, 2022

A powerful official extension library of Tab/TabBar/TabView, which support to scroll ancestor or child Tabs when current is overscroll, and set scroll direction and cache extent.

extended_tabs Language: English | 中文简体 A powerful official extension library of Tab/TabBar/TabView, which support to scroll ancestor or child Tabs whe

Dec 13, 2022

A web-safe implementation of dart.io.Platforms. Helps avoid the "Unsupported operation: Platform._operatingSystem" runtime error.

Universal Platform - A Web-safe Platform class Currently, if you include the dart.io.Platform anywhere in your code, your app will throw the following

Nov 20, 2022

Mildly encrypted package - An encryption client & server for Dart Native + mobile platforms.

TODO: Put a short description of the package here that helps potential users know whether this package might be useful for them. Features TODO: List w

Jan 9, 2022

This is a wallet application written in Flutter & Dart. Codebase could be shared effectively on other OS Platforms

This is a wallet application written in Flutter & Dart. Codebase could be shared effectively on other OS Platforms

Gwallet A Simple wallet application written in Flutter and Dart for Android and iOs. Getting Started For Android, Specifically. You can run iOS, by st

Dec 12, 2022

Flutterbodydetection - A flutter plugin that uses MLKit on iOS/Android platforms to enable body pose and mask detection using Pose Detection and Selfie Segmentation APIs for both static images and live camera stream.

Flutterbodydetection - A flutter plugin that uses MLKit on iOS/Android platforms to enable body pose and mask detection using Pose Detection and Selfie Segmentation APIs for both static images and live camera stream.

body_detection A flutter plugin that uses MLKit on iOS/Android platforms to enable body pose and mask detection using Pose Detection and Selfie Segmen

Dec 5, 2022
Owner
Hemish
Just new to programming and keen to learn more! 16 years old
Hemish
Yukino lets you read manga or stream anime ad-free from multiple sources for free! Available for Windows, Linux, MacOS and Android.

Yukino Yukino lets you read manga or stream anime ad-free from multiple sources. The project's name "Yukino" meaning "Snow" named after the character

Yukino 204 Jan 6, 2023
A program for Mac, Windows and Linux to manage multiple translation files at once

A program for Mac, Windows and Linux to manage multiple translation files at once. Easy to use UI, multithreaded for optimization and Google Translate natively integrated. NB: At the moment it doesn't support nested translation keys.

Jesper Paulsen 4 Aug 8, 2022
Flutter Control is complex library to maintain App and State management. Library merges multiple functionality under one hood. This approach helps to tidily bound separated logic into complex solution.

Flutter Control is complex library to maintain App and State management. Library merges multiple functionality under one hood. This approach helps to

Roman Hornak 23 Feb 23, 2022
Get or set persistent storage value based on MMKV framework.

mmkv_flutter Plugin that allow Flutter to read value from persistent storage or save value to persistent storage based on MMKV framework Getting Start

OpenFlutter 101 Jan 17, 2022
Generate secure passwords, check for exposed passwords, get visual feedback for password strength or get form validation with a minimum password strength required.

password_strength_checker Generate secure passwords, check for exposed passwords, get visual feedback for password strength or get form validation wit

Dario Varriale 6 Aug 8, 2023
A GUI package manager and package installer for Windows Subsystem for Android (WSA)

wsa_pacman A GUI package manager and package installer for Windows Subsystem for Android (WSA). Currently provides a double-click GUI installer for .a

null 2.6k Jan 1, 2023
A GUI package manager and package installer for Windows Subsystem for Android (WSA)

wsa_pacman A GUI package manager and package installer for Windows Subsystem for Android (WSA). Currently provides a double-click GUI installer for .a

null 3 Nov 14, 2022
🔒 Desktop GUI to generate file checksum (SHA and MD5).

Note currently this app is only available for Windows and Linux. File Checksum File checksum is an old technique to verify the integrity of a file. An

Alex Rintt 6 Jan 3, 2023
A GUI for the Neutrino neural singing synthesizer

Muon A GUI for the Neutrino neural singing synthesizer, written in Flutter (and uses synaps!). Eyecandy / screenshots Eye-burning Light mode Dark mode

swadical 35 Dec 17, 2022