CanvasWindow Class Reference

#include <CanvasWindow.h>

Inheritance diagram for CanvasWindow:

Inheritance graph
CanvasWindowBaseQMainWindow
[legend]
Collaboration diagram for CanvasWindow:

Collaboration graph
InspectorCanvasWindowBaseQMainWindowQActionGroupQMenuBarQPopupMenuQPixmapPlotTableBaseQActionQToolBarPlotTableQDialogQPushButtonQListViewQGridLayoutQWidgetCanvasViewFigureEditorQStringXmlControllerViewBaseXMLHiNTupleXMLDataRepXMLTupleCutXMLQtFileDialogQCanvasRectangleXmlElementXmlDocumentViewFactoryQFileDialog
[legend]

List of all members.


Detailed Description

A concrete window class that contains the canvas and responds to menu item and tool bar events from the window and messages sent by the Inspector.

Attention:
This class should implement those actions specific to HippoDraw as an application. All changes to the CanvasView should be implemented in the that class so that other applications can benefit from the implementation.
Bug:
@ After using edit->paste, trying to selected the pasted plot leads to selecting the original.
Bug:
@@@ It appears that if one cuts a cut from the canvas, then the target doesn't get its cut removed.
Bug:
If a document could not be opened, error messages displays, but one get a new empty canvas window. It is not throwing an exception which is read to be caught.
Bug:
The View/Cut empty pages button doesn't work and is not enabled.
Bug:
@@ Opening a document that references a ROOT array variable doesn't work.
Requests:
Have a editable DataSource table view.
Requests:
@ Open documents read only. This could be the default when the file Open menu item is used.
Requests:
A clear all button on the tool bar.
Todo:
@@ Be able to ask canvas if it is saved from Python.
Todo:
Make it a setting if the Inspector window comes up automatically or not.
Todo:
Respond to Page Up and Page Down keys.
Todo:
Needs something to display on the canvas for values only seen in the Inspector. One example is the name of a DataSource file file. This is so that the document when printed can be more useful as a stand alone.
Todo:
Use Qt's network example ftpclient to open files via ftp.
Author:
Jim Chiang <jchiang@slac.stanford.edu>

Kaustuv <kaustuv@stanford.edu>

Paul F. Kunz <Paul_Kunz@slac.stanford.edu>

Sanket B. Malde <sanket@stanford.edu>

Definition at line 107 of file CanvasWindow.h.


Public Slots

virtual void menubar_activated ()

Public Member Functions

void addDisplay (PlotterBase *plotter)
 Adds a new plot to the canvas and selects it.
 addDockWindow (QDockWindow *dockWindow, const QString &label, Dock edge=DockTop, bool newLine=FALSE)
 addDockWindow (QDockWindow *dockWindow, Dock edge=DockTop, bool newLine=FALSE)
void addFuncDisplay (PlotterBase *plotter, const std::string &name)
 Adds function textual display to the canvas.
void addPlotDisplay (PlotterBase *plotter, bool select)
 Adds a new plot display to the canvas.
void addTextDisplay (PlotterBase *plotter, const std::string &type, const std::string &text)
 Adds a textual display to the canvas of type type.
void addTextDisplay (PlotterBase *plotter, const std::string &type)
 Adds a textual display to the canvas of type type.
std::pair< double,
double > 
addTextDisplayAt (PlotterBase *plotter, const std::string &type, const std::string &text, double xrel, double yrel)
 Adds a text display at the relative position (xrel, yrel) in the selected item's coordinates.
bool allowClose ()
 If document has changed and not saved, opens a dialog box for user to choose to save, discard or cancel.
 appropriate (QDockWindow *dw) const
void autosaveSettings ()
 Automatically save dock windows and recently opened files.
 bottomDock () const
 CanvasWindow (const CanvasWindow &)
 A copy constructor that does nothing except keep boost.python happy.
 CanvasWindow (QWidget *parent=0, const char *name=0, Qt::WFlags fl=Qt::WType_TopLevel)
 constructor.
 centralWidget () const
 childEvent (QChildEvent *e)
void clear ()
 Removes all items from the canvas.
virtual bool closeNoPrompt ()
 Closes the window.
 createDockWindowMenu (DockWindows dockWindows=AllDockWindows) const
virtual void customEvent (QCustomEvent *event)
 Responds to QCustomEvents.
 customize ()
 dockWindowPositionChanged (QDockWindow *dockWindow)
 dockWindows () const
 dockWindows (Dock dock) const
 dockWindowsMovable () const
 enum {OnlyToolBars, NoToolBars, AllDockWindows}
virtual void fileNew ()
 Creates a new document CanvasWindow.
void fileSave ()
 Saves the document.
virtual void fileSaveAs ()
 Saves the document after display a file dialog to the user.
virtual void fileSaveSelectedImages (const std::string &filename)
 Saves the selected ViewBase objects as an image file with the given filename.
virtual void fileSaveSelectedImages ()
 Saves the selected ViewBase object as an image file.
void fillPlotterList (std::vector< PlotterBase * > &plotter_list)
 Clears and fills plotter_list with all the PlotterBase objects on the canvas.
const QStringgetAppKey () const
 Returns a reference the application's QSettings key.
CanvasViewgetCanvasView ()
 Returns the CanvasView object.
 getLocation (QDockWindow *dw, Dock &dock, int &index, bool &nl, int &extraOffset) const
NTuplegetPickTable (const PlotterBase *plotter) const
 Gets the pick table of a plotter.
NTuplegetPickTable () const
 Gets the pick table the selected plotter.
QtViewgetViewFor (const PlotterBase *plotter) const
 Returns the QtView object that is the Observer of the plotter.
 gt (QTextStream &ts, QMainWindow &mainWindow)
 hasDockWindow (QDockWindow *dw)
void inhibitClose (bool yes=true)
 If yes is true, sets a flag so that this object will not accept close events.
void initFromFile (const std::string &filename)
 Initializes this object from contents of file.
 isCustomizable () const
 isDockEnabled (QDockWindow *dw, QDockArea *area) const
 isDockEnabled (QDockWindow *tb, Dock dock) const
 isDockEnabled (QDockArea *area) const
 isDockEnabled (Dock dock) const
 isDockMenuEnabled () const
 leftDock () const
 lineUpDockWindows (bool keepNewLines=FALSE)
 lt (QTextStream &ts, const QMainWindow &mainWindow)
 menuAboutToShow ()
 menuBar () const
const std::vector
< double > & 
mouseEventData ()
 Retrieve a vector (x, y, z) points from the next mouse event.
 moveDockWindow (QDockWindow *dockWindow, Dock edge, bool nl, int index, int extraOffset=-1)
 moveDockWindow (QDockWindow *dockWindow, Dock edge=DockTop)
 opaqueMoving () const
 pixmapSizeChanged (bool)
void print (const std::string &filename)
 Prints the view to Postscript file without prompting user.
 prop -whether text labels for toolbar buttons are enabled
 prop -whether big pixmaps are enabled
 prop -whether dock windows are moved opaquely
 prop -whether the dock windows are movable
 QDockWindow () and
void removeDisplay (PlotterBase *plotter)
 Removes the plotter and its view from the canvas.
 removeDockWindow (QDockWindow *dockWindow)
 rightDock () const
void saveAllAs (const std::string &filename)
 Saves the document along with its NTuple objects.
void saveAs (const std::string &filename)
 Saves the document to the specified file.
void saveAsImage (const PlotterBase *plotter, const std::string &filename)
 Saves the plotter as image file.
void savePlotAsImage (const PlotterBase *plotter, const std::string &filename)
 Saves the plotter as image file.
PlotterBaseselectedPlotter ()
 Returns the selected plotter.
void setAddedSelected (bool yes)
 Sets to flag to make plots in their selected state when added to the canvas.
void setAllowClose (bool yes=true)
 Sets the window to allowed to be closed by user without prompting.
void setAllSelected (bool flag=true)
 Select or deselect all views in the window.
 setAppropriate (QDockWindow *dw, bool a)
void setCaption ()
 Sets the Windows title.
 setCentralWidget (QWidget *w)
