[Applet PYE] Improved an applet. Care to test?

About programming and getting involved with Linux Mint development
Forum rules
Topics in this forum are automatically closed 6 months after creation.
User avatar
Themero
Level 1
Level 1
Posts: 17
Joined: Fri May 21, 2021 11:57 am
Location: UK

Re: Improved an applet. Care to test?

Post by Themero »

yeah programming is way outta my league lol . i'll have a look around and see if i can an icon that will do for light / dark themes
User avatar
Drugwash
Level 5
Level 5
Posts: 733
Joined: Fri Jun 07, 2019 6:40 am
Location: Ploieşti, RO
Contact:

Re: Improved an applet. Care to test?

Post by Drugwash »

The current sets can probably be edited. Haven't tried it yet. There has to be some consistency between images themselves and between sets as a whole.
Will see what can be done.
User avatar
Themero
Level 1
Level 1
Posts: 17
Joined: Fri May 21, 2021 11:57 am
Location: UK

Re: Improved an applet. Care to test?

Post by Themero »

i was looking for a black and white icon , so the black element would show on a light panel and white element on dark , only svg's seem to be black on transparent so no good for a dark background .. would it be easier to include a few different coloured icons so users can choose one that suits them best , and tell them how to change it ?
User avatar
Drugwash
Level 5
Level 5
Posts: 733
Joined: Fri Jun 07, 2019 6:40 am
Location: Ploieşti, RO
Contact:

Re: Improved an applet. Care to test?

Post by Drugwash »

There may be hope. I just found out how to accurately get own x-let folder path, and also how to properly use own icons. It has to do with icon folder structure and adding that folder to theme's search path. However it's possible that icons themselves - SVG type only - should be modified in order to incorporate certain attributes that would allow the theme manager to automatically change their color according to current theme. I'll try to pull that off.

In the meantime there are colored icons that should fit any kind of theme. They can be used by setting the Colorful decorations option to ON in Settings > Extra.That will also add certain colorful features to the sliders GUI as well as the context menu. It's worth a try.

Personally I just can't get why this (forced?) trend towards simplicity after all the efforts made to growing from stick figures to elaborate drawings (icons) and from monochrome to million color displays. :?
User avatar
Themero
Level 1
Level 1
Posts: 17
Joined: Fri May 21, 2021 11:57 am
Location: UK

Re: Improved an applet. Care to test?

Post by Themero »

well if anyone can solve the problem you can :D

i'm playing about with plank dock now cause i'm fed-up with the apps menu lol
User avatar
Drugwash
Level 5
Level 5
Posts: 733
Joined: Fri Jun 07, 2019 6:40 am
Location: Ploieşti, RO
Contact:

Re: Improved an applet. Care to test?

Post by Drugwash »

Oh it's already done. :) It was extremely simple thanks to my foresight in designing icon loader subroutines to account for either theme icon name or GIcon object. 8)

But, as always, there's another problem: a couple of icons misbehave, they don't fully take the assigned color, not even when hovered. Got to the conclusion there must be something in SVG decoding on the x-let side because in Nemo their thumbnails appear correctly, and so they do in Inkscape.
Gonna fire up a 20.1 Mint in VBox to see if the issue propagates or has been fixed. Will publish a new version once I sort things out.

Good luck with Plank. I gave up testing docks a while ago and only added a secondary panel. Which has its bugs too.
User avatar
Themero
Level 1
Level 1
Posts: 17
Joined: Fri May 21, 2021 11:57 am
Location: UK

Re: Improved an applet. Care to test?

Post by Themero »

you'll figure it out , its still working fine here :)
User avatar
Drugwash
Level 5
Level 5
Posts: 733
Joined: Fri Jun 07, 2019 6:40 am
Location: Ploieşti, RO
Contact:

Re: Improved an applet. Care to test?

Post by Drugwash »

Well, hold on to that package because bugs always have a way to creep in. :wink:

I've packed this new version in a hurry because I'm tired and hungry. One never knows what might go wrong with it.
- fixed icon path issue so now it can be installed either as user or as root
- fixed broken icon (my lack of SVG knowledge when editing it); the other one is indeed a bug in 19.2 - works fine in 20.1
- fixed text color in tooltip for dark themes
- added feature to raise and activate Settings window if already open in background, instead of opening it again and again and again...

