List rendering issue with "List" triggered Scripted Column

Things you’d like to miss in the future...
Forum rules
You might want to read this if you're looking for priority service

:info: Please Include The Following Information
1) Your XYplorer Version (e.g., v28.00.0801)
2) Your Windows Version (e.g., Win 11)
3) Your Screen Scaling Percentage (e.g., 125%).

:info: Use Your Profile Or Signature
We strongly recommend adding your Windows Version and Screen Scaling Percentage to the Location field in your Profile or to your Signature. That way, you only have to type them once, and we won't have to search for that vital information.

:info: How To Attach Images
When attaching an Image, please use the Attachment tab at the bottom of your post and click "Add files".
Huidong
Posts: 213
Joined: 18 May 2011 21:55

List rendering issue with "List" triggered Scripted Column

Post by Huidong »

Hi, Don, just wanted to bring to attention the previous issue I reported here:
http://www.xyplorer.com/xyfc/viewtopic. ... 14#p106014

Image

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

Re: List rendering issue with "List" triggered Scripted Colu

Post by admin »

Looks like there are some formatting characters in your data. Can you hexdump the data to check? See SC hexdump()...

Huidong
Posts: 213
Joined: 18 May 2011 21:55

Re: List rendering issue with "List" triggered Scripted Colu

Post by Huidong »

Here's one result using default hexdump()

Code: Select all

00000000: 54 69 74 6C 65 3A 20 20 20 20 20 20 20 20 20 20   Title:          
00000010: 52 65 76 69 65 77 4F 66 4D 61 70 6C 65 31 38 2E   ReviewOfMaple18.
00000020: 6E 62 0D 0A 43 72 65 61 74 6F 72 3A 20 20 20 20   nb..Creator:    
00000030: 20 20 20 20 4D 61 74 68 65 6D 61 74 69 63 61 0D       Mathematica.
00000040: 0A 50 72 6F 64 75 63 65 72 3A 20 20 20 20 20 20   .Producer:      
00000050: 20 4D 61 74 68 65 6D 61 74 69 63 61 20 50 44 46    Mathematica PDF
00000060: 20 45 78 70 6F 72 74 0D 0A 43 72 65 61 74 69 6F    Export..Creatio
00000070: 6E 44 61 74 65 3A 20 20 20 30 33 2F 32 36 2F 31   nDate:   03/26/1
00000080: 34 20 31 32 3A 31 30 3A 31 37 0D 0A 4D 6F 64 44   4 12:10:17..ModD
00000090: 61 74 65 3A 20 20 20 20 20 20 20 20 30 33 2F 32   ate:        03/2
000000a0: 36 2F 31 34 20 31 32 3A 31 30 3A 31 37 0D 0A 54   6/14 12:10:17..T
000000b0: 61 67 67 65 64 3A 20 20 20 20 20 20 20 20 20 6E   agged:         n
000000c0: 6F 0D 0A 46 6F 72 6D 3A 20 20 20 20 20 20 20 20   o..Form:        
000000d0: 20 20 20 6E 6F 6E 65 0D 0A 50 61 67 65 73 3A 20      none..Pages: 
000000e0: 20 20 20 20 20 20 20 20 20 34 0D 0A 45 6E 63 72            4..Encr
000000f0: 79 70 74 65 64 3A 20 20 20 20 20 20 6E 6F 0D 0A   ypted:      no..
00000100: 50 61 67 65 20 73 69 7A 65 3A 20 20 20 20 20 20   Page size:      
00000110: 36 31 32 20 78 20 37 39 32 20 70 74 73 20 28 6C   612 x 792 pts (l
00000120: 65 74 74 65 72 29 20 28 72 6F 74 61 74 65 64 20   etter) (rotated 
00000130: 30 20 64 65 67 72 65 65 73 29 0D 0A 46 69 6C 65   0 degrees)..File
00000140: 20 73 69 7A 65 3A 20 20 20 20 20 20 31 35 37 31    size:      1571
00000150: 38 31 36 20 62 79 74 65 73 0D 0A 4F 70 74 69 6D   816 bytes..Optim
00000160: 69 7A 65 64 3A 20 20 20 20 20 20 6E 6F 0D 0A 50   ized:      no..P
00000170: 44 46 20 76 65 72 73 69 6F 6E 3A 20 20 20 20 31   DF version:    1
00000180: 2E 34 0D 0A                                       .4..            