void setChanged (bool flag=true)
 Sets the changed flag.
 setDockEnabled (QDockWindow *dw, Dock dock, bool enable)
 setDockEnabled (Dock dock, bool enable)
 setDockMenuEnabled (bool b)
 setDockWindowsMovable (bool)
void setIntervalEnabled (bool yes=true)
 Sets the display interval feature to enabled if yes is true, otherwise sets it to disabled.
 setOpaqueMoving (bool)
void setPlotMatrix (unsigned int columns, unsigned int rows)
 Sets the number of columns and rows of plots on each page.
void setSelected (QtView *view)
 Select a specific view in the window.
 setUpLayout ()
 setUsesBigPixmaps () is used to set whether tool buttons should
 setUsesBigPixmaps (bool)
 setUsesTextLabel () is used to set whether tool buttons
 setUsesTextLabel (bool)
 showDockMenu (const QPoint &globalPos)
 statusBar () const
 toolBars (Dock dock) const
 toolTipGroup () const
 topDock () const
void updateActions ()
 Update Action objects.
 usesBigPixmaps () const
 usesTextLabel () const
 usesTextLabelChanged (bool)
const std::vector
< const ViewBase * > & 
views ()
 Returns the list of ViewBase objects on the canvas.
 whatsThis ()
virtual ~CanvasWindow ()

Static Public Member Functions

static void resetFontSize ()
 Resets the font size to be no larger than 10.

Public Attributes

QActionGroupcutActionGroup
QPopupMenueditMenu
QPopupMenufileMenu
QPopupMenuhelpMenu
QActionm_aboutQt
QActionm_createNTuple
QActionm_cut1
QActionm_cut2
QActionm_cut3
QActionm_editClearAction
QActionm_editCopyAction
QActionm_editCutAction
QActionm_editDeleteAction
QActionm_editPasteAction
QActionm_editReTileAction
QActionm_editReTilePage
QActionm_editSelectAllAction
QActionm_editUndoAction
QActionm_enlarge
QActionm_exportTextTuple
QActionm_fileBrowse
QActionm_fileCloseAction
QActionm_fileExit
QActionm_fileNewAction
QActionm_fileOpen
QActionm_filePrint
QActionm_fileSaveAction
QActionm_fileSaveAllAction
QActionm_fileSaveAllAsAction
QActionm_fileSaveAsAction
QActionm_fileSaveSelected
QActionm_group
QActionm_helpAboutAction
QActionm_helpHelp
QActionm_nextView
QActionm_pick
QActionm_previousView
QActionGroupm_recent_files
QActionm_set_canvas
QActionGroupm_set_fitter
QActionm_set_printer
QActionm_settingDefaultDock
QActionm_settingsFontsAction
QActionm_showPickTableAction
QActionm_showPlotTableAction
QActionm_ungroup
QActionm_viewInspectorAction
QActionm_viewLockAction
QActionm_viewUnlockAction
QActionm_viewzoomreset
QActionm_zoomIn
QActionm_zoomMode
QActionm_zoomOut
QMenuBarmenubar
QPopupMenuPopupMenu
QPopupMenuPopupMenu_2
QToolBarToolbar
QToolBartoolBar
QToolBarToolbar_2
QToolBarToolbar_4

Protected Slots

virtual void fileBrowse ()
 Browse a document file, without opening a window for it.
virtual void fileExit ()
 Responds to the Quit item in the File menu.
virtual void fileOpen ()
 Opens an existing file.
virtual void languageChange ()
void viewRemoveEmpty ()

Protected Member Functions

virtual void aboutQt ()
 Brings up Qt's about message box.
virtual void closeEvent (QCloseEvent *e)
 Informs the application object that is window is about to close.
virtual void defaultToolbar ()
 Set the toolbar to default position.
virtual void editClear ()
 Responds to "Clear" menu item.
virtual void editCopy ()
virtual void editCut ()
 Removes selected items from canvas and add them to the pasteboard.
virtual void editDelete ()
 Removes selected items from canvas without copying them to the pasteboard.
virtual void editPaste ()
virtual void editReTile ()
 Re tiles the entire document.
virtual void editReTilePage ()
 Re tiles only the current page.
virtual void editSelectAll ()
 Sets all QCanvasItem objects to selected.
virtual void editUndo ()
 Responds to the undo action.
virtual void fileCreateNTuple ()
 Create a new NTuple from selected cut and column.
virtual void fileExportTextTuple ()
virtual void filePrint ()
 Prints the canvas to a Postscript file.
virtual void fileSaveAll ()
 Saves the canvas document and any NTuple that were not read from or written to a file.
virtual void fileSaveAllAs ()
 Saves the canvas document and its NTuple.
virtual void groupView ()
 Group the views.
virtual void helpAbout ()
 Brings up standard window showing version, authors, etc.
virtual void helpHelp ()
 Brings up a QAssistant client.
virtual void hideEvent (QHideEvent *e)
 Informs the application object that the window has been hidden.
void nextView ()
 Switches View to the next view for the selected item on the canvas.
virtual void openRecentFile (QAction *)
 Responds to open recent file.
void previousView ()
 Switches View to the previous view for the selected item on the canvas.
virtual void resizeEvent (QResizeEvent *)
 Informs the Canvas to re-size as well.
virtual void setCutMode (QAction *)
 Sets the cut mode.
virtual void setFitter (QAction *)
 Responds to change in fitter settings.
virtual void settingCanvas ()
 Sets the canvas settings.
virtual void settingFonts ()
 Sets the font settings.
virtual void settingPrinter ()
 Sets the printer settings.
virtual void setZoomMode (bool on)
 Sets the zoom mode to true or false.
virtual void showEvent (QShowEvent *e)
 Informs the application object that the window has been shown.
virtual void ungroupView ()
 Ungroup the views.
virtual void viewAddPage ()
 Adds a page to the canvas.
virtual void viewLock ()
 Locks a canvas item.
virtual void viewShowInspector ()
 Shows the Inspector window.
virtual void viewShowPickTable ()
 Shows the pick table window.
virtual void viewShowPlotTable ()
 Shows the plot table.
virtual void viewUnlock ()
 Unlocks a canvas item.
virtual void viewZoomIn ()
 Enlarges the view of the canvas.
virtual void viewZoomOut ()
 Reduces the view of the canvas.
virtual void viewZoomReset ()
 Returns the view of the canvas to normal.
virtual void windowActivationChange (bool oldActive)
 Informs the application object if this window has become the active one.

Private Member Functions

bool areDataSourcesSaved ()
 Returns true if all the data sources used by the document have been saved to or read from a file.
std::string getSaveDocFilename ()
 Returns the chosen file name from a save canvas dialog.
bool setFilenameFromDialog ()
 Sets the file name of document.
void setTitleFileName (const std::string &name)
 Sets the file name component of the window's title.

Private Attributes

bool m_allow_close
 A flag set to true to allow the window to close without prompting the user.
CanvasViewm_browsed_canvas
 The CanvasView object that is being browsed.
CanvasViewm_canvas_view
 The CanvasView object which is the central widget.
QString m_changed
 The changed status part of the window title.
QtFileDialogm_file_dialog
 The open file dialog for this window.
std::string m_filename
 The file name part of the window title.
bool m_filenameExists
 True if filename has been assigned, false if not.
bool m_hasChanged
 The current changed status.
bool m_inhibit_close
 A flag set to true if the CanvasWindow should not accept a close event.
QString m_prefix
 The prefix part of the window title.
XmlControllerm_xml_controller
 The controller object capable of serializing the canvas contents as XML and serializing them.

Static Private Attributes

static PlotTables_plot_table = 0
 The singleton instance of PlotTable.

Constructor & Destructor Documentation

CanvasWindow ( QWidget parent = 0,
const char *  name = 0,
Qt::WFlags  fl = Qt::WType_TopLevel 
)

constructor.

The arguments are defined by the inherited Qt QMainWindow class

Todo:
This is the only place where know we are using Qt XML support. It would be abstracted to a factory. Should also be in the CanvasView and not this class so it could be used by other windows.

