Multi-row Open File Tabs and Filename Truncation

Hi

I have been using Komodo IDE 8.5.4 for a few months now and there are two primary things that mar my experience on a day to day basis:

  1. No multi-row open file tabs

Personally, I want to be able to see all the files I have open at once, without having to click on anything else.

  1. Truncation of long file names

Combines with the above in annoyance because as well as not being able to see all open files, file names can be truncated. We commonly have file names up to about 60 characters long where only the last part of the file name distinguishes between two files. Komodo seems to chop at 25 characters. I know I can mouse over the tab but it’s an extra thing to do when switching between files and viewing what you’ve got open.

Two other prominent programming editors/IDEs - UltraEdit (which we moved from) and IntelliJ IDEA (which we also have licenses for) - have these usability features. I’m hoping someone will point out an option somewhere I’ve missed but otherwise can ActiveState add these please?

Alternatively, is it possible to write a plugin that would achieve these features? I’ve not tried writing Mozilla plugins before so don’t know how easy/hard it would be?

Regards

You must know XUL, JavaScript or Python and Komodo API (Components.classes and Components.services), so it’s not too easy at beginning of add-on creation but 5-10 days of learning Komodo sources (only if you know XUL (MDN - XUL), JavaScript or Python) - you already can create simple add-on.

OK thanks Defman. I would need to learn XUL as well. I might have a stab at that if I can find the time.

If you know HTML and English - XUL will be easy to learn, because a lot of XUL tags named as in real life: <splitter>, <hbox>, <vbox>, etc…

Hi @swarhurst, please check out the Open Files screencast, I think this will address many of your needs.

I’ll consider your feedback for the tabs (namely trunacting labels more meaniningfully), but I don’t think we’ll be adding multi-row tabs as if you require that functionality you should really be using the Open FIles widget.

Hi Nathan

Thanks for the reply and the link.

I’ve had a look at the Open Files widget and it does improve things to a degree, although I’d still rather have multi-row tabs so the side bar can be fully dedicated to the directory tree. It also makes the tabs kind of redundant on the screen. It seems to me the benefits of both are satisfied with multi-row tabs.

While I think it’s great that different software creators innovate and come up with their own takes on handling common tasks, I think they should also provide the commonly used methods as well, then users can decide which they prefer. If my experience with UltraEdit and IntelliJ IDEA are representative of most IDEs then multi-row tabs are a commonly accepted way of handling lots of open files.

On the file name truncation, thanks for adding it to your list for consideration. Maybe you could add a setting that allows full file names and/or even a field for specifying the truncation point.

Regards

Note you can combine the files tree with the open files in your sidebar (right click the icon for the pane > Customize > Drag Open Files on top of Places).

I think the commonly used methods is tabs, having it be multi-row is in my opinion a lazy solution to a problem that can be solved much better with a completely different approach; eg. the Open Files pane.

Komodo is Mozilla based so you could with relative ease build multi-tabs in yourself, but I don’t think it’s something we’ll be adding natively as in my opinion it promotes a bad workflow. I really think that anyone who would be interested in multi-row tabs would absolutely love the “Open FIles” pane once they use it for a while. It might be a bit jarring at first if you aren’t used to handling your open files that way, but you’ll get past that soon enough.

That said, I will definitely be looking into truncating filenames properly and making tab sizes more flexible (smaller if you have lots of open tabs).

This may not be fair (since I work with Nathanr (we don’t always agree)) but I totally agree with Nathan. Dual rows of tabs would very quickly get cluttered and unogranized.

Open files can be opened with a keybinding (I set ctrl k, ctrl o for me) and organized how ever you want. Also, when I use open file i remove the tabs; View > uncheck “view Editor Tabs”. It took come getting used to but it’s WAY easier to see many files at a time now.

  • Carey

Hi Guys

I have set the Open Files widget up so that it shares the left sidebar with the directory tree. It is certainly more usable to me than tabs as they are currently implemented in Komodo.

