Progress :D
This commit is contained in:
		@@ -1,6 +1,6 @@
 | 
				
			|||||||
<?xml version="1.0" encoding="UTF-8"?>
 | 
					<?xml version="1.0" encoding="UTF-8"?>
 | 
				
			||||||
<!DOCTYPE QtCreatorProject>
 | 
					<!DOCTYPE QtCreatorProject>
 | 
				
			||||||
<!-- Written by QtCreator 4.4.0, 2017-09-05T20:42:14. -->
 | 
					<!-- Written by QtCreator 4.4.0, 2017-09-06T18:37:05. -->
 | 
				
			||||||
<qtcreator>
 | 
					<qtcreator>
 | 
				
			||||||
 <data>
 | 
					 <data>
 | 
				
			||||||
  <variable>EnvironmentId</variable>
 | 
					  <variable>EnvironmentId</variable>
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1,12 +1,14 @@
 | 
				
			|||||||
#include "mainwindow.h"
 | 
					#include "mainwindow.h"
 | 
				
			||||||
#include "ui_mainwindow.h"
 | 
					#include "ui_mainwindow.h"
 | 
				
			||||||
#include <QPainter>
 | 
					#include <QPainter>
 | 
				
			||||||
 | 
					#include <QColorDialog>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
MainWindow::MainWindow(QWidget *parent) :
 | 
					MainWindow::MainWindow(QWidget *parent) :
 | 
				
			||||||
	QMainWindow(parent),
 | 
						QMainWindow(parent),
 | 
				
			||||||
	ui(new Ui::MainWindow)
 | 
						ui(new Ui::MainWindow)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
	ui->setupUi(this);
 | 
						ui->setupUi(this);
 | 
				
			||||||
 | 
						UpdateUi();
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
MainWindow::~MainWindow()
 | 
					MainWindow::~MainWindow()
 | 
				
			||||||
