[kde-doc-english] [labplot/integrate-cantor] /: Merging frameworks

Garvit Khatri garvitdelhi at gmail.com
Tue Oct 20 06:20:34 UTC 2015


Git commit 5013c59a35e51544aa7e4e7e04f470cef806daf8 by Garvit Khatri.
Committed on 20/10/2015 at 05:02.
Pushed by garvitkhatri into branch 'integrate-cantor'.

Merging frameworks

M  +9    -36   CMakeLists.txt
M  +1    -1    doc/index.docbook
M  +2    -1    src/CMakeLists.txt
M  +24   -12   src/backend/core/AbstractAspect.cpp
M  +7    -6    src/backend/core/AbstractAspect.h
M  +3    -5    src/backend/core/Project.cpp
M  +132  -57   src/backend/core/column/Column.cpp
M  +14   -12   src/backend/core/column/Column.h
M  +3    -16   src/backend/datasources/FileDataSource.cpp
M  +1    -1    src/backend/datasources/FileDataSource.h
M  +0    -5    src/backend/worksheet/TextLabel.cpp
M  +3    -1    src/backend/worksheet/plots/cartesian/Axis.h
M  +9    -3    src/commonfrontend/spreadsheet/SpreadsheetView.cpp
M  +40   -34   src/commonfrontend/worksheet/WorksheetView.cpp
M  +2    -2    src/kdefrontend/LabPlot.cpp
M  +15   -8    src/kdefrontend/MainWin.cpp
M  +35   -25   src/kdefrontend/datasources/ImportFileDialog.cpp
M  +49   -28   src/kdefrontend/datasources/ImportFileWidget.cpp
M  +2    -2    src/kdefrontend/dockwidgets/XYCurveDock.cpp
M  +2    -2    src/kdefrontend/dockwidgets/XYEquationCurveDock.cpp
M  +1    -3    src/kdefrontend/dockwidgets/XYFitCurveDock.cpp
M  +179  -49   src/kdefrontend/spreadsheet/FunctionValuesDialog.cpp
M  +1    -1    src/kdefrontend/spreadsheet/RandomValuesDialog.cpp
M  +2    -2    src/kdefrontend/widgets/LabelWidget.cpp
M  +1    -2    src/tools/TeXRenderer.cpp

http://commits.kde.org/labplot/5013c59a35e51544aa7e4e7e04f470cef806daf8

diff --cc src/backend/core/AbstractAspect.cpp
index 130bcc7,d1b92c3..0529fd7
--- a/src/backend/core/AbstractAspect.cpp
+++ b/src/backend/core/AbstractAspect.cpp
@@@ -41,12 -41,11 +41,11 @@@
  #include <QApplication>
  #include <QXmlStreamWriter>
  
- #ifndef ACTIVATE_SCIDAVIS_SPECIFIC_CODE
  #include <QIcon>
--#include <KAction>
++#include <QAction>
  #include <KStandardAction>
  #include <QMenu>
