Skip to content

Commit

Permalink
Added help button and wired context help for the new vector layer dialog
Browse files Browse the repository at this point in the history
git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@4695 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
gsherman committed Jan 15, 2006
1 parent 06619c2 commit a211553
Show file tree
Hide file tree
Showing 3 changed files with 80 additions and 62 deletions.
4 changes: 4 additions & 0 deletions src/gui/qgsgeomtypedialog.cpp
Expand Up @@ -85,6 +85,10 @@ void QgsGeomTypeDialog::on_mRemoveAttributeButton_clicked()

}

void QgsGeomTypeDialog::on_btnHelp_clicked()
{
QgsContextHelp::run(context_id);
}
void QgsGeomTypeDialog::attributes(std::list<std::pair<QString, QString> >& at) const
{
Q3ListViewItemIterator it(mAttributeView);
Expand Down
4 changes: 4 additions & 0 deletions src/gui/qgsgeomtypedialog.h
Expand Up @@ -19,6 +19,7 @@
#define QGSGEOMTYPEDIALOG_H

#include "ui_qgsgeomtypedialogbase.h"
#include "qgscontexthelp.h"
#include <QDialog>

#include "qgis.h"
Expand All @@ -39,6 +40,9 @@ class QgsGeomTypeDialog: public QDialog, private Ui::QgsGeomTypeDialogBase
protected slots:
void on_mAddAttributeButton_clicked();
void on_mRemoveAttributeButton_clicked();
void on_btnHelp_clicked();
private:
static const int context_id = 165149618;

};

Expand Down
134 changes: 72 additions & 62 deletions src/ui/qgsgeomtypedialogbase.ui
Expand Up @@ -22,51 +22,6 @@
<property name="spacing" >
<number>6</number>
</property>
<item row="4" column="0" colspan="4" >
<widget class="Q3ListView" name="mAttributeView" >
<column>
<property name="text" >
<string>Column 1</string>
</property>
</column>
</widget>
</item>
<item row="0" column="0" colspan="4" >
<widget class="QGroupBox" name="buttonGroup1" >
<property name="title" >
<string>Type</string>
</property>
<layout class="QGridLayout" >
<property name="margin" >
<number>9</number>
</property>
<property name="spacing" >
<number>6</number>
</property>
<item row="0" column="0" >
<widget class="QRadioButton" name="mPointRadioButton" >
<property name="text" >
<string>Point</string>
</property>
</widget>
</item>
<item row="0" column="1" >
<widget class="QRadioButton" name="mLineRadioButton" >
<property name="text" >
<string>Line</string>
</property>
</widget>
</item>
<item row="0" column="2" >
<widget class="QRadioButton" name="mPolygonRadioButton" >
<property name="text" >
<string>Polygon</string>
</property>
</widget>
</item>
</layout>
</widget>
</item>
<item row="5" column="0" colspan="4" >
<layout class="QHBoxLayout" >
<property name="margin" >
Expand All @@ -75,6 +30,16 @@
<property name="spacing" >
<number>6</number>
</property>
<item>
<widget class="QPushButton" name="btnHelp" >
<property name="enabled" >
<bool>true</bool>
</property>
<property name="text" >
<string>Help</string>
</property>
</widget>
</item>
<item>
<spacer>
<property name="orientation" >
Expand All @@ -85,8 +50,8 @@
</property>
<property name="sizeHint" >
<size>
<width>93</width>
<height>20</height>
<width>91</width>
<height>26</height>
</size>
</property>
</spacer>
Expand All @@ -110,17 +75,20 @@
</item>
</layout>
</item>
<item row="3" column="0" >
<widget class="QPushButton" name="mAddAttributeButton" >
<item row="1" column="0" colspan="2" >
<widget class="QLabel" name="mFileFormatLabel" >
<property name="text" >
<string>Add</string>
<string>File Format:</string>
</property>
</widget>
</item>
<item row="2" column="0" colspan="3" >
<widget class="QLabel" name="mAttributeLabel" >
<item row="1" column="2" colspan="2" >
<widget class="QComboBox" name="mFileFormatComboBox" />
</item>
<item row="3" column="1" colspan="2" >
<widget class="QPushButton" name="mRemoveAttributeButton" >
<property name="text" >
<string>Attributes:</string>
<string>Remove</string>
</property>
</widget>
</item>
Expand All @@ -140,21 +108,63 @@
</property>
</spacer>
</item>
<item row="3" column="1" colspan="2" >
<widget class="QPushButton" name="mRemoveAttributeButton" >
<item row="2" column="0" colspan="3" >
<widget class="QLabel" name="mAttributeLabel" >
<property name="text" >
<string>Remove</string>
<string>Attributes:</string>
</property>
</widget>
</item>
<item row="1" column="2" colspan="2" >
<widget class="QComboBox" name="mFileFormatComboBox" />
</item>
<item row="1" column="0" colspan="2" >
<widget class="QLabel" name="mFileFormatLabel" >
<item row="3" column="0" >
<widget class="QPushButton" name="mAddAttributeButton" >
<property name="text" >
<string>File Format:</string>
<string>Add</string>
</property>
</widget>
</item>
<item row="0" column="0" colspan="4" >
<widget class="QGroupBox" name="buttonGroup1" >
<property name="title" >
<string>Type</string>
</property>
<layout class="QGridLayout" >
<property name="margin" >
<number>9</number>
</property>
<property name="spacing" >
<number>6</number>
</property>
<item row="0" column="0" >
<widget class="QRadioButton" name="mPointRadioButton" >
<property name="text" >
<string>Point</string>
</property>
</widget>
</item>
<item row="0" column="1" >
<widget class="QRadioButton" name="mLineRadioButton" >
<property name="text" >
<string>Line</string>
</property>
</widget>
</item>
<item row="0" column="2" >
<widget class="QRadioButton" name="mPolygonRadioButton" >
<property name="text" >
<string>Polygon</string>
</property>
</widget>
</item>
</layout>
</widget>
</item>
<item row="4" column="0" colspan="4" >
<widget class="Q3ListView" name="mAttributeView" >
<column>
<property name="text" >
<string>Column 1</string>
</property>
</column>
</widget>
</item>
</layout>
Expand Down

0 comments on commit a211553

Please sign in to comment.