Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 23 additions & 0 deletions wallpaper-switcher/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# Wallpaper Switcher

This plugin switches to the next wallpaper in the selected wallpaper catalogue in
Noctalia settings.
The wallpaper can be switched by clicking on a bar widget or a control-center
shortcut tile.

## Plugin

| Field | Value |
| --- | --- |
| ID | `kavya-nama/wallpaper-switcher` |
| Entries | Bar widget: `switch`; control-center shortcut: `switch-shortcut` |

## Requirements

No external dependencies.

## Usage

Add the widget to bar using Noctalia GUI, click on the widget to switch wallpaper.
The control-center shortcut can be added from the control-center shortcuts
settings.
18 changes: 18 additions & 0 deletions wallpaper-switcher/plugin.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
id = "kavya-nama/wallpaper-switcher"
name = "Wallpaper Switcher"
version = "1.0.0"
plugin_api = 3
author = "kavya-nama"
license = "MIT"
icon = "image"
description = "Switch to the next wallpaper from a bar widget."
tags = ["bar", "shortcut", "wallpaper"]
dependencies = []

[[widget]]
id = "switch"
entry = "widget.luau"

[[shortcut]]
id = "switch-shortcut"
entry = "shortcut.luau"
7 changes: 7 additions & 0 deletions wallpaper-switcher/shortcut.luau
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
function onClick()
noctalia.runAsync("noctalia msg wallpaper-next")
noctalia.notify("Wallpaper Switch", "Wallpaper switched")
end

shortcut.setLabel("Next Wallpaper")
shortcut.setIcon("image")
Binary file added wallpaper-switcher/thumbnail.webp
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions wallpaper-switcher/translations/en.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{}
8 changes: 8 additions & 0 deletions wallpaper-switcher/widget.luau
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
function update()
barWidget.setGlyph("image")
end

function onClick()
noctalia.runAsync("noctalia msg wallpaper-next")
noctalia.notify("Wallpaper Switch", "Wallpaper switched")
end