Skip to content

Commit

Permalink
Text string made easier to translate in georeferencer.
Browse files Browse the repository at this point in the history
git-svn-id: http://svn.osgeo.org/qgis/trunk@11181 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
homann committed Jul 27, 2009
1 parent a99fb37 commit 4b0fbff
Show file tree
Hide file tree
Showing 6 changed files with 16 additions and 17 deletions.
4 changes: 2 additions & 2 deletions src/plugins/georeferencer/CMakeLists.txt
Expand Up @@ -2,7 +2,7 @@
# Files

SET (GEOREF_SRCS
plugin.cpp
qgsgeorefplugin.cpp
qgsgeorefdatapoint.cpp
qgsimagewarper.cpp
qgsleastsquares.cpp
Expand All @@ -20,7 +20,7 @@ SET (GEOREF_UIS
)

SET (GEOREF_MOC_HDRS
plugin.h
qgsgeorefplugin.h
qgspointdialog.h
mapcoordsdialog.h
qgsgeorefwarpoptionsdialog.h
Expand Down
9 changes: 9 additions & 0 deletions src/plugins/georeferencer/qgsgeorefdescriptiondialog.cpp
Expand Up @@ -20,4 +20,13 @@
QgsGeorefDescriptionDialog::QgsGeorefDescriptionDialog( QWidget* parent ): QDialog( parent )
{
setupUi( this );

textEdit->setText("<h2>Description</h2>"
"<p>This plugin can generate world files "
"for rasters. You select points on the "
"raster and give their world "
"coordinates, and the plugin will "
"compute the world file parameters. "
"The more coordinates you can "
"provide the better the result will be.</p>");
}
8 changes: 0 additions & 8 deletions src/plugins/georeferencer/qgsgeorefdescriptiondialogbase.ui
Expand Up @@ -13,7 +13,6 @@
<string>Description georeferencer</string>
</property>
<property name="windowIcon" >
<iconset resource="georeferencer.qrc" >:/georeferencer.png</iconset>
</property>
<property name="modal" >
<bool>true</bool>
Expand All @@ -40,13 +39,6 @@
<property name="readOnly" >
<bool>true</bool>
</property>
<property name="html" >
<string>&lt;html>&lt;head>&lt;meta name="qrichtext" content="1" />&lt;style type="text/css">
p, li { white-space: pre-wrap; }
&lt;/style>&lt;/head>&lt;body style=" font-family:'Sans Serif'; font-size:12pt; font-weight:400; font-style:normal; text-decoration:none;">
&lt;p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">&lt;span style=" font-size:11pt; font-weight:600;">Description&lt;/span>&lt;/p>
&lt;p style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;">This plugin can generate world files for rasters. You select points on the raster and give their world coordinates, and the plugin will compute the world file parameters. The more coordinates you can provide the better the result will be.&lt;/p>&lt;/body>&lt;/html></string>
</property>
</widget>
</item>
<item row="0" column="0" >
Expand Down
9 changes: 3 additions & 6 deletions src/plugins/georeferencer/qgsleastsquares.cpp
Expand Up @@ -30,8 +30,7 @@ void QgsLeastSquares::linear( std::vector<QgsPoint> mapCoords,
int n = mapCoords.size();
if ( n < 2 )
{
throw std::domain_error( QObject::tr( "Fit to a linear transform requires at "
"least 2 points." ).toLocal8Bit().constData() );
throw std::domain_error( QObject::tr( "Fit to a linear transform requires at least 2 points." ).toLocal8Bit().constData() );
}

double sumPx( 0 ), sumPy( 0 ), sumPx2( 0 ), sumPy2( 0 ), sumPxMx( 0 ), sumPyMy( 0 ),
Expand Down Expand Up @@ -72,8 +71,7 @@ void QgsLeastSquares::helmert( std::vector<QgsPoint> mapCoords,
int n = mapCoords.size();
if ( n < 2 )
{
throw std::domain_error( QObject::tr( "Fit to a Helmert transform requires at "
"least 2 points." ).toLocal8Bit().constData() );
throw std::domain_error( QObject::tr( "Fit to a Helmert transform requires at least 2 points." ).toLocal8Bit().constData() );
}

double A = 0, B = 0, C = 0, D = 0, E = 0, F = 0, G = 0, H = 0, I = 0, J = 0;
Expand Down Expand Up @@ -128,8 +126,7 @@ void QgsLeastSquares::affine( std::vector<QgsPoint> mapCoords,
int n = mapCoords.size();
if ( n < 4 )
{
throw std::domain_error( QObject::tr( "Fit to an affine transform requires at "
"least 4 points." ).toLocal8Bit().constData() );
throw std::domain_error( QObject::tr( "Fit to an affine transform requires at least 4 points." ).toLocal8Bit().constData() );
}

double A = 0, B = 0, C = 0, D = 0, E = 0, F = 0,
Expand Down
1 change: 1 addition & 0 deletions src/plugins/georeferencer/qgspointdialog.h
Expand Up @@ -76,6 +76,7 @@ class QgsPointDialog : public QDialog, private Ui::QgsPointDialogBase
QString guessWorldFileName( const QString& raster );

void enableModifiedRasterControls( bool state );
void enableControls(bool state);
QIcon getThemeIcon( const QString theName );

QActionGroup* mMapToolGroup;
Expand Down
2 changes: 1 addition & 1 deletion src/plugins/georeferencer/qgspointdialogbase.ui
Expand Up @@ -312,7 +312,7 @@
</widget>
</item>
<item row="3" column="0" >
<widget class="QLabel" name="textLabel1" >
<widget class="QLabel" name="lblSelectWorldFile" >
<property name="text" >
<string>World file:</string>
</property>
Expand Down

0 comments on commit 4b0fbff

Please sign in to comment.