Summary
With #56, STRING columns now default to natural sort (e.g. file2 before file10). This is the right default, but users should have an escape hatch to force lexicographic sort when needed.
Problem
There may be edge cases where a user wants strict lexicographic ordering on a STRING column — for example, base64-encoded identifiers or hash prefixes where digit groups don't represent meaningful numbers.
Proposed Solution
Add a LEX_STRING column type that can be set via :set type <col> lex (or similar). This would bypass natural_sort_key() and return the raw string value from coerce_sort_key(), restoring the pre-#56 behavior for that column.
Technical Considerations
- New
ColumnType.LEX_STRING variant
coerce_sort_key() STRING branch stays as natural sort; LEX_STRING returns raw value
- Column type label could use
"A" (alpha) to distinguish from default STRING (no label)
- Low priority — no known user request for this yet; filed as a safety valve
Summary
With #56, STRING columns now default to natural sort (e.g.
file2beforefile10). This is the right default, but users should have an escape hatch to force lexicographic sort when needed.Problem
There may be edge cases where a user wants strict lexicographic ordering on a STRING column — for example, base64-encoded identifiers or hash prefixes where digit groups don't represent meaningful numbers.
Proposed Solution
Add a
LEX_STRINGcolumn type that can be set via:set type <col> lex(or similar). This would bypassnatural_sort_key()and return the raw string value fromcoerce_sort_key(), restoring the pre-#56 behavior for that column.Technical Considerations
ColumnType.LEX_STRINGvariantcoerce_sort_key()STRING branch stays as natural sort; LEX_STRING returns raw value"A"(alpha) to distinguish from default STRING (no label)