Hi! I'm trying to create a Custom Context Menu, and I want to add the option for Variants. I have this:
ContextTitle11=Variants
ContextAction11=[!SkinMenu]
The thing is I have the bang to open the skin menu which is great, but I don't want it to open that menu with all the options I wanted to show just the variants the other .ini options for that instead of opening the whole menu. I want it to open just that section. Any ideas on how to do that?
It is currently April 27th, 2024, 10:32 pm
Custom Context Menu
-
- Posts: 5
- Joined: January 11th, 2024, 2:22 pm
-
- Rainmeter Sage
- Posts: 7178
- Joined: February 27th, 2015, 2:38 pm
- Location: Terra Yincognita
Re: Custom Context Menu
If I understand correctly what you want, displaying only a specific submenu from the skin's context menu (in this case, only the Variants submenu) is not possible, but you could reproduce it by creating the said menu choices and actions yourself...BaconCR wrote: ↑January 11th, 2024, 2:33 pm Hi! I'm trying to create a Custom Context Menu, and I want to add the option for Variants. I have this:
ContextTitle11=Variants
ContextAction11=[!SkinMenu]
The thing is I have the bang to open the skin menu which is great, but I don't want it to open that menu with all the options I wanted to show just the variants the other .ini options for that instead of opening the whole menu. I want it to open just that section. Any ideas on how to do that?
-
- Posts: 5
- Joined: January 11th, 2024, 2:22 pm
Re: Custom Context Menu
Yes, that's what I want, but I have no knowledge on how to do it. I kind of understand a bit certain things in the code, but I have no idea how to write to create that menu, by any chance you have some experience with it?Yincognito wrote: ↑January 11th, 2024, 6:07 pm If I understand correctly what you want, displaying only a specific submenu from the skin's context menu (in this case, only the Variants submenu) is not possible, but you could reproduce it by creating the said menu choices and actions yourself...
-
- Posts: 34
- Joined: December 20th, 2023, 9:18 am
Re: Custom Context Menu
I know this one :
Write:RightMouseUpAction=[!SkinCustomMenu] in [Rainmeter]. If this is skipped, then the regular context-menu appears and you can click "Custom Skin Action" to use the custom-menu.
Doing the above will open the custom menu directly and replace "SomethingX" with suitable heading and <SomethingX> with action like [!SkinMenu] or whatever you like.
Example:
Reference: 1. https://forum.rainmeter.net/viewtopic.php?t=13674 for Actions.
Edit: 2. https://forum.rainmeter.net/viewtopic.php?t=43139 for Right-Click Action.
Write:RightMouseUpAction=[!SkinCustomMenu] in [Rainmeter]. If this is skipped, then the regular context-menu appears and you can click "Custom Skin Action" to use the custom-menu.
Code: Select all
ContextTitle=Something1
ContextAction=<Something1>
ContextTitle2=Something2
ContextAction2=<Something2>
Example:
Code: Select all
[Rainmeter]
RightMouseUpAction=[!SkinCustomMenu]
ContextTitle=Run Notepad
ContextAction=["Notepad.exe"]
Edit: 2. https://forum.rainmeter.net/viewtopic.php?t=43139 for Right-Click Action.
-
- Rainmeter Sage
- Posts: 7178
- Joined: February 27th, 2015, 2:38 pm
- Location: Terra Yincognita
Re: Custom Context Menu
Not as much experience as others in this particular case, but I manage. Anyway, if you have difficulties with it, here are some descriptions and examples that might help:
https://docs.rainmeter.net/manual/skins/rainmeter-section/#Context
https://forum.rainmeter.net/viewtopic.php?t=20050
Basically, to do what you want you'd probably use those context menu options from [Rainmeter], and load the desired variant via a suited !ActivateConfig bang (scroll down a bit to find it):
https://docs.rainmeter.net/manual/bangs/#Skin
EDIT: Well, Aryx already provided a very good example of one way of doing it.
-
- Rainmeter Sage
- Posts: 7178
- Joined: February 27th, 2015, 2:38 pm
- Location: Terra Yincognita
-
- Posts: 34
- Joined: December 20th, 2023, 9:18 am
Re: Custom Context Menu
Ahhhh! Changed that now..
-
- Rainmeter Sage
- Posts: 5407
- Joined: April 12th, 2012, 9:40 pm
- Location: Cedar Point, Ohio, USA
Re: Custom Context Menu
You may eventually create a Context Menu to do what you want following the tips and documentation, but alternately, there is also a 'trick' that will step through any number of skin variants.
Use a Mouse Action Bang, for example:
LeftMouseDoubleClickAction=[!ActivateConfig #CURRENTCONFIG#] (note there is no INI file specified).
Add this to the [Rainmeter] section of each skin variant.
With that code, when you double-left-click the skin, the currently loaded variant will be unloaded, and the next variant will be loaded. This works since only 1 variant in the same folder can be active at any time.
Have fun!
:: My DA Gallery :: Rainmeter DA Gallery :: Rainmeter Workshops :: Rainmeter Documentation :: BBCode Guide ::
-
- Posts: 5
- Joined: January 11th, 2024, 2:22 pm
Re: Custom Context Menu
Hi, I tried that option but it's not working. When I double click it opens the program instead of loading the next variant. Here's the code I have.eclectic-tech wrote: ↑January 12th, 2024, 1:10 am You may eventually create a Context Menu to do what you want following the tips and documentation, but alternately, there is also a 'trick' that will step through any number of skin variants.
Use a Mouse Action Bang, for example:
LeftMouseDoubleClickAction=[!ActivateConfig #CURRENTCONFIG#] (note there is no INI file specified).
Add this to the [Rainmeter] section of each skin variant.
With that code, when you double-left-click the skin, the currently loaded variant will be unloaded, and the next variant will be loaded. This works since only 1 variant in the same folder can be active at any time.
Have fun!
Code: Select all
[Rainmeter]
DragGroup=BigSur
Group=Widget | BigSur
Author=Xyrfo and fediaFedia
OnRefreshAction=[!SetTransparency "#opacity#"]
MouseActionCursor=0
MiddleMouseUpAction=!DeactivateConfig
LefttMouseDoubleClickAction=[!ActivateConfig #CURRENTCONFIG#]
Update=-1
Blur=#globalblurenable#
BlurRegion=2,(10-#Padding#),(10-#Padding#),161*#scaledpi#,161*#scaledpi#,#blurcornerradius#
RightMouseUpAction=[!SkinCustomMenu]
ContextTitle=#Settings#
ContextAction=["#@#Config.exe" #Type# "#CURRENTCONFIG#" "#CURRENTFILE#" "#SETTINGSPATH#" "#SKINSPATH#" "#PROGRAMPATH#" "#scaledpi#"]
ContextTitle2=Variants
ContextAction2=[!SkinMenu]
ContextTitle3=#Close#
ContextAction3=[!DeactivateConfig]
ContextTitle4=----
ContextAction4=[]
ContextTitle5=#AddItems#
ContextAction5=[!ActivateConfig "BigSur\Gallery" "Gallery.ini"]
ContextTitle6=----
ContextAction6=[]
ContextTitle7=Refresh Skin
ContextAction7=[!Refresh "#CURRENTCONFIG#"]
ContextTitle8=Refresh All
ContextAction8=[!Refresh "*"]
ContextTitle9=Refresh Rainmeter
ContextAction9=[!RefreshApp]
ContextTitle10=----
ContextAction10=[]
ContextTitle11=#MoreActions#
ContextAction11=[!SkinMenu]
[Metadata]
Version=1.0
Information=BigSur for Rainmeter
License=Creative Commons Attribution-Noncommercial-Share Alike 3.0 License
[Variables]
Type=Mini
@include=#@#Global.inc
@include1=#@#Languages\#MainLanguage#.inc
@include2=#@#\Structure\#Type#\Type.inc
@include3=UserVariables.inc
Name=#PanelName#
[bgEe]
Meter=Image
ImageName=#IconLocation#
LeftMouseUpAction=!execute ["#PanelAction#"]
MeterStyle=Full
x=(22)*#scaledpi#
y=(20)*#scaledpi#
w=(40)*#scaledpi#
h=(40)*#scaledpi#
[bgEe]
Meter=Image
ImageName=#IconLocation#
LeftMouseUpAction=!execute ["#PanelAction#"]
MeterStyle=Full
x=(22)*#scaledpi#
y=(20)*#scaledpi#
w=(40)*#scaledpi#
h=(40)*#scaledpi#
As you can see the second option is called "Variants" the idea is to have the variants that are show on the SkinMenu shown on the Custom Context Menu.
So, the idea is to have it look something like this
If not to have a way to switch variables in an easy way without having to go on the Custom Context Menu to "More actions", then "Variants" ant then select the one I want. But I don't know how to do it. I know the bang I need to use is !SkinMenu but the things is how do I go about just showing the variants rather thatn the whole menu, because for that I already have "More Actions". The LeftMouse is a good option only thing is it did not work and it opens the program. What I want in the end is to be able to switch between variants in just to clicks and not having to go to multiple menus.
-
- Posts: 34
- Joined: December 20th, 2023, 9:18 am
Re: Custom Context Menu
Edit: I accidently read "What I want in the end is to be able to switch between variants in just to clicks and not having to go to multiple menus." In short, opposite of what you asked. I just got that after @Yincognito posted the solution.
Last edited by Aryx on January 12th, 2024, 2:08 pm, edited 1 time in total.