- #endif
+ 
  /**
   * \class AbstractAspect
   * \brief Base class of all persistent objects in a Project.
@@@ -304,25 -303,16 +303,16 @@@ QIcon AbstractAspect::icon() const 
   * The caller takes ownership of the menu.
   */
  QMenu* AbstractAspect::createContextMenu() {
- #ifdef ACTIVATE_SCIDAVIS_SPECIFIC_CODE
- 	QMenu* menu = new QMenu();
- 	QAction *action;
- 	const QStyle *widget_style = qApp->style();
- 	action = menu->addAction(QObject::i18n("&Remove"), this, SLOT(remove()));
- 	action->setIcon(widget_style->standardIcon(QStyle::SP_TrashIcon));
- 	return menu;
- #else
 -    QMenu* menu = new QMenu();
 -    menu->addSection(this->name());
 +	QMenu* menu = new QMenu();
 +	menu->addSection(this->name());
  	//TODO: activate this again when the functionality is implemented
  // 	menu->addAction( KStandardAction::cut(this) );
  // 	menu->addAction(KStandardAction::copy(this));
  // 	menu->addAction(KStandardAction::paste(this));
  // 	menu->addSeparator();
 -    menu->addAction(QIcon::fromTheme("edit-rename"), i18n("Rename"), this, SIGNAL(renameRequested()));
 -    menu->addAction(QIcon::fromTheme("edit-delete"), i18n("Delete"), this, SLOT(remove()));
 +	menu->addAction(QIcon::fromTheme("edit-rename"), i18n("Rename"), this, SIGNAL(renameRequested()));
 +	menu->addAction(QIcon::fromTheme("edit-delete"), i18n("Delete"), this, SLOT(remove()));
  	return menu;
- #endif
  }
  
  /**
diff --cc src/backend/datasources/FileDataSource.cpp
index b8d7706,c26bbc0..ef4a892
--- a/src/backend/datasources/FileDataSource.cpp
+++ b/src/backend/datasources/FileDataSource.cpp
@@@ -37,16 -37,10 +37,10 @@@ Copyright	: (C) 2009-2015 Alexander Sem
  #include <QDir>
  #include <QMenu>
  #include <QFileSystemWatcher>
- #include <QDebug>
  
- #ifdef ACTIVATE_SCIDAVIS_SPECIFIC_CODE
  #include <QIcon>
 -#include <KAction>
 +#include <QAction>
- #else
- #include <QIcon>
- #include <KAction>
  #include <KLocale>
- #endif
  
  /*!
    \class FileDataSource
diff --cc src/backend/worksheet/plots/cartesian/Axis.h
index 535c779,a545464..15fe5ca
--- a/src/backend/worksheet/plots/cartesian/Axis.h
+++ b/src/backend/worksheet/plots/cartesian/Axis.h
@@@ -62,9 -62,11 +62,11 @@@ class Axis: public WorksheetElement 
  		explicit Axis(const QString &name, const AxisOrientation &orientation = AxisHorizontal);
  		virtual ~Axis();
  
 -        virtual QIcon icon() const;
 +		virtual QIcon icon() const;
  		virtual QMenu* createContextMenu();
- 		virtual QGraphicsItem *graphicsItem() const;
+ 
+ 		virtual QGraphicsItem* graphicsItem() const;
+ 		virtual void setZValue(qreal);
  
  		virtual void save(QXmlStreamWriter *) const;
  		virtual bool load(XmlStreamReader *);
diff --cc src/commonfrontend/worksheet/WorksheetView.cpp
index 76753f1,a06b9e3..fedc118
--- a/src/commonfrontend/worksheet/WorksheetView.cpp
+++ b/src/commonfrontend/worksheet/WorksheetView.cpp
@@@ -114,53 -114,53 +114,53 @@@ WorksheetView::WorksheetView(Worksheet
  }
  
  void WorksheetView::initActions(){
 -    QActionGroup* addNewActionGroup = new QActionGroup(this);
 -    QActionGroup* zoomActionGroup = new QActionGroup(this);
 -    QActionGroup* mouseModeActionGroup = new QActionGroup(this);
 -    QActionGroup* layoutActionGroup = new QActionGroup(this);
 -    QActionGroup* gridActionGroup = new QActionGroup(this);
 -    gridActionGroup->setExclusive(true);
 -
 -    selectAllAction = new QAction(QIcon::fromTheme("edit-select-all"), i18n("Select all"), this);
 -    selectAllAction->setShortcut(Qt::CTRL+Qt::Key_A);
 -    this->addAction(selectAllAction);
 -    connect(selectAllAction, SIGNAL(triggered()), SLOT(selectAllElements()));
 -
 -    deleteAction = new QAction(QIcon::fromTheme("edit-delete"), i18n("Delete"), this);
 -    deleteAction->setShortcut(Qt::Key_Delete);
 -    this->addAction(deleteAction);
 -    connect(deleteAction, SIGNAL(triggered()), SLOT(deleteElement()));
 -
 -    backspaceAction = new QAction(this);
 -    backspaceAction->setShortcut(Qt::Key_Backspace);
 -    this->addAction(backspaceAction);
 -    connect(backspaceAction, SIGNAL(triggered()), SLOT(deleteElement()));
 -
 -    //Zoom actions
 -    zoomInViewAction = new QAction(QIcon::fromTheme("zoom-in"), i18n("Zoom in"), zoomActionGroup);
 -    zoomInViewAction->setShortcut(Qt::CTRL+Qt::Key_Plus);
 -
 -    zoomOutViewAction = new QAction(QIcon::fromTheme("zoom-out"), i18n("Zoom out"), zoomActionGroup);
 -    zoomOutViewAction->setShortcut(Qt::CTRL+Qt::Key_Minus);
 -
 -    zoomOriginAction = new QAction(QIcon::fromTheme("zoom-original"), i18n("Original size"), zoomActionGroup);
 -    zoomOriginAction->setShortcut(Qt::CTRL+Qt::Key_1);
 -
 -    zoomFitPageHeightAction = new QAction(QIcon::fromTheme("zoom-fit-height"), i18n("Fit to height"), zoomActionGroup);
 -    zoomFitPageWidthAction = new QAction(QIcon::fromTheme("zoom-fit-width"), i18n("Fit to width"), zoomActionGroup);
 -    zoomFitSelectionAction = new QAction(i18n("Fit to selection"), zoomActionGroup);
 +	QActionGroup* addNewActionGroup = new QActionGroup(this);
 +	QActionGroup* zoomActionGroup = new QActionGroup(this);
 +	QActionGroup* mouseModeActionGroup = new QActionGroup(this);
 +	QActionGroup* layoutActionGroup = new QActionGroup(this);
 +	QActionGroup* gridActionGroup = new QActionGroup(this);
 +	gridActionGroup->setExclusive(true);
 +
 +	selectAllAction = new QAction(QIcon::fromTheme("edit-select-all"), i18n("Select all"), this);
 +	selectAllAction->setShortcut(Qt::CTRL+Qt::Key_A);
 +	this->addAction(selectAllAction);
 +	connect(selectAllAction, SIGNAL(triggered()), SLOT(selectAllElements()));
 +
 +	deleteAction = new QAction(QIcon::fromTheme("edit-delete"), i18n("Delete"), this);
 +	deleteAction->setShortcut(Qt::Key_Delete);
 +	this->addAction(deleteAction);
 +	connect(deleteAction, SIGNAL(triggered()), SLOT(deleteElement()));
 +
 +	backspaceAction = new QAction(this);
 +	backspaceAction->setShortcut(Qt::Key_Backspace);
 +	this->addAction(backspaceAction);
 +	connect(backspaceAction, SIGNAL(triggered()), SLOT(deleteElement()));
 +
 +	//Zoom actions
 +	zoomInViewAction = new QAction(QIcon::fromTheme("zoom-in"), i18n("Zoom in"), zoomActionGroup);
 +	zoomInViewAction->setShortcut(Qt::CTRL+Qt::Key_Plus);
 +
 +	zoomOutViewAction = new QAction(QIcon::fromTheme("zoom-out"), i18n("Zoom out"), zoomActionGroup);
 +	zoomOutViewAction->setShortcut(Qt::CTRL+Qt::Key_Minus);
 +
 +	zoomOriginAction = new QAction(QIcon::fromTheme("zoom-original"), i18n("Original size"), zoomActionGroup);
 +	zoomOriginAction->setShortcut(Qt::CTRL+Qt::Key_1);
 +
 +	zoomFitPageHeightAction = new QAction(QIcon::fromTheme("zoom-fit-height"), i18n("Fit to height"), zoomActionGroup);
 +	zoomFitPageWidthAction = new QAction(QIcon::fromTheme("zoom-fit-width"), i18n("Fit to width"), zoomActionGroup);
 +	zoomFitSelectionAction = new QAction(i18n("Fit to selection"), zoomActionGroup);
  
  	// Mouse mode actions
- 	selectionModeAction = new QAction(QIcon::fromTheme("cursor-arrow"), i18n("Select and Edit"), mouseModeActionGroup);
+ 	selectionModeAction = new QAction(QIcon::fromTheme("labplot-cursor-arrow"), i18n("Select and Edit"), mouseModeActionGroup);
  	selectionModeAction->setCheckable(true);
  
 -    navigationModeAction = new QAction(QIcon::fromTheme("input-mouse"), i18n("Navigate"), mouseModeActionGroup);
 -    navigationModeAction->setCheckable(true);
 +	navigationModeAction = new QAction(QIcon::fromTheme("input-mouse"), i18n("Navigate"), mouseModeActionGroup);
 +	navigationModeAction->setCheckable(true);
  
 -    zoomSelectionModeAction = new QAction(QIcon::fromTheme("page-zoom"), i18n("Select and Zoom"), mouseModeActionGroup);
 -    zoomSelectionModeAction->setCheckable(true);
 +	zoomSelectionModeAction = new QAction(QIcon::fromTheme("page-zoom"), i18n("Select and Zoom"), mouseModeActionGroup);
 +	zoomSelectionModeAction->setCheckable(true);
  
 -    //TODO implement later "group selection action" where multiple objects can be selected by drawing a rectangular
 +	//TODO implement later "group selection action" where multiple objects can be selected by drawing a rectangular
  // 	selectionModeAction = new QAction(QIcon::fromTheme("select-rectangular"), i18n("Selection"), mouseModeActionGroup);
  // 	selectionModeAction->setCheckable(true);
  
@@@ -188,94 -188,94 +188,93 @@@
  	breakLayoutAction->setObjectName("breakLayoutAction");
  	breakLayoutAction->setEnabled(false);
  
 -   //Grid actions
 -    noGridAction = new QAction(i18n("no grid"), gridActionGroup);
 -    noGridAction->setObjectName("noGridAction");
 -    noGridAction->setCheckable(true);
 -    noGridAction->setChecked(true);
 -    noGridAction->setData(WorksheetView::NoGrid);
 -
 -    denseLineGridAction = new QAction(i18n("dense line grid"), gridActionGroup);
 -    denseLineGridAction->setObjectName("denseLineGridAction");
 -    denseLineGridAction->setCheckable(true);
 -
 -    sparseLineGridAction = new QAction(i18n("sparse line grid"), gridActionGroup);
 -    sparseLineGridAction->setObjectName("sparseLineGridAction");
 -    sparseLineGridAction->setCheckable(true);
 -
 -    denseDotGridAction = new QAction(i18n("dense dot grid"), gridActionGroup);
 -    denseDotGridAction->setObjectName("denseDotGridAction");
 -    denseDotGridAction->setCheckable(true);
 -
 -    sparseDotGridAction = new QAction(i18n("sparse dot grid"), gridActionGroup);
 -    sparseDotGridAction->setObjectName("sparseDotGridAction");
 -    sparseDotGridAction->setCheckable(true);
 -
 -    customGridAction = new QAction(i18n("custom grid"), gridActionGroup);
 -    customGridAction->setObjectName("customGridAction");
 -    customGridAction->setCheckable(true);
 -
 -    snapToGridAction = new QAction(i18n("snap to grid"), this);
 -    snapToGridAction->setCheckable(true);
 -
 -    //check the action corresponding to the currently active layout in worksheet
 -    this->layoutChanged(m_worksheet->layout());
 -
 -    connect(addNewActionGroup, SIGNAL(triggered(QAction*)), this, SLOT(addNew(QAction*)));
 -    connect(mouseModeActionGroup, SIGNAL(triggered(QAction*)), this, SLOT(mouseModeChanged(QAction*)));
 -    connect(zoomActionGroup, SIGNAL(triggered(QAction*)), this, SLOT(changeZoom(QAction*)));
 -    connect(layoutActionGroup, SIGNAL(triggered(QAction*)), this, SLOT(changeLayout(QAction*)));
 -    connect(gridActionGroup, SIGNAL(triggered(QAction*)), this, SLOT(changeGrid(QAction*)));
 -    connect(snapToGridAction, SIGNAL(triggered()), this, SLOT(changeSnapToGrid()));
 -
 -
 -    //action for cartesian plots
 -    QActionGroup* cartesianPlotActionModeActionGroup = new QActionGroup(this);
 -    cartesianPlotActionModeActionGroup->setExclusive(true);
 -    cartesianPlotApplyToSelectionAction = new QAction(i18n("selected plots"), cartesianPlotActionModeActionGroup);
 -    cartesianPlotApplyToSelectionAction->setCheckable(true);
 -    cartesianPlotApplyToSelectionAction->setChecked(true);
 -    cartesianPlotApplyToAllAction = new QAction(i18n("all plots"), cartesianPlotActionModeActionGroup);
 -    cartesianPlotApplyToAllAction->setCheckable(true);
 -    connect(cartesianPlotActionModeActionGroup, SIGNAL(triggered(QAction*)), SLOT(cartesianPlotActionModeChanged(QAction*)));
 -
 -	QActionGroup* cartesianPlotMouseModeActionGroup = new QActionGroup(this);
 -	cartesianPlotMouseModeActionGroup->setExclusive(true);
 +	//Grid actions
 +	noGridAction = new QAction(i18n("no grid"), gridActionGroup);
 +	noGridAction->setObjectName("noGridAction");
 +	noGridAction->setCheckable(true);
 +	noGridAction->setChecked(true);
 +	noGridAction->setData(WorksheetView::NoGrid);
 +
 +	denseLineGridAction = new QAction(i18n("dense line grid"), gridActionGroup);
 +	denseLineGridAction->setObjectName("denseLineGridAction");
 +	denseLineGridAction->setCheckable(true);
 +
 +	sparseLineGridAction = new QAction(i18n("sparse line grid"), gridActionGroup);
 +	sparseLineGridAction->setObjectName("sparseLineGridAction");
 +	sparseLineGridAction->setCheckable(true);
 +
 +	denseDotGridAction = new QAction(i18n("dense dot grid"), gridActionGroup);
 +	denseDotGridAction->setObjectName("denseDotGridAction");
 +	denseDotGridAction->setCheckable(true);
 +
 +	sparseDotGridAction = new QAction(i18n("sparse dot grid"), gridActionGroup);
 +	sparseDotGridAction->setObjectName("sparseDotGridAction");
 +	sparseDotGridAction->setCheckable(true);
 +
 +	customGridAction = new QAction(i18n("custom grid"), gridActionGroup);
 +	customGridAction->setObjectName("customGridAction");
 +	customGridAction->setCheckable(true);
 +
 +	snapToGridAction = new QAction(i18n("snap to grid"), this);
 +	snapToGridAction->setCheckable(true);
 +
 +	//check the action corresponding to the currently active layout in worksheet
 +	this->layoutChanged(m_worksheet->layout());
 +
 +	connect(addNewActionGroup, SIGNAL(triggered(QAction*)), this, SLOT(addNew(QAction*)));
 +	connect(mouseModeActionGroup, SIGNAL(triggered(QAction*)), this, SLOT(mouseModeChanged(QAction*)));
 +	connect(zoomActionGroup, SIGNAL(triggered(QAction*)), this, SLOT(changeZoom(QAction*)));
 +	connect(layoutActionGroup, SIGNAL(triggered(QAction*)), this, SLOT(changeLayout(QAction*)));
 +	connect(gridActionGroup, SIGNAL(triggered(QAction*)), this, SLOT(changeGrid(QAction*)));
 +	connect(snapToGridAction, SIGNAL(triggered()), this, SLOT(changeSnapToGrid()));
 +
 +
 +	//action for cartesian plots
 +	QActionGroup* cartesianPlotActionModeActionGroup = new QActionGroup(this);
 +	cartesianPlotActionModeActionGroup->setExclusive(true);
 +	cartesianPlotApplyToSelectionAction = new QAction(i18n("selected plots"), cartesianPlotActionModeActionGroup);
 +	cartesianPlotApplyToSelectionAction->setCheckable(true);
 +	cartesianPlotApplyToSelectionAction->setChecked(true);
 +	cartesianPlotApplyToAllAction = new QAction(i18n("all plots"), cartesianPlotActionModeActionGroup);
 +	cartesianPlotApplyToAllAction->setCheckable(true);
 +	connect(cartesianPlotActionModeActionGroup, SIGNAL(triggered(QAction*)), SLOT(cartesianPlotActionModeChanged(QAction*)));
 +
- 	QActionGroup* cartesianPlotMouseModeActionGroup = new QActionGroup(this);
- 	cartesianPlotMouseModeActionGroup->setExclusive(true);
 +	cartesianPlotSelectionModeAction = new QAction(QIcon::fromTheme("cursor-arrow"), i18n("Select and edit"), cartesianPlotMouseModeActionGroup);
+ 	cartesianPlotSelectionModeAction = new QAction(QIcon::fromTheme("labplot-cursor-arrow"), i18n("Select and edit"), cartesianPlotMouseModeActionGroup);
  	cartesianPlotSelectionModeAction->setCheckable(true);
  	cartesianPlotSelectionModeAction->setChecked(true);
  
- 	cartesianPlotZoomSelectionModeAction = new QAction(QIcon::fromTheme("zoom-select"), i18n("Select region and zoom in"), cartesianPlotMouseModeActionGroup);
+ 	cartesianPlotZoomSelectionModeAction = new QAction(QIcon::fromTheme("labplot-zoom-select"), i18n("Select region and zoom in"), cartesianPlotMouseModeActionGroup);
  	cartesianPlotZoomSelectionModeAction->setCheckable(true);
  
- 	cartesianPlotZoomXSelectionModeAction = new QAction(QIcon::fromTheme("zoom-select-x"), i18n("Select x-region and zoom in"), cartesianPlotMouseModeActionGroup);
+ 	cartesianPlotZoomXSelectionModeAction = new QAction(QIcon::fromTheme("labplot-zoom-select-x"), i18n("Select x-region and zoom in"), cartesianPlotMouseModeActionGroup);
  	cartesianPlotZoomXSelectionModeAction->setCheckable(true);
  
- 	cartesianPlotZoomYSelectionModeAction = new QAction(QIcon::fromTheme("zoom-select-y"), i18n("Select y-region and zoom in"), cartesianPlotMouseModeActionGroup);
+ 	cartesianPlotZoomYSelectionModeAction = new QAction(QIcon::fromTheme("labplot-zoom-select-y"), i18n("Select y-region and zoom in"), cartesianPlotMouseModeActionGroup);
  	cartesianPlotZoomYSelectionModeAction->setCheckable(true);
  
 -    connect(cartesianPlotMouseModeActionGroup, SIGNAL(triggered(QAction*)), SLOT(cartesianPlotMouseModeChanged(QAction*)));
 +	connect(cartesianPlotMouseModeActionGroup, SIGNAL(triggered(QAction*)), SLOT(cartesianPlotMouseModeChanged(QAction*)));
  
- 	addCurveAction = new QAction(QIcon::fromTheme("xy-curve"), i18n("xy-curve"), this);
- 	addEquationCurveAction = new QAction(QIcon::fromTheme("xy-equation-curve"), i18n("xy-curve from a mathematical equation"), this);
- 	addFitCurveAction = new QAction(QIcon::fromTheme("xy-fit-curve"), i18n("xy-curve from a fit to data"), this);
+ 	addCurveAction = new QAction(QIcon::fromTheme("labplot-xy-curve"), i18n("xy-curve"), this);
+ 	addEquationCurveAction = new QAction(QIcon::fromTheme("labplot-xy-equation-curve"), i18n("xy-curve from a mathematical equation"), this);
+ 	addFitCurveAction = new QAction(QIcon::fromTheme("labplot-xy-fit-curve"), i18n("xy-curve from a fit to data"), this);
  	addLegendAction = new QAction(QIcon::fromTheme("text-field"), i18n("legend"), this);
- 	addHorizontalAxisAction = new QAction(QIcon::fromTheme("axis-horizontal"), i18n("horizontal axis"), this);
- 	addVerticalAxisAction = new QAction(QIcon::fromTheme("axis-vertical"), i18n("vertical axis"), this);
+ 	addHorizontalAxisAction = new QAction(QIcon::fromTheme("labplot-axis-horizontal"), i18n("horizontal axis"), this);
+ 	addVerticalAxisAction = new QAction(QIcon::fromTheme("labplot-axis-vertical"), i18n("vertical axis"), this);
  
 -    connect(addCurveAction, SIGNAL(triggered()), SLOT(addCurve()));
 -    connect(addEquationCurveAction, SIGNAL(triggered()), SLOT(addEquationCurve()));
 -    connect(addFitCurveAction, SIGNAL(triggered()), SLOT(addFitCurve()));
 -    connect(addLegendAction, SIGNAL(triggered()), SLOT(addLegend()));
 -    connect(addHorizontalAxisAction, SIGNAL(triggered()), SLOT(addHorizontalAxis()));
 -    connect(addVerticalAxisAction, SIGNAL(triggered()), SLOT(addVerticalAxis()));
 +	connect(addCurveAction, SIGNAL(triggered()), SLOT(addCurve()));
 +	connect(addEquationCurveAction, SIGNAL(triggered()), SLOT(addEquationCurve()));
 +	connect(addFitCurveAction, SIGNAL(triggered()), SLOT(addFitCurve()));
 +	connect(addLegendAction, SIGNAL(triggered()), SLOT(addLegend()));
 +	connect(addHorizontalAxisAction, SIGNAL(triggered()), SLOT(addHorizontalAxis()));
 +	connect(addVerticalAxisAction, SIGNAL(triggered()), SLOT(addVerticalAxis()));
  
  	QActionGroup* cartesianPlotNavigationGroup = new QActionGroup(this);
- 	scaleAutoAction = new QAction(QIcon::fromTheme("auto-scale-all"), i18n("auto scale"), cartesianPlotNavigationGroup);
+ 	scaleAutoAction = new QAction(QIcon::fromTheme("labplot-auto-scale-all"), i18n("auto scale"), cartesianPlotNavigationGroup);
  	scaleAutoAction->setData(CartesianPlot::ScaleAuto);
- 	scaleAutoXAction = new QAction(QIcon::fromTheme("auto-scale-x"), i18n("auto scale X"), cartesianPlotNavigationGroup);
+ 	scaleAutoXAction = new QAction(QIcon::fromTheme("labplot-auto-scale-x"), i18n("auto scale X"), cartesianPlotNavigationGroup);
  	scaleAutoXAction->setData(CartesianPlot::ScaleAutoX);
- 	scaleAutoYAction = new QAction(QIcon::fromTheme("auto-scale-y"), i18n("auto scale Y"), cartesianPlotNavigationGroup);
+ 	scaleAutoYAction = new QAction(QIcon::fromTheme("labplot-auto-scale-y"), i18n("auto scale Y"), cartesianPlotNavigationGroup);
  	scaleAutoYAction->setData(CartesianPlot::ScaleAutoY);
  	zoomInAction = new QAction(QIcon::fromTheme("zoom-in"), i18n("zoom in"), cartesianPlotNavigationGroup);
  	zoomInAction->setData(CartesianPlot::ZoomIn);
diff --cc src/kdefrontend/MainWin.cpp
index 60e0791,5a06631..431990d
--- a/src/kdefrontend/MainWin.cpp
+++ b/src/kdefrontend/MainWin.cpp
@@@ -251,13 -245,13 +251,13 @@@ void MainWin::initActions() 
  // 	actionCollection()->addAction("new_database_datasource", m_newSqlDataSourceAction);
  // 	connect(m_newSqlDataSourceAction, SIGNAL(triggered()), this, SLOT(newSqlDataSourceActionTriggered()));
  
- 	m_importAction = new QAction(QIcon::fromTheme("document-import-database"), i18n("Import"), this);
+ 	m_importAction = new QAction(QIcon::fromTheme("document-import"), i18n("Import"), this);
 -	m_importAction->setShortcut(Qt::CTRL+Qt::SHIFT+Qt::Key_I);
 +	actionCollection()->setDefaultShortcut(m_importAction, Qt::CTRL+Qt::SHIFT+Qt::Key_I);
  	actionCollection()->addAction("import", m_importAction);
  	connect(m_importAction, SIGNAL(triggered()),SLOT(importFileDialog()));
  
- 	m_exportAction = new QAction(QIcon::fromTheme("document-export-database"), i18n("Export"), this);
+ 	m_exportAction = new QAction(QIcon::fromTheme("document-export"), i18n("Export"), this);
 -	m_exportAction->setShortcut(Qt::CTRL+Qt::SHIFT+Qt::Key_E);
 +	actionCollection()->setDefaultShortcut(m_exportAction, Qt::CTRL+Qt::SHIFT+Qt::Key_E);
  	actionCollection()->addAction("export", m_exportAction);
  	connect(m_exportAction, SIGNAL(triggered()),SLOT(exportDialog()));
  
diff --cc src/kdefrontend/datasources/ImportFileDialog.cpp
index e0b7915,33a6311..d76b279
--- a/src/kdefrontend/datasources/ImportFileDialog.cpp
+++ b/src/kdefrontend/datasources/ImportFileDialog.cpp
@@@ -90,9 -90,10 +90,10 @@@ ImportFileDialog::ImportFileDialog(Main
  	importFileWidget->showOptions(m_optionsShown);
  
  	connect(this,SIGNAL(user1Clicked()), this, SLOT(toggleOptions()));
+ 	connect(importFileWidget, SIGNAL(fileNameChanged()), this, SLOT(checkOkButton()));
  
  	setCaption(i18n("Import Data to Spreadsheet or Matrix"));
 -    setWindowIcon(QIcon::fromTheme("document-import-database"));
 +	setWindowIcon(QIcon::fromTheme("document-import-database"));
  	resize( QSize(500,0).expandedTo(minimumSize()) );
  }
  
diff --cc src/kdefrontend/datasources/ImportFileWidget.cpp
index ae99509,a939305..b622caa
--- a/src/kdefrontend/datasources/ImportFileWidget.cpp
+++ b/src/kdefrontend/datasources/ImportFileWidget.cpp
@@@ -141,8 -143,17 +143,17 @@@ ImportFileWidget::ImportFileWidget(QWid
  	connect( ui.cbFilter, SIGNAL(activated(int)), SLOT(filterChanged(int)) );
  	connect( ui.bRefreshPreview, SIGNAL(clicked()), SLOT(refreshPreview()) );
  
+ 	//TODO: implement save/load of user-defined settings later and activate these buttons again
+ 	ui.bSaveFilter->hide();
+ 	ui.bManageFilters->hide();
+ 
+ 	//defer the loading of settings a bit in order to show the dialog prior to blocking the GUI in refreshPreview()
+ 	QTimer::singleShot( 100, this, SLOT(loadSettings()) );
+ }
+ 
+ void ImportFileWidget::loadSettings() {
  	//load last used settings
 -    KConfigGroup conf(KSharedConfig::openConfig(),"Import");
 +	KConfigGroup conf(KSharedConfig::openConfig(),"Import");
  
  	//settings for data type specific widgets
  	// ascii data
diff --cc src/kdefrontend/spreadsheet/FunctionValuesDialog.cpp
index 888d6e9,1e64579..c1b89c4
--- a/src/kdefrontend/spreadsheet/FunctionValuesDialog.cpp
+++ b/src/kdefrontend/spreadsheet/FunctionValuesDialog.cpp
@@@ -54,38 -55,21 +55,23 @@@ FunctionValuesDialog::FunctionValuesDia
  
  	QFrame* mainWidget = new QFrame(this);
  	ui.setupUi(mainWidget);
- 	setMainWidget( mainWidget );
+ 	setMainWidget(mainWidget);
  
- 	cbXDataColumn = new TreeViewComboBox(mainWidget);
- 	QGridLayout* gridLayout = dynamic_cast<QGridLayout*>(mainWidget->layout());
- 	Q_ASSERT(gridLayout);
- 	gridLayout->addWidget(cbXDataColumn, 0, 2, 1, 1);
+ 	ui.tbConstants->setIcon( QIcon::fromTheme("labplot-format-text-symbol") );
 +
 +	ui.tbConstants->setIcon( QIcon::fromTheme("format-text-symbol") );
  	ui.tbFunctions->setIcon( QIcon::fromTheme("preferences-desktop-font") );
  
- 	QStringList vars;
- 	vars<<"x";
- 	ui.teEquation->setVariables(vars);
- 
  	ui.teEquation->setFocus();
  
- 	if (m_spreadsheet) {
- 		m_aspectTreeModel = std::auto_ptr<AspectTreeModel>(new AspectTreeModel(m_spreadsheet->project()));
+ 	m_topLevelClasses<<"Folder"<<"Workbook"<<"Spreadsheet"<<"FileDataSource"<<"Column";
+ 	m_selectableClasses<<"Column";
  
- 		QList<const char *>  list;
- 		list<<"Folder"<<"Workbook"<<"Spreadsheet"<<"FileDataSource"<<"Column";
- 		cbXDataColumn->setTopLevelClasses(list);
+ 	m_aspectTreeModel = std::auto_ptr<AspectTreeModel>(new AspectTreeModel(m_spreadsheet->project()));
+ 	m_aspectTreeModel->setSelectableAspects(m_selectableClasses);
  
- 		list.clear();
- 		list<<"Column";
- 		m_aspectTreeModel->setSelectableAspects(list);
- 		cbXDataColumn->setSelectableClasses(list);
- 		cbXDataColumn->setModel(m_aspectTreeModel.get());
- 
- 		//select the first available column in the spreadsheet
- 		cbXDataColumn->setCurrentModelIndex(m_aspectTreeModel->modelIndexOfAspect(m_spreadsheet->column(0)));
- 	}
+     ui.bAddVariable->setIcon(QIcon::fromTheme("list-add"));
+ 	ui.bAddVariable->setToolTip(i18n("Add new variable"));
  
  	setButtons( KDialog::Ok | KDialog::Cancel );
  	setButtonText(KDialog::Ok, i18n("&Generate"));
diff --cc src/kdefrontend/widgets/LabelWidget.cpp
index ab57a1b,33b3326..7aeea41
--- a/src/kdefrontend/widgets/LabelWidget.cpp
+++ b/src/kdefrontend/widgets/LabelWidget.cpp
@@@ -66,58 -66,58 +66,58 @@@ LabelWidget::LabelWidget(QWidget *paren
  	ui.tbFontStrikeOut->setIcon( QIcon::fromTheme("format-text-strikethrough") );
  	ui.tbFontSuperScript->setIcon( QIcon::fromTheme("format-text-superscript") );
  	ui.tbFontSubScript->setIcon( QIcon::fromTheme("format-text-subscript") );
- 	ui.tbSymbols->setIcon( QIcon::fromTheme("format-text-symbol") );
+ 	ui.tbSymbols->setIcon( QIcon::fromTheme("labplot-format-text-symbol") );
  	ui.tbDateTime->setIcon( QIcon::fromTheme("chronometer") );
  	ui.tbTexUsed->setIconSize(QSize(20, 20));
- 	ui.tbTexUsed->setIcon( QIcon::fromTheme("TeX_logo") );
+ 	ui.tbTexUsed->setIcon( QIcon::fromTheme("labplot-TeX-logo") );
  
 -    //Positioning and alignment
 -    ui.cbPositionX->addItem(i18n("left"));
 -    ui.cbPositionX->addItem(i18n("center"));
 -    ui.cbPositionX->addItem(i18n("right"));
 -    ui.cbPositionX->addItem(i18n("custom"));
 -
 -    ui.cbPositionY->addItem(i18n("top"));
 -    ui.cbPositionY->addItem(i18n("center"));
 -    ui.cbPositionY->addItem(i18n("bottom"));
 -    ui.cbPositionY->addItem(i18n("custom"));
 -
 -    ui.cbHorizontalAlignment->addItem(i18n("left"));
 -    ui.cbHorizontalAlignment->addItem(i18n("center"));
 -    ui.cbHorizontalAlignment->addItem(i18n("right"));
 -
 -    ui.cbVerticalAlignment->addItem(i18n("top"));
 -    ui.cbVerticalAlignment->addItem(i18n("center"));
 -    ui.cbVerticalAlignment->addItem(i18n("bottom"));
 -
 -    //SLOTS
 -    // text properties
 -    connect(ui.tbTexUsed, SIGNAL(clicked(bool)), this, SLOT(teXUsedChanged(bool)) );
 -    connect(ui.teLabel, SIGNAL(textChanged()), this, SLOT(textChanged()));
 -    connect(ui.teLabel, SIGNAL(currentCharFormatChanged(QTextCharFormat)),
 -            this, SLOT(charFormatChanged(QTextCharFormat)));
 -    connect(ui.kcbFontColor, SIGNAL(changed(QColor)), this, SLOT(fontColorChanged(QColor)));
 -    connect(ui.tbFontBold, SIGNAL(clicked(bool)), this, SLOT(fontBoldChanged(bool)));
 -    connect(ui.tbFontItalic, SIGNAL(clicked(bool)), this, SLOT(fontItalicChanged(bool)));
 -    connect(ui.tbFontUnderline, SIGNAL(clicked(bool)), this, SLOT(fontUnderlineChanged(bool)));
 -    connect(ui.tbFontStrikeOut, SIGNAL(clicked(bool)), this, SLOT(fontStrikeOutChanged(bool)));
 -    connect(ui.tbFontSuperScript, SIGNAL(clicked(bool)), this, SLOT(fontSuperScriptChanged(bool)));
 -    connect(ui.tbFontSubScript, SIGNAL(clicked(bool)), this, SLOT(fontSubScriptChanged(bool)));
 -    connect(ui.tbSymbols, SIGNAL(clicked(bool)), this, SLOT(charMenu()));
 -    connect(ui.tbDateTime, SIGNAL(clicked(bool)), this, SLOT(dateTimeMenu()));
 -    connect(m_dateTimeMenu, SIGNAL(triggered(QAction*)), this, SLOT(insertDateTime(QAction*)) );
 -    connect(ui.kfontRequester, SIGNAL(fontSelected(QFont)), this, SLOT(fontChanged(QFont)));
 -    connect(ui.sbFontSize, SIGNAL(valueChanged(int)), this, SLOT(fontSizeChanged(int)) );
 -
 -    // geometry
 -    connect( ui.cbPositionX, SIGNAL(currentIndexChanged(int)), this, SLOT(positionXChanged(int)) );
 -    connect( ui.cbPositionY, SIGNAL(currentIndexChanged(int)), this, SLOT(positionYChanged(int)) );
 -    connect( ui.sbPositionX, SIGNAL(valueChanged(double)), this, SLOT(customPositionXChanged(double)) );
 -    connect( ui.sbPositionY, SIGNAL(valueChanged(double)), this, SLOT(customPositionYChanged(double)) );
 -    connect( ui.cbHorizontalAlignment, SIGNAL(currentIndexChanged(int)), this, SLOT(horizontalAlignmentChanged(int)) );
 -    connect( ui.cbVerticalAlignment, SIGNAL(currentIndexChanged(int)), this, SLOT(verticalAlignmentChanged(int)) );
 -    connect( ui.sbRotation, SIGNAL(valueChanged(int)), this, SLOT(rotationChanged(int)) );
 -    connect( ui.sbOffset, SIGNAL(valueChanged(double)), this, SLOT(offsetChanged(double)) );
 +	//Positioning and alignment
 +	ui.cbPositionX->addItem(i18n("left"));
 +	ui.cbPositionX->addItem(i18n("center"));
 +	ui.cbPositionX->addItem(i18n("right"));
 +	ui.cbPositionX->addItem(i18n("custom"));
 +
 +	ui.cbPositionY->addItem(i18n("top"));
 +	ui.cbPositionY->addItem(i18n("center"));
 +	ui.cbPositionY->addItem(i18n("bottom"));
 +	ui.cbPositionY->addItem(i18n("custom"));
 +
 +	ui.cbHorizontalAlignment->addItem(i18n("left"));
 +	ui.cbHorizontalAlignment->addItem(i18n("center"));
 +	ui.cbHorizontalAlignment->addItem(i18n("right"));
 +
 +	ui.cbVerticalAlignment->addItem(i18n("top"));
 +	ui.cbVerticalAlignment->addItem(i18n("center"));
 +	ui.cbVerticalAlignment->addItem(i18n("bottom"));
 +
 +	//SLOTS
 +	// text properties
 +	connect(ui.tbTexUsed, SIGNAL(clicked(bool)), this, SLOT(teXUsedChanged(bool)) );
 +	connect(ui.teLabel, SIGNAL(textChanged()), this, SLOT(textChanged()));
 +	connect(ui.teLabel, SIGNAL(currentCharFormatChanged(QTextCharFormat)),
 +			this, SLOT(charFormatChanged(QTextCharFormat)));
 +	connect(ui.kcbFontColor, SIGNAL(changed(QColor)), this, SLOT(fontColorChanged(QColor)));
 +	connect(ui.tbFontBold, SIGNAL(clicked(bool)), this, SLOT(fontBoldChanged(bool)));
 +	connect(ui.tbFontItalic, SIGNAL(clicked(bool)), this, SLOT(fontItalicChanged(bool)));
 +	connect(ui.tbFontUnderline, SIGNAL(clicked(bool)), this, SLOT(fontUnderlineChanged(bool)));
 +	connect(ui.tbFontStrikeOut, SIGNAL(clicked(bool)), this, SLOT(fontStrikeOutChanged(bool)));
 +	connect(ui.tbFontSuperScript, SIGNAL(clicked(bool)), this, SLOT(fontSuperScriptChanged(bool)));
 +	connect(ui.tbFontSubScript, SIGNAL(clicked(bool)), this, SLOT(fontSubScriptChanged(bool)));
 +	connect(ui.tbSymbols, SIGNAL(clicked(bool)), this, SLOT(charMenu()));
 +	connect(ui.tbDateTime, SIGNAL(clicked(bool)), this, SLOT(dateTimeMenu()));
 +	connect(m_dateTimeMenu, SIGNAL(triggered(QAction*)), this, SLOT(insertDateTime(QAction*)) );
 +	connect(ui.kfontRequester, SIGNAL(fontSelected(QFont)), this, SLOT(fontChanged(QFont)));
 +	connect(ui.sbFontSize, SIGNAL(valueChanged(int)), this, SLOT(fontSizeChanged(int)) );
 +
 +	// geometry
 +	connect( ui.cbPositionX, SIGNAL(currentIndexChanged(int)), this, SLOT(positionXChanged(int)) );
 +	connect( ui.cbPositionY, SIGNAL(currentIndexChanged(int)), this, SLOT(positionYChanged(int)) );
 +	connect( ui.sbPositionX, SIGNAL(valueChanged(double)), this, SLOT(customPositionXChanged(double)) );
 +	connect( ui.sbPositionY, SIGNAL(valueChanged(double)), this, SLOT(customPositionYChanged(double)) );
 +	connect( ui.cbHorizontalAlignment, SIGNAL(currentIndexChanged(int)), this, SLOT(horizontalAlignmentChanged(int)) );
 +	connect( ui.cbVerticalAlignment, SIGNAL(currentIndexChanged(int)), this, SLOT(verticalAlignmentChanged(int)) );
 +	connect( ui.sbRotation, SIGNAL(valueChanged(int)), this, SLOT(rotationChanged(int)) );
 +	connect( ui.sbOffset, SIGNAL(valueChanged(double)), this, SLOT(offsetChanged(double)) );
  
  	connect( ui.chbVisible, SIGNAL(clicked(bool)), this, SLOT(visibilityChanged(bool)) );
  



More information about the kde-doc-english mailing list