Skip to content

Commit e1368a7

Browse files
author
timlinux
committedJul 31, 2008
Fix for ticket #15 (Use term CRS instead of Projection throughout. Note this is a cosmetic fix only - internally class and var names still use the incorrect 'projection' nomenclature
git-svn-id: http://svn.osgeo.org/qgis/trunk@8954 c8812cc2-4d05-0410-92ff-de0c093fc19c
1 parent 5ea7430 commit e1368a7

9 files changed

+208
-358
lines changed
 

‎python/gui/qgsprojectionselector.sip

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,6 @@ class QgsProjectionSelector: QWidget //, private Ui::QgsProjectionSelectorBase
4141
*/
4242
void applyProjList(QSet<QString> * crsFilter = 0);
4343

44-
void updateProjAndEllipsoidAcronyms(int theSrsid, QString theProj4String);
4544

4645
/*!
4746
* \brief Make the string safe for use in SQL statements.

‎src/app/qgisapp.cpp

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -661,9 +661,9 @@ void QgisApp::createActions()
661661
mActionOptions->setStatusTip(tr("Change various QGIS options"));
662662
connect(mActionOptions, SIGNAL(triggered()), this, SLOT(options()));
663663
//
664-
mActionCustomProjection= new QAction(getThemeIcon("/mActionCustomProjection.png"), tr("Custom Projection..."), this);
664+
mActionCustomProjection= new QAction(getThemeIcon("/mActionCustomProjection.png"), tr("Custom CRS..."), this);
665665
// mActionCustomProjection->setShortcut(tr("Alt+I","Manage custom projections"));
666-
mActionCustomProjection->setStatusTip(tr("Manage custom projections"));
666+
mActionCustomProjection->setStatusTip(tr("Manage custom coordinate reference systems"));
667667
connect(mActionCustomProjection, SIGNAL(triggered()), this, SLOT(customProjection()));
668668
//
669669
// Help Menu Related items
@@ -1237,10 +1237,11 @@ void QgisApp::createStatusBar()
12371237
exit(0);
12381238
}
12391239
mOnTheFlyProjectionStatusButton->setWhatsThis(tr("This icon shows whether "
1240-
"on the fly projection is enabled or not. Click the icon to bring up "
1240+
"on the fly coordinate reference system transformation is enabled or not. "
1241+
"Click the icon to bring up "
12411242
"the project properties dialog to alter this behaviour."));
1242-
mOnTheFlyProjectionStatusButton->setToolTip(tr("Projection status - Click "
1243-
"to open projection dialog"));
1243+
mOnTheFlyProjectionStatusButton->setToolTip(tr("CRS status - Click "
1244+
"to open coordinate reference system dialog"));
12441245
connect(mOnTheFlyProjectionStatusButton, SIGNAL(clicked()),
12451246
this, SLOT(projectPropertiesProjections()));//bring up the project props dialog when clicked
12461247
statusBar()->addPermanentWidget(mOnTheFlyProjectionStatusButton,0);

‎src/app/qgsprojectproperties.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,6 @@ QgsProjectProperties::QgsProjectProperties(QgsMapCanvas* mapCanvas, QWidget *par
5959
bool myProjectionEnabled = myRender->projectionsEnabled();
6060
cbxProjectionEnabled->setChecked(myProjectionEnabled);
6161

62-
// set the default wkt to WGS 84
6362
long mySRSID = myRender->destinationSrs().srsid();
6463
QgsDebugMsg("Read project SRSID: " + QString::number(mySRSID));
6564
projectionSelector->setSelectedSRSID(mySRSID);

‎src/gui/qgsprojectionselector.cpp

Lines changed: 84 additions & 167 deletions
Large diffs are not rendered by default.

‎src/gui/qgsprojectionselector.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,6 @@ class GUI_EXPORT QgsProjectionSelector: public QWidget, private Ui::QgsProjectio
5252
*/
5353
void applyProjList(QSet<QString> * crsFilter = 0);
5454

55-
void updateProjAndEllipsoidAcronyms(int theSrsid, QString theProj4String);
5655

5756
/*!
5857
* \brief Make the string safe for use in SQL statements.
@@ -156,6 +155,8 @@ class GUI_EXPORT QgsProjectionSelector: public QWidget, private Ui::QgsProjectio
156155
*/
157156
long getCurrentLongAttribute(QString attributeName);
158157

158+
/** Show the user a warning if the srs database could not be found */
159+
const void showDBMissingWarning(const QString theFileName);
159160
// List view nodes for the tree view of projections
160161
//! User defined projections node
161162
QTreeWidgetItem *mUserProjList;