Current mode icon will be missing from Settings > GUI due to path changes but it will go anyway because it doesn't have value anymore.
There are still issues that can't be fixed in current form and are not my fault, such as broken icon display or unresponsive switches when changing selection in combo, both in Settings > GUI. That's why the redesigning, which will take some time (something I don't quite have much anymore).
There's also an annoying mismatch between slider positions/values due to lack of calculation precision, circular references and my lack of knowledge. Still trying to figure it out.

Here is the new version, hope it works:
applet-pye@drugwash_0.0.5.0.zip
(158.86 KiB) Downloaded 112 times
User avatar
Themero
Level 1
Level 1
Posts: 17
Joined: Fri May 21, 2021 11:57 am
Location: UK

Re: Improved an applet. Care to test?

Post by Themero »

I'll try it on local and root soon as i've finished watching dr who :D

right everything working fine in local , clicks and scrolling and icon looks fine in light and dark themes , and in root no icon .
User avatar
Drugwash
Level 5
Level 5
Posts: 733
Joined: Fri Jun 07, 2019 6:40 am
Location: Ploieşti, RO
Contact:

Re: Improved an applet. Care to test?

Post by Drugwash »

Forgot to say the config file should've been deleted... again. The old paths remain there as values and apparently they won't change. This new version uses exclusively names, without paths or file extensions.
Or maybe i screwed it up again. Did work for me here though after deleting the config. :?

As mentioned in previous comment, there will be no Current mode icon shown in Settings anymore, regardless of it showing or not in the taskbar/panel. That is a vestige from the original B&G where there was a single mode with a single icon and the user had the ability to change it if so desired. Now there are four modes, each with its own icon, and for consistency sake they should remain as delivered with the package. If one really wants a different set of icons then they may change the sunX.png icons in applet's folder (icons/hicolor/...) keeping the same naming convention, for now. Maybe at some point I'll provide an easier way to change all four icons but can't promise anything.

I'll have to check again that Dr. Who series (it's a series,right?), I may like it.

EDIT:
New idea. Could you please perform a couple operations for the root installation and report back if that fixed it? I may have done it in the virtual 20.1 and forgot to apply it to the published package.
1. go to Applet PYE's folder > icons/hicolor/64x64, create a folder called apps, and move the four sunX PNG icons found there into the newly created folder;
2. close by go to icons/hicolor/16x16 and do the same: create apps folder, move the other four PNGs into that folder.

If that won't fix it then I'll have to perform some more testing.
User avatar
Themero
Level 1
Level 1
Posts: 17
Joined: Fri May 21, 2021 11:57 am
Location: UK

Re: Improved an applet. Care to test?

Post by Themero »

you may do , also check put space 1999 , another classic British scifi series ..

yes i know I've gone slightly off topic folks , but the man needs to relax after all his hard work lol
User avatar
Drugwash
Level 5
Level 5
Posts: 733
Joined: Fri Jun 07, 2019 6:40 am
Location: Ploieşti, RO
Contact:

Re: Improved an applet. Care to test?

Post by Drugwash »

Don't worry, nobody else is here. :P
I did watch Space: 1999 quite some time ago, already forgot everything about it. :lol: Actually I watched a lot of sci-fi, it's my favorite genre.
User avatar
Burning Desires 69
Level 2
Level 2
Posts: 93
Joined: Mon Feb 15, 2021 6:30 pm
Location: Your Backyard!
Contact:

Re: Improved an applet. Care to test?

Post by Burning Desires 69 »

Hello, it's been a while. I've been having issues. I got stuck with my PC.
I also lost your Post or Message in the Forums.

So I see you finally Updated your Applet here.


I wanted to Update you with the fact that I can't Install your Applet.
The Place I need to Install it to, i'm completely locked out of, o_@

I've been trying to figure this out for a bit, & haven't had much luck with it.

------------------------------------------------------------------------------------------------

1st.) The Folder it's supposed to install into, was not included in your Zip or Rar Folder,
so all I have is the Files. A previous one from 1.2.2.1 I think has the Folder, which I just
snagged for the New Rar or Zip File which I was interested in Testing.

So you have this set to user/local/shared/cinnamon/applet folder directory, but I don't have this directory.
I have this instead.
user/shared/cinnamon/applet folder directory. This directory is Locked, I cannot drag any anything over to it.
If I use the Applet Manager, I can Install from there to it, though.


Any ideas, or suggestions?
I Loved World = 80's & 90's
World Hates Me = 2016 to 2019
I Hate World = 2020 & ^
They want us to Suffer, then lets speed it up, just burn our Sanity away. Else, Shut It!
A "Scar" Means? Yur About To Find Out, The Hard Way!
User avatar
Drugwash
Level 5
Level 5
Posts: 733
Joined: Fri Jun 07, 2019 6:40 am
Location: Ploieşti, RO
Contact:

Re: Improved an applet. Care to test?

Post by Drugwash »

Oh you'll laugh!

Right now I'm on a recovery session as root. An hour ago ther power went down for a few seconds, the notebook shut down in the middle of working, and since then a login screen came out of the blue (I had autologin enabled and password disabled everywhere) and I just can't log in with any password, even after attempting to change it from a previous recovery session. So much for the "mighty linux"! My old trusty Win98SE went down in flames hundreds of times in ten years and I only had to restore registry about three times - otherwise it used to rise back like a Phoenix every time.

So yeah, I'm a fish out of the water now. How could I help you?
First, please don't use any old version of the original B&G mods - use the latest Applet PYE posted a few comments above.
Second, the path is wrong, maybe you mistyped it; should be installed in home/<username>/.local/share/cinnamon/applets.
If there is no applets folder in that path, create it and unpack the Applet PYE folder in there. If the applets folder is missing it could mean you're always running as root, reason why you could install applets directly in the root path (usr/share/cinnamon/applets). This latest 0.0.5.0 version can be installed there too, I just tested on this recovery session a minute ago.

