fifonik / FFMetrics

Visualizes Video Quality Metrics (PSNR, SSIM & VMAF) calculated by ffmpeg.exe
562 stars 22 forks source link

ffmetrics 1.5.0 beta 3 - filenames get cut after resizing the columns #143

Closed JamesPous closed 3 months ago

JamesPous commented 3 months ago

Bug-ffmetrics

I resized the columns to see the full filename. The list of the filenames does not automatically refresh long filenames and do not show them.

fifonik commented 3 months ago

This is not a new bug. Such implementation was from very beginning as it is very tricky to create a proper implementation that will calculate text's width (in characters) from available grid cell width in pixels to shorten the text (this should include all these DPI, scaling etc). To be honest I do not even know how to do this in reasonably optimal way. So it will not be fixed completely. However, I've slightly tweaked my hardcoded guessing logic, so it might be better (or worse, who knows). Will be available in the next beta version.

fifonik commented 3 months ago

Just uploaded beta 4 with some improvements in this area.

Hlsgs commented 3 months ago

The new beta is alot better regarding this! I had been meaning to make a bug report about this but didn't get to it, so thank you both for reporting and fixing, respectively. I will keep testing and report back here if I find any quirks.

Regarding the implementation, I would first truncate the parent path before starting to truncate the filename. Regardless, the main issue here seems to have been fixed. Which is: if you resize and provide enough real-estate for the whole thing, it should show the whole thing. Now, that seems to be the case.

JamesPous commented 3 months ago

Great solution! Thank you!

fifonik commented 3 months ago

I would first truncate the parent path before starting to truncate the filename

This is exactly how it was implemented from the beginning. The tricky bit is to find out the max string size that is needed to make the above logic to work.

fifonik commented 3 months ago

Assuming it is implemented :)