Files
dev/script/test/TestTab.py
2020-10-12 18:03:27 +02:00

18 lines
593 B
Python

import ch.psi.utils.swing.TextEditor as TextEditor
import ch.psi.pshell.ui.App as App
title="CXXC3"
editor = TextEditor();
tabpane = App.getInstance().getMainFrame().getLeftTab();
App.getInstance().getMainFrame().openComponent(title, editor, tabpane)
for i in range(App.getInstance().getMainFrame().getLeftTab().getTabCount()):
t=App.getInstance().getMainFrame().getLeftTab().getTabComponentAt(i)
if t:
if t.getLabel().getText() == title:
for l in t.getLabel().getMouseListeners():
print l
t.getLabel().removeMouseListener(l)