From 14316cddfb621038d95c542c00824f5a6d4a7d35 Mon Sep 17 00:00:00 2001 From: cniehaus Date: Mon, 16 Sep 2002 17:25:52 +0000 Subject: ok, perhaps someone else is able to tell OPIE where my file is. I am sure not... --- (limited to 'noncore/apps') diff --git a/noncore/apps/oxygen/.cvsignore b/noncore/apps/oxygen/.cvsignore index af13397..194054e 100644 --- a/noncore/apps/oxygen/.cvsignore +++ b/noncore/apps/oxygen/.cvsignore @@ -1,5 +1,7 @@ calcdlg.h calcdlg.cpp +datawidget.h +datawidget.cpp moc_* *.moc Makefile* diff --git a/noncore/apps/oxygen/calcdlg.ui b/noncore/apps/oxygen/calcdlg.ui index adaa8b0..b4e54f1 100644 --- a/noncore/apps/oxygen/calcdlg.ui +++ b/noncore/apps/oxygen/calcdlg.ui @@ -11,8 +11,8 @@ 0 0 - 271 - 357 + 253 + 352 @@ -36,7 +36,7 @@ 0 0 - 270 + 250 350 @@ -67,8 +67,8 @@ 0 0 - 260 - 320 + 240 + 310 @@ -90,8 +90,8 @@ 0 0 - 260 - 320 + 240 + 310 diff --git a/noncore/apps/oxygen/datawidget.ui b/noncore/apps/oxygen/datawidget.ui new file mode 100644 index 0000000..a4dcab2 --- a/dev/null +++ b/noncore/apps/oxygen/datawidget.ui @@ -0,0 +1,85 @@ + +dataWidget + + QDialog + + name + dataWidget + + + geometry + + 0 + 0 + 249 + 276 + + + + caption + Chemical Data + + + QComboBox + + + text + Helium + + + + + text + Carbon + + + + + text + Oxygen + + + + name + ComboBox2 + + + geometry + + 10 + 10 + 230 + 50 + + + + + QTable + + name + dataTable + + + geometry + + 0 + 80 + 240 + 190 + + + + numRows + 6 + + + numCols + 2 + + + showGrid + false + + + + diff --git a/noncore/apps/oxygen/datawidgetui.cpp b/noncore/apps/oxygen/datawidgetui.cpp new file mode 100644 index 0000000..5b34cf5 --- a/dev/null +++ b/noncore/apps/oxygen/datawidgetui.cpp @@ -0,0 +1,40 @@ +/*************************************************************************** + * * + * This program is free software; you can redistribute it and/or modify * + * it under the terms of the GNU General Public License as published by * + * the Free Software Foundation; either version 2 of the License, or * + * ( at your option ) any later version. * + * * + **************************************************************************/ +#include "oxygen.h" + +#include +#include "datawidgetui.h" +#include +#include + +dataWidgetUI::dataWidgetUI() : dataWidget() +{ + Config test( "oxygendata" ); + test.setGroup( "1" ); + + if ( test.hasKey( "Name" ) ) + { + qDebug ( "geht" ); + }else qDebug( "geht nicht" ); + + QString foo = test.readEntry( "Name" ); + //test.writeEntry( "Name", "test123" ); + + qDebug( "hier sollte was kommen" ); + qDebug( foo ); + + dataTable->horizontalHeader()->hide(); + dataTable->verticalHeader()->hide(); + dataTable->setTopMargin( 0 ); + dataTable->setLeftMargin( 0 ); + dataTable->setText( 0,0,"Atomic Radius" ); + dataTable->setText( 0,1,"17 nm" ); + dataTable->setText( 1,0,"Elec. neg." ); + dataTable->setText( 1,1,"234 Joule" ); +} diff --git a/noncore/apps/oxygen/datawidgetui.h b/noncore/apps/oxygen/datawidgetui.h new file mode 100644 index 0000000..47d9698 --- a/dev/null +++ b/noncore/apps/oxygen/datawidgetui.h @@ -0,0 +1,20 @@ + +/*************************************************************************** + * * + * This program is free software; you can redistribute it and/or modify * + * it under the terms of the GNU General Public License as published by * + * the Free Software Foundation; either version 2 of the License, or * + * ( at your option ) any later version. * + * * + **************************************************************************/ +#include "datawidget.h" + +class QTable; + +class dataWidgetUI : public dataWidget +{ + Q_OBJECT + + public: + dataWidgetUI(); +}; diff --git a/noncore/apps/oxygen/oxygen.cpp b/noncore/apps/oxygen/oxygen.cpp index 81897e9..a9c2276 100644 --- a/noncore/apps/oxygen/oxygen.cpp +++ b/noncore/apps/oxygen/oxygen.cpp @@ -5,20 +5,16 @@ * the Free Software Foundation; either version 2 of the License, or * * ( at your option ) any later version. * * * - * ***********************************************************************/ + **************************************************************************/ #include "oxygen.h" -#include -#include -#include #include #include #include -#include -#include #include #include "calcdlg.h" #include "calcdlgui.h" +#include "datawidgetui.h" Oxygen::Oxygen() : QMainWindow() @@ -27,6 +23,8 @@ Oxygen::Oxygen() vbox = new QVBox( this ); QPushButton *setButton = new QPushButton( "Settings", vbox ); connect ( setButton, SIGNAL( clicked() ), this, SLOT( slotSettings() ) ); + QPushButton *dataButton = new QPushButton( "Data", vbox ); + connect ( dataButton, SIGNAL( clicked() ), this, SLOT( slotData() ) ); QPushButton *calcButton = new QPushButton( "Calculations", vbox ); connect ( calcButton, SIGNAL( clicked() ), this, SLOT( slotCalculations() ) ); QPushButton *pseButton = new QPushButton( "PSE", vbox ); @@ -48,6 +46,11 @@ void Oxygen::slotCalculations(){ CalcDlgUI->show(); }; +void Oxygen::slotData(){ + dataWidgetUI *DataWidgetUI = new dataWidgetUI(); + DataWidgetUI->show(); +}; + void Oxygen::slotSettings(){ }; void Oxygen::slotPSE(){ }; diff --git a/noncore/apps/oxygen/oxygen.h b/noncore/apps/oxygen/oxygen.h index 1e923ee..71914eb 100644 --- a/noncore/apps/oxygen/oxygen.h +++ b/noncore/apps/oxygen/oxygen.h @@ -1,9 +1,13 @@ +/*************************************************************************** + * * + * This program is free software; you can redistribute it and/or modify * + * it under the terms of the GNU General Public License as published by * + * the Free Software Foundation; either version 2 of the License, or * + * ( at your option ) any later version. * + * * + **************************************************************************/ -#include #include -#include -#include -#include class QVBox; @@ -17,6 +21,7 @@ class Oxygen : public QMainWindow private slots: void slotCalculations(); void slotSettings(); + void slotData(); void slotPSE(); void close(); }; diff --git a/noncore/apps/oxygen/oxygen.pro b/noncore/apps/oxygen/oxygen.pro index c5448e7..7736a97 100644 --- a/noncore/apps/oxygen/oxygen.pro +++ b/noncore/apps/oxygen/oxygen.pro @@ -3,17 +3,20 @@ CONFIG = qt warn_on release HEADERS = oxygen.h \ kmolcalc.h \ kmolelements.h \ - calcdlgui.h + calcdlgui.h \ + datawidgetui.h SOURCES = main.cpp \ oxygen.cpp \ kmolcalc.cpp \ calcdlgui.cpp \ - kmolelements.cpp + kmolelements.cpp \ + datawidgetui.cpp INCLUDEPATH += $(OPIEDIR)/include DEPENDPATH += $(OPIEDIR)/include LIBS += -lqpe -INTERFACES = calcdlg.ui +INTERFACES = calcdlg.ui \ + datawidget.ui TARGET = oxygen DESTDIR = $(OPIEDIR)/bin -- cgit v0.9.0.2