Definition at line 71 of file CanvasWindow.cxx.

References WindowController::instance(), QtXMLController::instance(), CanvasWindow::m_canvas_view, CanvasWindow::m_file_dialog, CanvasWindowBase::m_recent_files, CanvasWindowBase::m_set_fitter, CanvasWindow::m_xml_controller, WindowController::newWindow(), CanvasWindowBase::PopupMenu, CanvasWindow::setCaption(), and QMainWindow::setCentralWidget().

Referenced by CanvasWindow::fileNew(), and CanvasWindow::fileOpen().

CanvasWindow ( const CanvasWindow  ) 

A copy constructor that does nothing except keep boost.python happy.

Without it, boost.python interface wouldn't compile because QMainWindow copy constructor is private.

Todo:
Probably should remove this method or make it private.

Definition at line 129 of file CanvasWindow.cxx.

~CanvasWindow (  )  [virtual]

Definition at line 135 of file CanvasWindow.cxx.

References QCanvasView::canvas(), and CanvasWindow::m_canvas_view.


Member Function Documentation

void aboutQt (  )  [protected, virtual]

Brings up Qt's about message box.

Implements CanvasWindowBase.

Definition at line 1019 of file CanvasWindow.cxx.

References QMessageBox::aboutQt().

void addDisplay ( PlotterBase plotter  ) 

Adds a new plot to the canvas and selects it.

Definition at line 1077 of file CanvasWindow.cxx.

References CanvasView::addPlotDisplay(), and CanvasWindow::m_canvas_view.

Referenced by CanvasWindow::customEvent().

void addFuncDisplay ( PlotterBase plotter,
const std::string &  name 
)

Adds function textual display to the canvas.

Definition at line 1067 of file CanvasWindow.cxx.

References CanvasView::addFuncDisplay(), and CanvasWindow::m_canvas_view.

Referenced by Inspector::summaryNew().

void addPlotDisplay ( PlotterBase plotter,
bool  select 
)

Adds a new plot display to the canvas.

Adds a new plot display to the canvas and puts it in selected state if select is true.

Definition at line 1072 of file CanvasWindow.cxx.

References CanvasView::addPlotDisplay(), and CanvasWindow::m_canvas_view.

Referenced by Inspector::newPlotButton_clicked().

void addTextDisplay ( PlotterBase plotter,
const std::string &  type,
const std::string &  text 
)

Adds a textual display to the canvas of type type.

This method is used when the text type requires additional text.

Definition at line 1048 of file CanvasWindow.cxx.

References CanvasView::addTextDisplay(), and CanvasWindow::m_canvas_view.

void addTextDisplay ( PlotterBase plotter,
const std::string &  type 
)

Adds a textual display to the canvas of type type.

Definition at line 1040 of file CanvasWindow.cxx.

References CanvasView::addTextDisplay(), and CanvasWindow::m_canvas_view.

Referenced by PyCanvas::addText(), and Inspector::summaryNew().

std::pair< double, double > addTextDisplayAt ( PlotterBase plotter,
const std::string &  type,
const std::string &  text,
double  xrel,
double  yrel 
)

Adds a text display at the relative position (xrel, yrel) in the selected item's coordinates.

This method returns the relative coordinates of the lower left corner as a pair of doubles.

Definition at line 1057 of file CanvasWindow.cxx.

References CanvasView::addTextDisplayAt(), and CanvasWindow::m_canvas_view.

Referenced by PyCanvas::addTextAt(), and PyCanvas::addTextAtAbs().

bool allowClose (  ) 

If document has changed and not saved, opens a dialog box for user to choose to save, discard or cancel.

Otherwise, return true. Intended to be used for closeEvent.

Todo:
bring the window up front before showing message box. Just doing a setActiveWindow() does work.

Definition at line 227 of file CanvasWindow.cxx.

References CanvasWindow::fileSave(), QMessageBox::information(), CanvasWindow::m_allow_close, CanvasWindow::m_canvas_view, CanvasWindow::m_filename, and CanvasWindow::m_hasChanged.

Referenced by CanvasWindow::closeEvent(), and WindowController::okToQuit().

bool areDataSourcesSaved (  )  [private]

Returns true if all the data sources used by the document have been saved to or read from a file.

If any data sources are only in memory, then inform the user with dialog and return false.

Definition at line 687 of file CanvasWindow.cxx.

References XmlController::areDataSourcesSaved(), QMessageBox::critical(), CanvasWindow::m_canvas_view, CanvasWindowBase::m_exportTextTuple, CanvasWindowBase::m_fileSaveAllAction, CanvasWindow::m_xml_controller, QAction::menuText(), CanvasView::views(), and CanvasWindow::views().

Referenced by CanvasWindow::fileSave(), and CanvasWindow::fileSaveAs().

void autosaveSettings (  ) 

Automatically save dock windows and recently opened files.

This method is called when choosing exit from menu or closing the window.

Definition at line 1380 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view.

Referenced by WindowController::aboutToClose(), and CanvasWindow::fileExit().

void clear (  ) 

Removes all items from the canvas.

See also:
editClear()

Definition at line 670 of file CanvasWindow.cxx.

References CanvasView::clear(), and CanvasWindow::m_canvas_view.

Referenced by CanvasWindow::editClear().

void closeEvent ( QCloseEvent e  )  [protected, virtual]

Informs the application object that is window is about to close.

Definition at line 277 of file CanvasWindow.cxx.

References QCloseEvent::accept(), CanvasWindow::allowClose(), QCloseEvent::ignore(), QMessageBox::information(), WindowController::instance(), CanvasWindow::m_allow_close, CanvasWindow::m_canvas_view, and CanvasWindow::m_inhibit_close.

bool closeNoPrompt (  )  [virtual]

Closes the window.

If no_prompt is true, the user will not be prompted, otherwise the user gets a dialog with which he can cancel the close operation.

Definition at line 270 of file CanvasWindow.cxx.

References QWidget::close(), and CanvasWindow::m_allow_close.

void customEvent ( QCustomEvent event  )  [virtual]

Responds to QCustomEvents.

Responds to SaveAsImageEvent custom events. All others are ignored.

Definition at line 160 of file CanvasWindow.cxx.

References CanvasWindow::addDisplay(), PlotTableEvent::Close, PlotTableEvent::Copy, CanvasWindow::m_browsed_canvas, CanvasWindow::m_canvas_view, CanvasWindow::s_plot_table, CanvasWindow::savePlotAsImage(), CanvasWindow::setCaption(), CanvasWindow::setChanged(), and num_util::type().

void defaultToolbar (  )  [protected, virtual]

Set the toolbar to default position.

Implements CanvasWindowBase.

Definition at line 3126 of file CanvasView.cxx.

References QMainWindow::lineUpDockWindows(), QMainWindow::moveDockWindow(), CanvasWindowBase::Toolbar, CanvasWindowBase::toolBar, CanvasWindowBase::Toolbar_2, and CanvasWindowBase::Toolbar_4.

void editClear (  )  [protected, virtual]

Responds to "Clear" menu item.

Prompts the user with a warning dialog, then removes all canvas items or not depending on user response.

See also:
clear()

Implements CanvasWindowBase.

Definition at line 430 of file CanvasWindow.cxx.

References QString::append(), CanvasWindow::clear(), WindowController::instance(), CanvasWindow::updateActions(), and QMessageBox::warning().

void editCopy (  )  [protected, virtual]

Implements CanvasWindowBase.

Definition at line 420 of file CanvasWindow.cxx.

References CanvasView::copySelectedToPasteboard(), WindowController::instance(), CanvasWindow::m_canvas_view, and CanvasWindow::updateActions().

void editCut (  )  [protected, virtual]

Removes selected items from canvas and add them to the pasteboard.

Implements CanvasWindowBase.

Definition at line 448 of file CanvasWindow.cxx.

References CanvasView::deleteSelected(), WindowController::instance(), CanvasWindow::m_canvas_view, and CanvasWindow::updateActions().

void editDelete (  )  [protected, virtual]

Removes selected items from canvas without copying them to the pasteboard.

Implements CanvasWindowBase.

Definition at line 456 of file CanvasWindow.cxx.

References CanvasView::deleteSelected(), WindowController::instance(), CanvasWindow::m_canvas_view, and CanvasWindow::updateActions().

void editPaste (  )  [protected, virtual]

Implements CanvasWindowBase.

Definition at line 487 of file CanvasWindow.cxx.

References CanvasView::copyFromPasteboard(), WindowController::instance(), CanvasWindow::m_canvas_view, and CanvasWindow::updateActions().

void editReTile (  )  [protected, virtual]

Re tiles the entire document.

Implements CanvasWindowBase.

Definition at line 466 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view, and CanvasView::reTile().

void editReTilePage (  )  [protected, virtual]

Re tiles only the current page.

Implements CanvasWindowBase.

Definition at line 473 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view, and CanvasView::reTilePage().

void editSelectAll (  )  [protected, virtual]

Sets all QCanvasItem objects to selected.

Implements CanvasWindowBase.

Definition at line 496 of file CanvasWindow.cxx.

References WindowController::instance(), CanvasWindow::m_canvas_view, FigureEditor::setAllSelected(), and CanvasWindow::updateActions().

void editUndo (  )  [protected, virtual]

Responds to the undo action.

Implements CanvasWindowBase.

Definition at line 480 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view, CanvasView::notifyObservers(), and CanvasView::restoreFromSelectCopy().

void fileBrowse (  )  [protected, virtual, slot]

Browse a document file, without opening a window for it.

Implements CanvasWindowBase.

Definition at line 521 of file CanvasWindow.cxx.

References QtFileDialog::createBrowseFilter(), QFileDialog::getOpenFileName(), CanvasWindow::initFromFile(), QtFileDialog::isDocSuffix(), QString::latin1(), CanvasWindow::m_browsed_canvas, CanvasWindow::s_plot_table, and QString::stripWhiteSpace().

void fileCreateNTuple (  )  [protected, virtual]

Create a new NTuple from selected cut and column.

Implements CanvasWindowBase.

Definition at line 939 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view.

void fileExit (  )  [protected, virtual, slot]

Responds to the Quit item in the File menu.

Implements CanvasWindowBase.

Definition at line 946 of file CanvasWindow.cxx.

References CanvasWindow::autosaveSettings(), and WindowController::instance().

void fileExportTextTuple (  )  [protected, virtual]

Implements CanvasWindowBase.

Definition at line 880 of file CanvasWindow.cxx.

References QString::append(), QMessageBox::critical(), QtFileDialog::getExportTupleFilename(), QtFileDialog::isFitsFile(), QtFileDialog::isFitsSuffix(), QtFileDialog::isTextSuffix(), QtFileDialog::isZippedFitsSuffix(), CanvasWindow::m_canvas_view, and CanvasWindow::m_file_dialog.

void fileNew (  )  [virtual]

Creates a new document CanvasWindow.

Implements CanvasWindowBase.

Definition at line 506 of file CanvasWindow.cxx.

References CanvasWindow::CanvasWindow(), WindowController::createInspector(), WindowController::instance(), and CanvasWindow::setCaption().

Referenced by hippodraw::Python::export_CanvasWindow().

void fileOpen (  )  [protected, virtual, slot]

Opens an existing file.

Opens an existing document or data file after prompting the user for the document's file name and/or type.

Implements CanvasWindowBase.

Definition at line 562 of file CanvasWindow.cxx.

References CanvasWindow::CanvasWindow(), WindowController::createInspector(), QtFileDialog::createOpenFilter(), QMessageBox::critical(), QFileDialog::getOpenFileName(), CanvasWindow::initFromFile(), WindowController::instance(), QtFileDialog::isDocSuffix(), QtFileDialog::isFitsFile(), QtFileDialog::isFitsSuffix(), QtFileDialog::isRootSuffix(), QtFileDialog::isTextSuffix(), QString::latin1(), CanvasWindow::m_canvas_view, CanvasWindow::m_file_dialog, CanvasWindowBase::m_recent_files, CanvasWindow::setChanged(), and QString::stripWhiteSpace().

void filePrint (  )  [protected, virtual]

Prints the canvas to a Postscript file.

Prints the canvas to a PostScript file.

Todo:
Add the `.ps' subscript to the file name if missing.
Todo:
Add the `.ps' subscript to the file name if missing.

Implements CanvasWindowBase.

Definition at line 415 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view, and CanvasView::print().

void fileSave (  )  [virtual]

Saves the document.

If the document already corresponds to a saved document, prompts the user with a warning dialog before over writing the file. If no file name has been assigned, then invokes the fileSaveAs() member function.

Implements CanvasWindowBase.

Definition at line 719 of file CanvasWindow.cxx.

References QString::append(), CanvasWindow::areDataSourcesSaved(), CanvasWindow::fileSaveAs(), CanvasWindow::m_filename, CanvasWindow::m_filenameExists, CanvasWindow::m_hasChanged, CanvasWindow::saveAs(), and QMessageBox::warning().

Referenced by CanvasWindow::allowClose().

void fileSaveAll (  )  [protected, virtual]

Saves the canvas document and any NTuple that were not read from or written to a file.

The NTuple objects are saved in the same directory as the canvas document. Their name becomes just the file name with index number with the suffix ".tnt". The path is striped from the name.

Implements CanvasWindowBase.

Definition at line 816 of file CanvasWindow.cxx.

References CanvasWindow::fileSaveAllAs(), CanvasWindow::m_filename, CanvasWindow::m_filenameExists, and CanvasWindow::saveAllAs().

void fileSaveAllAs (  )  [protected, virtual]

Saves the canvas document and its NTuple.

This function is similar to fileSaveAll(), but it always prompts the user for a filename.

Implements CanvasWindowBase.

Definition at line 827 of file CanvasWindow.cxx.

References CanvasWindow::m_filename, CanvasWindow::saveAllAs(), and CanvasWindow::setFilenameFromDialog().

Referenced by CanvasWindow::fileSaveAll().

void fileSaveAs (  )  [virtual]

Saves the document after display a file dialog to the user.

Implements CanvasWindowBase.

Definition at line 802 of file CanvasWindow.cxx.

References CanvasWindow::areDataSourcesSaved(), CanvasWindow::m_filename, CanvasWindow::saveAs(), and CanvasWindow::setFilenameFromDialog().

Referenced by CanvasWindow::fileSave().

void fileSaveSelectedImages ( const std::string &  filename  )  [virtual]

Saves the selected ViewBase objects as an image file with the given filename.

Definition at line 855 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view, and CanvasView::saveSelectedImages().

void fileSaveSelectedImages ( void   )  [virtual]

Saves the selected ViewBase object as an image file.

Implements CanvasWindowBase.

Definition at line 850 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view, and CanvasView::saveSelectedImages().

Referenced by PyCanvas::saveSelectedImages().

void fillPlotterList ( std::vector< PlotterBase * > &  plotter_list  ) 

Clears and fills plotter_list with all the PlotterBase objects on the canvas.

Definition at line 1105 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view.

const QString & getAppKey (  )  const

Returns a reference the application's QSettings key.

Definition at line 1272 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view.

CanvasView * getCanvasView (  ) 

Returns the CanvasView object.

Definition at line 873 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view.

Referenced by WindowController::newWindow().

NTuple * getPickTable ( const PlotterBase plotter  )  const

Gets the pick table of a plotter.

Definition at line 1315 of file CanvasWindow.cxx.

References CanvasWindow::getPickTable(), and CanvasWindow::m_canvas_view.

NTuple * getPickTable (  )  const

Gets the pick table the selected plotter.

Definition at line 1308 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view.

Referenced by PyCanvas::getPickTable(), CanvasWindow::getPickTable(), and PyCanvas::getSelPickTable().

std::string getSaveDocFilename (  )  [private]

Returns the chosen file name from a save canvas dialog.

Definition at line 748 of file CanvasWindow.cxx.

References QFileInfo::absFilePath(), QtFileDialog::createDocumentFilter(), QString::endsWith(), QFileInfo::exists(), QtFileDialog::getDocSuffix(), QFileDialog::getSaveFileName(), QString::latin1(), and QMessageBox::warning().

Referenced by CanvasWindow::setFilenameFromDialog().

QtView * getViewFor ( const PlotterBase plotter  )  const

Returns the QtView object that is the Observer of the plotter.

Definition at line 1112 of file CanvasWindow.cxx.

References CanvasView::getViewFor(), and CanvasWindow::m_canvas_view.

void groupView (  )  [protected, virtual]

Group the views.

Implements CanvasWindowBase.

Definition at line 1322 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view, and CanvasWindow::updateActions().

void helpAbout (  )  [protected, virtual]

Brings up standard window showing version, authors, etc.

Bug:
Mac only. About menu when launch with .app does not have the same case as the application claims to be.

Implements CanvasWindowBase.

Definition at line 993 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view.

void helpHelp (  )  [protected, virtual]

Brings up a QAssistant client.

Implements CanvasWindowBase.

Definition at line 1000 of file CanvasWindow.cxx.

References QMessageBox::information(), WindowController::instance(), and CanvasWindow::m_canvas_view.

void hideEvent ( QHideEvent e  )  [protected, virtual]

Informs the application object that the window has been hidden.

Definition at line 326 of file CanvasWindow.cxx.

References WindowController::instance().

void inhibitClose ( bool  yes = true  ) 

If yes is true, sets a flag so that this object will not accept close events.

Definition at line 336 of file CanvasWindow.cxx.

References CanvasWindow::m_inhibit_close.

Referenced by WindowController::aboutToClose(), and WindowController::newWindow().

void initFromFile ( const std::string &  filename  ) 

Initializes this object from contents of file.

Bug:
@@@ After initializing from file, the Window appears and responds like it has been changed.

Definition at line 659 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view, CanvasWindow::setChanged(), and CanvasWindow::setTitleFileName().

Referenced by CanvasWindow::fileBrowse(), and CanvasWindow::fileOpen().

void languageChange (  )  [protected, virtual, slot, inherited]

Definition at line 1121 of file CanvasWindowBase.cpp.

References CanvasWindowBase::cutActionGroup, CanvasWindowBase::m_aboutQt, CanvasWindowBase::m_createNTuple, CanvasWindowBase::m_cut1, CanvasWindowBase::m_cut2, CanvasWindowBase::m_cut3, CanvasWindowBase::m_editClearAction, CanvasWindowBase::m_editCopyAction, CanvasWindowBase::m_editCutAction, CanvasWindowBase::m_editDeleteAction, CanvasWindowBase::m_editPasteAction, CanvasWindowBase::m_editReTileAction, CanvasWindowBase::m_editReTilePage, CanvasWindowBase::m_editSelectAllAction, CanvasWindowBase::m_editUndoAction, CanvasWindowBase::m_enlarge, CanvasWindowBase::m_exportTextTuple, CanvasWindowBase::m_fileBrowse, CanvasWindowBase::m_fileCloseAction, CanvasWindowBase::m_fileExit, CanvasWindowBase::m_fileNewAction, CanvasWindowBase::m_fileOpen, CanvasWindowBase::m_filePrint, CanvasWindowBase::m_fileSaveAction, CanvasWindowBase::m_fileSaveAllAction, CanvasWindowBase::m_fileSaveAllAsAction, CanvasWindowBase::m_fileSaveAsAction, CanvasWindowBase::m_fileSaveSelected, CanvasWindowBase::m_group, CanvasWindowBase::m_helpAboutAction, CanvasWindowBase::m_helpHelp, CanvasWindowBase::m_nextView, CanvasWindowBase::m_pick, CanvasWindowBase::m_previousView, CanvasWindowBase::m_recent_files, CanvasWindowBase::m_set_canvas, CanvasWindowBase::m_set_fitter, CanvasWindowBase::m_set_printer, CanvasWindowBase::m_settingDefaultDock, CanvasWindowBase::m_settingsFontsAction, CanvasWindowBase::m_showPickTableAction, CanvasWindowBase::m_showPlotTableAction, CanvasWindowBase::m_ungroup, CanvasWindowBase::m_viewInspectorAction, CanvasWindowBase::m_viewLockAction, CanvasWindowBase::m_viewUnlockAction, CanvasWindowBase::m_viewzoomreset, CanvasWindowBase::m_zoomIn, CanvasWindowBase::m_zoomMode, CanvasWindowBase::m_zoomOut, CanvasWindowBase::menubar, QAction::setAccel(), QToolBar::setLabel(), QAction::setMenuText(), QAction::setStatusTip(), QAction::setText(), QAction::setToolTip(), QAction::setWhatsThis(), CanvasWindowBase::Toolbar, CanvasWindowBase::toolBar, CanvasWindowBase::Toolbar_2, and CanvasWindowBase::Toolbar_4.

Referenced by CanvasWindowBase::CanvasWindowBase().

void menubar_activated (  )  [virtual, slot, inherited]

Definition at line 1295 of file CanvasWindowBase.cpp.

const std::vector< double > & mouseEventData (  ) 

Retrieve a vector (x, y, z) points from the next mouse event.

Definition at line 1222 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view, and CanvasView::mouseEventData().

Referenced by PyCanvas::mouseData().

void nextView (  )  [protected, virtual]

Switches View to the next view for the selected item on the canvas.

Implements CanvasWindowBase.

Definition at line 1199 of file CanvasWindow.cxx.

References QCanvasView::canvas(), PlotterBase::getCurrentRangeSaved(), CanvasWindow::m_canvas_view, CanvasWindow::selectedPlotter(), and CanvasView::setCurrentRange().

Referenced by CanvasWindow::previousView().

void openRecentFile ( QAction action  )  [protected, virtual]

Responds to open recent file.

Implements CanvasWindowBase.

Definition at line 1338 of file CanvasWindow.cxx.

References QtFileDialog::isFitsSuffix(), QtFileDialog::isRootSuffix(), QtFileDialog::isTextSuffix(), QString::latin1(), CanvasWindow::m_canvas_view, CanvasWindow::m_file_dialog, QtFileDialog::openFitsTuple(), QtFileDialog::openRootTuple(), and QtFileDialog::openTextTuple().

void previousView (  )  [protected, virtual]

Switches View to the previous view for the selected item on the canvas.

Implements CanvasWindowBase.

Definition at line 1184 of file CanvasWindow.cxx.

References PlotterBase::getCurrentRangeSaved(), CanvasWindow::m_canvas_view, CanvasWindow::nextView(), and CanvasWindow::selectedPlotter().

void print ( const std::string &  filename  ) 

Prints the view to Postscript file without prompting user.

Definition at line 1257 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view.

void removeDisplay ( PlotterBase plotter  ) 

Removes the plotter and its view from the canvas.

Todo:
This method should only be in the CanvasView.

Definition at line 1086 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view, and CanvasView::removeDisplay().

Referenced by PyCanvas::removeDisplay().

void resetFontSize (  )  [static]

Resets the font size to be no larger than 10.

Definition at line 148 of file CanvasWindow.cxx.

References QApplication::font(), QFont::pointSize(), QApplication::setFont(), QFont::setPointSize(), and num_util::size().

Referenced by QtApp::init().

void resizeEvent ( QResizeEvent e  )  [protected, virtual]

Informs the Canvas to re-size as well.

Definition at line 675 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view, QWidget::resizeEvent(), and FigureEditor::resizeEvent().

void saveAllAs ( const std::string &  filename  ) 

Saves the document along with its NTuple objects.

Requests:
Raise error dialog if saving doesn't work.

Definition at line 838 of file CanvasWindow.cxx.

References QtFileDialog::getDocSuffix(), QtFileDialog::getTextSuffix(), NTupleController::instance(), and CanvasWindow::saveAs().

Referenced by CanvasWindow::fileSaveAll(), and CanvasWindow::fileSaveAllAs().

void saveAs ( const std::string &  filename  ) 

Saves the document to the specified file.

Definition at line 862 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view, CanvasWindow::setCaption(), CanvasWindow::setChanged(), and CanvasWindow::setTitleFileName().

