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

Colorful link-icons in dashboard #45

Closed
ZwennR opened this issue Mar 20, 2023 · 1 comment
Closed

Colorful link-icons in dashboard #45

ZwennR opened this issue Mar 20, 2023 · 1 comment

Comments

@ZwennR
Copy link

ZwennR commented Mar 20, 2023

Currently, all the link-icons(gmail, github etc.) are turned white on my device, even if i add a custom colorful one. Is there a way to change some code or maybe add a setting so that we can have colorful icons in the dashboard?
Thanks!

@ZwennR ZwennR closed this as completed Mar 20, 2023
@ZwennR
Copy link
Author

ZwennR commented Mar 20, 2023

I managed to do it myself by replacing _button in dashWidgets.js with this code:

    _button(name, link){
        if(!name) name = 'weblink';
        let icon = new St.Icon({
            gicon: Gio.icon_new_for_string(`${Me.path}/media/${name}-symbolic.svg`),
            style_class: 'system-status-icon',
            icon_size: this._settings.get_int('dash-links-icon-size')
        });
        icon.icon_name = `${name}-symbolic`;
        return new HoverButton(
            icon,
            link,
            () => {
                Util.spawnCommandLine(`xdg-open ${link}`);
                this._parentDialog.close();
            },
            this._hasBackground ? 'message-media-control' : 'events-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

1 participant