bravo-lemur wrote: ↑July 6th, 2021, 12:51 am
Awesome, thanks for the tip! This is the final code I'm using, which seems to be working perfectly:
Glad to help, however I have a comment.
In my opinion it's not alright to refresh everything when you click the slider or the string (through the [!Refresh *] bangs of the LeftMouseUpAction options of the [SysSizeMouse] measure and the [SysSizeSliderText] meter). Refreshes have to be seen extremely sceptic, especially when you refresh everything. There is not needed to refresh every activated skin, because the refresh is a quite distructive operation and should be avoided as much as possible.
So, I'd replace the the above mentioned [!Refresh *] bangs with [!SetVariable SysScale "#SysTempScale#"][!UpdateMeter "SysSizeSliderBar"][!UpdateMeter "SysSizeSliderBlob"][!UpdateMeasure "SysSizeSliderPercent"][!Redraw]. Something like this:
balala wrote: ↑July 6th, 2021, 6:34 am
Glad to help, however I have a comment.
In my opinion it's not alright to refresh everything when you click the slider or the string (through the [!Refresh *] bangs of the LeftMouseUpAction options of the [SysSizeMouse] measure and the [SysSizeSliderText] meter). Refreshes have to be seen extremely sceptic, especially when you refresh everything. There is not needed to refresh every activated skin, because the refresh is a quite distructive operation and should be avoided as much as possible.
So, I'd replace the the above mentioned [!Refresh *] bangs with [!SetVariable SysScale "#SysTempScale#"][!UpdateMeter "SysSizeSliderBar"][!UpdateMeter "SysSizeSliderBlob"][!UpdateMeasure "SysSizeSliderPercent"][!Redraw]. Something like this:
death.crafter wrote: ↑July 6th, 2021, 6:43 am
Actually it is a settings for his suite(latest post in suites). So instead of !Refresh he could use !RefreshGroup. But refresh would be necessary.
If that's related to a suite, then yes, probably the refresh is indeed needed. However as you said, including the skins of the suite into a group and refreshing the group would be much better.
To shortly describe to bravo-lemur how to do this, it's pretty simple: Add a Group=MyGroup option to the [Rainmeter] section of each skin you want to belong to the group (obviously you can name the group as you want, MyGroup is just an example), then replace the [!Refresh *] bang with [!RefreshGroup "MyGroup"]. This way when the refresh is applied, it refreshes only the skins belonging to MyGroup, not all activated skins. This is a good idea even if you're using only skins belonging to the group, because if you later will want to distribute your work, probably many people will use it and will have loaded many other skins, not belonging to the group. In such cases avoiding the refresh of those skins is desirable.
I have just noticed at the beginning of the thread you mentioned that it is possible to create a slider without any plugins. If you mean that the slider would be draggable, could your share your solution, if you already have one?
All the solutions I've seen are either either wonky, or require adding a lot of meters for every step of the slider. I came to a conclusion that it is rather impossible to make an elegant draggable slider without any plugins.
At the moment this is not a very important thing but if you know how to make one easily I will appreciate it very much!
I have just noticed at the beginning of the thread you mentioned that it is possible to create a slider without any plugins. If you mean that the slider would be draggable, could your share your solution, if you already have one?
All the solutions I've seen are either either wonky, or require adding a lot of meters for every step of the slider. I came to a conclusion that it is rather impossible to make an elegant draggable slider without any plugins.
At the moment this is not a very important thing but if you know how to make one easily I will appreciate it very much!
Sorry being late, but finally here is a NOT extremely accurate solution. I (hope at least) didn't say the solution not requiring a plugin would be simple or short. It isn't neither simple and definitely isn't nor short. As you said there are required many - many (11 in the following code) Image meters. I used only 11, but definitely for an accurate work at least 100 would be needed. I didn't add so many for an example skin, but if needed, obviously further such meters can be added. If you add those meters, making them much narrower, the slider will work much better.
Many - many years ago, when the Mouse (or some similar) plugin wasn't yet published, I worked with this implementation and as far as I remember, I got it working pretty well. In meantime the plugins came out and obviously I renounced to use this method (wasn't justified anymore, as you probably figured it out), so after all these years I don't have anymore the code(s) I worked with then.
balala wrote: ↑July 6th, 2021, 8:10 am
If that's related to a suite, then yes, probably the refresh is indeed needed. However as you said, including the skins of the suite into a group and refreshing the group would be much better.
To shortly describe to bravo-lemur how to do this, it's pretty simple: Add a Group=MyGroup option to the [Rainmeter] section of each skin you want to belong to the group (obviously you can name the group as you want, MyGroup is just an example), then replace the [!Refresh *] bang with [!RefreshGroup "MyGroup"]. This way when the refresh is applied, it refreshes only the skins belonging to MyGroup, not all activated skins. This is a good idea even if you're using only skins belonging to the group, because if you later will want to distribute your work, probably many people will use it and will have loaded many other skins, not belonging to the group. In such cases avoiding the refresh of those skins is desirable.
That's a great shout - I've implemented that now. Still learning a lot, so thanks for all the advice
balala wrote: ↑July 6th, 2021, 6:37 pmMany - many years ago, when the Mouse (or some similar) plugin wasn't yet published, I worked with this implementation and as far as I remember, I got it working pretty well. In meantime the plugins came out and obviously I renounced to use this method (wasn't justified anymore, as you probably figured it out), so after all these years I don't have anymore the code(s) I worked with then.
Nice trick though. It certainly works, and it works even better if you have a lower skin update value.
That being said, apart from this plugin being really great and all, I still wonder why folks seem a bit reluctant to use scrolling instead of dragging to control a slider of any kind. No plugin required, yields the mouse variables, adjusting the incrementing / decrementing step can be done easily either through an additional slider or using the mouse variables to control the "speed" of that scrolling, and so on.
balala wrote: ↑July 6th, 2021, 6:37 pm
Sorry being late, but finally here is a NOT extremely accurate solution. I (hope at least) didn't say the solution not requiring a plugin would be simple or short. It isn't neither simple and definitely isn't nor short. As you said there are required many - many (11 in the following code) Image meters. I used only 11, but definitely for an accurate work at least 100 would be needed. I didn't add so many for an example skin, but if needed, obviously further such meters can be added. If you add those meters, making them much narrower, the slider will work much better.
Many - many years ago, when the Mouse (or some similar) plugin wasn't yet published, I worked with this implementation and as far as I remember, I got it working pretty well. In meantime the plugins came out and obviously I renounced to use this method (wasn't justified anymore, as you probably figured it out), so after all these years I don't have anymore the code(s) I worked with then.
Thank you balala for sharing your methd. I wanted to escape "mapping" the bar but I suppose that's the only viable way to do it with the current condition of Rainmeter. I will use your way and I will think about how to optimize it.
Yincognito wrote: ↑July 7th, 2021, 10:25 pm
I still wonder why folks seem a bit reluctant to use scrolling instead of dragging to control a slider of any kind.
A regular computer user would instantly drag the knob when they see it. Besides, it is just more intuitive rather than scroll mouse, in my opinion. And it is just about human's perception based on associations. Remember this dude?