Conversation
HighlightEntry.IsHideLine (default false, cloned, serialized), HighlightEvaluator.IsHidden, an immutable row<->original-line map with append-only shared storage, and a tracker that rebuilds the map on a cancellable background scan with generation-tagged results.
The main grid now displays the rows of a LineVisibilityMap; reader, bookmark, timestamp, search, session and row-height code keeps using original logical lines. Explicit navigation to a hidden line turns on the per-window 'Show hidden lines' override; tail follow tracks the last visible row. A notice bar shows the hidden-line count and the override, and the Highlight Entry dialog gets a 'Hide line' checkbox.
The UI thread takes the tracker lock (Load/Rebuild/IsScanning) while a reader call made under it could wait for the UI thread, which could hang the window. Tail/scan evaluation now reads outside the lock and commits only if the state is unchanged. Also cancels the scan when the window closes, fixes marker navigation to lines beyond the visible row count, adds lifecycle/trigger/marker/perf tests and the CONTEXT.md glossary.
…en (#338) - While a load's first visibility scan runs the grid shows no rows, and saved/reload positions are applied once it has published. - Windows following a time sync select the nearest visible line; only the window the user navigates in reveals a hidden line. - Review fixes: shared evaluate-and-commit loop in the tracker, one publish path for the grid, CurrentLineNum instead of a duplicate property, line/row naming, unsubscribe on close, drop unused Truncate.
Collaborator
Author
- Remove stray Temp/Statusbar.png and unrelated Resources.Designer.cs whitespace - Queue explicit navigation (Go to Line, bookmark window, marker clicks) until the first visibility scan finishes - Pin line buffers in batches while the tracker reads, like the marker scan - One reveal-or-nearest decision (NavigationRow); rename SelectLine to RevealAndSelectLine - GridPosition replaces the loose current/first line pair; one ApplyPosition for restore and map changes - Share the hide-rule predicate; tracker tail methods return nothing; trim comments - Record reveal and matching policy in CONTEXT.md - Tests: truncation and rollover in a Log Window, Filter Pipe hiding and locate, highlight export/import, hide-rule markers, pinned reads, navigation during the first scan
- HiddenLinesBar: the notice bar control (count and Show hidden lines check box) - VisibleRows: the displayed Line Visibility Map, publishing it to the grid and keeping the position by original line - The remaining wiring moves into LogWindow.cs; LogWindow.LineVisibility.cs is removed
- Queue explicit navigation made before the first scan as the call itself, keeping its time-sync flag and follow-tail state; timestamp navigation from the sync origin is queued too and reports it did not scroll - Drop queued navigation when a reload replaces loaded content - Restoring a saved or reload position selects through SelectRow again (clears a pending time sync, focuses the grid) - VisibleRows takes an IVisibleRowsHost instead of three callbacks and owns the current-line lookup - Rename NavigationRow to RevealOrNearestRow; the pin delegate is required; comment fixes - Tests: bookmark window and timestamp navigation during the first scan
- One pending navigation (an Action) replaces the target line and the queued call; RunWhenNavigable runs it now or once navigable - Windows following a time sync queue during their first scan too, and move to the nearest visible line - Every reload after the first load drops queued navigation, the -line target included - A reload restores its position without taking focus; session restore still focuses; both clear a pending time sync - VisibleRows splits select-and-scroll from scroll-only; SameRules says why three fields suffice - Tests: time-sync follower during the first scan; timestamp tests skip instead of racing the scan
- Automatic reloads (ReloadNewFile) drop queued navigation where they start, like Reload(); entering the load status no longer does, so a multi-file session keeps its -line target - Queued time-sync following never replaces the user's own queued navigation (PendingNavigation) - Rename GoToTargetLine to GotoRequestedLine; inline the time-sync reset at the two restores; document ScrollToTimestampWorker's result - Test: a time sync during the first scan doesn't replace a queued Go to Line
- RestorePositionWithoutTimeSync replaces the two inlined copies - Queue -> SetPendingNavigation, PendingNavigation.Run -> Navigate, record moved out of the methods - Name the time-sync-follow condition in ScrollToTimestampWorker - ReloadNewFile drops queued navigation only for the reload it actually starts
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.


What
Highlight Entries get a Hide line checkbox. Lines matching any hide rule in the active Highlight Group are removed from the Log Window's main grid.
Behaviour
-linecommand-line target (Cmdline option to open file at specific line #58)-linetarget included, as Reload() already did before this PR.How
HighlightEntry.IsHideLinedefaults tofalse, so existing settings load unchanged. It is cloned, serialized and survives highlight export/import.HighlightEvaluator.IsHiddenmakes the hide decision. It never fires triggers.LineVisibilityMapis an immutable mapping between visible rows and original lines. Its memory is proportional to the number of hidden lines, and tail appends share storage.LineVisibilityTrackerkeeps the map up to date:VisibleRowsholds the displayed map, publishes it to the grid and keeps the selection and scroll position by original line.HiddenLinesBaris the notice bar control.LogWindowkeeps the wiring: the row↔line conversion, the reveal policy (NavigationRow) and the load and tail hooks.LogWindow.cs— every place that used a grid row index as a reader line now converts between the two. That covers selection, clipboard, bookmarks, row heights, timestamps, source-file lookup, the columnizer callback, sessions and follow tail.ColumnCache.PrefetchLinespins only the lines that visible rows display, even when they are far apart in the file.CONTEXT.mddocuments the new terms and the reveal policy: Hide-line rule, Original logical line, Visible row, Line Visibility Map, Show hidden lines.Tests
IsHideLine, and older files without it load asfalse. Marker criteria tests pin the colour policy for hide rules.[Explicit]. On 1M lines (62 MB) with 500k hidden: