diff options
| author | Christian Cleberg <[email protected]> | 2026-04-01 13:50:09 -0500 |
|---|---|---|
| committer | Christian Cleberg <[email protected]> | 2026-04-01 13:50:09 -0500 |
| commit | e84e5543be9be548784859f4b082b9d7a3122f15 (patch) | |
| tree | 0aa941558514adc1be7cdf5140c57bb3781ee1ad /Hutch.xcodeproj/project.xcworkspace | |
| parent | 109b0ea7e859de2d8b5a4dc22bf0472fd3b08eaa (diff) | |
| download | hutch-e84e5543be9be548784859f4b082b9d7a3122f15.tar.gz hutch-e84e5543be9be548784859f4b082b9d7a3122f15.tar.bz2 hutch-e84e5543be9be548784859f4b082b9d7a3122f15.zip | |
Rewrite file viewer with pinned gutter, syntax highlighting, and toolbar
Replace the SwiftUI-only CodeFileTextView with a UIViewRepresentable backed
by CodeFileUIView. The previous approach could not support a fixed line number
gutter while independently scrolling code content horizontally.
Changes:
- Gutter is pinned outside the horizontal scroll view and never scrolls left
- Vertical scroll is handled by a single outer UIScrollView shared by both
the gutter and code content, keeping them in sync
- Line numbers are right-aligned in a fixed-width gutter calculated from
the total line count
- Syntax highlighting via Splash for .swift files, with plain monospaced
rendering as fallback for unsupported file types
- Wrap toggle persisted via AppStorage (wrapRepositoryFileLines)
- Bottom toolbar replaces the floating Share button, adding Copy All and
Wrap toggle actions
- Copy All shows a brief checkmark confirmation that resets after 2 seconds
- Font fixed at SFMono-Regular 12pt, not scaled with Dynamic Type
Implements: https://todo.sr.ht/~ccleberg/Hutch/7
Diffstat (limited to 'Hutch.xcodeproj/project.xcworkspace')
| -rw-r--r-- | Hutch.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/Hutch.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved b/Hutch.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved index a2a45a3..ae6b756 100644 --- a/Hutch.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved +++ b/Hutch.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved @@ -1,7 +1,16 @@ { - "originHash" : "b809819531d430dc5b7a0fb1fb5538d0321c5d541eed52a9990f37c38dd0f98a", + "originHash" : "65542d8a5fbbad8dd7d07c8901c1cc48b3aba12cef8da1f062bd28d9b3a6ba50", "pins" : [ { + "identity" : "splash", + "kind" : "remoteSourceControl", + "location" : "https://github.com/JohnSundell/Splash", + "state" : { + "revision" : "7f4df436eb78fe64fe2c32c58006e9949fa28ad8", + "version" : "0.16.0" + } + }, + { "identity" : "swift-cmark", "kind" : "remoteSourceControl", "location" : "https://github.com/swiftlang/swift-cmark.git", |
