Opened 9 years ago
Closed 8 years ago
#12539 closed enhancement (fixed)
TextSearch won't grep XHTML files
Reported by: | humdinger | Owned by: | nobody |
---|---|---|---|
Priority: | normal | Milestone: | Unscheduled |
Component: | Applications/TextSearch | Version: | R1/Development |
Keywords: | Cc: | ||
Blocked By: | Blocking: | ||
Platform: | All |
Description
This is hrev49934.
XHTML has unfortunately a MIME type of application/xhtml+xml. You'd have to uncheck TextSearch's setting "Text files only" (which is what you usually want) to make it work.
TextSearch examines files, if they have a "text" supertype for this.
Would introducing this exception in code be acceptable:
// Make an exception for XHTML files if (strcmp("application/xhtml+xml", mimeTypeString) == 0) return true;
(inserted here: http://xref.plausible.coop/source/xref/haiku/src/apps/text_search/FileIterator.cpp#61)
Change History (4)
comment:1 by , 9 years ago
Owner: | changed from | to
---|---|
Status: | new → assigned |
comment:2 by , 8 years ago
So... is the above solution OK for now?
I know an even better idea would be to check the "supported types" of TextSearch. OTOH, there probably aren't that many more text files that aren't of the MIME text/* in the future. Plus, as TextSearch comes from a package and is therefore read-only, the user can't add more supported types (which is something that might be addressed after R1, I guess).
deassigning various things from me