Skip to content

feat(linux-grid): mark zero-width, control and special space characters - #4141

Closed
sedax90 wants to merge 73 commits into
TableProApp:mainfrom
sedax90:feat/linux-invisible-chars
Closed

sedax90 wants to merge 73 commits into
TableProApp:mainfrom
sedax90:feat/linux-invisible-chars

Conversation

@sedax90

@sedax90 sedax90 commented Nov 8, 2026 •

Copy link
Copy Markdown
Contributor

Summary

  • Add Show Invisible Characters to the Data Browser preferences, on by default, worded as in the macOS app.
  • Mark zero-width, control and special space characters with the macOS app's character set and labels (ZWSP, SOH, LF, RLO, ...).
  • Cells and the row details' field list write each one as its short name over an orange tint. A special space keeps its width under the tint, and a cell marks LF and CR since it shows one line.
  • The inline cell editor and the row details value editor mark them with Pango's show flags under a text attribute or tag. Their text, selection and undo history stay as typed.
  • Spaces, tabs and ordinary line breaks are not marked, as in the macOS app. Joiners inside emoji or scripts, variation selectors and emoji tag sequences are left alone.
  • Automatic column widths measure a value as its cell draws it, marks included, so a marked value is not cut. A width set by hand stays.
  • A preference change redraws open grids and editors. Builds on feat(linux-grid): sort a table by a default column when it opens #4140.

Test plan

  • Unit tests pin the character set, the labels, the exemptions and the cap of 4,096 marks.
  • Widget tests cover cells, the inline editor, the field list and the value editor with the preference on and off, a pane that opens after the change, a draft and its selection kept across changes, and automatic and manual column widths.
  • The marking code was type-checked and rendered against GTK 4.24 locally; the app's build and tests run in CI.

Screenshots

Before: the contributor's original row details editor. After shots of the rewrite are pending until local builds resume.

Light Dark
Before

# Conflicts:
#	linux/crates/app/src/ui/browse_tab/tests/mod.rs
#	linux/crates/app/src/ui/data_grid/edit/tests/rows.rs
#	linux/crates/app/src/ui/data_grid/row_detail/tests.rs
# Conflicts:
#	linux/crates/app/src/ui/data_grid/row_detail/tests.rs
# Conflicts:
#	linux/crates/app/src/ui/data_grid/edit/tests/rows.rs
#	linux/crates/app/src/ui/data_grid/row_detail/tests.rs
# Conflicts:
#	linux/crates/app/src/ui/data_grid/edit/tests/rows.rs
#	linux/crates/app/src/ui/data_grid/row_detail/tests.rs
#	linux/crates/app/src/ui/preferences_dialog/data_browser_group.rs
#	linux/crates/platform/src/settings/grid_preferences.rs
#	linux/crates/platform/src/settings/mod.rs
#	linux/crates/platform/tests/settings.rs
#	linux/data/app.tablepro.TablePro.gschema.xml.in
#	linux/docs/storage.md
# Conflicts:
#	linux/crates/app/src/ui/data_grid/row_detail/tests.rs
# Conflicts:
#	linux/crates/app/src/ui/browse_tab/tests/mod.rs
@datlechin datlechin changed the title feat(linux-grid): mark spaces, tabs and line breaks in the value editor feat(linux-grid): mark zero-width, control and special space characters Nov 9, 2026
@datlechin

Copy link
Copy Markdown
Member

Landed on main in #4142 (1071560), which was stacked on this branch and carried its commits. Closing as done. Thanks!

@datlechin datlechin closed this Nov 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants