Wed, 22 May 2013 20:34:21 +0300
License graphical assets under CC BY-SA 3.0 Unported
icons/qt.png | file | annotate | diff | comparison | revisions | |
ldforge.pro | file | annotate | diff | comparison | revisions | |
ldforge.qrc | file | annotate | diff | comparison | revisions | |
src/aboutDialog.cpp | file | annotate | diff | comparison | revisions | |
src/gldraw.cpp | file | annotate | diff | comparison | revisions | |
src/gldraw.h | file | annotate | diff | comparison | revisions | |
src/gui.cpp | file | annotate | diff | comparison | revisions | |
src/gui_actions.cpp | file | annotate | diff | comparison | revisions |
--- a/ldforge.pro Tue May 21 19:07:38 2013 +0300 +++ b/ldforge.pro Wed May 22 20:34:21 2013 +0300 @@ -17,10 +17,6 @@ QMAKE_CXXFLAGS += -std=c++0x QT += opengl -win32 { - DEFINES += "NO_OVERPAINTING" -} - unix { LIBS += -lGLU } \ No newline at end of file
--- a/ldforge.qrc Tue May 21 19:07:38 2013 +0300 +++ b/ldforge.qrc Wed May 22 20:34:21 2013 +0300 @@ -76,7 +76,6 @@ <file>./icons/overlay.png</file> <file>./icons/palette.png</file> <file>./icons/paste.png</file> - <file>./icons/qt.png</file> <file>./icons/quad.png</file> <file>./icons/quad-split.png</file> <file>./icons/radial-convert.png</file>
--- a/src/aboutDialog.cpp Tue May 21 19:07:38 2013 +0300 +++ b/src/aboutDialog.cpp Wed May 22 20:34:21 2013 +0300 @@ -47,17 +47,17 @@ "available for some reason, see<br />" "<a href=\"http://www.gnu.org/licenses/\">http://www.gnu.org/licenses/</a> for the license terms.</p>" - "<p>The application icon is derived from " - "<a href=\"http://en.wikipedia.org/wiki/File:Anvil,_labelled_en.svg\">this image</a>.</p>" + "<p>The graphical assets of " APPNAME " are licensed under the<br />" + "<a href=\"http://creativecommons.org/licenses/by-sa/3.0/\">CC Attribution-ShareAlike 3.0 Unported license</a>. The<br />" + "GNU GPL applies to the source code of the program.<br />" + "The application icon is derived from <a href=\"http://en.wikipedia.org/wiki/File:Anvil,_labelled_en.svg\">this image</a>. The<br />" + "linked image (retrieved 22 May 2013) was released<br />" + "into the public domain.</p>" ); // Rest in peace, James. QLabel* memorial = new QLabel ("In living memory of James Jessiman."); - // Align everything to the center. - for (QLabel* label : vector<QLabel*> ({icon, title, info, memorial})) - label->setAlignment (Qt::AlignCenter); - QDialogButtonBox* buttons = new QDialogButtonBox (QDialogButtonBox::Close); QPushButton* helpButton = new QPushButton; @@ -68,10 +68,13 @@ connect (buttons, SIGNAL (rejected ()), this, SLOT (reject ())); QVBoxLayout* layout = new QVBoxLayout (this); - layout->addWidget (icon); - layout->addWidget (title); - layout->addWidget (info); - layout->addWidget (memorial); + + // Align everything to the center. + for (QLabel* label : vector<QLabel*> ({icon, title, info, memorial})) { + label->setAlignment (Qt::AlignCenter); + layout->addWidget (label); + } + layout->addWidget (buttons); setWindowTitle ("About " APPNAME);
--- a/src/gldraw.cpp Tue May 21 19:07:38 2013 +0300 +++ b/src/gldraw.cpp Wed May 22 20:34:21 2013 +0300 @@ -189,10 +189,6 @@ glLineWidth (gl_linethickness); -#ifdef NO_OVERPAINTING - initGLData (); -#endif // NO_OVERPAINTING - setAutoFillBackground (false); setMouseTracking (true); setFocusPolicy (Qt::WheelFocus); @@ -479,8 +475,6 @@ // ============================================================================= // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // ============================================================================= -#ifndef NO_OVERPAINTING - void GLRenderer::paintEvent (QPaintEvent* ev) { Q_UNUSED (ev) m_virtWidth = m_zoom; @@ -665,23 +659,6 @@ } } -#else - -void GLRenderer::paintGL () { - m_virtWidth = m_zoom; - m_virtHeight = (m_height * m_virtWidth) / m_width; - drawGLScene (); - - m_hoverpos = g_origin; - if (m_camera != Free) - m_hoverpos = coordconv2_3 (m_pos, true); - - g_win->setStatusBarText (fmt ("%s camera: X: %f, Y: %f, Z: %f", - g_CameraNames[camera ()], m_hoverpos[X], m_hoverpos[Y], m_hoverpos[Z])); -} - -#endif // NO_OVERPAINTING - // ============================================================================= // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // =============================================================================
--- a/src/gldraw.h Tue May 21 19:07:38 2013 +0300 +++ b/src/gldraw.h Wed May 22 20:34:21 2013 +0300 @@ -83,14 +83,9 @@ void mousePressEvent (QMouseEvent* ev); void mouseMoveEvent (QMouseEvent* ev); void mouseReleaseEvent (QMouseEvent* ev); + void paintEvent (QPaintEvent* ev); void resizeGL (int w, int h); void wheelEvent (QWheelEvent* ev); - -#ifndef NO_OVERPAINTING - void paintEvent (QPaintEvent* ev); -#else - void paintGL (); -#endif // NO_OVERPAINTING private: QTimer* m_toolTipTimer;
--- a/src/gui.cpp Tue May 21 19:07:38 2013 +0300 +++ b/src/gui.cpp Wed May 22 20:34:21 2013 +0300 @@ -128,11 +128,6 @@ findAction ("wireframe")->setCheckable (true); findAction ("wireframe")->setChecked (gl_wireframe); -#ifdef NO_OVERPAINTING - for (int i = 0; i < 7; ++i) - findAction (fmt ("camera%s", g_CameraNames[i]))->setCheckable (true); -#endif - updateEditModeActions (); // things not implemented yet @@ -427,13 +422,6 @@ addToolBarAction ("modeSelect"); addToolBarAction ("modeDraw"); -#ifdef NO_OVERPAINTING - g_CurrentToolBar->addSeparator (); - - for (int i = 0; i < 7; ++i) - addToolBarAction (fmt ("camera%s", g_CameraNames[i])); -#endif // NO_OVERPAINTING - updateToolBars (); } @@ -1003,11 +991,6 @@ if (i != GL::Select) act->setEnabled (R ()->camera () != GL::Free); } - -#ifdef NO_OVERPAINTING - for (int i = 0; i < 7; ++i) - findAction (fmt ("camera%s", g_CameraNames[i]))->setChecked (i == (R ()->camera ())); -#endif } // ========================================================================================================================================
--- a/src/gui_actions.cpp Tue May 21 19:07:38 2013 +0300 +++ b/src/gui_actions.cpp Wed May 22 20:34:21 2013 +0300 @@ -449,20 +449,4 @@ if (ok) g_win->R ()->setDepthValue (depth); -} - -#ifdef NO_OVERPAINTING -#define CAMERA_ACTION(NAME,LOWERNAME) \ -MAKE_ACTION (camera##NAME, #NAME " Camera", "camera-" #LOWERNAME, "Change to the " #LOWERNAME " camera", (0)) { \ - g_win->R ()->setCamera (GL::NAME); \ -} - -CAMERA_ACTION (Top, top) -CAMERA_ACTION (Bottom, bottom) -CAMERA_ACTION (Left, left) -CAMERA_ACTION (Right, right) -CAMERA_ACTION (Front, front) -CAMERA_ACTION (Back, back) -CAMERA_ACTION (Free, free) - -#endif // NO_OVERPAINTING \ No newline at end of file +} \ No newline at end of file