Opened 3 days ago
Last modified 3 days ago
#19334 new enhancement
provide an option to add custom attributes to index in FileTypes
Reported by: | grexe | Owned by: | axeld |
---|---|---|---|
Priority: | normal | Milestone: | Unscheduled |
Component: | Preferences/FileTypes | Version: | R1/Development |
Keywords: | Cc: | ||
Blocked By: | Blocking: | ||
Platform: | All |
Description (last modified by )
FileTypes currently does not provide the UI for adding an attribute to the filesystem index. This is really a great lack of functionality and deprives average users of a core feature unique to Haiku/BFS.
Similar to "Visible" and "Editable", this option could be added below the group as "Searchable" (easier to understand) or "Add to index" (too techy) that affects how Tracker displays it.
This feature would introduce a new property in the META:ATTR_INFO
message of a filetype definition, something like attr:searchable
.
If true, the attribute is added to the index; if false, we need to check if the attribute is used by another MIME type and if not (i.e. orphaned index), remove it.
cf:
- https://www.haiku-os.org/legacy-docs/bebook/IndexFunctions_Overview.html
- https://www.haiku-os.org/legacy-docs/bebook/TheStorageKit_Functions.html#fs_create_index
Eventually, a simple preferences application for maintaining indices would be good, but is not required for now.
However, the current situation having indices only available on the command line is very unfortunate, as this is a feature many users would really need and we want to empower users and not restrict them to the default configuration...
here is a trivial working sample code from my simple MIME tool: