Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bluetooth library 🥺 #17

Open
deviantsemicolon opened this issue Feb 21, 2025 · 2 comments
Open

Bluetooth library 🥺 #17

deviantsemicolon opened this issue Feb 21, 2025 · 2 comments

Comments

@deviantsemicolon
Copy link

The one thing stopping me from using quickshell is that it doesn't have a library for Bluetooth, and I'd like to make an applet for connecting Bluetooth devices in quickshell.

@jmoggr
Copy link

jmoggr commented Feb 21, 2025

I worked around this for myself by adding a button that launches a bluetooth app. I personally don't change Bluetooth settings often, and in practice, I don't feel like I'm missing much without an applet. Still, more features is more better :)

import QtQuick
import QtQuick.Layouts
import Quickshell

MouseArea {
    Layout.preferredHeight: parent.height
    Layout.alignment: Qt.AlignHCenter
    Layout.fillHeight: true
    Layout.preferredWidth: icon.implicitWidth
    hoverEnabled: true

    Rectangle {
        id: background
        anchors.fill: parent
        radius: 5

        Image {
            id: icon
            source: "root:/assets/bluetooth.svg"
            height: parent.height * (2 / 3)

            anchors.verticalCenter: parent.verticalCenter
            fillMode: Image.PreserveAspectFit
        }
    }

    onEntered: background.color = "grey"
    onExited: background.color = "transparent"

    onClicked: {
        let entry = DesktopEntries.byId("io.github.kaii_lb.Overskride");
        if (!entry) {
            return;
        }

        entry.execute();
    }
}

@outfoxxed
Copy link
Member

This is already tracked internally, and is planned. I have not had the time to do it yet.

My current solution is blueman-tray, which works well enough to be usable in its tray menu. If you want you can filter it out of your normal system tray item list and give it a special button.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants