ddebruijne / Tray

Cross-platform Windows/MacOS/Linux tray menu

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Cross-platform Linux/Windows/MacOS Tray

Cross-platform, super tiny implementation of a system tray icon with a popup menu.

Works well on:

  • Linux/Gtk (libappindicator) - Gnome3 may need an extension
  • Windows XP or newer (shellapi.h)
  • MacOS (Cocoa/AppKit)

This fork is a different implementation based on Dmitry Mikushin's fork. using more modern c++ and standard library. He brought together the original work of Serge Zaitsev and the most interesting forks and PRs of respectable contributors:

Prerequisites

  • CMake
  • Ninja, in order to have the same build commands on all platforms
  • AppIndicator on Linux:

Debian-based:

sudo apt install libappindicator3-dev

Arch-based:

sudo pacman -S libappindicator-gtk3

Building

mkdir build
cd build
cmake -G Ninja ..
ninja

Personally, I open the folder in VSCode with CMake and CMake Tools extensions, that auto configures everything. Had some issues with the flatpak version, so I recommend installing from AUR or using Microsoft's .deb file on linux.

Demo

Execute the tray_example application:

./tray_example

Usage

Needs updating. For now check example.cpp

License

This software is distributed under MIT license, so feel free to integrate it in your commercial products.

About

Cross-platform Windows/MacOS/Linux tray menu

License:MIT License


Languages

Language:C++ 61.4%Language:Objective-C++ 21.1%Language:CMake 17.4%