After setting setSingleRow in EditTabs, the SideComponent of TabInfo does not display

Answered

This is the code I used to create EditTabs

        this.jbTabs = JBTabsFactory.createEditorTabs(project, this);
       jbTabs.getPresentation().setTabDraggingEnabled(true);
       jbTabs.getPresentation().setSingleRow(false);
       jbTabs.getPresentation().setSideComponentOnTabs(true);

 

When I set setSingleRow (false), the SideComponent of TabInfo does not display.

How to make him display? I have checked the source code, but I have no idea

 

 

0
1 comment

Hi,

Side components are supported only in a single-row layout.

If this functionality is crucial for your use case, you can create a feature request in the tabs’ behavior at https://youtrack.jetbrains.com/issues/IJPL (Subsystem: UI. Tabs). If you create an issue, please add mockups about the expected look/layout and describe your use case in detail. Please note there are no guarantees about the timeframe of implementing it.

You can also implement your own layout: com.intellij.ui.tabs.impl.TabLayout. Please note that this is not trivial and we cannot provide support in this area. In this case, I suggest checking implementations and usages in https://github.com/JetBrains/intellij-community source code.

0

Please sign in to leave a comment.