Minor scripting related wishes (a generic thread)

Features wanted...
tiago
Posts: 589
Joined: 14 Feb 2011 21:41

Re: Minor scripting related wishes (a generic thread)

Post by tiago »

As renameitem() has a return "empty string", what's the reason for the XYplorer Scripting warning that bleeds "Did not find: {item}" on each fail?
Please remove it.
Power-hungry user!!!

Twisten
Posts: 204
Joined: 27 Apr 2008 10:30

Re: Minor scripting related wishes (a generic thread)

Post by Twisten »

zer0 wrote:1. Calling those parameters via property() does not return anything, so it is not related to my setup.
Which I'm pretty sure is a result of your setup not supporting it (might be mitigated by a related codec that adds a property sheet handler).
If you search the forum there is a script that retrieves all available properties, which could assist you in testing your setup.
zer0 wrote:2. RegEx is not my strongest suit, so feel free to provide an example before you say "easily" ;)
For example:

Code: Select all

rename r , '\.(\d\d)(\d\d)\. > .X$1Y$2.' ;
would match a set of four digits enclosed in dots and would add X before the first couple of matched digits (represented by $1 in the replacement string, possible because they were enclosed by '()'), and Y between the first couple and the second matched couple of digits ($2).
To expand your knowledge you might want to look up the use of wildcards in regular expressions and the various matching methods relevant for replacements.
If you still need help you could also post a request in the Script Exchange forum.

zer0
Posts: 2673
Joined: 19 Jan 2009 20:11

Re: Minor scripting related wishes (a generic thread)

Post by zer0 »

Twisten wrote:Which I'm pretty sure is a result of your setup not supporting it (might be mitigated by a related codec that adds a property sheet handler).
If you search the forum there is a script that retrieves all available properties, which could assist you in testing your setup.
Sorry to be blunt, but that's a lot of bollocks. Even Don confirmed it here: http://www.xyplorer.com/xyfc/viewtopic. ... 971#p63971
Twisten wrote: For example:

Code: Select all

rename r , '\.(\d\d)(\d\d)\. > .X$1Y$2.' ;
would match a set of four digits enclosed in dots and would add X before the first couple of matched digits (represented by $1 in the replacement string, possible because they were enclosed by '()'), and Y between the first couple and the second matched couple of digits ($2).
Thank you for that example, I will give it a try when I can.
Reporting a bug? Have a wish? Got a question? Use search - View roadmap - FAQs: Forum + XY site
Windows 7/10
Always using the latest stable two-decimal build

serendipity
Posts: 3358
Joined: 07 May 2007 18:14
Location: NJ/NY

Re: Minor scripting related wishes (a generic thread)

Post by serendipity »

@zero:
Does this work?
text (property(#285)."x".property(#283));
It worked for my MP4 video and gives width and height values.
I am on Win7 32bit.

zer0
Posts: 2673
Joined: 19 Jan 2009 20:11

Re: Minor scripting related wishes (a generic thread)

Post by zer0 »

serendipity wrote:@zero:
Does this work?
text (property(#285)."x".property(#283));
It worked for my MP4 video and gives width and height values.
I am on Win7 32bit.
Thanks! Worked for MP4, AVI and WMV files here. Not for MKVs though, but I should be able to live with it.

Now onto that RegEx stuff...
Reporting a bug? Have a wish? Got a question? Use search - View roadmap - FAQs: Forum + XY site
Windows 7/10
Always using the latest stable two-decimal build

TheQwerty
Posts: 4373
Joined: 03 Aug 2007 22:30

Re: Minor scripting related wishes (a generic thread)

Post by TheQwerty »

Code: Select all

get('#178');
Tiny wish that #178 File | Floating Preview be added to the list of command IDs whose state can be retrieved via Get SC.

admin
Site Admin
Posts: 60357
Joined: 22 May 2004 16:48
Location: Win8.1 @100%, Win10 @100%
Contact:

Re: Minor scripting related wishes (a generic thread)

Post by admin »

'kay

klownboy
Posts: 4109
Joined: 28 Feb 2012 19:27

Re: Minor scripting related wishes (a generic thread)

Post by klownboy »

Hi Don, a small wish or maybe two small wishes:

Could you also add get("#functionID") for command #1061 which shows and hides the menu bar? You have it for the other bars, tool, status, address, and tab. It would be nice to have it for the menu bar as well such that all bars could be turned off and on smartly...especially handy to set up the windows for quickly viewing thumbnails using the entire window fully and then returning to the "normal" view with the click of a UDC. See attached XY view with no bars:

As a second request though not as high on ny list would be a command that turned all bars off and on and off though getting support for Get SC might be more difficult for that one.

Thanks,
Ken
Attachments
desktop_capture.JPG
desktop_capture.JPG (47.74 KiB) Viewed 2765 times
Windows 11, 22H2 Build 22621.1555 at 100% 2560x1440

admin
Site Admin
Posts: 60357
Joined: 22 May 2004 16:48
Location: Win8.1 @100%, Win10 @100%
Contact:

Re: Minor scripting related wishes (a generic thread)

Post by admin »

#1 fulfilled. :)

Filehero
Posts: 2644
Joined: 27 Feb 2012 18:50
Location: Windows 10 Pro x64

Re: Minor scripting related wishes (a generic thread)

Post by Filehero »

Heya,

this is my chance!

Code: Select all

#686          | Catalog Above Tree
#666          | Last Size/Minimize Info Panel
#667          | Maximize/Minimize Info Panel
I could expand the LayoutManager in my winter holidays. :)


Cheers,
Filehero

admin
Site Admin
Posts: 60357
Joined: 22 May 2004 16:48
Location: Win8.1 @100%, Win10 @100%
Contact:

Re: Minor scripting related wishes (a generic thread)

Post by admin »

#686 is okay, the other 2 are not layout states in the strict and usable sense but just commands.

Filehero
Posts: 2644
Joined: 27 Feb 2012 18:50
Location: Windows 10 Pro x64

Re: Minor scripting related wishes (a generic thread)

Post by Filehero »

Moin,
admin wrote:#686 is okay, the other 2 are not layout states in the strict and usable sense but just commands.
I see, asking for a state where there actually isn't one is rather difficult. :wink:


Thanks,
Filehero

klownboy
Posts: 4109
Joined: 28 Feb 2012 19:27

Re: Minor scripting related wishes (a generic thread)

Post by klownboy »

Thanks Don, I've already modified my scripts and UDCs to use get(#1061) and have eliminated the need for my compiled AutoHotkey file to sense whether the XYplorer menu was on or off and act appropriately. :appl:

And Filehero, maybe on winter break you can make the "Minimalistic" layout on your fantastic "Layout Manager" http://www.xyplorer.com/xyfc/viewtopic. ... =75#p72966 really minalistic or you could have a new layout called "Bare". :D
Windows 11, 22H2 Build 22621.1555 at 100% 2560x1440

highend
Posts: 13274
Joined: 06 Feb 2011 00:33

Re: Minor scripting related wishes (a generic thread)

Post by highend »

tab() misses the options to get the
a.) home path
b.) iconized state (0|1)
c.) locked state (0|1)
d.) locked home state (0|1)

via tab("get", "home|iconized|locked|lockedHome", [index]);

I'm currently extending the RestoreClosedTab script (http://www.xyplorer.com/xyfc/viewtopic.php?f=7&t=8633) to store and retrieve these values to restore a tab with all it's properties.

Is there any other (scriptable) way to get all those 4 properties in the meantime?
One of my scripts helped you out? Please donate via Paypal

admin
Site Admin
Posts: 60357
Joined: 22 May 2004 16:48
Location: Win8.1 @100%, Win10 @100%
Contact:

Re: Minor scripting related wishes (a generic thread)

Post by admin »

No other ways IMO. Currently I have no time to add this stuff, sorry.

Post Reply