|
From: <dhu...@us...> - 2006-11-27 21:14:46
|
Revision: 6
http://svn.sourceforge.net/qcell/?rev=6&view=rev
Author: dhubleizh
Date: 2006-11-27 13:14:42 -0800 (Mon, 27 Nov 2006)
Log Message:
-----------
- visgui files
Added Paths:
-----------
trunk/qcell/visgui/AboutDialog.ui
trunk/qcell/visgui/MainWindow.cpp
trunk/qcell/visgui/MainWindow.h
trunk/qcell/visgui/MainWindow.ui
trunk/qcell/visgui/main.cpp
trunk/qcell/visgui/visgui.pro
trunk/qcell/visgui/visgui_pl.qm
trunk/qcell/visgui/visgui_pl.ts
Added: trunk/qcell/visgui/AboutDialog.ui
===================================================================
--- trunk/qcell/visgui/AboutDialog.ui (rev 0)
+++ trunk/qcell/visgui/AboutDialog.ui 2006-11-27 21:14:42 UTC (rev 6)
@@ -0,0 +1,82 @@
+<ui version="4.0" >
+ <class>AboutDialog</class>
+ <widget class="QDialog" name="AboutDialog" >
+ <property name="geometry" >
+ <rect>
+ <x>0</x>
+ <y>0</y>
+ <width>400</width>
+ <height>300</height>
+ </rect>
+ </property>
+ <property name="windowTitle" >
+ <string>About QCell</string>
+ </property>
+ <layout class="QVBoxLayout" >
+ <property name="margin" >
+ <number>9</number>
+ </property>
+ <property name="spacing" >
+ <number>6</number>
+ </property>
+ <item>
+ <widget class="QGraphicsView" name="graphicsView" >
+ <property name="enabled" >
+ <bool>true</bool>
+ </property>
+ <property name="acceptDrops" >
+ <bool>false</bool>
+ </property>
+ <property name="autoFillBackground" >
+ <bool>false</bool>
+ </property>
+ </widget>
+ </item>
+ <item>
+ <spacer>
+ <property name="orientation" >
+ <enum>Qt::Vertical</enum>
+ </property>
+ <property name="sizeHint" >
+ <size>
+ <width>20</width>
+ <height>91</height>
+ </size>
+ </property>
+ </spacer>
+ </item>
+ <item>
+ <layout class="QHBoxLayout" >
+ <property name="margin" >
+ <number>0</number>
+ </property>
+ <property name="spacing" >
+ <number>6</number>
+ </property>
+ <item>
+ <spacer>
+ <property name="orientation" >
+ <enum>Qt::Horizontal</enum>
+ </property>
+ <property name="sizeHint" >
+ <size>
+ <width>40</width>
+ <height>20</height>
+ </size>
+ </property>
+ </spacer>
+ </item>
+ <item>
+ <widget class="QPushButton" name="OKButton" >
+ <property name="text" >
+ <string>&OK</string>
+ </property>
+ </widget>
+ </item>
+ </layout>
+ </item>
+ </layout>
+ </widget>
+ <resources/>
+ <connections/>
+</ui>
Added: trunk/qcell/visgui/MainWindow.cpp
===================================================================
--- trunk/qcell/visgui/MainWindow.cpp (rev 0)
+++ trunk/qcell/visgui/MainWindow.cpp 2006-11-27 21:14:42 UTC (rev 6)
@@ -0,0 +1,29 @@
+/**@file MainWindow.c
+ * @author czarny
+ * @version 0.1
+ * @date
+ * Created: ?ro 22 lis 2006 14:18:06 CET \n
+ * Last Update: ?ro 22 lis 2006 14:18:06 CET
+ */
+
+#include "MainWindow.h"
+
+MainWindow::MainWindow(QWidget* parent)
+{
+ setupUi(this);
+}
+
+void MainWindow::on_action_About_activated()
+{
+ QDialog* dialog = new QDialog(this);
+ Ui::AboutDialog* ad = new Ui::AboutDialog();
+ ad->setupUi(dialog);
+ connect(ad->OKButton, SIGNAL(clicked()), dialog, SLOT(accept()));
+ dialog->show();
+}
+
+void MainWindow::on_action_Quit_activated()
+{
+ // TODO: Some saving checking
+ QCoreApplication::exit();
+}
Added: trunk/qcell/visgui/MainWindow.h
===================================================================
--- trunk/qcell/visgui/MainWindow.h (rev 0)
+++ trunk/qcell/visgui/MainWindow.h 2006-11-27 21:14:42 UTC (rev 6)
@@ -0,0 +1,30 @@
+/**@file MainWindow.h
+ * @author czarny
+ * @version gg
+ * @date
+ * Created: ?ro 22 lis 2006 14:14:17 CET \n
+ * Last Update: ?ro 22 lis 2006 14:14:17 CET
+ */
+
+#ifndef __MAINWINDOW_H__
+#define __MAINWINDOW_H__
+
+#include "ui_MainWindow.h"
+#include "ui_AboutDialog.h"
+
+#include <iostream>
+using namespace std;
+
+class MainWindow : public QMainWindow, private Ui::MainWindow
+{
+ Q_OBJECT
+
+public:
+ MainWindow(QWidget* parent = 0);
+
+private slots:
+ void on_action_About_activated();
+ void on_action_Quit_activated();
+};
+
+#endif
Added: trunk/qcell/visgui/MainWindow.ui
===================================================================
--- trunk/qcell/visgui/MainWindow.ui (rev 0)
+++ trunk/qcell/visgui/MainWindow.ui 2006-11-27 21:14:42 UTC (rev 6)
@@ -0,0 +1,145 @@
+<ui version="4.0" >
+ <class>MainWindow</class>
+ <widget class="QMainWindow" name="MainWindow" >
+ <property name="geometry" >
+ <rect>
+ <x>0</x>
+ <y>0</y>
+ <width>557</width>
+ <height>541</height>
+ </rect>
+ </property>
+ <property name="windowTitle" >
+ <string>QCell</string>
+ </property>
+ <property name="windowIcon" >
+ <iconset/>
+ </property>
+ <widget class="QWidget" name="centralwidget" >
+ <layout class="QVBoxLayout" >
+ <property name="margin" >
+ <number>9</number>
+ </property>
+ <property name="spacing" >
+ <number>6</number>
+ </property>
+ <item>
+ <widget class="QWidget" native="1" name="MainGLWidget" />
+ </item>
+ </layout>
+ </widget>
+ <widget class="QMenuBar" name="mainMenubar" >
+ <property name="geometry" >
+ <rect>
+ <x>0</x>
+ <y>0</y>
+ <width>557</width>
+ <height>30</height>
+ </rect>
+ </property>
+ <widget class="QMenu" name="menu_Help" >
+ <property name="title" >
+ <string>&Help</string>
+ </property>
+ <addaction name="separator" />
+ <addaction name="action_About" />
+ </widget>
+ <widget class="QMenu" name="menu_File" >
+ <property name="title" >
+ <string>&File</string>
+ </property>
+ <widget class="QMenu" name="menu_Open" >
+ <property name="statusTip" >
+ <string>Opens experiment data.</string>
+ </property>
+ <property name="title" >
+ <string>&Open</string>
+ </property>
+ <addaction name="action_Neighbourhood" />
+ <addaction name="action_Function" />
+ <addaction name="action_World" />
+ </widget>
+ <addaction name="menu_Open" />
+ <addaction name="action_Open_experiment" />
+ <addaction name="action_Continiue_experiment" />
+ <addaction name="separator" />
+ <addaction name="action_Quit" />
+ </widget>
+ <addaction name="menu_File" />
+ <addaction name="menu_Help" />
+ </widget>
+ <widget class="QStatusBar" name="statusbar" />
+ <widget class="QToolBar" name="mainToolBar" >
+ <property name="toolTip" >
+ <string>This menu allows searching through help topics and reading about the application.</string>
+ </property>
+ <property name="orientation" >
+ <enum>Qt::Horizontal</enum>
+ </property>
+ <attribute name="toolBarArea" >
+ <number>4</number>
+ </attribute>
+ </widget>
+ <action name="action_Quit" >
+ <property name="text" >
+ <string>&Quit</string>
+ </property>
+ <property name="toolTip" >
+ <string comment="Quits the application" >This menu item quits the application.</string>
+ </property>
+ <property name="statusTip" >
+ <string>Quits the application.</string>
+ </property>
+ </action>
+ <action name="action_Neighbourhood" >
+ <property name="text" >
+ <string>&Neighbourhood</string>
+ </property>
+ <property name="statusTip" >
+ <string>Opens neighbourhood.</string>
+ </property>
+ </action>
+ <action name="action_Function" >
+ <property name="text" >
+ <string>&Function</string>
+ </property>
+ <property name="statusTip" >
+ <string>Opens function.</string>
+ </property>
+ </action>
+ <action name="action_World" >
+ <property name="text" >
+ <string>&World</string>
+ </property>
+ <property name="statusTip" >
+ <string>Opens world configuration.</string>
+ </property>
+ </action>
+ <action name="action_Open_experiment" >
+ <property name="text" >
+ <string>Open &experiment</string>
+ </property>
+ <property name="statusTip" >
+ <string>Opens a predefined experiment.</string>
+ </property>
+ </action>
+ <action name="action_Continiue_experiment" >
+ <property name="text" >
+ <string>&Continiue experiment</string>
+ </property>
+ <property name="statusTip" >
+ <string>Loads an earlier saved experiment.</string>
+ </property>
+ </action>
+ <action name="action_About" >
+ <property name="text" >
+ <string>&About</string>
+ </property>
+ <property name="statusTip" >
+ <string>Shows info about the program.</string>
+ </property>
+ </action>
+ </widget>
+ <resources/>
+ <connections/>
+</ui>
Added: trunk/qcell/visgui/main.cpp
===================================================================
--- trunk/qcell/visgui/main.cpp (rev 0)
+++ trunk/qcell/visgui/main.cpp 2006-11-27 21:14:42 UTC (rev 6)
@@ -0,0 +1,23 @@
+#include <iostream>
+
+#include <QtGui>
+#include "MainWindow.h"
+
+using namespace std;
+
+int main(int argc, char* argv[])
+{
+ QApplication app(argc, argv);
+
+ QString locale = QLocale::system().name();
+
+ QTranslator translator;
+ translator.load(QString("visgui_") + locale);
+ app.installTranslator(&translator);
+
+ MainWindow mw;
+ mw.show();
+
+ return app.exec();
+}
+
Added: trunk/qcell/visgui/visgui.pro
===================================================================
--- trunk/qcell/visgui/visgui.pro (rev 0)
+++ trunk/qcell/visgui/visgui.pro 2006-11-27 21:14:42 UTC (rev 6)
@@ -0,0 +1,13 @@
+TEMPLATE = app
+DESTDIR = ../bin
+CONFIG += qt thread warn_on debug
+
+FORMS = MainWindow.ui \
+ AboutDialog.ui
+
+HEADERS = MainWindow.h
+SOURCES = main.cpp \
+ MainWindow.cpp
+
+TRANSLATIONS = visgui_pl.ts
+
Added: trunk/qcell/visgui/visgui_pl.qm
===================================================================
(Binary files differ)
Property changes on: trunk/qcell/visgui/visgui_pl.qm
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: trunk/qcell/visgui/visgui_pl.ts
===================================================================
--- trunk/qcell/visgui/visgui_pl.ts (rev 0)
+++ trunk/qcell/visgui/visgui_pl.ts 2006-11-27 21:14:42 UTC (rev 6)
@@ -0,0 +1,125 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE TS><TS version="1.1" language="pl">
+<context>
+ <name>AboutDialog</name>
+ <message>
+ <location filename="AboutDialog.ui" line="13"/>
+ <source>About QCell</source>
+ <translation>O Qcell</translation>
+ </message>
+ <message>
+ <location filename="AboutDialog.ui" line="72"/>
+ <source>&OK</source>
+ <translation>&OK</translation>
+ </message>
+</context>
+<context>
+ <name>MainWindow</name>
+ <message>
+ <location filename="MainWindow.ui" line="13"/>
+ <source>QCell</source>
+ <translation>QCell</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="42"/>
+ <source>&Help</source>
+ <translation>P&omoc</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="49"/>
+ <source>&File</source>
+ <translation>&Plik</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="53"/>
+ <source>Opens experiment data.</source>
+ <translation>Otwiera dane eksperymentu.</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="56"/>
+ <source>&Open</source>
+ <translation>&Otwórz</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="74"/>
+ <source>This menu allows searching through help topics and reading about the application.</source>
+ <translation>To menu pozwala przeszukiwać tematy pomocy i poczytać o aplikacji.</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="85"/>
+ <source>&Quit</source>
+ <translation>&Wyjście</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="88"/>
+ <source>This menu item quits the application.</source>
+ <comment>Quits the application</comment>
+ <translation>Ten przycisk menu powoduje wyjście z aplikacji.</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="91"/>
+ <source>Quits the application.</source>
+ <translation>Wychodzi z aplikacji.</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="96"/>
+ <source>&Neighbourhood</source>
+ <translation>&Sąsiedztwo</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="99"/>
+ <source>Opens neighbourhood.</source>
+ <translation>Otwiera plik sąsiedztwa.</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="104"/>
+ <source>&Function</source>
+ <translation>&Funkcja</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="107"/>
+ <source>Opens function.</source>
+ <translation>Otwiera plik funkcji.</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="112"/>
+ <source>&World</source>
+ <translation>Ś&wiat</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="115"/>
+ <source>Opens world configuration.</source>
+ <translation>Otwiera konfigurację świata.</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="120"/>
+ <source>Open &experiment</source>
+ <translation>Otwórz &eksperyment</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="123"/>
+ <source>Opens a predefined experiment.</source>
+ <translation>Otwiera zdefiniowany wcześniej eksperyment.</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="128"/>
+ <source>&Continiue experiment</source>
+ <translation>&Kontynuuj eksperyment</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="131"/>
+ <source>Loads an earlier saved experiment.</source>
+ <translation>Ładuje wcześniej zachowany eksperyment.</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="136"/>
+ <source>&About</source>
+ <translation>&O programie</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="139"/>
+ <source>Shows info about the program.</source>
+ <translation>Pokazuje informacje o programie.</translation>
+ </message>
+</context>
+</TS>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <dhu...@us...> - 2006-11-28 10:18:27
|
Revision: 9
http://svn.sourceforge.net/qcell/?rev=9&view=rev
Author: dhubleizh
Date: 2006-11-28 02:18:24 -0800 (Tue, 28 Nov 2006)
Log Message:
-----------
- running fix
- beginned interface writing for parsers
Modified Paths:
--------------
trunk/qcell/visgui/main.cpp
trunk/qcell/visgui/visgui.pro
Added Paths:
-----------
trunk/qcell/visgui/ClientConfig.xml
trunk/qcell/visgui/interfaces.h
Added: trunk/qcell/visgui/ClientConfig.xml
===================================================================
--- trunk/qcell/visgui/ClientConfig.xml (rev 0)
+++ trunk/qcell/visgui/ClientConfig.xml 2006-11-28 10:18:24 UTC (rev 9)
@@ -0,0 +1 @@
+link ../bin/ClientConfig.xml
\ No newline at end of file
Property changes on: trunk/qcell/visgui/ClientConfig.xml
___________________________________________________________________
Name: svn:special
+ *
Added: trunk/qcell/visgui/interfaces.h
===================================================================
--- trunk/qcell/visgui/interfaces.h (rev 0)
+++ trunk/qcell/visgui/interfaces.h 2006-11-28 10:18:24 UTC (rev 9)
@@ -0,0 +1,24 @@
+/**@file interfaces.h
+ * @author czarny
+ * @version 0.1
+ * @date
+ * Created: wto 28 lis 2006 11:08:50 CET \n
+ * Last Update: wto 28 lis 2006 11:08:50 CET
+ */
+
+#ifndef __INTERFACES_H__
+#define __INTERFACES_H__
+
+class ParserInterface
+{
+public:
+ virtual ~ParserInterface() { };
+
+ virtual QStringList fileTypes() const = 0;
+};
+
+Q_DECLARE_INTERFACE(ParserInterface,
+ "qQCell.ParserInterface/1.0")
+
+#endif
+
Modified: trunk/qcell/visgui/main.cpp
===================================================================
--- trunk/qcell/visgui/main.cpp 2006-11-28 10:11:36 UTC (rev 8)
+++ trunk/qcell/visgui/main.cpp 2006-11-28 10:18:24 UTC (rev 9)
@@ -2,22 +2,28 @@
#include <QtGui>
#include "MainWindow.h"
+#include "../baseheaders/Client.h"
using namespace std;
int main(int argc, char* argv[])
{
QApplication app(argc, argv);
-
+
+ Client c;
+ if(c.initClient())
+ {
+ }
+
QString locale = QLocale::system().name();
-
+
QTranslator translator;
translator.load(QString("visgui_") + locale);
app.installTranslator(&translator);
-
+
MainWindow mw;
mw.show();
-
+
return app.exec();
}
Modified: trunk/qcell/visgui/visgui.pro
===================================================================
--- trunk/qcell/visgui/visgui.pro 2006-11-28 10:11:36 UTC (rev 8)
+++ trunk/qcell/visgui/visgui.pro 2006-11-28 10:18:24 UTC (rev 9)
@@ -1,13 +1,18 @@
TEMPLATE = app
DESTDIR = ../bin
-CONFIG += qt thread warn_on debug
+CONFIG += thread warn_on debug
+QT += network xml
FORMS = MainWindow.ui \
AboutDialog.ui
-HEADERS = MainWindow.h
+HEADERS = MainWindow.h \
+ ../baseheaders/Client.h \
+ ../baseheaders/ClientInfo.h
SOURCES = main.cpp \
- MainWindow.cpp
+ MainWindow.cpp \
+ ../basesources/Client.cpp \
+ ../basesources/ClientInfo.cpp
TRANSLATIONS = visgui_pl.ts
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <dhu...@us...> - 2006-11-28 16:59:19
|
Revision: 13
http://svn.sourceforge.net/qcell/?rev=13&view=rev
Author: dhubleizh
Date: 2006-11-28 08:59:04 -0800 (Tue, 28 Nov 2006)
Log Message:
-----------
- lib directory for output libs
- parsers dir and pro file for input files parsers plugins
Modified Paths:
--------------
trunk/qcell/visgui/main.cpp
trunk/qcell/visgui/visgui.pro
Modified: trunk/qcell/visgui/main.cpp
===================================================================
--- trunk/qcell/visgui/main.cpp 2006-11-28 11:05:24 UTC (rev 12)
+++ trunk/qcell/visgui/main.cpp 2006-11-28 16:59:04 UTC (rev 13)
@@ -6,6 +6,8 @@
using namespace std;
+Q_IMPORT_PLUGIN(NFileParser);
+
int main(int argc, char* argv[])
{
QApplication app(argc, argv);
@@ -21,6 +23,17 @@
translator.load(QString("visgui_") + locale);
app.installTranslator(&translator);
+ foreach(QObject* plugin, QPluginLoader::staticInstances())
+ {
+ ParserInterface* iParser = qobject_cast<ParserInterface *>(plugin);
+// if(iParser)
+// {
+// QStringList lista = iParser->fileTypes();
+// cout << lista[0] << endl;
+// }
+ }
+
+
MainWindow mw;
mw.show();
Modified: trunk/qcell/visgui/visgui.pro
===================================================================
--- trunk/qcell/visgui/visgui.pro 2006-11-28 11:05:24 UTC (rev 12)
+++ trunk/qcell/visgui/visgui.pro 2006-11-28 16:59:04 UTC (rev 13)
@@ -3,16 +3,18 @@
CONFIG += thread warn_on debug
QT += network xml
-FORMS = MainWindow.ui \
- AboutDialog.ui
+FORMS = MainWindow.ui \
+ AboutDialog.ui
+HEADERS = MainWindow.h \
+ ../baseheaders/Client.h \
+ ../baseheaders/ClientInfo.h \
+ ../baseheaders/interfaces.h
+SOURCES = main.cpp \
+ MainWindow.cpp \
+ ../basesources/Client.cpp \
+ ../basesources/ClientInfo.cpp
-HEADERS = MainWindow.h \
- ../baseheaders/Client.h \
- ../baseheaders/ClientInfo.h
-SOURCES = main.cpp \
- MainWindow.cpp \
- ../basesources/Client.cpp \
- ../basesources/ClientInfo.cpp
+LIBS = -L../libs -lN
-TRANSLATIONS = visgui_pl.ts
+TRANSLATIONS = visgui_pl.ts
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <dhu...@us...> - 2006-12-21 11:58:45
|
Revision: 77
http://svn.sourceforge.net/qcell/?rev=77&view=rev
Author: dhubleizh
Date: 2006-12-21 03:58:43 -0800 (Thu, 21 Dec 2006)
Log Message:
-----------
- menu actions call parsers
Modified Paths:
--------------
trunk/qcell/visgui/MainWindow.cpp
trunk/qcell/visgui/MainWindow.h
Modified: trunk/qcell/visgui/MainWindow.cpp
===================================================================
--- trunk/qcell/visgui/MainWindow.cpp 2006-12-21 11:55:24 UTC (rev 76)
+++ trunk/qcell/visgui/MainWindow.cpp 2006-12-21 11:58:43 UTC (rev 77)
@@ -10,7 +10,7 @@
MainWindow::MainWindow(QWidget* parent)
{
- // GUI setup
+ // GUI setup - earlies possible to show the user, that we're in buisness
setupUi(this);
// Plugin parsing
@@ -25,7 +25,7 @@
// according to supported types and file extensions
foreach(QObject* plugin, QPluginLoader::staticInstances())
{
- iParser = qobject_cast<ParserInterface *>(plugin);
+ iParser = qobject_cast<ParserInterface*>(plugin);
// If this is a parser plugin
if(iParser)
{
@@ -42,6 +42,7 @@
{
neighbourhood_parsers[extension] = iParser;
}
+
}
if(type == "Function")
{
@@ -97,7 +98,8 @@
QFileDialog fd(
/*parent*/ this,
- /*cation*/ tr("Open Neighbourhood")
+ /*cation*/ tr("Open Neighbourhood"),
+ /*dir*/ "."
);
fd.setFileMode(QFileDialog::ExistingFile);
@@ -116,6 +118,7 @@
fd.exec();
+ callParser(fd.selectedFiles().first(), "Neighbourhood");
}
void MainWindow::on_action_Function_activated()
@@ -134,7 +137,8 @@
QFileDialog fd(
/*parent*/ this,
- /*cation*/ tr("Open Function")
+ /*cation*/ tr("Open Function"),
+ /*dir*/ "."
);
fd.setFileMode(QFileDialog::ExistingFile);
@@ -171,7 +175,8 @@
QFileDialog fd(
/*parent*/ this,
- /*cation*/ tr("Open World")
+ /*cation*/ tr("Open World"),
+ /*dir*/ "."
);
fd.setFileMode(QFileDialog::ExistingFile);
@@ -192,3 +197,65 @@
}
+void MainWindow::callParser(QString filename, QString type)
+{
+ QFile file(filename);
+ QByteArray file_content;
+ QString subtype = filename.section('.', -1);
+
+ if (!file.open(QIODevice::ReadOnly | QIODevice::Text))
+ {
+ qDebug(tr("Error opening file %1.")
+ .arg(filename)
+ .toAscii()
+ );
+ }
+
+ if (type == "Neighbourhood")
+ {
+ if (!neighbourhood_parsers.contains(subtype))
+ {
+ qDebug(tr("The file extensions %1 isn't supported.")
+ .arg(subtype)
+ .toAscii()
+ );
+ return;
+ }
+
+ neighbourhood_parsers[subtype]->parse(file_content, type, subtype);
+
+ }
+ else if (type == "LocalFunction")
+ {
+ if (!function_parsers.contains(subtype))
+ {
+ qDebug(tr("The file extensions %1 isn't supported.")
+ .arg(subtype)
+ .toAscii()
+ );
+ return;
+ }
+
+ function_parsers[subtype]->parse(file_content, type, subtype);
+ }
+ else if (type == "World")
+ {
+ if (!world_parsers.contains(subtype))
+ {
+ qDebug(tr("The file extensions %1 isn't supported.")
+ .arg(subtype)
+ .toAscii()
+ );
+ return;
+ }
+
+ world_parsers[subtype]->parse(file_content, type, subtype);
+ }
+ else
+ {
+ qDebug(tr("Unsupported file type to parse.").toAscii());
+ return;
+ }
+
+}
+
Modified: trunk/qcell/visgui/MainWindow.h
===================================================================
--- trunk/qcell/visgui/MainWindow.h 2006-12-21 11:55:24 UTC (rev 76)
+++ trunk/qcell/visgui/MainWindow.h 2006-12-21 11:58:43 UTC (rev 77)
@@ -36,10 +36,12 @@
void on_action_World_activated();
private:
- QMap<QString, ParserInterface*> neighbourhood_parsers;
- QMap<QString, ParserInterface*> function_parsers;
- QMap<QString, ParserInterface*> world_parsers;
+ QMap<QString, ParserInterface*> neighbourhood_parsers;
+ QMap<QString, ParserInterface*> function_parsers;
+ QMap<QString, ParserInterface*> world_parsers;
+ void callParser(QString filename, QString type);
+
};
#endif
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <dhu...@us...> - 2007-01-05 10:42:47
|
Revision: 95
http://svn.sourceforge.net/qcell/?rev=95&view=rev
Author: dhubleizh
Date: 2007-01-05 02:42:45 -0800 (Fri, 05 Jan 2007)
Log Message:
-----------
- Proper handling of start, stop, continuos and timed processing
- nasty hackcs for database of experiments
Modified Paths:
--------------
trunk/qcell/visgui/MainWindow.cpp
trunk/qcell/visgui/MainWindow.h
trunk/qcell/visgui/MainWindow.ui
trunk/qcell/visgui/visgui.pro
Modified: trunk/qcell/visgui/MainWindow.cpp
===================================================================
--- trunk/qcell/visgui/MainWindow.cpp 2007-01-05 10:41:52 UTC (rev 94)
+++ trunk/qcell/visgui/MainWindow.cpp 2007-01-05 10:42:45 UTC (rev 95)
@@ -64,6 +64,7 @@
}
}
+ setupEngine();
}
@@ -118,7 +119,11 @@
fd.exec();
- callParser(fd.selectedFiles().first(), "Neighbourhood");
+ if(!fd.selectedFiles().isEmpty())
+ {
+ callParser(fd.selectedFiles().first(), "Neighbourhood");
+
+ }
}
void MainWindow::on_action_Function_activated()
@@ -157,6 +162,11 @@
fd.exec();
+ if(!fd.selectedFiles().isEmpty())
+ {
+ callParser(fd.selectedFiles().first(), "LocalFunction");
+
+ }
}
void MainWindow::on_action_World_activated()
@@ -195,6 +205,11 @@
fd.exec();
+ if(!fd.selectedFiles().isEmpty())
+ {
+ callParser(fd.selectedFiles().first(), "World");
+
+ }
}
void MainWindow::callParser(QString filename, QString type)
@@ -259,3 +274,90 @@
}
+void MainWindow::setupEngine()
+{
+ working = false;
+}
+
+void MainWindow::oneStep()
+{
+ /// @todo Write oneStep
+}
+
+void MainWindow::stepForward(int step)
+{
+ for(int i = 0; i < step; i++)
+ {
+ if(!working)
+ {
+ return;
+ }
+
+ oneStep();
+
+ // No freezing the app
+ if(qApp->hasPendingEvents())
+ {
+ qApp->processEvents();
+ }
+ }
+
+}
+
+void MainWindow::continousSteps()
+{
+ while(working)
+ {
+ oneStep();
+
+ // No freezing the app
+ if(qApp->hasPendingEvents())
+ {
+ qApp->processEvents();
+ }
+ }
+
+}
+
+void MainWindow::on_action_Forward_activated()
+{
+ oneStep();
+}
+
+void MainWindow::on_action_Back_activated()
+{
+ /// @todo Handle back movement
+}
+
+void MainWindow::on_action_Start_activated()
+{
+ QDialog* dialog = new QDialog(this);
+ Ui::ExperimentSetupDialog es;
+ es.setupUi(dialog);
+
+ if(dialog->exec() == QDialog::Accepted)
+ {
+ working = true;
+ if(es.continiuosCheckBox->isChecked())
+ {
+ continousSteps();
+ }
+ else
+ {
+ stepForward(es.iterationsSpinBox->value());
+ }
+ }
+
+}
+
+void MainWindow::on_action_Stop_activated()
+{
+ working=false;
+}
+
+void MainWindow::on_action_Restart_activated()
+{
+ /// @todo Handle restarting the experiment
+ CalculationData backup = data.first();
+}
+
Modified: trunk/qcell/visgui/MainWindow.h
===================================================================
--- trunk/qcell/visgui/MainWindow.h 2007-01-05 10:41:52 UTC (rev 94)
+++ trunk/qcell/visgui/MainWindow.h 2007-01-05 10:42:45 UTC (rev 95)
@@ -11,11 +11,17 @@
#include "ui_MainWindow.h"
#include "ui_AboutDialog.h"
+#include "ui_ExperimentSetup.h"
#include <QPluginLoader>
#include "GenericParserPlugin.h"
#include <QFileDialog>
#include <QMessageBox>
+#include <CalculationData.h>
+#include <LocalFunction.h>
+#include <Neighbourhood.h>
+#include <Renderer.h>
+
#include <iostream>
using namespace std;
@@ -35,13 +41,35 @@
void on_action_Function_activated();
void on_action_World_activated();
+ /// @todo not here!
+ void on_action_Forward_activated();
+ void on_action_Back_activated();
+
+ void on_action_Start_activated();
+ void on_action_Stop_activated();
+ void on_action_Restart_activated();
private:
QMap<QString, ParserInterface*> neighbourhood_parsers;
QMap<QString, ParserInterface*> function_parsers;
QMap<QString, ParserInterface*> world_parsers;
+
void callParser(QString filename, QString type);
+ /// @todo Not in here!
+ bool working;
+
+ QList<CalculationData> data;
+ LocalFunction* local_function;
+ Neighbourhood* neighbourhood;
+ Renderer* renderer;
+
+ void setupEngine();
+
+ void oneStep();
+ void stepForward(int step);
+ void continousSteps();
+
};
#endif
Modified: trunk/qcell/visgui/MainWindow.ui
===================================================================
--- trunk/qcell/visgui/MainWindow.ui 2007-01-05 10:41:52 UTC (rev 94)
+++ trunk/qcell/visgui/MainWindow.ui 2007-01-05 10:42:45 UTC (rev 95)
@@ -5,8 +5,8 @@
<rect>
<x>0</x>
<y>0</y>
- <width>557</width>
- <height>541</height>
+ <width>553</width>
+ <height>538</height>
</rect>
</property>
<property name="windowTitle" >
@@ -23,9 +23,6 @@
<property name="spacing" >
<number>6</number>
</property>
- <item>
- <widget class="QWidget" native="1" name="MainGLWidget" />
- </item>
</layout>
</widget>
<widget class="QMenuBar" name="mainMenubar" >
@@ -33,7 +30,7 @@
<rect>
<x>0</x>
<y>0</y>
- <width>557</width>
+ <width>553</width>
<height>30</height>
</rect>
</property>
@@ -44,6 +41,11 @@
<addaction name="separator" />
<addaction name="action_About" />
</widget>
+ <widget class="QMenu" name="menu_Edit" >
+ <property name="title" >
+ <string>&Edit</string>
+ </property>
+ </widget>
<widget class="QMenu" name="menu_File" >
<property name="title" >
<string>&File</string>
@@ -65,20 +67,36 @@
<addaction name="separator" />
<addaction name="action_Quit" />
</widget>
+ <widget class="QMenu" name="menu_Experiment" >
+ <property name="title" >
+ <string>&Experiment</string>
+ </property>
+ <addaction name="action_Start" />
+ <addaction name="action_Stop" />
+ <addaction name="action_Restart" />
+ <addaction name="separator" />
+ <addaction name="action_Forward" />
+ <addaction name="action_Back" />
+ </widget>
<addaction name="menu_File" />
+ <addaction name="menu_Edit" />
+ <addaction name="menu_Experiment" />
<addaction name="menu_Help" />
</widget>
<widget class="QStatusBar" name="statusbar" />
- <widget class="QToolBar" name="mainToolBar" >
- <property name="toolTip" >
- <string>This menu allows searching through help topics and reading about the application.</string>
- </property>
+ <widget class="QToolBar" name="toolBar" >
<property name="orientation" >
<enum>Qt::Horizontal</enum>
</property>
<attribute name="toolBarArea" >
<number>4</number>
</attribute>
+ <addaction name="action_Start" />
+ <addaction name="action_Stop" />
+ <addaction name="action_Restart" />
+ <addaction name="separator" />
+ <addaction name="action_Forward" />
+ <addaction name="action_Back" />
</widget>
<action name="action_Quit" >
<property name="text" >
@@ -139,6 +157,61 @@
<string>Shows info about the program.</string>
</property>
</action>
+ <action name="action_Start" >
+ <property name="text" >
+ <string>&Start</string>
+ </property>
+ <property name="toolTip" >
+ <string>Starts the experiment.</string>
+ </property>
+ <property name="statusTip" >
+ <string>Starts the experiment.</string>
+ </property>
+ </action>
+ <action name="action_Stop" >
+ <property name="text" >
+ <string>S&top</string>
+ </property>
+ <property name="toolTip" >
+ <string>Stops the experiment.</string>
+ </property>
+ <property name="statusTip" >
+ <string>Stops the experiment.</string>
+ </property>
+ </action>
+ <action name="action_Restart" >
+ <property name="text" >
+ <string>&Restart</string>
+ </property>
+ <property name="toolTip" >
+ <string>Restarts the experiment.</string>
+ </property>
+ <property name="statusTip" >
+ <string>Restarts the experiment.</string>
+ </property>
+ </action>
+ <action name="action_Forward" >
+ <property name="text" >
+ <string>&Forward</string>
+ </property>
+ <property name="toolTip" >
+ <string>Iterates one setp forward.</string>
+ </property>
+ <property name="statusTip" >
+ <string>Iterates one setp forward.</string>
+ </property>
+ </action>
+ <action name="action_Back" >
+ <property name="text" >
+ <string>&Back</string>
+ </property>
+ <property name="toolTip" >
+ <string>Iterates one setp back.</string>
+ </property>
+ <property name="statusTip" >
+ <string>Iterates one setp back.</string>
+ </property>
+ </action>
</widget>
<resources/>
<connections/>
Modified: trunk/qcell/visgui/visgui.pro
===================================================================
--- trunk/qcell/visgui/visgui.pro 2007-01-05 10:41:52 UTC (rev 94)
+++ trunk/qcell/visgui/visgui.pro 2007-01-05 10:42:45 UTC (rev 95)
@@ -1,12 +1,13 @@
TEMPLATE = app
DESTDIR = ../bin
CONFIG += thread warn_on debug
-QT += network xml
+QT += network xml opengl
INCLUDEPATH = ../baseheaders
FORMS = MainWindow.ui \
- AboutDialog.ui
+ AboutDialog.ui \
+ ExperimentSetup.ui
HEADERS = MainWindow.h \
../baseheaders/Client.h \
../baseheaders/ClientInfo.h \
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <dhu...@us...> - 2007-01-05 10:45:02
|
Revision: 96
http://svn.sourceforge.net/qcell/?rev=96&view=rev
Author: dhubleizh
Date: 2007-01-05 02:44:59 -0800 (Fri, 05 Jan 2007)
Log Message:
-----------
- translation of new ExperimentSetup dialog
Modified Paths:
--------------
trunk/qcell/visgui/visgui_pl.qm
trunk/qcell/visgui/visgui_pl.ts
Modified: trunk/qcell/visgui/visgui_pl.qm
===================================================================
(Binary files differ)
Modified: trunk/qcell/visgui/visgui_pl.ts
===================================================================
--- trunk/qcell/visgui/visgui_pl.ts 2007-01-05 10:42:45 UTC (rev 95)
+++ trunk/qcell/visgui/visgui_pl.ts 2007-01-05 10:44:59 UTC (rev 96)
@@ -37,6 +37,24 @@
</message>
</context>
<context>
+ <name>ExperimentSetupDialog</name>
+ <message>
+ <location filename="ExperimentSetup.ui" line="13"/>
+ <source>Experiment setup</source>
+ <translation>Przygotowanie eksperymentu</translation>
+ </message>
+ <message>
+ <location filename="ExperimentSetup.ui" line="33"/>
+ <source>Number of iterations</source>
+ <translation>Liczba iteracji</translation>
+ </message>
+ <message>
+ <location filename="ExperimentSetup.ui" line="59"/>
+ <source>Continuos Experiment</source>
+ <translation>Eksperyment Ciągły</translation>
+ </message>
+</context>
+<context>
<name>GenericParserPlugin</name>
<message>
<location filename="../baseheaders/GenericParserPlugin.h" line="61"/>
@@ -44,14 +62,14 @@
<translation>Typ wtyczki %1 nie jest wspierany przez te wtyczkę.</translation>
</message>
<message>
- <location filename="../basesources/GenericParserPlugin.cpp" line="69"/>
+ <location filename="../basesources/GenericParserPlugin.cpp" line="67"/>
<source>This plugin doesn't support parsing of type %1. It supports %2.</source>
<translation>Ta wtyczka nie obsługuję parsowania typu %1. Wspiera typ %2.</translation>
</message>
<message>
<location filename="../basesources/GenericParserPlugin.cpp" line="34"/>
<source>Here I am!</source>
- <translation>Tutaj jestem!</translation>
+ <translation type="obsolete">Tutaj jestem!</translation>
</message>
</context>
<context>
@@ -62,108 +80,108 @@
<translation>QCell</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="42"/>
+ <location filename="MainWindow.ui" line="39"/>
<source>&Help</source>
<translation>P&omoc</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="49"/>
+ <location filename="MainWindow.ui" line="51"/>
<source>&File</source>
<translation>&Plik</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="53"/>
+ <location filename="MainWindow.ui" line="55"/>
<source>Opens experiment data.</source>
<translation>Otwiera dane eksperymentu.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="56"/>
+ <location filename="MainWindow.ui" line="58"/>
<source>&Open</source>
<translation>&Otwórz</translation>
</message>
<message>
<location filename="MainWindow.ui" line="74"/>
<source>This menu allows searching through help topics and reading about the application.</source>
- <translation>To menu pozwala przeszukiwać tematy pomocy i poczytać o aplikacji.</translation>
+ <translation type="obsolete">To menu pozwala przeszukiwać tematy pomocy i poczytać o aplikacji.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="85"/>
+ <location filename="MainWindow.ui" line="103"/>
<source>&Quit</source>
<translation>&Wyjście</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="88"/>
+ <location filename="MainWindow.ui" line="106"/>
<source>This menu item quits the application.</source>
<comment>Quits the application</comment>
<translation>Ten przycisk menu powoduje wyjście z aplikacji.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="91"/>
+ <location filename="MainWindow.ui" line="109"/>
<source>Quits the application.</source>
<translation>Wychodzi z aplikacji.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="96"/>
+ <location filename="MainWindow.ui" line="114"/>
<source>&Neighbourhood</source>
<translation>&Sąsiedztwo</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="99"/>
+ <location filename="MainWindow.ui" line="117"/>
<source>Opens neighbourhood.</source>
<translation>Otwiera plik sąsiedztwa.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="104"/>
+ <location filename="MainWindow.ui" line="122"/>
<source>&Function</source>
<translation>&Funkcja</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="107"/>
+ <location filename="MainWindow.ui" line="125"/>
<source>Opens function.</source>
<translation>Otwiera plik funkcji.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="112"/>
+ <location filename="MainWindow.ui" line="130"/>
<source>&World</source>
<translation>Ś&wiat</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="115"/>
+ <location filename="MainWindow.ui" line="133"/>
<source>Opens world configuration.</source>
<translation>Otwiera konfigurację świata.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="120"/>
+ <location filename="MainWindow.ui" line="138"/>
<source>Open &experiment</source>
<translation>Otwórz &eksperyment</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="123"/>
+ <location filename="MainWindow.ui" line="141"/>
<source>Opens a predefined experiment.</source>
<translation>Otwiera zdefiniowany wcześniej eksperyment.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="128"/>
+ <location filename="MainWindow.ui" line="146"/>
<source>&Continiue experiment</source>
<translation>&Kontynuuj eksperyment</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="131"/>
+ <location filename="MainWindow.ui" line="149"/>
<source>Loads an earlier saved experiment.</source>
<translation>Ładuje wcześniej zachowany eksperyment.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="136"/>
+ <location filename="MainWindow.ui" line="154"/>
<source>&About</source>
<translation>&O programie</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="139"/>
+ <location filename="MainWindow.ui" line="157"/>
<source>Shows info about the program.</source>
<translation>Pokazuje informacje o programie.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="105"/>
+ <location filename="MainWindow.cpp" line="102"/>
<source>Open Neighbourhood</source>
<translation>Otwórz Sąsiedztwo</translation>
</message>
@@ -173,75 +191,140 @@
<translation type="obsolete"> pliki</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="195"/>
+ <location filename="MainWindow.cpp" line="201"/>
<source>files</source>
<translation>pliki</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="172"/>
+ <location filename="MainWindow.cpp" line="178"/>
<source>Plugins warning</source>
- <translation type="unfinished"></translation>
+ <translation>Ostrzeżenie wtyczek</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="97"/>
+ <location filename="MainWindow.cpp" line="94"/>
<source>There are no plugins loaded to handle Neighbourhood parsing.</source>
<translation>Nie ma załadowanej żadnej wtyczki do obsługi parsowania plików Sąsiedztwa.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="136"/>
+ <location filename="MainWindow.cpp" line="137"/>
<source>There are no plugins loaded to handle Function parsing.</source>
<translation>Nie ma załadowanej żadnej wtyczki do obsługi parsowania Funkcji.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="144"/>
+ <location filename="MainWindow.cpp" line="145"/>
<source>Open Function</source>
<translation>Otwórz Funkcję</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="174"/>
+ <location filename="MainWindow.cpp" line="180"/>
<source>There are no plugins loaded to handle World parsing.</source>
<translation>Nie ma załadowanej żadnej wtyczki do parsowania Świata.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="182"/>
+ <location filename="MainWindow.cpp" line="188"/>
<source>Open World</source>
<translation>Otwórz Świat</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="213"/>
+ <location filename="MainWindow.cpp" line="224"/>
<source>Error opening file %1.</source>
<translation>Błąd podczas otwierania pliku %1.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="251"/>
+ <location filename="MainWindow.cpp" line="261"/>
<source>The file extensions %1 isn't supported.</source>
<translation>Rozszerzenie pliku %1 nie jest wspierane.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="261"/>
+ <location filename="MainWindow.cpp" line="271"/>
<source>Unsupported file type to parse.</source>
<translation>Niewspierany typ pliku do przeczytania.</translation>
</message>
+ <message>
+ <location filename="MainWindow.ui" line="46"/>
+ <source>&Edit</source>
+ <translation>&Edycja</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="72"/>
+ <source>&Experiment</source>
+ <translation>&Eksperyment</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="162"/>
+ <source>&Start</source>
+ <translation>&Start</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="168"/>
+ <source>Starts the experiment.</source>
+ <translation>Startuje eksperyment.</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="173"/>
+ <source>S&top</source>
+ <translation>S&top</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="179"/>
+ <source>Stops the experiment.</source>
+ <translation>Zatrzymuje eksperyment.</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="184"/>
+ <source>&Restart</source>
+ <translation>Ponowne u&ruchominie</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="190"/>
+ <source>Restarts the experiment.</source>
+ <translation>Uruchamia eksperyment od nowa.</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="195"/>
+ <source>&Forward</source>
+ <translation>Do &przodu</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="198"/>
+ <source>Iterates one setp.</source>
+ <translation type="obsolete">Iteruje jeden krok.</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="201"/>
+ <source>Iterates one setp forward.</source>
+ <translation>Iteruje jeden krok do przodu.</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="206"/>
+ <source>&Back</source>
+ <translation>Do &tyłu</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="212"/>
+ <source>Iterates one setp back.</source>
+ <translation>Iteruje jeden krok wstecz.</translation>
+ </message>
</context>
<context>
<name>QApplication</name>
<message>
- <location filename="main.cpp" line="65"/>
+ <location filename="main.cpp" line="59"/>
<source>Debug</source>
<translation>Odpluskwianie</translation>
</message>
<message>
- <location filename="main.cpp" line="68"/>
+ <location filename="main.cpp" line="62"/>
<source>Warning</source>
<translation>Ostrzeżenie</translation>
</message>
<message>
- <location filename="main.cpp" line="71"/>
+ <location filename="main.cpp" line="65"/>
<source>Critical</source>
<translation>Krytyczny</translation>
</message>
<message>
- <location filename="main.cpp" line="74"/>
+ <location filename="main.cpp" line="68"/>
<source>Fatal</source>
<translation>Śmiertelny</translation>
</message>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <dhu...@us...> - 2007-01-10 14:20:08
|
Revision: 137
http://svn.sourceforge.net/qcell/?rev=137&view=rev
Author: dhubleizh
Date: 2007-01-10 06:20:03 -0800 (Wed, 10 Jan 2007)
Log Message:
-----------
- change in UI: iterationLCD isn't included in .ui file, but added manually to the status bar
- minor changes to update this LCD
- file loading test and some info for the user if succes or failure
- some actions disabled by default; enabling them on proper file load
- experiment actions enabled only after all thre elements loaded
Modified Paths:
--------------
trunk/qcell/visgui/MainWindow.cpp
trunk/qcell/visgui/MainWindow.h
trunk/qcell/visgui/MainWindow.ui
Modified: trunk/qcell/visgui/MainWindow.cpp
===================================================================
--- trunk/qcell/visgui/MainWindow.cpp 2007-01-10 12:33:32 UTC (rev 136)
+++ trunk/qcell/visgui/MainWindow.cpp 2007-01-10 14:20:03 UTC (rev 137)
@@ -11,12 +11,17 @@
MainWindow::MainWindow(QWidget* parent)
{
// GUI setup - earlies possible to show the user, that we're in buisness
- setupUi(this);
+ setupUi(this);
sw = new simulationWindow(this);
- QLayoutItem* tmp = centralWidget()->layout()->takeAt(0);
centralWidget()->layout()->addWidget(sw);
- centralWidget()->layout()->addItem(tmp);
+
+ // Adding iteration counter
+ statusBar()->addPermanentWidget(new QLabel(tr("Iteration")));
+ iterationLCD = new QLCDNumber();
+ iterationLCD->setSegmentStyle(QLCDNumber::Flat);
+ statusBar()->addPermanentWidget(iterationLCD);
+
// Plugin parsing
/// @todo get that code out of here!
ParserInterface* iParser;
@@ -247,9 +252,21 @@
}
neighbourhood = new Neighbourhood;
- neighbourhood->fromXmlString(&neighbourhood_parsers[subtype]->parse(file_content, type, subtype));
+ if (!neighbourhood->fromXmlString(&neighbourhood_parsers[subtype]->parse(file_content, type, subtype)))
+ {
+ qDebug(tr("Internal error: unable to parse %1 file")
+ .arg(type)
+ .toAscii()
+ );
+
+ return;
+ }
+
calc.setNeighbourhood(neighbourhood);
+ // Enable saving menu for Neighbourhood
+ menu_Save_experiment->setEnabled(true);
+ action_Neighbourhood_save->setEnabled(true);
}
else if (type == "LocalFunction")
{
@@ -263,7 +280,20 @@
}
local_function = new LocalFunction();
- local_function->fromXmlString(&function_parsers[subtype]->parse(file_content, type, subtype));
+ if (!local_function->fromXmlString(&function_parsers[subtype]->parse(file_content, type, subtype)))
+ {
+ qDebug(tr("Internal error: unable to parse %1 file")
+ .arg(type)
+ .toAscii()
+ );
+
+ return;
+ }
+
+ // Enable saving menu for LocalFunction
+ menu_Save_experiment->setEnabled(true);
+ action_Function_save->setEnabled(true);
+
calc.setLocalFunction(local_function);
}
else if (type == "World")
@@ -279,6 +309,18 @@
/// @todo Fix that!
data.clear();
+ /// @todo Get rid of that ugly hack!
+ QString XMLString = world_parsers[subtype]->parse(file_content, type, subtype);
+ /// @todo Nasty - get that code out of here !
+ if(XMLString.isEmpty())
+ {
+ qDebug(tr("The file extensions %1 isn't supported.")
+ .arg(subtype)
+ .toAscii()
+ );
+ return;
+ }
+
data.append((CalculationData*)world_parsers[subtype]->parse(file_content, type, subtype).toInt());
*sw->getStorage() = *data.last();
calc.setForeignDataPointer((char*)data.first()->getDataPointer());
@@ -287,14 +329,19 @@
<< data.last()->getSizeY()
<< data.last()->getSizeZ();
calc.setCalculationSpace(*new QVector<int>(3, 0), end_coord);
- /// @todo Nasty - get that code out of here !
+
+ // Enable saving menu for World
+ menu_Save_experiment->setEnabled(true);
+ action_World_save->setEnabled(true);
}
else
{
qDebug(tr("Unsupported file type to parse.").toAscii());
return;
}
-
+
+ unlockExperiment();
+ loadingSuccess(type);
}
void MainWindow::callSaver(const QString filename, const QString type)
@@ -361,10 +408,34 @@
}
}
+void MainWindow::unlockExperiment()
+{
+ if((!data.isEmpty()) && (neighbourhood != NULL) && (local_function != NULL))
+ {
+ menu_Experiment->setEnabled(true);
+ foreach(QAction* action, menu_Experiment->actions())
+ {
+ action->setEnabled(true);
+ }
+ }
+}
+
+void MainWindow::loadingSuccess(QString filetype)
+{
+ statusBar()->showMessage(tr(QString("%1 file loaded sucesfully!")
+ .arg(filetype)
+ .toAscii())
+ );
+}
+
void MainWindow::setupEngine()
{
working = false;
iteration = 0;
+
+ // Set all data pointers to NULL, as unlockExperiment depends on it!
+ neighbourhood = NULL;
+ local_function = NULL;
}
void MainWindow::oneStep(int direction)
@@ -479,7 +550,7 @@
void MainWindow::on_action_Restart_activated()
{
iteration = 0;
- this->iterationLCD->display(iteration);
+ iterationLCD->display(iteration);
CalculationData* backup = data.first();
data.clear();
Modified: trunk/qcell/visgui/MainWindow.h
===================================================================
--- trunk/qcell/visgui/MainWindow.h 2007-01-10 12:33:32 UTC (rev 136)
+++ trunk/qcell/visgui/MainWindow.h 2007-01-10 14:20:03 UTC (rev 137)
@@ -51,8 +51,11 @@
void on_action_Start_activated();
void on_action_Stop_activated();
void on_action_Restart_activated();
+
+ void loadingSuccess(QString filetype);
private:
simulationWindow* sw;
+ QLCDNumber* iterationLCD;
QMap<QString, ParserInterface*> neighbourhood_parsers;
QMap<QString, ParserInterface*> function_parsers;
QMap<QString, ParserInterface*> world_parsers;
@@ -60,6 +63,7 @@
void callParser(QString filename, QString type);
void callSaver(const QString filename, const QString type);
+ void unlockExperiment();
/// @todo Not in here!
enum Direction
Modified: trunk/qcell/visgui/MainWindow.ui
===================================================================
--- trunk/qcell/visgui/MainWindow.ui 2007-01-10 12:33:32 UTC (rev 136)
+++ trunk/qcell/visgui/MainWindow.ui 2007-01-10 14:20:03 UTC (rev 137)
@@ -23,46 +23,6 @@
<property name="spacing" >
<number>6</number>
</property>
- <item>
- <layout class="QHBoxLayout" >
- <property name="margin" >
- <number>0</number>
- </property>
- <property name="spacing" >
- <number>6</number>
- </property>
- <item>
- <spacer>
- <property name="orientation" >
- <enum>Qt::Horizontal</enum>
- </property>
- <property name="sizeHint" >
- <size>
- <width>321</width>
- <height>20</height>
- </size>
- </property>
- </spacer>
- </item>
- <item>
- <widget class="QLabel" name="iterationLabel" >
- <property name="text" >
- <string>Iteration</string>
- </property>
- </widget>
- </item>
- <item>
- <widget class="QLCDNumber" name="iterationLCD" >
- <property name="numDigits" >
- <number>5</number>
- </property>
- <property name="segmentStyle" >
- <enum>QLCDNumber::Flat</enum>
- </property>
- </widget>
- </item>
- </layout>
- </item>
</layout>
</widget>
<widget class="QMenuBar" name="mainMenubar" >
@@ -74,12 +34,17 @@
<height>30</height>
</rect>
</property>
- <widget class="QMenu" name="menu_Edit" >
+ <widget class="QMenu" name="menu_Help" >
<property name="title" >
- <string>&Edit</string>
+ <string>&Help</string>
</property>
+ <addaction name="separator" />
+ <addaction name="action_About" />
</widget>
<widget class="QMenu" name="menu_Experiment" >
+ <property name="enabled" >
+ <bool>false</bool>
+ </property>
<property name="title" >
<string>&Experiment</string>
</property>
@@ -90,13 +55,6 @@
<addaction name="action_Forward" />
<addaction name="action_Back" />
</widget>
- <widget class="QMenu" name="menu_Help" >
- <property name="title" >
- <string>&Help</string>
- </property>
- <addaction name="separator" />
- <addaction name="action_About" />
- </widget>
<widget class="QMenu" name="menu_File" >
<property name="title" >
<string>&File</string>
@@ -113,6 +71,9 @@
<addaction name="action_Function" />
</widget>
<widget class="QMenu" name="menu_Save_experiment" >
+ <property name="enabled" >
+ <bool>false</bool>
+ </property>
<property name="title" >
<string>&Save experiment</string>
</property>
@@ -128,7 +89,6 @@
<addaction name="action_Quit" />
</widget>
<addaction name="menu_File" />
- <addaction name="menu_Edit" />
<addaction name="menu_Experiment" />
<addaction name="menu_Help" />
</widget>
@@ -183,6 +143,9 @@
</property>
</action>
<action name="action_Open_experiment" >
+ <property name="enabled" >
+ <bool>false</bool>
+ </property>
<property name="text" >
<string>Open &experiment</string>
</property>
@@ -207,6 +170,9 @@
</property>
</action>
<action name="action_Start" >
+ <property name="enabled" >
+ <bool>false</bool>
+ </property>
<property name="text" >
<string>&Start</string>
</property>
@@ -218,6 +184,9 @@
</property>
</action>
<action name="action_Stop" >
+ <property name="enabled" >
+ <bool>false</bool>
+ </property>
<property name="text" >
<string>S&top</string>
</property>
@@ -229,6 +198,9 @@
</property>
</action>
<action name="action_Restart" >
+ <property name="enabled" >
+ <bool>false</bool>
+ </property>
<property name="text" >
<string>&Restart</string>
</property>
@@ -240,6 +212,9 @@
</property>
</action>
<action name="action_Forward" >
+ <property name="enabled" >
+ <bool>false</bool>
+ </property>
<property name="text" >
<string>&Forward</string>
</property>
@@ -251,6 +226,9 @@
</property>
</action>
<action name="action_Back" >
+ <property name="enabled" >
+ <bool>false</bool>
+ </property>
<property name="text" >
<string>&Back</string>
</property>
@@ -262,16 +240,25 @@
</property>
</action>
<action name="action_World_save" >
+ <property name="enabled" >
+ <bool>false</bool>
+ </property>
<property name="text" >
<string>&World</string>
</property>
</action>
<action name="action_Neighbourhood_save" >
+ <property name="enabled" >
+ <bool>false</bool>
+ </property>
<property name="text" >
<string>&Neighbourhood</string>
</property>
</action>
<action name="action_Function_save" >
+ <property name="enabled" >
+ <bool>false</bool>
+ </property>
<property name="text" >
<string>&Function</string>
</property>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <dhu...@us...> - 2007-01-10 14:45:28
|
Revision: 138
http://svn.sourceforge.net/qcell/?rev=138&view=rev
Author: dhubleizh
Date: 2007-01-10 06:45:17 -0800 (Wed, 10 Jan 2007)
Log Message:
-----------
- label added before interation LCD counter
- satus bar tooltips added for both LCD and label
- translated new LCD related strings
Modified Paths:
--------------
trunk/qcell/visgui/MainWindow.cpp
trunk/qcell/visgui/MainWindow.ui
trunk/qcell/visgui/visgui_pl.qm
trunk/qcell/visgui/visgui_pl.ts
Modified: trunk/qcell/visgui/MainWindow.cpp
===================================================================
--- trunk/qcell/visgui/MainWindow.cpp 2007-01-10 14:20:03 UTC (rev 137)
+++ trunk/qcell/visgui/MainWindow.cpp 2007-01-10 14:45:17 UTC (rev 138)
@@ -9,6 +9,7 @@
#include "MainWindow.h"
MainWindow::MainWindow(QWidget* parent)
+ :QMainWindow(parent)
{
// GUI setup - earlies possible to show the user, that we're in buisness
setupUi(this);
@@ -17,9 +18,14 @@
centralWidget()->layout()->addWidget(sw);
// Adding iteration counter
- statusBar()->addPermanentWidget(new QLabel(tr("Iteration")));
+ // Creating LCD counter
iterationLCD = new QLCDNumber();
iterationLCD->setSegmentStyle(QLCDNumber::Flat);
+ iterationLCD->setStatusTip(tr("Shows the current iteration number."));
+ QLabel* tmp_label = new QLabel(tr("Iteration"));
+ tmp_label->setBuddy(iterationLCD);
+ tmp_label->setStatusTip(iterationLCD->statusTip());
+ statusBar()->addPermanentWidget(tmp_label);
statusBar()->addPermanentWidget(iterationLCD);
// Plugin parsing
@@ -422,9 +428,9 @@
void MainWindow::loadingSuccess(QString filetype)
{
- statusBar()->showMessage(tr(QString("%1 file loaded sucesfully!")
+ statusBar()->showMessage(tr("%1 file loaded sucesfully!")
.arg(filetype)
- .toAscii())
+ .toAscii()
);
}
Modified: trunk/qcell/visgui/MainWindow.ui
===================================================================
--- trunk/qcell/visgui/MainWindow.ui 2007-01-10 14:20:03 UTC (rev 137)
+++ trunk/qcell/visgui/MainWindow.ui 2007-01-10 14:45:17 UTC (rev 138)
@@ -34,13 +34,6 @@
<height>30</height>
</rect>
</property>
- <widget class="QMenu" name="menu_Help" >
- <property name="title" >
- <string>&Help</string>
- </property>
- <addaction name="separator" />
- <addaction name="action_About" />
- </widget>
<widget class="QMenu" name="menu_Experiment" >
<property name="enabled" >
<bool>false</bool>
@@ -88,6 +81,13 @@
<addaction name="separator" />
<addaction name="action_Quit" />
</widget>
+ <widget class="QMenu" name="menu_Help" >
+ <property name="title" >
+ <string>&Help</string>
+ </property>
+ <addaction name="separator" />
+ <addaction name="action_About" />
+ </widget>
<addaction name="menu_File" />
<addaction name="menu_Experiment" />
<addaction name="menu_Help" />
Modified: trunk/qcell/visgui/visgui_pl.qm
===================================================================
(Binary files differ)
Modified: trunk/qcell/visgui/visgui_pl.ts
===================================================================
--- trunk/qcell/visgui/visgui_pl.ts 2007-01-10 14:20:03 UTC (rev 137)
+++ trunk/qcell/visgui/visgui_pl.ts 2007-01-10 14:45:17 UTC (rev 138)
@@ -26,12 +26,12 @@
<context>
<name>AboutDialog</name>
<message>
- <location filename="AboutDialog.ui" line="13"/>
+ <location filename="AboutDialog.ui" line="16"/>
<source>About QCell</source>
<translation>O Qcell</translation>
</message>
<message>
- <location filename="AboutDialog.ui" line="72"/>
+ <location filename="AboutDialog.ui" line="90"/>
<source>&OK</source>
<translation>&OK</translation>
</message>
@@ -85,22 +85,22 @@
<translation>QCell</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="95"/>
+ <location filename="MainWindow.ui" line="86"/>
<source>&Help</source>
<translation>P&omoc</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="102"/>
+ <location filename="MainWindow.ui" line="53"/>
<source>&File</source>
<translation>&Plik</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="106"/>
+ <location filename="MainWindow.ui" line="57"/>
<source>Opens experiment data.</source>
<translation>Otwiera dane eksperymentu.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="109"/>
+ <location filename="MainWindow.ui" line="60"/>
<source>&Open</source>
<translation>&Otwórz</translation>
</message>
@@ -110,83 +110,83 @@
<translation type="obsolete">To menu pozwala przeszukiwać tematy pomocy i poczytać o aplikacji.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="152"/>
+ <location filename="MainWindow.ui" line="112"/>
<source>&Quit</source>
<translation>&Wyjście</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="155"/>
+ <location filename="MainWindow.ui" line="115"/>
<source>This menu item quits the application.</source>
<comment>Quits the application</comment>
<translation>Ten przycisk menu powoduje wyjście z aplikacji.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="158"/>
+ <location filename="MainWindow.ui" line="118"/>
<source>Quits the application.</source>
<translation>Wychodzi z aplikacji.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="271"/>
+ <location filename="MainWindow.ui" line="255"/>
<source>&Neighbourhood</source>
<translation>&Sąsiedztwo</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="166"/>
+ <location filename="MainWindow.ui" line="126"/>
<source>Opens neighbourhood.</source>
<translation>Otwiera plik sąsiedztwa.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="276"/>
+ <location filename="MainWindow.ui" line="263"/>
<source>&Function</source>
<translation>&Funkcja</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="174"/>
+ <location filename="MainWindow.ui" line="134"/>
<source>Opens function.</source>
<translation>Otwiera plik funkcji.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="266"/>
+ <location filename="MainWindow.ui" line="247"/>
<source>&World</source>
<translation>Ś&wiat</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="182"/>
+ <location filename="MainWindow.ui" line="142"/>
<source>Opens world configuration.</source>
<translation>Otwiera konfigurację świata.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="187"/>
+ <location filename="MainWindow.ui" line="150"/>
<source>Open &experiment</source>
<translation>Otwórz &eksperyment</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="190"/>
+ <location filename="MainWindow.ui" line="153"/>
<source>Opens a predefined experiment.</source>
<translation>Otwiera zdefiniowany wcześniej eksperyment.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="195"/>
+ <location filename="MainWindow.ui" line="158"/>
<source>&Continiue experiment</source>
<translation>&Kontynuuj eksperyment</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="198"/>
+ <location filename="MainWindow.ui" line="161"/>
<source>Loads an earlier saved experiment.</source>
<translation>Ładuje wcześniej zachowany eksperyment.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="203"/>
+ <location filename="MainWindow.ui" line="166"/>
<source>&About</source>
<translation>&O programie</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="206"/>
+ <location filename="MainWindow.ui" line="169"/>
<source>Shows info about the program.</source>
<translation>Pokazuje informacje o programie.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="104"/>
+ <location filename="MainWindow.cpp" line="115"/>
<source>Open Neighbourhood</source>
<translation>Otwórz Sąsiedztwo</translation>
</message>
@@ -196,97 +196,97 @@
<translation type="obsolete"> pliki</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="566"/>
+ <location filename="MainWindow.cpp" line="643"/>
<source>files</source>
<translation>pliki</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="542"/>
+ <location filename="MainWindow.cpp" line="619"/>
<source>Plugins warning</source>
<translation>Ostrzeżenie wtyczek</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="96"/>
+ <location filename="MainWindow.cpp" line="107"/>
<source>There are no plugins loaded to handle Neighbourhood parsing.</source>
<translation>Nie ma załadowanej żadnej wtyczki do obsługi parsowania plików Sąsiedztwa.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="139"/>
+ <location filename="MainWindow.cpp" line="150"/>
<source>There are no plugins loaded to handle Function parsing.</source>
<translation>Nie ma załadowanej żadnej wtyczki do obsługi parsowania Funkcji.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="147"/>
+ <location filename="MainWindow.cpp" line="158"/>
<source>Open Function</source>
<translation>Otwórz Funkcję</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="183"/>
+ <location filename="MainWindow.cpp" line="194"/>
<source>There are no plugins loaded to handle World parsing.</source>
<translation>Nie ma załadowanej żadnej wtyczki do parsowania Świata.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="191"/>
+ <location filename="MainWindow.cpp" line="202"/>
<source>Open World</source>
<translation>Otwórz Świat</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="230"/>
+ <location filename="MainWindow.cpp" line="241"/>
<source>Error opening file %1.</source>
<translation>Błąd podczas otwierania pliku %1.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="346"/>
+ <location filename="MainWindow.cpp" line="400"/>
<source>The file extensions %1 isn't supported.</source>
<translation>Rozszerzenie pliku %1 nie jest wspierane.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="357"/>
+ <location filename="MainWindow.cpp" line="411"/>
<source>Unsupported file type to parse.</source>
<translation>Niewspierany typ pliku do przeczytania.</translation>
</message>
<message>
<location filename="MainWindow.ui" line="79"/>
<source>&Edit</source>
- <translation>&Edycja</translation>
+ <translation type="obsolete">&Edycja</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="84"/>
+ <location filename="MainWindow.ui" line="42"/>
<source>&Experiment</source>
<translation>&Eksperyment</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="211"/>
+ <location filename="MainWindow.ui" line="177"/>
<source>&Start</source>
<translation>&Start</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="217"/>
+ <location filename="MainWindow.ui" line="183"/>
<source>Starts the experiment.</source>
<translation>Startuje eksperyment.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="222"/>
+ <location filename="MainWindow.ui" line="191"/>
<source>S&top</source>
<translation>S&top</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="228"/>
+ <location filename="MainWindow.ui" line="197"/>
<source>Stops the experiment.</source>
<translation>Zatrzymuje eksperyment.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="233"/>
+ <location filename="MainWindow.ui" line="205"/>
<source>&Restart</source>
<translation>Ponowne u&ruchominie</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="239"/>
+ <location filename="MainWindow.ui" line="211"/>
<source>Restarts the experiment.</source>
<translation>Uruchamia eksperyment od nowa.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="244"/>
+ <location filename="MainWindow.ui" line="219"/>
<source>&Forward</source>
<translation>Do &przodu</translation>
</message>
@@ -296,60 +296,75 @@
<translation type="obsolete">Iteruje jeden krok.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="250"/>
+ <location filename="MainWindow.ui" line="225"/>
<source>Iterates one setp forward.</source>
<translation>Iteruje jeden krok do przodu.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="255"/>
+ <location filename="MainWindow.ui" line="233"/>
<source>&Back</source>
<translation>Do &tyłu</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="261"/>
+ <location filename="MainWindow.ui" line="239"/>
<source>Iterates one setp back.</source>
<translation>Iteruje jeden krok wstecz.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="50"/>
+ <location filename="MainWindow.cpp" line="24"/>
<source>Iteration</source>
<translation>Iteracja</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="394"/>
+ <location filename="MainWindow.cpp" line="471"/>
<source>You cannot step back beyond the beginning of the experiment!</source>
<translation>Nie możesz cofnąc się poza początek eksperymentu!</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="307"/>
+ <location filename="MainWindow.cpp" line="361"/>
<source>Error opnening file %1.</source>
<translation>Błąd podczas próby otwarcia pliku %1.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="496"/>
+ <location filename="MainWindow.cpp" line="573"/>
<source>There are no plugins loaded to handle World saving.</source>
<translation>Nie ma załadowanej żadnej wtyczki do obsługi zapisywania plików świata.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="504"/>
+ <location filename="MainWindow.cpp" line="581"/>
<source>Save World</source>
<translation>Zapisz Świat</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="544"/>
+ <location filename="MainWindow.cpp" line="621"/>
<source>There are no plugins loaded to handle Neighbourhood saving.</source>
<translation>Nie ma załadowanych żadnych wtyczek do obsługi zapisywania Sąsiedztwa.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="552"/>
+ <location filename="MainWindow.cpp" line="629"/>
<source>Save Neighbourhood</source>
<translation>Zapisz Sąsiedztwo</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="117"/>
+ <location filename="MainWindow.ui" line="71"/>
<source>&Save experiment</source>
<translation>&Zapisz eksperyment</translation>
</message>
+ <message>
+ <location filename="MainWindow.cpp" line="291"/>
+ <source>Internal error: unable to parse %1 file</source>
+ <translation>Wewnętrzny błąd: nie mogę zrozumiec pliku %1</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.cpp" line="431"/>
+ <source>%1 file loaded sucesfully!</source>
+ <translation>Plik %1 załadowany poprawnie!</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.cpp" line="23"/>
+ <source>Shows the current iteration number.</source>
+ <translation type="unfinished">Pokazuje aktualny numer iteracji.</translation>
+ </message>
</context>
<context>
<name>QApplication</name>
@@ -382,27 +397,27 @@
<translation>%1</translation>
</message>
<message>
- <location filename="../basesources/simulationwindow.cpp" line="437"/>
+ <location filename="../basesources/simulationwindow.cpp" line="443"/>
<source>Value</source>
<translation>Wartość</translation>
</message>
<message>
- <location filename="../basesources/simulationwindow.cpp" line="438"/>
+ <location filename="../basesources/simulationwindow.cpp" line="444"/>
<source>Symbol</source>
<translation>Symbol</translation>
</message>
<message>
- <location filename="../basesources/simulationwindow.cpp" line="439"/>
+ <location filename="../basesources/simulationwindow.cpp" line="445"/>
<source>Color</source>
<translation>Kolor</translation>
</message>
<message>
- <location filename="../basesources/simulationwindow.cpp" line="440"/>
+ <location filename="../basesources/simulationwindow.cpp" line="446"/>
<source>Model</source>
<translation>Model</translation>
</message>
<message>
- <location filename="../basesources/simulationwindow.cpp" line="441"/>
+ <location filename="../basesources/simulationwindow.cpp" line="447"/>
<source>Hide Flag</source>
<translation>Flaga Ukrycia</translation>
</message>
@@ -410,77 +425,77 @@
<context>
<name>simulationWindowClass</name>
<message>
- <location filename="../baseheaders/simulationwindow.ui" line="13"/>
+ <location filename="../baseheaders/simulationwindow.ui" line="21"/>
<source>simulationWindow</source>
<translation>oknoSymulacji</translation>
</message>
<message>
- <location filename="../baseheaders/simulationwindow.ui" line="35"/>
+ <location filename="../baseheaders/simulationwindow.ui" line="43"/>
<source>3D View</source>
<translation>Widok 3D</translation>
</message>
<message>
- <location filename="../baseheaders/simulationwindow.ui" line="47"/>
+ <location filename="../baseheaders/simulationwindow.ui" line="63"/>
<source>Perspective</source>
<translation>Perspektywa</translation>
</message>
<message>
- <location filename="../baseheaders/simulationwindow.ui" line="63"/>
+ <location filename="../baseheaders/simulationwindow.ui" line="73"/>
<source>Ortho2D</source>
<translation>Orto2D</translation>
</message>
<message>
- <location filename="../baseheaders/simulationwindow.ui" line="69"/>
+ <location filename="../baseheaders/simulationwindow.ui" line="96"/>
<source>2D Text View</source>
<translation>Widok Tekstowy 2D</translation>
</message>
<message>
- <location filename="../baseheaders/simulationwindow.ui" line="94"/>
+ <location filename="../baseheaders/simulationwindow.ui" line="143"/>
<source>Z Plane</source>
<translation>Płaszczyzna Z</translation>
</message>
<message>
- <location filename="../baseheaders/simulationwindow.ui" line="175"/>
+ <location filename="../baseheaders/simulationwindow.ui" line="207"/>
<source>Values</source>
<translation>Wartości</translation>
</message>
<message>
- <location filename="../baseheaders/simulationwindow.ui" line="162"/>
+ <location filename="../baseheaders/simulationwindow.ui" line="217"/>
<source>Symbols</source>
<translation>Symbole</translation>
</message>
<message>
- <location filename="../baseheaders/simulationwindow.ui" line="191"/>
+ <location filename="../baseheaders/simulationwindow.ui" line="200"/>
<source>Enable Colors</source>
<translation>Uruchom Kolory</translation>
</message>
<message>
- <location filename="../baseheaders/simulationwindow.ui" line="145"/>
+ <location filename="../baseheaders/simulationwindow.ui" line="175"/>
<source>2D Graphics View</source>
<translation>Graficzny Widok 2D</translation>
</message>
<message>
- <location filename="../baseheaders/simulationwindow.ui" line="150"/>
+ <location filename="../baseheaders/simulationwindow.ui" line="180"/>
<source>1D Text View</source>
<translation>Widok Tekstowy 1D</translation>
</message>
<message>
- <location filename="../baseheaders/simulationwindow.ui" line="204"/>
+ <location filename="../baseheaders/simulationwindow.ui" line="224"/>
<source>Clear Memory</source>
<translation>Wyczyśc Pamięć</translation>
</message>
<message>
- <location filename="../baseheaders/simulationwindow.ui" line="210"/>
+ <location filename="../baseheaders/simulationwindow.ui" line="247"/>
<source>Symbols Configuration</source>
<translation>Konfiguracja Symboli</translation>
</message>
<message>
- <location filename="../baseheaders/simulationwindow.ui" line="222"/>
+ <location filename="../baseheaders/simulationwindow.ui" line="274"/>
<source>Remove Symbol</source>
<translation>Usuń Symbol</translation>
</message>
<message>
- <location filename="../baseheaders/simulationwindow.ui" line="235"/>
+ <location filename="../baseheaders/simulationwindow.ui" line="267"/>
<source>Add Symbol</source>
<translation>Dodaj Symbol</translation>
</message>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <dhu...@us...> - 2007-01-10 16:48:34
|
Revision: 139
http://svn.sourceforge.net/qcell/?rev=139&view=rev
Author: dhubleizh
Date: 2007-01-10 08:48:27 -0800 (Wed, 10 Jan 2007)
Log Message:
-----------
- saving and loading the whole experiment (de-/serialization)
- menu options to save/load
- handled actions
- CalculationData serialization still to make
Modified Paths:
--------------
trunk/qcell/visgui/MainWindow.cpp
trunk/qcell/visgui/MainWindow.h
trunk/qcell/visgui/MainWindow.ui
Modified: trunk/qcell/visgui/MainWindow.cpp
===================================================================
--- trunk/qcell/visgui/MainWindow.cpp 2007-01-10 14:45:17 UTC (rev 138)
+++ trunk/qcell/visgui/MainWindow.cpp 2007-01-10 16:48:27 UTC (rev 139)
@@ -245,6 +245,7 @@
}
file_content = file.readAll();
+ file.close();
if (type == "Neighbourhood")
{
@@ -271,7 +272,7 @@
calc.setNeighbourhood(neighbourhood);
// Enable saving menu for Neighbourhood
- menu_Save_experiment->setEnabled(true);
+ menu_Save->setEnabled(true);
action_Neighbourhood_save->setEnabled(true);
}
else if (type == "LocalFunction")
@@ -297,7 +298,7 @@
}
// Enable saving menu for LocalFunction
- menu_Save_experiment->setEnabled(true);
+ menu_Save->setEnabled(true);
action_Function_save->setEnabled(true);
calc.setLocalFunction(local_function);
@@ -337,7 +338,7 @@
calc.setCalculationSpace(*new QVector<int>(3, 0), end_coord);
// Enable saving menu for World
- menu_Save_experiment->setEnabled(true);
+ menu_Save->setEnabled(true);
action_World_save->setEnabled(true);
}
else
@@ -412,17 +413,23 @@
qDebug(tr("Unsupported file type to parse.").toAscii());
return;
}
+
+ file.close();
}
void MainWindow::unlockExperiment()
{
if((!data.isEmpty()) && (neighbourhood != NULL) && (local_function != NULL))
{
+ // The whole Experiment menu
menu_Experiment->setEnabled(true);
foreach(QAction* action, menu_Experiment->actions())
{
action->setEnabled(true);
}
+
+ // Whole experiment saving
+ action_Save_experiment->setEnabled(true);
}
}
@@ -664,3 +671,160 @@
}
+void MainWindow::on_action_Save_experiment_activated()
+{
+ QFileDialog fd(
+ /*parent*/ this,
+ /*cation*/ tr("Save Experiment"),
+ /*dir*/ "."
+ );
+
+ fd.setAcceptMode(QFileDialog::AcceptSave);
+ fd.setFileMode(QFileDialog::AnyFile);
+
+ // Cellular Automata Experiment
+ QString suffix = "CAE";
+ fd.setFilters(QStringList(tr("Experiment files (*.%1)")
+ .arg(suffix)
+ )
+ );
+
+ fd.setDefaultSuffix(suffix);
+
+ // Show the dialog
+ // If pressed OK
+ if(fd.exec())
+ {
+ if(!fd.selectedFiles().isEmpty())
+ {
+ // Try to open the selected file
+ QFile file(fd.selectedFiles().first());
+ if (!file.open(QIODevice::WriteOnly))
+ {
+ qDebug(tr("Error opening file %1.")
+ .arg(file.fileName())
+ .toAscii()
+ );
+ }
+
+ // Do the actual serializing
+ QByteArray content = serialize();
+ if (content.isEmpty())
+ {
+ qDebug(tr("Internal error: unable to serialize experiment")
+ .toAscii());
+ return;
+ }
+ // Write to file and close
+ file.write(content);
+ file.close();
+ }
+ }
+}
+
+void MainWindow::on_action_Continue_experiment_activated()
+{
+ QFileDialog fd(
+ /*parent*/ this,
+ /*cation*/ tr("Open Experiment"),
+ /*dir*/ "."
+ );
+
+ fd.setFileMode(QFileDialog::ExistingFile);
+
+ // Cellular Automata Experiment
+ QString suffix = "CAE";
+ fd.setFilters(QStringList(tr("Experiment files (*.%1)")
+ .arg(suffix)
+ )
+ );
+
+ fd.setDefaultSuffix(suffix);
+
+ // Show the dialog
+ // If pressed OK
+ if(fd.exec())
+ {
+ if(!fd.selectedFiles().isEmpty())
+ {
+ // Try to open the selected file
+ QFile file(fd.selectedFiles().first());
+ if (!file.open(QIODevice::ReadOnly))
+ {
+ qDebug(tr("Error opening file %1.")
+ .arg(file.fileName())
+ .toAscii()
+ );
+ }
+
+ // Do the actual serializing
+ deserialize(file.readAll());
+ file.close();
+ }
+ }
+}
+
+QByteArray MainWindow::serialize()
+{
+ /// @todo wait for CalculationData toXml method and serialize using XML
+ QByteArray result, data_portion;
+ QDataStream ds(&result, QIODevice::WriteOnly);
+
+ // Neighbourhood
+ data_portion = neighbourhood->toXmlString().toAscii();
+ ds << (qint32)data_portion.size();
+ ds.writeRawData(data_portion.data(), (int)data_portion.size());
+
+ // LocalFunction
+ data_portion = local_function->toXmlString().toAscii();
+ ds << (qint32)data_portion.size();
+ ds.writeRawData(data_portion.data(), (int)data_portion.size());
+
+ // CalculationData
+ /// @todo write CalculationData serialization
+
+ return result;
+}
+
+void MainWindow::deserialize(QByteArray content)
+{
+ /// @todo Wait for fromXml in CalculationData and user pure XML
+ QDataStream ds(&content, QIODevice::ReadOnly);
+ qint32 data_size;
+ QByteArray data_portion;
+
+ // Neighbourhood
+ ds >> data_size;
+ data_portion.resize(data_size);
+ ds.readRawData(data_portion.data(), (uint)data_size);
+
+ if (neighbourhood == NULL)
+ {
+ neighbourhood = new Neighbourhood();
+ }
+ if (!neighbourhood->fromXmlString(&QString(data_portion)))
+ {
+ qDebug(tr("Error deserializing Neighbourhood").toAscii());
+ return;
+ }
+
+ // LocalFunction
+ ds >> data_size;
+ data_portion.resize(data_size);
+ ds.readRawData(data_portion.data(), (uint)data_size);
+
+ if (local_function == NULL)
+ {
+ local_function = new LocalFunction();
+ }
+ if (!local_function->fromXmlString(&QString(data_portion)))
+ {
+ qDebug(tr("Error deserializing Local Function").toAscii());
+ return;
+ }
+
+ /// @todo deserialize CalculationData
+
+ statusBar()->showMessage(tr("Sucessfully loaded experiment for continuation.").toAscii());
+}
+
Modified: trunk/qcell/visgui/MainWindow.h
===================================================================
--- trunk/qcell/visgui/MainWindow.h 2007-01-10 14:45:17 UTC (rev 138)
+++ trunk/qcell/visgui/MainWindow.h 2007-01-10 16:48:27 UTC (rev 139)
@@ -44,6 +44,9 @@
void on_action_Neighbourhood_save_activated();
void on_action_Function_save_activated();
+ void on_action_Save_experiment_activated();
+ void on_action_Continue_experiment_activated();
+
/// @todo not here!
void on_action_Forward_activated();
void on_action_Back_activated();
@@ -86,6 +89,18 @@
void oneStep(int direction = Forward);
void stepForward(int step);
void continousSteps();
+ /**
+ * @brief Serializes whole experiment
+ *
+ * @return QByteArray with the serialized experiment
+ */
+ QByteArray serialize();
+ /**
+ * @brief Initializes the whole experiment from file
+ *
+ * @param content File content
+ */
+ void deserialize(QByteArray content);
};
Modified: trunk/qcell/visgui/MainWindow.ui
===================================================================
--- trunk/qcell/visgui/MainWindow.ui 2007-01-10 14:45:17 UTC (rev 138)
+++ trunk/qcell/visgui/MainWindow.ui 2007-01-10 16:48:27 UTC (rev 139)
@@ -48,6 +48,13 @@
<addaction name="action_Forward" />
<addaction name="action_Back" />
</widget>
+ <widget class="QMenu" name="menu_Help" >
+ <property name="title" >
+ <string>&Help</string>
+ </property>
+ <addaction name="separator" />
+ <addaction name="action_About" />
+ </widget>
<widget class="QMenu" name="menu_File" >
<property name="title" >
<string>&File</string>
@@ -63,12 +70,12 @@
<addaction name="action_Neighbourhood" />
<addaction name="action_Function" />
</widget>
- <widget class="QMenu" name="menu_Save_experiment" >
+ <widget class="QMenu" name="menu_Save" >
<property name="enabled" >
<bool>false</bool>
</property>
<property name="title" >
- <string>&Save experiment</string>
+ <string>&Save</string>
</property>
<addaction name="action_World_save" />
<addaction name="action_Neighbourhood_save" />
@@ -76,18 +83,12 @@
</widget>
<addaction name="menu_Open" />
<addaction name="action_Open_experiment" />
- <addaction name="action_Continiue_experiment" />
- <addaction name="menu_Save_experiment" />
+ <addaction name="action_Continue_experiment" />
+ <addaction name="menu_Save" />
+ <addaction name="action_Save_experiment" />
<addaction name="separator" />
<addaction name="action_Quit" />
</widget>
- <widget class="QMenu" name="menu_Help" >
- <property name="title" >
- <string>&Help</string>
- </property>
- <addaction name="separator" />
- <addaction name="action_About" />
- </widget>
<addaction name="menu_File" />
<addaction name="menu_Experiment" />
<addaction name="menu_Help" />
@@ -153,10 +154,16 @@
<string>Opens a predefined experiment.</string>
</property>
</action>
- <action name="action_Continiue_experiment" >
+ <action name="action_Continue_experiment" >
<property name="text" >
- <string>&Continiue experiment</string>
+ <string>&Continue experiment</string>
</property>
+ <property name="iconText" >
+ <string>Continue experiment</string>
+ </property>
+ <property name="toolTip" >
+ <string>Continue experiment</string>
+ </property>
<property name="statusTip" >
<string>Loads an earlier saved experiment.</string>
</property>
@@ -263,6 +270,17 @@
<string>&Function</string>
</property>
</action>
+ <action name="action_Save_experiment" >
+ <property name="enabled" >
+ <bool>false</bool>
+ </property>
+ <property name="text" >
+ <string>Sa&ve experiment</string>
+ </property>
+ <property name="statusTip" >
+ <string>Saves the whole experiment with history for later continuation.</string>
+ </property>
+ </action>
</widget>
<resources/>
<connections/>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <dhu...@us...> - 2007-01-10 20:59:52
|
Revision: 143
http://svn.sourceforge.net/qcell/?rev=143&view=rev
Author: dhubleizh
Date: 2007-01-10 12:59:44 -0800 (Wed, 10 Jan 2007)
Log Message:
-----------
- stepping now honors delays
Modified Paths:
--------------
trunk/qcell/visgui/MainWindow.cpp
trunk/qcell/visgui/MainWindow.h
Modified: trunk/qcell/visgui/MainWindow.cpp
===================================================================
--- trunk/qcell/visgui/MainWindow.cpp 2007-01-10 20:14:34 UTC (rev 142)
+++ trunk/qcell/visgui/MainWindow.cpp 2007-01-10 20:59:44 UTC (rev 143)
@@ -352,7 +352,8 @@
data.append((CalculationData*)world_parsers[subtype]->parse(file_content, type, subtype).toInt());
*sw->getStorage() = *data.last();
- calc.setForeignDataPointer((char*)data.first()->getDataPointer());
+// calc.setForeignDataPointer((char*)data.first()->getDataPointer());
+ *(CalculationData*)&calc = *data.last();
QVector<int> end_coord;
end_coord << data.last()->getSizeX()
<< data.last()->getSizeY()
@@ -475,10 +476,12 @@
void MainWindow::oneStep(int direction)
{
+ QTime t;
switch (direction)
{
case Forward:
{
+ t.start();
if((iteration + 1) >= data.count())
{
/// @todo Use the updated API of Calculator
@@ -506,7 +509,24 @@
}
}
- /// @todo This will probabelly need change after the Calculator API change
+
+ // Timeout handling
+ // If the calculations took longer then the delay
+ if (t.elapsed()*1.0 >= msec_delay)
+ {
+ update();
+ /// @todo Make user know
+ }
+ // If not, we need to wait the rest of the time
+ else
+ {
+ QTimer::singleShot(msec_delay - (double)t.elapsed(),
+ this, SLOT(update()));
+ }
+}
+
+void MainWindow::update()
+{
*sw->getStorage() = *data[iteration];
iterationLCD->display(iteration);
}
Modified: trunk/qcell/visgui/MainWindow.h
===================================================================
--- trunk/qcell/visgui/MainWindow.h 2007-01-10 20:14:34 UTC (rev 142)
+++ trunk/qcell/visgui/MainWindow.h 2007-01-10 20:59:44 UTC (rev 143)
@@ -54,6 +54,7 @@
void sliderChanged(int value);
void spinBoxChanged(double value);
+ void update();
/// @todo not here!
void on_action_Forward_activated();
void on_action_Back_activated();
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <dhu...@us...> - 2007-01-10 21:09:31
|
Revision: 144
http://svn.sourceforge.net/qcell/?rev=144&view=rev
Author: dhubleizh
Date: 2007-01-10 13:09:28 -0800 (Wed, 10 Jan 2007)
Log Message:
-----------
- typo in english string
- translations mainly for new status bar features and delays
Modified Paths:
--------------
trunk/qcell/visgui/MainWindow.cpp
trunk/qcell/visgui/visgui_pl.qm
trunk/qcell/visgui/visgui_pl.ts
Modified: trunk/qcell/visgui/MainWindow.cpp
===================================================================
--- trunk/qcell/visgui/MainWindow.cpp 2007-01-10 20:59:44 UTC (rev 143)
+++ trunk/qcell/visgui/MainWindow.cpp 2007-01-10 21:09:28 UTC (rev 144)
@@ -20,7 +20,7 @@
// Adding delay setup
// An interlinked pair of QDoubleSpinBox and a QSlider
delaySlider = new QSlider(Qt::Horizontal);
- delaySlider->setStatusTip(tr("Sets the dleay between iteration steps in ms."));
+ delaySlider->setStatusTip(tr("Sets the delay between iteration steps in ms."));
delaySlider->setFixedWidth(100);
delaySpinBox = new QDoubleSpinBox();
delaySpinBox->setStatusTip(delaySlider->statusTip());
@@ -468,6 +468,7 @@
{
working = false;
iteration = 0;
+ msec_delay = 0.0;
// Set all data pointers to NULL, as unlockExperiment depends on it!
neighbourhood = NULL;
Modified: trunk/qcell/visgui/visgui_pl.qm
===================================================================
(Binary files differ)
Modified: trunk/qcell/visgui/visgui_pl.ts
===================================================================
--- trunk/qcell/visgui/visgui_pl.ts 2007-01-10 20:59:44 UTC (rev 143)
+++ trunk/qcell/visgui/visgui_pl.ts 2007-01-10 21:09:28 UTC (rev 144)
@@ -44,15 +44,30 @@
<translation>Przygotowanie eksperymentu</translation>
</message>
<message>
- <location filename="ExperimentSetup.ui" line="33"/>
+ <location filename="ExperimentSetup.ui" line="37"/>
<source>Number of iterations</source>
<translation>Liczba iteracji</translation>
</message>
<message>
- <location filename="ExperimentSetup.ui" line="59"/>
+ <location filename="ExperimentSetup.ui" line="63"/>
<source>Continuos Experiment</source>
<translation>Eksperyment Ciągły</translation>
</message>
+ <message>
+ <location filename="ExperimentSetup.ui" line="25"/>
+ <source>Iterations</source>
+ <translation>Iteracje</translation>
+ </message>
+ <message>
+ <location filename="ExperimentSetup.ui" line="73"/>
+ <source>Delay between iterations</source>
+ <translation>Opóźnienie między interacjami</translation>
+ </message>
+ <message>
+ <location filename="ExperimentSetup.ui" line="108"/>
+ <source>s</source>
+ <translation>s</translation>
+ </message>
</context>
<context>
<name>GenericParserPlugin</name>
@@ -62,7 +77,7 @@
<translation>Typ wtyczki %1 nie jest wspierany przez te wtyczkę.</translation>
</message>
<message>
- <location filename="../basesources/GenericParserPlugin.cpp" line="67"/>
+ <location filename="../basesources/GenericParserPlugin.cpp" line="46"/>
<source>This plugin doesn't support parsing of type %1. It supports %2.</source>
<translation>Ta wtyczka nie obsługuję parsowania typu %1. Wspiera typ %2.</translation>
</message>
@@ -72,7 +87,7 @@
<translation type="obsolete">Tutaj jestem!</translation>
</message>
<message>
- <location filename="../basesources/GenericParserPlugin.cpp" line="115"/>
+ <location filename="../basesources/GenericParserPlugin.cpp" line="93"/>
<source>This plugin doesn't support saving type %1. It supports %2.</source>
<translation>Ta wtyczka nie obsługuje zapisywania typu %1. Obsługuje typ %2.</translation>
</message>
@@ -85,22 +100,22 @@
<translation>QCell</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="86"/>
+ <location filename="MainWindow.ui" line="53"/>
<source>&Help</source>
<translation>P&omoc</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="53"/>
+ <location filename="MainWindow.ui" line="60"/>
<source>&File</source>
<translation>&Plik</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="57"/>
+ <location filename="MainWindow.ui" line="64"/>
<source>Opens experiment data.</source>
<translation>Otwiera dane eksperymentu.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="60"/>
+ <location filename="MainWindow.ui" line="67"/>
<source>&Open</source>
<translation>&Otwórz</translation>
</message>
@@ -110,83 +125,83 @@
<translation type="obsolete">To menu pozwala przeszukiwać tematy pomocy i poczytać o aplikacji.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="112"/>
+ <location filename="MainWindow.ui" line="113"/>
<source>&Quit</source>
<translation>&Wyjście</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="115"/>
+ <location filename="MainWindow.ui" line="116"/>
<source>This menu item quits the application.</source>
<comment>Quits the application</comment>
<translation>Ten przycisk menu powoduje wyjście z aplikacji.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="118"/>
+ <location filename="MainWindow.ui" line="119"/>
<source>Quits the application.</source>
<translation>Wychodzi z aplikacji.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="255"/>
+ <location filename="MainWindow.ui" line="262"/>
<source>&Neighbourhood</source>
<translation>&Sąsiedztwo</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="126"/>
+ <location filename="MainWindow.ui" line="127"/>
<source>Opens neighbourhood.</source>
<translation>Otwiera plik sąsiedztwa.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="263"/>
+ <location filename="MainWindow.ui" line="270"/>
<source>&Function</source>
<translation>&Funkcja</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="134"/>
+ <location filename="MainWindow.ui" line="135"/>
<source>Opens function.</source>
<translation>Otwiera plik funkcji.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="247"/>
+ <location filename="MainWindow.ui" line="254"/>
<source>&World</source>
<translation>Ś&wiat</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="142"/>
+ <location filename="MainWindow.ui" line="143"/>
<source>Opens world configuration.</source>
<translation>Otwiera konfigurację świata.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="150"/>
+ <location filename="MainWindow.ui" line="151"/>
<source>Open &experiment</source>
<translation>Otwórz &eksperyment</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="153"/>
+ <location filename="MainWindow.ui" line="154"/>
<source>Opens a predefined experiment.</source>
<translation>Otwiera zdefiniowany wcześniej eksperyment.</translation>
</message>
<message>
<location filename="MainWindow.ui" line="158"/>
<source>&Continiue experiment</source>
- <translation>&Kontynuuj eksperyment</translation>
+ <translation type="obsolete">&Kontynuuj eksperyment</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="161"/>
+ <location filename="MainWindow.ui" line="168"/>
<source>Loads an earlier saved experiment.</source>
<translation>Ładuje wcześniej zachowany eksperyment.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="166"/>
+ <location filename="MainWindow.ui" line="173"/>
<source>&About</source>
<translation>&O programie</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="169"/>
+ <location filename="MainWindow.ui" line="176"/>
<source>Shows info about the program.</source>
<translation>Pokazuje informacje o programie.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="115"/>
+ <location filename="MainWindow.cpp" line="139"/>
<source>Open Neighbourhood</source>
<translation>Otwórz Sąsiedztwo</translation>
</message>
@@ -196,52 +211,52 @@
<translation type="obsolete"> pliki</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="643"/>
+ <location filename="MainWindow.cpp" line="693"/>
<source>files</source>
<translation>pliki</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="619"/>
+ <location filename="MainWindow.cpp" line="669"/>
<source>Plugins warning</source>
<translation>Ostrzeżenie wtyczek</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="107"/>
+ <location filename="MainWindow.cpp" line="131"/>
<source>There are no plugins loaded to handle Neighbourhood parsing.</source>
<translation>Nie ma załadowanej żadnej wtyczki do obsługi parsowania plików Sąsiedztwa.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="150"/>
+ <location filename="MainWindow.cpp" line="174"/>
<source>There are no plugins loaded to handle Function parsing.</source>
<translation>Nie ma załadowanej żadnej wtyczki do obsługi parsowania Funkcji.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="158"/>
+ <location filename="MainWindow.cpp" line="182"/>
<source>Open Function</source>
<translation>Otwórz Funkcję</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="194"/>
+ <location filename="MainWindow.cpp" line="218"/>
<source>There are no plugins loaded to handle World parsing.</source>
<translation>Nie ma załadowanej żadnej wtyczki do parsowania Świata.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="202"/>
+ <location filename="MainWindow.cpp" line="226"/>
<source>Open World</source>
<translation>Otwórz Świat</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="241"/>
+ <location filename="MainWindow.cpp" line="797"/>
<source>Error opening file %1.</source>
<translation>Błąd podczas otwierania pliku %1.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="400"/>
+ <location filename="MainWindow.cpp" line="425"/>
<source>The file extensions %1 isn't supported.</source>
<translation>Rozszerzenie pliku %1 nie jest wspierane.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="411"/>
+ <location filename="MainWindow.cpp" line="436"/>
<source>Unsupported file type to parse.</source>
<translation>Niewspierany typ pliku do przeczytania.</translation>
</message>
@@ -256,37 +271,37 @@
<translation>&Eksperyment</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="177"/>
+ <location filename="MainWindow.ui" line="184"/>
<source>&Start</source>
<translation>&Start</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="183"/>
+ <location filename="MainWindow.ui" line="190"/>
<source>Starts the experiment.</source>
<translation>Startuje eksperyment.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="191"/>
+ <location filename="MainWindow.ui" line="198"/>
<source>S&top</source>
<translation>S&top</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="197"/>
+ <location filename="MainWindow.ui" line="204"/>
<source>Stops the experiment.</source>
<translation>Zatrzymuje eksperyment.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="205"/>
+ <location filename="MainWindow.ui" line="212"/>
<source>&Restart</source>
<translation>Ponowne u&ruchominie</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="211"/>
+ <location filename="MainWindow.ui" line="218"/>
<source>Restarts the experiment.</source>
<translation>Uruchamia eksperyment od nowa.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="219"/>
+ <location filename="MainWindow.ui" line="226"/>
<source>&Forward</source>
<translation>Do &przodu</translation>
</message>
@@ -296,75 +311,145 @@
<translation type="obsolete">Iteruje jeden krok.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="225"/>
+ <location filename="MainWindow.ui" line="232"/>
<source>Iterates one setp forward.</source>
<translation>Iteruje jeden krok do przodu.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="233"/>
+ <location filename="MainWindow.ui" line="240"/>
<source>&Back</source>
<translation>Do &tyłu</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="239"/>
+ <location filename="MainWindow.ui" line="246"/>
<source>Iterates one setp back.</source>
<translation>Iteruje jeden krok wstecz.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="24"/>
+ <location filename="MainWindow.cpp" line="48"/>
<source>Iteration</source>
<translation>Iteracja</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="471"/>
+ <location filename="MainWindow.cpp" line="505"/>
<source>You cannot step back beyond the beginning of the experiment!</source>
<translation>Nie możesz cofnąc się poza początek eksperymentu!</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="361"/>
+ <location filename="MainWindow.cpp" line="386"/>
<source>Error opnening file %1.</source>
<translation>Błąd podczas próby otwarcia pliku %1.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="573"/>
+ <location filename="MainWindow.cpp" line="623"/>
<source>There are no plugins loaded to handle World saving.</source>
<translation>Nie ma załadowanej żadnej wtyczki do obsługi zapisywania plików świata.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="581"/>
+ <location filename="MainWindow.cpp" line="631"/>
<source>Save World</source>
<translation>Zapisz Świat</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="621"/>
+ <location filename="MainWindow.cpp" line="671"/>
<source>There are no plugins loaded to handle Neighbourhood saving.</source>
<translation>Nie ma załadowanych żadnych wtyczek do obsługi zapisywania Sąsiedztwa.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="629"/>
+ <location filename="MainWindow.cpp" line="679"/>
<source>Save Neighbourhood</source>
<translation>Zapisz Sąsiedztwo</translation>
</message>
<message>
<location filename="MainWindow.ui" line="71"/>
<source>&Save experiment</source>
- <translation>&Zapisz eksperyment</translation>
+ <translation type="obsolete">&Zapisz eksperyment</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="291"/>
+ <location filename="MainWindow.cpp" line="315"/>
<source>Internal error: unable to parse %1 file</source>
<translation>Wewnętrzny błąd: nie mogę zrozumiec pliku %1</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="431"/>
+ <location filename="MainWindow.cpp" line="462"/>
<source>%1 file loaded sucesfully!</source>
<translation>Plik %1 załadowany poprawnie!</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="23"/>
+ <location filename="MainWindow.cpp" line="47"/>
<source>Shows the current iteration number.</source>
- <translation type="unfinished">Pokazuje aktualny numer iteracji.</translation>
+ <translation>Pokazuje aktualny numer iteracji.</translation>
</message>
+ <message>
+ <location filename="MainWindow.cpp" line="30"/>
+ <source>Delay</source>
+ <translation>Opóźnienie</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.cpp" line="720"/>
+ <source>Save Experiment</source>
+ <translation>Zachowaj Eksperyment</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.cpp" line="780"/>
+ <source>Experiment files (*.%1)</source>
+ <translation>Pliki Eksperymentów (*.%1)</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.cpp" line="757"/>
+ <source>Internal error: unable to serialize experiment</source>
+ <translation>Wewnętrzny błąd: serializacja eksperymentu niemożliwa</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.cpp" line="771"/>
+ <source>Open Experiment</source>
+ <translation>Otwórz Eksperyment</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.cpp" line="849"/>
+ <source>Error deserializing Neighbourhood</source>
+ <translation>Błąd podczas deserializacji Sąsiedztwa</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.cpp" line="864"/>
+ <source>Error deserializing Local Function</source>
+ <translation>Error podczas deserializacji Funkcji Lokalnej</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.cpp" line="870"/>
+ <source>Sucessfully loaded experiment for continuation.</source>
+ <translation>Załadowano eksperyment do kontynuowania.</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="78"/>
+ <source>&Save</source>
+ <translation>&Zachowaj</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="159"/>
+ <source>&Continue experiment</source>
+ <translation>&Wznów eksperyment</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="165"/>
+ <source>Continue experiment</source>
+ <translation>Wznów eksperyment</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="278"/>
+ <source>Sa&ve experiment</source>
+ <translation>Zac&howaj eksperyment</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="281"/>
+ <source>Saves the whole experiment with history for later continuation.</source>
+ <translation>Zachowuje cały eksperyment z historią dla þóźniejszego wznowienia.</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.cpp" line="23"/>
+ <source>Sets the delay between iteration steps in ms.</source>
+ <translation>Ustawia opóźnienie między krokami iteracji w ms.</translation>
+ </message>
</context>
<context>
<name>QApplication</name>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <dhu...@us...> - 2007-01-17 15:48:44
|
Revision: 183
http://svn.sourceforge.net/qcell/?rev=183&view=rev
Author: dhubleizh
Date: 2007-01-17 07:48:30 -0800 (Wed, 17 Jan 2007)
Log Message:
-----------
- updated translation for the new GUI
Modified Paths:
--------------
trunk/qcell/visgui/visgui_pl.qm
trunk/qcell/visgui/visgui_pl.ts
Modified: trunk/qcell/visgui/visgui_pl.qm
===================================================================
(Binary files differ)
Modified: trunk/qcell/visgui/visgui_pl.ts
===================================================================
--- trunk/qcell/visgui/visgui_pl.ts 2007-01-17 15:43:02 UTC (rev 182)
+++ trunk/qcell/visgui/visgui_pl.ts 2007-01-17 15:48:30 UTC (rev 183)
@@ -37,6 +37,69 @@
</message>
</context>
<context>
+ <name>BaseToolsClass</name>
+ <message>
+ <location filename="../baseheaders/basetools.ui" line="13"/>
+ <source>BaseTools</source>
+ <translation>Podstawowe Narzędzia</translation>
+ </message>
+ <message>
+ <location filename="../baseheaders/basetools.ui" line="25"/>
+ <source>Edit Tools</source>
+ <translation>Narzędzia Edycji</translation>
+ </message>
+ <message>
+ <location filename="../baseheaders/basetools.ui" line="37"/>
+ <source>Fill</source>
+ <translation>Uzupełnij</translation>
+ </message>
+ <message>
+ <location filename="../baseheaders/basetools.ui" line="50"/>
+ <source>Paste</source>
+ <translation>Wklej</translation>
+ </message>
+ <message>
+ <location filename="../baseheaders/basetools.ui" line="63"/>
+ <source>Copy</source>
+ <translation>Kopiuj</translation>
+ </message>
+ <message>
+ <location filename="../baseheaders/basetools.ui" line="77"/>
+ <source>Values</source>
+ <translation>Wartości</translation>
+ </message>
+ <message>
+ <location filename="../baseheaders/basetools.ui" line="100"/>
+ <source>View Mode</source>
+ <translation>Typ Wyświetlania</translation>
+ </message>
+ <message>
+ <location filename="../baseheaders/basetools.ui" line="112"/>
+ <source>Local</source>
+ <translation>Lokalny</translation>
+ </message>
+ <message>
+ <location filename="../baseheaders/basetools.ui" line="128"/>
+ <source>Global</source>
+ <translation>Globalny</translation>
+ </message>
+ <message>
+ <location filename="../baseheaders/basetools.ui" line="148"/>
+ <source>Edit Mode</source>
+ <translation>Tryb Edycji</translation>
+ </message>
+ <message>
+ <location filename="../baseheaders/basetools.ui" line="160"/>
+ <source>Edit</source>
+ <translation>Edycja</translation>
+ </message>
+ <message>
+ <location filename="../baseheaders/basetools.ui" line="176"/>
+ <source>Select</source>
+ <translation>Zaznacz</translation>
+ </message>
+</context>
+<context>
<name>ExperimentSetupDialog</name>
<message>
<location filename="ExperimentSetup.ui" line="13"/>
@@ -211,12 +274,12 @@
<translation type="obsolete"> pliki</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="704"/>
+ <location filename="MainWindow.cpp" line="706"/>
<source>files</source>
<translation>pliki</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="680"/>
+ <location filename="MainWindow.cpp" line="682"/>
<source>Plugins warning</source>
<translation>Ostrzeżenie wtyczek</translation>
</message>
@@ -246,17 +309,17 @@
<translation>Otwórz Świat</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="808"/>
+ <location filename="MainWindow.cpp" line="810"/>
<source>Error opening file %1.</source>
<translation>Błąd podczas otwierania pliku %1.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="425"/>
+ <location filename="MainWindow.cpp" line="423"/>
<source>The file extensions %1 isn't supported.</source>
<translation>Rozszerzenie pliku %1 nie jest wspierane.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="436"/>
+ <location filename="MainWindow.cpp" line="434"/>
<source>Unsupported file type to parse.</source>
<translation>Niewspierany typ pliku do przeczytania.</translation>
</message>
@@ -331,32 +394,32 @@
<translation>Iteracja</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="511"/>
+ <location filename="MainWindow.cpp" line="509"/>
<source>You cannot step back beyond the beginning of the experiment!</source>
<translation>Nie możesz cofnąc się poza początek eksperymentu!</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="386"/>
+ <location filename="MainWindow.cpp" line="384"/>
<source>Error opnening file %1.</source>
<translation>Błąd podczas próby otwarcia pliku %1.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="634"/>
+ <location filename="MainWindow.cpp" line="636"/>
<source>There are no plugins loaded to handle World saving.</source>
<translation>Nie ma załadowanej żadnej wtyczki do obsługi zapisywania plików świata.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="642"/>
+ <location filename="MainWindow.cpp" line="644"/>
<source>Save World</source>
<translation>Zapisz Świat</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="682"/>
+ <location filename="MainWindow.cpp" line="684"/>
<source>There are no plugins loaded to handle Neighbourhood saving.</source>
<translation>Nie ma załadowanych żadnych wtyczek do obsługi zapisywania Sąsiedztwa.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="690"/>
+ <location filename="MainWindow.cpp" line="692"/>
<source>Save Neighbourhood</source>
<translation>Zapisz Sąsiedztwo</translation>
</message>
@@ -371,7 +434,7 @@
<translation>Wewnętrzny błąd: nie mogę zrozumiec pliku %1</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="462"/>
+ <location filename="MainWindow.cpp" line="460"/>
<source>%1 file loaded sucesfully!</source>
<translation>Plik %1 załadowany poprawnie!</translation>
</message>
@@ -386,37 +449,37 @@
<translation>Opóźnienie</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="731"/>
+ <location filename="MainWindow.cpp" line="733"/>
<source>Save Experiment</source>
<translation>Zachowaj Eksperyment</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="791"/>
+ <location filename="MainWindow.cpp" line="793"/>
<source>Experiment files (*.%1)</source>
<translation>Pliki Eksperymentów (*.%1)</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="768"/>
+ <location filename="MainWindow.cpp" line="770"/>
<source>Internal error: unable to serialize experiment</source>
<translation>Wewnętrzny błąd: serializacja eksperymentu niemożliwa</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="782"/>
+ <location filename="MainWindow.cpp" line="784"/>
<source>Open Experiment</source>
<translation>Otwórz Eksperyment</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="860"/>
+ <location filename="MainWindow.cpp" line="862"/>
<source>Error deserializing Neighbourhood</source>
<translation>Błąd podczas deserializacji Sąsiedztwa</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="875"/>
+ <location filename="MainWindow.cpp" line="877"/>
<source>Error deserializing Local Function</source>
<translation>Error podczas deserializacji Funkcji Lokalnej</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="881"/>
+ <location filename="MainWindow.cpp" line="883"/>
<source>Sucessfully loaded experiment for continuation.</source>
<translation>Załadowano eksperyment do kontynuowania.</translation>
</message>
@@ -454,55 +517,174 @@
<context>
<name>QApplication</name>
<message>
- <location filename="main.cpp" line="59"/>
+ <location filename="main.cpp" line="61"/>
<source>Debug</source>
<translation>Odpluskwianie</translation>
</message>
<message>
- <location filename="main.cpp" line="62"/>
+ <location filename="main.cpp" line="64"/>
<source>Warning</source>
<translation>Ostrzeżenie</translation>
</message>
<message>
- <location filename="main.cpp" line="65"/>
+ <location filename="main.cpp" line="67"/>
<source>Critical</source>
<translation>Krytyczny</translation>
</message>
<message>
- <location filename="main.cpp" line="68"/>
+ <location filename="main.cpp" line="70"/>
<source>Fatal</source>
<translation>Śmiertelny</translation>
</message>
</context>
<context>
+ <name>View1DTextToolsClass</name>
+ <message>
+ <location filename="../baseheaders/view1dtexttools.ui" line="13"/>
+ <source>View1DTextTools</source>
+ <translation>Narzędzia Widoku Tekstowego 1D</translation>
+ </message>
+ <message>
+ <location filename="../baseheaders/view1dtexttools.ui" line="25"/>
+ <source>Memory</source>
+ <translation>Pamięć</translation>
+ </message>
+ <message>
+ <location filename="../baseheaders/view1dtexttools.ui" line="37"/>
+ <source>Clear</source>
+ <translation>Wyczyść</translation>
+ </message>
+ <message>
+ <location filename="../baseheaders/view1dtexttools.ui" line="51"/>
+ <source>View 1D Text</source>
+ <translation>Widok Tekstowy 1D</translation>
+ </message>
+ <message>
+ <location filename="../baseheaders/view1dtexttools.ui" line="63"/>
+ <source>Colors</source>
+ <translation>Kolory</translation>
+ </message>
+ <message>
+ <location filename="../baseheaders/view1dtexttools.ui" line="79"/>
+ <source>Values</source>
+ <translation>Wartości</translation>
+ </message>
+ <message>
+ <location filename="../baseheaders/view1dtexttools.ui" line="98"/>
+ <source>Symbols</source>
+ <translation>Symbole</translation>
+ </message>
+</context>
+<context>
+ <name>View2DTextToolsClass</name>
+ <message>
+ <location filename="../baseheaders/view2dtexttools.ui" line="13"/>
+ <source>View2DTextTools</source>
+ <translation>Narzędzia Widoku Tekstowego 2D</translation>
+ </message>
+ <message>
+ <location filename="../baseheaders/view2dtexttools.ui" line="25"/>
+ <source>Z Plane</source>
+ <translation>Płaszczyzna Z</translation>
+ </message>
+ <message>
+ <location filename="../baseheaders/view2dtexttools.ui" line="48"/>
+ <source>View 2D Text</source>
+ <translation>Widok Tekstowy 2D</translation>
+ </message>
+ <message>
+ <location filename="../baseheaders/view2dtexttools.ui" line="60"/>
+ <source>Values</source>
+ <translation>Wartości</translation>
+ </message>
+ <message>
+ <location filename="../baseheaders/view2dtexttools.ui" line="79"/>
+ <source>Colors</source>
+ <translation>Kolory</translation>
+ </message>
+ <message>
+ <location filename="../baseheaders/view2dtexttools.ui" line="95"/>
+ <source>Symbols</source>
+ <translation>Symbole</translation>
+ </message>
+</context>
+<context>
+ <name>View3DToolsClass</name>
+ <message>
+ <location filename="../baseheaders/view3dtools.ui" line="13"/>
+ <source>View3DTools</source>
+ <translation>Narzędzia Wiodku Tekstowego 3D</translation>
+ </message>
+ <message>
+ <location filename="../baseheaders/view3dtools.ui" line="25"/>
+ <source>View 3D</source>
+ <translation>Widok 3D</translation>
+ </message>
+ <message>
+ <location filename="../baseheaders/view3dtools.ui" line="37"/>
+ <source>Perspective</source>
+ <translation>Perspektywa</translation>
+ </message>
+ <message>
+ <location filename="../baseheaders/view3dtools.ui" line="56"/>
+ <source>Ortho</source>
+ <translation>Ortho</translation>
+ </message>
+ <message>
+ <location filename="../baseheaders/view3dtools.ui" line="73"/>
+ <source>Section</source>
+ <translation>Zaznaczenie</translation>
+ </message>
+ <message>
+ <location filename="../baseheaders/view3dtools.ui" line="95"/>
+ <source>Enable</source>
+ <translation>Włącz</translation>
+ </message>
+ <message>
+ <location filename="../baseheaders/view3dtools.ui" line="111"/>
+ <source>xy</source>
+ <translation>xy</translation>
+ </message>
+ <message>
+ <location filename="../baseheaders/view3dtools.ui" line="130"/>
+ <source>zy</source>
+ <translation>zy</translation>
+ </message>
+ <message>
+ <location filename="../baseheaders/view3dtools.ui" line="146"/>
+ <source>xz</source>
+ <translation>xz</translation>
+ </message>
+</context>
+<context>
<name>simulationWindow</name>
<message>
- <location filename="../basesources/simulationwindow.cpp" line="422"/>
+ <location filename="../basesources/simulationwindow.cpp" line="554"/>
<source>%1</source>
<translation>%1</translation>
</message>
<message>
- <location filename="../basesources/simulationwindow.cpp" line="466"/>
+ <location filename="../basesources/simulationwindow.cpp" line="625"/>
<source>Value</source>
<translation>Wartość</translation>
</message>
<message>
- <location filename="../basesources/simulationwindow.cpp" line="467"/>
+ <location filename="../basesources/simulationwindow.cpp" line="600"/>
<source>Symbol</source>
<translation>Symbol</translation>
</message>
<message>
- <location filename="../basesources/simulationwindow.cpp" line="468"/>
+ <location filename="../basesources/simulationwindow.cpp" line="601"/>
<source>Color</source>
<translation>Kolor</translation>
</message>
<message>
- <location filename="../basesources/simulationwindow.cpp" line="469"/>
+ <location filename="../basesources/simulationwindow.cpp" line="602"/>
<source>Model</source>
<translation>Model</translation>
</message>
<message>
- <location filename="../basesources/simulationwindow.cpp" line="470"/>
+ <location filename="../basesources/simulationwindow.cpp" line="603"/>
<source>Hide Flag</source>
<translation>Flaga Ukrycia</translation>
</message>
@@ -522,65 +704,65 @@
<message>
<location filename="../baseheaders/simulationwindow.ui" line="63"/>
<source>Perspective</source>
- <translation>Perspektywa</translation>
+ <translation type="obsolete">Perspektywa</translation>
</message>
<message>
<location filename="../baseheaders/simulationwindow.ui" line="73"/>
<source>Ortho2D</source>
- <translation>Orto2D</translation>
+ <translation type="obsolete">Orto2D</translation>
</message>
<message>
- <location filename="../baseheaders/simulationwindow.ui" line="96"/>
+ <location filename="../baseheaders/simulationwindow.ui" line="48"/>
<source>2D Text View</source>
<translation>Widok Tekstowy 2D</translation>
</message>
<message>
<location filename="../baseheaders/simulationwindow.ui" line="143"/>
<source>Z Plane</source>
- <translation>Płaszczyzna Z</translation>
+ <translation type="obsolete">Płaszczyzna Z</translation>
</message>
<message>
<location filename="../baseheaders/simulationwindow.ui" line="207"/>
<source>Values</source>
- <translation>Wartości</translation>
+ <translation type="obsolete">Wartości</translation>
</message>
<message>
<location filename="../baseheaders/simulationwindow.ui" line="217"/>
<source>Symbols</source>
- <translation>Symbole</translation>
+ <translation type="obsolete">Symbole</translation>
</message>
<message>
<location filename="../baseheaders/simulationwindow.ui" line="200"/>
<source>Enable Colors</source>
- <translation>Uruchom Kolory</translation>
+ <translation type="obsolete">Uruchom Kolory</translation>
</message>
<message>
- <location filename="../baseheaders/simulationwindow.ui" line="175"/>
+ <location filename="../baseheaders/simulationwindow.ui" line="53"/>
<source>2D Graphics View</source>
<translation>Graficzny Widok 2D</translation>
</message>
<message>
- <location filename="../baseheaders/simulationwindow.ui" line="180"/>
+ <location filename="../baseheaders/simulationwindow.ui" line="58"/>
<source>1D Text View</source>
<translation>Widok Tekstowy 1D</translation>
</message>
<message>
<location filename="../baseheaders/simulationwindow.ui" line="224"/>
<source>Clear Memory</source>
- <translation>Wyczyśc Pamięć</translation>
+ <translation type="obsolete">Wyczyśc Pamięć</translation>
</message>
<message>
- <location filename="../baseheaders/simulationwindow.ui" line="247"/>
+ <location filename="../baseheaders/simulationwindow.ui" line="63"/>
<source>Symbols Configuration</source>
<translation>Konfiguracja Symboli</translation>
</message>
<message>
- <location filename="../baseheaders/simulationwindow.ui" line="274"/>
+ <location filename="../baseheaders/simulationwindow.ui" line="90"/>
<source>Remove Symbol</source>
<translation>Usuń Symbol</translation>
</message>
<message>
- <location filename="../baseheaders/simulationwindow.ui" line="267"/>
+ <location filename="../baseheaders/simulationwindow.ui" line="83"/>
<source>Add Symbol</source>
<translation>Dodaj Symbol</translation>
</message>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <dhu...@us...> - 2007-01-20 12:33:25
|
Revision: 202
http://svn.sourceforge.net/qcell/?rev=202&view=rev
Author: dhubleizh
Date: 2007-01-20 04:33:20 -0800 (Sat, 20 Jan 2007)
Log Message:
-----------
- minor changes and bugfixes
Modified Paths:
--------------
trunk/qcell/visgui/main.cpp
trunk/qcell/visgui/visgui.pro
Modified: trunk/qcell/visgui/main.cpp
===================================================================
--- trunk/qcell/visgui/main.cpp 2007-01-20 12:32:39 UTC (rev 201)
+++ trunk/qcell/visgui/main.cpp 2007-01-20 12:33:20 UTC (rev 202)
@@ -12,6 +12,7 @@
Q_IMPORT_PLUGIN(NFileParser);
Q_IMPORT_PLUGIN(FQTFileParser);
Q_IMPORT_PLUGIN(KIFileParser);
+Q_IMPORT_PLUGIN(REAKFileParser);
/**
* @brief Displays all debug messages in GUI
Modified: trunk/qcell/visgui/visgui.pro
===================================================================
--- trunk/qcell/visgui/visgui.pro 2007-01-20 12:32:39 UTC (rev 201)
+++ trunk/qcell/visgui/visgui.pro 2007-01-20 12:33:20 UTC (rev 202)
@@ -48,7 +48,7 @@
../basesources/view2dtexttools.cpp \
../basesources/view1dtexttools.cpp
-LIBS = -L../libs -lN -lFQT -lKI
+LIBS = -L../libs -lN -lFQT -lKI -lREAK
TRANSLATIONS = visgui_pl.ts
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <dhu...@us...> - 2007-01-20 12:44:11
|
Revision: 204
http://svn.sourceforge.net/qcell/?rev=204&view=rev
Author: dhubleizh
Date: 2007-01-20 04:44:08 -0800 (Sat, 20 Jan 2007)
Log Message:
-----------
- added static plugins
Modified Paths:
--------------
trunk/qcell/visgui/main.cpp
trunk/qcell/visgui/visgui.pro
Modified: trunk/qcell/visgui/main.cpp
===================================================================
--- trunk/qcell/visgui/main.cpp 2007-01-20 12:33:55 UTC (rev 203)
+++ trunk/qcell/visgui/main.cpp 2007-01-20 12:44:08 UTC (rev 204)
@@ -13,6 +13,9 @@
Q_IMPORT_PLUGIN(FQTFileParser);
Q_IMPORT_PLUGIN(KIFileParser);
Q_IMPORT_PLUGIN(REAKFileParser);
+Q_IMPORT_PLUGIN(LTFLFileParser);
+Q_IMPORT_PLUGIN(ZIFWFileParser);
+Q_IMPORT_PLUGIN(ZIFWPFileParser);
/**
* @brief Displays all debug messages in GUI
Modified: trunk/qcell/visgui/visgui.pro
===================================================================
--- trunk/qcell/visgui/visgui.pro 2007-01-20 12:33:55 UTC (rev 203)
+++ trunk/qcell/visgui/visgui.pro 2007-01-20 12:44:08 UTC (rev 204)
@@ -48,7 +48,7 @@
../basesources/view2dtexttools.cpp \
../basesources/view1dtexttools.cpp
-LIBS = -L../libs -lN -lFQT -lKI -lREAK
+LIBS = -L../libs -lN -lFQT -lKI -lREAK -lLTFL -lZIFW -lZIFWP
TRANSLATIONS = visgui_pl.ts
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <dhu...@us...> - 2007-01-23 20:15:37
|
Revision: 238
http://svn.sourceforge.net/qcell/?rev=238&view=rev
Author: dhubleizh
Date: 2007-01-23 12:15:29 -0800 (Tue, 23 Jan 2007)
Log Message:
-----------
- new world wizard added
- new neighbourhood wizard added
Modified Paths:
--------------
trunk/qcell/visgui/MainWindow.cpp
trunk/qcell/visgui/MainWindow.h
trunk/qcell/visgui/MainWindow.ui
trunk/qcell/visgui/visgui.pro
Added Paths:
-----------
trunk/qcell/visgui/NewNeighbourhoodDialog.ui
trunk/qcell/visgui/NewNeighbourhoodWizard.cpp
trunk/qcell/visgui/NewNeighbourhoodWizard.h
trunk/qcell/visgui/NewWorldDialog.ui
trunk/qcell/visgui/NewWorldWizard.cpp
trunk/qcell/visgui/NewWorldWizard.h
Modified: trunk/qcell/visgui/MainWindow.cpp
===================================================================
--- trunk/qcell/visgui/MainWindow.cpp 2007-01-23 18:36:35 UTC (rev 237)
+++ trunk/qcell/visgui/MainWindow.cpp 2007-01-23 20:15:29 UTC (rev 238)
@@ -1001,3 +1001,21 @@
delaySlider->blockSignals(false);
}
+void MainWindow::on_action_New_World_activated()
+{
+ NewWorldWizard nww;
+ if (nww.exec())
+ {
+ /// @todo emit some signal here
+ }
+}
+
+void MainWindow::on_action_New_Neighbourhood_activated()
+{
+ NewNeighbourhoodWizard nnw;
+ if (nnw.exec())
+ {
+ /// @todo emit some signal here
+ }
+}
+
Modified: trunk/qcell/visgui/MainWindow.h
===================================================================
--- trunk/qcell/visgui/MainWindow.h 2007-01-23 18:36:35 UTC (rev 237)
+++ trunk/qcell/visgui/MainWindow.h 2007-01-23 20:15:29 UTC (rev 238)
@@ -14,6 +14,8 @@
#include "ExperimentSetup.h"
#include "ElementalRulesWidget.h"
#include "ElementalRules.h"
+#include "NewWorldWizard.h"
+#include "NewNeighbourhoodWizard.h"
#include <QPluginLoader>
#include "GenericParserPlugin.h"
#include <QFileDialog>
@@ -53,6 +55,9 @@
void on_action_Save_experiment_activated();
void on_action_Continue_experiment_activated();
+ void on_action_New_World_activated();
+ void on_action_New_Neighbourhood_activated();
+
void sliderChanged(int value);
void spinBoxChanged(double value);
Modified: trunk/qcell/visgui/MainWindow.ui
===================================================================
--- trunk/qcell/visgui/MainWindow.ui 2007-01-23 18:36:35 UTC (rev 237)
+++ trunk/qcell/visgui/MainWindow.ui 2007-01-23 20:15:29 UTC (rev 238)
@@ -55,10 +55,26 @@
<addaction name="separator" />
<addaction name="action_About" />
</widget>
+ <widget class="QMenu" name="menu_View" >
+ <property name="title" >
+ <string>&View</string>
+ </property>
+ </widget>
<widget class="QMenu" name="menu_File" >
<property name="title" >
<string>&File</string>
</property>
+ <widget class="QMenu" name="menu_Save" >
+ <property name="enabled" >
+ <bool>false</bool>
+ </property>
+ <property name="title" >
+ <string>&Save</string>
+ </property>
+ <addaction name="action_World_save" />
+ <addaction name="action_Neighbourhood_save" />
+ <addaction name="action_Function_save" />
+ </widget>
<widget class="QMenu" name="menu_Open" >
<property name="statusTip" >
<string>Opens experiment data.</string>
@@ -70,17 +86,15 @@
<addaction name="action_Neighbourhood" />
<addaction name="action_Function" />
</widget>
- <widget class="QMenu" name="menu_Save" >
- <property name="enabled" >
- <bool>false</bool>
- </property>
+ <widget class="QMenu" name="menu_New" >
<property name="title" >
- <string>&Save</string>
+ <string>&New</string>
</property>
- <addaction name="action_World_save" />
- <addaction name="action_Neighbourhood_save" />
- <addaction name="action_Function_save" />
+ <addaction name="action_New_World" />
+ <addaction name="action_New_Neighbourhood" />
+ <addaction name="action_New_Function" />
</widget>
+ <addaction name="menu_New" />
<addaction name="menu_Open" />
<addaction name="action_Open_experiment" />
<addaction name="action_Continue_experiment" />
@@ -89,11 +103,6 @@
<addaction name="separator" />
<addaction name="action_Quit" />
</widget>
- <widget class="QMenu" name="menu_View" >
- <property name="title" >
- <string>&View</string>
- </property>
- </widget>
<addaction name="menu_File" />
<addaction name="menu_View" />
<addaction name="menu_Experiment" />
@@ -295,6 +304,21 @@
<string>&Elemental rules</string>
</property>
</action>
+ <action name="action_New_World" >
+ <property name="text" >
+ <string>&World</string>
+ </property>
+ </action>
+ <action name="action_New_Neighbourhood" >
+ <property name="text" >
+ <string>&Neighbourhood</string>
+ </property>
+ </action>
+ <action name="action_New_Function" >
+ <property name="text" >
+ <string>&Function</string>
+ </property>
+ </action>
</widget>
<resources/>
<connections/>
Added: trunk/qcell/visgui/NewNeighbourhoodDialog.ui
===================================================================
--- trunk/qcell/visgui/NewNeighbourhoodDialog.ui (rev 0)
+++ trunk/qcell/visgui/NewNeighbourhoodDialog.ui 2007-01-23 20:15:29 UTC (rev 238)
@@ -0,0 +1,264 @@
+<ui version="4.0" >
+ <class>NewNeighbourhoodDialog</class>
+ <widget class="QDialog" name="NewNeighbourhoodDialog" >
+ <property name="geometry" >
+ <rect>
+ <x>0</x>
+ <y>0</y>
+ <width>400</width>
+ <height>288</height>
+ </rect>
+ </property>
+ <property name="windowTitle" >
+ <string>New Neighbourhood properties</string>
+ </property>
+ <layout class="QVBoxLayout" >
+ <property name="margin" >
+ <number>9</number>
+ </property>
+ <property name="spacing" >
+ <number>6</number>
+ </property>
+ <item>
+ <layout class="QVBoxLayout" >
+ <property name="margin" >
+ <number>0</number>
+ </property>
+ <property name="spacing" >
+ <number>6</number>
+ </property>
+ <item>
+ <widget class="QGroupBox" name="dimensionsGroupBox" >
+ <property name="title" >
+ <string>Dimensions selection</string>
+ </property>
+ <layout class="QHBoxLayout" >
+ <property name="margin" >
+ <number>9</number>
+ </property>
+ <property name="spacing" >
+ <number>6</number>
+ </property>
+ <item>
+ <widget class="QRadioButton" name="rdioButton1D" >
+ <property name="text" >
+ <string>1D</string>
+ </property>
+ <property name="checked" >
+ <bool>true</bool>
+ </property>
+ </widget>
+ </item>
+ <item>
+ <widget class="QRadioButton" name="radioButton2D" >
+ <property name="text" >
+ <string>2D</string>
+ </property>
+ </widget>
+ </item>
+ <item>
+ <widget class="QRadioButton" name="radioButton3D" >
+ <property name="text" >
+ <string>3D</string>
+ </property>
+ </widget>
+ </item>
+ </layout>
+ </widget>
+ </item>
+ </layout>
+ </item>
+ <item>
+ <layout class="QHBoxLayout" >
+ <property name="margin" >
+ <number>0</number>
+ </property>
+ <property name="spacing" >
+ <number>6</number>
+ </property>
+ <item>
+ <widget class="QGroupBox" name="sizesGroupBox" >
+ <property name="title" >
+ <string>Sizes specyfication</string>
+ </property>
+ <layout class="QGridLayout" >
+ <property name="margin" >
+ <number>9</number>
+ </property>
+ <property name="spacing" >
+ <number>6</number>
+ </property>
+ <item row="2" column="1" >
+ <widget class="QSpinBox" name="spinBox3D" >
+ <property name="enabled" >
+ <bool>false</bool>
+ </property>
+ </widget>
+ </item>
+ <item row="1" column="1" >
+ <widget class="QSpinBox" name="spinBox2D" >
+ <property name="enabled" >
+ <bool>false</bool>
+ </property>
+ </widget>
+ </item>
+ <item row="0" column="1" >
+ <widget class="QSpinBox" name="spinBox1D" >
+ <property name="minimum" >
+ <number>1</number>
+ </property>
+ </widget>
+ </item>
+ <item row="2" column="0" >
+ <widget class="QLabel" name="label3D" >
+ <property name="text" >
+ <string>Size Z</string>
+ </property>
+ <property name="buddy" >
+ <cstring>spinBox3D</cstring>
+ </property>
+ </widget>
+ </item>
+ <item row="0" column="0" >
+ <widget class="QLabel" name="label1D" >
+ <property name="text" >
+ <string>Size X</string>
+ </property>
+ <property name="buddy" >
+ <cstring>spinBox1D</cstring>
+ </property>
+ </widget>
+ </item>
+ <item row="1" column="0" >
+ <widget class="QLabel" name="label2D" >
+ <property name="text" >
+ <string>Size Y</string>
+ </property>
+ <property name="buddy" >
+ <cstring>spinBox2D</cstring>
+ </property>
+ </widget>
+ </item>
+ </layout>
+ </widget>
+ </item>
+ </layout>
+ </item>
+ <item>
+ <spacer>
+ <property name="orientation" >
+ <enum>Qt::Vertical</enum>
+ </property>
+ <property name="sizeHint" >
+ <size>
+ <width>20</width>
+ <height>40</height>
+ </size>
+ </property>
+ </spacer>
+ </item>
+ <item>
+ <widget class="QDialogButtonBox" name="buttonBox" >
+ <property name="orientation" >
+ <enum>Qt::Horizontal</enum>
+ </property>
+ <property name="standardButtons" >
+ <set>QDialogButtonBox::Cancel|QDialogButtonBox::NoButton|QDialogButtonBox::Ok</set>
+ </property>
+ </widget>
+ </item>
+ </layout>
+ </widget>
+ <tabstops>
+ <tabstop>rdioButton1D</tabstop>
+ <tabstop>radioButton2D</tabstop>
+ <tabstop>radioButton3D</tabstop>
+ <tabstop>spinBox2D</tabstop>
+ <tabstop>spinBox1D</tabstop>
+ <tabstop>spinBox3D</tabstop>
+ <tabstop>buttonBox</tabstop>
+ </tabstops>
+ <resources/>
+ <connections>
+ <connection>
+ <sender>buttonBox</sender>
+ <signal>accepted()</signal>
+ <receiver>NewNeighbourhoodDialog</receiver>
+ <slot>accept()</slot>
+ <hints>
+ <hint type="sourcelabel" >
+ <x>248</x>
+ <y>254</y>
+ </hint>
+ <hint type="destinationlabel" >
+ <x>157</x>
+ <y>274</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>buttonBox</sender>
+ <signal>rejected()</signal>
+ <receiver>NewNeighbourhoodDialog</receiver>
+ <slot>reject()</slot>
+ <hints>
+ <hint type="sourcelabel" >
+ <x>316</x>
+ <y>260</y>
+ </hint>
+ <hint type="destinationlabel" >
+ <x>286</x>
+ <y>274</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>radioButton2D</sender>
+ <signal>toggled(bool)</signal>
+ <receiver>spinBox2D</receiver>
+ <slot>setEnabled(bool)</slot>
+ <hints>
+ <hint type="sourcelabel" >
+ <x>170</x>
+ <y>55</y>
+ </hint>
+ <hint type="destinationlabel" >
+ <x>228</x>
+ <y>151</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>radioButton3D</sender>
+ <signal>toggled(bool)</signal>
+ <receiver>spinBox2D</receiver>
+ <slot>setEnabled(bool)</slot>
+ <hints>
+ <hint type="sourcelabel" >
+ <x>286</x>
+ <y>51</y>
+ </hint>
+ <hint type="destinationlabel" >
+ <x>333</x>
+ <y>161</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>radioButton3D</sender>
+ <signal>toggled(bool)</signal>
+ <receiver>spinBox3D</receiver>
+ <slot>setEnabled(bool)</slot>
+ <hints>
+ <hint type="sourcelabel" >
+ <x>358</x>
+ <y>47</y>
+ </hint>
+ <hint type="destinationlabel" >
+ <x>311</x>
+ <y>186</y>
+ </hint>
+ </hints>
+ </connection>
+ </connections>
+</ui>
Added: trunk/qcell/visgui/NewNeighbourhoodWizard.cpp
===================================================================
--- trunk/qcell/visgui/NewNeighbourhoodWizard.cpp (rev 0)
+++ trunk/qcell/visgui/NewNeighbourhoodWizard.cpp 2007-01-23 20:15:29 UTC (rev 238)
@@ -0,0 +1,14 @@
+/**@file NewNeighbourhoodWizard.cpp
+ * @author czarny
+ * @date
+ * Created: wto 23 sty 2007 20:32:50 CET \n
+ * Last Update: wto 23 sty 2007 20:32:50 CET
+ */
+
+#include "NewNeighbourhoodWizard.h"
+
+NewNeighbourhoodWizard::NewNeighbourhoodWizard()
+{
+ setupUi(this);
+}
+
Added: trunk/qcell/visgui/NewNeighbourhoodWizard.h
===================================================================
--- trunk/qcell/visgui/NewNeighbourhoodWizard.h (rev 0)
+++ trunk/qcell/visgui/NewNeighbourhoodWizard.h 2007-01-23 20:15:29 UTC (rev 238)
@@ -0,0 +1,23 @@
+/**@file NewNeighbourhoodWizard.h
+ * @author czarny
+ * @date
+ * Created: wto 23 sty 2007 20:33:00 CET \n
+ * Last Update: wto 23 sty 2007 20:33:00 CET
+ * @brief A wizard to get basic data about a new world
+ */
+
+#ifndef __NEWNEIGHBOURHOODWIZARD_H__
+#define __NEWNEIGHBOURHOODWIZARD_H__
+
+#include "ui_NewNeighbourhoodDialog.h"
+#include <QDialog>
+
+class NewNeighbourhoodWizard: public QDialog, public Ui::NewNeighbourhoodDialog
+{
+ Q_OBJECT
+public:
+ NewNeighbourhoodWizard();
+};
+
+#endif // __NEWNEIGHBOURHOODWIZARD_H__
+
Added: trunk/qcell/visgui/NewWorldDialog.ui
===================================================================
--- trunk/qcell/visgui/NewWorldDialog.ui (rev 0)
+++ trunk/qcell/visgui/NewWorldDialog.ui 2007-01-23 20:15:29 UTC (rev 238)
@@ -0,0 +1,297 @@
+<ui version="4.0" >
+ <class>NewWorldDialog</class>
+ <widget class="QDialog" name="NewWorldDialog" >
+ <property name="geometry" >
+ <rect>
+ <x>0</x>
+ <y>0</y>
+ <width>400</width>
+ <height>285</height>
+ </rect>
+ </property>
+ <property name="windowTitle" >
+ <string>New World setup</string>
+ </property>
+ <layout class="QVBoxLayout" >
+ <property name="margin" >
+ <number>9</number>
+ </property>
+ <property name="spacing" >
+ <number>6</number>
+ </property>
+ <item>
+ <layout class="QVBoxLayout" >
+ <property name="margin" >
+ <number>0</number>
+ </property>
+ <property name="spacing" >
+ <number>6</number>
+ </property>
+ <item>
+ <widget class="QGroupBox" name="dimensionsGroupBox" >
+ <property name="title" >
+ <string>Dimensions selection</string>
+ </property>
+ <layout class="QHBoxLayout" >
+ <property name="margin" >
+ <number>9</number>
+ </property>
+ <property name="spacing" >
+ <number>6</number>
+ </property>
+ <item>
+ <widget class="QRadioButton" name="rdioButton1D" >
+ <property name="text" >
+ <string>1D</string>
+ </property>
+ <property name="checked" >
+ <bool>true</bool>
+ </property>
+ </widget>
+ </item>
+ <item>
+ <widget class="QRadioButton" name="radioButton2D" >
+ <property name="text" >
+ <string>2D</string>
+ </property>
+ </widget>
+ </item>
+ <item>
+ <widget class="QRadioButton" name="radioButton3D" >
+ <property name="text" >
+ <string>3D</string>
+ </property>
+ </widget>
+ </item>
+ </layout>
+ </widget>
+ </item>
+ </layout>
+ </item>
+ <item>
+ <layout class="QHBoxLayout" >
+ <property name="margin" >
+ <number>0</number>
+ </property>
+ <property name="spacing" >
+ <number>6</number>
+ </property>
+ <item>
+ <widget class="QGroupBox" name="sizesGroupBox" >
+ <property name="title" >
+ <string>Sizes specyfication</string>
+ </property>
+ <layout class="QGridLayout" >
+ <property name="margin" >
+ <number>9</number>
+ </property>
+ <property name="spacing" >
+ <number>6</number>
+ </property>
+ <item row="2" column="1" >
+ <widget class="QSpinBox" name="spinBox3D" >
+ <property name="enabled" >
+ <bool>false</bool>
+ </property>
+ </widget>
+ </item>
+ <item row="1" column="1" >
+ <widget class="QSpinBox" name="spinBox2D" >
+ <property name="enabled" >
+ <bool>false</bool>
+ </property>
+ </widget>
+ </item>
+ <item row="0" column="1" >
+ <widget class="QSpinBox" name="spinBox1D" >
+ <property name="minimum" >
+ <number>1</number>
+ </property>
+ </widget>
+ </item>
+ <item row="2" column="0" >
+ <widget class="QLabel" name="label3D" >
+ <property name="text" >
+ <string>Size Z</string>
+ </property>
+ <property name="buddy" >
+ <cstring>spinBox3D</cstring>
+ </property>
+ </widget>
+ </item>
+ <item row="0" column="0" >
+ <widget class="QLabel" name="label1D" >
+ <property name="text" >
+ <string>Size X</string>
+ </property>
+ <property name="buddy" >
+ <cstring>spinBox1D</cstring>
+ </property>
+ </widget>
+ </item>
+ <item row="1" column="0" >
+ <widget class="QLabel" name="label2D" >
+ <property name="text" >
+ <string>Size Y</string>
+ </property>
+ <property name="buddy" >
+ <cstring>spinBox2D</cstring>
+ </property>
+ </widget>
+ </item>
+ </layout>
+ </widget>
+ </item>
+ <item>
+ <widget class="QGroupBox" name="othersGroupBox" >
+ <property name="title" >
+ <string>Others</string>
+ </property>
+ <layout class="QHBoxLayout" >
+ <property name="margin" >
+ <number>9</number>
+ </property>
+ <property name="spacing" >
+ <number>6</number>
+ </property>
+ <item>
+ <widget class="QLabel" name="defaultValueLabel" >
+ <property name="text" >
+ <string>Default value</string>
+ </property>
+ <property name="buddy" >
+ <cstring>defaultValueSpinBox</cstring>
+ </property>
+ </widget>
+ </item>
+ <item>
+ <widget class="QSpinBox" name="defaultValueSpinBox" >
+ <property name="maximum" >
+ <number>59</number>
+ </property>
+ </widget>
+ </item>
+ </layout>
+ </widget>
+ </item>
+ </layout>
+ </item>
+ <item>
+ <spacer>
+ <property name="orientation" >
+ <enum>Qt::Vertical</enum>
+ </property>
+ <property name="sizeHint" >
+ <size>
+ <width>20</width>
+ <height>40</height>
+ </size>
+ </property>
+ </spacer>
+ </item>
+ <item>
+ <widget class="QDialogButtonBox" name="buttonBox" >
+ <property name="orientation" >
+ <enum>Qt::Horizontal</enum>
+ </property>
+ <property name="standardButtons" >
+ <set>QDialogButtonBox::Cancel|QDialogButtonBox::NoButton|QDialogButtonBox::Ok</set>
+ </property>
+ </widget>
+ </item>
+ </layout>
+ </widget>
+ <tabstops>
+ <tabstop>rdioButton1D</tabstop>
+ <tabstop>radioButton2D</tabstop>
+ <tabstop>radioButton3D</tabstop>
+ <tabstop>spinBox1D</tabstop>
+ <tabstop>spinBox2D</tabstop>
+ <tabstop>spinBox3D</tabstop>
+ <tabstop>defaultValueSpinBox</tabstop>
+ <tabstop>buttonBox</tabstop>
+ </tabstops>
+ <resources/>
+ <connections>
+ <connection>
+ <sender>buttonBox</sender>
+ <signal>accepted()</signal>
+ <receiver>NewWorldDialog</receiver>
+ <slot>accept()</slot>
+ <hints>
+ <hint type="sourcelabel" >
+ <x>248</x>
+ <y>254</y>
+ </hint>
+ <hint type="destinationlabel" >
+ <x>157</x>
+ <y>274</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>buttonBox</sender>
+ <signal>rejected()</signal>
+ <receiver>NewWorldDialog</receiver>
+ <slot>reject()</slot>
+ <hints>
+ <hint type="sourcelabel" >
+ <x>316</x>
+ <y>260</y>
+ </hint>
+ <hint type="destinationlabel" >
+ <x>286</x>
+ <y>274</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>radioButton3D</sender>
+ <signal>toggled(bool)</signal>
+ <receiver>spinBox3D</receiver>
+ <slot>setEnabled(bool)</slot>
+ <hints>
+ <hint type="sourcelabel" >
+ <x>333</x>
+ <y>56</y>
+ </hint>
+ <hint type="destinationlabel" >
+ <x>160</x>
+ <y>190</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>radioButton2D</sender>
+ <signal>toggled(bool)</signal>
+ <receiver>spinBox2D</receiver>
+ <slot>setEnabled(bool)</slot>
+ <hints>
+ <hint type="sourcelabel" >
+ <x>146</x>
+ <y>45</y>
+ </hint>
+ <hint type="destinationlabel" >
+ <x>142</x>
+ <y>163</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>radioButton3D</sender>
+ <signal>toggled(bool)</signal>
+ <receiver>spinBox2D</receiver>
+ <slot>setEnabled(bool)</slot>
+ <hints>
+ <hint type="sourcelabel" >
+ <x>304</x>
+ <y>56</y>
+ </hint>
+ <hint type="destinationlabel" >
+ <x>171</x>
+ <y>158</y>
+ </hint>
+ </hints>
+ </connection>
+ </connections>
+</ui>
Added: trunk/qcell/visgui/NewWorldWizard.cpp
===================================================================
--- trunk/qcell/visgui/NewWorldWizard.cpp (rev 0)
+++ trunk/qcell/visgui/NewWorldWizard.cpp 2007-01-23 20:15:29 UTC (rev 238)
@@ -0,0 +1,14 @@
+/**@file NewWorldWizard.cpp
+ * @author czarny
+ * @date
+ * Created: wto 23 sty 2007 20:32:50 CET \n
+ * Last Update: wto 23 sty 2007 20:32:50 CET
+ */
+
+#include "NewWorldWizard.h"
+
+NewWorldWizard::NewWorldWizard()
+{
+ setupUi(this);
+}
+
Added: trunk/qcell/visgui/NewWorldWizard.h
===================================================================
--- trunk/qcell/visgui/NewWorldWizard.h (rev 0)
+++ trunk/qcell/visgui/NewWorldWizard.h 2007-01-23 20:15:29 UTC (rev 238)
@@ -0,0 +1,22 @@
+/**@file NewWorldWizard.h
+ * @author czarny
+ * @date
+ * Created: wto 23 sty 2007 20:33:00 CET \n
+ * Last Update: wto 23 sty 2007 20:33:00 CET
+ * @brief A wizard to get basic data about a new world
+ */
+
+#ifndef __NEWWORLDWIZARD_H__
+#define __NEWWORLDWIZARD_H__
+
+#include "ui_NewWorldDialog.h"
+#include <QDialog>
+
+class NewWorldWizard: public QDialog, public Ui::NewWorldDialog
+{
+ Q_OBJECT
+public:
+ NewWorldWizard();
+};
+
+#endif // __NEWWORLDWIZARD_H__
Modified: trunk/qcell/visgui/visgui.pro
===================================================================
--- trunk/qcell/visgui/visgui.pro 2007-01-23 18:36:35 UTC (rev 237)
+++ trunk/qcell/visgui/visgui.pro 2007-01-23 20:15:29 UTC (rev 238)
@@ -10,6 +10,8 @@
ExperimentSetup.ui \
ElementalRulesWidget.ui \
RulePropertiesDialog.ui \
+ NewWorldDialog.ui \
+ NewNeighbourhoodDialog.ui \
../baseheaders/simulationwindow.ui \
../baseheaders/basetools.ui \
../baseheaders/view3dtools.ui \
@@ -21,6 +23,8 @@
ExperimentSetup.h \
ElementalRulesWidget.h \
RuleProperties.h \
+ NewWorldWizard.h \
+ NewNeighbourhoodWizard.h \
../baseheaders/Client.h \
../baseheaders/ClientInfo.h \
../baseheaders/BaseDataTypes.h \
@@ -45,6 +49,8 @@
ExperimentSetup.cpp \
ElementalRulesWidget.cpp \
RuleProperties.cpp \
+ NewWorldWizard.cpp \
+ NewNeighbourhoodWizard.cpp \
../basesources/Client.cpp \
../basesources/ClientInfo.cpp \
../basesources/Neighbourhood.cpp \
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <dhu...@us...> - 2007-01-23 20:23:43
|
Revision: 239
http://svn.sourceforge.net/qcell/?rev=239&view=rev
Author: dhubleizh
Date: 2007-01-23 12:23:28 -0800 (Tue, 23 Jan 2007)
Log Message:
-----------
- pending translations
Modified Paths:
--------------
trunk/qcell/visgui/visgui_pl.qm
trunk/qcell/visgui/visgui_pl.ts
Modified: trunk/qcell/visgui/visgui_pl.qm
===================================================================
(Binary files differ)
Modified: trunk/qcell/visgui/visgui_pl.ts
===================================================================
--- trunk/qcell/visgui/visgui_pl.ts 2007-01-23 20:15:29 UTC (rev 238)
+++ trunk/qcell/visgui/visgui_pl.ts 2007-01-23 20:23:28 UTC (rev 239)
@@ -49,12 +49,12 @@
<translation>Narzędzia Edycji</translation>
</message>
<message>
- <location filename="../baseheaders/basetools.ui" line="37"/>
+ <location filename="../baseheaders/basetools.ui" line="50"/>
<source>Fill</source>
<translation>Uzupełnij</translation>
</message>
<message>
- <location filename="../baseheaders/basetools.ui" line="50"/>
+ <location filename="../baseheaders/basetools.ui" line="37"/>
<source>Paste</source>
<translation>Wklej</translation>
</message>
@@ -64,42 +64,109 @@
<translation>Kopiuj</translation>
</message>
<message>
- <location filename="../baseheaders/basetools.ui" line="77"/>
+ <location filename="../baseheaders/basetools.ui" line="173"/>
<source>Values</source>
<translation>Wartości</translation>
</message>
<message>
- <location filename="../baseheaders/basetools.ui" line="100"/>
+ <location filename="../baseheaders/basetools.ui" line="125"/>
<source>View Mode</source>
<translation>Typ Wyświetlania</translation>
</message>
<message>
- <location filename="../baseheaders/basetools.ui" line="112"/>
+ <location filename="../baseheaders/basetools.ui" line="137"/>
<source>Local</source>
<translation>Lokalny</translation>
</message>
<message>
- <location filename="../baseheaders/basetools.ui" line="128"/>
+ <location filename="../baseheaders/basetools.ui" line="153"/>
<source>Global</source>
<translation>Globalny</translation>
</message>
<message>
- <location filename="../baseheaders/basetools.ui" line="148"/>
+ <location filename="../baseheaders/basetools.ui" line="77"/>
<source>Edit Mode</source>
<translation>Tryb Edycji</translation>
</message>
<message>
- <location filename="../baseheaders/basetools.ui" line="160"/>
+ <location filename="../baseheaders/basetools.ui" line="89"/>
<source>Edit</source>
<translation>Edycja</translation>
</message>
<message>
- <location filename="../baseheaders/basetools.ui" line="176"/>
+ <location filename="../baseheaders/basetools.ui" line="105"/>
<source>Select</source>
<translation>Zaznacz</translation>
</message>
</context>
<context>
+ <name>CalculationData</name>
+ <message>
+ <location filename="../basesources/CalculationData.cpp" line="829"/>
+ <source>%1;</source>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+<context>
+ <name>ElementalRuleSetupDialog</name>
+ <message>
+ <location filename="RulePropertiesDialog.ui" line="13"/>
+ <source>Rule properties</source>
+ <translation>Właściwości reguły</translation>
+ </message>
+ <message>
+ <location filename="RulePropertiesDialog.ui" line="25"/>
+ <source>Choose a symbol or colour to represent the rule with.</source>
+ <translation>Wybierz symbol albo kolor do reprezentacji reguły.</translation>
+ </message>
+ <message>
+ <location filename="RulePropertiesDialog.ui" line="61"/>
+ <source>Rule nr</source>
+ <translation>Nr reguły</translation>
+ </message>
+ <message>
+ <location filename="RulePropertiesDialog.ui" line="66"/>
+ <source>Symbol</source>
+ <translation>Symbol</translation>
+ </message>
+ <message>
+ <location filename="RulePropertiesDialog.ui" line="71"/>
+ <source>Colour</source>
+ <translation>Kolor</translation>
+ </message>
+ <message>
+ <location filename="RulePropertiesDialog.ui" line="76"/>
+ <source>Rule</source>
+ <translation>Reguła</translation>
+ </message>
+</context>
+<context>
+ <name>ElementalRulesForm</name>
+ <message>
+ <location filename="ElementalRulesWidget.ui" line="13"/>
+ <source>Form</source>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+<context>
+ <name>ElementalRulesWidget</name>
+ <message>
+ <location filename="ElementalRulesWidget.cpp" line="16"/>
+ <source>Rule</source>
+ <translation>Reguła</translation>
+ </message>
+ <message>
+ <location filename="ElementalRulesWidget.cpp" line="16"/>
+ <source>Symbol</source>
+ <translation>Symbol</translation>
+ </message>
+ <message>
+ <location filename="ElementalRulesWidget.cpp" line="16"/>
+ <source>Coordinates</source>
+ <translation>Koordynaty</translation>
+ </message>
+</context>
+<context>
<name>ExperimentSetupDialog</name>
<message>
<location filename="ExperimentSetup.ui" line="13"/>
@@ -133,6 +200,22 @@
</message>
</context>
<context>
+ <name>FunctionTable</name>
+ <message>
+ <location filename="../basesources/functiontable.cpp" line="24"/>
+ <source>%1</source>
+ <translation type="unfinished">%1</translation>
+ </message>
+</context>
+<context>
+ <name>FunctionTableClass</name>
+ <message>
+ <location filename="../baseheaders/functiontable.ui" line="13"/>
+ <source>FunctionTable</source>
+ <translation>Tabela Funkcji</translation>
+ </message>
+</context>
+<context>
<name>GenericParserPlugin</name>
<message>
<location filename="../baseheaders/GenericParserPlugin.h" line="61"/>
@@ -156,6 +239,14 @@
</message>
</context>
<context>
+ <name>LocalFunction</name>
+ <message>
+ <location filename="../basesources/LocalFunction.cpp" line="776"/>
+ <source>%1;</source>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+<context>
<name>MainWindow</name>
<message>
<location filename="MainWindow.ui" line="13"/>
@@ -168,17 +259,17 @@
<translation>P&omoc</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="60"/>
+ <location filename="MainWindow.ui" line="65"/>
<source>&File</source>
<translation>&Plik</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="64"/>
+ <location filename="MainWindow.ui" line="80"/>
<source>Opens experiment data.</source>
<translation>Otwiera dane eksperymentu.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="67"/>
+ <location filename="MainWindow.ui" line="83"/>
<source>&Open</source>
<translation>&Otwórz</translation>
</message>
@@ -188,83 +279,78 @@
<translation type="obsolete">To menu pozwala przeszukiwać tematy pomocy i poczytać o aplikacji.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="113"/>
+ <location filename="MainWindow.ui" line="128"/>
<source>&Quit</source>
<translation>&Wyjście</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="116"/>
+ <location filename="MainWindow.ui" line="131"/>
<source>This menu item quits the application.</source>
<comment>Quits the application</comment>
<translation>Ten przycisk menu powoduje wyjście z aplikacji.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="119"/>
+ <location filename="MainWindow.ui" line="134"/>
<source>Quits the application.</source>
<translation>Wychodzi z aplikacji.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="262"/>
+ <location filename="MainWindow.ui" line="314"/>
<source>&Neighbourhood</source>
<translation>&Sąsiedztwo</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="127"/>
+ <location filename="MainWindow.ui" line="142"/>
<source>Opens neighbourhood.</source>
<translation>Otwiera plik sąsiedztwa.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="270"/>
+ <location filename="MainWindow.ui" line="319"/>
<source>&Function</source>
<translation>&Funkcja</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="135"/>
+ <location filename="MainWindow.ui" line="150"/>
<source>Opens function.</source>
<translation>Otwiera plik funkcji.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="254"/>
+ <location filename="MainWindow.ui" line="309"/>
<source>&World</source>
<translation>Ś&wiat</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="143"/>
+ <location filename="MainWindow.ui" line="158"/>
<source>Opens world configuration.</source>
<translation>Otwiera konfigurację świata.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="151"/>
+ <location filename="MainWindow.ui" line="166"/>
<source>Open &experiment</source>
<translation>Otwórz &eksperyment</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="154"/>
+ <location filename="MainWindow.ui" line="169"/>
<source>Opens a predefined experiment.</source>
<translation>Otwiera zdefiniowany wcześniej eksperyment.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="158"/>
- <source>&Continiue experiment</source>
- <translation type="obsolete">&Kontynuuj eksperyment</translation>
- </message>
- <message>
- <location filename="MainWindow.ui" line="168"/>
+ <location filename="MainWindow.ui" line="183"/>
<source>Loads an earlier saved experiment.</source>
<translation>Ładuje wcześniej zachowany eksperyment.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="173"/>
+ <location filename="MainWindow.ui" line="188"/>
<source>&About</source>
<translation>&O programie</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="176"/>
+ <location filename="MainWindow.ui" line="191"/>
<source>Shows info about the program.</source>
<translation>Pokazuje informacje o programie.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="139"/>
+ <location filename="MainWindow.cpp" line="155"/>
<source>Open Neighbourhood</source>
<translation>Otwórz Sąsiedztwo</translation>
</message>
@@ -274,52 +360,52 @@
<translation type="obsolete"> pliki</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="706"/>
+ <location filename="MainWindow.cpp" line="795"/>
<source>files</source>
<translation>pliki</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="682"/>
+ <location filename="MainWindow.cpp" line="771"/>
<source>Plugins warning</source>
<translation>Ostrzeżenie wtyczek</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="131"/>
+ <location filename="MainWindow.cpp" line="147"/>
<source>There are no plugins loaded to handle Neighbourhood parsing.</source>
<translation>Nie ma załadowanej żadnej wtyczki do obsługi parsowania plików Sąsiedztwa.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="174"/>
+ <location filename="MainWindow.cpp" line="195"/>
<source>There are no plugins loaded to handle Function parsing.</source>
<translation>Nie ma załadowanej żadnej wtyczki do obsługi parsowania Funkcji.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="182"/>
+ <location filename="MainWindow.cpp" line="203"/>
<source>Open Function</source>
<translation>Otwórz Funkcję</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="218"/>
+ <location filename="MainWindow.cpp" line="244"/>
<source>There are no plugins loaded to handle World parsing.</source>
<translation>Nie ma załadowanej żadnej wtyczki do parsowania Świata.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="226"/>
+ <location filename="MainWindow.cpp" line="252"/>
<source>Open World</source>
<translation>Otwórz Świat</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="810"/>
+ <location filename="MainWindow.cpp" line="899"/>
<source>Error opening file %1.</source>
<translation>Błąd podczas otwierania pliku %1.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="423"/>
+ <location filename="MainWindow.cpp" line="502"/>
<source>The file extensions %1 isn't supported.</source>
<translation>Rozszerzenie pliku %1 nie jest wspierane.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="434"/>
+ <location filename="MainWindow.cpp" line="513"/>
<source>Unsupported file type to parse.</source>
<translation>Niewspierany typ pliku do przeczytania.</translation>
</message>
@@ -334,37 +420,37 @@
<translation>&Eksperyment</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="184"/>
+ <location filename="MainWindow.ui" line="199"/>
<source>&Start</source>
<translation>&Start</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="190"/>
+ <location filename="MainWindow.ui" line="205"/>
<source>Starts the experiment.</source>
<translation>Startuje eksperyment.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="198"/>
+ <location filename="MainWindow.ui" line="213"/>
<source>S&top</source>
<translation>S&top</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="204"/>
+ <location filename="MainWindow.ui" line="219"/>
<source>Stops the experiment.</source>
<translation>Zatrzymuje eksperyment.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="212"/>
+ <location filename="MainWindow.ui" line="227"/>
<source>&Restart</source>
<translation>Ponowne u&ruchominie</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="218"/>
+ <location filename="MainWindow.ui" line="233"/>
<source>Restarts the experiment.</source>
<translation>Uruchamia eksperyment od nowa.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="226"/>
+ <location filename="MainWindow.ui" line="241"/>
<source>&Forward</source>
<translation>Do &przodu</translation>
</message>
@@ -374,52 +460,52 @@
<translation type="obsolete">Iteruje jeden krok.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="232"/>
+ <location filename="MainWindow.ui" line="247"/>
<source>Iterates one setp forward.</source>
<translation>Iteruje jeden krok do przodu.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="240"/>
+ <location filename="MainWindow.ui" line="255"/>
<source>&Back</source>
<translation>Do &tyłu</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="246"/>
+ <location filename="MainWindow.ui" line="261"/>
<source>Iterates one setp back.</source>
<translation>Iteruje jeden krok wstecz.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="48"/>
+ <location filename="MainWindow.cpp" line="54"/>
<source>Iteration</source>
<translation>Iteracja</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="509"/>
+ <location filename="MainWindow.cpp" line="596"/>
<source>You cannot step back beyond the beginning of the experiment!</source>
<translation>Nie możesz cofnąc się poza początek eksperymentu!</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="384"/>
+ <location filename="MainWindow.cpp" line="463"/>
<source>Error opnening file %1.</source>
<translation>Błąd podczas próby otwarcia pliku %1.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="636"/>
+ <location filename="MainWindow.cpp" line="725"/>
<source>There are no plugins loaded to handle World saving.</source>
<translation>Nie ma załadowanej żadnej wtyczki do obsługi zapisywania plików świata.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="644"/>
+ <location filename="MainWindow.cpp" line="733"/>
<source>Save World</source>
<translation>Zapisz Świat</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="684"/>
+ <location filename="MainWindow.cpp" line="773"/>
<source>There are no plugins loaded to handle Neighbourhood saving.</source>
<translation>Nie ma załadowanych żadnych wtyczek do obsługi zapisywania Sąsiedztwa.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="692"/>
+ <location filename="MainWindow.cpp" line="781"/>
<source>Save Neighbourhood</source>
<translation>Zapisz Sąsiedztwo</translation>
</message>
@@ -429,17 +515,17 @@
<translation type="obsolete">&Zapisz eksperyment</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="315"/>
+ <location filename="MainWindow.cpp" line="346"/>
<source>Internal error: unable to parse %1 file</source>
<translation>Wewnętrzny błąd: nie mogę zrozumiec pliku %1</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="460"/>
+ <location filename="MainWindow.cpp" line="539"/>
<source>%1 file loaded sucesfully!</source>
<translation>Plik %1 załadowany poprawnie!</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="47"/>
+ <location filename="MainWindow.cpp" line="53"/>
<source>Shows the current iteration number.</source>
<translation>Pokazuje aktualny numer iteracji.</translation>
</message>
@@ -449,62 +535,62 @@
<translation>Opóźnienie</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="733"/>
+ <location filename="MainWindow.cpp" line="822"/>
<source>Save Experiment</source>
<translation>Zachowaj Eksperyment</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="793"/>
+ <location filename="MainWindow.cpp" line="882"/>
<source>Experiment files (*.%1)</source>
<translation>Pliki Eksperymentów (*.%1)</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="770"/>
+ <location filename="MainWindow.cpp" line="859"/>
<source>Internal error: unable to serialize experiment</source>
<translation>Wewnętrzny błąd: serializacja eksperymentu niemożliwa</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="784"/>
+ <location filename="MainWindow.cpp" line="873"/>
<source>Open Experiment</source>
<translation>Otwórz Eksperyment</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="862"/>
+ <location filename="MainWindow.cpp" line="951"/>
<source>Error deserializing Neighbourhood</source>
<translation>Błąd podczas deserializacji Sąsiedztwa</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="877"/>
+ <location filename="MainWindow.cpp" line="966"/>
<source>Error deserializing Local Function</source>
<translation>Error podczas deserializacji Funkcji Lokalnej</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="883"/>
+ <location filename="MainWindow.cpp" line="972"/>
<source>Sucessfully loaded experiment for continuation.</source>
<translation>Załadowano eksperyment do kontynuowania.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="78"/>
+ <location filename="MainWindow.ui" line="72"/>
<source>&Save</source>
<translation>&Zachowaj</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="159"/>
+ <location filename="MainWindow.ui" line="174"/>
<source>&Continue experiment</source>
<translation>&Wznów eksperyment</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="165"/>
+ <location filename="MainWindow.ui" line="180"/>
<source>Continue experiment</source>
<translation>Wznów eksperyment</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="278"/>
+ <location filename="MainWindow.ui" line="293"/>
<source>Sa&ve experiment</source>
<translation>Zac&howaj eksperyment</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="281"/>
+ <location filename="MainWindow.ui" line="296"/>
<source>Saves the whole experiment with history for later continuation.</source>
<translation>Zachowuje cały eksperyment z historią dla þóźniejszego wznowienia.</translation>
</message>
@@ -513,26 +599,162 @@
<source>Sets the delay between iteration steps in ms.</source>
<translation>Ustawia opóźnienie między krokami iteracji w ms.</translation>
</message>
+ <message>
+ <location filename="MainWindow.cpp" line="70"/>
+ <source>Elemental rules</source>
+ <translation>Reguły elementarne</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.cpp" line="162"/>
+ <source>Supported neighbourhoods</source>
+ <translation>Wspierani sąsiedzi</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.cpp" line="210"/>
+ <source>Supported functions</source>
+ <translation>Wspierane funkcje</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.cpp" line="259"/>
+ <source>Supported worlds</source>
+ <translation>Wspierane światy</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="91"/>
+ <source>&New</source>
+ <translation>&Nowy</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.ui" line="304"/>
+ <source>&Elemental rules</source>
+ <translation>&Reguły elementarne</translation>
+ </message>
</context>
<context>
+ <name>NewNeighbourhoodDialog</name>
+ <message>
+ <location filename="NewNeighbourhoodDialog.ui" line="13"/>
+ <source>New Neighbourhood properties</source>
+ <translation>Właściwości nowego sąsiedztwa</translation>
+ </message>
+ <message>
+ <location filename="NewNeighbourhoodDialog.ui" line="33"/>
+ <source>Dimensions selection</source>
+ <translation>Wybór wymiarów</translation>
+ </message>
+ <message>
+ <location filename="NewNeighbourhoodDialog.ui" line="45"/>
+ <source>1D</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="NewNeighbourhoodDialog.ui" line="55"/>
+ <source>2D</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="NewNeighbourhoodDialog.ui" line="62"/>
+ <source>3D</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="NewNeighbourhoodDialog.ui" line="82"/>
+ <source>Sizes specyfication</source>
+ <translation>Specyfikacja rozmiarów</translation>
+ </message>
+ <message>
+ <location filename="NewNeighbourhoodDialog.ui" line="115"/>
+ <source>Size Z</source>
+ <translation>Rozmiar Z</translation>
+ </message>
+ <message>
+ <location filename="NewNeighbourhoodDialog.ui" line="125"/>
+ <source>Size X</source>
+ <translation>Rozmiar X</translation>
+ </message>
+ <message>
+ <location filename="NewNeighbourhoodDialog.ui" line="135"/>
+ <source>Size Y</source>
+ <translation>Rozmiar Y</translation>
+ </message>
+</context>
+<context>
+ <name>NewWorldDialog</name>
+ <message>
+ <location filename="NewWorldDialog.ui" line="13"/>
+ <source>New World setup</source>
+ <translation>Właściwości nowego Świata</translation>
+ </message>
+ <message>
+ <location filename="NewWorldDialog.ui" line="33"/>
+ <source>Dimensions selection</source>
+ <translation>Wybór wymiarów</translation>
+ </message>
+ <message>
+ <location filename="NewWorldDialog.ui" line="45"/>
+ <source>1D</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="NewWorldDialog.ui" line="55"/>
+ <source>2D</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="NewWorldDialog.ui" line="62"/>
+ <source>3D</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="NewWorldDialog.ui" line="82"/>
+ <source>Sizes specyfication</source>
+ <translation>Specyfikacja rozmiarów</translation>
+ </message>
+ <message>
+ <location filename="NewWorldDialog.ui" line="115"/>
+ <source>Size Z</source>
+ <translation>Rozmiar Z</translation>
+ </message>
+ <message>
+ <location filename="NewWorldDialog.ui" line="125"/>
+ <source>Size X</source>
+ <translation>Rozmiar X</translation>
+ </message>
+ <message>
+ <location filename="NewWorldDialog.ui" line="135"/>
+ <source>Size Y</source>
+ <translation>Rozmiar Y</translation>
+ </message>
+ <message>
+ <location filename="NewWorldDialog.ui" line="148"/>
+ <source>Others</source>
+ <translation>Inne</translation>
+ </message>
+ <message>
+ <location filename="NewWorldDialog.ui" line="160"/>
+ <source>Default value</source>
+ <translation>Wartość domyślna</translation>
+ </message>
+</context>
+<context>
<name>QApplication</name>
<message>
- <location filename="main.cpp" line="61"/>
+ <location filename="main.cpp" line="65"/>
<source>Debug</source>
<translation>Odpluskwianie</translation>
</message>
<message>
- <location filename="main.cpp" line="64"/>
+ <location filename="main.cpp" line="68"/>
<source>Warning</source>
<translation>Ostrzeżenie</translation>
</message>
<message>
- <location filename="main.cpp" line="67"/>
+ <location filename="main.cpp" line="71"/>
<source>Critical</source>
<translation>Krytyczny</translation>
</message>
<message>
- <location filename="main.cpp" line="70"/>
+ <location filename="main.cpp" line="74"/>
<source>Fatal</source>
<translation>Śmiertelny</translation>
</message>
@@ -545,32 +767,32 @@
<translation>Narzędzia Widoku Tekstowego 1D</translation>
</message>
<message>
- <location filename="../baseheaders/view1dtexttools.ui" line="25"/>
+ <location filename="../baseheaders/view1dtexttools.ui" line="89"/>
<source>Memory</source>
<translation>Pamięć</translation>
</message>
<message>
- <location filename="../baseheaders/view1dtexttools.ui" line="37"/>
+ <location filename="../baseheaders/view1dtexttools.ui" line="101"/>
<source>Clear</source>
<translation>Wyczyść</translation>
</message>
<message>
- <location filename="../baseheaders/view1dtexttools.ui" line="51"/>
+ <location filename="../baseheaders/view1dtexttools.ui" line="25"/>
<source>View 1D Text</source>
<translation>Widok Tekstowy 1D</trans...
[truncated message content] |
|
From: <dhu...@us...> - 2007-01-24 12:49:45
|
Revision: 243
http://svn.sourceforge.net/qcell/?rev=243&view=rev
Author: dhubleizh
Date: 2007-01-24 04:49:43 -0800 (Wed, 24 Jan 2007)
Log Message:
-----------
- docks disabled by default
- unlocking of docks after full experiment setup
Modified Paths:
--------------
trunk/qcell/visgui/MainWindow.cpp
trunk/qcell/visgui/MainWindow.h
Modified: trunk/qcell/visgui/MainWindow.cpp
===================================================================
--- trunk/qcell/visgui/MainWindow.cpp 2007-01-24 12:38:54 UTC (rev 242)
+++ trunk/qcell/visgui/MainWindow.cpp 2007-01-24 12:49:43 UTC (rev 243)
@@ -49,15 +49,16 @@
// );
// View 3D Tools
- QDockWidget* dw = new QDockWidget(this);
- dw->hide();
+ dock3D = new QDockWidget(this);
+ dock3D->hide();
+ dock3D->setDisabled(true);
View3DTools* view3DTools = new View3DTools(this);
- dw->setWindowTitle(tr("3D Tools"));
- dw->setWidget(view3DTools);
- ((QVBoxLayout*)dw->layout())->addStretch();
- addDockWidget(Qt::RightDockWidgetArea, dw);
+ dock3D->setWindowTitle(tr("3D Tools"));
+ dock3D->setWidget(view3DTools);
+ ((QVBoxLayout*)dock3D->layout())->addStretch();
+ addDockWidget(Qt::RightDockWidgetArea, dock3D);
- QAction* v3d_action = dw->toggleViewAction();
+ QAction* v3d_action = dock3D->toggleViewAction();
v3d_action->setText(tr("&3D Tools"));
menu_View->addAction(v3d_action);
@@ -69,19 +70,20 @@
view3DTools, SLOT(setRange(int, int, int))
);
connect(sw, SIGNAL(set3DToolsVisible(bool)),
- dw, SLOT(setVisible(bool))
+ dock3D, SLOT(setVisible(bool))
);
// View 2D Tools
- dw = new QDockWidget(this);
- dw->hide();
+ dock2D = new QDockWidget(this);
+ dock2D->hide();
+ dock2D->setDisabled(true);
View2DTextTools* view2DTextTools = new View2DTextTools(this);
- dw->setWindowTitle(tr("2D Text Tools"));
- dw->setWidget(view2DTextTools);
- ((QVBoxLayout*)dw->layout())->addStretch();
- addDockWidget(Qt::RightDockWidgetArea, dw);
+ dock2D->setWindowTitle(tr("2D Text Tools"));
+ dock2D->setWidget(view2DTextTools);
+ ((QVBoxLayout*)dock2D->layout())->addStretch();
+ addDockWidget(Qt::RightDockWidgetArea, dock2D);
- QAction* v2d_action = dw->toggleViewAction();
+ QAction* v2d_action = dock2D->toggleViewAction();
v2d_action->setText(tr("&2D Text Tools"));
menu_View->addAction(v2d_action);
@@ -99,20 +101,21 @@
view2DTextTools, SLOT(showZPlaneOnly(bool))
);
connect(sw, SIGNAL(set2DTextToolsVisible(bool)),
- dw, SLOT(setVisible(bool))
+ dock2D, SLOT(setVisible(bool))
);
// View 1D Tools
- dw = new QDockWidget(this);
- dw->hide();
+ dock1D = new QDockWidget(this);
+ dock1D->hide();
+ dock1D->setDisabled(true);
View1DTextTools* view1DTextTools = new View1DTextTools(this);
- dw->setWindowTitle(tr("1D Text Tools"));
- dw->setWidget(view1DTextTools);
- ((QVBoxLayout*)dw->layout())->addStretch();
- addDockWidget(Qt::RightDockWidgetArea, dw);
+ dock1D->setWindowTitle(tr("1D Text Tools"));
+ dock1D->setWidget(view1DTextTools);
+ ((QVBoxLayout*)dock1D->layout())->addStretch();
+ addDockWidget(Qt::RightDockWidgetArea, dock1D);
- QAction* v1d_action = dw->toggleViewAction();
- v1d_action->setText(tr("1D Text Tools"));
+ QAction* v1d_action = dock1D->toggleViewAction();
+ v1d_action->setText(tr("&1D Text Tools"));
menu_View->addAction(v1d_action);
connect(view1DTextTools, SIGNAL(viewModeChenged(int)),
@@ -122,7 +125,7 @@
sw, SLOT(GridView1DMemClear())
);
connect(sw, SIGNAL(set1DTextToolsVisible(bool)),
- dw, SLOT(setVisible(bool))
+ dock1D, SLOT(setVisible(bool))
);
// Adding delay setup
@@ -635,6 +638,11 @@
// Whole experiment saving
action_Save_experiment->setEnabled(true);
+ // Docks unlocking
+ dock3D->setEnabled(true);
+ dock2D->setEnabled(true);
+ dock1D->setEnabled(true);
+
emit unlockGUI();
}
}
Modified: trunk/qcell/visgui/MainWindow.h
===================================================================
--- trunk/qcell/visgui/MainWindow.h 2007-01-24 12:38:54 UTC (rev 242)
+++ trunk/qcell/visgui/MainWindow.h 2007-01-24 12:49:43 UTC (rev 243)
@@ -106,6 +106,9 @@
Calculator calc;
ElementalRules* elemental_rules;
QDockWidget* elemental_dock;
+ QDockWidget* dock3D;
+ QDockWidget* dock2D;
+ QDockWidget* dock1D;
QList<CalculationData*> data;
LocalFunction* local_function;
Neighbourhood* neighbourhood;
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <dhu...@us...> - 2007-01-24 13:47:28
|
Revision: 244
http://svn.sourceforge.net/qcell/?rev=244&view=rev
Author: dhubleizh
Date: 2007-01-24 05:47:27 -0800 (Wed, 24 Jan 2007)
Log Message:
-----------
- BetterDockWidget implemented on top of QDockWidget to make floating widget adjust their size to minimum required
Modified Paths:
--------------
trunk/qcell/visgui/MainWindow.cpp
trunk/qcell/visgui/MainWindow.h
trunk/qcell/visgui/visgui.pro
Added Paths:
-----------
trunk/qcell/visgui/BetterDockWidget.cpp
trunk/qcell/visgui/BetterDockWidget.h
Added: trunk/qcell/visgui/BetterDockWidget.cpp
===================================================================
--- trunk/qcell/visgui/BetterDockWidget.cpp (rev 0)
+++ trunk/qcell/visgui/BetterDockWidget.cpp 2007-01-24 13:47:27 UTC (rev 244)
@@ -0,0 +1,34 @@
+/**@file BetterDockWidget.cpp
+ * @author czarny
+ * @date
+ * Created: \xB6ro 24 sty 2007 14:15:49 CET \n
+ * Last Update: \xB6ro 24 sty 2007 14:15:49 CET
+ */
+
+#include "BetterDockWidget.h"
+
+BetterDockWidget::BetterDockWidget ( const QString & title, QWidget * parent/*0*/, Qt::WindowFlags flags/*0 */)
+ : QDockWidget(title, parent, flags)
+{
+ connect(this, SIGNAL(topLevelChanged(bool)),
+ this, SLOT(shrinkOnFloat())
+ );
+}
+
+BetterDockWidget::BetterDockWidget ( QWidget * parent/*0*/, Qt::WindowFlags flags/*0 */)
+ : QDockWidget(parent, flags)
+{
+ connect(this, SIGNAL(topLevelChanged(bool)),
+ this, SLOT(shrinkOnFloat())
+ );
+}
+
+BetterDockWidget::~BetterDockWidget()
+{
+}
+
+void BetterDockWidget::shrinkOnFloat()
+{
+ adjustSize();
+}
+
Added: trunk/qcell/visgui/BetterDockWidget.h
===================================================================
--- trunk/qcell/visgui/BetterDockWidget.h (rev 0)
+++ trunk/qcell/visgui/BetterDockWidget.h 2007-01-24 13:47:27 UTC (rev 244)
@@ -0,0 +1,27 @@
+/**@file BetterDockWidget.h
+ * @author czarny
+ * @date
+ * Created: \xB6ro 24 sty 2007 14:13:00 CET \n
+ * Last Update: \xB6ro 24 sty 2007 14:13:00 CET
+ * @brief Make QDockWidgets shrink as they become floating
+ */
+
+#ifndef __BETTERDOCKWIDGET_H__
+#define __BETTERDOCKWIDGET_H__
+
+#include <QDockWidget>
+#include <QObject>
+
+class BetterDockWidget: public QDockWidget
+{
+ Q_OBJECT
+protected slots:
+ void shrinkOnFloat();
+public:
+ BetterDockWidget (const QString & title, QWidget * parent = 0, Qt::WindowFlags flags = 0);
+ BetterDockWidget (QWidget * parent = 0, Qt::WindowFlags flags = 0);
+
+ ~BetterDockWidget();
+};
+
+#endif // __BETTERDOCKWIDGET_H__
Modified: trunk/qcell/visgui/MainWindow.cpp
===================================================================
--- trunk/qcell/visgui/MainWindow.cpp 2007-01-24 12:49:43 UTC (rev 243)
+++ trunk/qcell/visgui/MainWindow.cpp 2007-01-24 13:47:27 UTC (rev 244)
@@ -48,20 +48,26 @@
// basetools, SLOT(setItem(int, int, QTableWidgetItem*))
// );
+// QSizePolicy sp(QSizePolicy::Minimum, QSizePolicy::Minimum);
// View 3D Tools
- dock3D = new QDockWidget(this);
+ dock3D = new BetterDockWidget(this);
dock3D->hide();
dock3D->setDisabled(true);
+// dock3D->setSizePolicy(sp);
View3DTools* view3DTools = new View3DTools(this);
dock3D->setWindowTitle(tr("3D Tools"));
dock3D->setWidget(view3DTools);
((QVBoxLayout*)dock3D->layout())->addStretch();
+ dock3D->setAllowedAreas(Qt::LeftDockWidgetArea | Qt::RightDockWidgetArea);
addDockWidget(Qt::RightDockWidgetArea, dock3D);
QAction* v3d_action = dock3D->toggleViewAction();
v3d_action->setText(tr("&3D Tools"));
menu_View->addAction(v3d_action);
+// connect(dock3D, SIGNAL(topLevelChanged(bool)),
+// this, SLOT(test())
+// );
connect(view3DTools, SIGNAL(ViewModeUpdated(int)),
sw, SLOT(perspectiveUpdate(int)));
connect(view3DTools, SIGNAL(maskSet(int, int, int)),
@@ -74,13 +80,14 @@
);
// View 2D Tools
- dock2D = new QDockWidget(this);
+ dock2D = new BetterDockWidget(this);
dock2D->hide();
dock2D->setDisabled(true);
View2DTextTools* view2DTextTools = new View2DTextTools(this);
dock2D->setWindowTitle(tr("2D Text Tools"));
dock2D->setWidget(view2DTextTools);
((QVBoxLayout*)dock2D->layout())->addStretch();
+ dock2D->setAllowedAreas(Qt::LeftDockWidgetArea | Qt::RightDockWidgetArea);
addDockWidget(Qt::RightDockWidgetArea, dock2D);
QAction* v2d_action = dock2D->toggleViewAction();
@@ -105,13 +112,14 @@
);
// View 1D Tools
- dock1D = new QDockWidget(this);
+ dock1D = new BetterDockWidget(this);
dock1D->hide();
dock1D->setDisabled(true);
View1DTextTools* view1DTextTools = new View1DTextTools(this);
dock1D->setWindowTitle(tr("1D Text Tools"));
dock1D->setWidget(view1DTextTools);
((QVBoxLayout*)dock1D->layout())->addStretch();
+ dock1D->setAllowedAreas(Qt::LeftDockWidgetArea | Qt::RightDockWidgetArea);
addDockWidget(Qt::RightDockWidgetArea, dock1D);
QAction* v1d_action = dock1D->toggleViewAction();
@@ -170,12 +178,13 @@
QStringList parser_types, file_types;
// Elemental dock widget
- elemental_dock = new QDockWidget(this);
+ elemental_dock = new BetterDockWidget(this);
// We don't want it appear at the beginning
elemental_dock->hide();
elemental_dock->setWidget(new ElementalRulesWidget());
elemental_dock->setWindowTitle(tr("Elemental rules"));
+ elemental_dock->setAllowedAreas(Qt::LeftDockWidgetArea | Qt::RightDockWidgetArea);
addDockWidget(Qt::LeftDockWidgetArea, elemental_dock);
// We want to be able to show or hide the widget from View menu
QAction* elemental_action = elemental_dock->toggleViewAction();
@@ -1133,3 +1142,8 @@
}
}
+void MainWindow::test()
+{
+ dock3D->adjustSize();
+}
+
Modified: trunk/qcell/visgui/MainWindow.h
===================================================================
--- trunk/qcell/visgui/MainWindow.h 2007-01-24 12:49:43 UTC (rev 243)
+++ trunk/qcell/visgui/MainWindow.h 2007-01-24 13:47:27 UTC (rev 244)
@@ -16,6 +16,7 @@
#include "ElementalRules.h"
#include "NewWorldWizard.h"
#include "NewNeighbourhoodWizard.h"
+#include "BetterDockWidget.h"
#include <view3dtools.h>
#include <view2dtexttools.h>
#include <view1dtexttools.h>
@@ -45,6 +46,8 @@
Q_OBJECT
signals:
void unlockGUI();
+public slots:
+ void test();
public:
MainWindow(QWidget* parent = 0);
@@ -106,9 +109,9 @@
Calculator calc;
ElementalRules* elemental_rules;
QDockWidget* elemental_dock;
- QDockWidget* dock3D;
- QDockWidget* dock2D;
- QDockWidget* dock1D;
+ BetterDockWidget* dock3D;
+ BetterDockWidget* dock2D;
+ BetterDockWidget* dock1D;
QList<CalculationData*> data;
LocalFunction* local_function;
Neighbourhood* neighbourhood;
Modified: trunk/qcell/visgui/visgui.pro
===================================================================
--- trunk/qcell/visgui/visgui.pro 2007-01-24 12:49:43 UTC (rev 243)
+++ trunk/qcell/visgui/visgui.pro 2007-01-24 13:47:27 UTC (rev 244)
@@ -25,6 +25,7 @@
RuleProperties.h \
NewWorldWizard.h \
NewNeighbourhoodWizard.h \
+ BetterDockWidget.h \
../baseheaders/Client.h \
../baseheaders/ClientInfo.h \
../baseheaders/BaseDataTypes.h \
@@ -51,6 +52,7 @@
RuleProperties.cpp \
NewWorldWizard.cpp \
NewNeighbourhoodWizard.cpp \
+ BetterDockWidget.cpp \
../basesources/Client.cpp \
../basesources/ClientInfo.cpp \
../basesources/Neighbourhood.cpp \
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <dhu...@us...> - 2007-01-24 17:06:38
|
Revision: 251
http://svn.sourceforge.net/qcell/?rev=251&view=rev
Author: dhubleizh
Date: 2007-01-24 09:06:29 -0800 (Wed, 24 Jan 2007)
Log Message:
-----------
- serialization works now
Modified Paths:
--------------
trunk/qcell/visgui/MainWindow.cpp
trunk/qcell/visgui/MainWindow.h
trunk/qcell/visgui/MainWindow.ui
Modified: trunk/qcell/visgui/MainWindow.cpp
===================================================================
--- trunk/qcell/visgui/MainWindow.cpp 2007-01-24 16:23:56 UTC (rev 250)
+++ trunk/qcell/visgui/MainWindow.cpp 2007-01-24 17:06:29 UTC (rev 251)
@@ -25,6 +25,7 @@
BaseTools* basetools = new BaseTools(baseDock);
baseDock->setWindowTitle(tr("Base tools"));
baseDock->setWidget(basetools);
+ baseDock->setDisabled(true);
((QVBoxLayout*)baseDock->layout())->addStretch();
addDockWidget(Qt::RightDockWidgetArea, baseDock);
@@ -171,6 +172,15 @@
statusBar()->addPermanentWidget(tmp_label);
statusBar()->addPermanentWidget(iterationLCD);
+ // Model elements loaded indicator
+ world_check = new QCheckBox(tr("World"), this);
+// world_check->setBackgroundColor(QColor(Qt::red));
+ neighbourhood_check = new QCheckBox(tr("Neighbourhood"), this);
+ local_function_check = new QCheckBox(tr("Local Function"), this);
+ statusBar()->addPermanentWidget(world_check);
+ statusBar()->addPermanentWidget(neighbourhood_check);
+ statusBar()->addPermanentWidget(local_function_check);
+
// Plugin parsing
/// @todo get that code out of here!
ParserInterface* iParser;
@@ -438,7 +448,7 @@
}
//***************************************************
- *sw->getNeighbourhoodEditor()->getStorage() = neighbourhood->toCalculationData();
+// *sw->getNeighbourhoodEditor()->getStorage() = neighbourhood->toCalculationData();
sw->getNeighbourhoodEditor()->setTranslation(0.0f, 0.0f, -10.0f);
sw->getNeighbourhoodEditor()->setSymbolColor(1, QColor(128, 128, 128));
//***************************************************
@@ -651,7 +661,11 @@
// Whole experiment saving
action_Save_experiment->setEnabled(true);
+ // Menus
+ menu_View->setEnabled(true);
+
// Docks unlocking
+ baseDock->setEnabled(true);
dock3D->setEnabled(true);
dock2D->setEnabled(true);
dock1D->setEnabled(true);
@@ -1037,24 +1051,51 @@
QByteArray MainWindow::serialize()
{
- /// @todo wait for CalculationData toXml method and serialize using XML
- QByteArray result, data_portion;
- QDataStream ds(&result, QIODevice::WriteOnly);
+ QDomDocument doc;
+ QDomDocument *element;
+ QDomElement root;
- // Neighbourhood
- data_portion = neighbourhood->toXmlString().toAscii();
- ds << (qint32)data_portion.size();
- ds.writeRawData(data_portion.data(), (int)data_portion.size());
+ // Creating root
+ root = doc.createElement("Experiment");
+ root.setAttribute("iterations", iteration);
- // LocalFunction
- data_portion = local_function->toXmlString().toAscii();
- ds << (qint32)data_portion.size();
- ds.writeRawData(data_portion.data(), (int)data_portion.size());
+ // Try to parse Neighbourhood
+ element = new QDomDocument();
+ if(!element->setContent(neighbourhood->toXmlString()))
+ {
+ qDebug(tr("Internal error: unable to serialize Neighbourhood.").toAscii());
+ return QByteArray();
+ }
+ root.appendChild(*element);
- // CalculationData
- /// @todo write CalculationData serialization
+ // Try serializing Local Function
+ element = new QDomDocument();
+ if (!element->setContent(local_function->toXmlString()))
+ {
+ qDebug(tr("Internal error: unable to serialize Local Function.").toAscii());
+ return QByteArray();
+ }
+ root.appendChild(*element);
- return result;
+ // Now the hardest part - serializing calculation data history
+ for (int i = 0; i < iteration+1; i++)
+ {
+ element = new QDomDocument();
+ if (!element->setContent(data[i]->toXmlString()))
+ {
+ qDebug(tr("Internal error: unable to serialize Calculation Data in the %1th iteration.")
+ .arg(i)
+ .toAscii()
+ );
+ return QByteArray();
+ }
+
+ root.appendChild(*element);
+ }
+
+ doc.appendChild(root);
+
+ return doc.toByteArray();
}
void MainWindow::deserialize(QByteArray content)
Modified: trunk/qcell/visgui/MainWindow.h
===================================================================
--- trunk/qcell/visgui/MainWindow.h 2007-01-24 16:23:56 UTC (rev 250)
+++ trunk/qcell/visgui/MainWindow.h 2007-01-24 17:06:29 UTC (rev 251)
@@ -85,6 +85,7 @@
QLCDNumber* iterationLCD;
QSlider* delaySlider;
QDoubleSpinBox* delaySpinBox;
+ QCheckBox* world_check, *neighbourhood_check, *local_function_check;
QMap<QString, ParserInterface*> neighbourhood_parsers;
QMap<QString, ParserInterface*> function_parsers;
QMap<QString, ParserInterface*> world_parsers;
Modified: trunk/qcell/visgui/MainWindow.ui
===================================================================
--- trunk/qcell/visgui/MainWindow.ui 2007-01-24 16:23:56 UTC (rev 250)
+++ trunk/qcell/visgui/MainWindow.ui 2007-01-24 17:06:29 UTC (rev 251)
@@ -56,6 +56,9 @@
<addaction name="action_About" />
</widget>
<widget class="QMenu" name="menu_View" >
+ <property name="enabled" >
+ <bool>false</bool>
+ </property>
<property name="title" >
<string>&View</string>
</property>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <dhu...@us...> - 2007-01-24 18:34:45
|
Revision: 252
http://svn.sourceforge.net/qcell/?rev=252&view=rev
Author: dhubleizh
Date: 2007-01-24 10:34:40 -0800 (Wed, 24 Jan 2007)
Log Message:
-----------
- serialization and deserialization fully work
- tested it somewhat
Modified Paths:
--------------
trunk/qcell/visgui/MainWindow.cpp
trunk/qcell/visgui/MainWindow.h
Modified: trunk/qcell/visgui/MainWindow.cpp
===================================================================
--- trunk/qcell/visgui/MainWindow.cpp 2007-01-24 17:06:29 UTC (rev 251)
+++ trunk/qcell/visgui/MainWindow.cpp 2007-01-24 18:34:40 UTC (rev 252)
@@ -447,16 +447,8 @@
return;
}
- //***************************************************
-// *sw->getNeighbourhoodEditor()->getStorage() = neighbourhood->toCalculationData();
- sw->getNeighbourhoodEditor()->setTranslation(0.0f, 0.0f, -10.0f);
- sw->getNeighbourhoodEditor()->setSymbolColor(1, QColor(128, 128, 128));
- //***************************************************
- calc.setNeighbourhood(neighbourhood);
+ setupNeighbourhood();
- // Enable saving menu for Neighbourhood
- menu_Save->setEnabled(true);
- action_Neighbourhood_save->setEnabled(true);
}
else if (type == "LocalFunction")
{
@@ -472,7 +464,7 @@
local_function = new LocalFunction();
if (!local_function->fromXmlString(&function_parsers[subtype]->parse(file_content, type, subtype)))
{
- qDebug(tr("Internal error: unable to parse %1 file")
+ qDebug(tr("Internal error: unable to parse %1 file.")
.arg(type)
.toAscii()
);
@@ -480,14 +472,8 @@
return;
}
- // Enable saving menu for LocalFunction
- menu_Save->setEnabled(true);
- action_Function_save->setEnabled(true);
+ setupLocalFunction();
- calc.setLocalFunction(local_function);
- // for test only *********************************
- sw->getFunctionTable()->setFunctionPointer(local_function);
- //************************************************
}
else if (type == "World")
{
@@ -500,76 +486,23 @@
return;
}
- /// @todo Fix that!
+ // Reset the data
data.clear();
- /// @todo Get rid of that ugly hack!
- QString XMLString = world_parsers[subtype]->parse(file_content, type, subtype);
- /// @todo Nasty - get that code out of here !
- if(XMLString.isEmpty())
+
+ // Parse the file
+ CalculationData *tempCD = new CalculationData();
+ if(!tempCD->setFromXmlString(&world_parsers[subtype]->parse(file_content, type, subtype)))
{
- qDebug(tr("The file extensions %1 isn't supported.")
+ qDebug(tr("Internal error: unable to parse %1 file.")
.arg(subtype)
.toAscii()
);
return;
}
- // Internal data settings
- //data.append((CalculationData*)world_parsers[subtype]->parse(file_content, type, subtype).toInt());
- CalculationData *tempCD = new CalculationData();
- tempCD->setFromXmlString(&XMLString);
data.append(tempCD);
- *(CalculationData*)&calc = *data.last();
- // Creating elemental rules accroding to DATA_TYPE
- elemental_rules = new ElementalRules;
- // Pass the calculation result to rules selection
- connect(&calc, SIGNAL(calculated(QVector<int>, QVector<int>, int)),
- elemental_rules, SLOT(possibleRule(QVector<int>, QVector<int>, int))
- );
-
- // Notify things connected with rules to reset the list
- // as we hold only one iteration rules
- connect(&calc, SIGNAL(calculationBegin()),
- elemental_rules, SLOT(resetList())
- );
- connect(&calc, SIGNAL(calculationBegin()),
- ((ElementalRulesWidget*)elemental_dock->widget()), SLOT(resetList())
- );
-
- // Display the results (there is no need to refresh the table before
- // the end of one iteration)
- connect(&calc, SIGNAL(calculationEnd()),
- ((ElementalRulesWidget*)elemental_dock->widget()), SLOT(display())
- );
-
- // Notify the GUI 'bout new items
- connect(elemental_rules, SIGNAL(newRule(int, QVector<int>, int, QVector<int>)),
- ((ElementalRulesWidget*)elemental_dock->widget()), SLOT(addRule(int, QVector<int>, int, QVector<int>))
- );
- connect(elemental_rules, SIGNAL(newOccurance(int, QVector<int>)),
- ((ElementalRulesWidget*)elemental_dock->widget()), SLOT(addOccurance(int, QVector<int>))
- );
-
- // Pass rules selection from GUI to engine
- connect(((ElementalRulesWidget*)elemental_dock->widget()), SIGNAL(rulesSelected(QVector<int>)),
- elemental_rules, SLOT(rulesSelected(QVector<int>))
- );
-
- // We should only work when the rules list is visible, as it slows
- // the calculation considerably
- connect(elemental_dock->toggleViewAction(), SIGNAL(toggled(bool)),
- elemental_rules, SLOT(work(bool))
- );
-
- iteration=0;
-
- // visualization update
- update();
-
- // Enable saving menu for World
- menu_Save->setEnabled(true);
- action_World_save->setEnabled(true);
+ setupWorld();
}
else
{
@@ -1095,49 +1028,143 @@
doc.appendChild(root);
+ statusBar()->showMessage(tr("Successfully saved experiment for late continuation."));
return doc.toByteArray();
}
void MainWindow::deserialize(QByteArray content)
{
/// @todo Wait for fromXml in CalculationData and user pure XML
- QDataStream ds(&content, QIODevice::ReadOnly);
- qint32 data_size;
- QByteArray data_portion;
+ QDomDocument doc;
+ QDomElement* root;
+ int iterations;
- // Neighbourhood
- ds >> data_size;
- data_portion.resize(data_size);
- ds.readRawData(data_portion.data(), (uint)data_size);
+ if(!doc.setContent(content))
+ {
+ qDebug(tr("There were errors in parsing the file's content")
+ .toAscii()
+ );
+ return;
+ }
- if (neighbourhood == NULL)
+ if(!doc.hasChildNodes())
{
- neighbourhood = new Neighbourhood();
+ qDebug(tr("The document has no nodes!")
+ .toAscii()
+ );
+ return;
}
- if (!neighbourhood->fromXmlString(&QString(data_portion)))
+
+ if(!(doc.firstChild().nodeName() == "Experiment"))
{
- qDebug(tr("Error deserializing Neighbourhood").toAscii());
+ qDebug(tr("First node isn't `Experiment'.")
+ .toAscii()
+ );
return;
}
- // LocalFunction
- ds >> data_size;
- data_portion.resize(data_size);
- ds.readRawData(data_portion.data(), (uint)data_size);
+ if (!(doc.firstChild().isElement()))
+ {
+ qDebug(tr("Error parsing Experiment node.")
+ .toAscii()
+ );
+ return;
+ }
+ root = &doc.firstChild().toElement();
- if (local_function == NULL)
+ if(!root->hasAttribute("iterations"))
{
- local_function = new LocalFunction();
+ qDebug(tr("Iteration attribute in `Experiment' node.")
+ .toAscii()
+ );
+ return;
}
- if (!local_function->fromXmlString(&QString(data_portion)))
+ iterations = root->attribute("iterations").toInt();
+ iterations++;
+
+ // Neighbourhood parsing
+ if (!(root->firstChild().nodeName() == "Neighbourhood"))
{
- qDebug(tr("Error deserializing Local Function").toAscii());
+ qDebug(tr("First leaf should be `Neighbourhood'")
+ .toAscii()
+ );
return;
}
+ neighbourhood = new Neighbourhood();
- /// @todo deserialize CalculationData
+ if (!neighbourhood->fromDomElement(&root->firstChild().toElement()))
+ {
+ qDebug(tr("Error parsing Neighbourhood element")
+ .toAscii()
+ );
+ return;
+ }
+ root->removeChild(root->firstChild());
- statusBar()->showMessage(tr("Sucessfully loaded experiment for continuation.").toAscii());
+
+ // Local Function parsing
+ if(!(root->firstChild().nodeName() == "LocalFunction"))
+ {
+ qDebug(tr("Second leaf should be `Local Function'.")
+ .toAscii()
+ );
+ return;
+ }
+ local_function = new LocalFunction();
+
+ if (!local_function->fromDomElement(&root->firstChild().toElement()))
+ {
+ qDebug(tr("Error parsing Local Function element.")
+ .toAscii()
+ );
+ return;
+ }
+ root->removeChild(root->firstChild());
+
+ // Reset data
+ data.clear();
+
+ CalculationData* tmp_data;
+ // And finally CalculationData parsing
+ for (int i = 0; i < iterations; i++)
+ {
+ if (!(root->firstChild().nodeName() == "CalculationData"))
+ {
+ qDebug(tr("The %1 leaf should be `CalculatioData")
+ .arg(i+2)
+ .toAscii()
+ );
+ return;
+ }
+ tmp_data = new CalculationData();
+
+ if (!tmp_data->parseXmlElement(&root->firstChild().toElement()))
+ {
+ qDebug(tr("Error parsing the %1th CalculationData.")
+ .arg(i)
+ .toAscii()
+ );
+ return;
+ }
+
+ data.append(tmp_data);
+ root->removeChild(root->firstChild());
+ }
+
+ if (root->hasChildNodes())
+ {
+ qDebug(tr("Hm, there are some nodes left, but I've extracted all iterations. I'll gracefully ignore that.")
+ .toAscii()
+ );
+ }
+
+ statusBar()->showMessage(tr("Successfully loaded experiment for continuation.").toAscii());
+
+ setupNeighbourhood();
+ setupLocalFunction();
+ setupWorld();
+
+ unlockExperiment();
}
void MainWindow::sliderChanged(int value)
@@ -1187,3 +1214,91 @@
}
}
+void MainWindow::setupNeighbourhood()
+{
+ // Pass Neighbourhood to Calculator
+ calc.setNeighbourhood(neighbourhood);
+
+ // Enable saving menu for Neighbourhood
+ menu_Save->setEnabled(true);
+ action_Neighbourhood_save->setEnabled(true);
+
+ // Setup Neighbourhood editor
+ //***************************************************
+ // *sw->getNeighbourhoodEditor()->getStorage() = neighbourhood->toCalculationData();
+ sw->getNeighbourhoodEditor()->setTranslation(0.0f, 0.0f, -10.0f);
+ sw->getNeighbourhoodEditor()->setSymbolColor(1, QColor(128, 128, 128));
+ //***************************************************
+}
+
+void MainWindow::setupLocalFunction()
+{
+ // Pass Local Function to Calculator
+ calc.setLocalFunction(local_function);
+
+ // Enable saving menu for LocalFunction
+ menu_Save->setEnabled(true);
+ action_Function_save->setEnabled(true);
+
+ // for test only *********************************
+ sw->getFunctionTable()->setFunctionPointer(local_function);
+ //************************************************
+}
+
+void MainWindow::setupWorld()
+{
+ // Pass data to Calculator
+ *(CalculationData*)&calc = *data.last();
+
+ // Creating elemental rules according to DATA_TYPE
+ elemental_rules = new ElementalRules;
+
+ // Pass the calculation result to rules selection
+ connect(&calc, SIGNAL(calculated(QVector<int>, QVector<int>, int)),
+ elemental_rules, SLOT(possibleRule(QVector<int>, QVector<int>, int))
+ );
+
+ // Notify things connected with rules to reset the list
+ // as we hold only one iteration rules
+ connect(&calc, SIGNAL(calculationBegin()),
+ elemental_rules, SLOT(resetList())
+ );
+ connect(&calc, SIGNAL(calculationBegin()),
+ ((ElementalRulesWidget*)elemental_dock->widget()), SLOT(resetList())
+ );
+
+ // Display the results (there is no need to refresh the table before
+ // the end of one iteration)
+ connect(&calc, SIGNAL(calculationEnd()),
+ ((ElementalRulesWidget*)elemental_dock->widget()), SLOT(display())
+ );
+
+ // Notify the GUI 'bout new items
+ connect(elemental_rules, SIGNAL(newRule(int, QVector<int>, int, QVector<int>)),
+ ((ElementalRulesWidget*)elemental_dock->widget()), SLOT(addRule(int, QVector<int>, int, QVector<int>))
+ );
+ connect(elemental_rules, SIGNAL(newOccurance(int, QVector<int>)),
+ ((ElementalRulesWidget*)elemental_dock->widget()), SLOT(addOccurance(int, QVector<int>))
+ );
+
+ // Pass rules selection from GUI to engine
+ connect(((ElementalRulesWidget*)elemental_dock->widget()), SIGNAL(rulesSelected(QVector<int>)),
+ elemental_rules, SLOT(rulesSelected(QVector<int>))
+ );
+
+ // We should only work when the rules list is visible, as it slows
+ // the calculation considerably
+ connect(elemental_dock->toggleViewAction(), SIGNAL(toggled(bool)),
+ elemental_rules, SLOT(work(bool))
+ );
+
+ iteration=data.count()-1;
+
+ // visualization update
+ update();
+
+ // Enable saving menu for World
+ menu_Save->setEnabled(true);
+ action_World_save->setEnabled(true);
+}
+
Modified: trunk/qcell/visgui/MainWindow.h
===================================================================
--- trunk/qcell/visgui/MainWindow.h 2007-01-24 17:06:29 UTC (rev 251)
+++ trunk/qcell/visgui/MainWindow.h 2007-01-24 18:34:40 UTC (rev 252)
@@ -93,6 +93,9 @@
void callParser(QString filename, QString type);
void callSaver(const QString filename, const QString type);
void unlockExperiment();
+ void setupNeighbourhood();
+ void setupLocalFunction();
+ void setupWorld();
/// @todo Not in here!
enum Direction
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <dhu...@us...> - 2007-01-25 15:48:35
|
Revision: 256
http://svn.sourceforge.net/qcell/?rev=256&view=rev
Author: dhubleizh
Date: 2007-01-25 07:48:29 -0800 (Thu, 25 Jan 2007)
Log Message:
-----------
- minor typos
- updated translations
Modified Paths:
--------------
trunk/qcell/visgui/MainWindow.cpp
trunk/qcell/visgui/visgui_pl.qm
trunk/qcell/visgui/visgui_pl.ts
Modified: trunk/qcell/visgui/MainWindow.cpp
===================================================================
--- trunk/qcell/visgui/MainWindow.cpp 2007-01-25 08:56:53 UTC (rev 255)
+++ trunk/qcell/visgui/MainWindow.cpp 2007-01-25 15:48:29 UTC (rev 256)
@@ -1041,7 +1041,7 @@
if(!doc.setContent(content))
{
- qDebug(tr("There were errors in parsing the file's content")
+ qDebug(tr("There were errors in parsing the file's content.")
.toAscii()
);
return;
@@ -1074,7 +1074,7 @@
if(!root->hasAttribute("iterations"))
{
- qDebug(tr("Iteration attribute in `Experiment' node.")
+ qDebug(tr("Iteration attribute in `Experiment' node is missing.")
.toAscii()
);
return;
@@ -1085,7 +1085,7 @@
// Neighbourhood parsing
if (!(root->firstChild().nodeName() == "Neighbourhood"))
{
- qDebug(tr("First leaf should be `Neighbourhood'")
+ qDebug(tr("First leaf should be `Neighbourhood'.")
.toAscii()
);
return;
@@ -1094,7 +1094,7 @@
if (!neighbourhood->fromDomElement(&root->firstChild().toElement()))
{
- qDebug(tr("Error parsing Neighbourhood element")
+ qDebug(tr("Error parsing `Neighbourhood' element.")
.toAscii()
);
@@ -1115,7 +1115,7 @@
if (!local_function->fromDomElement(&root->firstChild().toElement()))
{
- qDebug(tr("Error parsing Local Function element.")
+ qDebug(tr("Error parsing `LocalFunction' element.")
.toAscii()
);
return;
@@ -1131,7 +1131,7 @@
{
if (!(root->firstChild().nodeName() == "CalculationData"))
{
- qDebug(tr("The %1 leaf should be `CalculatioData")
+ qDebug(tr("The %1th leaf should be `CalculatioData.")
.arg(i+2)
.toAscii()
);
@@ -1141,7 +1141,7 @@
if (!tmp_data->parseXmlElement(&root->firstChild().toElement()))
{
- qDebug(tr("Error parsing the %1th CalculationData.")
+ qDebug(tr("Error parsing the %1th `CalculationData' node.")
.arg(i)
.toAscii()
);
Modified: trunk/qcell/visgui/visgui_pl.qm
===================================================================
(Binary files differ)
Modified: trunk/qcell/visgui/visgui_pl.ts
===================================================================
--- trunk/qcell/visgui/visgui_pl.ts 2007-01-25 08:56:53 UTC (rev 255)
+++ trunk/qcell/visgui/visgui_pl.ts 2007-01-25 15:48:29 UTC (rev 256)
@@ -39,65 +39,80 @@
<context>
<name>BaseToolsClass</name>
<message>
- <location filename="../baseheaders/basetools.ui" line="13"/>
+ <location filename="../baseheaders/basetools.ui" line="16"/>
<source>BaseTools</source>
<translation>Podstawowe Narzędzia</translation>
</message>
<message>
- <location filename="../baseheaders/basetools.ui" line="25"/>
+ <location filename="../baseheaders/basetools.ui" line="160"/>
<source>Edit Tools</source>
<translation>Narzędzia Edycji</translation>
</message>
<message>
- <location filename="../baseheaders/basetools.ui" line="50"/>
+ <location filename="../baseheaders/basetools.ui" line="210"/>
<source>Fill</source>
<translation>Uzupełnij</translation>
</message>
<message>
- <location filename="../baseheaders/basetools.ui" line="37"/>
+ <location filename="../baseheaders/basetools.ui" line="195"/>
<source>Paste</source>
<translation>Wklej</translation>
</message>
<message>
- <location filename="../baseheaders/basetools.ui" line="63"/>
+ <location filename="../baseheaders/basetools.ui" line="180"/>
<source>Copy</source>
<translation>Kopiuj</translation>
</message>
<message>
- <location filename="../baseheaders/basetools.ui" line="173"/>
+ <location filename="../baseheaders/basetools.ui" line="234"/>
<source>Values</source>
<translation>Wartości</translation>
</message>
<message>
- <location filename="../baseheaders/basetools.ui" line="125"/>
+ <location filename="../baseheaders/basetools.ui" line="36"/>
<source>View Mode</source>
<translation>Typ Wyświetlania</translation>
</message>
<message>
- <location filename="../baseheaders/basetools.ui" line="137"/>
+ <location filename="../baseheaders/basetools.ui" line="77"/>
<source>Local</source>
<translation>Lokalny</translation>
</message>
<message>
- <location filename="../baseheaders/basetools.ui" line="153"/>
+ <location filename="../baseheaders/basetools.ui" line="56"/>
<source>Global</source>
<translation>Globalny</translation>
</message>
<message>
- <location filename="../baseheaders/basetools.ui" line="77"/>
+ <location filename="../baseheaders/basetools.ui" line="98"/>
<source>Edit Mode</source>
<translation>Tryb Edycji</translation>
</message>
<message>
- <location filename="../baseheaders/basetools.ui" line="89"/>
+ <location filename="../baseheaders/basetools.ui" line="139"/>
<source>Edit</source>
<translation>Edycja</translation>
</message>
<message>
- <location filename="../baseheaders/basetools.ui" line="105"/>
+ <location filename="../baseheaders/basetools.ui" line="118"/>
<source>Select</source>
<translation>Zaznacz</translation>
</message>
+ <message>
+ <location filename="../baseheaders/basetools.ui" line="261"/>
+ <source>1</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../baseheaders/basetools.ui" line="266"/>
+ <source>2</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../baseheaders/basetools.ui" line="271"/>
+ <source>Value</source>
+ <translation>Wartość</translation>
+ </message>
</context>
<context>
<name>CalculationData</name>
@@ -259,17 +274,17 @@
<translation>P&omoc</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="65"/>
+ <location filename="MainWindow.ui" line="68"/>
<source>&File</source>
<translation>&Plik</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="80"/>
+ <location filename="MainWindow.ui" line="83"/>
<source>Opens experiment data.</source>
<translation>Otwiera dane eksperymentu.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="83"/>
+ <location filename="MainWindow.ui" line="86"/>
<source>&Open</source>
<translation>&Otwórz</translation>
</message>
@@ -279,78 +294,78 @@
<translation type="obsolete">To menu pozwala przeszukiwać tematy pomocy i poczytać o aplikacji.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="128"/>
+ <location filename="MainWindow.ui" line="131"/>
<source>&Quit</source>
<translation>&Wyjście</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="131"/>
+ <location filename="MainWindow.ui" line="134"/>
<source>This menu item quits the application.</source>
<comment>Quits the application</comment>
<translation>Ten przycisk menu powoduje wyjście z aplikacji.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="134"/>
+ <location filename="MainWindow.ui" line="137"/>
<source>Quits the application.</source>
<translation>Wychodzi z aplikacji.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="314"/>
+ <location filename="MainWindow.ui" line="317"/>
<source>&Neighbourhood</source>
<translation>&Sąsiedztwo</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="142"/>
+ <location filename="MainWindow.ui" line="145"/>
<source>Opens neighbourhood.</source>
<translation>Otwiera plik sąsiedztwa.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="319"/>
+ <location filename="MainWindow.ui" line="322"/>
<source>&Function</source>
<translation>&Funkcja</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="150"/>
+ <location filename="MainWindow.ui" line="153"/>
<source>Opens function.</source>
<translation>Otwiera plik funkcji.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="309"/>
+ <location filename="MainWindow.ui" line="312"/>
<source>&World</source>
<translation>Ś&wiat</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="158"/>
+ <location filename="MainWindow.ui" line="161"/>
<source>Opens world configuration.</source>
<translation>Otwiera konfigurację świata.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="166"/>
+ <location filename="MainWindow.ui" line="169"/>
<source>Open &experiment</source>
<translation>Otwórz &eksperyment</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="169"/>
+ <location filename="MainWindow.ui" line="172"/>
<source>Opens a predefined experiment.</source>
<translation>Otwiera zdefiniowany wcześniej eksperyment.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="183"/>
+ <location filename="MainWindow.ui" line="186"/>
<source>Loads an earlier saved experiment.</source>
<translation>Ładuje wcześniej zachowany eksperyment.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="188"/>
+ <location filename="MainWindow.ui" line="191"/>
<source>&About</source>
<translation>&O programie</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="191"/>
+ <location filename="MainWindow.ui" line="194"/>
<source>Shows info about the program.</source>
<translation>Pokazuje informacje o programie.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="155"/>
+ <location filename="MainWindow.cpp" line="280"/>
<source>Open Neighbourhood</source>
<translation>Otwórz Sąsiedztwo</translation>
</message>
@@ -360,52 +375,52 @@
<translation type="obsolete"> pliki</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="795"/>
+ <location filename="MainWindow.cpp" line="869"/>
<source>files</source>
<translation>pliki</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="771"/>
+ <location filename="MainWindow.cpp" line="845"/>
<source>Plugins warning</source>
<translation>Ostrzeżenie wtyczek</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="147"/>
+ <location filename="MainWindow.cpp" line="272"/>
<source>There are no plugins loaded to handle Neighbourhood parsing.</source>
<translation>Nie ma załadowanej żadnej wtyczki do obsługi parsowania plików Sąsiedztwa.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="195"/>
+ <location filename="MainWindow.cpp" line="320"/>
<source>There are no plugins loaded to handle Function parsing.</source>
<translation>Nie ma załadowanej żadnej wtyczki do obsługi parsowania Funkcji.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="203"/>
+ <location filename="MainWindow.cpp" line="328"/>
<source>Open Function</source>
<translation>Otwórz Funkcję</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="244"/>
+ <location filename="MainWindow.cpp" line="369"/>
<source>There are no plugins loaded to handle World parsing.</source>
<translation>Nie ma załadowanej żadnej wtyczki do parsowania Świata.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="252"/>
+ <location filename="MainWindow.cpp" line="377"/>
<source>Open World</source>
<translation>Otwórz Świat</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="899"/>
+ <location filename="MainWindow.cpp" line="973"/>
<source>Error opening file %1.</source>
<translation>Błąd podczas otwierania pliku %1.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="502"/>
+ <location filename="MainWindow.cpp" line="565"/>
<source>The file extensions %1 isn't supported.</source>
<translation>Rozszerzenie pliku %1 nie jest wspierane.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="513"/>
+ <location filename="MainWindow.cpp" line="576"/>
<source>Unsupported file type to parse.</source>
<translation>Niewspierany typ pliku do przeczytania.</translation>
</message>
@@ -420,37 +435,37 @@
<translation>&Eksperyment</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="199"/>
+ <location filename="MainWindow.ui" line="202"/>
<source>&Start</source>
<translation>&Start</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="205"/>
+ <location filename="MainWindow.ui" line="208"/>
<source>Starts the experiment.</source>
<translation>Startuje eksperyment.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="213"/>
+ <location filename="MainWindow.ui" line="216"/>
<source>S&top</source>
<translation>S&top</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="219"/>
+ <location filename="MainWindow.ui" line="222"/>
<source>Stops the experiment.</source>
<translation>Zatrzymuje eksperyment.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="227"/>
+ <location filename="MainWindow.ui" line="230"/>
<source>&Restart</source>
<translation>Ponowne u&ruchominie</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="233"/>
+ <location filename="MainWindow.ui" line="236"/>
<source>Restarts the experiment.</source>
<translation>Uruchamia eksperyment od nowa.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="241"/>
+ <location filename="MainWindow.ui" line="244"/>
<source>&Forward</source>
<translation>Do &przodu</translation>
</message>
@@ -460,52 +475,52 @@
<translation type="obsolete">Iteruje jeden krok.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="247"/>
+ <location filename="MainWindow.ui" line="250"/>
<source>Iterates one setp forward.</source>
<translation>Iteruje jeden krok do przodu.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="255"/>
+ <location filename="MainWindow.ui" line="258"/>
<source>&Back</source>
<translation>Do &tyłu</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="261"/>
+ <location filename="MainWindow.ui" line="264"/>
<source>Iterates one setp back.</source>
<translation>Iteruje jeden krok wstecz.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="54"/>
+ <location filename="MainWindow.cpp" line="169"/>
<source>Iteration</source>
<translation>Iteracja</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="596"/>
+ <location filename="MainWindow.cpp" line="670"/>
<source>You cannot step back beyond the beginning of the experiment!</source>
<translation>Nie możesz cofnąc się poza początek eksperymentu!</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="463"/>
+ <location filename="MainWindow.cpp" line="526"/>
<source>Error opnening file %1.</source>
<translation>Błąd podczas próby otwarcia pliku %1.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="725"/>
+ <location filename="MainWindow.cpp" line="799"/>
<source>There are no plugins loaded to handle World saving.</source>
<translation>Nie ma załadowanej żadnej wtyczki do obsługi zapisywania plików świata.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="733"/>
+ <location filename="MainWindow.cpp" line="807"/>
<source>Save World</source>
<translation>Zapisz Świat</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="773"/>
+ <location filename="MainWindow.cpp" line="847"/>
<source>There are no plugins loaded to handle Neighbourhood saving.</source>
<translation>Nie ma załadowanych żadnych wtyczek do obsługi zapisywania Sąsiedztwa.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="781"/>
+ <location filename="MainWindow.cpp" line="855"/>
<source>Save Neighbourhood</source>
<translation>Zapisz Sąsiedztwo</translation>
</message>
@@ -515,120 +530,265 @@
<translation type="obsolete">&Zapisz eksperyment</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="346"/>
+ <location filename="MainWindow.cpp" line="443"/>
<source>Internal error: unable to parse %1 file</source>
<translation>Wewnętrzny błąd: nie mogę zrozumiec pliku %1</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="539"/>
+ <location filename="MainWindow.cpp" line="613"/>
<source>%1 file loaded sucesfully!</source>
<translation>Plik %1 załadowany poprawnie!</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="53"/>
+ <location filename="MainWindow.cpp" line="167"/>
<source>Shows the current iteration number.</source>
<translation>Pokazuje aktualny numer iteracji.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="30"/>
+ <location filename="MainWindow.cpp" line="168"/>
<source>Delay</source>
<translation>Opóźnienie</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="822"/>
+ <location filename="MainWindow.cpp" line="896"/>
<source>Save Experiment</source>
<translation>Zachowaj Eksperyment</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="882"/>
+ <location filename="MainWindow.cpp" line="956"/>
<source>Experiment files (*.%1)</source>
<translation>Pliki Eksperymentów (*.%1)</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="859"/>
+ <location filename="MainWindow.cpp" line="933"/>
<source>Internal error: unable to serialize experiment</source>
<translation>Wewnętrzny błąd: serializacja eksperymentu niemożliwa</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="873"/>
+ <location filename="MainWindow.cpp" line="947"/>
<source>Open Experiment</source>
<translation>Otwórz Eksperyment</translation>
</message>
<message>
<location filename="MainWindow.cpp" line="951"/>
<source>Error deserializing Neighbourhood</source>
- <translation>Błąd podczas deserializacji Sąsiedztwa</translation>
+ <translation type="obsolete">Błąd podczas deserializacji Sąsiedztwa</translation>
</message>
<message>
<location filename="MainWindow.cpp" line="966"/>
<source>Error deserializing Local Function</source>
- <translation>Error podczas deserializacji Funkcji Lokalnej</translation>
+ <translation type="obsolete">Error podczas deserializacji Funkcji Lokalnej</translation>
</message>
<message>
<location filename="MainWindow.cpp" line="972"/>
<source>Sucessfully loaded experiment for continuation.</source>
- <translation>Załadowano eksperyment do kontynuowania.</translation>
+ <translation type="obsolete">Załadowano eksperyment do kontynuowania.</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="72"/>
+ <location filename="MainWindow.ui" line="75"/>
<source>&Save</source>
<translation>&Zachowaj</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="174"/>
+ <location filename="MainWindow.ui" line="177"/>
<source>&Continue experiment</source>
<translation>&Wznów eksperyment</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="180"/>
+ <location filename="MainWindow.ui" line="183"/>
<source>Continue experiment</source>
<translation>Wznów eksperyment</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="293"/>
+ <location filename="MainWindow.ui" line="296"/>
<source>Sa&ve experiment</source>
<translation>Zac&howaj eksperyment</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="296"/>
+ <location filename="MainWindow.ui" line="299"/>
<source>Saves the whole experiment with history for later continuation.</source>
<translation>Zachowuje cały eksperyment z historią dla þóźniejszego wznowienia.</translation>
</message>
<message>
<location filename="MainWindow.cpp" line="23"/>
<source>Sets the delay between iteration steps in ms.</source>
- <translation>Ustawia opóźnienie między krokami iteracji w ms.</translation>
+ <translation type="obsolete">Ustawia opóźnienie między krokami iteracji w ms.</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="70"/>
+ <location filename="MainWindow.cpp" line="194"/>
<source>Elemental rules</source>
<translation>Reguły elementarne</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="162"/>
+ <location filename="MainWindow.cpp" line="287"/>
<source>Supported neighbourhoods</source>
<translation>Wspierani sąsiedzi</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="210"/>
+ <location filename="MainWindow.cpp" line="335"/>
<source>Supported functions</source>
<translation>Wspierane funkcje</translation>
</message>
<message>
- <location filename="MainWindow.cpp" line="259"/>
+ <location filename="MainWindow.cpp" line="384"/>
<source>Supported worlds</source>
<translation>Wspierane światy</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="91"/>
+ <location filename="MainWindow.ui" line="94"/>
<source>&New</source>
<translation>&Nowy</translation>
</message>
<message>
- <location filename="MainWindow.ui" line="304"/>
+ <location filename="MainWindow.ui" line="307"/>
<source>&Elemental rules</source>
<translation>&Reguły elementarne</translation>
</message>
+ <message>
+ <location filename="MainWindow.cpp" line="26"/>
+ <source>Base tools</source>
+ <translation>Podstawowe narzędzia</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.cpp" line="58"/>
+ <source>3D Tools</source>
+ <translation>Narzędzia 3D</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.cpp" line="66"/>
+ <source>&3D Tools</source>
+ <translation>Narzędzia &3D</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.cpp" line="85"/>
+ <source>2D Text Tools</source>
+ <translation>Narzędzia 2D</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.cpp" line="93"/>
+ <source>&2D Text Tools</source>
+ <translation>Narzędzia &2D</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.cpp" line="118"/>
+ <source>1D Text Tools</source>
+ <translation>Narzędzia 1D</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.cpp" line="126"/>
+ <source>&1D Text Tools</source>
+ <translation>Narzędzia &1D</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.cpp" line="176"/>
+ <source>World</source>
+ <translation>Świat</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.cpp" line="178"/>
+ <source>Neighbourhood</source>
+ <translation>Sąsiedztwo</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.cpp" line="179"/>
+ <source>Local Function</source>
+ <translation>Funkcja Lokalna</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.cpp" line="497"/>
+ <source>Internal error: unable to parse %1 file.</source>
+ <translation>Błąd wewnętrzny: nie można odczytać pliku %1.</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.cpp" line="999"/>
+ <source>Internal error: unable to serialize Neighbourhood.</source>
+ <translation>Błąd wewnętrzny: nie udało się serializować Sąsiedztwa.</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.cpp" line="1008"/>
+ <source>Internal error: unable to serialize Local Function.</source>
+ <translation>Błąd wewnętrzny: nie można serializować Funkcji Lokalnej.</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.cpp" line="1020"/>
+ <source>Internal error: unable to serialize Calculation Data in the %1th iteration.</source>
+ <translation>Błąd wenętrzny: nie można serializować Świata w iteracji %1.</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.cpp" line="1031"/>
+ <source>Successfully saved experiment for late continuation.</source>
+ <translation>Zapisano eksperyment dla późniejszego wznowienia.</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.cpp" line="1045"/>
+ <source>There were errors in parsing the file's content</source>
+ <translation>Wystąpiły błedy przy czytaniu zawartości pliku</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.cpp" line="1053"/>
+ <source>The document has no nodes!</source>
+ <translation>Dokument nie zawiera węzłów!</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.cpp" line="1061"/>
+ <source>First node isn't `Experiment'.</source>
+ <translation>Pierwszy węzeł nie nazywa się `Experiment'.</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.cpp" line="1069"/>
+ <source>Error parsing Experiment node.</source>
+ <translation>Błąd podczas przetwarzania węzła Experiment.</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.cpp" line="1078"/>
+ <source>Iteration attribute in `Experiment' node.</source>
+ <translation>Brak atrybutu `iteration' w węźle `Experiment'.</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.cpp" line="1089"/>
+ <source>First leaf should be `Neighbourhood'</source>
+ <translation>Pierwszy liść powinien nazywać się `Neighbourhood'</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.cpp" line="1098"/>
+ <source>Error parsing Neighbourhood element</source>
+ <translation>Błąd podczas przetwarzania elementu `Neighbourhood'</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.cpp" line="1109"/>
+ <source>Second leaf should be `Local Function'.</source>
+ <translation>Drugi liśc powinien nazywać się `Local Function'.</translation>
+ </message>
+ <message>
+ <location filename="MainWindow.cpp" line="1118"/>
+ <source>Error parsing Local Function element.</source>
+ <translation>Błąd podczas przetwarzania elementu `Local Function'.</translation>
+ </message>
+ <message>
+ <location filename="Main...
[truncated message content] |
|
From: <dhu...@us...> - 2007-02-12 10:12:50
|
Revision: 309
http://svn.sourceforge.net/qcell/?rev=309&view=rev
Author: dhubleizh
Date: 2007-02-12 02:12:48 -0800 (Mon, 12 Feb 2007)
Log Message:
-----------
- not using not finished function parsers
- export works only with whole experiment loaded
Modified Paths:
--------------
trunk/qcell/visgui/MainWindow.cpp
trunk/qcell/visgui/MainWindow.ui
trunk/qcell/visgui/main.cpp
trunk/qcell/visgui/visgui.pro
Modified: trunk/qcell/visgui/MainWindow.cpp
===================================================================
--- trunk/qcell/visgui/MainWindow.cpp 2007-02-12 10:07:30 UTC (rev 308)
+++ trunk/qcell/visgui/MainWindow.cpp 2007-02-12 10:12:48 UTC (rev 309)
@@ -733,6 +733,7 @@
// Whole experiment saving
action_Save_experiment->setEnabled(true);
+ action_Export->setEnabled(true);
// Menus
menu_View->setEnabled(true);
Modified: trunk/qcell/visgui/MainWindow.ui
===================================================================
--- trunk/qcell/visgui/MainWindow.ui 2007-02-12 10:07:30 UTC (rev 308)
+++ trunk/qcell/visgui/MainWindow.ui 2007-02-12 10:12:48 UTC (rev 309)
@@ -351,6 +351,9 @@
</property>
</action>
<action name="action_Export" >
+ <property name="enabled" >
+ <bool>false</bool>
+ </property>
<property name="text" >
<string>&Export</string>
</property>
Modified: trunk/qcell/visgui/main.cpp
===================================================================
--- trunk/qcell/visgui/main.cpp 2007-02-12 10:07:30 UTC (rev 308)
+++ trunk/qcell/visgui/main.cpp 2007-02-12 10:12:48 UTC (rev 309)
@@ -12,9 +12,9 @@
Q_IMPORT_PLUGIN(NFileParser);
Q_IMPORT_PLUGIN(FQTFileParser);
Q_IMPORT_PLUGIN(KIFileParser);
-Q_IMPORT_PLUGIN(REAKFileParser);
-Q_IMPORT_PLUGIN(LTFLFileParser);
-Q_IMPORT_PLUGIN(ZIFWFileParser);
+//Q_IMPORT_PLUGIN(REAKFileParser);
+//Q_IMPORT_PLUGIN(LTFLFileParser);
+//Q_IMPORT_PLUGIN(ZIFWFileParser);
//Q_IMPORT_PLUGIN(ZIFWPFileParser);
Q_IMPORT_PLUGIN(Life105FileParser);
Modified: trunk/qcell/visgui/visgui.pro
===================================================================
--- trunk/qcell/visgui/visgui.pro 2007-02-12 10:07:30 UTC (rev 308)
+++ trunk/qcell/visgui/visgui.pro 2007-02-12 10:12:48 UTC (rev 309)
@@ -67,7 +67,7 @@
../basesources/functiontable.cpp \
../basesources/neigborhoodtools.cpp
-LIBS = -L../libs -lN -lFQT -lKI -lREAK -lLTFL -lZIFW -lZIFWP -lLife105
+LIBS = -L../libs -lN -lFQT -lKI -lLife105
TRANSLATIONS = visgui_pl.ts
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <dhu...@us...> - 2007-02-16 23:48:09
|
Revision: 342
http://svn.sourceforge.net/qcell/?rev=342&view=rev
Author: dhubleizh
Date: 2007-02-16 15:48:05 -0800 (Fri, 16 Feb 2007)
Log Message:
-----------
- back disabled in OL mode
Modified Paths:
--------------
trunk/qcell/visgui/MainWindow.cpp
trunk/qcell/visgui/MainWindow.h
Modified: trunk/qcell/visgui/MainWindow.cpp
===================================================================
--- trunk/qcell/visgui/MainWindow.cpp 2007-02-16 23:32:16 UTC (rev 341)
+++ trunk/qcell/visgui/MainWindow.cpp 2007-02-16 23:48:05 UTC (rev 342)
@@ -37,6 +37,9 @@
connect(basetools, SIGNAL(toolsModeUpdate(int)),
sw, SLOT(workModeChange(int))
);
+ connect(basetools, SIGNAL(toolsModeUpdate(int)),
+ this, SLOT(localObserver(int))
+ );
connect(basetools, SIGNAL(symbolSelected(int)),
sw, SLOT(selectSymbol(int))
);
@@ -1749,3 +1752,15 @@
);
}
+void MainWindow::localObserver(int mode)
+{
+ if (mode == 3)
+ {
+ action_Back->setDisabled(1);
+ }
+ else
+ {
+ action_Back->setEnabled(1);
+ }
+}
+
Modified: trunk/qcell/visgui/MainWindow.h
===================================================================
--- trunk/qcell/visgui/MainWindow.h 2007-02-16 23:32:16 UTC (rev 341)
+++ trunk/qcell/visgui/MainWindow.h 2007-02-16 23:48:05 UTC (rev 342)
@@ -85,6 +85,7 @@
void on_action_Restart_activated();
void loadingSuccess(QString filetype);
+ void localObserver(int mode);
private:
simulationWindow* sw;
QLCDNumber* iterationLCD;
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <dhu...@us...> - 2006-12-21 08:09:00
|
Revision: 75
http://svn.sourceforge.net/qcell/?rev=75&view=rev
Author: dhubleizh
Date: 2006-12-21 00:08:59 -0800 (Thu, 21 Dec 2006)
Log Message:
-----------
- KI and FQT plugin aware
- loads static plugins and utilizes them
- typos
Modified Paths:
--------------
trunk/qcell/visgui/MainWindow.cpp
trunk/qcell/visgui/main.cpp
trunk/qcell/visgui/visgui.pro
Modified: trunk/qcell/visgui/MainWindow.cpp
===================================================================
--- trunk/qcell/visgui/MainWindow.cpp 2006-12-21 07:59:49 UTC (rev 74)
+++ trunk/qcell/visgui/MainWindow.cpp 2006-12-21 08:08:59 UTC (rev 75)
@@ -18,6 +18,8 @@
ParserInterface* iParser;
QStringList parser_types, file_types;
+ QMessageBox::information(this, "Plugins",
+ QString("Number of plugins: %1").arg(QPluginLoader::staticInstances().count()));
// We check each static plugin if it is a parser plugin
// and if it is we register each parsing fucntion
// according to supported types and file extensions
@@ -57,10 +59,11 @@
world_parsers[extension] = iParser;
}
}
-}
+ }
}
}
+
}
void MainWindow::on_action_About_activated()
Modified: trunk/qcell/visgui/main.cpp
===================================================================
--- trunk/qcell/visgui/main.cpp 2006-12-21 07:59:49 UTC (rev 74)
+++ trunk/qcell/visgui/main.cpp 2006-12-21 08:08:59 UTC (rev 75)
@@ -8,8 +8,8 @@
using namespace std;
Q_IMPORT_PLUGIN(NFileParser);
-//Q_IMPORT_PLUGIN(FQTFileParser);
-//Q_IMPORT_PLUGIN(KIFileParser);
+Q_IMPORT_PLUGIN(FQTFileParser);
+Q_IMPORT_PLUGIN(KIFileParser);
int main(int argc, char* argv[])
{
Modified: trunk/qcell/visgui/visgui.pro
===================================================================
--- trunk/qcell/visgui/visgui.pro 2006-12-21 07:59:49 UTC (rev 74)
+++ trunk/qcell/visgui/visgui.pro 2006-12-21 08:08:59 UTC (rev 75)
@@ -10,17 +10,23 @@
HEADERS = MainWindow.h \
../baseheaders/Client.h \
../baseheaders/ClientInfo.h \
+ ../baseheaders/BaseDataTypes.h \
../baseheaders/interfaces.h \
../baseheaders/GenericParserPlugin.h \
- ../baseheaders/Neighbourhood.h
+ ../baseheaders/Neighbourhood.h \
+ ../baseheaders/CalculationData.h \
+ ../baseheaders/LocalFunction.h
+
SOURCES = ../basesources/GenericParserPlugin.cpp \
main.cpp \
MainWindow.cpp \
../basesources/Client.cpp \
../basesources/ClientInfo.cpp \
- ../basesources/Neighbourhood.cpp
+ ../basesources/Neighbourhood.cpp \
+ ../basesources/CalculationData.cpp \
+ ../basesources/LocalFunction.cpp
-LIBS = -L../libs -lN
+LIBS = -L../libs -lN -lFQT -lKI
TRANSLATIONS = visgui_pl.ts
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <dhu...@us...> - 2007-01-10 19:57:16
|
Revision: 141
http://svn.sourceforge.net/qcell/?rev=141&view=rev
Author: dhubleizh
Date: 2007-01-10 11:57:11 -0800 (Wed, 10 Jan 2007)
Log Message:
-----------
- seperate ExperimetSetup class to handle delay settings
- dalay tweaking from inside of MainWindow
Modified Paths:
--------------
trunk/qcell/visgui/ExperimentSetup.ui
trunk/qcell/visgui/MainWindow.cpp
trunk/qcell/visgui/MainWindow.h
trunk/qcell/visgui/visgui.pro
Added Paths:
-----------
trunk/qcell/visgui/ExperimentSetup.cpp
trunk/qcell/visgui/ExperimentSetup.h
Added: trunk/qcell/visgui/ExperimentSetup.cpp
===================================================================
--- trunk/qcell/visgui/ExperimentSetup.cpp (rev 0)
+++ trunk/qcell/visgui/ExperimentSetup.cpp 2007-01-10 19:57:11 UTC (rev 141)
@@ -0,0 +1,44 @@
+/**@file ExperimentSetup.cpp
+ * @author czarny
+ * @date
+ * Created: ?ro 10 sty 2007 19:17:46 CET \n
+ * Last Update: ?ro 10 sty 2007 19:17:46 CET
+ */
+
+#include "ExperimentSetup.h"
+
+ExperimentSetup::ExperimentSetup()
+{
+ setupUi(this);
+ connect(delaySlider, SIGNAL(valueChanged(int)),
+ SLOT(sliderChanged(int))
+ );
+ connect(delaySpinBox, SIGNAL(valueChanged(double)),
+ this, SLOT(spinBoxChanged(double)));
+}
+
+void ExperimentSetup::sliderChanged(int value)
+{
+ // Anti slider->spinBox value change lock
+ delaySpinBox->blockSignals(true);
+ // Set the spinBox to value from slider proportional to the spinBox range
+ delaySpinBox->setValue(
+ ((delaySpinBox->maximum() - delaySpinBox->minimum()) / 100)
+ * value
+ );
+ // release lock
+ delaySpinBox->blockSignals(false);
+}
+
+void ExperimentSetup::spinBoxChanged(double value)
+{
+ // Anti spinBox->slider value change lock
+ delaySlider->blockSignals(true);
+ // Set the slider proportional to spinBox range
+ delaySlider->setValue(
+ (value / (delaySpinBox->maximum() - delaySpinBox->minimum()))
+ * 100);
+ // release lock
+ delaySlider->blockSignals(false);
+}
+
Added: trunk/qcell/visgui/ExperimentSetup.h
===================================================================
--- trunk/qcell/visgui/ExperimentSetup.h (rev 0)
+++ trunk/qcell/visgui/ExperimentSetup.h 2007-01-10 19:57:11 UTC (rev 141)
@@ -0,0 +1,25 @@
+/**@file ExperimentDialog.h
+ * @author czarny
+ * @date
+ * Created: ?ro 10 sty 2007 19:13:42 CET \n
+ * Last Update: ?ro 10 sty 2007 19:13:42 CET
+ * @brief Events for ExperimentSettings
+ */
+
+#ifndef __EXPERIMENTSETUP_H__
+#define __EXPERIMENTSETUP_H__
+
+#include "ui_ExperimentSetup.h"
+
+class ExperimentSetup: public QDialog, public Ui::ExperimentSetupDialog
+{
+ Q_OBJECT
+public slots:
+ void sliderChanged(int value);
+ void spinBoxChanged(double value);
+public:
+ ExperimentSetup();
+
+};
+
+#endif // __EXPERIMENTSETUP_H__
Modified: trunk/qcell/visgui/ExperimentSetup.ui
===================================================================
--- trunk/qcell/visgui/ExperimentSetup.ui 2007-01-10 19:50:10 UTC (rev 140)
+++ trunk/qcell/visgui/ExperimentSetup.ui 2007-01-10 19:57:11 UTC (rev 141)
@@ -6,7 +6,7 @@
<x>0</x>
<y>0</y>
<width>400</width>
- <height>133</height>
+ <height>231</height>
</rect>
</property>
<property name="windowTitle" >
@@ -20,47 +20,97 @@
<number>6</number>
</property>
<item>
- <layout class="QHBoxLayout" >
- <property name="margin" >
- <number>0</number>
+ <widget class="QGroupBox" name="iterationsBox" >
+ <property name="title" >
+ <string>Iterations</string>
</property>
- <property name="spacing" >
- <number>6</number>
+ <layout class="QHBoxLayout" >
+ <property name="margin" >
+ <number>9</number>
+ </property>
+ <property name="spacing" >
+ <number>6</number>
+ </property>
+ <item>
+ <widget class="QLabel" name="iterationsNumberLabel" >
+ <property name="text" >
+ <string>Number of iterations</string>
+ </property>
+ <property name="buddy" >
+ <cstring>iterationsSpinBox</cstring>
+ </property>
+ </widget>
+ </item>
+ <item>
+ <widget class="QSpinBox" name="iterationsSpinBox" >
+ <property name="alignment" >
+ <set>Qt::AlignRight</set>
+ </property>
+ <property name="maximum" >
+ <number>10000</number>
+ </property>
+ <property name="minimum" >
+ <number>2</number>
+ </property>
+ <property name="value" >
+ <number>10</number>
+ </property>
+ </widget>
+ </item>
+ <item>
+ <widget class="QCheckBox" name="continiuosCheckBox" >
+ <property name="text" >
+ <string>Continuos Experiment</string>
+ </property>
+ </widget>
+ </item>
+ </layout>
+ </widget>
+ </item>
+ <item>
+ <widget class="QGroupBox" name="speedBox" >
+ <property name="title" >
+ <string>Delay between iterations</string>
</property>
- <item>
- <widget class="QLabel" name="iterationsNumberLabel" >
- <property name="text" >
- <string>Number of iterations</string>
- </property>
- <property name="buddy" >
- <cstring>iterationsSpinBox</cstring>
- </property>
- </widget>
- </item>
- <item>
- <widget class="QSpinBox" name="iterationsSpinBox" >
- <property name="alignment" >
- <set>Qt::AlignRight</set>
- </property>
- <property name="maximum" >
- <number>10000</number>
- </property>
- <property name="minimum" >
- <number>2</number>
- </property>
- <property name="value" >
- <number>10</number>
- </property>
- </widget>
- </item>
- <item>
- <widget class="QCheckBox" name="continiuosCheckBox" >
- <property name="text" >
- <string>Continuos Experiment</string>
- </property>
- </widget>
- </item>
- </layout>
+ <layout class="QHBoxLayout" >
+ <property name="margin" >
+ <number>9</number>
+ </property>
+ <property name="spacing" >
+ <number>6</number>
+ </property>
+ <item>
+ <widget class="QSlider" name="delaySlider" >
+ <property name="maximum" >
+ <number>100</number>
+ </property>
+ <property name="singleStep" >
+ <number>0</number>
+ </property>
+ <property name="orientation" >
+ <enum>Qt::Horizontal</enum>
+ </property>
+ </widget>
+ </item>
+ <item>
+ <widget class="QDoubleSpinBox" name="delaySpinBox" >
+ <property name="maximum" >
+ <double>5.000000000000000</double>
+ </property>
+ <property name="singleStep" >
+ <double>0.100000000000000</double>
+ </property>
+ </widget>
+ </item>
+ <item>
+ <widget class="QLabel" name="msLabel" >
+ <property name="text" >
+ <string>s</string>
+ </property>
+ </widget>
+ </item>
+ </layout>
+ </widget>
</item>
<item>
<spacer>
@@ -96,8 +146,8 @@
<slot>accept()</slot>
<hints>
<hint type="sourcelabel" >
- <x>227</x>
- <y>110</y>
+ <x>236</x>
+ <y>221</y>
</hint>
<hint type="destinationlabel" >
<x>157</x>
@@ -112,8 +162,8 @@
<slot>reject()</slot>
<hints>
<hint type="sourcelabel" >
- <x>295</x>
- <y>116</y>
+ <x>304</x>
+ <y>221</y>
</hint>
<hint type="destinationlabel" >
<x>286</x>
@@ -128,12 +178,12 @@
<slot>setDisabled(bool)</slot>
<hints>
<hint type="sourcelabel" >
- <x>262</x>
- <y>24</y>
+ <x>243</x>
+ <y>52</y>
</hint>
<hint type="destinationlabel" >
- <x>215</x>
- <y>25</y>
+ <x>216</x>
+ <y>50</y>
</hint>
</hints>
</connection>
Modified: trunk/qcell/visgui/MainWindow.cpp
===================================================================
--- trunk/qcell/visgui/MainWindow.cpp 2007-01-10 19:50:10 UTC (rev 140)
+++ trunk/qcell/visgui/MainWindow.cpp 2007-01-10 19:57:11 UTC (rev 141)
@@ -17,12 +17,35 @@
sw = new simulationWindow(this);
centralWidget()->layout()->addWidget(sw);
+ // Adding delay setup
+ // An interlinked pair of QDoubleSpinBox and a QSlider
+ delaySlider = new QSlider(Qt::Horizontal);
+ delaySlider->setStatusTip(tr("Sets the dleay between iteration steps in ms."));
+ delaySlider->setFixedWidth(100);
+ delaySpinBox = new QDoubleSpinBox();
+ delaySpinBox->setStatusTip(delaySlider->statusTip());
+ delaySpinBox->setMinimum(MIN_DELAY);
+ delaySpinBox->setMaximum(MAX_DELAY);
+ delaySpinBox->setSingleStep(DELAY_STEP);
+ QLabel* tmp_label = new QLabel(tr("Delay"));
+ tmp_label->setStatusTip(delaySlider->statusTip());
+ statusBar()->addPermanentWidget(tmp_label);
+ statusBar()->addPermanentWidget(delaySlider);
+ statusBar()->addPermanentWidget(delaySpinBox);
+ statusBar()->addPermanentWidget(new QLabel("ms"));
+ // Interconnect both widgets - change in one will change the other as well
+ connect(delaySlider, SIGNAL(valueChanged(int)),
+ SLOT(sliderChanged(int))
+ );
+ connect(delaySpinBox, SIGNAL(valueChanged(double)),
+ this, SLOT(spinBoxChanged(double)));
+
// Adding iteration counter
// Creating LCD counter
iterationLCD = new QLCDNumber();
iterationLCD->setSegmentStyle(QLCDNumber::Flat);
iterationLCD->setStatusTip(tr("Shows the current iteration number."));
- QLabel* tmp_label = new QLabel(tr("Iteration"));
+ tmp_label = new QLabel(tr("Iteration"));
tmp_label->setBuddy(iterationLCD);
tmp_label->setStatusTip(iterationLCD->statusTip());
statusBar()->addPermanentWidget(tmp_label);
@@ -535,13 +558,12 @@
void MainWindow::on_action_Start_activated()
{
- QDialog* dialog = new QDialog(this);
- Ui::ExperimentSetupDialog es;
- es.setupUi(dialog);
+ ExperimentSetup es;
- if(dialog->exec() == QDialog::Accepted)
+ if(es.exec() == QDialog::Accepted)
{
working = true;
+ msec_delay = (int)(es.delaySpinBox->value() * 100.00);
if(es.continiuosCheckBox->isChecked())
{
continousSteps();
@@ -827,3 +849,31 @@
statusBar()->showMessage(tr("Sucessfully loaded experiment for continuation.").toAscii());
}
+void MainWindow::sliderChanged(int value)
+{
+ // Anti slider->spinBox value change lock
+ delaySpinBox->blockSignals(true);
+ // Set the spinBox to value from slider proportional to the spinBox range
+ delaySpinBox->setValue(
+ ((delaySpinBox->maximum() - delaySpinBox->minimum()) / 100)
+ * value
+ );
+ // release lock
+ delaySpinBox->blockSignals(false);
+}
+
+void MainWindow::spinBoxChanged(double value)
+{
+ // Anti spinBox->slider value change lock
+ delaySlider->blockSignals(true);
+ // Setting it here is easier
+ // When the value is set by slider, this function will be called anywayz
+ msec_delay = value * 100.00;
+ // Set the slider proportional to spinBox range
+ delaySlider->setValue(
+ (value / (delaySpinBox->maximum() - delaySpinBox->minimum()))
+ * 100);
+ // release lock
+ delaySlider->blockSignals(false);
+}
+
Modified: trunk/qcell/visgui/MainWindow.h
===================================================================
--- trunk/qcell/visgui/MainWindow.h 2007-01-10 19:50:10 UTC (rev 140)
+++ trunk/qcell/visgui/MainWindow.h 2007-01-10 19:57:11 UTC (rev 141)
@@ -1,6 +1,6 @@
/**@file MainWindow.h
* @author czarny
- * @version gg
+ * @version 0.7
* @date
* Created: ?ro 22 lis 2006 14:14:17 CET \n
* Last Update: ?ro 22 lis 2006 14:14:17 CET
@@ -11,7 +11,7 @@
#include "ui_MainWindow.h"
#include "ui_AboutDialog.h"
-#include "ui_ExperimentSetup.h"
+#include "ExperimentSetup.h"
#include <QPluginLoader>
#include "GenericParserPlugin.h"
#include <QFileDialog>
@@ -24,6 +24,10 @@
#include <simulationwindow.h>
#include <Calculator.h>
+#define MIN_DELAY 0.0
+#define MAX_DELAY 5.0
+#define DELAY_STEP 0.1
+
typedef QString (*parser_fun)(QByteArray content, QString type, QString subtype);
class MainWindow : public QMainWindow, private Ui::MainWindow
@@ -47,6 +51,9 @@
void on_action_Save_experiment_activated();
void on_action_Continue_experiment_activated();
+ void sliderChanged(int value);
+ void spinBoxChanged(double value);
+
/// @todo not here!
void on_action_Forward_activated();
void on_action_Back_activated();
@@ -59,6 +66,8 @@
private:
simulationWindow* sw;
QLCDNumber* iterationLCD;
+ QSlider* delaySlider;
+ QDoubleSpinBox* delaySpinBox;
QMap<QString, ParserInterface*> neighbourhood_parsers;
QMap<QString, ParserInterface*> function_parsers;
QMap<QString, ParserInterface*> world_parsers;
@@ -77,6 +86,7 @@
bool working;
int iteration;
+ uint msec_delay;
Calculator calc;
QList<CalculationData*> data;
Modified: trunk/qcell/visgui/visgui.pro
===================================================================
--- trunk/qcell/visgui/visgui.pro 2007-01-10 19:50:10 UTC (rev 140)
+++ trunk/qcell/visgui/visgui.pro 2007-01-10 19:57:11 UTC (rev 141)
@@ -10,6 +10,7 @@
ExperimentSetup.ui \
../baseheaders/simulationwindow.ui
HEADERS = MainWindow.h \
+ ExperimentSetup.h \
../baseheaders/Client.h \
../baseheaders/ClientInfo.h \
../baseheaders/BaseDataTypes.h \
@@ -25,6 +26,7 @@
SOURCES = ../basesources/GenericParserPlugin.cpp \
main.cpp \
MainWindow.cpp \
+ ExperimentSetup.cpp \
../basesources/Client.cpp \
../basesources/ClientInfo.cpp \
../basesources/Neighbourhood.cpp \
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|