Repository navigation
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info
📝 Walkthrough
Merge Risk: ⚪ Minimal · up to
|
|
@coderabbitai review |
✅ Action performedReview finished.
|
|
Great one, will add! |
|
@greptileai review |
[Medium impact] The change reaches Flea’s main file-browsing text and rename workflow. Fix the new grid fixture before merging; also align the Trash date measurement with its font.
|
| Flea.MatchText { id: match; width: 900; height: 32; text: root.sample.n } | ||
| Flea.Row { id: row; width: 900; row: Object.assign({}, root.sample, { n: "Reference/" + root.sample.n }); hiddenCols: [] } | ||
| Flea.ColumnRow { id: columnRow; width: 900; row: root.sample; showSize: true; pane: searchPane } | ||
| Flea.GridTile { id: tile; width: Flea.Theme.grid.cellWidth; height: Flea.Theme.grid.cellHeight; row: Object.assign({}, root.sample, { n: "a-very-long-synthetic-filename-that-needs-an-elided-grid-caption-and-a-hover-tip.txt" }); hovered: true } |
There was a problem hiding this comment.
Grid test uses missing sizes.
Theme.grid defines neither cellWidth nor cellHeight. These bindings therefore assign undefined to the tile's dimensions and produce Qt warnings. font-hinting.sh rejects warnings, so the newly registered suite makes run-all.sh fail. Use Theme.grid.minCellWidth and derive the height through GridGeometry.cellHeightFor, as the existing grid fixtures do.
Prompt To Fix With AI
This is a comment left during a code review.
Path: tests/font-hinting.qml
Line: 26
Comment:
**Grid test uses missing sizes.** `Theme.grid` defines neither `cellWidth` nor `cellHeight`. These bindings therefore assign `undefined` to the tile's dimensions and produce Qt warnings. `font-hinting.sh` rejects warnings, so the newly registered suite makes `run-all.sh` fail. Use `Theme.grid.minCellWidth` and derive the height through `GridGeometry.cellHeightFor`, as the existing grid fixtures do.
---
For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.|
|
||
| // Trash draws its Deleted cell at body, and body/bodySmall is not one ratio across the size stops. | ||
| TextMetrics { id: bodyGlyphMetrics; font.family: Style.font.family; font.pixelSize: root.font.body; text: "0" } | ||
| TextMetrics { id: bodyGlyphMetrics; renderType: Text.NativeRendering; font.family: Style.font.family; font.hintingPreference: Font.PreferFullHinting; font.pixelSize: root.font.body; text: "0" } |
There was a problem hiding this comment.
Trash date measurements no longer match.
bodyGlyphMetrics also sets Theme.column.trashDate, but the deleted text in TrashView.qml still uses default hinting. If full hinting rounds a font's character widths down, the date column now shrinks while its text does not, cutting off timestamps even when the pane has enough room. Give the Trash date the same hinting choice, or keep a separate measurement that matches its existing font.
Prompt To Fix With AI
This is a comment left during a code review.
Path: ui/Theme.qml
Line: 122
Comment:
**Trash date measurements no longer match.** `bodyGlyphMetrics` also sets `Theme.column.trashDate`, but the `deleted` text in `TrashView.qml` still uses default hinting. If full hinting rounds a font's character widths down, the date column now shrinks while its text does not, cutting off timestamps even when the pane has enough room. Give the Trash date the same hinting choice, or keep a separate measurement that matches its existing font.
---
For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.|
Flea's interface moved from QML to GPUI in v0.4.0 (https://github.com/thisisgm/flea/releases/tag/v0.4.0), so this QML change no longer applies. Thanks @OldJobobo! |
Summary
Request explicit
Font.PreferFullHintingfor listing names/metadata in list, columns and grid views, and their rename fields. On Maple Mono NF at scale 1 this makes the small listing text noticeably clearer.Flea already enables native text rendering. This patch does not change the renderer, force a font family, increase text sizes, add a setting, or introduce the diagnostic item-tree traversal/timer. It preserves the existing system-family and size bindings and leaves icon rendering alone.
Full hinting can change horizontal advances, so the matching filename-budget and column-autofit TextMetrics also use native rendering and full hinting. Existing caption containment checks now include rounded pixel extents; the Recent layout test compares against its actual dual-column floor instead of assuming it exceeds the single-pane floor. Source-line allowances and byte/line pins are re-derived, with no new allowances or production objects.
This is deliberately a draft: the visual preference is font/display dependent, especially at fractional scale, and needs maintainer review rather than a claim that full hinting universally looks better.
Privacy-safe visual evidence
Actual Flea: before and after
Same synthetic files, Maple Mono NF Regular, 14 px body size and scale 1; both sides use native rendering. Open the original PNG at 100%:
https://raw.githubusercontent.com/OldJobobo/flea/evidence/font-hinting/before-after.png
Current, vertical and full hinting
Current/default, vertical and full hinting at 10, 12, 14, 16 and 20 px, with native rendering in every column:
https://raw.githubusercontent.com/OldJobobo/flea/evidence/font-hinting/hinting-comparison.png
The assets and standalone comparison QML are on a separate fork-only evidence branch, not in this code diff. Captures show only generated samples and an isolated home, omit the filesystem status strip, and have stripped PNG metadata. Capture details and individual before/after images:
https://github.com/OldJobobo/flea/blob/evidence/font-hinting/README.md
Validation
tests/font-hinting.sh: 444 checks across all seven supported size stops, including lazy match/location/drop/tooltip text and matching measurements. Against unchanged upstream, it reports 144 failures.columnrow-geom,gridcaption,gridmark,listnamebudget,rowcost,budget, all 14 static gates, file budgets, shell syntax and code diff whitespace checks.rename-grid-bottomfixture's missingdropsLocalproperty fail on the unchanged baseline too. The functional header/startup probes pass; startup remains at 628 objects. The full matrix was not run.Detailed results, including the interrupted
rename-list-bottomattempt:https://github.com/OldJobobo/flea/blob/evidence/font-hinting/VALIDATION.md
--[ Pi :: gpt-6.1-sol ]----- on behalf of:@OldJoboboSummary by CodeRabbit
Bug Fixes
Tests