[kde-doc-english] [labplot/frameworks] /: Merge branch 'master' into frameworks

Alexander Semke alexander.semke at web.de
Sat May 14 19:04:50 UTC 2016


Git commit 996576f0af2a29600d317940f9c3b289ae05622d by Alexander Semke.
Committed on 14/05/2016 at 19:04.
Pushed by asemke into branch 'frameworks'.

Merge branch 'master' into frameworks

M  +9    -5    doc/index.docbook
M  +2    -6    src/backend/core/Folder.cpp
M  +9    -8    src/backend/core/column/Column.cpp
M  +3    -4    src/backend/datasources/FileDataSource.h
M  +3    -3    src/backend/worksheet/TextLabel.cpp
M  +1    -1    src/backend/worksheet/TextLabel.h
M  +0    -1    src/backend/worksheet/Worksheet.cpp
M  +3    -3    src/backend/worksheet/plots/cartesian/Axis.cpp
M  +594  -509  src/backend/worksheet/plots/cartesian/CartesianPlot.cpp
M  +3    -2    src/backend/worksheet/plots/cartesian/CartesianPlot.h
M  +7    -0    src/backend/worksheet/plots/cartesian/XYCurve.cpp
M  +4    -0    src/backend/worksheet/plots/cartesian/XYFitCurve.cpp
M  +51   -10   src/commonfrontend/matrix/MatrixView.cpp
M  +82   -11   src/commonfrontend/spreadsheet/SpreadsheetView.cpp
M  +5    -4    src/commonfrontend/spreadsheet/SpreadsheetView.h
M  +78   -34   src/commonfrontend/widgets/TreeViewComboBox.cpp
M  +7    -4    src/commonfrontend/worksheet/WorksheetView.cpp
M  +2    -1    src/commonfrontend/worksheet/WorksheetView.h
M  +562  -452  src/kdefrontend/dockwidgets/CartesianPlotDock.cpp
M  +6    -2    src/kdefrontend/dockwidgets/CartesianPlotDock.h
M  +1    -1    src/kdefrontend/dockwidgets/XYFourierFilterCurveDock.cpp
M  +116  -17   src/kdefrontend/dockwidgets/XYInterpolationCurveDock.cpp
M  +56   -17   src/kdefrontend/spreadsheet/ExportSpreadsheetDialog.cpp
M  +137  -65   src/kdefrontend/spreadsheet/RandomValuesDialog.cpp
M  +3    -2    src/kdefrontend/spreadsheet/RandomValuesDialog.h
M  +1    -37   src/kdefrontend/ui/dockwidgets/cartesianplotdock.ui
M  +15   -15   src/kdefrontend/widgets/LabelWidget.cpp

http://commits.kde.org/labplot/996576f0af2a29600d317940f9c3b289ae05622d

diff --cc src/backend/worksheet/plots/cartesian/CartesianPlot.cpp
index 5fc788a,3e628ea..68826a6
--- a/src/backend/worksheet/plots/cartesian/CartesianPlot.cpp
+++ b/src/backend/worksheet/plots/cartesian/CartesianPlot.cpp
@@@ -342,17 -342,17 +342,17 @@@ void CartesianPlot::initDefault(Type ty
  	d->retransform();
  }
  
- void CartesianPlot::initActions(){
+ void CartesianPlot::initActions() {
  	//"add new" actions
 -	addCurveAction = new KAction(KIcon("labplot-xy-curve"), i18n("xy-curve"), this);
 -	addEquationCurveAction = new KAction(KIcon("labplot-xy-equation-curve"), i18n("xy-curve from a mathematical equation"), this);
 -	addFitCurveAction = new KAction(KIcon("labplot-xy-fit-curve"), i18n("xy-curve from a fit to data"), this);
 -	addFourierFilterCurveAction = new KAction(KIcon("labplot-xy-fourier_filter-curve"), i18n("xy-curve from a Fourier filter"), this);
 -	addInterpolationCurveAction = new KAction(KIcon("labplot-xy-interpolation-curve"), i18n("xy-curve from an interpolation"), this);
 -	addLegendAction = new KAction(KIcon("text-field"), i18n("legend"), this);
 -	addHorizontalAxisAction = new KAction(KIcon("labplot-axis-horizontal"), i18n("horizontal axis"), this);
 -	addVerticalAxisAction = new KAction(KIcon("labplot-axis-vertical"), i18n("vertical axis"), this);
 -	addCustomPointAction = new KAction(KIcon("draw-cross"), i18n("custom point"), 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);
 +	addFourierFilterCurveAction = new QAction(QIcon::fromTheme("labplot-xy-fourier_filter-curve"), i18n("xy-curve from a Fourier filter"), this);
 +	addInterpolationCurveAction = new QAction(QIcon::fromTheme("labplot-xy-interpolation-curve"), i18n("xy-curve from an interpolation"), this);
 +	addLegendAction = new QAction(QIcon::fromTheme("text-field"), i18n("legend"), 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);
 +	addCustomPointAction = new QAction(QIcon::fromTheme("draw-cross"), i18n("custom point"), this);
  
  	connect(addCurveAction, SIGNAL(triggered()), SLOT(addCurve()));
  	connect(addEquationCurveAction, SIGNAL(triggered()), SLOT(addEquationCurve()));
@@@ -364,19 -364,19 +364,19 @@@
  	connect(addCustomPointAction, SIGNAL(triggered()), SLOT(addCustomPoint()));
  
  	//zoom/navigate actions
 -	scaleAutoAction = new KAction(KIcon("labplot-auto-scale-all"), i18n("auto scale"), this);
 -	scaleAutoXAction = new KAction(KIcon("labplot-auto-scale-x"), i18n("auto scale X"), this);
 -	scaleAutoYAction = new KAction(KIcon("labplot-auto-scale-y"), i18n("auto scale Y"), this);
 -	zoomInAction = new KAction(KIcon("zoom-in"), i18n("zoom in"), this);
 -	zoomOutAction = new KAction(KIcon("zoom-out"), i18n("zoom out"), this);
 -	zoomInXAction = new KAction(KIcon("labplot-zoom-in-x"), i18n("zoom in X"), this);
 -	zoomOutXAction = new KAction(KIcon("labplot-zoom-out-x"), i18n("zoom out X"), this);
 -	zoomInYAction = new KAction(KIcon("labplot-zoom-in-y"), i18n("zoom in Y"), this);
 -	zoomOutYAction = new KAction(KIcon("labplot-zoom-out-y"), i18n("zoom out Y"), this);
 -	shiftLeftXAction = new KAction(KIcon("labplot-shift-left-x"), i18n("shift left X"), this);
 -	shiftRightXAction = new KAction(KIcon("labplot-shift-right-x"), i18n("shift right X"), this);
 -	shiftUpYAction = new KAction(KIcon("labplot-shift-up-y"), i18n("shift up Y"), this);
 -	shiftDownYAction = new KAction(KIcon("labplot-shift-down-y"), i18n("shift down Y"), this);
 +	scaleAutoAction = new QAction(QIcon::fromTheme("labplot-auto-scale-all"), i18n("auto scale"), this);
 +	scaleAutoXAction = new QAction(QIcon::fromTheme("labplot-auto-scale-x"), i18n("auto scale X"), this);
 +	scaleAutoYAction = new QAction(QIcon::fromTheme("labplot-auto-scale-y"), i18n("auto scale Y"), this);
 +	zoomInAction = new QAction(QIcon::fromTheme("zoom-in"), i18n("zoom in"), this);
 +	zoomOutAction = new QAction(QIcon::fromTheme("zoom-out"), i18n("zoom out"), this);
 +	zoomInXAction = new QAction(QIcon::fromTheme("labplot-zoom-in-x"), i18n("zoom in X"), this);
 +	zoomOutXAction = new QAction(QIcon::fromTheme("labplot-zoom-out-x"), i18n("zoom out X"), this);
 +	zoomInYAction = new QAction(QIcon::fromTheme("labplot-zoom-in-y"), i18n("zoom in Y"), this);
 +	zoomOutYAction = new QAction(QIcon::fromTheme("labplot-zoom-out-y"), i18n("zoom out Y"), this);
-     shiftLeftXAction = new QAction(QIcon::fromTheme("labplot-shift-left-x"), i18n("shift left X"), this);
++	shiftLeftXAction = new QAction(QIcon::fromTheme("labplot-shift-left-x"), i18n("shift left X"), this);
 +	shiftRightXAction = new QAction(QIcon::fromTheme("labplot-shift-right-x"), i18n("shift right X"), this);
 +	shiftUpYAction = new QAction(QIcon::fromTheme("labplot-shift-up-y"), i18n("shift up Y"), this);
 +	shiftDownYAction = new QAction(QIcon::fromTheme("labplot-shift-down-y"), i18n("shift down Y"), this);
  
  	connect(scaleAutoAction, SIGNAL(triggered()), SLOT(scaleAuto()));
  	connect(scaleAutoXAction, SIGNAL(triggered()), SLOT(scaleAutoX()));
@@@ -449,8 -449,8 +449,8 @@@ QMenu* CartesianPlot::createContextMenu
  /*!
  	Returns an icon to be used in the project explorer.
  */
- QIcon CartesianPlot::icon() const{
+ QIcon CartesianPlot::icon() const {
 -	return KIcon("office-chart-line");
 +	return QIcon::fromTheme("office-chart-line");
  }
  
  void CartesianPlot::navigate(CartesianPlot::NavigationOperation op) {
diff --cc src/commonfrontend/spreadsheet/SpreadsheetView.cpp
index 77b53d3,653dba8..4c5260d
--- a/src/commonfrontend/spreadsheet/SpreadsheetView.cpp
+++ b/src/commonfrontend/spreadsheet/SpreadsheetView.cpp
@@@ -48,14 -48,14 +48,15 @@@
  #include <QDate>
  #include <QApplication>
  #include <QMenu>
++#include <QMimeData>
  #include <QPainter>
  #include <QPrinter>
  #include <QToolBar>
  #include <QTextStream>
- #include <QMimeData>
+ #include <QProcess>
  // #include <QDebug>
  
 -#include <KAction>
 +#include <QAction>
  #include <KLocale>
  #include "kdefrontend/spreadsheet/DropValuesDialog.h"
  #include "kdefrontend/spreadsheet/SortDialog.h"
@@@ -156,60 -156,61 +157,61 @@@ void SpreadsheetView::init() 
  
  void SpreadsheetView::initActions() {
  	// selection related actions
 -	action_cut_selection = new KAction(KIcon("edit-cut"), i18n("Cu&t"), this);
 -	action_copy_selection = new KAction(KIcon("edit-copy"), i18n("&Copy"), this);
 -	action_paste_into_selection = new KAction(KIcon("edit-paste"), i18n("Past&e"), this);
 -	action_mask_selection = new KAction(KIcon("edit-node"), i18n("&Mask Selection"), this);
 -	action_unmask_selection = new KAction(KIcon("format-remove-node"), i18n("&Unmask Selection"), this);
 -	action_clear_selection = new KAction(KIcon("edit-clear"), i18n("Clea&r Selection"), this);
 -	action_select_all = new KAction(KIcon("edit-select-all"), i18n("Select All"), this);
 -
 -// 	action_set_formula = new KAction(KIcon(""), i18n("Assign &Formula"), this);
 -// 	action_recalculate = new KAction(KIcon(""), i18n("Recalculate"), this);
 -	action_fill_sel_row_numbers = new KAction(KIcon(""), i18n("Row Numbers"), this);
 -	action_fill_row_numbers = new KAction(KIcon(""), i18n("Row Numbers"), this);
 -	action_fill_random = new KAction(KIcon(""), i18n("Uniform Random Values"), this);
 -	action_fill_random_nonuniform = new KAction(KIcon(""), i18n("Random Values"), this);
 -	action_fill_equidistant = new KAction(KIcon(""), i18n("Equidistant Values"), this);
 -	action_fill_function = new KAction(KIcon(""), i18n("Function Values"), this);
 -	action_fill_const = new KAction(KIcon(""), i18n("Const Values"), this);
 +	action_cut_selection = new QAction(QIcon::fromTheme("edit-cut"), i18n("Cu&t"), this);
 +	action_copy_selection = new QAction(QIcon::fromTheme("edit-copy"), i18n("&Copy"), this);
 +	action_paste_into_selection = new QAction(QIcon::fromTheme("edit-paste"), i18n("Past&e"), this);
 +	action_mask_selection = new QAction(QIcon::fromTheme("edit-node"), i18n("&Mask Selection"), this);
 +	action_unmask_selection = new QAction(QIcon::fromTheme("format-remove-node"), i18n("&Unmask Selection"), this);
 +	action_clear_selection = new QAction(QIcon::fromTheme("edit-clear"), i18n("Clea&r Selection"), this);
 +	action_select_all = new QAction(QIcon::fromTheme("edit-select-all"), i18n("Select All"), this);
 +
 +// 	action_set_formula = new QAction(QIcon::fromTheme(""), i18n("Assign &Formula"), this);
 +// 	action_recalculate = new QAction(QIcon::fromTheme(""), i18n("Recalculate"), this);
++	action_fill_sel_row_numbers = new QAction(QIcon::fromTheme(""), i18n("Row Numbers"), this);
 +	action_fill_row_numbers = new QAction(QIcon::fromTheme(""), i18n("Row Numbers"), this);
 +	action_fill_random = new QAction(QIcon::fromTheme(""), i18n("Uniform Random Values"), this);
 +	action_fill_random_nonuniform = new QAction(QIcon::fromTheme(""), i18n("Random Values"), this);
 +	action_fill_equidistant = new QAction(QIcon::fromTheme(""), i18n("Equidistant Values"), this);
 +	action_fill_function = new QAction(QIcon::fromTheme(""), i18n("Function Values"), this);
 +	action_fill_const = new QAction(QIcon::fromTheme(""), i18n("Const Values"), this);
  
  	//spreadsheet related actions
 -	action_toggle_comments = new KAction(KIcon("document-properties"), i18n("Show Comments"), this);
 -	action_add_column = new KAction(KIcon("edit-table-insert-column-left"), i18n("&Add Column"), this);
 -	action_clear_spreadsheet = new KAction(KIcon("edit-clear"), i18n("Clear Spreadsheet"), this);
 -	action_clear_masks = new KAction(KIcon("format-remove-node"), i18n("Clear Masks"), this);
 -	action_sort_spreadsheet = new KAction(KIcon("view-sort-ascending"), i18n("&Sort Spreadsheet"), this);
 -	action_go_to_cell = new KAction(KIcon("go-jump"), i18n("&Go to Cell"), this);
 -	action_statistics_all_columns = new KAction(KIcon("view-statistics"), i18n("Statisti&cs"), this );
 +	action_toggle_comments = new QAction(QIcon::fromTheme("document-properties"), i18n("Show Comments"), this);
 +	action_add_column = new QAction(QIcon::fromTheme("edit-table-insert-column-left"), i18n("&Add Column"), this);
 +	action_clear_spreadsheet = new QAction(QIcon::fromTheme("edit-clear"), i18n("Clear Spreadsheet"), this);
 +	action_clear_masks = new QAction(QIcon::fromTheme("format-remove-node"), i18n("Clear Masks"), this);
 +	action_sort_spreadsheet = new QAction(QIcon::fromTheme("view-sort-ascending"), i18n("&Sort Spreadsheet"), this);
 +	action_go_to_cell = new QAction(QIcon::fromTheme("go-jump"), i18n("&Go to Cell"), this);
 +	action_statistics_all_columns = new QAction(QIcon::fromTheme("view-statistics"), i18n("Statisti&cs"), this );
  
  	// column related actions
 -	action_insert_columns = new KAction(KIcon("edit-table-insert-column-left"), i18n("&Insert Empty Columns"), this);
 -	action_remove_columns = new KAction(KIcon("edit-table-delete-column"), i18n("Remo&ve Columns"), this);
 -	action_clear_columns = new KAction(KIcon("edit-clear"), i18n("Clea&r Columns"), this);
 -	action_add_columns = new KAction(KIcon("edit-table-insert-column-right"), i18n("&Add Columns"), this);
 -// 	action_set_as_x = new KAction(KIcon(""), i18n("X, Plot Designation"), this);
 -// 	action_set_as_y = new KAction(KIcon(""), i18n("Y, Plot Designation"), this);
 -// 	action_set_as_z = new KAction(KIcon(""), i18n("Z, Plot Designation"), this);
 -// 	action_set_as_xerr = new KAction(KIcon(""), i18n("X Error, Plot Designation"), this);
 -// 	action_set_as_yerr = new KAction(KIcon(""), i18n("Y Error, Plot Designation"), this);
 -// 	action_set_as_none = new KAction(KIcon(""), i18n("None, Plot Designation"), this);
 -	action_reverse_columns = new KAction(KIcon(""), i18n("Reverse"), this);
 -	action_drop_values = new KAction(KIcon(""), i18n("Drop Values"), this);
 -	action_mask_values = new KAction(KIcon(""), i18n("Mask Values"), this);
 -// 	action_join_columns = new KAction(KIcon(""), i18n("Join"), this);
 -	action_normalize_columns = new KAction(KIcon(""), i18n("&Normalize"), this);
 -	action_normalize_selection = new KAction(KIcon(""), i18n("&Normalize Selection"), this);
 -	action_sort_columns = new KAction(KIcon(""), i18n("&Selected Columns"), this);
 -	action_sort_asc_column = new KAction(KIcon("view-sort-ascending"), i18n("&Ascending"), this);
 -	action_sort_desc_column = new KAction(KIcon("view-sort-descending"), i18n("&Descending"), this);
 -	action_statistics_columns = new KAction(KIcon("view-statistics"), i18n("Column Statisti&cs"), this);
 +	action_insert_columns = new QAction(QIcon::fromTheme("edit-table-insert-column-left"), i18n("&Insert Empty Columns"), this);
 +	action_remove_columns = new QAction(QIcon::fromTheme("edit-table-delete-column"), i18n("Remo&ve Columns"), this);
 +	action_clear_columns = new QAction(QIcon::fromTheme("edit-clear"), i18n("Clea&r Columns"), this);
 +	action_add_columns = new QAction(QIcon::fromTheme("edit-table-insert-column-right"), i18n("&Add Columns"), this);
 +// 	action_set_as_x = new QAction(QIcon::fromTheme(""), i18n("X, Plot Designation"), this);
 +// 	action_set_as_y = new QAction(QIcon::fromTheme(""), i18n("Y, Plot Designation"), this);
 +// 	action_set_as_z = new QAction(QIcon::fromTheme(""), i18n("Z, Plot Designation"), this);
 +// 	action_set_as_xerr = new QAction(QIcon::fromTheme(""), i18n("X Error, Plot Designation"), this);
 +// 	action_set_as_yerr = new QAction(QIcon::fromTheme(""), i18n("Y Error, Plot Designation"), this);
 +// 	action_set_as_none = new QAction(QIcon::fromTheme(""), i18n("None, Plot Designation"), this);
 +	action_reverse_columns = new QAction(QIcon::fromTheme(""), i18n("Reverse"), this);
 +	action_drop_values = new QAction(QIcon::fromTheme(""), i18n("Drop Values"), this);
 +	action_mask_values = new QAction(QIcon::fromTheme(""), i18n("Mask Values"), this);
 +// 	action_join_columns = new QAction(QIcon::fromTheme(""), i18n("Join"), this);
 +	action_normalize_columns = new QAction(QIcon::fromTheme(""), i18n("&Normalize"), this);
 +	action_normalize_selection = new QAction(QIcon::fromTheme(""), i18n("&Normalize Selection"), this);
 +	action_sort_columns = new QAction(QIcon::fromTheme(""), i18n("&Selected Columns"), this);
 +	action_sort_asc_column = new QAction(QIcon::fromTheme("view-sort-ascending"), i18n("&Ascending"), this);
 +	action_sort_desc_column = new QAction(QIcon::fromTheme("view-sort-descending"), i18n("&Descending"), this);
 +	action_statistics_columns = new QAction(QIcon::fromTheme("view-statistics"), i18n("Column Statisti&cs"), this);
  
  	// row related actions
 -	action_insert_rows = new KAction(KIcon("edit-table-insert-row-above") ,i18n("&Insert Empty Rows"), this);
 -	action_remove_rows = new KAction(KIcon("edit-table-delete-row"), i18n("Remo&ve Rows"), this);
 -	action_clear_rows = new KAction(KIcon("edit-clear"), i18n("Clea&r Rows"), this);
 -	action_add_rows = new KAction(KIcon("edit-table-insert-row-above"), i18n("&Add Rows"), this);
 -	action_statistics_rows = new KAction(KIcon("view-statistics"), i18n("Row Statisti&cs"), this);
 +	action_insert_rows = new QAction(QIcon::fromTheme("edit-table-insert-row-above") ,i18n("&Insert Empty Rows"), this);
 +	action_remove_rows = new QAction(QIcon::fromTheme("edit-table-delete-row"), i18n("Remo&ve Rows"), this);
 +	action_clear_rows = new QAction(QIcon::fromTheme("edit-clear"), i18n("Clea&r Rows"), this);
 +	action_add_rows = new QAction(QIcon::fromTheme("edit-table-insert-row-above"), i18n("&Add Rows"), this);
 +	action_statistics_rows = new QAction(QIcon::fromTheme("view-statistics"), i18n("Row Statisti&cs"), this);
  }
  
  void SpreadsheetView::initMenus() {
diff --cc src/commonfrontend/worksheet/WorksheetView.cpp
index 6a1b3a0,88713b3..c944757
--- a/src/commonfrontend/worksheet/WorksheetView.cpp
+++ b/src/commonfrontend/worksheet/WorksheetView.cpp
@@@ -431,10 -431,11 +431,11 @@@ void WorksheetView::initMenus() 
  	m_cartesianPlotMenu->addSeparator();
  	m_cartesianPlotMenu->addMenu(m_cartesianPlotActionModeMenu);
  
- 	m_filterMenu = new QMenu(i18n("Filter"));
+ 	// Filter menu?
+ 	//m_filterMenu = new QMenu(i18n("Filter"));
  	//TODO: filter icon
- 	m_filterMenu->setIcon(QIcon::fromTheme("zoom-draw"));
- 	m_filterMenu->addAction(addFourierFilterAction);
 -	//m_filterMenu->setIcon(KIcon("zoom-draw"));
 -	//m_filterMenu->addAction(addFourierFilterAction);
++// 	m_filterMenu->setIcon(QIcon::fromTheme("zoom-draw"));
++// 	m_filterMenu->addAction(addFourierFilterAction);
  }
  
  /*!
diff --cc src/kdefrontend/dockwidgets/CartesianPlotDock.cpp
index 8b8a5b2,a6c36ca..88d06aa
--- a/src/kdefrontend/dockwidgets/CartesianPlotDock.cpp
+++ b/src/kdefrontend/dockwidgets/CartesianPlotDock.cpp
@@@ -171,87 -172,87 +173,87 @@@ CartesianPlotDock::~CartesianPlotDock(
  	delete m_completion;
  }
  
- void CartesianPlotDock::init(){
-     this->retranslateUi();
- 
-     //create icons for the different styles for scale breaking
-     QPainter pa;
-     pa.setPen( QPen(Qt::SolidPattern, 0) );
-     QPixmap pm(20, 20);
-     ui.cbXBreakStyle->setIconSize( QSize(20,20) );
-     ui.cbYBreakStyle->setIconSize( QSize(20,20) );
- 
-     //simple
-     pm.fill(Qt::transparent);
-     pa.begin( &pm );
-     pa.setRenderHint(QPainter::Antialiasing);
-     pa.setBrush(Qt::SolidPattern);
-     pa.drawLine(3,10,8,10);
-     pa.drawLine(12,10,17,10);
-     pa.end();
-     ui.cbXBreakStyle->setItemIcon(0, pm);
-     ui.cbYBreakStyle->setItemIcon(0, pm);
- 
-     //vertical
-     pm.fill(Qt::transparent);
-     pa.begin( &pm );
-     pa.setRenderHint(QPainter::Antialiasing);
-     pa.setBrush(Qt::SolidPattern);
-     pa.drawLine(3,10,8,10);
-     pa.drawLine(12,10,17,10);
-     pa.drawLine(8,14,8,6);
-     pa.drawLine(12,14,12,6);
-     pa.end();
-     ui.cbXBreakStyle->setItemIcon(1, pm);
-     ui.cbYBreakStyle->setItemIcon(1, pm);
- 
-     //sloped
-     pm.fill(Qt::transparent);
-     pa.begin( &pm );
-     pa.setRenderHint(QPainter::Antialiasing);
-     pa.setBrush(Qt::SolidPattern);
-     pa.drawLine(3,10,8,10);
-     pa.drawLine(12,10,17,10);
-     pa.drawLine(6,14,10,6);
-     pa.drawLine(10,14,14,6);
-     pa.end();
-     ui.cbXBreakStyle->setItemIcon(2, pm);
-     ui.cbYBreakStyle->setItemIcon(2, pm);
- }
- 
- void CartesianPlotDock::setPlots(QList<CartesianPlot*> list){
-     m_initializing = true;
-     m_plotList = list;
+ void CartesianPlotDock::init() {
+ 	this->retranslateUi();
+ 
+ 	//create icons for the different styles for scale breaking
+ 	QPainter pa;
+ 	pa.setPen( QPen(Qt::SolidPattern, 0) );
+ 	QPixmap pm(20, 20);
+ 	ui.cbXBreakStyle->setIconSize( QSize(20,20) );
+ 	ui.cbYBreakStyle->setIconSize( QSize(20,20) );
+ 
+ 	//simple
+ 	pm.fill(Qt::transparent);
+ 	pa.begin( &pm );
+ 	pa.setRenderHint(QPainter::Antialiasing);
+ 	pa.setBrush(Qt::SolidPattern);
+ 	pa.drawLine(3,10,8,10);
+ 	pa.drawLine(12,10,17,10);
+ 	pa.end();
+ 	ui.cbXBreakStyle->setItemIcon(0, pm);
+ 	ui.cbYBreakStyle->setItemIcon(0, pm);
+ 
+ 	//vertical
+ 	pm.fill(Qt::transparent);
+ 	pa.begin( &pm );
+ 	pa.setRenderHint(QPainter::Antialiasing);
+ 	pa.setBrush(Qt::SolidPattern);
+ 	pa.drawLine(3,10,8,10);
+ 	pa.drawLine(12,10,17,10);
+ 	pa.drawLine(8,14,8,6);
+ 	pa.drawLine(12,14,12,6);
+ 	pa.end();
+ 	ui.cbXBreakStyle->setItemIcon(1, pm);
+ 	ui.cbYBreakStyle->setItemIcon(1, pm);
+ 
+ 	//sloped
+ 	pm.fill(Qt::transparent);
+ 	pa.begin( &pm );
+ 	pa.setRenderHint(QPainter::Antialiasing);
+ 	pa.setBrush(Qt::SolidPattern);
+ 	pa.drawLine(3,10,8,10);
+ 	pa.drawLine(12,10,17,10);
+ 	pa.drawLine(6,14,10,6);
+ 	pa.drawLine(10,14,14,6);
+ 	pa.end();
+ 	ui.cbXBreakStyle->setItemIcon(2, pm);
+ 	ui.cbYBreakStyle->setItemIcon(2, pm);
+ }
+ 
+ void CartesianPlotDock::setPlots(QList<CartesianPlot*> list) {
+ 	m_initializing = true;
+ 	m_plotList = list;
  
 -	m_plot=list.first();
 +    m_plot=list.first();
  
 -	QList<TextLabel*> labels;
 -	foreach(CartesianPlot* plot, list)
 -		labels.append(plot->title());
 +    QList<TextLabel*> labels;
 +    foreach(CartesianPlot* plot, list)
 +        labels.append(plot->title());
  
 -	labelWidget->setLabels(labels);
 +    labelWidget->setLabels(labels);
  
  	//if there is more then one plot in the list, disable the name and comment fields in the tab "general"
- 	if (list.size()==1){
+ 	if (list.size()==1) {
  		ui.lName->setEnabled(true);
  		ui.leName->setEnabled(true);
  		ui.lComment->setEnabled(true);
  		ui.leComment->setEnabled(true);
  
-         ui.leName->setText(m_plot->name());
-         ui.leComment->setText(m_plot->comment());
-     }else{
-         ui.lName->setEnabled(false);
-         ui.leName->setEnabled(false);
-         ui.lComment->setEnabled(false);
-         ui.leComment->setEnabled(false);
+ 		ui.leName->setText(m_plot->name());
+ 		ui.leComment->setText(m_plot->comment());
+ 	} else {
+ 		ui.lName->setEnabled(false);
+ 		ui.leName->setEnabled(false);
+ 		ui.lComment->setEnabled(false);
+ 		ui.leComment->setEnabled(false);
  
 -		ui.leName->setText("");
 -		ui.leComment->setText("");
 -	}
 +        ui.leName->setText("");
 +        ui.leComment->setText("");
 +    }
  
  	//show the properties of the first plot
-   	this->load();
+ 	this->load();
  
  	//update active widgets
  	backgroundTypeChanged(ui.cbBackgroundType->currentIndex());
@@@ -308,193 -313,184 +314,184 @@@ void CartesianPlotDock::activateTitleTa
  //************************************************************
  //**** SLOTs for changes triggered in CartesianPlotDock ******
  //************************************************************
- void CartesianPlotDock::retranslateUi(){
-     m_initializing = true;
+ void CartesianPlotDock::retranslateUi() {
+ 	m_initializing = true;
  
 -	//general
 -	ui.cbXScaling->addItem( i18n("linear") );
 -	ui.cbXScaling->addItem( i18n("log(x)") );
 -	ui.cbXScaling->addItem( i18n("log2(x)") );
 -	ui.cbXScaling->addItem( i18n("ln(x)") );
 -
 -	ui.cbYScaling->addItem( i18n("linear") );
 -	ui.cbYScaling->addItem( i18n("log(y)") );
 -	ui.cbYScaling->addItem( i18n("log2(y)") );
 -	ui.cbYScaling->addItem( i18n("ln(y)") );
 -
 -	//scale breakings
 -	ui.cbXBreakStyle->addItem( i18n("simple") );
 -	ui.cbXBreakStyle->addItem( i18n("vertical") );
 -	ui.cbXBreakStyle->addItem( i18n("sloped") );
 -
 -	ui.cbYBreakStyle->addItem( i18n("simple") );
 -	ui.cbYBreakStyle->addItem( i18n("vertical") );
 -	ui.cbYBreakStyle->addItem( i18n("sloped") );
 -
 -	//plot area
 -	ui.cbBackgroundType->addItem(i18n("color"));
 -	ui.cbBackgroundType->addItem(i18n("image"));
 -	ui.cbBackgroundType->addItem(i18n("pattern"));
 -
 -	ui.cbBackgroundColorStyle->addItem(i18n("single color"));
 -	ui.cbBackgroundColorStyle->addItem(i18n("horizontal linear gradient"));
 -	ui.cbBackgroundColorStyle->addItem(i18n("vertical linear gradient"));
 -	ui.cbBackgroundColorStyle->addItem(i18n("diagonal linear gradient (start from top left)"));
 -	ui.cbBackgroundColorStyle->addItem(i18n("diagonal linear gradient (start from bottom left)"));
 -	ui.cbBackgroundColorStyle->addItem(i18n("radial gradient"));
 -
 -	ui.cbBackgroundImageStyle->addItem(i18n("scaled and cropped"));
 -	ui.cbBackgroundImageStyle->addItem(i18n("scaled"));
 -	ui.cbBackgroundImageStyle->addItem(i18n("scaled, keep proportions"));
 -	ui.cbBackgroundImageStyle->addItem(i18n("centered"));
 -	ui.cbBackgroundImageStyle->addItem(i18n("tiled"));
 -	ui.cbBackgroundImageStyle->addItem(i18n("center tiled"));
 -
 -	GuiTools::updatePenStyles(ui.cbBorderStyle, Qt::black);
 -	GuiTools::updateBrushStyles(ui.cbBackgroundBrushStyle, Qt::SolidPattern);
 +    //general
 +    ui.cbXScaling->addItem( i18n("linear") );
 +    ui.cbXScaling->addItem( i18n("log(x)") );
 +    ui.cbXScaling->addItem( i18n("log2(x)") );
 +    ui.cbXScaling->addItem( i18n("ln(x)") );
  
 -	m_initializing = false;
 +    ui.cbYScaling->addItem( i18n("linear") );
 +    ui.cbYScaling->addItem( i18n("log(y)") );
 +    ui.cbYScaling->addItem( i18n("log2(y)") );
 +    ui.cbYScaling->addItem( i18n("ln(y)") );
 +
 +    //scale breakings
 +    ui.cbXBreakStyle->addItem( i18n("simple") );
 +    ui.cbXBreakStyle->addItem( i18n("vertical") );
 +    ui.cbXBreakStyle->addItem( i18n("sloped") );
 +
 +    ui.cbYBreakStyle->addItem( i18n("simple") );
 +    ui.cbYBreakStyle->addItem( i18n("vertical") );
 +    ui.cbYBreakStyle->addItem( i18n("sloped") );
 +
 +    //plot area
 +    ui.cbBackgroundType->addItem(i18n("color"));
 +    ui.cbBackgroundType->addItem(i18n("image"));
 +    ui.cbBackgroundType->addItem(i18n("pattern"));
 +
 +    ui.cbBackgroundColorStyle->addItem(i18n("single color"));
 +    ui.cbBackgroundColorStyle->addItem(i18n("horizontal linear gradient"));
 +    ui.cbBackgroundColorStyle->addItem(i18n("vertical linear gradient"));
 +    ui.cbBackgroundColorStyle->addItem(i18n("diagonal linear gradient (start from top left)"));
 +    ui.cbBackgroundColorStyle->addItem(i18n("diagonal linear gradient (start from bottom left)"));
 +    ui.cbBackgroundColorStyle->addItem(i18n("radial gradient"));
 +
 +    ui.cbBackgroundImageStyle->addItem(i18n("scaled and cropped"));
 +    ui.cbBackgroundImageStyle->addItem(i18n("scaled"));
 +    ui.cbBackgroundImageStyle->addItem(i18n("scaled, keep proportions"));
 +    ui.cbBackgroundImageStyle->addItem(i18n("centered"));
 +    ui.cbBackgroundImageStyle->addItem(i18n("tiled"));
 +    ui.cbBackgroundImageStyle->addItem(i18n("center tiled"));
 +
 +    GuiTools::updatePenStyles(ui.cbBorderStyle, Qt::black);
 +    GuiTools::updateBrushStyles(ui.cbBackgroundBrushStyle, Qt::SolidPattern);
 +
 +    m_initializing = false;
  }
  
  // "General"-tab
- void CartesianPlotDock::nameChanged(){
-   if (m_initializing)
-     return;
+ void CartesianPlotDock::nameChanged() {
+ 	if (m_initializing)
+ 		return;
  
-   m_plot->setName(ui.leName->text());
+ 	m_plot->setName(ui.leName->text());
  }
  
- void CartesianPlotDock::commentChanged(){
-   if (m_initializing)
-     return;
+ void CartesianPlotDock::commentChanged() {
+ 	if (m_initializing)
+ 		return;
  
-   m_plot->setComment(ui.leComment->text());
+ 	m_plot->setComment(ui.leComment->text());
  }
  
- void CartesianPlotDock::visibilityChanged(bool state){
-     if (m_initializing)
-             return;
+ void CartesianPlotDock::visibilityChanged(bool state) {
+ 	if (m_initializing)
+ 		return;
  
 -	foreach(CartesianPlot* plot, m_plotList)
 -		plot->setVisible(state);
 +    foreach(CartesianPlot* plot, m_plotList)
 +            plot->setVisible(state);
  }
  
- void CartesianPlotDock::geometryChanged(){
-     if (m_initializing)
-         return;
+ void CartesianPlotDock::geometryChanged() {
+ 	if (m_initializing)
+ 		return;
  
 -	float x = Worksheet::convertToSceneUnits(ui.sbLeft->value(), Worksheet::Centimeter);
 -	float y = Worksheet::convertToSceneUnits(ui.sbTop->value(), Worksheet::Centimeter);
 -	float w = Worksheet::convertToSceneUnits(ui.sbWidth->value(), Worksheet::Centimeter);
 -	float h = Worksheet::convertToSceneUnits(ui.sbHeight->value(), Worksheet::Centimeter);
 +    float x = Worksheet::convertToSceneUnits(ui.sbLeft->value(), Worksheet::Centimeter);
 +    float y = Worksheet::convertToSceneUnits(ui.sbTop->value(), Worksheet::Centimeter);
 +    float w = Worksheet::convertToSceneUnits(ui.sbWidth->value(), Worksheet::Centimeter);
 +    float h = Worksheet::convertToSceneUnits(ui.sbHeight->value(), Worksheet::Centimeter);
  
 -	QRectF rect(x,y,w,h);
 -	m_plot->setRect(rect);
 +    QRectF rect(x,y,w,h);
 +    m_plot->setRect(rect);
  }
  
  /*!
 -	Called when the layout in the worksheet gets changed.
 -	Enables/disables the geometry widgets if the layout was deactivated/activated.
 -	Shows the new geometry values of the first plot if the layout was activated.
 +    Called when the layout in the worksheet gets changed.
 +    Enables/disables the geometry widgets if the layout was deactivated/activated.
 +    Shows the new geometry values of the first plot if the layout was activated.
   */
- void CartesianPlotDock::layoutChanged(Worksheet::Layout layout){
-     bool b = (layout == Worksheet::NoLayout);
-     ui.sbTop->setEnabled(b);
-     ui.sbLeft->setEnabled(b);
-     ui.sbWidth->setEnabled(b);
-     ui.sbHeight->setEnabled(b);
-     if (!b){
-         m_initializing = true;
-         ui.sbLeft->setValue(Worksheet::convertFromSceneUnits(m_plot->rect().x(), Worksheet::Centimeter));
-         ui.sbTop->setValue(Worksheet::convertFromSceneUnits(m_plot->rect().y(), Worksheet::Centimeter));
-         ui.sbWidth->setValue(Worksheet::convertFromSceneUnits(m_plot->rect().width(), Worksheet::Centimeter));
-         ui.sbHeight->setValue(Worksheet::convertFromSceneUnits(m_plot->rect().height(), Worksheet::Centimeter));
-         m_initializing = false;
-     }
+ void CartesianPlotDock::layoutChanged(Worksheet::Layout layout) {
+ 	bool b = (layout == Worksheet::NoLayout);
+ 	ui.sbTop->setEnabled(b);
+ 	ui.sbLeft->setEnabled(b);
+ 	ui.sbWidth->setEnabled(b);
+ 	ui.sbHeight->setEnabled(b);
  }
  
- 
- void CartesianPlotDock::autoScaleXChanged(int state){
-     bool checked = (state==Qt::Checked);
-     ui.kleXMin->setEnabled(!checked);
-     ui.kleXMax->setEnabled(!checked);
+ void CartesianPlotDock::autoScaleXChanged(int state) {
+ 	bool checked = (state==Qt::Checked);
+ 	ui.kleXMin->setEnabled(!checked);
+ 	ui.kleXMax->setEnabled(!checked);
  
 -	if (m_initializing)
 -		return;
 +    if (m_initializing)
 +        return;
  
 -	foreach(CartesianPlot* plot, m_plotList)
 -		plot->setAutoScaleX(checked);
 +    foreach(CartesianPlot* plot, m_plotList)
 +        plot->setAutoScaleX(checked);
  }
  
- void CartesianPlotDock::xMinChanged(){
-     if (m_initializing)
-         return;
+ void CartesianPlotDock::xMinChanged() {
+ 	if (m_initializing)
+ 		return;
  
 -	float value = ui.kleXMin->text().toDouble();
 -	foreach(CartesianPlot* plot, m_plotList)
 -		plot->setXMin(value);
 +    float value = ui.kleXMin->text().toDouble();
 +    foreach(CartesianPlot* plot, m_plotList)
 +        plot->setXMin(value);
  }
  
- void CartesianPlotDock::xMaxChanged(){
-     if (m_initializing)
-         return;
+ void CartesianPlotDock::xMaxChanged() {
+ 	if (m_initializing)
+ 		return;
  
 -	float value = ui.kleXMax->text().toDouble();
 -	foreach(CartesianPlot* plot, m_plotList)
 -		plot->setXMax(value);
 +    float value = ui.kleXMax->text().toDouble();
 +    foreach(CartesianPlot* plot, m_plotList)
 +        plot->setXMax(value);
  }
  
  /*!
 -	called on scale changes (linear, log) for the x-axis
 +    called on scale changes (linear, log) for the x-axis
   */
- void CartesianPlotDock::xScaleChanged(int scale){
-   if (m_initializing)
-     return;
+ void CartesianPlotDock::xScaleChanged(int scale) {
+ 	if (m_initializing)
+ 		return;
  
-   foreach(CartesianPlot* plot, m_plotList)
-     plot->setXScale((CartesianPlot::Scale) scale);
+ 	foreach(CartesianPlot* plot, m_plotList)
+ 		plot->setXScale((CartesianPlot::Scale) scale);
  }
  
- void CartesianPlotDock::autoScaleYChanged(int state){
-     bool checked = (state==Qt::Checked);
-     ui.kleYMin->setEnabled(!checked);
-     ui.kleYMax->setEnabled(!checked);
+ void CartesianPlotDock::autoScaleYChanged(int state) {
+ 	bool checked = (state==Qt::Checked);
+ 	ui.kleYMin->setEnabled(!checked);
+ 	ui.kleYMax->setEnabled(!checked);
  
 -	if (m_initializing)
 -		return;
 +    if (m_initializing)
 +        return;
  
 -	foreach(CartesianPlot* plot, m_plotList)
 -		plot->setAutoScaleY(checked);
 +    foreach(CartesianPlot* plot, m_plotList)
 +        plot->setAutoScaleY(checked);
  }
  
- void CartesianPlotDock::yMinChanged(){
-     if (m_initializing)
-         return;
+ void CartesianPlotDock::yMinChanged() {
+ 	if (m_initializing)
+ 		return;
  
 -	float value = ui.kleYMin->text().toDouble();
 -	foreach(CartesianPlot* plot, m_plotList)
 -		plot->setYMin(value);
 +    float value = ui.kleYMin->text().toDouble();
 +    foreach(CartesianPlot* plot, m_plotList)
 +        plot->setYMin(value);
  }
  
- void CartesianPlotDock::yMaxChanged(){
-     if (m_initializing)
-         return;
+ void CartesianPlotDock::yMaxChanged() {
+ 	if (m_initializing)
+ 		return;
  
 -	float value = ui.kleYMax->text().toDouble();
 -	foreach(CartesianPlot* plot, m_plotList)
 -		plot->setYMax(value);
 +    float value = ui.kleYMax->text().toDouble();
 +    foreach(CartesianPlot* plot, m_plotList)
 +        plot->setYMax(value);
  }
  
  /*!
 -	called on scale changes (linear, log) for the y-axis
 +    called on scale changes (linear, log) for the y-axis
   */
- void CartesianPlotDock::yScaleChanged(int index){
-   if (m_initializing)
-     return;
+ void CartesianPlotDock::yScaleChanged(int index) {
+ 	if (m_initializing)
+ 		return;
  
-   CartesianPlot::Scale scale = (CartesianPlot::Scale)index;
-   foreach(CartesianPlot* plot, m_plotList)
-     plot->setYScale(scale);
+ 	CartesianPlot::Scale scale = (CartesianPlot::Scale)index;
+ 	foreach(CartesianPlot* plot, m_plotList)
+ 		plot->setYScale(scale);
  }
  
  // "Range Breaks"-tab
@@@ -702,50 -816,45 +817,45 @@@ void CartesianPlotDock::backgroundColor
  		ui.cbBackgroundBrushStyle->hide();
  	}
  
 -	if (m_initializing)
 -		return;
 +    if (m_initializing)
 +        return;
  
-     foreach(CartesianPlot* plot, m_plotList){
-         plot->plotArea()->setBackgroundColorStyle(style);
-   }
+ 	foreach(CartesianPlot* plot, m_plotList)
+ 		plot->plotArea()->setBackgroundColorStyle(style);
  }
  
- void CartesianPlotDock::backgroundImageStyleChanged(int index){
-     if (m_initializing)
-         return;
+ void CartesianPlotDock::backgroundImageStyleChanged(int index) {
+ 	if (m_initializing)
+ 		return;
  
-     PlotArea::BackgroundImageStyle style = (PlotArea::BackgroundImageStyle)index;
-     foreach(CartesianPlot* plot, m_plotList){
-         plot->plotArea()->setBackgroundImageStyle(style);
-   }
+ 	PlotArea::BackgroundImageStyle style = (PlotArea::BackgroundImageStyle)index;
+ 	foreach(CartesianPlot* plot, m_plotList)
+ 		plot->plotArea()->setBackgroundImageStyle(style);
  }
  
- void CartesianPlotDock::backgroundBrushStyleChanged(int index){
-     if (m_initializing)
-         return;
+ void CartesianPlotDock::backgroundBrushStyleChanged(int index) {
+ 	if (m_initializing)
+ 		return;
  
-     Qt::BrushStyle style = (Qt::BrushStyle)index;
-     foreach(CartesianPlot* plot, m_plotList){
-         plot->plotArea()->setBackgroundBrushStyle(style);
-   }
+ 	Qt::BrushStyle style = (Qt::BrushStyle)index;
+ 	foreach(CartesianPlot* plot, m_plotList)
+ 		plot->plotArea()->setBackgroundBrushStyle(style);
  }
  
- void CartesianPlotDock::backgroundFirstColorChanged(const QColor& c){
-   if (m_initializing)
-     return;
+ void CartesianPlotDock::backgroundFirstColorChanged(const QColor& c) {
+ 	if (m_initializing)
+ 		return;
  
-   foreach(CartesianPlot* plot, m_plotList){
-     plot->plotArea()->setBackgroundFirstColor(c);
-   }
+ 	foreach(CartesianPlot* plot, m_plotList)
+ 		plot->plotArea()->setBackgroundFirstColor(c);
  }
  
- void CartesianPlotDock::backgroundSecondColorChanged(const QColor& c){
-   if (m_initializing)
-     return;
+ void CartesianPlotDock::backgroundSecondColorChanged(const QColor& c) {
+ 	if (m_initializing)
+ 		return;
  
-   foreach(CartesianPlot* plot, m_plotList){
-     plot->plotArea()->setBackgroundSecondColor(c);
-   }
+ 	foreach(CartesianPlot* plot, m_plotList)
+ 		plot->plotArea()->setBackgroundSecondColor(c);
  }
  
  /*!
@@@ -762,114 -871,113 +872,113 @@@ void CartesianPlotDock::selectFile() 
  	}
  
  	QString path = QFileDialog::getOpenFileName(this, i18n("Select the image file"), dir, i18n("Images (%1)", formats));
-     if (path.isEmpty())
-         return; //cancel was clicked in the file-dialog
+ 	if (path.isEmpty())
+ 		return; //cancel was clicked in the file-dialog
  
 -	int pos = path.lastIndexOf(QDir::separator());
 -	if (pos!=-1) {
 -		QString newDir = path.left(pos);
 -		if (newDir!=dir)
 -			conf.writeEntry("LastImageDir", newDir);
 -	}
 +    int pos = path.lastIndexOf(QDir::separator());
 +    if (pos!=-1) {
 +        QString newDir = path.left(pos);
 +        if (newDir!=dir)
 +            conf.writeEntry("LastImageDir", newDir);
 +    }
  
-     ui.kleBackgroundFileName->setText( path );
+ 	ui.kleBackgroundFileName->setText( path );
  
 -	foreach(CartesianPlot* plot, m_plotList)
 -		plot->plotArea()->setBackgroundFileName(path);
 +    foreach(CartesianPlot* plot, m_plotList)
 +        plot->plotArea()->setBackgroundFileName(path);
  }
  
- void CartesianPlotDock::fileNameChanged(){
-     if (m_initializing)
-         return;
+ void CartesianPlotDock::fileNameChanged() {
+ 	if (m_initializing)
+ 		return;
  
-     QString fileName = ui.kleBackgroundFileName->text();
-     foreach(CartesianPlot* plot, m_plotList){
-         plot->plotArea()->setBackgroundFileName(fileName);
-   }
+ 	QString fileName = ui.kleBackgroundFileName->text();
+ 	foreach(CartesianPlot* plot, m_plotList)
+ 		plot->plotArea()->setBackgroundFileName(fileName);
  }
  
- void CartesianPlotDock::backgroundOpacityChanged(int value){
-     if (m_initializing)
-         return;
+ void CartesianPlotDock::backgroundOpacityChanged(int value) {
+ 	if (m_initializing)
+ 		return;
  
 -	qreal opacity = (float)value/100.;
 -	foreach(CartesianPlot* plot, m_plotList)
 -		plot->plotArea()->setBackgroundOpacity(opacity);
 +    qreal opacity = (float)value/100.;
 +    foreach(CartesianPlot* plot, m_plotList)
 +        plot->plotArea()->setBackgroundOpacity(opacity);
  }
  
  // "Border"-tab
- void CartesianPlotDock::borderStyleChanged(int index){
-    if (m_initializing)
-     return;
+ void CartesianPlotDock::borderStyleChanged(int index) {
+ 	if (m_initializing)
+ 		return;
  
-   Qt::PenStyle penStyle=Qt::PenStyle(index);
-   QPen pen;
-   foreach(CartesianPlot* plot, m_plotList){
-     pen=plot->plotArea()->borderPen();
-     pen.setStyle(penStyle);
-     plot->plotArea()->setBorderPen(pen);
-   }
+ 	Qt::PenStyle penStyle=Qt::PenStyle(index);
+ 	QPen pen;
+ 	foreach(CartesianPlot* plot, m_plotList) {
+ 		pen=plot->plotArea()->borderPen();
+ 		pen.setStyle(penStyle);
+ 		plot->plotArea()->setBorderPen(pen);
+ 	}
  }
  
- void CartesianPlotDock::borderColorChanged(const QColor& color){
-   if (m_initializing)
-     return;
+ void CartesianPlotDock::borderColorChanged(const QColor& color) {
+ 	if (m_initializing)
+ 		return;
  
-   QPen pen;
-   foreach(CartesianPlot* plot, m_plotList){
-     pen=plot->plotArea()->borderPen();
-     pen.setColor(color);
-     plot->plotArea()->setBorderPen(pen);
-   }
+ 	QPen pen;
+ 	foreach(CartesianPlot* plot, m_plotList) {
+ 		pen=plot->plotArea()->borderPen();
+ 		pen.setColor(color);
+ 		plot->plotArea()->setBorderPen(pen);
+ 	}
  
-   m_initializing=true;
-   GuiTools::updatePenStyles(ui.cbBorderStyle, color);
-   m_initializing=false;
+ 	m_initializing=true;
+ 	GuiTools::updatePenStyles(ui.cbBorderStyle, color);
+ 	m_initializing=false;
  }
  
- void CartesianPlotDock::borderWidthChanged(double value){
-   if (m_initializing)
-     return;
+ void CartesianPlotDock::borderWidthChanged(double value) {
+ 	if (m_initializing)
+ 		return;
  
-   QPen pen;
-   foreach(CartesianPlot* plot, m_plotList){
-     pen=plot->plotArea()->borderPen();
-     pen.setWidthF( Worksheet::convertToSceneUnits(value, Worksheet::Point) );
-     plot->plotArea()->setBorderPen(pen);
-   }
+ 	QPen pen;
+ 	foreach(CartesianPlot* plot, m_plotList) {
+ 		pen=plot->plotArea()->borderPen();
+ 		pen.setWidthF( Worksheet::convertToSceneUnits(value, Worksheet::Point) );
+ 		plot->plotArea()->setBorderPen(pen);
+ 	}
  }
  
- void CartesianPlotDock::borderCornerRadiusChanged(double value){
-     if (m_initializing)
-         return;
+ void CartesianPlotDock::borderCornerRadiusChanged(double value) {
+ 	if (m_initializing)
+ 		return;
  
 -	foreach(CartesianPlot* plot, m_plotList)
 -		plot->plotArea()->setBorderCornerRadius(Worksheet::convertToSceneUnits(value, Worksheet::Centimeter));
 +    foreach(CartesianPlot* plot, m_plotList)
 +        plot->plotArea()->setBorderCornerRadius(Worksheet::convertToSceneUnits(value, Worksheet::Centimeter));
  }
  
- void CartesianPlotDock::borderOpacityChanged(int value){
-     if (m_initializing)
-         return;
+ void CartesianPlotDock::borderOpacityChanged(int value) {
+ 	if (m_initializing)
+ 		return;
  
 -	qreal opacity = (float)value/100.;
 -	foreach(CartesianPlot* plot, m_plotList)
 -		plot->plotArea()->setBorderOpacity(opacity);
 +    qreal opacity = (float)value/100.;
 +    foreach(CartesianPlot* plot, m_plotList)
 +        plot->plotArea()->setBorderOpacity(opacity);
  }
  
- void CartesianPlotDock::horizontalPaddingChanged(double value){
-   if (m_initializing)
-     return;
+ void CartesianPlotDock::horizontalPaddingChanged(double value) {
+ 	if (m_initializing)
+ 		return;
  
-   foreach(CartesianPlot* plot, m_plotList)
-     plot->setHorizontalPadding(Worksheet::convertToSceneUnits(value, Worksheet::Centimeter));
+ 	foreach(CartesianPlot* plot, m_plotList)
+ 		plot->setHorizontalPadding(Worksheet::convertToSceneUnits(value, Worksheet::Centimeter));
  }
  
- void CartesianPlotDock::verticalPaddingChanged(double value){
-   if (m_initializing)
-     return;
+ void CartesianPlotDock::verticalPaddingChanged(double value) {
+ 	if (m_initializing)
+ 		return;
  
-   foreach(CartesianPlot* plot, m_plotList)
-     plot->setVerticalPadding(Worksheet::convertToSceneUnits(value, Worksheet::Centimeter));
+ 	foreach(CartesianPlot* plot, m_plotList)
+ 		plot->setVerticalPadding(Worksheet::convertToSceneUnits(value, Worksheet::Centimeter));
  }
  
  //*************************************************************
@@@ -877,25 -985,25 +986,25 @@@
  //*************************************************************
  //general
  void CartesianPlotDock::plotDescriptionChanged(const AbstractAspect* aspect) {
 -	if (m_plot != aspect)
 -		return;
 +    if (m_plot != aspect)
 +        return;
  
 -	m_initializing = true;
 -	if (aspect->name() != ui.leName->text()) {
 -		ui.leName->setText(aspect->name());
 -	} else if (aspect->comment() != ui.leComment->text()) {
 -		ui.leComment->setText(aspect->comment());
 -	}
 -	m_initializing = false;
 +    m_initializing = true;
 +    if (aspect->name() != ui.leName->text()) {
 +        ui.leName->setText(aspect->name());
 +    } else if (aspect->comment() != ui.leComment->text()) {
 +        ui.leComment->setText(aspect->comment());
 +    }
 +    m_initializing = false;
  }
  
- void CartesianPlotDock::plotRectChanged(QRectF& rect){
-     m_initializing = true;
-     ui.sbLeft->setValue(Worksheet::convertFromSceneUnits(rect.x(), Worksheet::Centimeter));
-     ui.sbTop->setValue(Worksheet::convertFromSceneUnits(rect.y(), Worksheet::Centimeter));
-     ui.sbWidth->setValue(Worksheet::convertFromSceneUnits(rect.width(), Worksheet::Centimeter));
-     ui.sbHeight->setValue(Worksheet::convertFromSceneUnits(rect.height(), Worksheet::Centimeter));
-     m_initializing = false;
+ void CartesianPlotDock::plotRectChanged(QRectF& rect) {
+ 	m_initializing = true;
+ 	ui.sbLeft->setValue(Worksheet::convertFromSceneUnits(rect.x(), Worksheet::Centimeter));
+ 	ui.sbTop->setValue(Worksheet::convertFromSceneUnits(rect.y(), Worksheet::Centimeter));
+ 	ui.sbWidth->setValue(Worksheet::convertFromSceneUnits(rect.width(), Worksheet::Centimeter));
+ 	ui.sbHeight->setValue(Worksheet::convertFromSceneUnits(rect.height(), Worksheet::Centimeter));
+ 	m_initializing = false;
  }
  
  void CartesianPlotDock::plotXAutoScaleChanged(bool value) {
@@@ -1051,26 -1170,26 +1171,26 @@@ void CartesianPlotDock::plotVerticalPad
  //******************** SETTINGS *******************************
  //*************************************************************
  void CartesianPlotDock::loadConfigFromTemplate(KConfig& config) {
 -	//extract the name of the template from the file name
 -	QString name;
 -	int index = config.name().lastIndexOf(QDir::separator());
 -	if (index!=-1)
 -		name = config.name().right(config.name().size() - index - 1);
 -	else
 -		name = config.name();
 +    //extract the name of the template from the file name
 +    QString name;
 +    int index = config.name().lastIndexOf(QDir::separator());
 +    if (index!=-1)
 +        name = config.name().right(config.name().size() - index - 1);
 +    else
 +        name = config.name();
  
 -	int size = m_plotList.size();
 -	if (size>1)
 -		m_plot->beginMacro(i18n("%1 cartesian plots: template \"%2\" loaded", size, name));
 -	else
 -		m_plot->beginMacro(i18n("%1: template \"%2\" loaded", m_plot->name(), name));
 +    int size = m_plotList.size();
 +    if (size>1)
 +        m_plot->beginMacro(i18n("%1 cartesian plots: template \"%2\" loaded", size, name));
 +    else
 +        m_plot->beginMacro(i18n("%1: template \"%2\" loaded", m_plot->name(), name));
  
 -	this->loadConfig(config);
 +    this->loadConfig(config);
  
 -	m_plot->endMacro();
 +    m_plot->endMacro();
  }
  
- void CartesianPlotDock::load(){
+ void CartesianPlotDock::load() {
  	//General-tab
  	ui.chkVisible->setChecked(m_plot->isVisible());
  	ui.sbLeft->setValue(Worksheet::convertFromSceneUnits(m_plot->rect().x(), Worksheet::Centimeter));
@@@ -1154,59 -1263,59 +1264,59 @@@
  	m_initializing=false;
  }
  
- void CartesianPlotDock::loadConfig(KConfig& config){
- //  KConfigGroup group = config.group( "CartesianPlot" );
+ void CartesianPlotDock::loadConfig(KConfig& config) {
+ // 	KConfigGroup group = config.group( "CartesianPlot" );
  
-     //General-tab
-     //TODO: decide whether to load properties, not related to the appearance/style of the plot.
-     //most probably we don't want: when loading a new template we only want to change the style of the plot
-     //and not the plot region that depends on the data currently shown in the plot.
- //  ui.chkVisible->setChecked( group.readEntry("Visible", m_plot->isVisible()) );
- //  ui.sbLeft->setValue(Worksheet::convertFromSceneUnits(group.readEntry("Left", m_plot->rect().x()), Worksheet::Centimeter));
- //  ui.sbTop->setValue(Worksheet::convertFromSceneUnits(group.readEntry("Top", m_plot->rect().y()), Worksheet::Centimeter));
- //  ui.sbWidth->setValue(Worksheet::convertFromSceneUnits(group.readEntry("Width", m_plot->rect().width()), Worksheet::Centimeter));
- //  ui.sbHeight->setValue(Worksheet::convertFromSceneUnits(group.readEntry("Height", m_plot->rect().height()), Worksheet::Centimeter));
+ 	//General-tab
+ 	//TODO: decide whether to load properties, not related to the appearance/style of the plot.
+ 	//most probably we don't want: when loading a new template we only want to change the style of the plot
+ 	//and not the plot region that depends on the data currently shown in the plot.
+ // 	ui.chkVisible->setChecked( group.readEntry("Visible", m_plot->isVisible()) );
+ // 	ui.sbLeft->setValue(Worksheet::convertFromSceneUnits(group.readEntry("Left", m_plot->rect().x()), Worksheet::Centimeter));
+ // 	ui.sbTop->setValue(Worksheet::convertFromSceneUnits(group.readEntry("Top", m_plot->rect().y()), Worksheet::Centimeter));
+ // 	ui.sbWidth->setValue(Worksheet::convertFromSceneUnits(group.readEntry("Width", m_plot->rect().width()), Worksheet::Centimeter));
+ // 	ui.sbHeight->setValue(Worksheet::convertFromSceneUnits(group.readEntry("Height", m_plot->rect().height()), Worksheet::Centimeter));
  //
 -// 	ui.chkAutoScaleX->setChecked(group.readEntry("AutoScaleX", m_plot->autoScaleX()));
 -//   	ui.kleXMin->setText( QString::number( group.readEntry("xMin", m_plot->xMin())) );
 -// 	ui.kleXMax->setText( QString::number( group.readEntry("xMax", m_plot->xMax())) );
 -// 	ui.cbXScaling->setCurrentIndex( group.readEntry("xScale", (int) m_plot->xScale()) );
 +//  ui.chkAutoScaleX->setChecked(group.readEntry("AutoScaleX", m_plot->autoScaleX()));
 +//      ui.kleXMin->setText( QString::number( group.readEntry("xMin", m_plot->xMin())) );
 +//  ui.kleXMax->setText( QString::number( group.readEntry("xMax", m_plot->xMax())) );
 +//  ui.cbXScaling->setCurrentIndex( group.readEntry("xScale", (int) m_plot->xScale()) );
  //
 -// 	ui.chkAutoScaleY->setChecked(group.readEntry("AutoScaleY", m_plot->autoScaleY()));
 -//   	ui.kleYMin->setText( QString::number( group.readEntry("yMin", m_plot->yMin())) );
 -// 	ui.kleYMax->setText( QString::number( group.readEntry("yMax", m_plot->yMax())) );
 -// 	ui.cbYScaling->setCurrentIndex( group.readEntry("yScale", (int) m_plot->yScale()) );
 -
 -	//Title
 -	KConfigGroup group = config.group("PlotTitle");
 -	labelWidget->loadConfig(group);
 -
 -	//Scale breakings
 -	//TODO
 -
 -	//Background-tab
 -	group = config.group("PlotArea");
 -	ui.cbBackgroundType->setCurrentIndex( group.readEntry("BackgroundType", (int) m_plot->plotArea()->backgroundType()) );
 -	ui.cbBackgroundColorStyle->setCurrentIndex( group.readEntry("BackgroundColorStyle", (int) m_plot->plotArea()->backgroundColorStyle()) );
 -	ui.cbBackgroundImageStyle->setCurrentIndex( group.readEntry("BackgroundImageStyle", (int) m_plot->plotArea()->backgroundImageStyle()) );
 -	ui.cbBackgroundBrushStyle->setCurrentIndex( group.readEntry("BackgroundBrushStyle", (int) m_plot->plotArea()->backgroundBrushStyle()) );
 -	ui.kleBackgroundFileName->setText( group.readEntry("BackgroundFileName", m_plot->plotArea()->backgroundFileName()) );
 -	ui.kcbBackgroundFirstColor->setColor( group.readEntry("BackgroundFirstColor", m_plot->plotArea()->backgroundFirstColor()) );
 -	ui.kcbBackgroundSecondColor->setColor( group.readEntry("BackgroundSecondColor", m_plot->plotArea()->backgroundSecondColor()) );
 -	ui.sbBackgroundOpacity->setValue( round(group.readEntry("BackgroundOpacity", m_plot->plotArea()->backgroundOpacity())*100.0) );
 -	ui.sbPaddingHorizontal->setValue(Worksheet::convertFromSceneUnits(group.readEntry("HorizontalPadding", m_plot->horizontalPadding()), Worksheet::Centimeter));
 -	ui.sbPaddingVertical->setValue(Worksheet::convertFromSceneUnits(group.readEntry("VerticalPadding", m_plot->verticalPadding()), Worksheet::Centimeter));
 -
 -	//Border-tab
 -	ui.kcbBorderColor->setColor( group.readEntry("BorderColor", m_plot->plotArea()->borderPen().color()) );
 -	ui.cbBorderStyle->setCurrentIndex( group.readEntry("BorderStyle", (int) m_plot->plotArea()->borderPen().style()) );
 -	ui.sbBorderWidth->setValue( Worksheet::convertFromSceneUnits(group.readEntry("BorderWidth", m_plot->plotArea()->borderPen().widthF()), Worksheet::Point) );
 -	ui.sbBorderCornerRadius->setValue( Worksheet::convertFromSceneUnits(group.readEntry("BorderCornerRadius", m_plot->plotArea()->borderCornerRadius()), Worksheet::Centimeter) );
 -	ui.sbBorderOpacity->setValue( group.readEntry("BorderOpacity", m_plot->plotArea()->borderOpacity())*100 );
 -
 -	m_initializing=true;
 -	GuiTools::updatePenStyles(ui.cbBorderStyle, ui.kcbBorderColor->color());
 -	m_initializing=false;
 +//  ui.chkAutoScaleY->setChecked(group.readEntry("AutoScaleY", m_plot->autoScaleY()));
 +//      ui.kleYMin->setText( QString::number( group.readEntry("yMin", m_plot->yMin())) );
 +//  ui.kleYMax->setText( QString::number( group.readEntry("yMax", m_plot->yMax())) );
 +//  ui.cbYScaling->setCurrentIndex( group.readEntry("yScale", (int) m_plot->yScale()) );
 +
 +    //Title
 +    KConfigGroup group = config.group("PlotTitle");
 +    labelWidget->loadConfig(group);
 +
 +    //Scale breakings
 +    //TODO
 +
 +    //Background-tab
 +    group = config.group("PlotArea");
 +    ui.cbBackgroundType->setCurrentIndex( group.readEntry("BackgroundType", (int) m_plot->plotArea()->backgroundType()) );
 +    ui.cbBackgroundColorStyle->setCurrentIndex( group.readEntry("BackgroundColorStyle", (int) m_plot->plotArea()->backgroundColorStyle()) );
 +    ui.cbBackgroundImageStyle->setCurrentIndex( group.readEntry("BackgroundImageStyle", (int) m_plot->plotArea()->backgroundImageStyle()) );
 +    ui.cbBackgroundBrushStyle->setCurrentIndex( group.readEntry("BackgroundBrushStyle", (int) m_plot->plotArea()->backgroundBrushStyle()) );
 +    ui.kleBackgroundFileName->setText( group.readEntry("BackgroundFileName", m_plot->plotArea()->backgroundFileName()) );
 +    ui.kcbBackgroundFirstColor->setColor( group.readEntry("BackgroundFirstColor", m_plot->plotArea()->backgroundFirstColor()) );
 +    ui.kcbBackgroundSecondColor->setColor( group.readEntry("BackgroundSecondColor", m_plot->plotArea()->backgroundSecondColor()) );
 +    ui.sbBackgroundOpacity->setValue( round(group.readEntry("BackgroundOpacity", m_plot->plotArea()->backgroundOpacity())*100.0) );
 +    ui.sbPaddingHorizontal->setValue(Worksheet::convertFromSceneUnits(group.readEntry("HorizontalPadding", m_plot->horizontalPadding()), Worksheet::Centimeter));
 +    ui.sbPaddingVertical->setValue(Worksheet::convertFromSceneUnits(group.readEntry("VerticalPadding", m_plot->verticalPadding()), Worksheet::Centimeter));
 +
 +    //Border-tab
 +    ui.kcbBorderColor->setColor( group.readEntry("BorderColor", m_plot->plotArea()->borderPen().color()) );
 +    ui.cbBorderStyle->setCurrentIndex( group.readEntry("BorderStyle", (int) m_plot->plotArea()->borderPen().style()) );
 +    ui.sbBorderWidth->setValue( Worksheet::convertFromSceneUnits(group.readEntry("BorderWidth", m_plot->plotArea()->borderPen().widthF()), Worksheet::Point) );
 +    ui.sbBorderCornerRadius->setValue( Worksheet::convertFromSceneUnits(group.readEntry("BorderCornerRadius", m_plot->plotArea()->borderCornerRadius()), Worksheet::Centimeter) );
 +    ui.sbBorderOpacity->setValue( group.readEntry("BorderOpacity", m_plot->plotArea()->borderOpacity())*100 );
 +
 +    m_initializing=true;
 +    GuiTools::updatePenStyles(ui.cbBorderStyle, ui.kcbBorderColor->color());
 +    m_initializing=false;
  }
  
  void CartesianPlotDock::saveConfigAsTemplate(KConfig& config) {
diff --cc src/kdefrontend/dockwidgets/XYInterpolationCurveDock.cpp
index 375ed8b,fec6ad7..a29a032
--- a/src/kdefrontend/dockwidgets/XYInterpolationCurveDock.cpp
+++ b/src/kdefrontend/dockwidgets/XYInterpolationCurveDock.cpp
@@@ -92,13 -91,22 +91,22 @@@ void XYInterpolationCurveDock::setupGen
  #if GSL_MAJOR_VERSION >= 2
  	uiGeneralTab.cbType->addItem(i18n("Steffen spline"));
  #endif
+ 	uiGeneralTab.cbType->addItem(i18n("cosine"));
+ 	uiGeneralTab.cbType->addItem(i18n("exponential"));
+ 	uiGeneralTab.cbType->addItem(i18n("piecewise cubic Hermite (PCH)"));
+ 	uiGeneralTab.cbType->addItem(i18n("rational functions"));
+ 
+ 	uiGeneralTab.cbVariant->addItem(i18n("finite differences"));
+ 	uiGeneralTab.cbVariant->addItem(i18n("Catmull-Rom"));
+ 	uiGeneralTab.cbVariant->addItem(i18n("cardinal"));
+ 	uiGeneralTab.cbVariant->addItem(i18n("Kochanek-Bartels (TCB)"));
  
- 	uiGeneralTab.cbEval->addItem(i18n("Function"));
- 	uiGeneralTab.cbEval->addItem(i18n("Derivative"));
- 	uiGeneralTab.cbEval->addItem(i18n("Second derivative"));
- 	uiGeneralTab.cbEval->addItem(i18n("Integral"));
+ 	uiGeneralTab.cbEval->addItem(i18n("function"));
+ 	uiGeneralTab.cbEval->addItem(i18n("derivative"));
+ 	uiGeneralTab.cbEval->addItem(i18n("second derivative"));
+ 	uiGeneralTab.cbEval->addItem(i18n("integral"));
  
 -	uiGeneralTab.pbRecalculate->setIcon(KIcon("run-build"));
 +	uiGeneralTab.pbRecalculate->setIcon(QIcon::fromTheme("run-build"));
  
  	QHBoxLayout* layout = new QHBoxLayout(ui.tabGeneral);
  	layout->setMargin(0);
diff --cc src/kdefrontend/spreadsheet/ExportSpreadsheetDialog.cpp
index ecd4324,414b85c..47bc8b8
--- a/src/kdefrontend/spreadsheet/ExportSpreadsheetDialog.cpp
+++ b/src/kdefrontend/spreadsheet/ExportSpreadsheetDialog.cpp
@@@ -68,9 -65,7 +68,7 @@@ ExportSpreadsheetDialog::ExportSpreadsh
  	ui.cbLaTeXExport->addItem(i18n("Export spreadsheet"));
  	ui.cbLaTeXExport->addItem(i18n("Export selection"));
  
- 	ui.gbMatrixOptions->setVisible(false);
- 
 -	ui.bOpen->setIcon( KIcon("document-open") );
 +	ui.bOpen->setIcon( QIcon::fromTheme("document-open") );
  
  	setMainWidget( mainWidget );
  
diff --cc src/kdefrontend/spreadsheet/RandomValuesDialog.cpp
index ae5c15c,8d24816..b29e07b
--- a/src/kdefrontend/spreadsheet/RandomValuesDialog.cpp
+++ b/src/kdefrontend/spreadsheet/RandomValuesDialog.cpp
@@@ -33,9 -33,6 +33,12 @@@
  #include <stdio.h>
  #include <gsl/gsl_rng.h>
  #include <gsl/gsl_randist.h>
 +#include <KLocalizedString>
++// 
 +#include <QDialogButtonBox>
- #include <QPushButton>
++// #include <QPushButton>
++#include <KConfigGroup>
++#include <KSharedConfig>
  
  /*!
  	\class RandomValuesDialog
@@@ -147,14 -139,33 +150,35 @@@ RandomValuesDialog::RandomValuesDialog(
  	connect( ui.kleParameter1, SIGNAL(textChanged(QString)), this, SLOT(checkValues()) );
  	connect( ui.kleParameter2, SIGNAL(textChanged(QString)), this, SLOT(checkValues()) );
  	connect( ui.kleParameter3, SIGNAL(textChanged(QString)), this, SLOT(checkValues()) );
 -	connect(this, SIGNAL(okClicked()), this, SLOT(generate()));
 +	connect(buttonBox, SIGNAL(accepted()), this, SLOT(generate()));
 +	connect(buttonBox, SIGNAL(rejected()), this, SLOT(reject()));
 +	connect(buttonBox, SIGNAL(accepted()), this, SLOT(accept()));
  
- 	//Gaussian distribution as default
- 	this->distributionChanged(0);
+ 	//restore saved settings if available
+ 	KConfigGroup conf(KSharedConfig::openConfig(), "RandomValuesDialog");
+ 	if (conf.exists()) {
+ 		ui.cbDistribution->setCurrentIndex(conf.readEntry("Distribution", 0));
+ 		this->distributionChanged(ui.cbDistribution->currentIndex()); //if index=0 no signal is emmited above, call this slot directly here
+ 		ui.kleParameter1->setText(conf.readEntry("Parameter1"));
+ 		ui.kleParameter2->setText(conf.readEntry("Parameter2"));
+ 		ui.kleParameter3->setText(conf.readEntry("Parameter3"));
+ 		restoreDialogSize(conf);
+ 	} else {
+ 		//Gaussian distribution as default
+ 		this->distributionChanged(0);
  
- 	resize( QSize(400,0).expandedTo(minimumSize()) );
+ 		resize( QSize(400,0).expandedTo(minimumSize()) );
+ 	}
+ }
+ 
+ RandomValuesDialog::~RandomValuesDialog() {
+ 	//save current settings
+ 	KConfigGroup conf(KSharedConfig::openConfig(), "RandomValuesDialog");
+ 	conf.writeEntry("Distribution", ui.cbDistribution->currentIndex());
+ 	conf.writeEntry("Parameter1", ui.kleParameter1->text());
+ 	conf.writeEntry("Parameter2", ui.kleParameter2->text());
+ 	conf.writeEntry("Parameter3", ui.kleParameter3->text());
+ 	saveDialogSize(conf);
  }
  
  void RandomValuesDialog::setColumns(QList<Column*> list) {
diff --cc src/kdefrontend/spreadsheet/RandomValuesDialog.h
index d4a5a98,3eff181..98db5f5
--- a/src/kdefrontend/spreadsheet/RandomValuesDialog.h
+++ b/src/kdefrontend/spreadsheet/RandomValuesDialog.h
@@@ -30,8 -30,7 +30,8 @@@
  
  #include "ui_randomvalueswidget.h"
  #include <QMap>
- #include <QDialog>
+ #include <KDialog>
 +#include <QPushButton>
  
  class Column;
  class Spreadsheet;
diff --cc src/kdefrontend/ui/dockwidgets/cartesianplotdock.ui
index 788b202,14c0c7c..fa9b9e8
--- a/src/kdefrontend/ui/dockwidgets/cartesianplotdock.ui
+++ b/src/kdefrontend/ui/dockwidgets/cartesianplotdock.ui
@@@ -495,13 -483,7 +483,7 @@@
             </widget>
            </item>
            <item>
 -           <widget class="KComboBox" name="cbXBreak">
 +           <widget class="QComboBox" name="cbXBreak">
-             <property name="maximumSize">
-              <size>
-               <width>40</width>
-               <height>16777215</height>
-              </size>
-             </property>
              <property name="toolTip">
               <string>Current scale breaking</string>
              </property>
@@@ -654,13 -624,7 +624,7 @@@
             </widget>
            </item>
            <item>
 -           <widget class="KComboBox" name="cbYBreak">
 +           <widget class="QComboBox" name="cbYBreak">
-             <property name="maximumSize">
-              <size>
-               <width>40</width>
-               <height>16777215</height>
-              </size>
-             </property>
              <property name="toolTip">
               <string>Current scale breaking</string>
              </property>
diff --cc src/kdefrontend/widgets/LabelWidget.cpp
index 4d9bc88,1f5b192..a220db2
--- a/src/kdefrontend/widgets/LabelWidget.cpp
+++ b/src/kdefrontend/widgets/LabelWidget.cpp
@@@ -439,43 -438,42 +439,42 @@@ void LabelWidget::insertDateTime(QActio
  // geometry slots
  
  /*!
 -	called when label's current horizontal position relative to its parent (left, center, right, custom ) is changed.
 +    called when label's current horizontal position relative to its parent (left, center, right, custom ) is changed.
  */
  void LabelWidget::positionXChanged(int index){
-     //Enable/disable the spinbox for the x- oordinates if the "custom position"-item is selected/deselected
-     if (index == ui.cbPositionX->count()-1 ){
-         ui.sbPositionX->setEnabled(true);
-     }else{
-         ui.sbPositionX->setEnabled(false);
-     }
+ 	//Enable/disable the spinbox for the x- oordinates if the "custom position"-item is selected/deselected
+ 	if (index == ui.cbPositionX->count()-1 )
+ 		ui.sbPositionX->setEnabled(true);
+ 	else
+ 		ui.sbPositionX->setEnabled(false);
  
 -	if (m_initializing)
 -		return;
 +    if (m_initializing)
 +        return;
  
 -	TextLabel::PositionWrapper position = m_label->position();
 -	position.horizontalPosition = TextLabel::HorizontalPosition(index);
 -	foreach(TextLabel* label, m_labelsList)
 -		label->setPosition(position);
 +    TextLabel::PositionWrapper position = m_label->position();
 +    position.horizontalPosition = TextLabel::HorizontalPosition(index);
 +    foreach(TextLabel* label, m_labelsList)
 +        label->setPosition(position);
  }
  
  /*!
 -	called when label's current horizontal position relative to its parent (top, center, bottom, custom ) is changed.
 +    called when label's current horizontal position relative to its parent (top, center, bottom, custom ) is changed.
  */
  void LabelWidget::positionYChanged(int index){
-     //Enable/disable the spinbox for the y- oordinates if the "custom position"-item is selected/deselected
-     if (index == ui.cbPositionY->count()-1 ){
-         ui.sbPositionY->setEnabled(true);
-     }else{
-         ui.sbPositionY->setEnabled(false);
-     }
+ 	//Enable/disable the spinbox for the y-coordinates if the "custom position"-item is selected/deselected
+ 	if (index == ui.cbPositionY->count()-1 ){
+ 		ui.sbPositionY->setEnabled(true);
+ 	}else{
+ 		ui.sbPositionY->setEnabled(false);
+ 	}
  
 -	if (m_initializing)
 -		return;
 +    if (m_initializing)
 +        return;
  
 -	TextLabel::PositionWrapper position = m_label->position();
 -	position.verticalPosition = TextLabel::VerticalPosition(index);
 -	foreach(TextLabel* label, m_labelsList)
 -		label->setPosition(position);
 +    TextLabel::PositionWrapper position = m_label->position();
 +    position.verticalPosition = TextLabel::VerticalPosition(index);
 +    foreach(TextLabel* label, m_labelsList)
 +        label->setPosition(position);
  }
  
  void LabelWidget::customPositionXChanged(double value){


More information about the kde-doc-english mailing list