✨ Allow configuring a vertical gutter separator
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 3/5
- Thời gian dự kiến
- 1-2 ngày
- Mức phù hợp với người mới
- 68/100
- Loại issue
- Tính năng
- Độ rõ ràng
- Khá rõ ràng
- Mức độ hoạt động
- Sôi nổi
- Công nghệ
- macos, swift
- Lĩnh vực
- design, desktop-dev
Hướng nghiên cứu
Bắt đầu bằng cách đọc GutterView và bố cục gutter xung quanh cùng mã vẽ của SourceEditor. Theo dõi cách chiều rộng của gutter thay đổi theo số chữ số của số dòng, sau đó định nghĩa một dấu phân cách tùy chọn tương thích ngược với màu sắc và kiểu vẽ có thể cấu hình; được xem là hoàn tất khi nó vẫn bị vô hiệu hóa theo mặc định và bám theo ranh giới của gutter khi chiều rộng của nó thay đổi.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Description
Please allow API consumers to configure an optional vertical separator between the line-number gutter and the editor content.
Some editor designs use a thin solid or dashed line beside the line numbers. The separator needs to be drawn by the gutter itself because the gutter width changes as the document's line-number digit count grows. There is currently no public configuration for this, so matching such a design requires maintaining a fork of GutterView.
A backward-compatible configuration could keep the separator disabled by default and allow consumers to specify its color and drawing style. The exact API is open to the maintainers' preference.
Alternatives Considered
- Overlaying a line outside
SourceEditor. This cannot reliably follow the gutter because its width is managed internally and changes with the number of line-number digits. - Making internal gutter layout properties public. A configuration option would expose less implementation detail.
Additional Context
Our current use case is a 1 pt separator using NSColor.separatorColor with a [1, 1] dash pattern.
No matching open or closed issue was found before filing this request. Observed on current main at revision 1fa4d3c.
Screenshots
Not included.
- Ngôn ngữ chính
- Swift
- Star
- 720
- Fork
- 162
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
Hướng dẫn đóng góp
Chưa lập chỉ mục được hướng dẫn đóng góp cho kho mã nguồn này
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của CodeEditApp/CodeEditSourceEditor
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 84/100
CodeEditApp/CodeEditSourceEditor#377 · 1 bình luận ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
CodeEditApp/CodeEditSourceEditor#376 · 1 bình luận ·
-
Độ khó 1/5 1-3 giờ Mức phù hợp với người mới 68/100
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 32/100
-
bug
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 45/100
Tất cả issue của CodeEditApp/CodeEditSourceEditor
Issue tương tự
-
enhancement
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
-
type: docs
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 95/100
googleapis/google-cloud-swift#971 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
bitcoindevkit/bdk-ffi#1125 ·
-
Move wallpaper setting Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
mozilla-mobile/firefox-ios#35743 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 84/100
manaflow-ai/cmux#13417 ·