It doesn't seem to have any formatting chars to me?

BTW the Scripted Column that produces this rendering issue is as follows:

Code: Select all

$output = runret("cmd /c D:\Xpdf\pdfinfo.exe ""<cc_item>""");
$a = strpos($output, "Pages:");
$b = strpos($output, "Encrypted:");
$len = $b - $a - 2;  // get rid of trailing crlf
$pages = substr($output, $a, $len);  
$count = gettoken($pages, 2, ":", t);
return $count;
Trigger is chosen to be "List".

Note that this issue occurs only after scrolling, and not every row is messed up, there's some apparent randomness to it.

Also, when the trigger is set to "Browse", there's no such rendering issue. (Of course no issue with trigger by "Click" either).

==============
EDIT
The hexdump shown above is the entire output of pdfinfo.exe. But the return value of my CC script is just a single number. No formatting chars I believe.
Last edited by Huidong on 07 Jun 2014 10:18, edited 1 time in total.

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

Re: List rendering issue with "List" triggered Scripted Colu

Post by admin »

OK, then it's indeed a bug. I will later check that...

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

Re: List rendering issue with "List" triggered Scripted Colu

Post by admin »

Huidong wrote:EDIT
The hexdump shown above is the entire output of pdfinfo.exe. But the return value of my CC script is just a single number. No formatting chars I believe.
You should hexdump the contents of that $count variable then.

Huidong
Posts: 213
Joined: 18 May 2011 21:55

Re: List rendering issue with "List" triggered Scripted Colu

Post by Huidong »

Sure, here it is:

Code: Select all

00000000: 34                                                4               
There is a CR+LF at the end, but I guess that shouldn't be the cause?

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

Re: List rendering issue with "List" triggered Scripted Colu

Post by admin »

:? I see no CRLF in the hexdump. Where does it come from? It should not be there.

Huidong
Posts: 213
Joined: 18 May 2011 21:55

Re: List rendering issue with "List" triggered Scripted Colu

Post by Huidong »

Sorry my bad, there is NO CRLF within the hexdump, it's the CRLF of the text command. How silly.

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

Re: List rendering issue with "List" triggered Scripted Colu

Post by admin »

I will later try to install pdfinfo...


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

Re: List rendering issue with "List" triggered Scripted Colu

Post by admin »

OK, done. Tried your scripted column. It works fine! No rendering issue!

Are you sure it's not maybe one of the other items in that column, e.g. the image dimensions I see in your screenshot?

Huidong
Posts: 213
Joined: 18 May 2011 21:55

Re: List rendering issue with "List" triggered Scripted Colu

Post by Huidong »

I'm pretty sure it cannot be the image dimensions (I've been using it for quite some time, way before I started trying Scripted Columns).

Just making sure, did you select "List" as the trigger?

Also I'm suspecting perhaps it affects long list? For example, the folder I was testing on contains 1812 items.

Does it occur after quickly scrolling down?

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

Re: List rendering issue with "List" triggered Scripted Colu

Post by admin »

OK, I had "Click". Now I checked List as trigger, but still no problems.

Can you find out what characters/words are misprinted? Maybe that is a trace...

Huidong
Posts: 213
Joined: 18 May 2011 21:55

Re: List rendering issue with "List" triggered Scripted Colu

Post by Huidong »

Now noticed some randomness to this issue. Sometimes it's better. No messing up of the text (it seems to be due to sluggish refreshing while pdfinfo is doing the computation)

But even in those good days when no "mashed" text occurs, the Scripted Columns still has issues:

Image

Note that some cells failed to display the return value?

I'm guessing it has to do with pdfinfo simultaneously running, i.e. some blocking effect?

Huidong
Posts: 213
Joined: 18 May 2011 21:55

Re: List rendering issue with "List" triggered Scripted Colu

Post by Huidong »

Hmm, the screenshot is not shown for some reason, here's the dropbox link

https://www.dropbox.com/s/qgrz7x4cd2a7y ... _bug_2.png

Post Reply