‎src/ui/qgscustomprojectiondialogbase.ui

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
</rect>
1111
</property>
1212
<property name="windowTitle" >
13-
<string>Custom Projection Definition</string>
13+
<string>Custom Coordinate Reference System Definition</string>
1414
</property>
1515
<property name="windowIcon" >
1616
<iconset/>
@@ -25,7 +25,7 @@
2525
<item row="0" column="0" colspan="2" >
2626
<widget class="QLabel" name="label" >
2727
<property name="text" >
28-
<string>You can define your own custom projection here. The definition must conform to the proj4 format for specifying a Spatial Reference System.</string>
28+
<string>You can define your own custom Coordinate Reference System (CRS) here. The definition must conform to the proj4 format for specifying a CRS.</string>
2929
</property>
3030
<property name="wordWrap" >
3131
<bool>true</bool>
@@ -154,7 +154,7 @@
154154
<item row="0" column="0" colspan="3" >
155155
<widget class="QLabel" name="label_2" >
156156
<property name="text" >
157-
<string>Use the text boxes below to test the projection definition you are creating. Enter a coordinate where both the lat/long and the projected result are known (for example by reading off a map). Then press the calculate button to see if the projection definition you are creating is accurate.</string>
157+
<string>Use the text boxes below to test the CRS definition you are creating. Enter a coordinate where both the lat/long and the transformed result are known (for example by reading off a map). Then press the calculate button to see if the CRS definition you are creating is accurate.</string>
158158
</property>
159159
<property name="wordWrap" >
160160
<bool>true</bool>
@@ -184,7 +184,7 @@
184184
<item row="2" column="2" >
185185
<widget class="QLabel" name="textLabel2_3" >
186186
<property name="text" >
187-
<string>Projected Coordinate System</string>
187+
<string>Destination CRS </string>
188188
</property>
189189
</widget>
190190
</item>

‎src/ui/qgsprojectionselectorbase.ui

Lines changed: 106 additions & 174 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@
55
<rect>
66
<x>0</x>
77
<y>0</y>
8-
<width>468</width>
9-
<height>428</height>
8+
<width>457</width>
9+
<height>403</height>
1010
</rect>
1111
</property>
1212
<property name="sizePolicy" >
@@ -16,216 +16,148 @@
1616
</sizepolicy>
1717
</property>
1818
<property name="windowTitle" >
19-
<string>Projection Selector</string>
19+
<string>Coordinate Reference System Selector</string>
2020
</property>
2121
<property name="windowIcon" >
2222
<iconset/>
2323
</property>
2424
<layout class="QGridLayout" >
2525
<property name="leftMargin" >
26-
<number>0</number>
26+
<number>3</number>
2727
</property>
2828
<property name="topMargin" >
29-
<number>0</number>
29+
<number>3</number>
3030
</property>
3131
<property name="rightMargin" >
32-
<number>0</number>
32+
<number>3</number>
3333
</property>
3434
<property name="bottomMargin" >
35-
<number>0</number>
36-
</property>
37-
<property name="horizontalSpacing" >
38-
<number>0</number>
39-
</property>
40-
<property name="verticalSpacing" >
41-
<number>0</number>
35+
<number>3</number>
4236
</property>
4337
<item row="0" column="0" >
44-
<widget class="QGroupBox" name="groupBox_2" >
38+
<widget class="QTreeWidget" name="lstCoordinateSystems" >
39+
<property name="alternatingRowColors" >
40+
<bool>true</bool>
41+
</property>
42+
<property name="uniformRowHeights" >
43+
<bool>true</bool>
44+
</property>
45+
<property name="columnCount" >
46+
<number>3</number>
47+
</property>
48+
<column>
49+
<property name="text" >
50+
<string>Coordinate Reference System</string>
51+
</property>
52+
</column>
53+
<column>
54+
<property name="text" >
55+
<string>EPSG</string>
56+
</property>
57+
</column>
58+
<column>
59+
<property name="text" >
60+
<string>ID</string>
61+
</property>
62+
</column>
63+
</widget>
64+
</item>
65+
<item row="1" column="0" >
66+
<widget class="QTextEdit" name="teProjection" >
4567
<property name="sizePolicy" >
4668
<sizepolicy vsizetype="Expanding" hsizetype="Expanding" >
4769
<horstretch>0</horstretch>
4870
<verstretch>0</verstretch>
4971
</sizepolicy>
5072
</property>
73+
<property name="minimumSize" >
74+
<size>
75+
<width>0</width>
76+
<height>100</height>
77+
</size>
78+
</property>
79+
<property name="maximumSize" >
80+
<size>
81+
<width>16777215</width>
82+
<height>100</height>
83+
</size>
84+
</property>
85+
<property name="autoFormatting" >
86+
<set>QTextEdit::AutoBulletList</set>
87+
</property>
88+
<property name="readOnly" >
89+
<bool>true</bool>
90+
</property>
91+
</widget>
92+
</item>
93+
<item row="2" column="0" >
94+
<widget class="QGroupBox" name="groupBox" >
95+
<property name="sizePolicy" >
96+
<sizepolicy vsizetype="Minimum" hsizetype="MinimumExpanding" >
97+
<horstretch>0</horstretch>
98+
<verstretch>0</verstretch>
99+
</sizepolicy>
100+
</property>
51101
<property name="title" >
52-
<string>Projection</string>
102+
<string>Search</string>
53103
</property>
54104
<layout class="QGridLayout" >
55-
<property name="leftMargin" >
56-
<number>12</number>
57-
</property>
58-
<property name="topMargin" >
59-
<number>12</number>
60-
</property>
61-
<property name="rightMargin" >
62-
<number>12</number>
63-
</property>
64-
<property name="bottomMargin" >
65-
<number>12</number>
66-
</property>
67-
<property name="horizontalSpacing" >
68-
<number>0</number>
69-
</property>
70-
<property name="verticalSpacing" >
71-
<number>0</number>
72-
</property>
73-
<item row="2" column="0" >
74-
<widget class="QGroupBox" name="groupBox" >
75-
<property name="sizePolicy" >
76-
<sizepolicy vsizetype="Minimum" hsizetype="MinimumExpanding" >
77-
<horstretch>0</horstretch>
78-
<verstretch>0</verstretch>
79-
</sizepolicy>
105+
<item row="0" column="0" >
106+
<widget class="QRadioButton" name="radEPSGID" >
107+
<property name="text" >
108+
<string>EPSG ID</string>
80109
</property>
81-
<property name="title" >
82-
<string>Search</string>
110+
<property name="iconSize" >
111+
<size>
112+
<width>16</width>
113+
<height>10</height>
114+
</size>
83115
</property>
84-
<layout class="QGridLayout" >
85-
<property name="leftMargin" >
86-
<number>2</number>
87-
</property>
88-
<property name="topMargin" >
89-
<number>2</number>
90-
</property>
91-
<property name="rightMargin" >
92-
<number>2</number>
93-
</property>
94-
<property name="bottomMargin" >
95-
<number>2</number>
96-
</property>
97-
<property name="horizontalSpacing" >
98-
<number>3</number>
99-
</property>
100-
<property name="verticalSpacing" >
101-
<number>3</number>
102-
</property>
103-
<item row="1" column="3" >
104-
<widget class="QPushButton" name="pbnFind" >
105-
<property name="maximumSize" >
106-
<size>
107-
<width>100</width>
108-
<height>16777215</height>
109-
</size>
110-
</property>
111-
<property name="text" >
112-
<string>Find</string>
113-
</property>
114-
<property name="default" >
115-
<bool>true</bool>
116-
</property>
117-
</widget>
118-
</item>
119-
<item row="1" column="0" colspan="3" >
120-
<widget class="QLineEdit" name="leSearch" />
121-
</item>
122-
<item row="0" column="3" >
123-
<widget class="QRadioButton" name="radName" >
124-
<property name="text" >
125-
<string>Name</string>
126-
</property>
127-
<property name="iconSize" >
128-
<size>
129-
<width>16</width>
130-
<height>10</height>
131-
</size>
132-
</property>
133-
</widget>
134-
</item>
135-
<item row="0" column="2" >
136-
<widget class="QRadioButton" name="radSRSID" >
137-
<property name="text" >
138-
<string>QGIS SRSID</string>
139-
</property>
140-
<property name="iconSize" >
141-
<size>
142-
<width>16</width>
143-
<height>10</height>
144-
</size>
145-
</property>
146-
</widget>
147-
</item>
148-
<item row="0" column="1" >
149-
<widget class="QRadioButton" name="radEPSGID" >
150-
<property name="text" >
151-
<string>EPSG ID</string>
152-
</property>
153-
<property name="iconSize" >
154-
<size>
155-
<width>16</width>
156-
<height>10</height>
157-
</size>
158-
</property>
159-
</widget>
160-
</item>
161-
<item row="0" column="0" >
162-
<widget class="QRadioButton" name="radSRID" >
163-
<property name="text" >
164-
<string>Postgis SRID</string>
165-
</property>
166-
<property name="iconSize" >
167-
<size>
168-
<width>16</width>
169-
<height>10</height>
170-
</size>
171-
</property>
172-
<property name="checked" >
173-
<bool>true</bool>
174-
</property>
175-
</widget>
176-
</item>
177-
</layout>
178116
</widget>
179117
</item>
180-
<item row="1" column="0" >
181-
<widget class="QTextEdit" name="teProjection" >
182-
<property name="sizePolicy" >
183-
<sizepolicy vsizetype="Expanding" hsizetype="Expanding" >
184-
<horstretch>0</horstretch>
185-
<verstretch>0</verstretch>
186-
</sizepolicy>
118+
<item row="0" column="1" >
119+
<widget class="QRadioButton" name="radName" >
120+
<property name="text" >
121+
<string>Name</string>
187122
</property>
188-
<property name="minimumSize" >
123+
<property name="iconSize" >
189124
<size>
190-
<width>0</width>
191-
<height>100</height>
125+
<width>16</width>
126+
<height>10</height>
192127
</size>
193128
</property>
194-
<property name="maximumSize" >
129+
</widget>
130+
</item>
131+
<item row="0" column="2" colspan="2" >
132+
<spacer>
133+
<property name="orientation" >
134+
<enum>Qt::Horizontal</enum>
135+
</property>
136+
<property name="sizeHint" >
195137
<size>
196-
<width>16777215</width>
197-
<height>100</height>
138+
<width>231</width>
139+
<height>20</height>
198140
</size>
199141
</property>
200-
<property name="autoFormatting" >
201-
<set>QTextEdit::AutoBulletList</set>
202-
</property>
203-
<property name="readOnly" >
204-
<bool>true</bool>
205-
</property>
206-
</widget>
142+
</spacer>
207143
</item>
208-
<item row="0" column="0" >
209-
<widget class="QTreeWidget" name="lstCoordinateSystems" >
210-
<property name="alternatingRowColors" >
211-
<bool>true</bool>
144+
<item row="1" column="0" colspan="3" >
145+
<widget class="QLineEdit" name="leSearch" />
146+
</item>
147+
<item row="1" column="3" >
148+
<widget class="QPushButton" name="pbnFind" >
149+
<property name="maximumSize" >
150+
<size>
151+
<width>100</width>
152+
<height>16777215</height>
153+
</size>
212154
</property>
213-
<property name="uniformRowHeights" >
214-
<bool>true</bool>
155+
<property name="text" >
156+
<string>Find</string>
215157
</property>
216-
<property name="columnCount" >
217-
<number>2</number>
158+
<property name="default" >
159+
<bool>true</bool>
218160
</property>
219-
<column>
220-
<property name="text" >
221-
<string>Spatial Reference System</string>
222-
</property>
223-
</column>
224-
<column>
225-
<property name="text" >
226-
<string>Id</string>
227-
</property>
228-
</column>
229161
</widget>
230162
</item>
231163
</layout>

‎src/ui/qgsprojectpropertiesbase.ui

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -279,25 +279,25 @@
279279
</widget>
280280
<widget class="QWidget" name="tab2" >
281281
<attribute name="title" >
282-
<string>Projection</string>
282+
<string>Coordinate Reference System (CRS)</string>
283283
</attribute>
284284
<layout class="QGridLayout" >
285285
<property name="leftMargin" >
286-
<number>11</number>
286+
<number>3</number>
287287
</property>
288288
<property name="topMargin" >
289289
<number>11</number>
290290
</property>
291291
<property name="rightMargin" >
292-
<number>11</number>
292+
<number>3</number>
293293
</property>
294294
<property name="bottomMargin" >
295295
<number>11</number>
296296
</property>
297297
<item row="0" column="0" >
298298
<widget class="QCheckBox" name="cbxProjectionEnabled" >
299299
<property name="text" >
300-
<string>Enable on the fly projection</string>
300+
<string>Enable 'on the fly' CRS transformation</string>
301301
</property>
302302
</widget>
303303
</item>

‎tests/src/core/qgsrenderchecker.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,8 @@ bool QgsRenderChecker::runTest( QString theTestName )
5656
QImage myImage( myExpectedImage.width() , myExpectedImage.height(), QImage::Format_RGB32 );
5757
myImage.fill ( qRgb( 152,219,249 ) );
5858
QPainter myPainter( &myImage );
59-
mpMapRenderer->setOutputSize( QSize ( myExpectedImage.width(),myExpectedImage.height() ),72 );
59+
mpMapRenderer->setOutputSize( QSize (
60+
myExpectedImage.width(),myExpectedImage.height() ),myExpectedImage.logicalDpiX() );
6061
QTime myTime;
6162
myTime.start();
6263
mpMapRenderer->render( &myPainter );

0 commit comments

Comments
 (0)
Please sign in to comment.