the title bar sometimes flows on to the second line #32
Labels
No Label
blocked
bug
build
documentation
duplicate
enhancement
finger
gemini
gopher
help wanted
http
in progress
invalid
local
needs-info
non-code
non-functional
non-urgent
question
release
rendering
suggestion
telnet
terminal
urgent
wontfix
No Milestone
No Assignees
2 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: sloum/bombadillo#32
Loading…
Reference in New Issue
No description provided.
Delete Branch "%!s(<nil>)"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
It seems that the title bar will flow on to the second line at times, possibly only when the URL is for a full text search page (because it has a tab in the title?).
When it flows over, it obscures the characters on the second line. This can just be the white background of the title bar, or the continued ellipsis of a shortened title.
Below is a veronica2 search for golang. The first line has the white background, and the first two characters of the second line have the white background and what should be (MAP) becomes AP):
This seems to be related to line wrapping of the title within a limited size console, but with a large title I've seen this at full screen. Other gopher links don't seem to have this issue though, and wrap correctly, making me think that the tab is the problem.
This occurs in the latest version of bombadillo as well as previous versions, and have checked a few different terminal emulators and have seen the same result.
The issue is 100% related to tabs. Since tab width is set in a way that I cannot seem to query (if you know a way, please let me know) I am not able to account for the tab and there is overflow when a tab is present. I could remove the tab and replace it with a set number of spaces... but then users would not be able to copy and paste the link, which I think is important.
The title/url bar is set up to add an ellipses when the text is too long, it just has now way to count a tab as anything other than a single character since the space taken by a tab a) does not always equate to a number of characters, b) it a part of how the individual terminal renders things and can vary from terminal to terminal.
I'll do some more research and see if there is any reliable way to get tab length pulled into the program. That would make a lot of things easier... I'm just not sure if it exists.
Some additional research has revealed that often the default tab behavior is provided by a list of values and when you tab it goes to the nearest value to the right (as such, it is not necessarily always a set value ahead). It may be possible for me to overcome that, but I'm not sure. I'll do more research.
I have worked out a fix to at least part of this: #33
That fixes the base case where the color overflows. On small screens the tab may still cause issues with the ellipses not fully showing. I'll work that in when I can. Still not sure the best way to handle it as I have not found any promising info on predicting tab behavior.