casa
5.7.0-16
|
Main window which is mainly responsible for menu actions. More...
#include <TBMain.qo.h>
Signals | |
void | closeTableTriggered (casacore::String name) |
This signal is emitted when a close menu command is given with a table name. More... | |
Public Member Functions | |
TBMain () | |
Default Constructor. More... | |
~TBMain () | |
void | openTable (casacore::String filename, DriverParams *dp=NULL, int start=0, int num=TBConstants::DEFAULT_SELECT_NUM) |
Opens a table with the given file name and driver parameters. More... | |
Protected Member Functions | |
void | closeEvent (QCloseEvent *event) |
Catches a close event for the window. More... | |
Private Slots | |
void | openTable () |
Opens a filechooser dialog to allow the user to open a table. More... | |
void | openTaQL () |
Opens a TBTaQL dialog to allow the user to open a table using a TaQL command. More... | |
void | tableOpened (casacore::String name, casacore::String fullpath) |
Connects with TBBrowser::tableOpened() signal. More... | |
void | closeTable () |
void openTableWithOptions(); More... | |
void | closeTable (QAction *which) |
Closes the table corresponding to the given action's name. More... | |
void | closeAll () |
Closes all opened tables. More... | |
void | closeAllAndExit () |
Closes all currently opened tables and closes the window. More... | |
void | showVersion () |
void | tableClosed (casacore::String name) |
Connects with TBBrowser::tableClosed() signal. More... | |
void | tabChanged (int tableIndex) |
Slot for when the tab is changed in the browser. More... | |
void | viewColumn (QAction *which) |
Shows or hides the column on the current table that corresponds to the name of the given action. More... | |
void | columnHidden (int index, bool hidden) |
Updates the column menu to indicate that the given column has been shown/hidden. More... | |
void | actionPerformed (TBAction *action) |
Updates display to indicate the last action performed. More... | |
void | actionUndone () |
Updates display to indicate that the last action was undone. More... | |
void | actionRedone () |
Update display to indicate that the last undone action was redone. More... | |
void | undoAction () |
Undoes the last performed action. More... | |
void | redoAction () |
Redoes the last undone action. More... | |
void | editCurrentTable () |
Enters the currently selected table into editing mode. More... | |
void | editTable (QAction *action) |
Enters the table corresponding to the given edit action into editing mode. More... | |
void | exportVOTable () |
Exports the current table to VOTable format. More... | |
void | threadFinished () |
Reenables menus after a task thread has completed. More... | |
void | checkValidity () |
Opens a new TBValidityChecker widget. More... | |
void | plot2D () |
Opens a new TBPlotter window. More... | |
void | showAllColumns () |
Shows all the columns in the currently selected table. More... | |
void | hideAllColumns () |
Hides all the columns in the currently selected table. More... | |
void | filterOnFields () |
Opens widget to enter filter rules for the current table. More... | |
void | clearFilterOnFields () |
Clears the current filter on the current table. More... | |
void | filterRuleAvailable (int i) |
Enables the "clear filter" action. More... | |
void | filterRuleCleared (int i) |
Disables the "clear filter" action. More... | |
void | find () |
Opens widget to enter search rules for the current table. More... | |
void | findNext () |
Searches for the next row matching the search rule for the current table. More... | |
void | findPrev () |
Searches for the previous row matching the search rule for the current table. More... | |
void | findRuleAvailable () |
Slot for when the current table has a find rule associated with it. More... | |
void | sortEntered () |
Slot for when a sort has been entered for the current table. More... | |
void | sortCleared () |
Slot for when a sort has been cleared for the current table. More... | |
void | viewTableInfo () |
Displays table information for the currently selected table. More... | |
void | formatDisplay (QAction *which) |
Formats the field with the name in the given QAction. More... | |
void | openHelp () |
Opens the help window. More... | |
void | insertRows () |
Shows an insert rows dialog. More... | |
void | deleteRows () |
Shows a delete rows dialog. More... | |
void | sort () |
Shows a sort dialog. More... | |
void | clearSort () |
Clears the current sort. More... | |
void | sort (std::vector< std::pair< casacore::String, bool > > &sort) |
casacore::Sort the current table with the given order. More... | |
void | options () |
Allows the user to edit table options. More... | |
void | saveOptions (TBOptions *opt) |
Applies the user-provided options and deletes the TBOptions widget. More... | |
Private Member Functions | |
void | setup () |
Sets up GUI components and signal/slot connections. More... | |
void | setupKeyboardShortcuts () |
Sets up the keyboard shortcuts. More... | |
void | enableMenus (bool en) |
Calls setEnabled() on all menus with the given parameter. More... | |
void | editTable (TBTableTabs *table, bool edit) |
Turns on/off editing, if write lock is available, on the given table. More... | |
Private Attributes | |
TBBrowser | browser |
Browser object. More... | |
QStatusBar * | statusBar |
The window's status bar. More... | |
QMenu * | closeMenu |
Close menu that lists all currently opened tables. More... | |
QMenu * | columnsMenu |
Columns menu that lists the table fields in the currently selected table. More... | |
QMenu * | editTablesMenu |
Edit menu that lists all currently opened tables. More... | |
bool | waiting |
Indicates whether the main window is waiting for some other task to complete or not. More... | |
QAction * | separator |
Separator added in the Edit menu before the Options command. More... | |
QMenu * | formatMenu |
casacore::Format menu that lists the table fields in the currently selected table. More... | |
QToolBar * | fileBar |
Toolbar holding "file"-related menu commands. More... | |
QToolBar * | editBar |
Toolbar holding "edit"-related menu commands. More... | |
QToolBar * | viewBar |
Toolbar holding "view"-related menu commands. More... | |
QToolBar * | toolBar |
Toolbar holding "tool"-related menu commands. More... | |
bool | saveView |
Indicates whether the TBMain should save the current view on close or not. More... | |
Main window which is mainly responsible for menu actions.
TBMain is a QMainWindow subclass that wraps about a TBBrowser object. Its main responsibility is to provide menu commands and interact with the TBBrowser.
Definition at line 55 of file TBMain.qo.h.
casa::TBMain::TBMain | ( | ) |
Default Constructor.
casa::TBMain::~TBMain | ( | ) |
|
privateslot |
Updates display to indicate the last action performed.
|
privateslot |
Update display to indicate that the last undone action was redone.
|
privateslot |
Updates display to indicate that the last action was undone.
|
privateslot |
Opens a new TBValidityChecker widget.
|
privateslot |
Clears the current filter on the current table.
|
privateslot |
Clears the current sort.
|
privateslot |
Closes all opened tables.
|
privateslot |
Closes all currently opened tables and closes the window.
|
protected |
Catches a close event for the window.
If a background task is running, a confirmation dialog is presented to the user. If the "save view on close" option is turned on, the current view is saved to the default location.
|
privateslot |
void openTableWithOptions();
Closes the currently selected table.
|
privateslot |
Closes the table corresponding to the given action's name.
|
signal |
This signal is emitted when a close menu command is given with a table name.
|
privateslot |
Updates the column menu to indicate that the given column has been shown/hidden.
|
privateslot |
Shows a delete rows dialog.
|
privateslot |
Enters the currently selected table into editing mode.
|
private |
Turns on/off editing, if write lock is available, on the given table.
|
privateslot |
Enters the table corresponding to the given edit action into editing mode.
|
private |
Calls setEnabled() on all menus with the given parameter.
|
privateslot |
Exports the current table to VOTable format.
|
privateslot |
Opens widget to enter filter rules for the current table.
|
privateslot |
Enables the "clear filter" action.
|
privateslot |
Disables the "clear filter" action.
|
privateslot |
Opens widget to enter search rules for the current table.
See TBBrowser::find().
|
privateslot |
Searches for the next row matching the search rule for the current table.
|
privateslot |
Searches for the previous row matching the search rule for the current table.
|
privateslot |
Slot for when the current table has a find rule associated with it.
|
privateslot |
Formats the field with the name in the given QAction.
|
privateslot |
Hides all the columns in the currently selected table.
|
privateslot |
Shows an insert rows dialog.
|
privateslot |
Opens the help window.
See TBHelp.
void casa::TBMain::openTable | ( | casacore::String | filename, |
DriverParams * | dp = NULL , |
||
int | start = 0 , |
||
int | num = TBConstants::DEFAULT_SELECT_NUM |
||
) |
Opens a table with the given file name and driver parameters.
If the driver parameters are NULL, the defaults are used. If a start and num are provided, those rows are loaded into the new table; otherwise the default number of rows are loaded.
|
privateslot |
Opens a filechooser dialog to allow the user to open a table.
|
privateslot |
Opens a TBTaQL dialog to allow the user to open a table using a TaQL command.
|
privateslot |
Allows the user to edit table options.
See TBOptions.
|
privateslot |
Opens a new TBPlotter window.
|
privateslot |
Redoes the last undone action.
|
privateslot |
Applies the user-provided options and deletes the TBOptions widget.
|
private |
Sets up GUI components and signal/slot connections.
|
private |
Sets up the keyboard shortcuts.
|
privateslot |
Shows all the columns in the currently selected table.
|
privateslot |
|
privateslot |
Shows a sort dialog.
See TBSorter.
|
privateslot |
casacore::Sort the current table with the given order.
See TBBrowser::sort().
|
privateslot |
Slot for when a sort has been cleared for the current table.
|
privateslot |
Slot for when a sort has been entered for the current table.
|
privateslot |
Slot for when the tab is changed in the browser.
Updates all necessary menus.
|
privateslot |
Connects with TBBrowser::tableClosed() signal.
Updates dynamic menus as necessary.
|
privateslot |
Connects with TBBrowser::tableOpened() signal.
Updates dynamic menus as necessary.
|
privateslot |
Reenables menus after a task thread has completed.
|
privateslot |
Undoes the last performed action.
|
privateslot |
Shows or hides the column on the current table that corresponds to the name of the given action.
|
privateslot |
Displays table information for the currently selected table.
|
private |
Browser object.
Definition at line 86 of file TBMain.qo.h.
|
private |
Close menu that lists all currently opened tables.
Definition at line 92 of file TBMain.qo.h.
|
private |
Columns menu that lists the table fields in the currently selected table.
Definition at line 96 of file TBMain.qo.h.
|
private |
Toolbar holding "edit"-related menu commands.
Definition at line 117 of file TBMain.qo.h.
|
private |
Edit menu that lists all currently opened tables.
Definition at line 99 of file TBMain.qo.h.
|
private |
Toolbar holding "file"-related menu commands.
Definition at line 114 of file TBMain.qo.h.
|
private |
casacore::Format menu that lists the table fields in the currently selected table.
Definition at line 111 of file TBMain.qo.h.
|
private |
Indicates whether the TBMain should save the current view on close or not.
Definition at line 127 of file TBMain.qo.h.
|
private |
Separator added in the Edit menu before the Options command.
Definition at line 107 of file TBMain.qo.h.
|
private |
The window's status bar.
Definition at line 89 of file TBMain.qo.h.
|
private |
Toolbar holding "tool"-related menu commands.
Definition at line 123 of file TBMain.qo.h.
|
private |
Toolbar holding "view"-related menu commands.
Definition at line 120 of file TBMain.qo.h.
|
private |
Indicates whether the main window is waiting for some other task to complete or not.
If the window is waiting, menu commands will not respond.
Definition at line 104 of file TBMain.qo.h.