[QGIS Commit] r8910 - branches/grass-tidyup-branch/src/plugins/grass

svn_qgis at osgeo.org svn_qgis at osgeo.org
Fri Jul 25 19:44:14 EDT 2008


Author: timlinux
Date: 2008-07-25 19:44:13 -0400 (Fri, 25 Jul 2008)
New Revision: 8910

Removed:
   branches/grass-tidyup-branch/src/plugins/grass/qgsgrassshellbase.ui
Modified:
   branches/grass-tidyup-branch/src/plugins/grass/qgsgrassmodule.cpp
   branches/grass-tidyup-branch/src/plugins/grass/qgsgrassshell.cpp
Log:
Got rid of references to qgsgrassshelltext.h. No need for qgrassshellbase.ui anymore since I'm building the widget programmatically. The grass modules list is now in a scroll area so no more massive long list of options overrunning the available screen real estate.

Modified: branches/grass-tidyup-branch/src/plugins/grass/qgsgrassmodule.cpp
===================================================================
--- branches/grass-tidyup-branch/src/plugins/grass/qgsgrassmodule.cpp	2008-07-25 23:18:02 UTC (rev 8909)
+++ branches/grass-tidyup-branch/src/plugins/grass/qgsgrassmodule.cpp	2008-07-25 23:44:13 UTC (rev 8910)
@@ -301,7 +301,10 @@
   }
   else
   {
-    QMessageBox::warning( 0, tr("Warning"), tr("Cannot find man page ") + manPath );
+    mManualTextBrowser->clear();
+    mManualTextBrowser->textCursor().insertImage( ":/grass/error.png");
+    mManualTextBrowser->insertPlainText (  tr("Cannot find man page ") + manPath );
+    mManualTextBrowser->insertPlainText (  tr("Please ensure you have the GRASS documentation installed.") );
   }
 
   connect ( &mProcess, SIGNAL(readyReadStandardOutput()), this, SLOT(readStdout()));
@@ -409,8 +412,23 @@
 
   // Read QGIS options and create controls
   QDomNode n = qDocElem.firstChild();
-  //QVBoxLayout *layout = new QVBoxLayout ( mTabWidget->page(0), 10 );
-  QVBoxLayout *layout = new QVBoxLayout ( mParent, 10 );
+  //
+  //Set up dynamic inside a scroll box
+  //
+  QVBoxLayout * mypOuterLayout = new QVBoxLayout(mParent);
+  mypOuterLayout->setContentsMargins(0,0,0,0);
+  //transfers layout ownership so no need to call delete
+  this->setLayout(mypOuterLayout);
+  QScrollArea * mypScrollArea = new QScrollArea();
+  //transfers scroll area ownership so no need to call delete
+  mypOuterLayout->addWidget(mypScrollArea);
+  QFrame * mypInnerFrame = new QFrame();
+  mypInnerFrame->setFrameShape(QFrame::NoFrame);
+  mypInnerFrame->setFrameShadow(QFrame::Plain);
+  //transfers frame ownership so no need to call delete
+  mypScrollArea->setWidget(mypInnerFrame);
+  mypScrollArea->setWidgetResizable( true );
+  QVBoxLayout *layout = new QVBoxLayout ( mypInnerFrame);
   while( !n.isNull() ) {
     QDomElement e = n.toElement();
     if( !e.isNull() ) {

Modified: branches/grass-tidyup-branch/src/plugins/grass/qgsgrassshell.cpp
===================================================================
--- branches/grass-tidyup-branch/src/plugins/grass/qgsgrassshell.cpp	2008-07-25 23:18:02 UTC (rev 8909)
+++ branches/grass-tidyup-branch/src/plugins/grass/qgsgrassshell.cpp	2008-07-25 23:44:13 UTC (rev 8910)
@@ -39,7 +39,6 @@
 
 #include "qgsapplication.h"
 #include "qgsgrassshell.h"
-#include "qgsgrassshelltext.h"
 
 extern "C" {
 #include <stdio.h>

Deleted: branches/grass-tidyup-branch/src/plugins/grass/qgsgrassshellbase.ui
===================================================================



More information about the QGIS-commit mailing list