-
-
Notifications
You must be signed in to change notification settings - Fork 1.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Auto-render hyperlinks #3914
Auto-render hyperlinks #3914
Conversation
Coverage summary from CodacySee diff coverage on Codacy
Coverage variation details
Coverage variation is the difference between the coverage for the head and common ancestor commits of the pull request branch: Diff coverage details
Diff coverage is the percentage of lines that are covered by tests out of the coverable lines that the pull request added or modified: See your quality gate settings Change summary preferencesCodacy stopped sending the deprecated coverage status on June 5th, 2024. Learn more Footnotes
|
@@ -171,6 +171,7 @@ func (gui *Gui) createAllViews() error { | |||
gui.Views.Extras.Title = gui.c.Tr.CommandLog | |||
gui.Views.Extras.Autoscroll = true | |||
gui.Views.Extras.Wrap = true | |||
gui.Views.Extras.AutoRenderHyperLinks = true |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Unlike in Aleksei's earlier PR, I decided to not set the UnderlineHyperLinksOnlyOnHover in this view, following the earlier decision to turn this on only in the main view, but underline links directly everywhere else. Let me know if you dislike this @jesseduffield.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's fine.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Some commands output hyperlinks, and it's useful to be able to click them.
This allows clicking on links in commit messages, for examples. It also affects the status view, so we can get rid of the manual hyperlinking there.
This allows us to get rid of the underlineLinks function.
041daf9
to
825f5c0
Compare
Add a facility to gocui.View to enable auto-rendering of https hyperlinks. Then, use it for the Command Log panel (as an alternative approach to #3911), and also in the status view and in confirmation popups to get rid of some code that used to do this manually.
go generate ./...
)