@@ -14,6 +16,13 @@ MainWindow::~MainWindow()
 | 
				
			|||||||
	delete ui;
 | 
						delete ui;
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					void MainWindow::UpdateUi()
 | 
				
			||||||
 | 
					{
 | 
				
			||||||
 | 
						this->ui->scaleInput->setValue(this->ui->renderArea->scale());
 | 
				
			||||||
 | 
						this->ui->intervalInput->setValue(this->ui->renderArea->intervalLenght());
 | 
				
			||||||
 | 
						this->ui->stepInput->setValue(this->ui->renderArea->stepCount());
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
void MainWindow::paintEvent(QPaintEvent* event)
 | 
					void MainWindow::paintEvent(QPaintEvent* event)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
	QPainter painter{this};
 | 
						QPainter painter{this};
 | 
				
			||||||
@@ -24,46 +33,61 @@ void MainWindow::on_btnAstroid_clicked()
 | 
				
			|||||||
{
 | 
					{
 | 
				
			||||||
	this->ui->renderArea->setShape(RenderArea::Astroid);
 | 
						this->ui->renderArea->setShape(RenderArea::Astroid);
 | 
				
			||||||
	this->ui->renderArea->repaint();
 | 
						this->ui->renderArea->repaint();
 | 
				
			||||||
 | 
						UpdateUi();
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
void MainWindow::on_btnCicloid_clicked()
 | 
					void MainWindow::on_btnCicloid_clicked()
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
	this->ui->renderArea->setShape(RenderArea::Cycloid);
 | 
						this->ui->renderArea->setShape(RenderArea::Cycloid);
 | 
				
			||||||
	this->ui->renderArea->repaint();
 | 
						this->ui->renderArea->repaint();
 | 
				
			||||||
 | 
						UpdateUi();
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
void MainWindow::on_btnHuygens_clicked()
 | 
					void MainWindow::on_btnHuygens_clicked()
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
	this->ui->renderArea->setShape(RenderArea::HuygensCycloid);
 | 
						this->ui->renderArea->setShape(RenderArea::HuygensCycloid);
 | 
				
			||||||
	this->ui->renderArea->repaint();
 | 
						this->ui->renderArea->repaint();
 | 
				
			||||||
 | 
						UpdateUi();
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
void MainWindow::on_btnHypo_clicked()
 | 
					void MainWindow::on_btnHypo_clicked()
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
	this->ui->renderArea->setShape(RenderArea::HypoCycloid);
 | 
						this->ui->renderArea->setShape(RenderArea::HypoCycloid);
 | 
				
			||||||
	this->ui->renderArea->repaint();
 | 
						this->ui->renderArea->repaint();
 | 
				
			||||||
 | 
						UpdateUi();
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
void MainWindow::on_btnLine_clicked()
 | 
					void MainWindow::on_btnLine_clicked()
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
	this->ui->renderArea->setShape(RenderArea::Line);
 | 
						this->ui->renderArea->setShape(RenderArea::Line);
 | 
				
			||||||
	this->ui->renderArea->repaint();
 | 
						this->ui->renderArea->repaint();
 | 
				
			||||||
 | 
						UpdateUi();
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
void MainWindow::on_intervalInput_valueChanged(double arg1)
 | 
					void MainWindow::on_intervalInput_valueChanged(double interval)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
	this->ui->renderArea->setInternalLenght(arg1);
 | 
						this->ui->renderArea->setInternalLenght(interval);
 | 
				
			||||||
	this->ui->renderArea->repaint();
 | 
					 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
void MainWindow::on_scaleInput_valueChanged(double arg1)
 | 
					void MainWindow::on_scaleInput_valueChanged(double scale)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
	this->ui->renderArea->setScale(arg1);
 | 
						this->ui->renderArea->setScale(scale);
 | 
				
			||||||
	this->ui->renderArea->repaint();
 | 
					 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
void MainWindow::on_stepInput_valueChanged(double arg1)
 | 
					void MainWindow::on_stepInput_valueChanged(int count)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
	this->ui->renderArea->setStepCount(arg1);
 | 
						this->ui->renderArea->setStepCount(count);
 | 
				
			||||||
	this->ui->renderArea->repaint();
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					void MainWindow::on_btnBackgroundColor_clicked()
 | 
				
			||||||
 | 
					{
 | 
				
			||||||
 | 
						auto color{QColorDialog::getColor(this->ui->renderArea->backgroundColor(),this,"Select Color")};
 | 
				
			||||||
 | 
						ui->renderArea->setBackgroundColor(color);
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					void MainWindow::on_btnLineColor_clicked()
 | 
				
			||||||
 | 
					{
 | 
				
			||||||
 | 
						auto color{QColorDialog::getColor(this->ui->renderArea->shapeColor(),this,"Select Color")};
 | 
				
			||||||
 | 
						ui->renderArea->setShapeColor(color);
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -33,9 +33,14 @@ class MainWindow : public QMainWindow
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
		void on_scaleInput_valueChanged(double arg1);
 | 
							void on_scaleInput_valueChanged(double arg1);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
		void on_stepInput_valueChanged(double arg1);
 | 
							void on_stepInput_valueChanged(int arg1);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
							void on_btnBackgroundColor_clicked();
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
							void on_btnLineColor_clicked();
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	private:
 | 
						private:
 | 
				
			||||||
 | 
							void UpdateUi();
 | 
				
			||||||
		constexpr static QWidget* root = 0;
 | 
							constexpr static QWidget* root = 0;
 | 
				
			||||||
		Ui::MainWindow *ui;
 | 
							Ui::MainWindow *ui;
 | 
				
			||||||
};
 | 
					};
 | 
				
			||||||
 
 | 
				
			|||||||
							
								
								
									
										384
									
								
								mainwindow.ui
									
									
									
									
									
								
							
							
						
						
									
										384
									
								
								mainwindow.ui
									
									
									
									
									
								
							@@ -6,13 +6,22 @@
 | 
				
			|||||||
   <rect>
 | 
					   <rect>
 | 
				
			||||||
    <x>0</x>
 | 
					    <x>0</x>
 | 
				
			||||||
    <y>0</y>
 | 
					    <y>0</y>
 | 
				
			||||||
    <width>670</width>
 | 
					    <width>669</width>
 | 
				
			||||||
    <height>612</height>
 | 
					    <height>611</height>
 | 
				
			||||||
   </rect>
 | 
					   </rect>
 | 
				
			||||||
  </property>
 | 
					  </property>
 | 
				
			||||||
  <property name="palette">
 | 
					  <property name="palette">
 | 
				
			||||||
   <palette>
 | 
					   <palette>
 | 
				
			||||||
    <active>
 | 
					    <active>
 | 
				
			||||||
 | 
					     <colorrole role="WindowText">
 | 
				
			||||||
 | 
					      <brush brushstyle="SolidPattern">
 | 
				
			||||||
 | 
					       <color alpha="255">
 | 
				
			||||||
 | 
					        <red>251</red>
 | 
				
			||||||
 | 
					        <green>250</green>
 | 
				
			||||||
 | 
					        <blue>250</blue>
 | 
				
			||||||
 | 
					       </color>
 | 
				
			||||||
 | 
					      </brush>
 | 
				
			||||||
 | 
					     </colorrole>
 | 
				
			||||||
     <colorrole role="Button">
 | 
					     <colorrole role="Button">
 | 
				
			||||||
      <brush brushstyle="SolidPattern">
 | 
					      <brush brushstyle="SolidPattern">
 | 
				
			||||||
       <color alpha="255">
 | 
					       <color alpha="255">
 | 
				
			||||||
@@ -31,6 +40,24 @@
 | 
				
			|||||||
       </color>
 | 
					       </color>
 | 
				
			||||||
      </brush>
 | 
					      </brush>
 | 
				
			||||||
     </colorrole>
 | 
					     </colorrole>
 | 
				
			||||||
 | 
					     <colorrole role="Text">
 | 
				
			||||||
 | 
					      <brush brushstyle="SolidPattern">
 | 
				
			||||||
 | 
					       <color alpha="255">
 | 
				
			||||||
 | 
					        <red>251</red>
 | 
				
			||||||
 | 
					        <green>250</green>
 | 
				
			||||||
 | 
					        <blue>250</blue>
 | 
				
			||||||
 | 
					       </color>
 | 
				
			||||||
 | 
					      </brush>
 | 
				
			||||||
 | 
					     </colorrole>
 | 
				
			||||||
 | 
					     <colorrole role="ButtonText">
 | 
				
			||||||
 | 
					      <brush brushstyle="SolidPattern">
 | 
				
			||||||
 | 
					       <color alpha="255">
 | 
				
			||||||
 | 
					        <red>251</red>
 | 
				
			||||||
 | 
					        <green>250</green>
 | 
				
			||||||
 | 
					        <blue>250</blue>
 | 
				
			||||||
 | 
					       </color>
 | 
				
			||||||
 | 
					      </brush>
 | 
				
			||||||
 | 
					     </colorrole>
 | 
				
			||||||
     <colorrole role="Base">
 | 
					     <colorrole role="Base">
 | 
				
			||||||
      <brush brushstyle="SolidPattern">
 | 
					      <brush brushstyle="SolidPattern">
 | 
				
			||||||
       <color alpha="255">
 | 
					       <color alpha="255">
 | 
				
			||||||
@@ -51,6 +78,15 @@
 | 
				
			|||||||
     </colorrole>
 | 
					     </colorrole>
 | 
				
			||||||
    </active>
 | 
					    </active>
 | 
				
			||||||
    <inactive>
 | 
					    <inactive>
 | 
				
			||||||
 | 
					     <colorrole role="WindowText">
 | 
				
			||||||
 | 
					      <brush brushstyle="SolidPattern">
 | 
				
			||||||
 | 
					       <color alpha="255">
 | 
				
			||||||
 | 
					        <red>251</red>
 | 
				
			||||||
 | 
					        <green>250</green>
 | 
				
			||||||
 | 
					        <blue>250</blue>
 | 
				
			||||||
 | 
					       </color>
 | 
				
			||||||
 | 
					      </brush>
 | 
				
			||||||
 | 
					     </colorrole>
 | 
				
			||||||
     <colorrole role="Button">
 | 
					     <colorrole role="Button">
 | 
				
			||||||
      <brush brushstyle="SolidPattern">
 | 
					      <brush brushstyle="SolidPattern">
 | 
				
			||||||
       <color alpha="255">
 | 
					       <color alpha="255">
 | 
				
			||||||
@@ -69,6 +105,24 @@
 | 
				
			|||||||
       </color>
 | 
					       </color>
 | 
				
			||||||
      </brush>
 | 
					      </brush>
 | 
				
			||||||
     </colorrole>
 | 
					     </colorrole>
 | 
				
			||||||
 | 
					     <colorrole role="Text">
 | 
				
			||||||
 | 
					      <brush brushstyle="SolidPattern">
 | 
				
			||||||
 | 
					       <color alpha="255">
 | 
				
			||||||
 | 
					        <red>251</red>
 | 
				
			||||||
 | 
					        <green>250</green>
 | 
				
			||||||
 | 
					        <blue>250</blue>
 | 
				
			||||||
 | 
					       </color>
 | 
				
			||||||
 | 
					      </brush>
 | 
				
			||||||
 | 
					     </colorrole>
 | 
				
			||||||
 | 
					     <colorrole role="ButtonText">
 | 
				
			||||||
 | 
					      <brush brushstyle="SolidPattern">
 | 
				
			||||||
 | 
					       <color alpha="255">
 | 
				
			||||||
 | 
					        <red>251</red>
 | 
				
			||||||
 | 
					        <green>250</green>
 | 
				
			||||||
 | 
					        <blue>250</blue>
 | 
				
			||||||
 | 
					       </color>
 | 
				
			||||||
 | 
					      </brush>
 | 
				
			||||||
 | 
					     </colorrole>
 | 
				
			||||||
     <colorrole role="Base">
 | 
					     <colorrole role="Base">
 | 
				
			||||||
      <brush brushstyle="SolidPattern">
 | 
					      <brush brushstyle="SolidPattern">
 | 
				
			||||||
       <color alpha="255">
 | 
					       <color alpha="255">
 | 
				
			||||||
@@ -89,6 +143,15 @@
 | 
				
			|||||||
     </colorrole>
 | 
					     </colorrole>
 | 
				
			||||||
    </inactive>
 | 
					    </inactive>
 | 
				
			||||||
    <disabled>
 | 
					    <disabled>
 | 
				
			||||||
 | 
					     <colorrole role="WindowText">
 | 
				
			||||||
 | 
					      <brush brushstyle="SolidPattern">
 | 
				
			||||||
 | 
					       <color alpha="255">
 | 
				
			||||||
 | 
					        <red>251</red>
 | 
				
			||||||
 | 
					        <green>250</green>
 | 
				
			||||||
 | 
					        <blue>250</blue>
 | 
				
			||||||
 | 
					       </color>
 | 
				
			||||||
 | 
					      </brush>
 | 
				
			||||||
 | 
					     </colorrole>
 | 
				
			||||||
     <colorrole role="Button">
 | 
					     <colorrole role="Button">
 | 
				
			||||||
      <brush brushstyle="SolidPattern">
 | 
					      <brush brushstyle="SolidPattern">
 | 
				
			||||||
       <color alpha="255">
 | 
					       <color alpha="255">
 | 
				
			||||||
@@ -107,6 +170,24 @@
 | 
				
			|||||||
       </color>
 | 
					       </color>
 | 
				
			||||||
      </brush>
 | 
					      </brush>
 | 
				
			||||||
     </colorrole>
 | 
					     </colorrole>
 | 
				
			||||||
 | 
					     <colorrole role="Text">
 | 
				
			||||||
 | 
					      <brush brushstyle="SolidPattern">
 | 
				
			||||||
 | 
					       <color alpha="255">
 | 
				
			||||||
 | 
					        <red>251</red>
 | 
				
			||||||
 | 
					        <green>250</green>
 | 
				
			||||||
 | 
					        <blue>250</blue>
 | 
				
			||||||
 | 
					       </color>
 | 
				
			||||||
 | 
					      </brush>
 | 
				
			||||||
 | 
					     </colorrole>
 | 
				
			||||||
 | 
					     <colorrole role="ButtonText">
 | 
				
			||||||
 | 
					      <brush brushstyle="SolidPattern">
 | 
				
			||||||
 | 
					       <color alpha="255">
 | 
				
			||||||
 | 
					        <red>251</red>
 | 
				
			||||||
 | 
					        <green>250</green>
 | 
				
			||||||
 | 
					        <blue>250</blue>
 | 
				
			||||||
 | 
					       </color>
 | 
				
			||||||
 | 
					      </brush>
 | 
				
			||||||
 | 
					     </colorrole>
 | 
				
			||||||
     <colorrole role="Base">
 | 
					     <colorrole role="Base">
 | 
				
			||||||
      <brush brushstyle="SolidPattern">
 | 
					      <brush brushstyle="SolidPattern">
 | 
				
			||||||
       <color alpha="255">
 | 
					       <color alpha="255">
 | 
				
			||||||
@@ -135,34 +216,27 @@
 | 
				
			|||||||
   <bool>false</bool>
 | 
					   <bool>false</bool>
 | 
				
			||||||
  </property>
 | 
					  </property>
 | 
				
			||||||
  <property name="styleSheet">
 | 
					  <property name="styleSheet">
 | 
				
			||||||
   <string notr="true">background-color: rgb(11,10,10);</string>
 | 
					   <string notr="true">background-color: rgb(11,10,10);
 | 
				
			||||||
 | 
					color: rgb(251, 250, 250);</string>
 | 
				
			||||||
  </property>
 | 
					  </property>
 | 
				
			||||||
  <widget class="QWidget" name="centralWidget">
 | 
					  <widget class="QWidget" name="centralWidget">
 | 
				
			||||||
   <property name="styleSheet">
 | 
					   <property name="styleSheet">
 | 
				
			||||||
    <string notr="true">background-color: rgb(16, 15, 15);</string>
 | 
					    <string notr="true">background-color: rgb(16, 15, 15);</string>
 | 
				
			||||||
   </property>
 | 
					   </property>
 | 
				
			||||||
 | 
					   <layout class="QGridLayout" name="gridLayout">
 | 
				
			||||||
 | 
					    <item row="0" column="0">
 | 
				
			||||||
 | 
					     <layout class="QVBoxLayout" name="verticalLayout_2">
 | 
				
			||||||
 | 
					      <item>
 | 
				
			||||||
       <widget class="RenderArea" name="renderArea" native="true">
 | 
					       <widget class="RenderArea" name="renderArea" native="true">
 | 
				
			||||||
        <property name="enabled">
 | 
					        <property name="enabled">
 | 
				
			||||||
         <bool>true</bool>
 | 
					         <bool>true</bool>
 | 
				
			||||||
        </property>
 | 
					        </property>
 | 
				
			||||||
    <property name="geometry">
 | 
					 | 
				
			||||||
     <rect>
 | 
					 | 
				
			||||||
      <x>11</x>
 | 
					 | 
				
			||||||
      <y>11</y>
 | 
					 | 
				
			||||||
      <width>491</width>
 | 
					 | 
				
			||||||
      <height>481</height>
 | 
					 | 
				
			||||||
     </rect>
 | 
					 | 
				
			||||||
    </property>
 | 
					 | 
				
			||||||
       </widget>
 | 
					       </widget>
 | 
				
			||||||
   <widget class="QPushButton" name="btnLine_2">
 | 
					      </item>
 | 
				
			||||||
    <property name="geometry">
 | 
					      <item>
 | 
				
			||||||
     <rect>
 | 
					       <layout class="QHBoxLayout" name="horizontalLayout_4">
 | 
				
			||||||
      <x>10</x>
 | 
					        <item>
 | 
				
			||||||
      <y>560</y>
 | 
					         <widget class="QPushButton" name="btnBackgroundColor">
 | 
				
			||||||
      <width>101</width>
 | 
					 | 
				
			||||||
      <height>21</height>
 | 
					 | 
				
			||||||
     </rect>
 | 
					 | 
				
			||||||
    </property>
 | 
					 | 
				
			||||||
          <property name="styleSheet">
 | 
					          <property name="styleSheet">
 | 
				
			||||||
           <string notr="true">color: rgb(255, 255, 255);
 | 
					           <string notr="true">color: rgb(255, 255, 255);
 | 
				
			||||||
background-color: rgb(36, 35, 35);
 | 
					background-color: rgb(36, 35, 35);
 | 
				
			||||||
@@ -172,15 +246,9 @@ border-color: rgb(255, 255, 255);</string>
 | 
				
			|||||||
           <string>Background colour</string>
 | 
					           <string>Background colour</string>
 | 
				
			||||||
          </property>
 | 
					          </property>
 | 
				
			||||||
         </widget>
 | 
					         </widget>
 | 
				
			||||||
   <widget class="QPushButton" name="btnLine_3">
 | 
					        </item>
 | 
				
			||||||
    <property name="geometry">
 | 
					        <item>
 | 
				
			||||||
     <rect>
 | 
					         <widget class="QPushButton" name="btnLineColor">
 | 
				
			||||||
      <x>120</x>
 | 
					 | 
				
			||||||
      <y>560</y>
 | 
					 | 
				
			||||||
      <width>61</width>
 | 
					 | 
				
			||||||
      <height>21</height>
 | 
					 | 
				
			||||||
     </rect>
 | 
					 | 
				
			||||||
    </property>
 | 
					 | 
				
			||||||
          <property name="styleSheet">
 | 
					          <property name="styleSheet">
 | 
				
			||||||
           <string notr="true">color: rgb(255, 255, 255);
 | 
					           <string notr="true">color: rgb(255, 255, 255);
 | 
				
			||||||
background-color: rgb(36, 35, 35);
 | 
					background-color: rgb(36, 35, 35);
 | 
				
			||||||
@@ -190,121 +258,26 @@ border-color: rgb(255, 255, 255);</string>
 | 
				
			|||||||
           <string> Line colour</string>
 | 
					           <string> Line colour</string>
 | 
				
			||||||
          </property>
 | 
					          </property>
 | 
				
			||||||
         </widget>
 | 
					         </widget>
 | 
				
			||||||
   <widget class="QWidget" name="">
 | 
					        </item>
 | 
				
			||||||
    <property name="geometry">
 | 
					        <item>
 | 
				
			||||||
     <rect>
 | 
					         <spacer name="horizontalSpacer">
 | 
				
			||||||
      <x>510</x>
 | 
					          <property name="orientation">
 | 
				
			||||||
      <y>150</y>
 | 
					           <enum>Qt::Horizontal</enum>
 | 
				
			||||||
      <width>151</width>
 | 
					 | 
				
			||||||
      <height>86</height>
 | 
					 | 
				
			||||||
     </rect>
 | 
					 | 
				
			||||||
          </property>
 | 
					          </property>
 | 
				
			||||||
 | 
					          <property name="sizeHint" stdset="0">
 | 
				
			||||||
 | 
					           <size>
 | 
				
			||||||
 | 
					            <width>318</width>
 | 
				
			||||||
 | 
					            <height>20</height>
 | 
				
			||||||
 | 
					           </size>
 | 
				
			||||||
 | 
					          </property>
 | 
				
			||||||
 | 
					         </spacer>
 | 
				
			||||||
 | 
					        </item>
 | 
				
			||||||
 | 
					       </layout>
 | 
				
			||||||
 | 
					      </item>
 | 
				
			||||||
 | 
					     </layout>
 | 
				
			||||||
 | 
					    </item>
 | 
				
			||||||
 | 
					    <item row="0" column="1">
 | 
				
			||||||
     <layout class="QVBoxLayout" name="verticalLayout">
 | 
					     <layout class="QVBoxLayout" name="verticalLayout">
 | 
				
			||||||
     <item>
 | 
					 | 
				
			||||||
      <layout class="QHBoxLayout" name="horizontalLayout_3">
 | 
					 | 
				
			||||||
       <item>
 | 
					 | 
				
			||||||
        <widget class="QLabel" name="label">
 | 
					 | 
				
			||||||
         <property name="styleSheet">
 | 
					 | 
				
			||||||
          <string notr="true">color: rgb(255, 255, 255);</string>
 | 
					 | 
				
			||||||
         </property>
 | 
					 | 
				
			||||||
         <property name="text">
 | 
					 | 
				
			||||||
          <string>Scale</string>
 | 
					 | 
				
			||||||
         </property>
 | 
					 | 
				
			||||||
         <property name="textFormat">
 | 
					 | 
				
			||||||
          <enum>Qt::PlainText</enum>
 | 
					 | 
				
			||||||
         </property>
 | 
					 | 
				
			||||||
         <property name="scaledContents">
 | 
					 | 
				
			||||||
          <bool>false</bool>
 | 
					 | 
				
			||||||
         </property>
 | 
					 | 
				
			||||||
         <property name="alignment">
 | 
					 | 
				
			||||||
          <set>Qt::AlignCenter</set>
 | 
					 | 
				
			||||||
         </property>
 | 
					 | 
				
			||||||
        </widget>
 | 
					 | 
				
			||||||
       </item>
 | 
					 | 
				
			||||||
       <item>
 | 
					 | 
				
			||||||
        <widget class="QDoubleSpinBox" name="scaleInput">
 | 
					 | 
				
			||||||
         <property name="styleSheet">
 | 
					 | 
				
			||||||
          <string notr="true">color: rgb(255, 255, 255);
 | 
					 | 
				
			||||||
background-color: rgb(36, 35, 35);</string>
 | 
					 | 
				
			||||||
         </property>
 | 
					 | 
				
			||||||
        </widget>
 | 
					 | 
				
			||||||
       </item>
 | 
					 | 
				
			||||||
      </layout>
 | 
					 | 
				
			||||||
     </item>
 | 
					 | 
				
			||||||
     <item>
 | 
					 | 
				
			||||||
      <layout class="QHBoxLayout" name="horizontalLayout_2">
 | 
					 | 
				
			||||||
       <item>
 | 
					 | 
				
			||||||
        <widget class="QLabel" name="label_2">
 | 
					 | 
				
			||||||
         <property name="styleSheet">
 | 
					 | 
				
			||||||
          <string notr="true">color: rgb(255, 255, 255);</string>
 | 
					 | 
				
			||||||
         </property>
 | 
					 | 
				
			||||||
         <property name="text">
 | 
					 | 
				
			||||||
          <string>Interval lenght</string>
 | 
					 | 
				
			||||||
         </property>
 | 
					 | 
				
			||||||
         <property name="textFormat">
 | 
					 | 
				
			||||||
          <enum>Qt::PlainText</enum>
 | 
					 | 
				
			||||||
         </property>
 | 
					 | 
				
			||||||
         <property name="scaledContents">
 | 
					 | 
				
			||||||
          <bool>false</bool>
 | 
					 | 
				
			||||||
         </property>
 | 
					 | 
				
			||||||
         <property name="alignment">
 | 
					 | 
				
			||||||
          <set>Qt::AlignCenter</set>
 | 
					 | 
				
			||||||
         </property>
 | 
					 | 
				
			||||||
        </widget>
 | 
					 | 
				
			||||||
       </item>
 | 
					 | 
				
			||||||
       <item>
 | 
					 | 
				
			||||||
        <widget class="QDoubleSpinBox" name="intervalInput">
 | 
					 | 
				
			||||||
         <property name="styleSheet">
 | 
					 | 
				
			||||||
          <string notr="true">color: rgb(255, 255, 255);
 | 
					 | 
				
			||||||
background-color: rgb(36, 35, 35);</string>
 | 
					 | 
				
			||||||
         </property>
 | 
					 | 
				
			||||||
        </widget>
 | 
					 | 
				
			||||||
       </item>
 | 
					 | 
				
			||||||
      </layout>
 | 
					 | 
				
			||||||
     </item>
 | 
					 | 
				
			||||||
     <item>
 | 
					 | 
				
			||||||
      <layout class="QHBoxLayout" name="horizontalLayout">
 | 
					 | 
				
			||||||
       <item>
 | 
					 | 
				
			||||||
        <widget class="QLabel" name="label_3">
 | 
					 | 
				
			||||||
         <property name="styleSheet">
 | 
					 | 
				
			||||||
          <string notr="true">color: rgb(255, 255, 255);</string>
 | 
					 | 
				
			||||||
         </property>
 | 
					 | 
				
			||||||
         <property name="text">
 | 
					 | 
				
			||||||
          <string>Step count</string>
 | 
					 | 
				
			||||||
         </property>
 | 
					 | 
				
			||||||
         <property name="textFormat">
 | 
					 | 
				
			||||||
          <enum>Qt::PlainText</enum>
 | 
					 | 
				
			||||||
         </property>
 | 
					 | 
				
			||||||
         <property name="scaledContents">
 | 
					 | 
				
			||||||
          <bool>false</bool>
 | 
					 | 
				
			||||||
         </property>
 | 
					 | 
				
			||||||
         <property name="alignment">
 | 
					 | 
				
			||||||
          <set>Qt::AlignCenter</set>
 | 
					 | 
				
			||||||
         </property>
 | 
					 | 
				
			||||||
        </widget>
 | 
					 | 
				
			||||||
       </item>
 | 
					 | 
				
			||||||
       <item>
 | 
					 | 
				
			||||||
        <widget class="QDoubleSpinBox" name="stepInput">
 | 
					 | 
				
			||||||
         <property name="styleSheet">
 | 
					 | 
				
			||||||
          <string notr="true">color: rgb(255, 255, 255);
 | 
					 | 
				
			||||||
background-color: rgb(36, 35, 35);</string>
 | 
					 | 
				
			||||||
         </property>
 | 
					 | 
				
			||||||
        </widget>
 | 
					 | 
				
			||||||
       </item>
 | 
					 | 
				
			||||||
      </layout>
 | 
					 | 
				
			||||||
     </item>
 | 
					 | 
				
			||||||
    </layout>
 | 
					 | 
				
			||||||
   </widget>
 | 
					 | 
				
			||||||
   <widget class="QWidget" name="">
 | 
					 | 
				
			||||||
    <property name="geometry">
 | 
					 | 
				
			||||||
     <rect>
 | 
					 | 
				
			||||||
      <x>509</x>
 | 
					 | 
				
			||||||
      <y>12</y>
 | 
					 | 
				
			||||||
      <width>151</width>
 | 
					 | 
				
			||||||
      <height>131</height>
 | 
					 | 
				
			||||||
     </rect>
 | 
					 | 
				
			||||||
    </property>
 | 
					 | 
				
			||||||
    <layout class="QVBoxLayout" name="verticalLayout_2">
 | 
					 | 
				
			||||||
      <item>
 | 
					      <item>
 | 
				
			||||||
       <widget class="QPushButton" name="btnAstroid">
 | 
					       <widget class="QPushButton" name="btnAstroid">
 | 
				
			||||||
        <property name="sizePolicy">
 | 
					        <property name="sizePolicy">
 | 
				
			||||||
@@ -392,8 +365,133 @@ border-color: rgb(255, 255, 255);</string>
 | 
				
			|||||||
        </property>
 | 
					        </property>
 | 
				
			||||||
       </widget>
 | 
					       </widget>
 | 
				
			||||||
      </item>
 | 
					      </item>
 | 
				
			||||||
    </layout>
 | 
					      <item>
 | 
				
			||||||
 | 
					       <layout class="QHBoxLayout" name="horizontalLayout_3">
 | 
				
			||||||
 | 
					        <item>
 | 
				
			||||||
 | 
					         <widget class="QLabel" name="label">
 | 
				
			||||||
 | 
					          <property name="styleSheet">
 | 
				
			||||||
 | 
					           <string notr="true">color: rgb(255, 255, 255);</string>
 | 
				
			||||||
 | 
					          </property>
 | 
				
			||||||
 | 
					          <property name="text">
 | 
				
			||||||
 | 
					           <string>Scale:</string>
 | 
				
			||||||
 | 
					          </property>
 | 
				
			||||||
 | 
					          <property name="textFormat">
 | 
				
			||||||
 | 
					           <enum>Qt::PlainText</enum>
 | 
				
			||||||
 | 
					          </property>
 | 
				
			||||||
 | 
					          <property name="scaledContents">
 | 
				
			||||||
 | 
					           <bool>false</bool>
 | 
				
			||||||
 | 
					          </property>
 | 
				
			||||||
 | 
					          <property name="alignment">
 | 
				
			||||||
 | 
					           <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
 | 
				
			||||||
 | 
					          </property>
 | 
				
			||||||
         </widget>
 | 
					         </widget>
 | 
				
			||||||
 | 
					        </item>
 | 
				
			||||||
 | 
					        <item>
 | 
				
			||||||
 | 
					         <widget class="QDoubleSpinBox" name="scaleInput">
 | 
				
			||||||
 | 
					          <property name="styleSheet">
 | 
				
			||||||
 | 
					           <string notr="true">color: rgb(255, 255, 255);
 | 
				
			||||||
 | 
					background-color: rgb(36, 35, 35);</string>
 | 
				
			||||||
 | 
					          </property>
 | 
				
			||||||
 | 
					          <property name="decimals">
 | 
				
			||||||
 | 
					           <number>1</number>
 | 
				
			||||||
 | 
					          </property>
 | 
				
			||||||
 | 
					          <property name="maximum">
 | 
				
			||||||
 | 
					           <double>100.000000000000000</double>
 | 
				
			||||||
 | 
					          </property>
 | 
				
			||||||
 | 
					          <property name="singleStep">
 | 
				
			||||||
 | 
					           <double>0.100000000000000</double>
 | 
				
			||||||
 | 
					          </property>
 | 
				
			||||||
 | 
					         </widget>
 | 
				
			||||||
 | 
					        </item>
 | 
				
			||||||
 | 
					       </layout>
 | 
				
			||||||
 | 
					      </item>
 | 
				
			||||||
 | 
					      <item>
 | 
				
			||||||
 | 
					       <layout class="QHBoxLayout" name="horizontalLayout_2">
 | 
				
			||||||
 | 
					        <item>
 | 
				
			||||||
 | 
					         <widget class="QLabel" name="label_2">
 | 
				
			||||||
 | 
					          <property name="styleSheet">
 | 
				
			||||||
 | 
					           <string notr="true">color: rgb(255, 255, 255);</string>
 | 
				
			||||||
 | 
					          </property>
 | 
				
			||||||
 | 
					          <property name="text">
 | 
				
			||||||
 | 
					           <string>Interval lenght:</string>
 | 
				
			||||||
 | 
					          </property>
 | 
				
			||||||
 | 
					          <property name="textFormat">
 | 
				
			||||||
 | 
					           <enum>Qt::PlainText</enum>
 | 
				
			||||||
 | 
					          </property>
 | 
				
			||||||
 | 
					          <property name="scaledContents">
 | 
				
			||||||
 | 
					           <bool>false</bool>
 | 
				
			||||||
 | 
					          </property>
 | 
				
			||||||
 | 
					          <property name="alignment">
 | 
				
			||||||
 | 
					           <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
 | 
				
			||||||
 | 
					          </property>
 | 
				
			||||||
 | 
					         </widget>
 | 
				
			||||||
 | 
					        </item>
 | 
				
			||||||
 | 
					        <item>
 | 
				
			||||||
 | 
					         <widget class="QDoubleSpinBox" name="intervalInput">
 | 
				
			||||||
 | 
					          <property name="styleSheet">
 | 
				
			||||||
 | 
					           <string notr="true">color: rgb(255, 255, 255);
 | 
				
			||||||
 | 
					background-color: rgb(36, 35, 35);</string>
 | 
				
			||||||
 | 
					          </property>
 | 
				
			||||||
 | 
					          <property name="maximum">
 | 
				
			||||||
 | 
					           <double>100.000000000000000</double>
 | 
				
			||||||
 | 
					          </property>
 | 
				
			||||||
 | 
					          <property name="singleStep">
 | 
				
			||||||
 | 
					           <double>0.100000000000000</double>
 | 
				
			||||||
 | 
					          </property>
 | 
				
			||||||
 | 
					         </widget>
 | 
				
			||||||
 | 
					        </item>
 | 
				
			||||||
 | 
					       </layout>
 | 
				
			||||||
 | 
					      </item>
 | 
				
			||||||
 | 
					      <item>
 | 
				
			||||||
 | 
					       <layout class="QHBoxLayout" name="horizontalLayout">
 | 
				
			||||||
 | 
					        <item>
 | 
				
			||||||
 | 
					         <widget class="QLabel" name="label_3">
 | 
				
			||||||
 | 
					          <property name="styleSheet">
 | 
				
			||||||
 | 
					           <string notr="true">color: rgb(255, 255, 255);</string>
 | 
				
			||||||
 | 
					          </property>
 | 
				
			||||||
 | 
					          <property name="text">
 | 
				
			||||||
 | 
					           <string>Step count:</string>
 | 
				
			||||||
 | 
					          </property>
 | 
				
			||||||
 | 
					          <property name="textFormat">
 | 
				
			||||||
 | 
					           <enum>Qt::PlainText</enum>
 | 
				
			||||||
 | 
					          </property>
 | 
				
			||||||
 | 
					          <property name="scaledContents">
 | 
				
			||||||
 | 
					           <bool>false</bool>
 | 
				
			||||||
 | 
					          </property>
 | 
				
			||||||
 | 
					          <property name="alignment">
 | 
				
			||||||
 | 
					           <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
 | 
				
			||||||
 | 
					          </property>
 | 
				
			||||||
 | 
					         </widget>
 | 
				
			||||||
 | 
					        </item>
 | 
				
			||||||
 | 
					        <item>
 | 
				
			||||||
 | 
					         <widget class="QSpinBox" name="stepInput">
 | 
				
			||||||
 | 
					          <property name="styleSheet">
 | 
				
			||||||
 | 
					           <string notr="true">color: rgb(255, 255, 255);
 | 
				
			||||||
 | 
					background-color: rgb(36, 35, 35);</string>
 | 
				
			||||||
 | 
					          </property>
 | 
				
			||||||
 | 
					          <property name="maximum">
 | 
				
			||||||
 | 
					           <number>1024</number>
 | 
				
			||||||
 | 
					          </property>
 | 
				
			||||||
 | 
					         </widget>
 | 
				
			||||||
 | 
					        </item>
 | 
				
			||||||
 | 
					       </layout>
 | 
				
			||||||
 | 
					      </item>
 | 
				
			||||||
 | 
					      <item>
 | 
				
			||||||
 | 
					       <spacer name="verticalSpacer">
 | 
				
			||||||
 | 
					        <property name="orientation">
 | 
				
			||||||
 | 
					         <enum>Qt::Vertical</enum>
 | 
				
			||||||
 | 
					        </property>
 | 
				
			||||||
 | 
					        <property name="sizeHint" stdset="0">
 | 
				
			||||||
 | 
					         <size>
 | 
				
			||||||
 | 
					          <width>20</width>
 | 
				
			||||||
 | 
					          <height>40</height>
 | 
				
			||||||
 | 
					         </size>
 | 
				
			||||||
 | 
					        </property>
 | 
				
			||||||
 | 
					       </spacer>
 | 
				
			||||||
 | 
					      </item>
 | 
				
			||||||
 | 
					     </layout>
 | 
				
			||||||
 | 
					    </item>
 | 
				
			||||||
 | 
					   </layout>
 | 
				
			||||||
  </widget>
 | 
					  </widget>
 | 
				
			||||||
  <widget class="QStatusBar" name="statusBar"/>
 | 
					  <widget class="QStatusBar" name="statusBar"/>
 | 
				
			||||||
 </widget>
 | 
					 </widget>
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1,6 +1,47 @@
 | 
				
			|||||||
#include "renderarea.h"
 | 
					#include "renderarea.h"
 | 
				
			||||||
#include <QPainter>
 | 
					#include <QPainter>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					QSize RenderArea::minimumSizeHint() const
 | 
				
			||||||
 | 
					{
 | 
				
			||||||
 | 
						return QSize{491,481};
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					QSize RenderArea::sizeHint() const
 | 
				
			||||||
 | 
					{
 | 
				
			||||||
 | 
						return QSize{491,481};
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					void RenderArea::paintEvent(QPaintEvent* event)
 | 
				
			||||||
 | 
					{
 | 
				
			||||||
 | 
						Q_UNUSED(event);
 | 
				
			||||||
 | 
						QPainter painter{this};
 | 
				
			||||||
 | 
						painter.setRenderHint(QPainter::Antialiasing,true);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
						painter.setBrush(mBackgroundColour);
 | 
				
			||||||
 | 
						painter.setPen(mShapeColour);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
						painter.drawRect(this->rect());
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
						QPointF prevPoint{Compute(0)};
 | 
				
			||||||
 | 
						QPoint center{this->rect().center()},prevPixel;
 | 
				
			||||||
 | 
						prevPixel.setX(prevPoint.x() * mScale + center.x());
 | 
				
			||||||
 | 
						prevPixel.setY(prevPoint.y() * mScale + center.y());
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
						double step{ mIntervalLenght / mStepCount };
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
						for(double t{0}; t < mIntervalLenght; t += step){
 | 
				
			||||||
 | 
							QPointF point = Compute(t);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
							QPoint pixel{};
 | 
				
			||||||
 | 
							pixel.setX(point.x() * mScale + center.x());
 | 
				
			||||||
 | 
							pixel.setY(point.y() * mScale + center.y());
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
							painter.drawLine(pixel, prevPixel);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
							prevPixel=pixel;
 | 
				
			||||||
 | 
						}
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
RenderArea::RenderArea(QWidget *parent) :
 | 
					RenderArea::RenderArea(QWidget *parent) :
 | 
				
			||||||
	QWidget{parent},
 | 
						QWidget{parent},
 | 
				
			||||||
	mBackgroundColour{36,35,35},
 | 
						mBackgroundColour{36,35,35},
 | 
				
			||||||
@@ -46,61 +87,6 @@ QPointF RenderArea::ComputeLine(double t)
 | 
				
			|||||||
	return QPointF{1-t,1-t};
 | 
						return QPointF{1-t,1-t};
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
QSize RenderArea::minimumSizeHint() const
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
	return QSize(100,100);
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
QSize RenderArea::sizeHint() const
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
	return QSize(400,200);
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
void RenderArea::setInternalLenght(double l)
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
	mIntervalLenght = l;
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
void RenderArea::setScale(double s)
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
	mScale = s;
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
void RenderArea::setStepCount(double s)
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
	mStepCount = s;
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
void RenderArea::paintEvent(QPaintEvent* event)
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
	QPainter painter{this};
 | 
					 | 
				
			||||||
	painter.setRenderHint(QPainter::Antialiasing,true);
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
	painter.setBrush(mBackgroundColour);
 | 
					 | 
				
			||||||
	painter.setPen(mShapeColour);
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
	painter.drawRect(this->rect());
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
	QPointF prevPoint{Compute(0)};
 | 
					 | 
				
			||||||
	QPoint center{this->rect().center()},prevPixel;
 | 
					 | 
				
			||||||
	prevPixel.setX(prevPoint.x() * mScale + center.x());
 | 
					 | 
				
			||||||
	prevPixel.setY(prevPoint.y() * mScale + center.y());
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
	double step{ mIntervalLenght / mStepCount };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
	for(float t = 0; t < mIntervalLenght; t += step){
 | 
					 | 
				
			||||||
		QPointF point = Compute(t);
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
		QPoint pixel;
 | 
					 | 
				
			||||||
		pixel.setX(point.x() * mScale + center.x());
 | 
					 | 
				
			||||||
		pixel.setY(point.y() * mScale + center.y());
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
		painter.drawLine(pixel, prevPixel);
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
		prevPixel=pixel;
 | 
					 | 
				
			||||||
	}
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
void RenderArea::OnShapeChanged()
 | 
					void RenderArea::OnShapeChanged()
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
	switch (mShape) {
 | 
						switch (mShape) {
 | 
				
			||||||
 
 | 
				
			|||||||
							
								
								
									
										15
									
								
								renderarea.h
									
									
									
									
									
								
							
							
						
						
									
										15
									
								
								renderarea.h
									
									
									
									
									
								
							@@ -22,12 +22,21 @@ class RenderArea : public QWidget
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
		void setBackgroundColor(QColor color) { mBackgroundColour = color; }
 | 
							void setBackgroundColor(QColor color) { mBackgroundColour = color; }
 | 
				
			||||||
		QColor backgroundColor() const { return mBackgroundColour; }
 | 
							QColor backgroundColor() const { return mBackgroundColour; }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
							void setShapeColor(QColor color) { mShapeColour = color; }
 | 
				
			||||||
 | 
							QColor shapeColor() const { return mShapeColour; }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
		void setShape(ShapesType shape) { mShape = shape; OnShapeChanged(); }
 | 
							void setShape(ShapesType shape) { mShape = shape; OnShapeChanged(); }
 | 
				
			||||||
		ShapesType shape() const { return mShape; }
 | 
							ShapesType shape() const { return mShape; }
 | 
				
			||||||
		void setInternalLenght(double l);
 | 
					 | 
				
			||||||
		void setScale(double s);
 | 
					 | 
				
			||||||
		void setStepCount(double s);
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
							void setInternalLenght(double l){mIntervalLenght=l;repaint();}
 | 
				
			||||||
 | 
							double intervalLenght() const {return mIntervalLenght;}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
							void setScale(double s){mScale=s;repaint();}
 | 
				
			||||||
 | 
							double scale() const {return mScale;}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
							void setStepCount(int s){mStepCount=s;repaint();}
 | 
				
			||||||
 | 
							int stepCount() const {return mStepCount;}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	signals:
 | 
						signals:
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user