Skip to content

Commit e88f90b

Browse files
author
gsherman
committedJan 15, 2006
Added help button and wired context help for the new vector layer dialog
git-svn-id: http://svn.osgeo.org/qgis/trunk@4695 c8812cc2-4d05-0410-92ff-de0c093fc19c
1 parent 241f207 commit e88f90b

File tree

3 files changed

+80
-62
lines changed

3 files changed

+80
-62
lines changed
 

‎src/gui/qgsgeomtypedialog.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,10 @@ void QgsGeomTypeDialog::on_mRemoveAttributeButton_clicked()
8585

8686
}
8787

88+
void QgsGeomTypeDialog::on_btnHelp_clicked()
89+
{
90+
QgsContextHelp::run(context_id);
91+
}
8892
void QgsGeomTypeDialog::attributes(std::list<std::pair<QString, QString> >& at) const
8993
{
9094
Q3ListViewItemIterator it(mAttributeView);

‎src/gui/qgsgeomtypedialog.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919
#define QGSGEOMTYPEDIALOG_H
2020

2121
#include "ui_qgsgeomtypedialogbase.h"
22+
#include "qgscontexthelp.h"
2223
#include <QDialog>
2324

2425
#include "qgis.h"
@@ -39,6 +40,9 @@ class QgsGeomTypeDialog: public QDialog, private Ui::QgsGeomTypeDialogBase
3940
protected slots:
4041
void on_mAddAttributeButton_clicked();
4142
void on_mRemoveAttributeButton_clicked();
43+
void on_btnHelp_clicked();
44+
private:
45+
static const int context_id = 165149618;
4246

4347
};
4448

‎src/ui/qgsgeomtypedialogbase.ui

Lines changed: 72 additions & 62 deletions
Original file line numberDiff line numberDiff line change
@@ -22,51 +22,6 @@
2222
<property name="spacing" >
2323
<number>6</number>
2424
</property>
25-
<item row="4" column="0" colspan="4" >
26-
<widget class="Q3ListView" name="mAttributeView" >
27-
<column>
28-
<property name="text" >
29-
<string>Column 1</string>
30-
</property>
31-
</column>
32-
</widget>
33-
</item>
34-
<item row="0" column="0" colspan="4" >
35-
<widget class="QGroupBox" name="buttonGroup1" >
36-
<property name="title" >
37-
<string>Type</string>
38-
</property>
39-
<layout class="QGridLayout" >
40-
<property name="margin" >
41-
<number>9</number>
42-
</property>
43-
<property name="spacing" >
44-
<number>6</number>
45-
</property>
46-
<item row="0" column="0" >
47-
<widget class="QRadioButton" name="mPointRadioButton" >
48-
<property name="text" >
49-
<string>Point</string>
50-
</property>
51-
</widget>
52-
</item>
53-
<item row="0" column="1" >
54-
<widget class="QRadioButton" name="mLineRadioButton" >
55-
<property name="text" >
56-
<string>Line</string>
57-
</property>
58-
</widget>
59-
</item>
60-
<item row="0" column="2" >
61-
<widget class="QRadioButton" name="mPolygonRadioButton" >
62-
<property name="text" >
63-
<string>Polygon</string>
64-
</property>
65-
</widget>
66-
</item>
67-
</layout>
68-
</widget>
69-
</item>
7025
<item row="5" column="0" colspan="4" >
7126
<layout class="QHBoxLayout" >
7227
<property name="margin" >
@@ -75,6 +30,16 @@
7530
<property name="spacing" >
7631
<number>6</number>
7732
</property>
33+
<item>
34+
<widget class="QPushButton" name="btnHelp" >
35+
<property name="enabled" >
36+
<bool>true</bool>
37+
</property>
38+
<property name="text" >
39+
<string>Help</string>
40+
</property>
41+
</widget>
42+
</item>
7843
<item>
7944
<spacer>
8045
<property name="orientation" >
@@ -85,8 +50,8 @@
8550
</property>
8651
<property name="sizeHint" >
8752
<size>
88-
<width>93</width>
89-
<height>20</height>
53+
<width>91</width>
54+
<height>26</height>
9055
</size>
9156
</property>
9257
</spacer>
@@ -110,17 +75,20 @@
11075
</item>
11176
</layout>
11277
</item>
113-
<item row="3" column="0" >
114-
<widget class="QPushButton" name="mAddAttributeButton" >
78+
<item row="1" column="0" colspan="2" >
79+
<widget class="QLabel" name="mFileFormatLabel" >
11580
<property name="text" >
116-
<string>Add</string>
81+
<string>File Format:</string>
11782
</property>
11883
</widget>
11984
</item>
120-
<item row="2" column="0" colspan="3" >
121-
<widget class="QLabel" name="mAttributeLabel" >
85+
<item row="1" column="2" colspan="2" >
86+
<widget class="QComboBox" name="mFileFormatComboBox" />
87+
</item>
88+
<item row="3" column="1" colspan="2" >
89+
<widget class="QPushButton" name="mRemoveAttributeButton" >
12290
<property name="text" >
123-
<string>Attributes:</string>
91+
<string>Remove</string>
12492
</property>
12593
</widget>
12694
</item>
@@ -140,21 +108,63 @@
140108
</property>
141109
</spacer>
142110
</item>
143-
<item row="3" column="1" colspan="2" >
144-
<widget class="QPushButton" name="mRemoveAttributeButton" >
111+
<item row="2" column="0" colspan="3" >
112+
<widget class="QLabel" name="mAttributeLabel" >
145113
<property name="text" >
146-
<string>Remove</string>
114+
<string>Attributes:</string>
147115
</property>
148116
</widget>
149117
</item>
150-
<item row="1" column="2" colspan="2" >
151-
<widget class="QComboBox" name="mFileFormatComboBox" />
152-
</item>
153-
<item row="1" column="0" colspan="2" >
154-
<widget class="QLabel" name="mFileFormatLabel" >
118+
<item row="3" column="0" >
119+
<widget class="QPushButton" name="mAddAttributeButton" >
155120
<property name="text" >
156-
<string>File Format:</string>
121+
<string>Add</string>
122+
</property>
123+
</widget>
124+
</item>
125+
<item row="0" column="0" colspan="4" >
126+
<widget class="QGroupBox" name="buttonGroup1" >
127+
<property name="title" >
128+
<string>Type</string>
157129
</property>
130+
<layout class="QGridLayout" >
131+
<property name="margin" >
132+
<number>9</number>
133+
</property>
134+
<property name="spacing" >
135+
<number>6</number>
136+
</property>
137+
<item row="0" column="0" >
138+
<widget class="QRadioButton" name="mPointRadioButton" >
139+
<property name="text" >
140+
<string>Point</string>
141+
</property>
142+
</widget>
143+
</item>
144+
<item row="0" column="1" >
145+
<widget class="QRadioButton" name="mLineRadioButton" >
146+
<property name="text" >
147+
<string>Line</string>
148+
</property>
149+
</widget>
150+
</item>
151+
<item row="0" column="2" >
152+
<widget class="QRadioButton" name="mPolygonRadioButton" >
153+
<property name="text" >
154+
<string>Polygon</string>
155+
</property>
156+
</widget>
157+
</item>
158+
</layout>
159+
</widget>
160+
</item>
161+
<item row="4" column="0" colspan="4" >
162+
<widget class="Q3ListView" name="mAttributeView" >
163+
<column>
164+
<property name="text" >
165+
<string>Column 1</string>
166+
</property>
167+
</column>
158168
</widget>
159169
</item>
160170
</layout>

0 commit comments

Comments
 (0)
Please sign in to comment.