[FIXED] patchimage not applied in some cases

Things you’d like to miss in the future...
SammaySarkar
Posts: 4205
Joined: 12 Mar 2014 17:27
Location: Asteroid B-612 / Dhaka
Contact:

[FIXED] patchimage not applied in some cases

Post by SammaySarkar » 23 Mar 2019 07:53

the PatchImagesPath tweak cannot patch the disabled state of icons, but the patchimage command can.

Code: Select all

patchimage 'undo', "<xydata>\Patch\undo.png";
patchimage 'undo-', "<xydata>\Patch\undo-.png";
patches both states of the redo button. But PatchImagesPath=Patch method only patches the enabled state.
This is happening because the - in undo-.png is taken as a separator.
admin wrote:
21 Mar 2019 19:25

Code: Select all

v19.80.0115 - 2019-03-21 19:24
      [...] Each image file must have the image key 
      in the beginning of the filename, optionally searated by "-" from any 
      other parts of the name.
Please change this. A space can be a good separator, since button keys do not contain spaces. For example:

Code: Select all

undo-.png // patches undo disabled state
undo- rest-of-filename.png // patches undo disabled state
undo-,1 rest-of-filename.png // patches undo disabled state, small size

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

Re: patchimage not applied in some cases

Post by SammaySarkar » 23 Mar 2019 07:59

At least these two buttons, back and fore, cannot be patched with either SC patchimage or the tweak.
But their disabled state can be patched with patchimage.

Code: Select all

patchimage "back-", "<xydata>\Patch\back-.png"; //works
patchimage "back", "<xydata>\Patch\back.png"; // no effect. the tweak also fails

admin
Site Admin
Posts: 47432
Joined: 22 May 2004 16:48
Location: Cologne, Win 8.1, Win 10
Contact:

Re: patchimage not applied in some cases

Post by admin » 23 Mar 2019 14:45

Oh yes, "-" was such a dumb choice. :roll: All will be good in the next beta...

PS: Actually I think I'll take the dot instead. (Space has its own disadvantages.)

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

Re: patchimage not applied in some cases

Post by SammaySarkar » 23 Mar 2019 15:14

sure, thanks!

admin
Site Admin
Posts: 47432
Joined: 22 May 2004 16:48
Location: Cologne, Win 8.1, Win 10
Contact:

Re: patchimage not applied in some cases

Post by admin » 23 Mar 2019 17:15

Conc. back and fore: if this is checked then the keys "backtab" and "foretab" are used.
Configuration | General | Refresh, Icons, History | History | History per tab

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

Re: patchimage not applied in some cases

Post by SammaySarkar » 23 Mar 2019 21:20

Ah, thanks. Both Customize Toolbar and toolbar() are totally silent about this. it's no big deal though . :tup:

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

Re: [FIXED] patchimage not applied in some cases

Post by SammaySarkar » 23 Mar 2019 21:36

Code: Select all

      The separator between key and the rest of the filename is now ".", not "-" 
      anymore. Examples:
        flatview.Cherries-24 x 24.png
Great! But the issue now is, how do people patch the darn 'cherries**' key? As you know, some people seem to absolutely hate this one. :lol:

Actually, seriously, since patchimage 'cherries**', 'not-cherries.png'; does work, would you consider swapping out the asterisks from button keys with something more filesystem friendly * ? Just for the sake of making the command and the patch files tweak completely equivalent.

* on linux, I'm able to create a <xydata>\Patch\cherries**.png file, but this doesn't work anyway.

admin
Site Admin
Posts: 47432
Joined: 22 May 2004 16:48
Location: Cologne, Win 8.1, Win 10
Contact:

Re: [FIXED] patchimage not applied in some cases

Post by admin » 23 Mar 2019 21:42

The **keys are for resource hackers only, so I don't f**king care. :mrgreen:

jupe
Posts: 1176
Joined: 20 Oct 2017 21:14
Location: 1903 x64

Re: [FIXED] patchimage not applied in some cases

Post by jupe » 23 Mar 2019 22:22

Slightly off topic, but can anyone else get the 24x24 image of "rfo" to be replaced by using the tweak folder implementation, not the SC ? I seem to only be getting the 16x16 version of it replaced.

edit: actually it seems to happen to only certain keys, some replace both some only replace the smaller image, but the file gets locked still. :veryconfused:

admin
Site Admin
Posts: 47432
Joined: 22 May 2004 16:48
Location: Cologne, Win 8.1, Win 10
Contact:

Re: [FIXED] patchimage not applied in some cases

Post by admin » 23 Mar 2019 22:30

No problem here:
Attachments
2019-03-23_222951.png
2019-03-23_222951.png (35.93 KiB) Viewed 309 times

jupe
Posts: 1176
Joined: 20 Oct 2017 21:14
Location: 1903 x64

Re: [FIXED] patchimage not applied in some cases

Post by jupe » 24 Mar 2019 06:06

Well I am having weird issues, I'll have to do further testing when I get time because it is only working intermittently for me, I can't quite work out the cause yet.
The main issue is the 16 size always gets replaced the larger size only sometimes, but both files get locked so I assume it is accepting it as valid, but strangely the same thing happens if only using 1 file anyway.

Anyway I have managed to get it working for now for the images I wanted to replace, so no worries, I'll report back if I can nail down the cause.

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

Re: [FIXED] patchimage not applied in some cases

Post by SammaySarkar » 27 Mar 2019 16:16

These keys don't get patched. Please add support for these to patchimage, if possible.

Code: Select all


flipall
flipdown
flipup

prog1
prog2
prog3

click1
click2
click3
scriptXX

C
C-
D
D-
M
M-
N
N-
R
R-

admin
Site Admin
Posts: 47432
Joined: 22 May 2004 16:48
Location: Cologne, Win 8.1, Win 10
Contact:

Re: [FIXED] patchimage not applied in some cases

Post by admin » 27 Mar 2019 16:44

Should work in next version...
Attachments
2019-03-27_164316.png
2019-03-27_164316.png (8 KiB) Viewed 247 times

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

Re: [FIXED] patchimage not applied in some cases

Post by SammaySarkar » 27 Mar 2019 16:51

too much rolling stones! :kidding:
(thanks)

admin
Site Admin
Posts: 47432
Joined: 22 May 2004 16:48
Location: Cologne, Win 8.1, Win 10
Contact:

Re: [FIXED] patchimage not applied in some cases

Post by admin » 27 Mar 2019 19:43

BTW, click3 and scriptXX are not used.

Post Reply