diff --git a/main.cpp b/main.cpp index e59cc70..182f596 100644 --- a/main.cpp +++ b/main.cpp @@ -9,9 +9,8 @@ int main(int argc, char *argv[]) return a.exec(); } -void QTSGraph::slotStartTimer() +void QTSGraph::PaintBox() { - // Тут рисовать PutPixel(100,100); @@ -26,6 +25,4 @@ void QTSGraph::slotStartTimer() } // Конец рисования - - StartTimer->stop(); } diff --git a/qtSimpleGraph.pro.user b/qtSimpleGraph.pro.user deleted file mode 100644 index d291e54..0000000 --- a/qtSimpleGraph.pro.user +++ /dev/null @@ -1,356 +0,0 @@ - - - - - - EnvironmentId - {05f74a09-f8dc-44d7-b276-0cdf5e994b4e} - - - ProjectExplorer.Project.ActiveTarget - 0 - - - ProjectExplorer.Project.EditorSettings - - true - false - true - - Cpp - - CppGlobal - - - - QmlJS - - QmlJSGlobal - - - 2 - UTF-8 - false - 4 - false - 80 - true - true - 1 - true - false - 0 - true - true - 0 - 8 - true - 1 - true - true - true - *.md, *.MD, Makefile - false - true - - - - ProjectExplorer.Project.PluginSettings - - - true - true - true - true - true - - - 0 - true - - true - Builtin.Questionable - - true - Builtin.DefaultTidyAndClazy - 4 - - - - true - - - - - ProjectExplorer.Project.Target.0 - - Desktop - Desktop - Desktop - {1639e0f7-0173-409e-a3e8-eff2678b1555} - 0 - 0 - 0 - - true - 0 - /home/tema/temp/build-qtSimpleGraph-Desktop-Debug - /home/tema/temp/build-qtSimpleGraph-Desktop-Debug - - - true - QtProjectManager.QMakeBuildStep - - false - - - - true - Qt4ProjectManager.MakeStep - - false - - - false - - 2 - Сборка - Сборка - ProjectExplorer.BuildSteps.Build - - - - true - Qt4ProjectManager.MakeStep - - true - clean - - false - - 1 - Очистка - Очистка - ProjectExplorer.BuildSteps.Clean - - 2 - false - - - Отладка - Qt4ProjectManager.Qt4BuildConfiguration - 2 - 2 - 2 - - - true - 2 - /home/tema/temp/build-qtSimpleGraph-Desktop-Release - /home/tema/temp/build-qtSimpleGraph-Desktop-Release - - - true - QtProjectManager.QMakeBuildStep - - false - - - - true - Qt4ProjectManager.MakeStep - - false - - - false - - 2 - Сборка - Сборка - ProjectExplorer.BuildSteps.Build - - - - true - Qt4ProjectManager.MakeStep - - true - clean - - false - - 1 - Очистка - Очистка - ProjectExplorer.BuildSteps.Clean - - 2 - false - - - Выпуск - Qt4ProjectManager.Qt4BuildConfiguration - 0 - 0 - 2 - - - true - 0 - /home/tema/temp/build-qtSimpleGraph-Desktop-Profile - /home/tema/temp/build-qtSimpleGraph-Desktop-Profile - - - true - QtProjectManager.QMakeBuildStep - - false - - - - true - Qt4ProjectManager.MakeStep - - false - - - false - - 2 - Сборка - Сборка - ProjectExplorer.BuildSteps.Build - - - - true - Qt4ProjectManager.MakeStep - - true - clean - - false - - 1 - Очистка - Очистка - ProjectExplorer.BuildSteps.Clean - - 2 - false - - - Профилирование - Qt4ProjectManager.Qt4BuildConfiguration - 0 - 0 - 0 - - 3 - - - 0 - Развёртывание - Развёртывание - ProjectExplorer.BuildSteps.Deploy - - 1 - - false - ProjectExplorer.DefaultDeployConfiguration - - 1 - - - dwarf - - cpu-cycles - - - 250 - - -e - cpu-cycles - --call-graph - dwarf,4096 - -F - 250 - - -F - true - 4096 - false - false - 1000 - - true - - false - false - false - false - true - 0.01 - 10 - true - kcachegrind - 1 - 25 - - 1 - true - false - true - valgrind - - 0 - 1 - 2 - 3 - 4 - 5 - 6 - 7 - 8 - 9 - 10 - 11 - 12 - 13 - 14 - - - 2 - - qtSimpleGraph2 - Qt4ProjectManager.Qt4RunConfiguration:/home/tema/github/qtSimpleGraph/qtSimpleGraph.pro - /home/tema/github/qtSimpleGraph/qtSimpleGraph.pro - - false - - false - true - true - false - false - true - - /home/tema/temp/build-qtSimpleGraph-Desktop-Debug - - 1 - - - - ProjectExplorer.Project.TargetCount - 1 - - - ProjectExplorer.Project.Updater.FileVersion - 22 - - - Version - 22 - - diff --git a/qtsgraph.cpp b/qtsgraph.cpp index 3be126b..9a37cf8 100644 --- a/qtsgraph.cpp +++ b/qtsgraph.cpp @@ -50,6 +50,12 @@ void QTSGraph::PutPixel(int x, int y, Qt::GlobalColor c) update(); } +void QTSGraph::slotStartTimer() +{ + StartTimer->stop(); + PaintBox(); +} + void QTSGraph::paintEvent(QPaintEvent *event) { QPainter p(this); diff --git a/qtsgraph.h b/qtsgraph.h index 5245316..82f1803 100644 --- a/qtsgraph.h +++ b/qtsgraph.h @@ -32,6 +32,7 @@ private: QPixmap m_Pixmap; QTimer *StartTimer; bool EventMouseClicked = false; + void PaintBox(); protected: void paintEvent(QPaintEvent *event) override;