So please try the above while I attempt to get back to my regular session - if at all possible.

EDIT:
I'm back, thanks to gm10's advices quoted by MrEen here.

Now, if you really want to install this applet as root (accessible for all users) then you have to open the path as root: sudo nemo /usr/share/cinnamon/applets. Then open the applet-pye archive and drag the included folder to an empty space inside the applets folder. After that it should be available in the Applets panel.
User avatar
Drugwash
Level 5
Level 5
Posts: 733
Joined: Fri Jun 07, 2019 6:40 am
Location: Ploieşti, RO
Contact:

Re: Improved an applet. Care to test?

Post by Drugwash »

Published a new version today, v0.0.6.0. Download link is in first post of this topic.

Basically the only (important) change compared to previous v0.0.5.0 found somewhere above is a new Settings panel, completely redesigned.
This was necessary in order to get over a few bugs or shortcomings of the default settings schema. And to suit my personal preference of getting rid of those stupid ugly tumble switches that in real life have been part of my grandparents' childhood as mounted in various hardware devices and appliances. Operating systems are going (very) vintage and I don't like it at all.

- First problem was that locally stored icons wouldn't be displayed in a standard list (GtkTreeView widget) regardless of the relative/full path passed or only icon name complete with adding local path to system theme path.
- Second problem was that there was no way to safely copy text from a field without being able to accidentally modify or delete it, changing the stored data in the process. There were only visually readable (but not copiable) fields (GtkLabel widget) or fully editable fields (GtkTextView widget). All we needed was at least an editable attribute in the settings schema for the textview fields so that the user could select and copy text but not modify it - willingly or not. Or maybe there is and I couldn't find it at the time? The very scarce official documentation regarding x-let creation doesn't mention anything of the sorts.
- Third problem was that I couldn't seem to make four switches and a combobox work together. The operation was simple: choose All, then all four switches would go to ON; choose None, and all four switches would go to OFF; choose Selected and whatever was selected before any of All/None were chosen would get back to their respective states. Well, no can do with the standard schema - switches would acknowledge the change of state but only display it visually after the Settings panel was closed and reopened. So much for visual feedback! :(

This version (as well as the previous 0.0.5.0) can be installed either for the current user or for all users (see details in a comment above). Should work correctly out of the box but in case it doesn't and a previous version was already installed then please delete the corresponding configuration file:
/home/<username>/.cinnamon/configs/applet-pye@drugwash/applet-pye@drugwash.json
then reload the applet (there's a convenient option in tray icon's context menu).

There would be more to say but my time on Earth is limited and probably so is your patience, so I'll spare y'all the laments about the programming languages I had to temporarily learn and juggle with for the last month while working on this thing.

New screenshots for the colorful version; don't worry, the "modern" no-personality wireframe icons are still there in glyph or outline flavors.
Enjoy!
Attachments
AppletPYE0060Settings.png
AppletPYE0060Tooltip+Menus.png
User avatar
Themero
Level 1
Level 1
Posts: 17
Joined: Fri May 21, 2021 11:57 am
Location: UK

Re: Improved an applet. Care to test?

Post by Themero »

Excellent work , you can have a rest now lol :D
User avatar
Drugwash
Level 5
Level 5
Posts: 733
Joined: Fri Jun 07, 2019 6:40 am
Location: Ploieşti, RO
Contact:

Re: Improved an applet. Care to test?

Post by Drugwash »

Thank you very much my friend, indeed I shall rest now. Probably forever. All the best!
User avatar
Drugwash
Level 5
Level 5
Posts: 733
Joined: Fri Jun 07, 2019 6:40 am
Location: Ploieşti, RO
Contact:

Re: Improved an applet. Care to test?

Post by Drugwash »

Not much rest after all. Still alive but not for long (surviving off $10, ha!)

Just published latest version 0.0.6.2 - link in first post.
- fixed not reaching final values after day/night transition
- fixed auto mode not accounting for cloudy mode when cycling modes
- added emoji for cloudy mode in tooltip when colorful decorations are enabled
- minor fixes in the code
User avatar
Themero
Level 1
Level 1
Posts: 17
Joined: Fri May 21, 2021 11:57 am
Location: UK

Re: Improved an applet. Care to test?

Post by Themero »

i was naughty and went back to windows for a few days lol . i'll try it out :P
User avatar
Drugwash
Level 5
Level 5
Posts: 733
Joined: Fri Jun 07, 2019 6:40 am
Location: Ploieşti, RO
Contact:

Re: Improved an applet. Care to test?

Post by Drugwash »

It's OK, I too tested a browser in XP the other day. A VBox installation, of course, since my real XP machine doesn't quite start at first "key" anymore. I was amazed at how quickly it started up and shut down, compared to this Mint. Nothing beats my old trusty 98SE though: 3.5 seconds for full shutdown, and that's for a 667MHz Pentium III CPU with 512MB PC133 SDRAM. No "wait for an hour or two to complete the update before we actually allow you to shut down the computer". I just don't understand what got into people to put up with that kind of garbage.
Locked

Return to “Programming & Development”