It is currently April 27th, 2024, 6:02 pm

Simulating the Edit Skin feature of the comtext menu from within a skin.

Get help with creating, editing & fixing problems with skins
User avatar
jsmorley
Developer
Posts: 22631
Joined: April 19th, 2009, 11:02 pm
Location: Fort Hunt, Virginia, USA

Re: Simulating the Edit Skin feature of the comtext menu from within a skin.

Post by jsmorley »

BTW, here is an example of editing the skin while ensuring that ConfigEditor is used if found...

Code: Select all

[Rainmeter]
Update=1000
DynamicWindowSize=1
AccurateText=1

[Variables]
EditThisSkin=["#CURRENTPATH##CURRENTFILE#"]

[MeasureEditor]
Measure=Plugin
Plugin=WebParser
URL=file://#SETTINGSPATH#Rainmeter.ini
RegExp=(?siU)(?(?=.*ConfigEditor=.*\r\n).*ConfigEditor=(.*)\r\n)
LogSubstringErrors=0
StringIndex=1
IfMatch=^$
IfMatchAction=[!SetVariable EditThisSkin """["#CURRENTPATH##CURRENTFILE#"]"""
IfNotMatchAction=[!SetVariable EditThisSkin """["[MeasureEditor]" "#CURRENTPATH##CURRENTFILE#"]"""]

[MeterEditSkin]
Meter=String
FontSize=14
FontWeight=400
FontColor=255,255,255,255
SolidColor=47,47,47,255
Padding=5,5,5,5
AntiAlias=1
Text=Edit Me
LeftMouseUpAction=#EditThisSkin#
DynamicVariables=1
Which I confess is just stupidly harder than it should have to be. We probably really should look at:

LeftMouseUpAction=[!EditSkin "ConfigName" ".iniName"]

Using the same format as !ActivateConfig, while defaulting to the current skin.
User avatar
Codger
Posts: 97
Joined: May 29th, 2017, 3:16 pm

Re: Simulating the Edit Skin feature of the comtext menu from within a skin.

Post by Codger »

jsmorley wrote:No, you will not be able to enter anything via the context menus. That is just not what they are for or how they work in Windows.
Just in case I was confusing there. I meant to enter via a meter or whatnot triggered from an option on the context menu. If the menu is the problem I'm slightly less but still happy to make it double clicking on Weather display or something.

I just have absolutely no idea to even beginning looking for data entry commands or ideally routines as I am attempting to avoid learning lua as much as possible.

Hopefully I was just confusing and it isn't impossible.

Update: I missed the rapid fire double response. I see you have already pointed me in a direction. Thank you. The games afoot... :welcome:
[hr][/hr][hr][/hr]
"If you are the smartest one in the room, you are in the wrong room."
User avatar
jsmorley
Developer
Posts: 22631
Joined: April 19th, 2009, 11:02 pm
Location: Fort Hunt, Virginia, USA

Re: Simulating the Edit Skin feature of the comtext menu from within a skin.

Post by jsmorley »

Codger wrote:Just in case I was confusing there. I meant to enter via a meter or whatnot triggered from an option on the context menu. If the menu is the problem I'm slightly less but still happy to make it double clicking on Weather display or something.

I just have absolutely no idea to even beginning looking for data entry commands or ideally routines as I am attempting to avoid learning lua as much as possible.

Hopefully I was just confusing and it isn't impossible.
If you want to collect user input and write it to a file, you will have to use the InputText plugin. While you can have a bang trigger the InputText field, it won't be related to the context menu, but just some input box that will open up on the skin and take mouse focus. Driving that with the context menu might be ugly and not the right way to get there.

https://docs.rainmeter.net/manual/plugins/inputtext/

Lua is just not a factor in this, and would be of no help.
User avatar
jsmorley
Developer
Posts: 22631
Joined: April 19th, 2009, 11:02 pm
Location: Fort Hunt, Virginia, USA

Re: Simulating the Edit Skin feature of the comtext menu from within a skin.

Post by jsmorley »

Codger wrote:The games afoot... :welcome:
Bring your service revolver Watson!
User avatar
Codger
Posts: 97
Joined: May 29th, 2017, 3:16 pm

Re: Simulating the Edit Skin feature of the comtext menu from within a skin.

Post by Codger »

jsmorley wrote:If you want to collect user input and write it to a file, you will have to use the InputText plugin. While you can have a bang trigger the InputText field, it won't be related to the context menu, but just some input box that will open up on the skin and take mouse focus. Driving that with the context menu might be ugly and not the right way to get there.

https://docs.rainmeter.net/manual/plugins/inputtext/

Lua is just not a factor in this, and would be of no help.
Right at the top (it usually let's me get more invested before pulling the rug) it states you can't be set to TopMost. Which makes perfect sense. Decided staying above fullscreen TV was more important then entering rather than editing the zip code. :)

Going to put my efforts into making it international. Thanks for the info though. Nothing ever gets wasted here...
[hr][/hr][hr][/hr]
"If you are the smartest one in the room, you are in the wrong room."
User avatar
Brian
Developer
Posts: 2686
Joined: November 24th, 2011, 1:42 am
Location: Utah

Re: Simulating the Edit Skin feature of the comtext menu from within a skin.

Post by Brian »

A new !EditSkin bang will be in the next beta.

Usage:
!EditSkin (Opens the current skin with the ConfigEditor)
!EditSkin "Config" "Ini file" (Opens 'Ini file' with the ConfigEditor)

Example: (Using jsmorleys APNews)
!EditSkin "APNews" "APNews.ini"

-Brian
User avatar
Codger
Posts: 97
Joined: May 29th, 2017, 3:16 pm

Re: Simulating the Edit Skin feature of the comtext menu from within a skin.

Post by Codger »

Brian wrote:A new !EditSkin bang will be in the next beta.

Usage:
!EditSkin (Opens the current skin with the ConfigEditor)
!EditSkin "Config" "Ini file" (Opens 'Ini file' with the ConfigEditor)

Example: (Using jsmorleys APNews)
!EditSkin "APNews" "APNews.ini"

-Brian
Excellent. Thanks for letting me know.
[hr][/hr][hr][/hr]
"If you are the smartest one in the room, you are in the wrong room."