Yet another Syncthing Tray

I’m also not aware of any specific environment variable to influence QSettings except what’s mentioned here: https://doc.qt.io/qt-5/qsettings.html#setPath

I guess making this configurable via a command-line switch (which also has a fallback enviroment variable) makes sense.

1 Like

That would be very nice. I have seen the same link, but from what it seems, there is no way to override the path in Windows that way, or is it?

Just for the record, the reasons why I would like to have this option is to 1) be able to run Syncthing Tray in a portable way, and b) run multiple instances, each with a different configuration.

Good that you tell me your exact use case because for b) there’s actually more work to do. So far - even if you start multiple instances - there’s actually just running one executable at a time. That’s because the 2nd invocation just passes the arguments to the already running process. I suppose I also need to add a CLI option to prevent that because one process can only have one configuration.

But I’d also like to note that if you want to show multiple tray icons for different Syncthing instances at the same time that’s possible right now. Just configure multiple connections in the settings. The first connection configuration is used by default but you can use the --connection argument when starting the 2nd instance. This way you’ll end up with 2 tray icons but just a single background process.

Thank you. I was experimenting with that yesterday, but was unsure how the flag worked exactly. It is impossible to run more than 2 instances though, right? I would personally want to start more than that, and have a separate icon displayed for each of them.

It would be neat to be able to pass multiple arguments like syncthingtray --connection config1 config2 config3 or similar.

I’ve implemented the issue you’ve opened on GitHub and implemented the possibility to specify multiple connection configurations at once and to specify the configuration directory. The only thing missing is an option to prevent the single-process behavior.

If you want to help me testing, you can find a recent development build here:

Thank you very much :slightly_smiling_face:.

I have tried starting the program using the command

syncthingtray --config-dir-path . --connection config1 config2 config3

and everything seems to be working as expected.

I hope that you will not mind, but there is one more thing that I would like to ask. I am not sure whether this is OS-specific, but when hovering over each tray icon, a tooltip pops up saying

Syncthing is ...
Connected to ...

Would it be possible to have the name of the config also displayed on the top of the tooltip? This would make it easier to quickly know which icon belongs to which device.

On a similar vein, I think that it would be useful to be able to set custom colours per config rather than having one colour set for the entire program. This way it would be possible to distinguish the icons without even interacting with them (e.g. by making one config blue, the other green, and yet the other one red, etc.). I guess though that implementing something like this would likely require a lot of work, so I will not dare to be the one asking for it.

I made it include the name of the config within the tooltip if there are 2 or more icons displayed.

Setting the custom colors per connection config would be quite some effort, indeed. I’ll maybe implement it at some point. However, I now also added an opt-out flag for the single-process behavior. That means one can now simply start multiple processes. In combination with the --config-dir-path argument that allows running completely different configurations at the same time (at the cost of having a separate process per tray icon and maintaining completely separated configurations).

1 Like

Thank you again! If you happen to have a new development build, then I am willing to test.

I am mostly worried about the increased RAM usage with multiple processes, but will likely go this route anyhow just to have each icon in a different colour. Maintaining different configurations should not be a big deal though, as it seems that most of the .ini file can simply be cloned and re-used, except for the icon related stuff.

I’ve created a new Windows build (available under the old link). It also has sorted devices.

1 Like

I have tried the new build and everything seems to work as expected. Thank you again.

Although I must say that I would prefer to be able to always include the config name in the tool tip (and possibly the popup window) even if there is only 1 icon displayed, the reason being that it is helpful when running multiple instances. I know that I can now use colours to differentiate, but still :nerd_face:.

New release v1.0.1 is available.

The most notable change is that directories/devices are now sorted by label. Here’s a full list of changes: https://github.com/Martchus/syncthingtray/compare/v1.0.0...v1.0.1

3 Likes

The release v1.1.0 has been available since a few days.

Not much has changed. Here’s a full list of changes: https://github.com/Martchus/syncthingtray/compare/v1.0.1...v1.1.0


The interesting part is that Qt 6.0.0 has recently been released as well and that the latest Syncthing Tray release already supports it (apart from the KDE integration which is blocked by various KDE libraries not being ported yet).

So if one is interested, one could already try out Qt 6. For Arch Linux I’ve already created syncthingtray-qt6 which also shows generally which build flags are required to use Qt 6. It is co-installable with the Qt 5 based version. I’ll still keep the Qt 5 version as the default because Qt 6 currently still lacks Plasma platform integration and most 3rd party Qt Widgets styles are likely not available yet.

To all Windows users: I would like to use Qt 6 for the Windows binaries available on GitHub. However, Qt 6 supports only Windows 10 as far as I know. Are there any users who still use an older Windows version? I could provide Qt 5 builds alongside Qt 6 builds if support for older Windows versions is requested.

2 Likes

Thank you very much for the new version.

Windows 7 is unsupported by MS, so dropping support for it would be understandable, but it seems that Qt 6 also does not support Windows 8 (supported by MS until 2023) and also any 32-bit (x86) version of Windows, which is not great.

I personally do use 32-bit versions of Windows 10 on Intel Atom machines.

I wasn’t aware of that since I’m also not relying on their binaries. In fact I have already built Qt 6 for i686-w64-mingw32. When I have builds of Syncthing Tray ready it would be interesting to know whether they actually run on the old hardware.

(Note that I compiled and ran Syncthing and Syncthing Tray’s CLI already on s390x which is also not likely to be supported. So not supported luckily doesn’t mean that it doesn’t work.)

Yeah, I am just relying on the information from https://qt.io/blog/qt6-development-hosts-and-targets, i.e. I have not tested anything myself. However, on the same site they claim that Windows 8 is no longer supported by MS, which is not the case, so I guess that all the statements do need to be verified anyway.

Here are Qt 6 based Windows builds if anyone wants to test: Server dashboard

I only tested under a recent Windows 10 under x86_64. The i686 builds run there as well. I had to disable translations for now because the CMake macros apparently don’t work when cross compiling. (Translations do work in Linux builds.) It would be interesting to know whether they work under older Windows versions and 32-bit as well.

They were likely not considering the extended support.

I can confirm that the build seems to be working fine under Windows 7 x86 :+1:.

They lumped Windows 7 and 8 together though, as if they were in the same situation. From an individual user’s perspective, there is no real difference between the mainstream and extended support, as long as security updates are still released.

Plus, it would be similar to saying that Red Hat discontinued support for an older version of RHEL, even though the maintenance support cycle is still going on. I am using Red Hat as the example, as they seem to have the same 5+5 model as Microsoft when it comes to supporting their OS (at least when it comes to the enterprise versions of the latter).

Anyhow, please excuse my digression, as it is not really directly related to Syncthing Tray anyway :disappointed_relieved:.

QT6 version working fine under Windows 7 x64. But fonts and UI elements have strange rendering:

What Qt Widgets styles does it offer in the Qt settings? The one which looks more modern would be the “WindowsVista” style. You should also be able to configure the font to use manually.

Does the QT5 one look different in the same system?

For me, there is no difference in the look between the two, and I have also tested them with the Windows Classic theme.

Edit: The QT6 version does seem to follow the system DPI better. In the QT5 version, only some text gets resized based on the DPI, while in the QT6 version, all the text seems to get resized properly.

Both screenshots taken with 125% DPI. View in full size or download and examine the image files to see the difference.

Qt5:

image

Qt6: