labplot  2.8.2
About: LabPlot is an application for plotting and analysis of 2D and 3D functions and data. It is a complete rewrite of LabPlot1 and lacks in the first release a lot of features available in the predecessor. On the other hand, the GUI and the usability is more superior.
  Fossies Dox: labplot-2.8.2.tar.gz  ("unofficial" and yet experimental doxygen-generated source code documentation)  

AbstractAspect Class Referenceabstract

Base class of all persistent objects in a Project. More...

#include <AbstractAspect.h>

Inheritance diagram for AbstractAspect:
[legend]
Collaboration diagram for AbstractAspect:
[legend]

Public Types

enum class  ChildIndexFlag { IncludeHidden = 0x01 , Recursive = 0x02 , Compress = 0x04 }
 Flags which control numbering scheme of children. More...
 

Public Slots

bool setName (const QString &, bool autoUnique=true)
 AbstractAspect::setName sets the name of the abstract aspect. More...
 
void setComment (const QString &)
 
void remove ()
 Remove me from my parent's list of children. More...
 

Signals

void aspectDescriptionAboutToChange (const AbstractAspect *)
 Emitted before the name, comment or caption spec is changed. More...
 
void aspectDescriptionChanged (const AbstractAspect *)
 Emitted after the name, comment or caption spec have changed. More...
 
void aspectAboutToBeAdded (const AbstractAspect *parent, const AbstractAspect *before, const AbstractAspect *child)
 Emitted before a new child is inserted. More...
 
void aspectAdded (const AbstractAspect *)
 Emitted after a new Aspect has been added to the tree. More...
 
void aspectAboutToBeRemoved (const AbstractAspect *)
 Emitted before an aspect is removed from its parent. More...
 
void aspectRemoved (const AbstractAspect *parent, const AbstractAspect *before, const AbstractAspect *child)
 Emitted from the parent after removing a child. More...
 
void aspectHiddenAboutToChange (const AbstractAspect *)
 Emitted before the hidden attribute is changed. More...
 
void aspectHiddenChanged (const AbstractAspect *)
 Emitted after the hidden attribute has changed. More...
 
void statusInfo (const QString &)
 Emitted whenever some aspect in the tree wants to give status information to the user. More...
 
void renameRequested ()
 
void selected (const AbstractAspect *)
 
void deselected (const AbstractAspect *)
 
void childAspectSelectedInView (const AbstractAspect *)
 
void childAspectDeselectedInView (const AbstractAspect *)
 

Public Member Functions

 AbstractAspect (const QString &name, AspectType type)
 
 ~AbstractAspect () override
 
QString name () const
 
QString comment () const
 
void setCreationTime (const QDateTime &)
 
QDateTime creationTime () const
 
virtual Projectproject ()
 Return the Project this Aspect belongs to, or 0 if it is currently not part of one. More...
 
virtual QString path () const
 Return the path that leads from the top-most Aspect (usually a Project) to me. More...
 
void setHidden (bool)
 Set "hidden" property, i.e. whether to exclude this aspect from being shown in the explorer. More...
 
bool hidden () const
 
void setIsLoading (bool)
 
bool isLoading () const
 
virtual QIcon icon () const
 Return an icon to be used for decorating my views. More...
 
virtual QMenu * createContextMenu ()
 Return a new context menu. More...
 
AspectType type () const
 
bool inherits (AspectType type) const
 
AbstractAspectparentAspect () const
 Return my parent Aspect or 0 if I currently don't have one. More...
 
AbstractAspectparent (AspectType type) const
 In the parent-child hierarchy, return the first parent of type. More...
 
void setParentAspect (AbstractAspect *)
 
Folderfolder ()
 Return the folder the Aspect is contained in or 0 if there is none. More...
 
bool isDescendantOf (AbstractAspect *other)
 Return whether the there is a path upwards to the given aspect. More...
 
void addChild (AbstractAspect *)
 Add the given Aspect to my list of children. More...
 
void addChildFast (AbstractAspect *)
 Add the given Aspect to my list of children without any checks and without putting this step onto the undo-stack. More...
 
virtual void finalizeAdd ()
 
QVector< AbstractAspect * > children (AspectType type, ChildIndexFlags flags={}) const
 
void insertChildBefore (AbstractAspect *child, AbstractAspect *before)
 Insert the given Aspect at a specific position in my list of children. More...
 
void insertChildBeforeFast (AbstractAspect *child, AbstractAspect *before)
 Insert the given Aspect at a specific position in my list of children.without any checks and without putting this step onto the undo-stack. More...
 
void reparent (AbstractAspect *newParent, int newIndex=-1)
 Move a child to another parent aspect and transfer ownership. More...
 
void removeChild (AbstractAspect *)
 Remove the given Aspect from my list of children. More...
 
void removeAllChildren ()
 Remove all child Aspects. More...
 
virtual QVector< AbstractAspect * > dependsOn () const
 
virtual bool isDraggable () const
 
virtual QVector< AspectTypedropableOn () const
 
virtual void processDropEvent (const QVector< quintptr > &)
 
template<class T >
T * ancestor () const
 Return the closest ancestor of class T (or NULL if none found). More...
 
template<class T >
QVector< T * > children (ChildIndexFlags flags={}) const
 
template<class T >
T * child (int index, ChildIndexFlags flags={}) const
 
template<class T >
T * child (const QString &name) const
 Get child by name and class. More...
 
template<class T >
int childCount (ChildIndexFlags flags={}) const
 Return the number of child Aspects inheriting from given class. More...
 
template<class T >
int indexOfChild (const AbstractAspect *child, ChildIndexFlags flags={}) const
 Return (0 based) index of child in the list of children inheriting from class T. More...
 

Protected Member Functions

void info (const QString &text)
 Implementations should call this whenever status information should be given to the user. More...
 

Protected Attributes

const AspectType m_type
 

Private Member Functions

const QVector< AbstractAspect * > & children () const
 

Private Attributes

AbstractAspectPrivated
 

Friends

class AspectChildAddCmd
 
class AspectChildRemoveCmd
 
class AbstractAspectPrivate
 

undo related

void setSelected (bool)
 
void setUndoAware (bool)
 
virtual QUndoStack * undoStack () const
 Return the undo stack of the Project, or 0 if this Aspect is not part of a Project. More...
 
void exec (QUndoCommand *)
 Execute the given command, pushing it on the undoStack() if available. More...
 
void exec (QUndoCommand *command, const char *preChangeSignal, const char *postChangeSignal, QGenericArgument val0=QGenericArgument(), QGenericArgument val1=QGenericArgument(), QGenericArgument val2=QGenericArgument(), QGenericArgument val3=QGenericArgument())
 Execute command and arrange for signals to be sent before/after it is redone or undone. More...
 
void beginMacro (const QString &text)
 Begin an undo stack macro (series of commands) More...
 
void endMacro ()
 End the current undo stack macro. More...
 
QString uniqueNameFor (const QString &) const
 Make the specified name unique among my children by incrementing a trailing number. More...
 
void connectChild (AbstractAspect *)
 
virtual void childSelected (const AbstractAspect *)
 
virtual void childDeselected (const AbstractAspect *)
 

serialize/deserialize

virtual void save (QXmlStreamWriter *) const =0
 Save as XML. More...
 
virtual bool load (XmlStreamReader *, bool preview)=0
 Load from XML. More...
 
bool readBasicAttributes (XmlStreamReader *)
 Load name and creation time from XML. More...
 
void writeBasicAttributes (QXmlStreamWriter *) const
 Save name and creation time to XML. More...
 
void writeCommentElement (QXmlStreamWriter *) const
 Save the comment to XML. More...
 
bool readCommentElement (XmlStreamReader *)
 Load comment from an XML element. More...
 

Detailed Description

Base class of all persistent objects in a Project.

File : AbstractAspect.cpp

Project : LabPlot

Copyright : (C) 2007-2009 by Tilman Benkert (thzs@.nosp@m.gmx..nosp@m.net) Copyright : (C) 2007-2010 by Knut Franke (knut..nosp@m.fran.nosp@m.ke@gm.nosp@m.x.de) Copyright : (C) 2011-2016 by Alexander Semke (alexa.nosp@m.nder.nosp@m..semk.nosp@m.e@we.nosp@m.b.de) Description : Base class for all objects in a Project.

  • This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. *
  • This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. *
  • You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, * Boston, MA 02110-1301 USA *

Before going into the details, it's useful to understand the ideas behind the Aspect Framework.

Aspects organize themselves into trees, where a parent takes ownership of its children. Usually, though not necessarily, a Project instance will sit at the root of the tree (without a Project ancestor, project() will return 0 and undo does not work). Children are organized using addChild(), removeChild(), child(), indexOfChild() and childCount() on the parent's side as well as the equivalent convenience methods index() and remove() on the child's side. In contrast to the similar feature of QObject, Aspect trees are fully undo/redo aware and provide signals around object adding/removal.

AbstractAspect manages for every Aspect the properties name, comment, #captionSpec and creationTime. All of these translate into the caption() as described in the documentation of setCaptionSpec().

If an undoStack() can be found (usually it is managed by Project), changes to the properties as well as adding/removing children support multi-level undo/redo. In order to support undo/redo for problem-specific data in derived classes, make sure that all changes to your data are done by handing appropriate commands to exec().

Definition at line 112 of file AbstractAspect.h.

Member Enumeration Documentation

◆ ChildIndexFlag

Flags which control numbering scheme of children.

Enumerator
IncludeHidden 

Include aspects marked as "hidden" in numbering or listing children.

Recursive 

Recursively handle all descendents, not just immediate children.

Compress 

Remove all null pointers from the result list.

Definition at line 116 of file AbstractAspect.h.

Constructor & Destructor Documentation

◆ AbstractAspect()

AbstractAspect::AbstractAspect ( const QString &  name,
AspectType  type 
)

Definition at line 206 of file AbstractAspect.cpp.

◆ ~AbstractAspect()

AbstractAspect::~AbstractAspect ( )
override

Definition at line 210 of file AbstractAspect.cpp.

References d.

Member Function Documentation

◆ addChild()

void AbstractAspect::addChild ( AbstractAspect child)

Add the given Aspect to my list of children.

Definition at line 418 of file AbstractAspect.cpp.

References AspectChildAddCmd, beginMacro(), child(), d, endMacro(), exec(), i18n, info(), AbstractAspectPrivate::m_children, name(), and uniqueNameFor().

Referenced by MainWin::addAspectToProject(), CartesianPlot::addConvolutionCurve(), CartesianPlot::addCorrelationCurve(), CartesianPlot::addCurve(), DatapickerImageView::addCurve(), PlotDataDialog::addCurvesToPlots(), CartesianPlot::addCustomPoint(), CartesianPlot::addDataReductionCurve(), DatapickerCurve::addDatasheet(), CartesianPlot::addDifferentiationCurve(), CartesianPlot::addEquationCurve(), CartesianPlot::addFitCurve(), CartesianPlot::addFourierFilterCurve(), CartesianPlot::addFourierTransformCurve(), CartesianPlot::addHistogram(), CartesianPlot::addHorizontalAxis(), CartesianPlot::addImage(), CartesianPlot::addIntegrationCurve(), CartesianPlot::addInterpolationCurve(), CartesianPlot::addLegend(), WorkbookView::addMatrix(), WorksheetView::addNew(), Datapicker::addNewPoint(), CartesianPlot::addReferenceLine(), CartesianPlot::addSmoothCurve(), WorkbookView::addSpreadsheet(), CartesianPlot::addTextLabel(), CartesianPlot::addVerticalAxis(), DatapickerCurve::appendColumn(), Spreadsheet::copy(), Matrix::duplicate(), ProjectParser::importTo(), Datapicker::init(), Spreadsheet::init(), Axis::init(), CartesianPlot::init(), CartesianPlotLegend::init(), SpreadsheetView::insertColumnsLeft(), SpreadsheetView::insertColumnsRight(), CantorWorksheet::load(), Workbook::load(), Datapicker::load(), DatapickerCurve::load(), DatapickerImage::load(), LiveDataSource::load(), MQTTTopic::load(), XYConvolutionCurve::load(), XYCorrelationCurve::load(), XYDataReductionCurve::load(), XYDifferentiationCurve::load(), XYFitCurve::load(), XYFourierFilterCurve::load(), XYFourierTransformCurve::load(), XYIntegrationCurve::load(), XYInterpolationCurve::load(), XYSmoothCurve::load(), OriginProjectParser::loadWorksheet(), ProjectParser::moveFolder(), MainWin::newMatrix(), MainWin::newSpreadsheet(), MainWin::openProject(), SpreadsheetView::pasteIntoSelection(), PlotDataDialog::plot(), XYFitCurvePrivate::prepareResultColumns(), CartesianPlot::processDropEvent(), XYConvolutionCurvePrivate::recalculate(), XYCorrelationCurvePrivate::recalculate(), XYDataReductionCurvePrivate::recalculate(), XYDifferentiationCurvePrivate::recalculate(), XYFourierFilterCurvePrivate::recalculate(), XYFourierTransformCurvePrivate::recalculate(), XYIntegrationCurvePrivate::recalculate(), XYInterpolationCurvePrivate::recalculate(), XYSmoothCurvePrivate::recalculate(), Spreadsheet::resize(), CantorWorksheet::rowsInserted(), Column::setColumnMode(), and CartesianPlot::setType().

◆ addChildFast()

◆ ancestor()

template<class T >
template< class T > T * AbstractAspect::ancestor ( ) const
inline

Return the closest ancestor of class T (or NULL if none found).

Definition at line 169 of file AbstractAspect.h.

References parent(), and parentAspect().

Referenced by MainWin::addAspectToProject(), and Datapicker::childSelected().

◆ aspectAboutToBeAdded

void AbstractAspect::aspectAboutToBeAdded ( const AbstractAspect parent,
const AbstractAspect before,
const AbstractAspect child 
)
signal

◆ aspectAboutToBeRemoved

◆ aspectAdded

◆ aspectDescriptionAboutToChange

void AbstractAspect::aspectDescriptionAboutToChange ( const AbstractAspect aspect)
signal

Emitted before the name, comment or caption spec is changed.

Referenced by connectChild(), and AbstractFilter::input().

◆ aspectDescriptionChanged

◆ aspectHiddenAboutToChange

void AbstractAspect::aspectHiddenAboutToChange ( const AbstractAspect aspect)
signal

Emitted before the hidden attribute is changed.

Referenced by AspectTreeModel::AspectTreeModel(), and connectChild().

◆ aspectHiddenChanged

void AbstractAspect::aspectHiddenChanged ( const AbstractAspect aspect)
signal

Emitted after the hidden attribute has changed.

Referenced by AspectTreeModel::AspectTreeModel(), and connectChild().

◆ aspectRemoved

◆ beginMacro()

void AbstractAspect::beginMacro ( const QString &  text)

Begin an undo stack macro (series of commands)

Definition at line 763 of file AbstractAspect.cpp.

References d, AbstractAspectPrivate::m_undoAware, and undoStack().

Referenced by addChild(), Matrix::addColumns(), DatapickerImageView::addCurve(), CartesianPlot::addDataReductionCurve(), CartesianPlot::addDifferentiationCurve(), CartesianPlot::addFitCurve(), CartesianPlot::addFourierFilterCurve(), CartesianPlot::addIntegrationCurve(), CartesianPlot::addInterpolationCurve(), Datapicker::addNewPoint(), Matrix::addRows(), CartesianPlot::addSmoothCurve(), WorksheetDock::backgroundColorStyleChanged(), WorksheetView::cartesianPlotAddNew(), DatapickerImageView::changeSelectedItemsPosition(), Matrix::clear(), Spreadsheet::clear(), Spreadsheet::clearMasks(), MatrixView::clearSelectedCells(), SpreadsheetView::clearSelectedCells(), MatrixView::clearSelectedColumns(), SpreadsheetView::clearSelectedColumns(), MatrixView::clearSelectedRows(), SpreadsheetView::clearSelectedRows(), Matrix::copy(), Spreadsheet::copy(), MatrixView::cutSelection(), SpreadsheetView::cutSelection(), WorksheetView::deleteElement(), ProjectExplorer::deleteSelected(), DropValuesDialog::dropValues(), exec(), WorksheetElement::execMoveBehind(), WorksheetElement::execMoveInFrontOf(), SpreadsheetView::fillSelectedCellsWithConstValues(), SpreadsheetView::fillSelectedCellsWithRandomNumbers(), SpreadsheetView::fillSelectedCellsWithRowNumbers(), SpreadsheetView::fillWithRowNumbers(), MatrixFunctionDialog::generate(), EquidistantValuesDialog::generate(), FunctionValuesDialog::generate(), RandomValuesDialog::generate(), AddSubtractValueDialog::generateForColumns(), AddSubtractValueDialog::generateForMatrices(), ProjectParser::importTo(), insertChildBefore(), Spreadsheet::insertColumns(), SpreadsheetView::insertColumnsLeft(), SpreadsheetView::insertColumnsRight(), MatrixView::insertEmptyColumns(), MatrixView::insertEmptyRows(), AbstractColumn::insertRows(), Spreadsheet::insertRows(), SpreadsheetView::insertRowsAbove(), SpreadsheetView::insertRowsBelow(), AxisDock::loadConfigFromTemplate(), CartesianPlotDock::loadConfigFromTemplate(), CartesianPlotLegendDock::loadConfigFromTemplate(), CustomPointDock::loadConfigFromTemplate(), HistogramDock::loadConfigFromTemplate(), MatrixDock::loadConfigFromTemplate(), SpreadsheetDock::loadConfigFromTemplate(), WorksheetDock::loadConfigFromTemplate(), XYCurveDock::loadConfigFromTemplate(), SpreadsheetView::maskSelection(), DropValuesDialog::maskValues(), Spreadsheet::moveColumn(), SpreadsheetView::normalizeSelectedColumns(), MatrixView::pasteIntoSelection(), SpreadsheetView::pasteIntoSelection(), PlotDataDialog::plot(), SpreadsheetView::powerTransformSelectedColumns(), removeAllChildren(), removeChild(), Spreadsheet::removeColumns(), AbstractColumn::removeRows(), Spreadsheet::removeRows(), MatrixView::removeSelectedColumns(), SpreadsheetView::removeSelectedColumns(), MatrixView::removeSelectedRows(), SpreadsheetView::removeSelectedRows(), SpreadsheetView::reverseColumns(), Column::setColumnMode(), Matrix::setDimensions(), Worksheet::setPageRect(), SpreadsheetView::setSelectionAs(), Spreadsheet::sortColumns(), CustomPointDock::symbolBorderColorChanged(), CustomPointDock::symbolBorderStyleChanged(), CustomPointDock::symbolBorderWidthChanged(), CustomPointDock::symbolFillingColorChanged(), CustomPointDock::symbolFillingStyleChanged(), CustomPointDock::symbolOpacityChanged(), CustomPointDock::symbolRotationChanged(), CustomPointDock::symbolSizeChanged(), CustomPointDock::symbolStyleChanged(), SpreadsheetView::unmaskSelection(), and CustomPointDock::visibilityChanged().

◆ child() [1/2]

template<class T >
template< class T > T * AbstractAspect::child ( const QString &  name) const
inline

Get child by name and class.

Definition at line 205 of file AbstractAspect.h.

References child(), children(), and name().

◆ child() [2/2]

template<class T >
T* AbstractAspect::child ( int  index,
ChildIndexFlags  flags = {} 
) const
inline

◆ childAspectDeselectedInView

◆ childAspectSelectedInView

◆ childCount()

template<class T >
template< class T > int AbstractAspect::childCount ( ChildIndexFlags  flags = {}) const
inline

◆ childDeselected

void AbstractAspect::childDeselected ( const AbstractAspect aspect)
protectedvirtualslot

◆ children() [1/3]

◆ children() [2/3]

QVector< AbstractAspect * > AbstractAspect::children ( AspectType  type,
ChildIndexFlags  flags = {} 
) const

Definition at line 554 of file AbstractAspect.cpp.

References child(), children(), Compress, IncludeHidden, Recursive, and type().

Referenced by Datapicker::addNewPoint(), Column::addUsedInPlots(), FunctionValuesDialog::addVariable(), AspectTreeModel::aspectAdded(), Project::aspectAddedSlot(), Worksheet::aspectFromGraphicsItem(), WorksheetView::cartesianPlotAddNew(), WorksheetView::cartesianPlotMouseModeChanged(), WorksheetView::cartesianPlotNavigationChanged(), DatapickerImageView::changeSelectedItemsPosition(), Spreadsheet::copy(), Column::createContextMenu(), WorksheetElement::createContextMenu(), DatapickerView::DatapickerView(), Datapicker::handleAspectAdded(), WorksheetView::handleCartesianPlotActions(), DatapickerView::handleDescriptionChanged(), MainWin::handleSettingsChanges(), CartesianPlotPrivate::hoverLeaveEvent(), CartesianPlotPrivate::hoverMoveEvent(), ImportProjectDialog::importTo(), SpreadsheetView::init(), OriginProjectParser::load(), ProjectExplorer::load(), AspectTreeModel::modelIndexOfAspect(), ProjectParser::moveFolder(), MainWin::newLiveDataSourceActionTriggered(), PlotDataDialog::plot(), WorksheetView::plotAt(), PlotDataDialog::PlotDataDialog(), WorksheetElement::prepareMoveBehindMenu(), WorksheetElement::prepareMoveInFrontOfMenu(), PlotDataDialog::processColumns(), AspectChildRemoveCmd::redo(), SpreadsheetView::resizeHeader(), DatapickerCurvePrivate::retransform(), DatapickerImagePrivate::retransform(), CartesianPlotLegendPrivate::retransform(), CartesianPlotPrivate::retransformScales(), ProjectExplorer::save(), Datapicker::setChildSelectedInView(), FunctionValuesDialog::setColumns(), DatapickerImage::setPrinting(), CursorDock::setWorksheet(), MainWin::showPresenter(), SpreadsheetView::sortSpreadsheet(), DatapickerImagePrivate::updateFileName(), WorksheetPrivate::updateLayout(), WorksheetPrivate::updatePageRect(), DatapickerCurveWidget::updateSymbolWidgets(), CartesianPlotPrivate::wheelEvent(), WorkbookView::WorkbookView(), CartesianPlotPrivate::xRangeFormatChanged(), CartesianPlotPrivate::yRangeFormatChanged(), DatapickerView::~DatapickerView(), and WorkbookView::~WorkbookView().

◆ children() [3/3]

template<class T >
QVector<T*> AbstractAspect::children ( ChildIndexFlags  flags = {}) const
inline

Definition at line 180 of file AbstractAspect.h.

◆ childSelected

void AbstractAspect::childSelected ( const AbstractAspect aspect)
protectedvirtualslot

◆ comment()

QString AbstractAspect::comment ( ) const

Definition at line 251 of file AbstractAspect.cpp.

References d, and AbstractAspectPrivate::m_comment.

Referenced by AxisDock::axisDescriptionChanged(), ColumnDock::columnDescriptionChanged(), Spreadsheet::copy(), HistogramDock::curveDescriptionChanged(), XYConvolutionCurveDock::curveDescriptionChanged(), XYCorrelationCurveDock::curveDescriptionChanged(), XYCurveDock::curveDescriptionChanged(), XYDataReductionCurveDock::curveDescriptionChanged(), XYDifferentiationCurveDock::curveDescriptionChanged(), XYEquationCurveDock::curveDescriptionChanged(), XYFitCurveDock::curveDescriptionChanged(), XYFourierFilterCurveDock::curveDescriptionChanged(), XYFourierTransformCurveDock::curveDescriptionChanged(), XYIntegrationCurveDock::curveDescriptionChanged(), XYInterpolationCurveDock::curveDescriptionChanged(), XYSmoothCurveDock::curveDescriptionChanged(), DatapickerCurveWidget::curveDescriptionChanged(), Spreadsheet::finalizeImport(), SpreadsheetModel::headerData(), ImageDock::imageDescriptionChanged(), DatapickerImageWidget::imageDescriptionChanged(), XYCurveDock::initGeneralTab(), XYConvolutionCurveDock::initGeneralTab(), XYCorrelationCurveDock::initGeneralTab(), XYDataReductionCurveDock::initGeneralTab(), XYDifferentiationCurveDock::initGeneralTab(), XYEquationCurveDock::initGeneralTab(), XYFitCurveDock::initGeneralTab(), XYFourierFilterCurveDock::initGeneralTab(), XYFourierTransformCurveDock::initGeneralTab(), XYIntegrationCurveDock::initGeneralTab(), XYInterpolationCurveDock::initGeneralTab(), XYSmoothCurveDock::initGeneralTab(), CartesianPlotLegendDock::legendDescriptionChanged(), ReferenceLineDock::lineDescriptionChanged(), ProjectDock::loadConfig(), MatrixDock::matrixDescriptionChanged(), CartesianPlotDock::plotDescriptionChanged(), CustomPointDock::pointDescriptionChanged(), ProjectDock::projectDescriptionChanged(), AxisDock::setAxes(), CantorWorksheetDock::setCantorWorksheets(), ColumnDock::setColumns(), DatapickerCurveWidget::setCurves(), HistogramDock::setCurves(), DatapickerImageWidget::setImages(), ImageDock::setImages(), CartesianPlotLegendDock::setLegends(), MatrixDock::setMatrices(), CartesianPlotDock::setPlots(), CustomPointDock::setPoints(), ReferenceLineDock::setReferenceLines(), SpreadsheetDock::setSpreadsheets(), WorksheetDock::setWorksheets(), SpreadsheetDock::spreadsheetDescriptionChanged(), CantorWorksheetDock::worksheetDescriptionChanged(), WorksheetDock::worksheetDescriptionChanged(), FITSFilterPrivate::writeCHDU(), and writeCommentElement().

◆ connectChild()

◆ createContextMenu()

◆ creationTime()

QDateTime AbstractAspect::creationTime ( ) const

Definition at line 266 of file AbstractAspect.cpp.

References d, and AbstractAspectPrivate::m_creation_time.

Referenced by ProjectDock::setProject(), and writeBasicAttributes().

◆ dependsOn()

QVector< AbstractAspect * > AbstractAspect::dependsOn ( ) const
virtual

returns the list of all parent aspects (folders and sub-folders)

Reimplemented in CartesianPlot, and Worksheet.

Definition at line 585 of file AbstractAspect.cpp.

References dependsOn(), and parentAspect().

Referenced by dependsOn(), and Worksheet::dependsOn().

◆ deselected

void AbstractAspect::deselected ( const AbstractAspect )
signal

◆ dropableOn()

QVector< AspectType > AbstractAspect::dropableOn ( ) const
virtual

Reimplemented in AbstractPart, Column, and Folder.

Definition at line 597 of file AbstractAspect.cpp.

Referenced by ProjectExplorer::eventFilter().

◆ endMacro()

void AbstractAspect::endMacro ( )

End the current undo stack macro.

Definition at line 775 of file AbstractAspect.cpp.

References d, AbstractAspectPrivate::m_undoAware, and undoStack().

Referenced by addChild(), Matrix::addColumns(), DatapickerImageView::addCurve(), CartesianPlot::addDataReductionCurve(), CartesianPlot::addDifferentiationCurve(), CartesianPlot::addFitCurve(), CartesianPlot::addFourierFilterCurve(), CartesianPlot::addIntegrationCurve(), CartesianPlot::addInterpolationCurve(), Datapicker::addNewPoint(), Matrix::addRows(), CartesianPlot::addSmoothCurve(), WorksheetDock::backgroundColorStyleChanged(), WorksheetView::cartesianPlotAddNew(), DatapickerImageView::changeSelectedItemsPosition(), Matrix::clear(), Spreadsheet::clear(), Spreadsheet::clearMasks(), MatrixView::clearSelectedCells(), SpreadsheetView::clearSelectedCells(), MatrixView::clearSelectedColumns(), SpreadsheetView::clearSelectedColumns(), MatrixView::clearSelectedRows(), SpreadsheetView::clearSelectedRows(), Matrix::copy(), Spreadsheet::copy(), MatrixView::cutSelection(), SpreadsheetView::cutSelection(), WorksheetView::deleteElement(), ProjectExplorer::deleteSelected(), DropValuesDialog::dropValues(), exec(), WorksheetElement::execMoveBehind(), WorksheetElement::execMoveInFrontOf(), SpreadsheetView::fillSelectedCellsWithConstValues(), SpreadsheetView::fillSelectedCellsWithRandomNumbers(), SpreadsheetView::fillSelectedCellsWithRowNumbers(), SpreadsheetView::fillWithRowNumbers(), MatrixFunctionDialog::generate(), EquidistantValuesDialog::generate(), FunctionValuesDialog::generate(), RandomValuesDialog::generate(), AddSubtractValueDialog::generateForColumns(), AddSubtractValueDialog::generateForMatrices(), ProjectParser::importTo(), insertChildBefore(), Spreadsheet::insertColumns(), SpreadsheetView::insertColumnsLeft(), SpreadsheetView::insertColumnsRight(), MatrixView::insertEmptyColumns(), MatrixView::insertEmptyRows(), AbstractColumn::insertRows(), Spreadsheet::insertRows(), SpreadsheetView::insertRowsAbove(), SpreadsheetView::insertRowsBelow(), AxisDock::loadConfigFromTemplate(), CartesianPlotDock::loadConfigFromTemplate(), CartesianPlotLegendDock::loadConfigFromTemplate(), CustomPointDock::loadConfigFromTemplate(), HistogramDock::loadConfigFromTemplate(), MatrixDock::loadConfigFromTemplate(), SpreadsheetDock::loadConfigFromTemplate(), WorksheetDock::loadConfigFromTemplate(), XYCurveDock::loadConfigFromTemplate(), SpreadsheetView::maskSelection(), DropValuesDialog::maskValues(), Spreadsheet::moveColumn(), SpreadsheetView::normalizeSelectedColumns(), MatrixView::pasteIntoSelection(), SpreadsheetView::pasteIntoSelection(), PlotDataDialog::plot(), SpreadsheetView::powerTransformSelectedColumns(), removeAllChildren(), removeChild(), Spreadsheet::removeColumns(), AbstractColumn::removeRows(), Spreadsheet::removeRows(), MatrixView::removeSelectedColumns(), SpreadsheetView::removeSelectedColumns(), MatrixView::removeSelectedRows(), SpreadsheetView::removeSelectedRows(), SpreadsheetView::reverseColumns(), Column::setColumnMode(), Matrix::setDimensions(), Worksheet::setPageRect(), SpreadsheetView::setSelectionAs(), Spreadsheet::sortColumns(), CustomPointDock::symbolBorderColorChanged(), CustomPointDock::symbolBorderStyleChanged(), CustomPointDock::symbolBorderWidthChanged(), CustomPointDock::symbolFillingColorChanged(), CustomPointDock::symbolFillingStyleChanged(), CustomPointDock::symbolOpacityChanged(), CustomPointDock::symbolRotationChanged(), CustomPointDock::symbolSizeChanged(), CustomPointDock::symbolStyleChanged(), SpreadsheetView::unmaskSelection(), and CustomPointDock::visibilityChanged().

◆ exec() [1/2]

void AbstractAspect::exec ( QUndoCommand *  cmd)

Execute the given command, pushing it on the undoStack() if available.

Definition at line 713 of file AbstractAspect.cpp.

References d, AbstractAspectPrivate::m_undoAware, project(), Project::setChanged(), and undoStack().

Referenced by addChild(), Matrix::addColumns(), Matrix::addRows(), Matrix::clear(), Column::clear(), Matrix::clearCell(), Matrix::clearColumn(), Column::clearFormulas(), AbstractColumn::clearMasks(), Matrix::clearRow(), Column::copy(), exec(), AbstractColumn::handleRowInsertion(), Column::handleRowInsertion(), AbstractColumn::handleRowRemoval(), Column::handleRowRemoval(), insertChildBefore(), Matrix::insertColumns(), AbstractColumn::insertRows(), Matrix::insertRows(), CartesianPlot::loadThemeConfig(), Matrix::mirrorHorizontally(), Matrix::mirrorVertically(), removeAllChildren(), removeChild(), Matrix::removeColumns(), AbstractColumn::removeRows(), Matrix::removeRows(), reparent(), Column::replaceBigInt(), Column::replaceDateTimes(), Column::replaceInteger(), Column::replaceTexts(), Column::replaceValues(), Column::setBigIntAt(), Matrix::setCell(), Matrix::setColumnCells(), Column::setColumnMode(), Column::setColumnModeFast(), setComment(), Matrix::setCoordinates(), Matrix::setData(), Column::setDateTimeAt(), DateTime2StringFilter::setFormat(), String2DateTimeFilter::setFormat(), Column::setFormula(), Column::setIntegerAt(), AbstractColumn::setMasked(), setName(), Double2StringFilter::setNumDigits(), Double2StringFilter::setNumericFormat(), Axis::setOffset(), Worksheet::setPageRect(), Column::setPlotDesignation(), Image::setPosition(), TextLabel::setPosition(), CartesianPlot::setRect(), Matrix::setRowCells(), Column::setTextAt(), Column::setValueAt(), Image::setVisible(), CustomPoint::setVisible(), ReferenceLine::setVisible(), TextLabel::setVisible(), Axis::setVisible(), and Matrix::transpose().

◆ exec() [2/2]

void AbstractAspect::exec ( QUndoCommand *  command,
const char *  preChangeSignal,
const char *  postChangeSignal,
QGenericArgument  val0 = QGenericArgument(),
QGenericArgument  val1 = QGenericArgument(),
QGenericArgument  val2 = QGenericArgument(),
QGenericArgument  val3 = QGenericArgument() 
)

Execute command and arrange for signals to be sent before/after it is redone or undone.

  • command The command to be executed.
  • preChangeSignal The name of the signal to be triggered before re-/undoing the command.
  • postChangeSignal The name of the signal to be triggered after re-/undoing the command.
  • val0,val1,val2,val3 Arguments to the signals; to be given using Q_ARG().

Signal arguments are given using the macro Q_ARG(typename, const value&). Since the variable given as "value" will likely be out of scope when the signals are emitted, a copy needs to be created. This uses QMetaType, which means that (non-trivial) argument types need to be registered using qRegisterMetaType() before giving them to exec() (in particular, this also goes for pointers to custom data types).

See also
SignallingUndoCommand

Definition at line 748 of file AbstractAspect.cpp.

References beginMacro(), endMacro(), and exec().

◆ finalizeAdd()

virtual void AbstractAspect::finalizeAdd ( )
inlinevirtual

Reimplemented in Axis, and XYCurve.

Definition at line 156 of file AbstractAspect.h.

◆ folder()

Folder * AbstractAspect::folder ( )

Return the folder the Aspect is contained in or 0 if there is none.

The returned folder may be the aspect itself if it inherits Folder.

Definition at line 378 of file AbstractAspect.cpp.

References Folder, inherits(), and parentAspect().

Referenced by MainWin::addAspectToProject(), Project::createFolderContextMenu(), Matrix::duplicate(), MainWin::handleCurrentAspectChanged(), Folder::processDropEvent(), Folder::readChildAspectElement(), and MainWin::updateMdiWindowVisibility().

◆ hidden()

◆ icon()

◆ indexOfChild()

◆ info()

protected void AbstractAspect::info ( const QString &  text)
inlineprotected

Implementations should call this whenever status information should be given to the user.

This will cause statusInfo() to be emitted. Typically, this will cause the specified string to be displayed in a status bar, a log window or some similar non-blocking way so as not to disturb the workflow.

Definition at line 250 of file AbstractAspect.h.

References statusInfo().

Referenced by addChild(), CartesianPlotPrivate::hoverMoveEvent(), insertChildBefore(), CartesianPlotPrivate::mouseMoveCursorMode(), CartesianPlotPrivate::mouseMoveEvent(), CartesianPlotPrivate::mouseMoveZoomSelectionMode(), HistogramPrivate::recalcHistogram(), setName(), and XYCurvePrivate::updateLines().

◆ inherits()

◆ insertChildBefore()

◆ insertChildBeforeFast()

void AbstractAspect::insertChildBeforeFast ( AbstractAspect child,
AbstractAspect before 
)

Insert the given Aspect at a specific position in my list of children.without any checks and without putting this step onto the undo-stack.

Definition at line 466 of file AbstractAspect.cpp.

References aspectAboutToBeAdded(), aspectAdded(), child(), childDeselected(), childSelected(), d, deselected(), AbstractAspectPrivate::indexOfChild(), AbstractAspectPrivate::insertChild(), AbstractAspectPrivate::m_children, and selected().

◆ isDescendantOf()

bool AbstractAspect::isDescendantOf ( AbstractAspect other)

Return whether the there is a path upwards to the given aspect.

This also returns true if other==this.

Definition at line 391 of file AbstractAspect.cpp.

References parentAspect().

Referenced by MainWin::updateMdiWindowVisibility().

◆ isDraggable()

bool AbstractAspect::isDraggable ( ) const
virtual

Reimplemented in AbstractPart, Column, and Folder.

Definition at line 593 of file AbstractAspect.cpp.

◆ isLoading()

◆ load()

bool AbstractAspect::load ( XmlStreamReader ,
bool  preview 
)
pure virtual

Load from XML.

XmlStreamReader supports errors as well as warnings. If only warnings (non-critical errors) occur, this function must return the reader at the end element corresponding to the current element at the time the function was called.

This function is normally intended to be called directly after the ctor. If you want to call load on an aspect that has been altered, you must make sure beforehand that it is in the same state as after creation, e.g., remove all its child aspects.

Returns
false on error

Implemented in CantorWorksheet, AbstractSimpleFilter, SimpleFilterColumn, Column, ColumnStringIO, DateTime2StringFilter, Double2StringFilter, String2DateTimeFilter, Folder, Project, Workbook, Datapicker, DatapickerCurve, DatapickerImage, DatapickerPoint, LiveDataSource, MQTTClient, MQTTSubscription, MQTTTopic, Matrix, Note, Spreadsheet, Image, Axis, CartesianPlot, CartesianPlotLegend, CustomPoint, Histogram, ReferenceLine, XYAnalysisCurve, XYConvolutionCurve, XYCorrelationCurve, XYCurve, XYDataReductionCurve, XYDifferentiationCurve, XYEquationCurve, XYFitCurve, XYFourierFilterCurve, XYFourierTransformCurve, XYIntegrationCurve, XYInterpolationCurve, XYSmoothCurve, PlotArea, TextLabel, and Worksheet.

Referenced by setIsLoading().

◆ name()

QString AbstractAspect::name ( ) const

Definition at line 214 of file AbstractAspect.cpp.

References d, and AbstractAspectPrivate::m_name.

Referenced by addChild(), Matrix::addColumns(), DatapickerImageView::addCurve(), CartesianPlot::addDataReductionCurve(), CartesianPlot::addDifferentiationCurve(), CartesianPlot::addFitCurve(), CartesianPlot::addFourierFilterCurve(), CartesianPlot::addIntegrationCurve(), CartesianPlot::addInterpolationCurve(), Datapicker::addNewPoint(), Matrix::addRows(), CartesianPlot::addSmoothCurve(), DatapickerCurve::appendColumn(), AspectChildAddCmd::AspectChildAddCmd(), AspectChildRemoveCmd::AspectChildRemoveCmd(), AspectChildReparentCmd::AspectChildReparentCmd(), AxisDock::axisDescriptionChanged(), WorksheetView::cartesianPlotAddNew(), DatapickerImageView::changeSelectedItemsPosition(), child(), Datapicker::childSelected(), Matrix::clear(), Spreadsheet::clear(), Spreadsheet::clearMasks(), MatrixView::clearSelectedCells(), SpreadsheetView::clearSelectedCells(), MatrixView::clearSelectedColumns(), SpreadsheetView::clearSelectedColumns(), MatrixView::clearSelectedRows(), SpreadsheetView::clearSelectedRows(), Spreadsheet::column(), ColumnDock::columnDescriptionChanged(), AspectTreeModel::containsFilterString(), ProjectExplorer::contextMenuEvent(), Matrix::copy(), Spreadsheet::copy(), createContextMenu(), XYCurve::createContextMenu(), Worksheet::cursorModelPlotAdded(), Worksheet::cursorModelPlotRemoved(), Worksheet::curveAdded(), Worksheet::curveDataChanged(), HistogramDock::curveDescriptionChanged(), XYConvolutionCurveDock::curveDescriptionChanged(), XYCorrelationCurveDock::curveDescriptionChanged(), XYCurveDock::curveDescriptionChanged(), XYDataReductionCurveDock::curveDescriptionChanged(), XYDifferentiationCurveDock::curveDescriptionChanged(), XYEquationCurveDock::curveDescriptionChanged(), XYFitCurveDock::curveDescriptionChanged(), XYFourierFilterCurveDock::curveDescriptionChanged(), XYFourierTransformCurveDock::curveDescriptionChanged(), XYIntegrationCurveDock::curveDescriptionChanged(), XYInterpolationCurveDock::curveDescriptionChanged(), XYSmoothCurveDock::curveDescriptionChanged(), DatapickerCurveWidget::curveDescriptionChanged(), Worksheet::curveRemoved(), MatrixView::cutSelection(), SpreadsheetView::cutSelection(), AspectTreeModel::data(), CantorWorksheet::dataChanged(), DateTime2StringFilterSetFormatCmd::DateTime2StringFilterSetFormatCmd(), WorksheetView::deleteElement(), XYConvolutionCurveDock::directionChanged(), Double2StringFilterSetDigitsCmd::Double2StringFilterSetDigitsCmd(), Double2StringFilterSetFormatCmd::Double2StringFilterSetFormatCmd(), DropValuesDialog::dropValues(), Matrix::duplicate(), DynamicPresenterWidget::DynamicPresenterWidget(), WorksheetElement::execMoveBehind(), WorksheetElement::execMoveInFrontOf(), MainWin::exportDialog(), SpreadsheetView::exportToFile(), SpreadsheetView::exportToLaTeX(), MatrixView::exportToLaTeX(), SpreadsheetView::exportToSQLite(), SpreadsheetView::exportView(), DatapickerImage::exportView(), Matrix::exportView(), Worksheet::exportView(), SpreadsheetView::fillSelectedCellsWithConstValues(), SpreadsheetView::fillSelectedCellsWithRandomNumbers(), SpreadsheetView::fillSelectedCellsWithRowNumbers(), SpreadsheetView::fillWithRowNumbers(), ProjectExplorer::filter(), MatrixFunctionDialog::generate(), EquidistantValuesDialog::generate(), FunctionValuesDialog::generate(), RandomValuesDialog::generate(), AddSubtractValueDialog::generateForColumns(), AddSubtractValueDialog::generateForMatrices(), DatapickerView::handleAspectAdded(), WorkbookView::handleAspectAdded(), PartMdiView::handleAspectDescriptionChanged(), DatapickerView::handleDescriptionChanged(), WorkbookView::handleDescriptionChanged(), ImageDock::imageDescriptionChanged(), DatapickerImageWidget::imageDescriptionChanged(), ProjectParser::importTo(), Axis::init(), CartesianPlot::init(), CartesianPlotLegend::init(), XYCurveDock::initGeneralTab(), XYConvolutionCurveDock::initGeneralTab(), XYCorrelationCurveDock::initGeneralTab(), XYDataReductionCurveDock::initGeneralTab(), XYDifferentiationCurveDock::initGeneralTab(), XYEquationCurveDock::initGeneralTab(), XYFitCurveDock::initGeneralTab(), XYFourierFilterCurveDock::initGeneralTab(), XYFourierTransformCurveDock::initGeneralTab(), XYIntegrationCurveDock::initGeneralTab(), XYInterpolationCurveDock::initGeneralTab(), XYSmoothCurveDock::initGeneralTab(), insertChildBefore(), Spreadsheet::insertColumns(), SpreadsheetView::insertColumnsLeft(), SpreadsheetView::insertColumnsRight(), MatrixView::insertEmptyColumns(), MatrixView::insertEmptyRows(), AbstractColumn::insertRows(), Spreadsheet::insertRows(), SpreadsheetView::insertRowsAbove(), SpreadsheetView::insertRowsBelow(), CartesianPlotLegendDock::legendDescriptionChanged(), ReferenceLineDock::lineDescriptionChanged(), CartesianPlot::load(), XYConvolutionCurve::load(), XYCorrelationCurve::load(), XYDataReductionCurve::load(), XYDifferentiationCurve::load(), XYFitCurve::load(), XYFourierFilterCurve::load(), XYFourierTransformCurve::load(), XYIntegrationCurve::load(), XYInterpolationCurve::load(), XYSmoothCurve::load(), ProjectDock::loadConfig(), AxisDock::loadConfigFromTemplate(), CartesianPlotDock::loadConfigFromTemplate(), CartesianPlotLegendDock::loadConfigFromTemplate(), CustomPointDock::loadConfigFromTemplate(), HistogramDock::loadConfigFromTemplate(), MatrixDock::loadConfigFromTemplate(), SpreadsheetDock::loadConfigFromTemplate(), WorksheetDock::loadConfigFromTemplate(), XYCurveDock::loadConfigFromTemplate(), OriginProjectParser::loadFolder(), OriginProjectParser::loadMatrixWorkbook(), OriginProjectParser::loadNote(), OriginProjectParser::loadWorkbook(), OriginProjectParser::loadWorksheet(), SpreadsheetView::maskSelection(), DropValuesDialog::maskValues(), MatrixDock::matrixDescriptionChanged(), DatapickerImageView::mouseMoveEvent(), Spreadsheet::moveColumn(), ProjectParser::moveFolder(), MQTTSubscription::MQTTSubscription(), AbstractColumnPrivate::name(), ColumnPrivate::name(), Project::Private::name(), DatapickerCurvePrivate::name(), DatapickerImagePrivate::name(), DatapickerPointPrivate::name(), MatrixPrivate::name(), ImagePrivate::name(), AbstractPlotPrivate::name(), AxisPrivate::name(), CartesianPlotLegendPrivate::name(), CustomPointPrivate::name(), HistogramPrivate::name(), ReferenceLinePrivate::name(), XYCurvePrivate::name(), PlotAreaPrivate::name(), TextLabelPrivate::name(), WorksheetElementContainerPrivate::name(), WorksheetPrivate::name(), MainWin::newProject(), SpreadsheetView::normalizeSelectedColumns(), MainWin::openProject(), CartesianPlotLegendPrivate::paint(), MatrixView::pasteIntoSelection(), SpreadsheetView::pasteIntoSelection(), path(), Project::path(), PlotDataDialog::plot(), CartesianPlotDock::plotDescriptionChanged(), CustomPointDock::pointDescriptionChanged(), SpreadsheetView::powerTransformSelectedColumns(), WorksheetElement::prepareMoveBehindMenu(), WorksheetElement::prepareMoveInFrontOfMenu(), WorksheetView::presenterMode(), MainWin::print(), MainWin::printPreview(), PlotDataDialog::processColumns(), ProjectDock::projectDescriptionChanged(), readBasicAttributes(), Folder::readChildAspectElement(), removeAllChildren(), removeChild(), Spreadsheet::removeColumns(), AbstractColumn::removeRows(), Spreadsheet::removeRows(), MatrixView::removeSelectedColumns(), SpreadsheetView::removeSelectedColumns(), MatrixView::removeSelectedRows(), SpreadsheetView::removeSelectedRows(), CartesianPlotLegendPrivate::retransform(), SpreadsheetView::reverseColumns(), CantorWorksheet::rowsAboutToBeRemoved(), CantorWorksheet::rowsInserted(), Column::save(), XYFitCurve::save(), AxisDock::setAxes(), CantorWorksheetDock::setCantorWorksheets(), Column::setColumnMode(), ColumnDock::setColumns(), DatapickerCurveWidget::setCurves(), HistogramDock::setCurves(), Matrix::setDimensions(), LiveDataSource::setFileName(), DatapickerImageWidget::setImages(), ImageDock::setImages(), CartesianPlotLegendDock::setLegends(), LiveDataDock::setLiveDataSource(), LiveDataSource::setLocalSocketName(), MatrixDock::setMatrices(), NoteDock::setNotesList(), Worksheet::setPageRect(), CartesianPlotDock::setPlots(), CustomPointDock::setPoints(), ReferenceLineDock::setReferenceLines(), SpreadsheetView::setSelectionAs(), LiveDataSource::setSerialPort(), SpreadsheetDock::setSpreadsheets(), WorksheetDock::setWorksheets(), MatrixView::showColumnStatistics(), SpreadsheetView::showColumnStatistics(), MatrixView::showRowStatistics(), SpreadsheetView::showRowStatistics(), Spreadsheet::sortColumns(), SpreadsheetDock::spreadsheetDescriptionChanged(), String2DateTimeFilterSetFormatCmd::String2DateTimeFilterSetFormatCmd(), MQTTClient::subscriptionLoaded(), SpreadsheetView::unmaskSelection(), Worksheet::updateCompleteCursorTreeModel(), Worksheet::updateCurveBackground(), SpreadsheetModel::updateHorizontalHeader(), MainWin::updateTitleBar(), MainWin::warnModified(), CantorWorksheetDock::worksheetDescriptionChanged(), WorksheetDock::worksheetDescriptionChanged(), writeBasicAttributes(), and FITSFilterPrivate::writeCHDU().

◆ parent()

◆ parentAspect()

AbstractAspect * AbstractAspect::parentAspect ( ) const

Return my parent Aspect or 0 if I currently don't have one.

Definition at line 365 of file AbstractAspect.cpp.

References d, and AbstractAspectPrivate::m_parent.

Referenced by MainWin::activateSubWindowForAspect(), MainWin::activeSpreadsheet(), MainWin::addAspectToProject(), Datapicker::addNewPoint(), ancestor(), AspectTreeModel::aspectAboutToBeRemoved(), ProjectExplorer::aspectAdded(), AspectTreeModel::aspectAdded(), AspectTreeModel::aspectDeselectedInView(), AspectTreeModel::aspectHiddenAboutToChange(), AspectTreeModel::aspectHiddenChanged(), AspectTreeModel::aspectSelectedInView(), AxisDock::axisMajorTicksSpacingChanged(), AxisDock::axisMinorTicksSpacingChanged(), DatapickerImageView::changeSelectedItemsPosition(), childDeselected(), childSelected(), ColumnPrivate::connectFormulaColumn(), AspectTreeModel::containsFilterString(), createContextMenu(), AbstractPart::createContextMenu(), XYCurve::createContextMenu(), WorksheetElement::createContextMenu(), DateTime2StringFilterSetFormatCmd::DateTime2StringFilterSetFormatCmd(), Worksheet::deleteAspectFromGraphicsItem(), AbstractPart::deleteView(), dependsOn(), Double2StringFilterSetDigitsCmd::Double2StringFilterSetDigitsCmd(), Double2StringFilterSetFormatCmd::Double2StringFilterSetFormatCmd(), WorksheetElement::execMoveBehind(), WorksheetElement::execMoveInFrontOf(), Axis::finalizeAdd(), XYCurve::finalizeAdd(), FitOptionsWidget::FitOptionsWidget(), folder(), SpreadsheetModel::handleAspectAboutToBeRemoved(), SpreadsheetView::handleAspectAboutToBeRemoved(), MainWin::handleAspectAboutToBeRemoved(), SpreadsheetModel::handleAspectAdded(), Worksheet::handleAspectAdded(), WorksheetElementContainer::handleAspectAdded(), SpreadsheetView::handleAspectAdded(), MainWin::handleAspectRemoved(), SpreadsheetModel::handleDescriptionChange(), DatapickerView::handleDescriptionChanged(), GuiObserver::hiddenAspectSelected(), HistogramPrivate::hoverEnterEvent(), HistogramPrivate::hoverLeaveEvent(), DatapickerImageWidget::imageDescriptionChanged(), MainWin::importFileDialog(), MainWin::importSqlDialog(), DatapickerImageWidget::initConnections(), LabelWidget::initConnections(), XYDataReductionCurveDock::initGeneralTab(), XYDifferentiationCurveDock::initGeneralTab(), XYIntegrationCurveDock::initGeneralTab(), XYInterpolationCurveDock::initGeneralTab(), XYSmoothCurveDock::initGeneralTab(), AbstractAspectPrivate::insertChild(), isDescendantOf(), AbstractPart::isDraggable(), SegmentPrivate::itemChange(), CartesianPlotPrivate::keyPressEvent(), AxisDock::load(), OriginProjectParser::load(), AxisDock::loadConfig(), Axis::loadThemeConfig(), Histogram::loadThemeConfig(), XYCurve::loadThemeConfig(), OriginProjectParser::loadWorksheet(), AxisDock::majorTicksSpacingChanged(), AxisDock::majorTicksTypeChanged(), AxisDock::minorTicksSpacingChanged(), AxisDock::minorTicksTypeChanged(), AspectTreeModel::modelIndexOfAspect(), AxisPrivate::mouseMoveEvent(), AxisPrivate::mousePressEvent(), HistogramPrivate::mousePressEvent(), ProjectParser::moveFolder(), parent(), path(), PlotDataDialog::plot(), WorksheetElement::prepareMoveBehindMenu(), WorksheetElement::prepareMoveInFrontOfMenu(), project(), remove(), reparent(), DatapickerPoint::save(), AxisDock::saveConfigAsTemplate(), Histogram::saveThemeConfig(), XYCurve::saveThemeConfig(), ColumnDock::setColumns(), Spreadsheet::setColumnSelectedInView(), DatapickerImageWidget::setImages(), CartesianPlot::setMouseMode(), CartesianPlotDock::setPlots(), XYFitCurveDock::setPlotXRange(), DatapickerImage::setPrinting(), String2DateTimeFilterSetFormatCmd::String2DateTimeFilterSetFormatCmd(), undoStack(), LabelWidget::updateBackground(), DatapickerImagePrivate::updateFileName(), HistogramPrivate::updateFilling(), ColumnPrivate::updateFormula(), MainWin::updateGUI(), HistogramPrivate::updateLines(), DatapickerPointPrivate::updatePoint(), DatapickerCurve::updatePoint(), DatapickerPointPrivate::updatePropeties(), and Spreadsheet::view().