My point though, was why not support both methods? If there is a commonly used method in other editors why not support that as well and let the user decide which they want to use? Flexibility is a good thing in software because different users have different ways they prefer doing things. I’ve used a multi-row tab editor (with different colours for different files types - yeah, I’ve found and utilised the ColorTab addon for Komodo) for years and it worked perfectly for me and didn’t seem to promote bad workflow at all.

It’s like (although this is obviously way more ubiquitous than multi-row tabs) IntelliJ IDEA doesn’t have a “Save As” option for files, unlike virtually every other bit of file editing software on the planet. Obviously a deliberate omission and one they have their reasons for, but conversely there is almost certainly no reason why they couldn’t have provided a Save As option, so why didn’t they? Why not provide common features to help draw migrating users in and they can discover your amazing new ways of working once they settle in? The Save As thing in IDEA is a relatively trivial thing but, along with some other minor niggles, it put me off what is otherwise a well crafted piece of software. The sum of those niggles is also why, as a team, we get along with Komodo better :slight_smile:

Regards

A couple reasons why we would not want to include a feature that one might think is a no brainer:

  • Maintainability, every feature you add has to be maintained (bugs, support, compatibility … )
  • Appearance, multi-tabs are ugly and unwieldly, personally I wouldn’t want a ton of people to be using that and spreading the misconception that this is what default-komodo looks like
  • Promoting a bad workflow, I really believe that anyone that uses tabs to manage a large amount of open files is shooting himself in the foot because it is impossible to keep a clean oversight of the files that you are working with. I think multi-tabs were only ever “invented” as a quick & dirty solution to a real problem, and caught on because the real solution might not be as easy to grasp initially.

All that said, it’s precisely because people want to customize their IDE to their own personal preference (whether we agree with it or not) that we make Komodo as customizable as possible.

@toddw is actually preparing a blog on a multi-row tabs macro, I’ll cheat a bit and include his solution here so you can start using it right away:

/* Make the editor scroll tabs wrap around. */
#topview .arrowscrollbox-scrollbox {
    overflow: visible;
}
#topview .arrowscrollbox-scrollbox > box {
    display: inline-block;
}

You can use this by installing Stylish and adding a User Style under Tools > Addons > User Styles (after installing Stylish and restarting Komodo).

Hi Nathan

Not wishing to labour the point :wink: but I agree that multi-row tabs could lead to the negatives you state if you had like 20 files open and more than two rows but a common scenario in our workflow is having a group of 6 to 8 files open (css/js/html/perl) which often goes into a second row (given 2 sidebars open and depending on filename length). To me, that is perfectly manageable, doesn’t take up too much extra vertical height and looks absolutely fine.

Anyway, I appreciate that Komodo has a high degree of flexibility and thanks for taking the time to respond (even if we might have to agree to disagree on certain points ;-).

That “Stylish” & CSS solution is fantastic, thanks :slight_smile: How does one find out all the styles in use in the Komodo interface? Is there a plugin or other means where you can click on a UI element and see it’s properties in that way?

Regards

For 6-8 tabs ideally the tabs should be “responsive” and resize to fit all of the tabs in your tab bar, which is something I’ll be looking into.

As for inspecting the UI, you can use DOM Inspector for that, it’s not quite as fancy as the chrome/firefox DOM inspectors, but it’ll get the job done :slight_smile:

Also I recommend Element Inspector - https://addons.mozilla.org/en-US/firefox/addon/element-inspector/?src=search

Great, thanks. I’ve installed DOM Inspector. Element Inspector wouldn’t install in Komodo 8.5.4.

If you want to get Element Inspector work you must edit some strings in install.rdf.
I made it for you - download it here

Maybe someone could fork the project and add it to our resources section… hint :smiley:

There is no repositories for this add-on but… Yeah, I understand your hint :wink:

https://bitbucket.org/zbinlin/element-inspector

It’s just one file and no commit history though, so I wouldn’t even bother.

Thanks Defman, got it :slight_smile:

Now element inspector for komodo here

Also it will be available in Resources.