Referenced by CanvasWindow::fileSave(), CanvasWindow::fileSaveAs(), CanvasWindow::saveAllAs(), and PyCanvas::saveAs().

void saveAsImage ( const PlotterBase plotter,
const std::string &  filename 
)

Saves the plotter as image file.

The filename should have suffix appropriate for the image format desired. If no suffix is given, then a file dialog may be opened. If file exists, it will be over-written as this method is intended to be call from Python script. It locks and locks the application object so it maybe called from a non-GUI thread.

Definition at line 1160 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view, and CanvasWindow::savePlotAsImage().

void savePlotAsImage ( const PlotterBase plotter,
const std::string &  filename 
)

Saves the plotter as image file.

The filename should have suffix appropriate for the image format desired. If no suffix is given, then a file dialog may be opened. If file exists, it will be over-written as this method is intended to be call from Python script.

Attention:
Calling this method from a non GUI thread could be dangerous. It would be better to post a SaveAsImageEvent custom event to the CanvasWindow.

Definition at line 1151 of file CanvasWindow.cxx.

References QApplication::postEvent().

Referenced by CanvasWindow::customEvent(), and CanvasWindow::saveAsImage().

PlotterBase * selectedPlotter (  ) 

Returns the selected plotter.

Todo:
This method should go away or return null pointer if multiple plots are selected.

Definition at line 1093 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view, and CanvasView::selectedPlotter().

Referenced by PyCanvas::getCut(), PyCanvas::getDisplay(), CanvasWindow::nextView(), and CanvasWindow::previousView().

void setAddedSelected ( bool  yes  ) 

Sets to flag to make plots in their selected state when added to the canvas.

Definition at line 1287 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view.

void setAllowClose ( bool  yes = true  ) 

Sets the window to allowed to be closed by user without prompting.

Definition at line 219 of file CanvasWindow.cxx.

References CanvasWindow::m_allow_close.

void setAllSelected ( bool  flag = true  ) 

Select or deselect all views in the window.

Definition at line 1170 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view, and FigureEditor::setAllSelected().

void setCaption (  ) 

Sets the Windows title.

The windows title depends on an number of attributes. They are collected to set the title.

Definition at line 1024 of file CanvasWindow.cxx.

References CanvasWindow::m_changed, CanvasWindow::m_filename, CanvasWindow::m_prefix, and QWidget::setCaption().

Referenced by CanvasWindow::CanvasWindow(), CanvasWindow::customEvent(), CanvasWindow::fileNew(), CanvasWindow::saveAs(), CanvasWindow::setChanged(), and WindowController::setFirstWindow().

void setChanged ( bool  flag = true  ) 

Sets the changed flag.

If the changed status has already set to true and flag is true, this member function does nothing. Otherwise, updates the window's title bar to reflect the document's current status.

See also:
m_hasChanged.

Definition at line 341 of file CanvasWindow.cxx.

References WindowController::instance(), CanvasWindow::m_changed, CanvasWindow::m_hasChanged, CanvasWindow::setCaption(), and CanvasWindow::updateActions().

Referenced by CanvasWindow::customEvent(), CanvasWindow::fileOpen(), CanvasWindow::initFromFile(), and CanvasWindow::saveAs().

void setCutMode ( QAction action  )  [protected, virtual]

Sets the cut mode.

Implements CanvasWindowBase.

Definition at line 1294 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view, CanvasWindowBase::m_cut1, CanvasWindowBase::m_cut2, and CanvasWindowBase::m_cut3.

bool setFilenameFromDialog (  )  [private]

Sets the file name of document.

Sets the file name of the canvas document from a QtFileDialog with the user. Returns true if the user gave the dialog a file name. Returns false if the user canceled.

Definition at line 793 of file CanvasWindow.cxx.

References CanvasWindow::getSaveDocFilename(), CanvasWindow::m_filename, and CanvasWindow::m_filenameExists.

Referenced by CanvasWindow::fileSaveAllAs(), and CanvasWindow::fileSaveAs().

void setFitter ( QAction action  )  [protected, virtual]

Responds to change in fitter settings.

Implements CanvasWindowBase.

Definition at line 1279 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view.

void setIntervalEnabled ( bool  yes = true  ) 

Sets the display interval feature to enabled if yes is true, otherwise sets it to disabled.

Definition at line 1117 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view, and CanvasView::setIntervalEnabled().

void setPlotMatrix ( unsigned int  columns,
unsigned int  rows 
)

Sets the number of columns and rows of plots on each page.

Definition at line 1264 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view.

void setSelected ( QtView view  ) 

Select a specific view in the window.

Definition at line 1177 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view, and FigureEditor::setSelectedItem().

Referenced by PyCanvas::selectDisplay().

void settingCanvas (  )  [protected, virtual]

Sets the canvas settings.

Implements CanvasWindowBase.

Definition at line 1236 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view.

void settingFonts (  )  [protected, virtual]

Sets the font settings.

Implements CanvasWindowBase.

Definition at line 1243 of file CanvasWindow.cxx.

References QFontDialog::getFont(), and CanvasWindow::m_canvas_view.

void settingPrinter (  )  [protected, virtual]

Sets the printer settings.

Implements CanvasWindowBase.

Definition at line 1229 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view.

void setTitleFileName ( const std::string &  name  )  [private]

Sets the file name component of the window's title.

Definition at line 1032 of file CanvasWindow.cxx.

References CanvasWindow::m_filename, and CanvasWindow::m_filenameExists.

Referenced by CanvasWindow::initFromFile(), and CanvasWindow::saveAs().

void setZoomMode ( bool  on  )  [protected, virtual]

Sets the zoom mode to true or false.

Implements CanvasWindowBase.

Definition at line 1215 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view.

void showEvent ( QShowEvent e  )  [protected, virtual]

Informs the application object that the window has been shown.

Definition at line 331 of file CanvasWindow.cxx.

References WindowController::instance().

void ungroupView (  )  [protected, virtual]

Ungroup the views.

Implements CanvasWindowBase.

Definition at line 1330 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view, and CanvasWindow::updateActions().

void updateActions (  ) 

Update Action objects.

Sets enable status of QAction objects such as menu items and tool bar icons.

Definition at line 357 of file CanvasWindow.cxx.

References QtXMLController::instance(), CanvasWindow::m_canvas_view, CanvasWindowBase::m_editCopyAction, CanvasWindowBase::m_editCutAction, CanvasWindowBase::m_editDeleteAction, CanvasWindowBase::m_editPasteAction, CanvasWindowBase::m_editUndoAction, CanvasWindowBase::m_fileSaveSelected, CanvasWindowBase::m_group, CanvasWindowBase::m_ungroup, CanvasWindowBase::m_viewLockAction, CanvasWindowBase::m_viewUnlockAction, CanvasView::selectedViews(), QAction::setEnabled(), and CanvasWindow::views().

Referenced by CanvasWindow::editClear(), CanvasWindow::editCopy(), CanvasWindow::editCut(), CanvasWindow::editDelete(), CanvasWindow::editPaste(), CanvasWindow::editSelectAll(), CanvasWindow::groupView(), CanvasWindow::setChanged(), CanvasWindow::ungroupView(), WindowController::updateActions(), CanvasWindow::viewLock(), CanvasWindow::viewUnlock(), and CanvasWindow::windowActivationChange().

void viewAddPage (  )  [protected, virtual]

Adds a page to the canvas.

Implements CanvasWindowBase.

Definition at line 682 of file CanvasWindow.cxx.

References FigureEditor::addPage(), and CanvasWindow::m_canvas_view.

void viewLock ( void   )  [protected, virtual]

Locks a canvas item.

Locks a canvas item so it can not be moved or re-sized.

Implements CanvasWindowBase.

Definition at line 976 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view, FigureEditor::setLocked(), and CanvasWindow::updateActions().

void viewRemoveEmpty (  )  [protected, slot, inherited]

Definition at line 1290 of file CanvasWindowBase.cpp.

const vector< const ViewBase * > & views (  ) 

Returns the list of ViewBase objects on the canvas.

Definition at line 1098 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view, and CanvasView::views().

Referenced by CanvasWindow::areDataSourcesSaved(), PyCanvas::getDisplays(), and CanvasWindow::updateActions().

void viewShowInspector (  )  [protected, virtual]

Shows the Inspector window.

Implements CanvasWindowBase.

Definition at line 1124 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view.

void viewShowPickTable (  )  [protected, virtual]

Shows the pick table window.

Implements CanvasWindowBase.

Definition at line 1142 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view, CanvasWindowBase::m_pick, and CanvasView::viewShowPickTable().

void viewShowPlotTable (  )  [protected, virtual]

Shows the plot table.

Implements CanvasWindowBase.

Definition at line 1131 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view, CanvasWindow::s_plot_table, PlotTable::setCanvas(), and QDialog::show().

void viewUnlock ( void   )  [protected, virtual]

Unlocks a canvas item.

Unlocks a canvas item so it can be moved and re-sized.

Implements CanvasWindowBase.

Definition at line 984 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view, FigureEditor::setLocked(), and CanvasWindow::updateActions().

void viewZoomIn (  )  [protected, virtual]

Enlarges the view of the canvas.

Implements CanvasWindowBase.

Definition at line 957 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view, and FigureEditor::viewZoomIn().

void viewZoomOut (  )  [protected, virtual]

Reduces the view of the canvas.

Implements CanvasWindowBase.

Definition at line 962 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view, and FigureEditor::viewZoomOut().

void viewZoomReset (  )  [protected, virtual]

Returns the view of the canvas to normal.

Implements CanvasWindowBase.

Definition at line 969 of file CanvasWindow.cxx.

References CanvasWindow::m_canvas_view.

void windowActivationChange ( bool  oldActive  )  [protected, virtual]

Informs the application object if this window has become the active one.

Attention:
The implementation of this function informs the singleton instance of the application that this window has become the active one. Therefore, the implementation of the constructor must not cause this method to be called before the application object is full constructed.

Definition at line 203 of file CanvasWindow.cxx.

References WindowController::instance(), CanvasWindow::m_canvas_view, CanvasWindow::updateActions(), and QWidget::windowActivationChange().


Member Data Documentation

QActionGroup* cutActionGroup [inherited]

Definition at line 83 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), and CanvasWindowBase::languageChange().

QPopupMenu* editMenu [inherited]

Definition at line 36 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase().

QPopupMenu* fileMenu [inherited]

Definition at line 35 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase().

QPopupMenu* helpMenu [inherited]

Definition at line 39 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase().

QAction* m_aboutQt [inherited]

Definition at line 77 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), and CanvasWindowBase::languageChange().

bool m_allow_close [private]

A flag set to true to allow the window to close without prompting the user.

Definition at line 158 of file CanvasWindow.h.

Referenced by CanvasWindow::allowClose(), CanvasWindow::closeEvent(), CanvasWindow::closeNoPrompt(), and CanvasWindow::setAllowClose().

CanvasView* m_browsed_canvas [private]

The CanvasView object that is being browsed.

Definition at line 127 of file CanvasWindow.h.

Referenced by CanvasWindow::customEvent(), and CanvasWindow::fileBrowse().

CanvasView* m_canvas_view [private]

The CanvasView object which is the central widget.

Definition at line 123 of file CanvasWindow.h.

Referenced by CanvasWindow::addDisplay(), CanvasWindow::addFuncDisplay(), CanvasWindow::addPlotDisplay(), CanvasWindow::addTextDisplay(), CanvasWindow::addTextDisplayAt(), CanvasWindow::allowClose(), CanvasWindow::areDataSourcesSaved(), CanvasWindow::autosaveSettings(), CanvasWindow::CanvasWindow(), CanvasWindow::clear(), CanvasWindow::closeEvent(), CanvasWindow::customEvent(), CanvasWindow::editCopy(), CanvasWindow::editCut(), CanvasWindow::editDelete(), CanvasWindow::editPaste(), CanvasWindow::editReTile(), CanvasWindow::editReTilePage(), CanvasWindow::editSelectAll(), CanvasWindow::editUndo(), CanvasWindow::fileCreateNTuple(), CanvasWindow::fileExportTextTuple(), CanvasWindow::fileOpen(), CanvasWindow::filePrint(), CanvasWindow::fileSaveSelectedImages(), CanvasWindow::fillPlotterList(), CanvasWindow::getAppKey(), CanvasWindow::getCanvasView(), CanvasWindow::getPickTable(), CanvasWindow::getViewFor(), CanvasWindow::groupView(), CanvasWindow::helpAbout(), CanvasWindow::helpHelp(), CanvasWindow::initFromFile(), CanvasWindow::mouseEventData(), CanvasWindow::nextView(), CanvasWindow::openRecentFile(), CanvasWindow::previousView(), CanvasWindow::print(), CanvasWindow::removeDisplay(), CanvasWindow::resizeEvent(), CanvasWindow::saveAs(), CanvasWindow::saveAsImage(), CanvasWindow::selectedPlotter(), CanvasWindow::setAddedSelected(), CanvasWindow::setAllSelected(), CanvasWindow::setCutMode(), CanvasWindow::setFitter(), CanvasWindow::setIntervalEnabled(), CanvasWindow::setPlotMatrix(), CanvasWindow::setSelected(), CanvasWindow::settingCanvas(), CanvasWindow::settingFonts(), CanvasWindow::settingPrinter(), CanvasWindow::setZoomMode(), CanvasWindow::ungroupView(), CanvasWindow::updateActions(), CanvasWindow::viewAddPage(), CanvasWindow::viewLock(), CanvasWindow::views(), CanvasWindow::viewShowInspector(), CanvasWindow::viewShowPickTable(), CanvasWindow::viewShowPlotTable(), CanvasWindow::viewUnlock(), CanvasWindow::viewZoomIn(), CanvasWindow::viewZoomOut(), CanvasWindow::viewZoomReset(), CanvasWindow::windowActivationChange(), and CanvasWindow::~CanvasWindow().

QString m_changed [private]

The changed status part of the window title.

Definition at line 140 of file CanvasWindow.h.

Referenced by CanvasWindow::setCaption(), and CanvasWindow::setChanged().

QAction* m_createNTuple [inherited]

Definition at line 89 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), and CanvasWindowBase::languageChange().

QAction* m_cut1 [inherited]

Definition at line 84 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), CanvasWindowBase::languageChange(), and CanvasWindow::setCutMode().

QAction* m_cut2 [inherited]

Definition at line 85 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), CanvasWindowBase::languageChange(), and CanvasWindow::setCutMode().

QAction* m_cut3 [inherited]

Definition at line 86 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), CanvasWindowBase::languageChange(), and CanvasWindow::setCutMode().

QAction* m_editClearAction [inherited]

Definition at line 63 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), and CanvasWindowBase::languageChange().

QAction* m_editCopyAction [inherited]

Definition at line 49 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), CanvasWindowBase::languageChange(), and CanvasWindow::updateActions().

QAction* m_editCutAction [inherited]

Definition at line 48 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), CanvasWindowBase::languageChange(), and CanvasWindow::updateActions().

QAction* m_editDeleteAction [inherited]

Definition at line 75 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), CanvasWindowBase::languageChange(), and CanvasWindow::updateActions().

QAction* m_editPasteAction [inherited]

Definition at line 50 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), CanvasWindowBase::languageChange(), and CanvasWindow::updateActions().

QAction* m_editReTileAction [inherited]

Definition at line 66 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), and CanvasWindowBase::languageChange().

QAction* m_editReTilePage [inherited]

Definition at line 74 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), and CanvasWindowBase::languageChange().

QAction* m_editSelectAllAction [inherited]

Definition at line 65 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), and CanvasWindowBase::languageChange().

QAction* m_editUndoAction [inherited]

Definition at line 64 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), CanvasWindowBase::languageChange(), and CanvasWindow::updateActions().

QAction* m_enlarge [inherited]

Definition at line 53 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), and CanvasWindowBase::languageChange().

QAction* m_exportTextTuple [inherited]

Definition at line 58 of file CanvasWindowBase.h.

Referenced by CanvasWindow::areDataSourcesSaved(), CanvasWindowBase::CanvasWindowBase(), and CanvasWindowBase::languageChange().

QtFileDialog* m_file_dialog [private]

The open file dialog for this window.

Definition at line 131 of file CanvasWindow.h.

Referenced by CanvasWindow::CanvasWindow(), CanvasWindow::fileExportTextTuple(), CanvasWindow::fileOpen(), and CanvasWindow::openRecentFile().

QAction* m_fileBrowse [inherited]

Definition at line 78 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), and CanvasWindowBase::languageChange().

QAction* m_fileCloseAction [inherited]

Definition at line 57 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), and CanvasWindowBase::languageChange().

QAction* m_fileExit [inherited]

Definition at line 47 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), and CanvasWindowBase::languageChange().

std::string m_filename [private]

The file name part of the window title.

Definition at line 137 of file CanvasWindow.h.

Referenced by CanvasWindow::allowClose(), CanvasWindow::fileSave(), CanvasWindow::fileSaveAll(), CanvasWindow::fileSaveAllAs(), CanvasWindow::fileSaveAs(), CanvasWindow::setCaption(), CanvasWindow::setFilenameFromDialog(), and CanvasWindow::setTitleFileName().

bool m_filenameExists [private]

True if filename has been assigned, false if not.

Definition at line 161 of file CanvasWindow.h.

Referenced by CanvasWindow::fileSave(), CanvasWindow::fileSaveAll(), CanvasWindow::setFilenameFromDialog(), and CanvasWindow::setTitleFileName().

QAction* m_fileNewAction [inherited]

Definition at line 56 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), and CanvasWindowBase::languageChange().

QAction* m_fileOpen [inherited]

Definition at line 44 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), and CanvasWindowBase::languageChange().

QAction* m_filePrint [inherited]

Definition at line 52 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), and CanvasWindowBase::languageChange().

QAction* m_fileSaveAction [inherited]

Definition at line 45 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), and CanvasWindowBase::languageChange().

QAction* m_fileSaveAllAction [inherited]

Definition at line 60 of file CanvasWindowBase.h.

Referenced by CanvasWindow::areDataSourcesSaved(), CanvasWindowBase::CanvasWindowBase(), and CanvasWindowBase::languageChange().

QAction* m_fileSaveAllAsAction [inherited]

Definition at line 67 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), and CanvasWindowBase::languageChange().

QAction* m_fileSaveAsAction [inherited]

Definition at line 46 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), and CanvasWindowBase::languageChange().

QAction* m_fileSaveSelected [inherited]

Definition at line 59 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), CanvasWindowBase::languageChange(), and CanvasWindow::updateActions().

QAction* m_group [inherited]

Definition at line 90 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), CanvasWindowBase::languageChange(), and CanvasWindow::updateActions().

bool m_hasChanged [private]

The current changed status.

If true, the document has been changed since last saved or opened. If false the document has not been changed since saved or opened.

Definition at line 149 of file CanvasWindow.h.

Referenced by CanvasWindow::allowClose(), CanvasWindow::fileSave(), and CanvasWindow::setChanged().

QAction* m_helpAboutAction [inherited]

Definition at line 51 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), and CanvasWindowBase::languageChange().

QAction* m_helpHelp [inherited]

Definition at line 88 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), and CanvasWindowBase::languageChange().

bool m_inhibit_close [private]

A flag set to true if the CanvasWindow should not accept a close event.

Definition at line 153 of file CanvasWindow.h.

Referenced by CanvasWindow::closeEvent(), and CanvasWindow::inhibitClose().

QAction* m_nextView [inherited]

Definition at line 81 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), and CanvasWindowBase::languageChange().

QAction* m_pick [inherited]

Definition at line 87 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), CanvasWindowBase::languageChange(), and CanvasWindow::viewShowPickTable().

QString m_prefix [private]

The prefix part of the window title.

Definition at line 134 of file CanvasWindow.h.

Referenced by CanvasWindow::setCaption().

QAction* m_previousView [inherited]

Definition at line 80 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), and CanvasWindowBase::languageChange().

QActionGroup* m_recent_files [inherited]

Definition at line 92 of file CanvasWindowBase.h.

Referenced by CanvasWindow::CanvasWindow(), CanvasWindowBase::CanvasWindowBase(), CanvasWindow::fileOpen(), and CanvasWindowBase::languageChange().

QAction* m_set_canvas [inherited]

Definition at line 71 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), and CanvasWindowBase::languageChange().

QActionGroup* m_set_fitter [inherited]

Definition at line 82 of file CanvasWindowBase.h.

Referenced by CanvasWindow::CanvasWindow(), CanvasWindowBase::CanvasWindowBase(), and CanvasWindowBase::languageChange().

QAction* m_set_printer [inherited]

Definition at line 70 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), and CanvasWindowBase::languageChange().

QAction* m_settingDefaultDock [inherited]

Definition at line 93 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), and CanvasWindowBase::languageChange().

QAction* m_settingsFontsAction [inherited]

Definition at line 73 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), and CanvasWindowBase::languageChange().

QAction* m_showPickTableAction [inherited]

Definition at line 69 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), and CanvasWindowBase::languageChange().

QAction* m_showPlotTableAction [inherited]

Definition at line 68 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), and CanvasWindowBase::languageChange().

QAction* m_ungroup [inherited]

Definition at line 91 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), CanvasWindowBase::languageChange(), and CanvasWindow::updateActions().

QAction* m_viewInspectorAction [inherited]

Definition at line 76 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), and CanvasWindowBase::languageChange().

QAction* m_viewLockAction [inherited]

Definition at line 61 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), CanvasWindowBase::languageChange(), and CanvasWindow::updateActions().

QAction* m_viewUnlockAction [inherited]

Definition at line 62 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), CanvasWindowBase::languageChange(), and CanvasWindow::updateActions().

QAction* m_viewzoomreset [inherited]

Definition at line 72 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), and CanvasWindowBase::languageChange().

XmlController* m_xml_controller [private]

The controller object capable of serializing the canvas contents as XML and serializing them.

Definition at line 120 of file CanvasWindow.h.

Referenced by CanvasWindow::areDataSourcesSaved(), and CanvasWindow::CanvasWindow().

QAction* m_zoomIn [inherited]

Definition at line 54 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), and CanvasWindowBase::languageChange().

QAction* m_zoomMode [inherited]

Definition at line 79 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), and CanvasWindowBase::languageChange().

QAction* m_zoomOut [inherited]

Definition at line 55 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), and CanvasWindowBase::languageChange().

QMenuBar* menubar [inherited]

Definition at line 34 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), and CanvasWindowBase::languageChange().

QPopupMenu* PopupMenu [inherited]

Definition at line 38 of file CanvasWindowBase.h.

Referenced by CanvasWindow::CanvasWindow(), and CanvasWindowBase::CanvasWindowBase().

QPopupMenu* PopupMenu_2 [inherited]

Definition at line 37 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase().

PlotTable * s_plot_table = 0 [static, private]

The singleton instance of PlotTable.

Definition at line 144 of file CanvasWindow.h.

Referenced by CanvasWindow::customEvent(), CanvasWindow::fileBrowse(), and CanvasWindow::viewShowPlotTable().

QToolBar* Toolbar [inherited]

Definition at line 42 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), CanvasWindow::defaultToolbar(), and CanvasWindowBase::languageChange().

QToolBar* toolBar [inherited]

Definition at line 40 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), CanvasWindow::defaultToolbar(), and CanvasWindowBase::languageChange().

QToolBar* Toolbar_2 [inherited]

Definition at line 41 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), CanvasWindow::defaultToolbar(), and CanvasWindowBase::languageChange().

QToolBar* Toolbar_4 [inherited]

Definition at line 43 of file CanvasWindowBase.h.

Referenced by CanvasWindowBase::CanvasWindowBase(), CanvasWindow::defaultToolbar(), and CanvasWindowBase::languageChange().


The documentation for this class was generated from the following files:
Generated for HippoDraw Class Library by doxygen