XYstylEZ - Visual Themes for your XYplorer, made easy

Discuss and share scripts and script files...
SkyFrontier
Posts: 2341
Joined: 04 Jan 2010 14:27
Location: Pasárgada (eu vou!)

Re: XYstylEZ - Visual Themes for your XYplorer, made easy

Post by SkyFrontier »

The core code of Theme.xys is (besides elegant) pretty harmless, as far as I can tell.
I've splitted the keys' template of both systems (his and mine) to compare them side by side so this may give another hint.
Essentially, *BOTH* are just automating the changing of pretty basic values which are already provided via GUI, so those scripts are as potentially dangerous as playing with XY interface itself.

If you can provide a way to accurately reproduce the problem, this would help much.
Still hunting - when time permits.

The strangest thing that happened was related on those lengthy posts: at certain point I *had* to disable auto-restart to apply colors as this was causing Windows to interpret XY as being frozen. Still haven't observed the other issue you related regarding session state preservation. Again, steps to reproduce would be welcome.

Glad you're happy with the chromatically improved, ostensively eye-relaxing brand-new-old XY rediscovered feature. I'm captivated by its simplistic power to deliver some relieve from desktop boredom. Never cared much (except for the golden win98 Talisman days!), now just can't live without it!
New User's Ref. Guide and Quick Setup Guide can help a bit! Check XYplorer Resources Index for many useful links!
Want a new XYperience? XY MOD - surfYnXoard
-coz' the aim of computing is to free us to LIVE...

SkyFrontier
Posts: 2341
Joined: 04 Jan 2010 14:27
Location: Pasárgada (eu vou!)

Re: XYstylEZ - Visual Themes for your XYplorer, made easy

Post by SkyFrontier »

Compared all keys from the 2 methods.
They deal with the *exact same settings* (except that later I abandoned FVS handling - XYstylEZ Themes Tool reflects that), so concerning functionality, they are much the same, ie, either one system or the other will or will not produce the behavior you're experiencing. It *could be* other external factor, like programs that refresh the screen often, videos being played. But if you consistently have this issue and may have the steps to get it, please let me know.
New User's Ref. Guide and Quick Setup Guide can help a bit! Check XYplorer Resources Index for many useful links!
Want a new XYperience? XY MOD - surfYnXoard
-coz' the aim of computing is to free us to LIVE...

aurumdigitus
Posts: 1075
Joined: 30 May 2008 21:02
Location: Lake Erie

Re: XYstylEZ - Visual Themes for your XYplorer, made easy

Post by aurumdigitus »

In the great universal scheme of things, whether or not the button is able to show number of changes since last save is probablely inconsequential except for two factors. One, being rather Obsessive-Compulsive knowing the actual count is a feedback on the amount of tinkering that has been done. Second, wondering what change that occurred is interfering with it.

Being able to trace the error will be excoriating difficult. The only observation is that before the first invocation of Theme.xys it worked and following first use it is not.

Sorry there aren't clues to offer. Will try a couple of things but will be surprised if they turn any thing up. It may simply be one of those elusive anomalies that has to be lived with. :(

SkyFrontier
Posts: 2341
Joined: 04 Jan 2010 14:27
Location: Pasárgada (eu vou!)

Re: XYstylEZ - Visual Themes for your XYplorer, made easy

Post by SkyFrontier »

Oh, no, you don't HAVE to live with that...
Let's try another thing: XY *has* an autobackup feature.
Whether or not it was triggered by the script, can't tell.
BUT:

1. backup your current .ini;
2. go to <xyData>\AutoBackup, then put it into use overwriting current (backep-up!) one;
3. use the theme of choice - not the Theme.xys. Themes CAN'T change a thing (as far as I'm aware) other than stored configs;
4. tell me if that causes the problem again.

Relax - you don't need to tell me the usefulness of Save Setts clues as I AM that security-obsessive.
That's the reason why I included the self-preservation codes BOTH in Themes Tool AND Themes themselves (v2, of course!).

So the basic recommendation is:

-Use a theme.
-want it stored separately? Use the Themes Tool.
-had a problem? Let me know.
(as said, I doubt Themes.xys have the power to cause your issue - but, this is computing...
anything can happen in this very unique science.)
New User's Ref. Guide and Quick Setup Guide can help a bit! Check XYplorer Resources Index for many useful links!
Want a new XYperience? XY MOD - surfYnXoard
-coz' the aim of computing is to free us to LIVE...

aurumdigitus
Posts: 1075
Joined: 30 May 2008 21:02
Location: Lake Erie

Re: XYstylEZ - Visual Themes for your XYplorer, made easy

Post by aurumdigitus »

Did not have to work today. It is a "Level 3 Snow Emergency" which means stay off the roads under penalty of arrest. Therefore could spend much time playing with themes.

May have figured out trouble spot but am too embarrassed to admit what it might be. Somewhere between operator error and culpable negligence.

Sometimes to build it is necessary to tear down. Accordingly, tomorrow all files D/L'ed on this will be deleted and XY reverted to last save. Then start from scratch. Am hoping to get it right this time around! :oops:

SkyFrontier
Posts: 2341
Joined: 04 Jan 2010 14:27
Location: Pasárgada (eu vou!)

Re: XYstylEZ - Visual Themes for your XYplorer, made easy

Post by SkyFrontier »

Play safe, Aurum! Make it 3 installations, keeping the basic, one with Themes.xys and the other with the Theme MNGMNT set.
I have no regret on anything nor undesired side-effects - otherwise would put a word on caution or disabled a feature as I did with the
auto-restart one.
Whatever it is, count on me. And if you discover a clear hint on what NOT to do, please let us know.
;)

(your other script may reach light of the day tomorrow - or in a few hours, at best. Core functionality is ready since your post, but as always,
other ideas came so had to delay)

Regards,

SF
New User's Ref. Guide and Quick Setup Guide can help a bit! Check XYplorer Resources Index for many useful links!
Want a new XYperience? XY MOD - surfYnXoard
-coz' the aim of computing is to free us to LIVE...

klownboy
Posts: 4397
Joined: 28 Feb 2012 19:27
Location: Windows 11, 25H2 Build 26200.7171 at 100% 2560x1440

Re: XYstylEZ - Visual Themes for your XYplorer, made easy

Post by klownboy »

Hi, here's another version or generation of a theme script. It's based mostly on binocular222 version. I take absolutely no credit for this. The real meat and potatoes of changing themes is binocular222's and SkyFrontier's code and I want to thank both SkyFrontier and binocular222 for the scripts and ideas. My chief change was to flag the "current" theme in the menu and to display that theme as the default in the "save as" dialog box. It makes it much easier to remember which theme you were working on if you want to save it as the current theme (i.e., update) or as a different theme name. I was modifying themes continually and forgetting which one I was currently updating. I also provided a delete theme capablility.
theme_capture.PNG
theme_capture.PNG (37.27 KiB) Viewed 5767 times
Also, SkyFrontier had mentioned that it would be great if Don would implement icon display capability in SC popupmenu and that got me thinking. I second that motion by the way. Until then, I thought there's got to be away to display a theme menu with icons by simply generating a script on the fly and loading it, and deleting it afterwards similar to what SkyFrontier does in his version. The script uses standard built-in icons for the "Save as" and "Delete Theme" menu items and uses a list of icons within the script for the other menu items which you can change as you wish. The result is, the menu is populated with totally meaningless icons for each theme. You could instead use a small folder of icons to generate this icon list. Note, I used different icons here at home that are more theme-like. For the posted script I had to use XY built-in icons for compatablity reasons. You should change the icons along with the appropriate paths in the script to display some more visually pleasant. I also included my present theme folder. My themes, all based on those of SkyFrontier and binocular222, are a bit more subdued since I'm an old fart.

Yes, I realize themes are basically fluff to pretty up XY and this is just adding more fluff, but sometimes it's the fluff that makes you want to use it and it keeps the boredom down. It seems relatively fast even though it's generating variable lists and writing and loading a file. I didn't want any user intervention when simply changing themes since you'd want that to be done as quickly and seamlessly as possible.
Theme.zip
(25.05 KiB) Downloaded 415 times
Thanks again to binocular222 and SkyFrontier,
Ken

Edit: I think my next version will have an icon file path specified in each theme ini file. That way the icon could be more specific or more closely associated with a particular theme. When saving a new theme we could associate an icon resource to the new theme and maybe even change the icon of existing themes.

SkyFrontier
Posts: 2341
Joined: 04 Jan 2010 14:27
Location: Pasárgada (eu vou!)

Re: XYstylEZ - Visual Themes for your XYplorer, made easy

Post by SkyFrontier »

Hi, Ken!

Interesting... but I just can't see the current theme highlight in action!
Also, some themes need a revision as, as you said, they had their color schemes inherited from a previous theme ("I was modifying themes continually and forgetting which one I was currently updating" - I know what you've been thru...), generating similar color schemes under different names. 'Solaris', for instance (unless you're totally deviating from original color schemes - then I take my words back).

1. did you noticed the 'false freezing' bug when changing themes upon auto-restart?

2. can you please pack a theme set *with* required icon set, matching icons x themes on menu? Curious to see that...

3. as far as I can see, you're revising every visual aspect of each theme, making more appropriate colors to details like background'ed tabs backgrounds ('ClrTabOtherBack', I guess), which I totally ignored in my themes' first run, generating some obscene results. Is that right?

Great job! Thanks for the addition!

__________
P.S.: My automatic themes creator, balanced colors is almost ready for publication. Just need few more testings and fix a little intermittent bug, plus a rock-solid ini backup feature. All in all, after auto-creating 200+ themes already, I see it's pretty stable concerning color balancing. I also made it possible and simple to work with several pre-defined color-schemes algorithms, but version 1.0 will have a single one - WHICH IS MORE THAN ENOUGH!, believe me, as it's generating themes from single base color for tree + panes to totally different colors for each element (tree or panes, but 'panes' being kept consistent). Now, it's also saving each auto-generated theme under a 'Themes\RandomlyGenerated' folder, no questions made, .xys format.

To sum up: you'll be able to change your color-schemes in the blink of an eye to something totally new, also having base themes to fine tune when the inspiration has gone away.
Pretty cool!
New User's Ref. Guide and Quick Setup Guide can help a bit! Check XYplorer Resources Index for many useful links!
Want a new XYperience? XY MOD - surfYnXoard
-coz' the aim of computing is to free us to LIVE...

klownboy
Posts: 4397
Joined: 28 Feb 2012 19:27
Location: Windows 11, 25H2 Build 26200.7171 at 100% 2560x1440

Re: XYstylEZ - Visual Themes for your XYplorer, made easy

Post by klownboy »

Hi SkyFrontier,
SkyFrontier wrote:Interesting... but I just can't see the current theme highlight in action!
I think that's because I used a special ASCII character Dec "017" which you obtain by holding "alt" key down while pressing 017 on the numpad - see note in script and picture. It may not have translated or the font may not have produced it or more than likely it's a Unicode issue again. I also used couple of bell characters in the theme menu title which probably didn't display either. I changed the "flag" to a simple asterisk * instead on this version so hopefully that works alright.
theme_capture2.PNG
theme_capture2.PNG (18.55 KiB) Viewed 5740 times
Also, I've made a set of simple icons that better represent the theme color which are used in the theme menu. Place the icon folder "XYthemeIcons" in your XYplorer default icon folder (i.e., where ever the folder <xyicons> is located). The theme "folder" should be placed off your <xyscripts> folder.

I'm not experiencing any freezing once so ever. Though I'm not sure what you mean by the auto restart? Are you referring to something other than the normal "restart without saving" (#190 or exit "nr") which is used in the script? I'm not sure what the issue might be. The change to a new/different them takes place very quickly on restart without saving.

And yes, you're absolutely right I have played with the original theme colors to the point where they're nothing like the original at least in some cases. But, really that's what it's all about, making up themes that suit your liking and the names themselves become a bit less important.Please let me know how you make out.
theme.zip
(30.68 KiB) Downloaded 484 times
Thanks,
Ken

Edit: I had a change in heart concerning where the XY theme Icons should go. It makes much more sense to keep them separate in a "XYthemeIcons" folder off the your default XY icons folder <xyicons> then to mix them up in your normal icons folder. So I tweaked the script to reflect this change.

SkyFrontier
Posts: 2341
Joined: 04 Jan 2010 14:27
Location: Pasárgada (eu vou!)

Re: XYstylEZ - Visual Themes for your XYplorer, made easy

Post by SkyFrontier »

So here it is...
Random Themes Creator
.

Designed to provide both security, simplicity and beauty, the Random Themes Creator is easy to operate, requiring just a touch on a CTB or the press of a CKS once configured. No external dependencies, no need to put on special folders or anything like that. It can even be run from 'scripting > run script...\run script again'.

Once fired, it will

-generate a random combination of colors, minding a minimum color coherence as much as automation allows it - *but it works!*, you need to see it;
-backup your current xyini under '<xydata>\AutoBackup\[1, 2, or 3]\' on each run, preserving the last 5 and 10 past days' backups intact, plus the most recent .ini prior to changing colors;
-create a Theme File under '<xyscripts>\Themes\RandomlyGenerated\' with a unique name so all your random themes are preserved for later reuse;
-apply currently generated theme using the "restart without saving" feature (which now is bug-free again on this script)


all of this without any interaction. No prompts, no questions, no dialogs, no warning screens - just click and have all of the above.

The code is ready to receive color schemes, which I made easy to work with, ensuring more randomness for the theme (auto) creation task. Currently a single scheme is implemented, but you'll see it's more than enough to provide completely different themes each time the script is used. On a series of 200 themes created, 31 of them were found to be exact duplicates - which is fair, as sometimes you may want to have again a previously used theme without loading all of the saved themes. Yes, the limitation is present: you can't preview a theme prior to its actual application.

Want a new theme? Just run the script. Easy like that.

Then, it's up to you to refine it and share using the other tools presented in this thread.

Have a nice day!
Attachments
RandomThemesCreator.xys
(32.46 KiB) Downloaded 751 times
New User's Ref. Guide and Quick Setup Guide can help a bit! Check XYplorer Resources Index for many useful links!
Want a new XYperience? XY MOD - surfYnXoard
-coz' the aim of computing is to free us to LIVE...

klownboy
Posts: 4397
Joined: 28 Feb 2012 19:27
Location: Windows 11, 25H2 Build 26200.7171 at 100% 2560x1440

Re: XYstylEZ - Visual Themes for your XYplorer, made easy

Post by klownboy »

Hey SkyFrontier, it works and it's cool. :appl: I did have a few themes come up in which the text in the tabs was unreadable though (i.e., obviously the text color was too near in "color" to the background color). I suppose it's just due to the randomness of the script. I haven't looked at the script code in any detail yet, but could you place some further restriction on how close the color RGB values can be for certain combos like tab text and tab background and other text/background combos?

I looked at the AutoBackup folder after running the script about 10 times. There were only folders 1,2,3 and only folder 2 had an xyplorer.ini file in it. I'm not sure why that was the case, but I figured I let you know.

By the way, did you experience any of the restart delays when running my script? Here, your script takes longer than mine, but that's explainable since it's doing much more work to actually generate the new theme from scratch as well as save it.

Thanks again,
Ken

SkyFrontier
Posts: 2341
Joined: 04 Jan 2010 14:27
Location: Pasárgada (eu vou!)

Re: XYstylEZ - Visual Themes for your XYplorer, made easy

Post by SkyFrontier »

klownboy wrote:Hey SkyFrontier, it works and it's cool. :appl: I did have a few themes come up in which the text in the tabs was unreadable though (i.e., obviously the text color was too near in "color" to the background color).
Hello, Ken! Hi again!
Yes, it works and I'm very pleased by the results I'm getting as at the early development stages I was skeptical and thought this would be impossible to script so to have usable themes. But to my amazed surprise the color schemes idea proved to be able to produce some very beautiful themes with much varying combinations. Sometimes the algorithm won't work well, but it's a mere matter of fine tuning the resulting theme - or just push the button again and see something totally new. As said, I consider this very interesting as we're getting random themes with a (my opinion) high rate of success = saving time while producing a massive amount of random combinations of colors which, as you can see, are meaningful most of the time.
klownboy wrote: I looked at the AutoBackup folder after running the script about 10 times. There were only folders 1,2,3 and only folder 2 had an xyplorer.ini file in it.
Those folders are filled in the run of 15 days, ie, each cycle of 5 days the scripts jumps to the next folder writing there the recent changes and keeping intact the last used folder. That way you'll always have a fresh backup, plus two older ones to resource to in case anything goes wrong with your .ini by any means. Script is safe, even the basic Theme Set I published hasn't had any issue reported despite the ~70 downloads made. But I'm a bit picky when it comes to system security. It's never enough.
klownboy wrote: By the way, did you experience any of the restart delays when running my script? Here, your script takes longer than mine, but that's explainable since it's doing much more work to actually generate the new theme from scratch as well as save it.
They match, in terms of loading times. Actually, it takes a bit more time to chose a theme from the list, plus getting rid of the two Windows warnings on XY being frozen (reason why I abandoned the auto-restart ("restart w/o saving"), but actual loading takes almost the same here.

Soon I'll test your icon-filled script plus giving comments to the post itself.

If you have any idea on how to deal with backcolor vs fonts, please let me know. I'm trying to figure it out but it's very low prio now. The color schemes method partially solves that (for instance, current tree folder tends to get very light and hardly readable - I'll probably script a subroutine specially to deal with that, but another color scheme artificially solves that. Easily, I guess). Have to try.
New User's Ref. Guide and Quick Setup Guide can help a bit! Check XYplorer Resources Index for many useful links!
Want a new XYperience? XY MOD - surfYnXoard
-coz' the aim of computing is to free us to LIVE...

klownboy
Posts: 4397
Joined: 28 Feb 2012 19:27
Location: Windows 11, 25H2 Build 26200.7171 at 100% 2560x1440

Re: XYstylEZ - Visual Themes for your XYplorer, made easy

Post by klownboy »

SkyFrontier wrote: I consider this very interesting as we're getting random themes with a (my opinion) high rate of success = saving time while producing a massive amount of random combinations of colors which, as you can see, are meaningful most of the time.
You're quite right, I've already used your Random Theme generator to come up with a couple of new themes. I typically end up doing only a few minor tweaks such as getting pane 2 slight off color from the pane 1 or dialing down the intensity a little and then I save in my version as well. Thanks again.

SkyFrontier
Posts: 2341
Joined: 04 Jan 2010 14:27
Location: Pasárgada (eu vou!)

Re: XYstylEZ - Visual Themes for your XYplorer, made easy

Post by SkyFrontier »

klownboy wrote:
SkyFrontier wrote: I consider this very interesting as we're getting random themes with a (my opinion) high rate of success = saving time while producing a massive amount of random combinations of colors which, as you can see, are meaningful most of the time.
You're quite right, I've already used your Random Theme generator to come up with a couple of new themes. I typically end up doing only a few minor tweaks such as getting pane 2 slight off color from the pane 1 or dialing down the intensity a little and then I save in my version as well. Thanks again.
That's when color schemes come into play, Ken.
As you can see,current scheme goes like:
main color 1, tree and numbers column
main color 2, pane 1 & pane 2.

I'm working on adding more variations like the one you mentioned (pane 1 != pane 2), also variation ranges to increase the randomness in the schemes themselves.

Discarding one or another theme which is pure bogus, I'm finding the majority of them usable and some fine tuning lead to perfection.

I still can't see the marking. I checked, the asterisk is in the code but later I'll try to check the code itself so I may have better chances of getting this working on my system.

Hey: I JUST LOVED the custom icons for the theme set! They're great, Ken! Haha! Nice catch.

The auto-restart ("restart w/o saving") problem was the reason why I abandoned (see http://www.xyplorer.com/xyfc/viewtopic. ... 15#p101144, "Previous incarnations of the themes were capable of restart XY automatically. Removed...") the feature. I bump on this as I'm willing to understand what's causing it. Nothing to worry about - it's the CLOSING instance which is reported (twice!) frozen by Windows, but new users may think it's an XYplorer issue instead of Windows'. Sort of. As you can see, the Random Themes Creator have the feature enabled as it's not producing the freeze unlike the original v2 themes, unpublished. The Themes Tool produces themes which won't auto-restart to apply new colors.

By reading your post, it seems you thought I was against the full repaint of any theme by asking the question. No, I'm not - that's why I shared all the tools I created to either create or modify themes. More to come.
_____________
Direct download of Random Themes Creator = http://www.xyplorer.com/xyfc/download/file.php?id=5033
Direct download of Theme Set = http://www.xyplorer.com/xyfc/download/file.php?id=4892
Direct download of Themes Tool, plus Helpers = http://www.xyplorer.com/xyfc/download/file.php?id=4918
New User's Ref. Guide and Quick Setup Guide can help a bit! Check XYplorer Resources Index for many useful links!
Want a new XYperience? XY MOD - surfYnXoard
-coz' the aim of computing is to free us to LIVE...

klownboy
Posts: 4397
Joined: 28 Feb 2012 19:27
Location: Windows 11, 25H2 Build 26200.7171 at 100% 2560x1440

Re: XYstylEZ - Visual Themes for your XYplorer, made easy

Post by klownboy »

Hey SkyFrontier,
I'm glad you like the silly icons. I was thinking I may further tweak the code such that when you save as a theme, you will be able to associate the theme with the current theme icon (as you can now - when saving as the same theme) or save the theme with any icon you choose from the theme icon folder instead of just the default theme icon. Fiddling with existing ones and making new icons is quite easy with Greenfish Icon Editor Pro 3.31 (open source freeware).

I'm really disappointed and stumped as to why you can't see the asterisk or the original ASCII character Dec "017". I still think it may be a Font or Unicode issue. This issue has come up before here on the XY forums. Since both the asterisk and original character work for me it hard for me to troubleshoot. Do you have a permanent variable called "$p_theme" being saved as the current theme? That variable would probably not exist until the second run. The theme files were being saved using "writefile" in mode "tu". I wonder if using "t" might help which saves in text or if necessary Unicode. I'll investigate further...
Note: You could also temporarily comment out the line which deletes "themes_ahoy.xys" to see what it looks like after the script is run (i.e., check if the current theme has the * flag to the right of the them name, etc.).

No, my only point about themes in general was the "Need for Speed" when changing themes, at least as fast as possible, since most people wouldn't want to bother changing themes unless it was very quick and without further user intervention after the theme selection. If you are using tools like your creation tools obviously that's a different story. The more attributes we can tweak the better as long as the speed isn't affected.

Don always has so much on his plate between the continual updates and forum wishes etc., but theme capability would be a nice built-in addition to XY and it would go hand in hand with the "user.ini" request. Theme changing would probably be faster than we can do it. It would certainly look good on his XY Features web page as far as drawing in new customers.

Thanks again,
Ken

Post Reply