Skip to content
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

markjump for tabs rather than URLs #4946

Open
Zerogaku opened this issue Mar 11, 2024 · 9 comments
Open

markjump for tabs rather than URLs #4946

Zerogaku opened this issue Mar 11, 2024 · 9 comments

Comments

@Zerogaku
Copy link

Hi! This issue is mostly intrusive on the midnight theme or similar themes that have the prompt centered but when jumping to marks the command prompt a message will popup confirming the jump, is there a way to suppress this message or target the html to style it?

markjump.mp4

Also is there a way mark just the tab, and not the specific url? I often find myself browsing documentation and switching back and forth between a select few tabs, but often times when the url of the tab changes, I can no longer jump to said tab.

@Zerogaku Zerogaku changed the title Can jumped to markjump notification be supressed? And other markjump related feature. Can the markjump notification be supressed? And other markjump related feature. Mar 11, 2024
@Zerogaku Zerogaku changed the title Can the markjump notification be supressed? And other markjump related feature. Can the markjump notification be supressed? And other markjump related question. Mar 11, 2024
@bovine3dom
Copy link
Member

Thanks for reporting, :set markjumpnoisy false should appear whenever I next release a beta :)

I often find myself browsing documentation and switching back and forth between a select few tabs, but often times when the url of the tab changes, I can no longer jump to said tab.

Have you tried using [n]gt to jump to specific tabs? e.g. 3gt to jump to tab 3.

I'm not sure how marking tabs with the current mark function could work ergonomically.

@Zerogaku
Copy link
Author

@bovine3dom currently I use:

bind <A-\> gobble 1 markaddglobal
bind \ gobble 1 markjumpglobal

for global tab jumping or marking the tab instead of the url, in terms of ergonomics, it's pretty efficient, since after marking i just need to press 2 characters \ + [chosen letter] this is particularly useful if i don't remember the tab number that I wish to jump to and/or it isn't currently visible on the navbar, it can also be assigned to a mnemonic instead, like \+d to jump to a dictionary tab, or \+m for a music tab if it was paused.

Also since tab numbers might change depending on where you're opening a new tab from, like if you open a new link from within tab 50, the new tab takes the place of the previous tab 51, and the previous tab 51 becomes tab 52, making it less consistent to try to remember the numbers instead of say just the mnemonic, and since I'm using sidebery I haven't found a way to get tab numbers to show without collapsed tab branches being treated as individual tabs, like for example after collapsing 5 tabs (numbers 10-15) the visible tabs after the collapsed start at 11 instead of 16.

I know you can pin a tab and it will always be sorted at the top of the tab search if you type a character the tab includes, but pinning tabs require displacing them from the current tab group/branch if using a tree style tab extension.

Also convenient for situations where the title of the tabs can't be discerned even with the tridactyl's tab find:
image
image
image

@bovine3dom
Copy link
Member

for global tab jumping or marking the tab instead of the url

I think I don't quite understand you, that marks a URL rather than a tab, right?

Are you saying that you would be happy with e.g. a separate :markaddtab command? My reticence at the moment is that :markadd determines between global/local marks by using lowercase/capital letters.

Maybe it could work with numbers for tabs?

@bovine3dom bovine3dom changed the title Can the markjump notification be supressed? And other markjump related question. markjump for tabs rather than URLs Mar 15, 2024
@bovine3dom bovine3dom reopened this Mar 15, 2024
@Zerogaku
Copy link
Author

Zerogaku commented Mar 15, 2024

I think I don't quite understand you, that marks a URL rather than a tab, right?

Yes currently right now, if the tab changes it's url even a little bit tridactyl won't jump to it and instead opens a new tab with that specific url, I also have been using markaddglobal and markjumpglobal instead of markadd and markjump
since I didn't know that it worked by distinguishing uppercase and lowercase

Are you saying that you would be happy with e.g. a separate :markaddtab command? My reticence at the moment is that :markadd determines between global/local marks by using lowercase/capital letters.

Maybe it could work with numbers for tabs?

marking the tab number would be interesting but would suffer from the problem of tab numbers constantly changing, a new logic might have to be written, but yes I think the separate markaddtab command would be best.

@bovine3dom
Copy link
Member

Sorry, by number I am suggesting:

  • lowercase makes a local mark
  • uppercase makes a global mark
  • a number (of your choosing) marks a tab

so you could do e.g. m7 to make a mark to e.g. the 137th tab, no matter where it moved (i think providing that it stays in the same window)

@Zerogaku
Copy link
Author

That sounds great!

@UreshiiPanda
Copy link

I was also really hoping there could be some "marktab" and "marktabjump" features. The global jump to a url instead of to a tab feels counter-intuitive to me.

Is there any way the choice of lowercase/uppercase/number part could be left up to the users? Since I use global marks way more than local marks, I'd rather just set my global marks to lowercase letters but as of right now this is pre-decided by Tridactyl (I understand that this follows the Vim layout though). Numbers are also less memorable imo. Eg. I'd mark a tab with GPT in it with a g and I wouldn't need to think twice about where GPT is, but if I had 5 tabs marked and they're all marked with numbers, I'll probably forget which numbers I marked where, especially if I'm changing/moving marks often enough. I think letters are much more intuitive, maybe this is just me though.

@bovine3dom
Copy link
Member

On my phone so excuse my brevity: run the two commands

bind m gobble 1 markaddglobal
bind ` gobble 1 markjumpglobal

@bovine3dom
Copy link
Member

For marking tabs you could try :bind [whatever] tab [fragment of title or URL], that'll jump to the best match. Not exactly what you're asking for but maybe good enough

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants