Bug 486226

Summary: Custom Columns as plugin or script in details view
Product: [Applications] dolphin Reporter: myusualnickname <myusualnickname>
Component: view-engine: details modeAssignee: Dolphin Bug Assignee <dolphin-bugs-null>
Status: CONFIRMED ---    
Severity: wishlist CC: felixernst, kfm-devel
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description myusualnickname@gmail.com 2024-04-28 01:24:58 UTC
I worked as a document scanner, and we had to have our files match some really stupid formats.

With microsoft explorer, I was able get the dev environment up, find examples, and create a column that I could sort by that was a regular expression search on the name.  I could create a column from the filename where I reordered the date format to YYYYMMDD and then was able to sort nicely, and it happened within an evening.

 It would also be nice to be able to refer to a search index, or actually read the file and grep each file searching the contents and counting the occurrences of words. Basically, there could be a plugin system, or this feature could be a custom column with meta data taken from a meta data library (to read resolution of the image, compression type, number of pages in a pdf or tiff image) and using a regex on the filename or filename contents.


This would appear as add custom tab, and there should be no limit to the number of them.  When a custom tab is added to the list of tabs, it can be edited, a selection of metadata library, regex, or  file search, or shell command.  the metadata library could populate a submenu with all the types of data.   bitrate,x pixels, y pixels ,inches,word count, signed date,  there are so many things this could be.  there may be more than one metadata scraper.

We wouldn't even need to compile anything.
KDE has had cool regex searches in a few applications before, so that may already have components ready.



Basically, this is an advanced col


***
If you're not sure this is actually a bug, instead post about it at https://discuss.kde.org

If you're reporting a crash, attach a backtrace with debug symbols; see https://community.kde.org/Guidelines_and_HOWTOs/Debugging/How_to_create_useful_crash_reports
***

SUMMARY


STEPS TO REPRODUCE
1. 
2. 
3. 

OBSERVED RESULT


EXPECTED RESULT


SOFTWARE/OS VERSIONS
Windows: 
macOS: 
Linux/KDE Plasma: 
(available in About System)
KDE Plasma Version: 
KDE Frameworks Version: 
Qt Version: 

ADDITIONAL INFORMATION
Comment 1 Felix Ernst 2024-04-29 16:50:01 UTC
>Basically, this is an advanced col

Your comment is cut off there. Maybe you would have put a nice summary there. As it stands it is really difficult to follow what exactly you want to see changed. It reads more like a huge list of features and behaviour changes that would be necessary to fulfill a very specific workflow.

Please also be aware that Dolphin does explicitly not have the design goal to have features for niche and advanced use cases.

One thing you mention is regex filtering. That is indeed a feature that has been requested in the past and is supposed to be added to Dolphin's "Filter" feature as soon as any contributor shows up to implement it.

There is also some work underway that would allow end users to use command line tools for the search. I am not sure how exactly that feature will materialise (it is quite complicated and currently in review) but there is a chance that it might allow you to create a command that serves your use case.
Comment 2 myusualnickname@gmail.com 2024-12-20 06:17:16 UTC
I'm looking to add custom columns to dolphin.

Like metadata from mp3 files or playlists...
It would be nice to have a way to make a little script so I can check each file and fill out an entry for each file in the folder.

With windows scripting it was superduuper easy, I had a xolumn that was filled by a properly ordered date rather than the date that was in the filename.  our filenames were like DDDYYYY  and I needed it to be in correct order without changing the filenames, so I did a regex and made it find strings of numbers and then rearrange them so it was year then day of the year.
I'm just saying it would be nice to have a custom column option and the ability to input a script that could grab the head or tail of a file or filename or whatever, and run on each file in the folder and then have the output be a string.

Custom columns I would write include:
Is filename valid for 8.3 dos? and 8.3 dosname
and valid for windows, and valid for mac, and a flag if the filename is ascii, and a flag if it uses unicode encoding for the filename.

There are so many pieces of data that I want and need to to see.

I want to know if I can copy the file to NTFS, or if it has an O that is really another character that has noting to do with O.
I want to be able to see if people are putting files on USB drives that have filenames that will hurt the computer.
Comment 3 Felix Ernst 2024-12-20 09:58:36 UTC
Yes, this is not possible currently. One can only add data to already available columns like the "comment" role and then sorting only works alphabetically.

Your wish seems a bit too advanced for a typical file manager to me, but as long as someone finds a way to implement this cleanly and in an a way that is easy to maintain and does not confuse novice users, I won't stand in the way of it.