◆ path()

◆ processDropEvent()

virtual void AbstractAspect::processDropEvent ( const QVector< quintptr > &  )
inlinevirtual

Reimplemented in Folder, and CartesianPlot.

Definition at line 167 of file AbstractAspect.h.

Referenced by ProjectExplorer::eventFilter().

◆ project()

◆ readBasicAttributes()

◆ readCommentElement()

◆ remove

void AbstractAspect::remove ( )
slot

◆ removeAllChildren()

void AbstractAspect::removeAllChildren ( )

Remove all child Aspects.

Definition at line 506 of file AbstractAspect.cpp.

References aspectAboutToBeRemoved(), AspectChildRemoveCmd, aspectRemoved(), beginMacro(), children(), d, endMacro(), exec(), i18n, and name().

◆ removeChild()

◆ renameRequested

void AbstractAspect::renameRequested ( )
signal

◆ reparent()

void AbstractAspect::reparent ( AbstractAspect newParent,
int  newIndex = -1 
)

Move a child to another parent aspect and transfer ownership.

Definition at line 536 of file AbstractAspect.cpp.

References childCount(), d, exec(), IncludeHidden, and parentAspect().

Referenced by Folder::processDropEvent().

◆ save()

◆ selected

◆ setComment

◆ setCreationTime()

void AbstractAspect::setCreationTime ( const QDateTime &  time)

◆ setHidden()

◆ setIsLoading()

◆ setName

◆ setParentAspect()

void AbstractAspect::setParentAspect ( AbstractAspect parent)

◆ setSelected()

void AbstractAspect::setSelected ( bool  s)

this function is called when the selection in ProjectExplorer was changed. forwards the selection/deselection to the parent aspect via emitting a signal.

Definition at line 793 of file AbstractAspect.cpp.

References deselected(), and selected().

Referenced by ProjectExplorer::navigateTo(), Folder::processDropEvent(), and ProjectExplorer::selectionChanged().

◆ setUndoAware()

void AbstractAspect::setUndoAware ( bool  b)

Definition at line 695 of file AbstractAspect.cpp.

References d, and AbstractAspectPrivate::m_undoAware.

Referenced by CartesianPlot::addHorizontalAxis(), CartesianPlot::addVerticalAxis(), DatapickerImageView::changeSelectedItemsPosition(), CartesianPlot::checkAxisFormat(), Matrix::finalizeImport(), Spreadsheet::finalizeImport(), ImportFileDialog::importTo(), Datapicker::init(), XYEquationCurve::init(), CantorWorksheet::load(), CartesianPlotPrivate::mouseMoveEvent(), Matrix::prepareImport(), Spreadsheet::prepareImport(), XYFitCurvePrivate::prepareResultColumns(), WorksheetView::processResize(), Project::Project(), ImageFilterPrivate::readDataFromFile(), XYConvolutionCurvePrivate::recalculate(), XYCorrelationCurvePrivate::recalculate(), XYDataReductionCurvePrivate::recalculate(), XYDifferentiationCurvePrivate::recalculate(), XYFourierFilterCurvePrivate::recalculate(), XYFourierTransformCurvePrivate::recalculate(), XYIntegrationCurvePrivate::recalculate(), XYInterpolationCurvePrivate::recalculate(), XYSmoothCurvePrivate::recalculate(), Spreadsheet::resize(), CantorWorksheet::rowsInserted(), WorksheetPrivate::setContainerRect(), CartesianPlot::shiftDownY(), CartesianPlot::shiftLeftX(), CartesianPlot::shiftRightX(), CartesianPlot::shiftUpY(), Project::updateCurveColumnDependencies(), WorksheetPrivate::updatePageRect(), CartesianPlot::xDataChanged(), CartesianPlot::yDataChanged(), CartesianPlot::zoomIn(), CartesianPlot::zoomInX(), CartesianPlot::zoomInY(), CartesianPlot::zoomOut(), CartesianPlot::zoomOutX(), and CartesianPlot::zoomOutY().

◆ statusInfo

void AbstractAspect::statusInfo ( const QString &  text)
signal

◆ type()

◆ undoStack()

QUndoStack * AbstractAspect::undoStack ( ) const
virtual

Return the undo stack of the Project, or 0 if this Aspect is not part of a Project.

It's also possible to construct undo-enabled Aspect trees without Project. The only requirement is that the root Aspect reimplements undoStack() to get the undo stack from somewhere (the default implementation just delegates to parentAspect()).

Reimplemented in Project.

Definition at line 706 of file AbstractAspect.cpp.

References parentAspect(), and undoStack().

Referenced by beginMacro(), endMacro(), exec(), and undoStack().

◆ uniqueNameFor()

QString AbstractAspect::uniqueNameFor ( const QString &  current_name) const
private

Make the specified name unique among my children by incrementing a trailing number.

Definition at line 835 of file AbstractAspect.cpp.

References child(), and children().

Referenced by addChild(), insertChildBefore(), and setName().

◆ writeBasicAttributes()

◆ writeCommentElement()

Friends And Related Function Documentation

◆ AbstractAspectPrivate

friend class AbstractAspectPrivate
friend

Definition at line 126 of file AbstractAspect.h.

◆ AspectChildAddCmd

friend class AspectChildAddCmd
friend

Definition at line 124 of file AbstractAspect.h.

Referenced by addChild(), and insertChildBefore().

◆ AspectChildRemoveCmd

friend class AspectChildRemoveCmd
friend

Definition at line 125 of file AbstractAspect.h.

Referenced by removeAllChildren(), and removeChild().

Member Data Documentation

◆ d

AbstractAspectPrivate* AbstractAspect::d
private

Definition at line 261 of file AbstractAspect.h.

