Website and Help Typos

Things you’d like to miss in the future...
klownboy
Posts: 4140
Joined: 28 Feb 2012 19:27

Re: Website and Help Typos

Post by klownboy »

I see what you're saying Sammay. All the examples back up what you stated. So it looks like a combo deal, "" means no wildcards and case sensitive and there's no way to separate the two that I can tell. So if that's what you want (i.e., to have the token treated literally) to specify this, you actually need the "" else the token is treated as having wildcards whether you have the "w" or not. It seems like an unusual way though to specify or not specify wildcards (i.e., needing to have the "" to force case sensitivity and no wildcards). I'll have to relook at some old scripts. :) Thanks to both of you.
Windows 11, 23H2 Build 22631.3447 at 100% 2560x1440

PeterH
Posts: 2785
Joined: 21 Nov 2005 20:39
Location: Germany

Re: Website and Help Typos

Post by PeterH »

SammaySarkar wrote:... so, been away from XYplorer for a while? :wink:
Oh - not much scripting for some time.
And not using help :biggrin: :oops:

So I think at least my text about help formatting was OK :?:

After that, the (wrong) rest built up from one to the other - I just was ignoring that [flags=iw] specifies the defaults, not the available options...
(By the way: often each operand desscription explicitely specifies the defaults.)

Still a bit strange is that "" doesn't request defaults, but to not use defaults. Without this I *might* have seen my error.
Win11 Pro 223H2 Gerrman

bdeshi
Posts: 4249
Joined: 12 Mar 2014 17:27
Location: Asteroid B-612 / Dhaka
Contact:

Re: Website and Help Typos

Post by bdeshi »

PeterH wrote:Still a bit strange is that "" doesn't request defaults, but to not use defaults. Without this I *might* have seen my error.
That's a little confusing, yes.
You see there are some cases where a parameter considers being EMPTY or MISSING completely as different values.

Code: Select all

"line 1" echo gettokenindex('c*', 'a|b|cc|C|c', '|',    /*flags*/); //flags is MISSING. Returns 3: 'cc'
"line 2" echo gettokenindex('c*', 'a|b|cc|C|c', '|', '' /*flags*/); //flags is   EMPTY. Returns 0
See?
In line 1, the flags parameter is missing, so the "iw" default is applied, and "cc" matches
but in line 2 it's empty, which means you're explicitly disabling all of case-insensitivity, wildcard-parsing, (and counter). So nothing matches.

Hope that helps.
klownboy wrote: "" means no wildcards and case sensitive and there's no way to separate the two that I can tell. So if that's what you want (i.e., to have the token treated literally) to specify this, you actually need the "" else the token is treated as having wildcards whether you have the "w" or not.

Code: Select all

flags  case-insensitive  wilcards
iw            Y             Y
i             Y             N
w             N             Y
''            N             N
seems to cover all bases. :?
Icon Names | Onyx | Undocumented Commands | xypcre
[ this user is asleep ]

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

Re: Website and Help Typos

Post by klownboy »

Thanks Sammay for the table explanations on flags - case-insensitive - wildcards. I ran some tests that back up your table.
So put into words:
- Essentially if you leave both flags 'iw' out it's like having both flags since, as you and PeterH stated, [flags=iw] specifies the defaults (that's what I was missing as well).
- If you specify "" null, then neither apply (it will be case sensitive and no wildcards.
- If you specify 'i' only, it will be case-insensitive, but the 'w' is no longer the default as it is when you don't specify anything.
- If you specify 'w' only, it will use wildcards but will be case sensitive. The 'i' even though it's the default if left out of the flags, it's no longer the default if only 'w' is specified.

I think the last two statements above were the harder ones for me to 'get'.

Thanks :tup:
Windows 11, 23H2 Build 22631.3447 at 100% 2560x1440

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

Re: Website and Help Typos

Post by admin »

I corrected the slight indenting errors at the parameters (this is BTW a bug in the Help Software I'm using -- I have to work around this all the time).

The rest seems okay to me. All examples are alright. Right?

PeterH
Posts: 2785
Joined: 21 Nov 2005 20:39
Location: Germany

Re: Website and Help Typos

Post by PeterH »

admin wrote:I corrected the slight indenting errors at the parameters (this is BTW a bug in the Help Software I'm using -- I have to work around this all the time).

The rest seems okay to me. All examples are alright. Right?
Correct: part of the syntax isn't really nice, (here: the defaults,) but it's right as written.
Win11 Pro 223H2 Gerrman

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

Re: Website and Help Typos

Post by TheQwerty »

PeterH wrote:
admin wrote:I corrected the slight indenting errors at the parameters (this is BTW a bug in the Help Software I'm using -- I have to work around this all the time).

The rest seems okay to me. All examples are alright. Right?
Correct: part of the syntax isn't really nice, (here: the defaults,) but it's right as written.
Sorry, I'm the one responsible for those defaults: http://www.xyplorer.com/xyfc/viewtopic. ... 190#p92190

The thought was that case insensitivity and wildcards should be the default behavior.
Then it came down to having flags to disable them is more awkward (especially in wording), so it seemed logical to have it be that the default value was including both flags.

PeterH
Posts: 2785
Joined: 21 Nov 2005 20:39
Location: Germany

Re: Website and Help Typos

Post by PeterH »

TheQwerty wrote:Sorry, I'm the one responsible for those defaults: http://www.xyplorer.com/xyfc/viewtopic. ... 190#p92190

The thought was that case insensitivity and wildcards should be the default behavior.
Then it came down to having flags to disable them is more awkward (especially in wording), so it seemed logical to have it be that the default value was including both flags.
I think you understood that my problem is not what is default, but the way you speciy it.

Having thought about it I think I found my basic problem with it: the operand is for a list of flags, but there's not a default for every flag, but for a special combination of these flags.
The default is "iw". If you specify "i" you automatically reset "w".
For me "" requests defaults - here it resets the defaults.

So if every flag would have 2 values, for the opposite meanings, you could change each flag without affecting others. (Be it "i"=ignore case, "c"=differentiate case. Or "c+" and "c-", or whatever.)
If you are used to this kind of syntax, it's quite easy to misunderstand the way how it's defined here in XY. So I named it "a bit strange" :ninja:
(And I still think it is - though I don't expect it to be changed now :biggrin: )
(But maybe for the next new command :P )
Win11 Pro 223H2 Gerrman

bdeshi
Posts: 4249
Joined: 12 Mar 2014 17:27
Location: Asteroid B-612 / Dhaka
Contact:

Re: Website and Help Typos

Post by bdeshi »

v16.50.0200 > XYplorer.chm > Advanced Topics > IDH_IPTABVERSION shouldn't be there.
Icon Names | Onyx | Undocumented Commands | xypcre
[ this user is asleep ]

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

Re: Website and Help Typos

Post by admin »

SammaySarkar wrote:v16.50.0200 > XYplorer.chm > Advanced Topics > IDH_IPTABVERSION shouldn't be there.
Whoa, where did this come from? :o Not my bug... :biggrin: ...anyway, thanks!

bdeshi
Posts: 4249
Joined: 12 Mar 2014 17:27
Location: Asteroid B-612 / Dhaka
Contact:

Re: Website and Help Typos

Post by bdeshi »

Sc property() reference should note that the canonical property IDs are a post-XP feature only.
(Tried to use a prewritten script on an XP system and didn't work as expected, as expected in hindsight :whistle: )
Icon Names | Onyx | Undocumented Commands | xypcre
[ this user is asleep ]

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

Re: Website and Help Typos

Post by admin »

Ok. :tup:

bdeshi
Posts: 4249
Joined: 12 Mar 2014 17:27
Location: Asteroid B-612 / Dhaka
Contact:

Re: Website and Help Typos

Post by bdeshi »

Not exactly a typo.
The contacts section on the homepage - both the text and buttons - are aligned slightly to the left, rather than center proper.


And another thing, this is as good a place as any.
A user is explosively annoyed at the cactus banner background. I disapproved the post, but got to agree, that might be a... surprising intro. (I don't have a refined artistic eye tho :kidding: )
Icon Names | Onyx | Undocumented Commands | xypcre
[ this user is asleep ]

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

Re: Website and Help Typos

Post by admin »

1) OK, thanks. Fixed.

2) LOL.

bdeshi
Posts: 4249
Joined: 12 Mar 2014 17:27
Location: Asteroid B-612 / Dhaka
Contact:

Re: Website and Help Typos

Post by bdeshi »

changelog

Code: Select all

      - And <typo>it</typo> actually LNKs have always been passed unresolved to PFA 
Icon Names | Onyx | Undocumented Commands | xypcre
[ this user is asleep ]

Post Reply