]> Git trees. - libqmvoc.git/commitdiff
API change: deprecated the constructor with the limits, in flavour of a simple constr...
authorPino Toscano <pino@kde.org>
Fri, 16 Feb 2007 17:49:24 +0000 (17:49 +0000)
committerPino Toscano <pino@kde.org>
Fri, 16 Feb 2007 17:49:24 +0000 (17:49 +0000)
svn path=/trunk/KDE/kdeedu/libkdeedu/; revision=634247

kdeeduplot/kplotwidget.cpp
kdeeduplot/kplotwidget.h
widgets/kdeedu.widgets

index d8720afbf6d6431fc48914987abe8ffa3067a966..013719e8cd70d6ab85547a0352233cdddea34515 100644 (file)
@@ -91,6 +91,20 @@ KPlotWidget::KPlotWidget( QWidget *parent, double x1, double x2, double y1, doub
        setMinimumSize( 150, 150 );
 }
 
+KPlotWidget::KPlotWidget( QWidget * parent )
+    : QFrame( parent ), d( new Private( this ) )
+{
+    setAttribute( Qt::WA_NoBackground, true );
+
+    // sets the default limits
+    setLimits( 0.0, 1.0, 0.0, 1.0 );
+    SecondDataRect = QRect(); //default: no secondary data rect
+
+    setDefaultPaddings();
+
+    setMinimumSize( 150, 150 );
+}
+
 KPlotWidget::~KPlotWidget()
 {
        qDeleteAll( ObjectList );
index 169a72d0808e81d1fd1e2d1f507c3349a49ff242..42494fc0ae71a3d3a4acd38d508f347f05b330ce 100644 (file)
@@ -84,14 +84,15 @@ class KDEEDUPLOT_EXPORT KPlotWidget : public QFrame {
        Q_PROPERTY(bool objectToolTip READ areObjectToolTipsShown WRITE setShowObjectToolTips)
 public:
        /**
-        * @short Constructor. Sets the primary x and y limits in data units.
-        * @param parent the parent widget
-        * @param x1 the minimum X value in data units
-        * @param x2 the maximum X value in data units
-        * @param y1 the minimum Y value in data units
-        * @param y2 the maximum Y value in data units
+        * @deprecated use the normal constructor and setLimits()
         */
-       KPlotWidget( QWidget *parent=0, double x1=0.0, double x2=1.0, double y1=0.0, double y2=1.0 );
+       KDE_DEPRECATED KPlotWidget( QWidget *parent, double x1, double x2, double y1, double y2 );
+
+        /**
+         * Constructor.
+         * @param parent the parent widget
+         */
+        explicit KPlotWidget( QWidget * parent = 0 );
 
        /**
         * Destructor.
index b6864b792f102f345fcc4da57a3ba888a48e3a13..0e90aacbd38e80bda2797af78c5975a8e1da6e9f 100644 (file)
@@ -7,7 +7,6 @@ Init=new KComponentData("kdeeduwidgets");
 ToolTip=A plot widget (KDE-Edu)
 WhatsThis=A widget for easily making 2-dimensional plots
 Group=Plot (KDE-Edu)
-ConstructorArgs=(parent, 0.0, 1.0, 0.0, 1.0)
 
 [ExtDateEdit]
 ToolTip=spinbox-based extended date editor (KDE-Edu)