Referenced by Histogram::activateCurve(), XYCurve::activateCurve(), addChild(), addChildFast(), DatapickerCurve::addDatasheet(), beginMacro(), CartesianPlot::calculateCurvesXMinMax(), CartesianPlot::calculateCurvesYMinMax(), CartesianPlot::checkAxisFormat(), CartesianPlot::childAdded(), CartesianPlot::childHovered(), WorksheetElementContainer::childHovered(), children(), WorksheetElementContainer::childUnhovered(), comment(), Axis::createContextMenu(), ReferenceLine::createContextMenu(), creationTime(), CartesianPlot::cursor(), CartesianPlot::cursorPos(), CartesianPlot::curveVisibilityChanged(), CartesianPlot::dataChanged(), Histogram::dataColumnAboutToBeRemoved(), endMacro(), XYFitCurve::evaluate(), exec(), Axis::finalizeAdd(), XYCurve::finalizeAdd(), WorksheetElementContainer::handleAspectAdded(), AbstractPlot::handleResize(), Axis::handleResize(), Histogram::handleResize(), XYCurve::handleResize(), PlotArea::handleResize(), TextLabel::handleResize(), WorksheetElementContainer::handleResize(), XYAnalysisCurve::handleSourceDataChanged(), hidden(), Axis::icon(), DatapickerCurve::init(), DatapickerPoint::init(), Image::init(), Axis::init(), CartesianPlot::init(), CartesianPlotLegend::init(), CustomPoint::init(), Histogram::init(), ReferenceLine::init(), XYAnalysisCurve::init(), XYCurve::init(), XYEquationCurve::init(), PlotArea::init(), TextLabel::init(), XYFitCurve::initFitData(), XYFitCurve::initStartValues(), insertChildBefore(), insertChildBeforeFast(), Axis::isDefault(), Axis::isHovered(), CartesianPlot::isHovered(), isLoading(), CartesianPlot::isLocked(), CartesianPlot::isPanningActive(), CartesianPlot::isPrinted(), CartesianPlot::isSelected(), Image::isVisible(), Axis::isVisible(), CartesianPlotLegend::isVisible(), CustomPoint::isVisible(), Histogram::isVisible(), ReferenceLine::isVisible(), XYCurve::isVisible(), PlotArea::isVisible(), TextLabel::isVisible(), WorksheetElementContainer::isVisible(), Axis::labelChanged(), Axis::lineColorChanged(), ReferenceLine::lineColorChanged(), Axis::lineStyleChanged(), ReferenceLine::lineStyleChanged(), DatapickerCurve::load(), DatapickerPoint::load(), Image::load(), Axis::load(), CartesianPlot::load(), CartesianPlotLegend::load(), CustomPoint::load(), Histogram::load(), ReferenceLine::load(), XYConvolutionCurve::load(), XYCorrelationCurve::load(), XYCurve::load(), XYDataReductionCurve::load(), XYDifferentiationCurve::load(), XYFitCurve::load(), XYFourierFilterCurve::load(), XYFourierTransformCurve::load(), XYIntegrationCurve::load(), XYInterpolationCurve::load(), XYSmoothCurve::load(), PlotArea::load(), TextLabel::load(), Axis::loadThemeConfig(), CartesianPlot::loadThemeConfig(), Histogram::loadThemeConfig(), XYCurve::loadThemeConfig(), TextLabel::loadThemeConfig(), Axis::majorTicksColumnAboutToBeRemoved(), Axis::minorTicksColumnAboutToBeRemoved(), CartesianPlot::mouseHoverOutsideDataRect(), CartesianPlot::mouseHoverZoomSelectionMode(), CartesianPlot::mouseMode(), CartesianPlot::mouseMoveCursorMode(), CartesianPlot::mouseMoveZoomSelectionMode(), CartesianPlot::mousePressCursorMode(), CartesianPlot::mousePressZoomSelectionMode(), CartesianPlot::mouseReleaseZoomSelectionMode(), name(), CartesianPlot::navigate(), parentAspect(), WorksheetElementContainer::prepareGeometryChange(), readBasicAttributes(), XYCurve::recalcLogicalPoints(), XYEquationCurve::recalculate(), XYConvolutionCurve::recalculate(), XYCorrelationCurve::recalculate(), XYDataReductionCurve::recalculate(), XYDifferentiationCurve::recalculate(), XYFitCurve::recalculate(), XYFourierFilterCurve::recalculate(), XYFourierTransformCurve::recalculate(), XYIntegrationCurve::recalculate(), XYInterpolationCurve::recalculate(), XYSmoothCurve::recalculate(), WorksheetElementContainer::rect(), removeAllChildren(), removeChild(), reparent(), DatapickerPoint::retransform(), Image::retransform(), Axis::retransform(), CustomPoint::retransform(), ReferenceLine::retransform(), XYCurve::retransform(), TextLabel::retransform(), WorksheetElementContainer::retransform(), Axis::retransformTickLabelStrings(), Axis::retransformTicks(), DatapickerCurve::save(), DatapickerPoint::save(), Image::save(), Axis::save(), CartesianPlot::save(), CartesianPlotLegend::save(), CustomPoint::save(), Histogram::save(), ReferenceLine::save(), XYAnalysisCurve::save(), XYConvolutionCurve::save(), XYCorrelationCurve::save(), XYCurve::save(), XYDataReductionCurve::save(), XYDifferentiationCurve::save(), XYEquationCurve::save(), XYFitCurve::save(), XYFourierFilterCurve::save(), XYFourierTransformCurve::save(), XYIntegrationCurve::save(), XYInterpolationCurve::save(), XYSmoothCurve::save(), PlotArea::save(), TextLabel::save(), Axis::saveThemeConfig(), CartesianPlot::scaleAuto(), CartesianPlot::scaleAutoX(), CartesianPlot::scaleAutoY(), setComment(), setCreationTime(), Axis::setDefault(), setHidden(), Histogram::setHover(), XYCurve::setHover(), setIsLoading(), CartesianPlot::setLocked(), CartesianPlot::setMouseMode(), setName(), Axis::setOffset(), setParentAspect(), DatapickerPoint::setParentGraphicsItem(), Image::setParentGraphicsItem(), TextLabel::setParentGraphicsItem(), Image::setPosition(), TextLabel::setPosition(), TextLabel::setPositionInvalid(), Histogram::setPrinting(), XYCurve::setPrinting(), DatapickerPoint::setPrinting(), Image::setPrinting(), Axis::setPrinting(), CartesianPlotLegend::setPrinting(), CustomPoint::setPrinting(), ReferenceLine::setPrinting(), TextLabel::setPrinting(), WorksheetElementContainer::setPrinting(), CartesianPlot::setRect(), CartesianPlot::setSuppressDataChangedSignal(), Axis::setSuppressRetransform(), CartesianPlot::setType(), setUndoAware(), Image::setVisible(), CustomPoint::setVisible(), ReferenceLine::setVisible(), TextLabel::setVisible(), Axis::setVisible(), Axis::setZValue(), CartesianPlotLegend::setZValue(), CartesianPlot::shift(), CartesianPlot::shiftDownY(), CartesianPlot::shiftLeftX(), CartesianPlot::shiftRightX(), CartesianPlot::shiftUpY(), XYCurve::suppressRetransform(), CartesianPlot::type(), XYCurve::updateErrorBars(), DatapickerCurve::updatePoint(), TextLabel::updateTeXImage(), XYCurve::updateValues(), Histogram::valuesColumnAboutToBeRemoved(), XYCurve::valuesColumnAboutToBeRemoved(), XYCurve::valuesColumnNameChanged(), Image::visibilityChanged(), CartesianPlot::visibilityChanged(), CustomPoint::visibilityChanged(), XYCurve::visibilityChanged(), TextLabel::visibilityChanged(), Axis::visibilityChangedSlot(), CartesianPlotLegend::visibilityChangedSlot(), Histogram::visibilityChangedSlot(), ReferenceLine::visibilityChangedSlot(), XYCurve::xColumnAboutToBeRemoved(), XYCurve::xColumnNameChanged(), CartesianPlot::xDataChanged(), XYAnalysisCurve::xDataColumnAboutToBeRemoved(), XYAnalysisCurve::xDataColumnNameChanged(), XYCurve::xErrorMinusColumnAboutToBeRemoved(), XYCurve::xErrorMinusColumnNameChanged(), XYCurve::xErrorPlusColumnAboutToBeRemoved(), XYCurve::xErrorPlusColumnNameChanged(), CartesianPlot::xRangeDateTimeFormat(), XYAnalysisCurve::y2DataColumnAboutToBeRemoved(), XYAnalysisCurve::y2DataColumnNameChanged(), XYCurve::yColumnAboutToBeRemoved(), XYCurve::yColumnNameChanged(), CartesianPlot::yDataChanged(), XYAnalysisCurve::yDataColumnAboutToBeRemoved(), XYAnalysisCurve::yDataColumnNameChanged(), XYFitCurve::yErrorColumnPath(), XYCurve::yErrorMinusColumnAboutToBeRemoved(), XYCurve::yErrorMinusColumnNameChanged(), XYCurve::yErrorPlusColumnAboutToBeRemoved(), XYCurve::yErrorPlusColumnNameChanged(), CartesianPlot::yRangeDateTimeFormat(), CartesianPlot::zoom(), CartesianPlot::zoomIn(), CartesianPlot::zoomInX(), CartesianPlot::zoomInY(), CartesianPlot::zoomOut(), CartesianPlot::zoomOutX(), CartesianPlot::zoomOutY(), and ~AbstractAspect().

◆ m_type

const AspectType AbstractAspect::m_type
protected

Definition at line 258 of file AbstractAspect.h.

Referenced by inherits(), and type().


The documentation for this class was generated from the following files: