/** * Notification that a user has logged in to the server. A new title will be set * to the tab of the given debugger. * * @param debugger the debugger whose connection logged in to the server * @param user the user@host/resource that has just logged in */ static synchronized void userHasLogged(EnhancedDebugger debugger, String user) { int index = getInstance().tabbedPane.indexOfComponent(debugger.tabbedPane); getInstance().tabbedPane.setTitleAt( index, user); getInstance().tabbedPane.setIconAt( index, connectionActiveIcon); }
/** * Updates all text labels in the GUI with localized labels. */ private void setLocalLabels() { this.controlContextTabbedPane.setTitleAt(0, Localization.getString("mainWindow.swing.controlContextTabbedPane.machineControl")); this.controlContextTabbedPane.setTitleAt(1, Localization.getString("mainWindow.swing.controlContextTabbedPane.macros")); this.controlContextTabbedPane.setTitleAt(2, Localization.getString("mainWindow.swing.visualizeButton")); this.firmwareSettingsMenu.setText(Localization.getString("mainWindow.swing.firmwareSettingsMenu")); this.grblConnectionSettingsMenuItem.setText(Localization.getString("mainWindow.swing.grblConnectionSettingsMenuItem")); this.grblFirmwareSettingsMenuItem.setText(Localization.getString("mainWindow.swing.grblFirmwareSettingsMenuItem")); this.settingsMenu.setText(Localization.getString("mainWindow.swing.settingsMenu")); this.macroEditPanel.setToolTipText(Localization.getString("mainWindow.swing.macroInstructions")); this.pendantMenu.setText(Localization.getString("mainWindow.swing.pendant")); this.gcodeProcessorSettings.setText(Localization.getString("settings.processors.header")); }
SqlEngine.TAB_ERROR.setTitleAt(SqlEngine.TAB_ERROR.getTabCount() - 1, "<html><div style=\"text-align:left;width:150px;\">"+ methodError.getName() +"</div></html>");
this.commandLabel.setText(Localization.getString("mainWindow.swing.commandLabel")); this.connectionPanel.setBorder(javax.swing.BorderFactory.createTitledBorder(Localization.getString("mainWindow.swing.connectionPanel"))); this.controlContextTabbedPane.setTitleAt(0, Localization.getString("mainWindow.swing.controlContextTabbedPane.machineControl")); this.controlContextTabbedPane.setTitleAt(1, Localization.getString("mainWindow.swing.controlContextTabbedPane.macros")); this.durationLabel.setText(Localization.getString("mainWindow.swing.durationLabel")); this.fileModePanel.setBorder(javax.swing.BorderFactory.createTitledBorder(Localization.getString("mainWindow.swing.fileLabel"))); this.settingsMenu.setText(Localization.getString("mainWindow.swing.settingsMenu")); this.statusPanel.setBorder(javax.swing.BorderFactory.createTitledBorder(Localization.getString("mainWindow.swing.statusPanel"))); this.bottomTabbedPane.setTitleAt(0, Localization.getString("mainWindow.swing.bottomTabbedPane.console")); this.bottomTabbedPane.setTitleAt(1, Localization.getString("mainWindow.swing.bottomTabbedPane.table")); this.latestCommentLabel.setText(Localization.getString("mainWindow.swing.latestCommentLabel")); this.machinePosition.setText(Localization.getString("mainWindow.swing.machinePosition"));
public void setTitleAt(int index, String name) { panes.get(index).name = name; if(panes.size() > 1) { tabbedPane.setTitleAt(index, name); } }
/** * Set the title of the current (visible) tab * * @param title the tab title to use */ protected void setCurrentTabTitle(String title) { m_flowTabs.setTitleAt(getCurrentTabIndex(), title); }
public class WhateverFrame extends JFrame{ private JTabbedPane tabbedPane; public WhateverFrame() { BrowserPanel x=new BrowserPanel(); tabbedPane = new JTabbedPane(JTabbedPane.TOP); tabbedPane.add(x, BorderLayout.WEST); tabbedPane.setTitleAt(0, "Start"); /* * add the tabbedPane to the content pane */ setContentPane(tabbedPane); }
public final void setViewName(Component view, String name) { int viewIndex = getViewIndex(view); if (viewIndex == -1) return; if (tabs == null) firstName = name; else tabs.setTitleAt(viewIndex, name); }
public void actionPerformed(ActionEvent e) { int tabIndex = sheetPane.getSelectedIndex(); if (tabIndex != -1) { String newSheetName = JOptionPane.showInputDialog(sheetPane, "Enter a new Sheetname", "Rename Sheet", JOptionPane.QUESTION_MESSAGE); if (newSheetName != null) { wb.setSheetName(tabIndex, newSheetName); sheetPane.setTitleAt(tabIndex, newSheetName); } } } }
@Override public void actionPerformed(ActionEvent e) { int tabIndex = sheetPane.getSelectedIndex(); if (tabIndex != -1) { String newSheetName = JOptionPane.showInputDialog(sheetPane, "Enter a new Sheetname", "Rename Sheet", JOptionPane.QUESTION_MESSAGE); if (newSheetName != null) { wb.setSheetName(tabIndex, newSheetName); sheetPane.setTitleAt(tabIndex, newSheetName); } } } }
public void actionPerformed(ActionEvent e) { int tabIndex = sheetPane.getSelectedIndex(); if (tabIndex != -1) { String newSheetName = JOptionPane.showInputDialog(sheetPane, "Enter a new Sheetname", "Rename Sheet", JOptionPane.QUESTION_MESSAGE); if (newSheetName != null) { wb.setSheetName(tabIndex, newSheetName); sheetPane.setTitleAt(tabIndex, newSheetName); } } } }
@Override public void onRelocalization() { for (int i = 0; i < this.tabbedPane.getTabCount(); i++) { this.tabbedPane.setTitleAt(i, this.tabs.get(i).getTitle()); } } }
public void setTitleForComponent(Component comp, String title, String tooltip) { int index = tabs.indexOfComponent(comp); if (index != -1) { tabs.setTitleAt(index, title); tabs.setToolTipTextAt(index, tooltip); } }
@Override public void setTitleAt(int index, String title) { Component cmpt = this.getTabComponentAt(index); if( cmpt instanceof TabQuery )((TabQuery)cmpt).setTabTitle(title); super.setTitleAt(index, title); }
private static void setTabTitle(JTabbedPane tabs, Component c, String string) { for (int i = tabs.getTabCount(); i-- != 0;) { Component tc = tabs.getComponent(i);//tabs.getTabComponentAt(i); if (tc == c) { tabs.setTitleAt(i, string); return; } } }
protected void addChildrenToGearTab() { if (!allComponentsCreated) { return; } gearTab.add(gearTabUI); gearTab.add(selectivityUI); $TabInfo0.addPropertyChangeListener(new TabInfoPropertyChangeListener(gearTab, 0)); gearTab.setTitleAt(0, t("isisfish.gear.title")); $TabInfo1.addPropertyChangeListener(new TabInfoPropertyChangeListener(gearTab, 1)); gearTab.setTitleAt(1, t("isisfish.selectivity.title")); }
protected void addChildrenToStrategyTab() { if (!allComponentsCreated) { return; } strategyTab.add(strategyTabUI); strategyTab.add(strategyMonthInfoUI); $TabInfo0.addPropertyChangeListener(new TabInfoPropertyChangeListener(strategyTab, 0)); strategyTab.setTitleAt(0, t("isisfish.strategy.title")); $TabInfo1.addPropertyChangeListener(new TabInfoPropertyChangeListener(strategyTab, 1)); strategyTab.setTitleAt(1, t("isisfish.strategyMonthInfo.title")); }
public void updateTabTitle() { int itemCount = getItemCount(); String title = String.format("%s (%d/%s)", this.title, itemCount, listModel.size()); JComponent navigationContent = parent.getNavigationContent(); if (navigationContent instanceof JTabbedPane) { ((JTabbedPane) navigationContent).setTitleAt(tabIndex, title); } }
public synchronized void setTabTitle(int index, String title) { if (index < getNumTabs() && index >= 0) { m_flowTabs.setTitleAt(index, title); ((CloseableTabTitle) m_flowTabs.getTabComponentAt(index)).revalidate(); } }
private void updateTabTitle( final GraphCanvas graphCanvas, final Workflow workflow) { int index = XBayaGUI.this.graphTabbedPane.indexOfComponent(graphCanvas.getSwingComponent()); String newTitle = workflow.getName(); if (graphCanvas.isWorkflowChanged()) { newTitle = "*" + newTitle; } XBayaGUI.this.graphTabbedPane.setTitleAt(index, newTitle); } });