Commit 0b6e05df authored by Jan Möbius's avatar Jan Möbius

Translations

git-svn-id: http://www.openflipper.org/svnrepo/OpenFlipper/branches/Free@6754 383ad7c9-94d9-4d36-a494-682f7c89f535
parent 3d81fcb5
include (plugin)
openflipper_plugin ()
openflipper_plugin ( TRANSLATION_LANGUAGES de_DE )
......@@ -34,7 +34,7 @@
/*===========================================================================*\
* *
* $Revision$ *
* $Revision$ *
* $Author$ *
* $Date$ *
* *
......@@ -94,26 +94,26 @@ void InfoPlugin::printMeshInfo( MeshT* _mesh , int _id, unsigned int _face ) {
int closest_e_idx = getClosestEdge(_mesh, _face);
// ID
info_->id->setText( "<B>Object ID:</B> " + locale.toString(_id) );
info_->id->setText( tr("<B>Object ID:</B> ") + locale.toString(_id) );
// Vertices
info_->vertices->setText( "<B>Vertices:</B> " + locale.toString( _mesh->n_vertices() ) );
info_->vertices->setText( tr("<B>Vertices:</B> ") + locale.toString( _mesh->n_vertices() ) );
// Faces
info_->faces->setText( "<B>Faces:</B> " + locale.toString( _mesh->n_faces() ) );
info_->faces->setText( tr("<B>Faces:</B> ") + locale.toString( _mesh->n_faces() ) );
// Edges
info_->edges->setText( "<B>Edges:</B> " + locale.toString( _mesh->n_edges() ) );
info_->edges->setText( tr("<B>Edges:</B> ") + locale.toString( _mesh->n_edges() ) );
// Closest Vertex
info_->closestv->setText( "<B>Closest vertex:</B> " + locale.toString( closest_v_idx ) );
info_->closestv->setText( tr("<B>Closest vertex:</B> ") + locale.toString( closest_v_idx ) );
// Closest Edge
info_->closeste->setText( "<B>Closest edge:</B> " + locale.toString( closest_e_idx ) );
info_->closeste->setText( tr("<B>Closest edge:</B> ") + locale.toString( closest_e_idx ) );
// Picked Vertex
info_->pickedFace->setText( "<B>Picked face:</B> " + locale.toString( _face ) );
info_->pickedFace->setText( tr("<B>Picked face:</B> ") + locale.toString( _face ) );
// Components
info_->components->setText( "<B>Components:</B> " + locale.toString(MeshInfo::componentCount(_mesh)));
info_->components->setText( tr("<B>Components:</B> ") + locale.toString(MeshInfo::componentCount(_mesh)));
// Boundaries
info_->boundaries->setText( "<B>Boundaries:</B> " + locale.toString(MeshInfo::boundaryCount(_mesh)) );
info_->boundaries->setText( tr("<B>Boundaries:</B> ") + locale.toString(MeshInfo::boundaryCount(_mesh)) );
// Genus
int genus = 1 - (_mesh->n_vertices() - _mesh->n_edges() + _mesh->n_faces() ) / 2;
info_->genus->setText( "<B>Genus:</B> " + QString::number(genus) );
info_->genus->setText( tr("<B>Genus:</B> ") + QString::number(genus) );
info_->table->clear();
......@@ -122,27 +122,27 @@ void InfoPlugin::printMeshInfo( MeshT* _mesh , int _id, unsigned int _face ) {
QStringList headerdata;
headerdata << "Min" << "Mean" << "Max";
headerdata << tr("Min") << tr("Mean") << tr("Max");
info_->table->setHorizontalHeaderLabels(headerdata);
headerdata.clear();
headerdata << "X Coordinate" << "Y Coordinate" << "Z Coordinate" << "Vertex Valence" << "Edge Length" << "Aspect Ratio";
headerdata << "Inner Face Angles" << "Dihedral Angles";
headerdata << tr("X Coordinate") << tr("Y Coordinate") << tr("Z Coordinate") << tr("Vertex Valence") << tr("Edge Length") << tr("Aspect Ratio");
headerdata << tr("Inner Face Angles") << tr("Dihedral Angles");
info_->table->setVerticalHeaderLabels(headerdata);
//set tooltips
info_->table->verticalHeaderItem(0)->setToolTip("minimum, maximum and arithmetic mean of the vertex x-coordinates");
info_->table->verticalHeaderItem(1)->setToolTip("minimum, maximum and arithmetic mean of the vertex y-coordinates");
info_->table->verticalHeaderItem(2)->setToolTip("minimum, maximum and arithmetic mean of the vertex z-coordinates");
info_->table->verticalHeaderItem(3)->setToolTip("minimum, maximum and arithmetic mean of the vertex valences");
info_->table->verticalHeaderItem(4)->setToolTip("minimum, maximum and arithmetic mean of the edge lengthes");
info_->table->verticalHeaderItem(5)->setToolTip("minimum, maximum and arithmetic mean of the aspect ratio."
" i.e. the ratio between longest and shortest edge in a triangle.");
info_->table->verticalHeaderItem(6)->setToolTip("minimum, maximum and arithmetic mean of the inner angles in a face.");
info_->table->verticalHeaderItem(7)->setToolTip("minimum, maximum and arithmetic mean of the dihedral angles"
" i.e. the angles between neighboring faces.");
info_->table->verticalHeaderItem(0)->setToolTip(tr("minimum, maximum and arithmetic mean of the vertex x-coordinates"));
info_->table->verticalHeaderItem(1)->setToolTip(tr("minimum, maximum and arithmetic mean of the vertex y-coordinates"));
info_->table->verticalHeaderItem(2)->setToolTip(tr("minimum, maximum and arithmetic mean of the vertex z-coordinates"));
info_->table->verticalHeaderItem(3)->setToolTip(tr("minimum, maximum and arithmetic mean of the vertex valences"));
info_->table->verticalHeaderItem(4)->setToolTip(tr("minimum, maximum and arithmetic mean of the edge lengthes"));
info_->table->verticalHeaderItem(5)->setToolTip(tr("minimum, maximum and arithmetic mean of the aspect ratio."
" i.e. the ratio between longest and shortest edge in a triangle."));
info_->table->verticalHeaderItem(6)->setToolTip(tr("minimum, maximum and arithmetic mean of the inner angles in a face."));
info_->table->verticalHeaderItem(7)->setToolTip(tr("minimum, maximum and arithmetic mean of the dihedral angles"
" i.e. the angles between neighboring faces."));
// Coordinates
typename MeshT::VertexIter v_it;
......@@ -318,13 +318,13 @@ void InfoPlugin::printMeshInfo( MeshT* _mesh , int _id, unsigned int _face ) {
typename MeshT::FaceHandle fh = _mesh->face_handle(_face);
headerdata.clear();
headerdata << "Bounding Box (Minimum)" << "Bounding Box (Maximum)" << "BoundingBox (Size)" << "Center of Gravity";
headerdata << "Picked Face Normal (Handle "+ QString::number(fh.idx()) +")";
headerdata << tr("Bounding Box (Minimum)") << tr("Bounding Box (Maximum)") << tr("BoundingBox (Size)") << tr("Center of Gravity");
headerdata << tr("Picked Face Normal (Handle %1 )" ).arg(fh.idx());
typename MeshT::FaceVertexIter fv_it = _mesh->fv_iter(fh);
int vertexCount = 0;
while( fv_it ){
headerdata << "Adjacent Vertex (Handle " + QString::number(fv_it.handle().idx()) + ")";
headerdata << tr("Adjacent Vertex (Handle %1 )").arg(fv_it.handle().idx());
++fv_it;
vertexCount++;
}
......@@ -333,13 +333,13 @@ void InfoPlugin::printMeshInfo( MeshT* _mesh , int _id, unsigned int _face ) {
info_->table3->setVerticalHeaderLabels(headerdata);
//set tooltips
info_->table3->verticalHeaderItem(0)->setToolTip("minimum corner coordinates of the bounding box");
info_->table3->verticalHeaderItem(1)->setToolTip("maximum corner coordinates of the bounding box");
info_->table3->verticalHeaderItem(2)->setToolTip("diagonal size of the bounding box");
info_->table3->verticalHeaderItem(3)->setToolTip("coordinates of the center of gravity");
info_->table3->verticalHeaderItem(4)->setToolTip("direction of the face normal that was picked");
info_->table3->verticalHeaderItem(0)->setToolTip(tr("minimum corner coordinates of the bounding box"));
info_->table3->verticalHeaderItem(1)->setToolTip(tr("maximum corner coordinates of the bounding box"));
info_->table3->verticalHeaderItem(2)->setToolTip(tr("diagonal size of the bounding box"));
info_->table3->verticalHeaderItem(3)->setToolTip(tr("coordinates of the center of gravity"));
info_->table3->verticalHeaderItem(4)->setToolTip(tr("direction of the face normal that was picked"));
for (int i=0; i < vertexCount; i++)
info_->table3->verticalHeaderItem(5 + i)->setToolTip("Coordinates of a vertex which is adjacent to the picked face");
info_->table3->verticalHeaderItem(5 + i)->setToolTip(tr("Coordinates of a vertex which is adjacent to the picked face"));
//Calculate Bounding Box(min,max,cog)
ACG::Vec3d min;
......@@ -543,7 +543,7 @@ bool InfoPlugin::getEdgeLengths(int _id, double &min, double &max, double &mean)
return false;
if ( object == 0){
emit log(LOGERR, "Unable to get object");
emit log(LOGERR, tr("Unable to get object"));
return false;
}
......@@ -551,7 +551,7 @@ bool InfoPlugin::getEdgeLengths(int _id, double &min, double &max, double &mean)
TriMesh* mesh = PluginFunctions::triMesh(object);
if ( mesh == 0 ) {
emit log(LOGERR,"Unable to get mesh");
emit log(LOGERR,tr("Unable to get mesh"));
return false;
}
......@@ -562,7 +562,7 @@ bool InfoPlugin::getEdgeLengths(int _id, double &min, double &max, double &mean)
PolyMesh* mesh = PluginFunctions::polyMesh(object);
if ( mesh == 0 ) {
emit log(LOGERR,"Unable to get mesh");
emit log(LOGERR,tr("Unable to get mesh"));
return false;
}
......
......@@ -34,7 +34,7 @@
/*===========================================================================*\
* *
* $Revision$ *
* $Revision$ *
* $Author$ *
* $Date$ *
* *
......@@ -106,7 +106,7 @@ class InfoPlugin : public QObject, BaseInterface, MouseInterface, LoggingInterfa
QString name(){ return (QString("Info")); };
/// Description of the Plugin
QString description() { return (QString("Providing Information about Objects")); };
QString description() { return (QString(tr("Providing Information about Objects"))); };
private :
InfoDialog* info_;
......
......@@ -54,61 +54,61 @@
*/
void InfoPlugin::setDescriptions(){
emit setSlotDescription("vertexCount(int)","get total number of vertices for a given object",
QStringList("objectID"), QStringList("id of an object"));
emit setSlotDescription("vertexCount(int)",tr("get total number of vertices for a given object"),
QStringList(tr("objectID")), QStringList(tr("id of an object")));
emit setSlotDescription("edgeCount(int)","get total number of edges for a given object",
QStringList("objectID"), QStringList("id of an object"));
emit setSlotDescription("edgeCount(int)",tr("get total number of edges for a given object"),
QStringList(tr("objectID")), QStringList(tr("id of an object")));
emit setSlotDescription("faceCount(int)","get total number of faces for a given object",
QStringList("objectID"), QStringList("id of an object"));
emit setSlotDescription("faceCount(int)",tr("get total number of faces for a given object"),
QStringList(tr("objectID")), QStringList(tr("id of an object")));
emit setSlotDescription("boundaryCount(int)","get number of boundaries for a given object",
QStringList("objectID"), QStringList("id of an object"));
emit setSlotDescription("boundaryCount(int)",tr("get number of boundaries for a given object"),
QStringList(tr("objectID")), QStringList(tr("id of an object")));
emit setSlotDescription("componentCount(int)","get number of components for a given object",
QStringList("objectID"), QStringList("id of an object"));
emit setSlotDescription("componentCount(int)",tr("get number of components for a given object"),
QStringList(tr("objectID")), QStringList(tr("id of an object")));
emit setSlotDescription("genus(int)","get the genus of a given object",
QStringList("objectID"), QStringList("id of an object"));
emit setSlotDescription("genus(int)",tr("get the genus of a given object"),
QStringList(tr("objectID")), QStringList(tr("id of an object")));
emit setSlotDescription("cog(int)","get the center of gravity for a given object",
QStringList("objectID"), QStringList("id of an object"));
emit setSlotDescription("cog(int)",tr("get the center of gravity for a given object"),
QStringList(tr("objectID")), QStringList(tr("id of an object")));
emit setSlotDescription("boundingBoxMin(int)","get minimum point of the axis-aligned bounding box",
QStringList("objectID"), QStringList("id of an object"));
emit setSlotDescription("boundingBoxMin(int)",tr("get minimum point of the axis-aligned bounding box"),
QStringList(tr("objectID")), QStringList(tr("id of an object")));
emit setSlotDescription("boundingBoxMax(int)","get maximum point of the axis-aligned bounding box",
QStringList("objectID"), QStringList("id of an object"));
emit setSlotDescription("boundingBoxMax(int)",tr("get maximum point of the axis-aligned bounding box"),
QStringList(tr("objectID")), QStringList(tr("id of an object")));
emit setSlotDescription("boundingBoxSize(int)","get the size of the axis-aligned bounding box",
QStringList("objectID"), QStringList("id of an object"));
emit setSlotDescription("boundingBoxSize(int)",tr("get the size of the axis-aligned bounding box"),
QStringList(tr("objectID")), QStringList(tr("id of an object")));
emit setSlotDescription("edgeLength(int,int)","Get the length of an edge",
QString("ObjectId,EdgeHandle").split(","),
QString("id of the object, handle of an edge").split(","));
emit setSlotDescription("edgeLength(int,int)",tr("Get the length of an edge"),
QString(tr("ObjectId,EdgeHandle")).split(","),
QString(tr("id of the object, handle of an edge")).split(","));
emit setSlotDescription("faceArea(int,int)","Get the area of a face",
QString("ObjectId,FaceHandle").split(","),
QString("id of the object, handle of a face").split(","));
emit setSlotDescription("faceArea(int,int)",tr("Get the area of a face"),
QString(tr("ObjectId,FaceHandle")).split(","),
QString(tr("id of the object, handle of a face")).split(","));
emit setSlotDescription("aspectRatio(int,int)","Get the aspect ratio of a face",
QString("ObjectId,FaceHandle").split(","),
QString("id of the object, handle of a face").split(","));
emit setSlotDescription("aspectRatio(int,int)",tr("Get the aspect ratio of a face"),
QString(tr("ObjectId,FaceHandle")).split(","),
QString(tr("id of the object, handle of a face")).split(","));
emit setSlotDescription("vertexValence(int,int)","Get the valence of a vertex",
QString("ObjectId,VertexHandle").split(","),
QString("id of the object, handle of a vertex").split(","));
emit setSlotDescription("vertexValence(int,int)",tr("Get the valence of a vertex"),
QString(tr("ObjectId,VertexHandle")).split(","),
QString(tr("id of the object, handle of a vertex")).split(","));
emit setSlotDescription("minEdgeLength(int)","Get the minimal edge length of an object",
QStringList("ObjectId"), QStringList("id of the object"));
emit setSlotDescription("minEdgeLength(int)",tr("Get the minimal edge length of an object"),
QStringList(tr("ObjectId")), QStringList(tr("id of the object")));
emit setSlotDescription("maxEdgeLength(int)","Get the maximal edge length of an object",
QStringList("ObjectId"), QStringList("id of the object"));
emit setSlotDescription("maxEdgeLength(int)",tr("Get the maximal edge length of an object"),
QStringList(tr("ObjectId")), QStringList(tr("id of the object")));
emit setSlotDescription("meanEdgeLength(int)","Get the mean edge length of an object",
QStringList("ObjectId"), QStringList("id of the object"));
emit setSlotDescription("meanEdgeLength(int)",tr("Get the mean edge length of an object"),
QStringList(tr("ObjectId")), QStringList(tr("id of the object")));
}
......@@ -128,7 +128,7 @@ int InfoPlugin::vertexCount(int _id)
return -1;
if ( object == 0){
emit log(LOGERR, "Unable to get object");
emit log(LOGERR, tr("Unable to get object"));
return -1;
}
......@@ -136,7 +136,7 @@ int InfoPlugin::vertexCount(int _id)
TriMesh* mesh = PluginFunctions::triMesh(object);
if ( mesh == 0 ) {
emit log(LOGERR,"Unable to get mesh");
emit log(LOGERR, tr("Unable to get mesh"));
return -1;
}
......@@ -146,7 +146,7 @@ int InfoPlugin::vertexCount(int _id)
PolyMesh* mesh = PluginFunctions::polyMesh(object);
if ( mesh == 0 ) {
emit log(LOGERR,"Unable to get mesh");
emit log(LOGERR, tr("Unable to get mesh"));
return -1;
}
......@@ -170,7 +170,7 @@ int InfoPlugin::edgeCount(int _id)
return -1;
if ( object == 0){
emit log(LOGERR, "Unable to get object");
emit log(LOGERR, tr("Unable to get object"));
return -1;
}
......@@ -178,7 +178,7 @@ int InfoPlugin::edgeCount(int _id)
TriMesh* mesh = PluginFunctions::triMesh(object);
if ( mesh == 0 ) {
emit log(LOGERR,"Unable to get mesh");
emit log(LOGERR, tr("Unable to get mesh"));
return -1;
}
......@@ -188,7 +188,7 @@ int InfoPlugin::edgeCount(int _id)
PolyMesh* mesh = PluginFunctions::polyMesh(object);
if ( mesh == 0 ) {
emit log(LOGERR,"Unable to get mesh");
emit log(LOGERR, tr("Unable to get mesh"));
return -1;
}
......@@ -212,7 +212,7 @@ int InfoPlugin::faceCount(int _id)
return -1;
if ( object == 0){
emit log(LOGERR, "Unable to get object");
emit log(LOGERR, tr("Unable to get object"));
return -1;
}
......@@ -220,7 +220,7 @@ int InfoPlugin::faceCount(int _id)
TriMesh* mesh = PluginFunctions::triMesh(object);
if ( mesh == 0 ) {
emit log(LOGERR,"Unable to get mesh");
emit log(LOGERR, tr("Unable to get mesh"));
return -1;
}
......@@ -230,7 +230,7 @@ int InfoPlugin::faceCount(int _id)
PolyMesh* mesh = PluginFunctions::polyMesh(object);
if ( mesh == 0 ) {
emit log(LOGERR,"Unable to get mesh");
emit log(LOGERR, tr("Unable to get mesh"));
return -1;
}
......@@ -254,7 +254,7 @@ int InfoPlugin::boundaryCount(int _id)
return -1;
if ( object == 0){
emit log(LOGERR, "Unable to get object");
emit log(LOGERR, tr("Unable to get object"));
return -1;
}
......@@ -262,7 +262,7 @@ int InfoPlugin::boundaryCount(int _id)
TriMesh* mesh = PluginFunctions::triMesh(object);
if ( mesh == 0 ) {
emit log(LOGERR,"Unable to get mesh");
emit log(LOGERR, tr("Unable to get mesh"));
return -1;
}
......@@ -272,7 +272,7 @@ int InfoPlugin::boundaryCount(int _id)
PolyMesh* mesh = PluginFunctions::polyMesh(object);
if ( mesh == 0 ) {
emit log(LOGERR,"Unable to get mesh");
emit log(LOGERR, tr("Unable to get mesh"));
return -1;
}
......@@ -296,7 +296,7 @@ int InfoPlugin::componentCount(int _id)
return -1;
if ( object == 0){
emit log(LOGERR, "Unable to get object");
emit log(LOGERR, tr("Unable to get object"));
return -1;
}
......@@ -304,7 +304,7 @@ int InfoPlugin::componentCount(int _id)
TriMesh* mesh = PluginFunctions::triMesh(object);
if ( mesh == 0 ) {
emit log(LOGERR,"Unable to get mesh");
emit log(LOGERR, tr("Unable to get mesh"));
return -1;
}
......@@ -314,7 +314,7 @@ int InfoPlugin::componentCount(int _id)
PolyMesh* mesh = PluginFunctions::polyMesh(object);
if ( mesh == 0 ) {
emit log(LOGERR,"Unable to get mesh");
emit log(LOGERR, tr("Unable to get mesh"));
return -1;
}
......@@ -338,7 +338,7 @@ int InfoPlugin::genus(int _id)
return -1;
if ( object == 0){
emit log(LOGERR, "Unable to get object");
emit log(LOGERR, tr("Unable to get object"));
return -1;
}
......@@ -346,7 +346,7 @@ int InfoPlugin::genus(int _id)
TriMesh* mesh = PluginFunctions::triMesh(object);
if ( mesh == 0 ) {
emit log(LOGERR,"Unable to get mesh");
emit log(LOGERR, tr("Unable to get mesh"));
return -1;
}
///TODO this formula only works for closed objects: fix it
......@@ -356,7 +356,7 @@ int InfoPlugin::genus(int _id)
PolyMesh* mesh = PluginFunctions::polyMesh(object);
if ( mesh == 0 ) {
emit log(LOGERR,"Unable to get mesh");
emit log(LOGERR, tr("Unable to get mesh"));
return -1;
}
......@@ -380,7 +380,7 @@ Vector InfoPlugin::cog(int _id)
return Vector();
if ( object == 0){
emit log(LOGERR, "Unable to get object");
emit log(LOGERR, tr("Unable to get object"));
return Vector();
}
......@@ -388,7 +388,7 @@ Vector InfoPlugin::cog(int _id)
TriMesh* mesh = PluginFunctions::triMesh(object);
if ( mesh == 0 ) {
emit log(LOGERR,"Unable to get mesh");
emit log(LOGERR, tr("Unable to get mesh"));
return Vector();
}
......@@ -398,7 +398,7 @@ Vector InfoPlugin::cog(int _id)
PolyMesh* mesh = PluginFunctions::polyMesh(object);
if ( mesh == 0 ) {
emit log(LOGERR,"Unable to get mesh");
emit log(LOGERR, tr("Unable to get mesh"));
return Vector();
}
......@@ -422,7 +422,7 @@ Vector InfoPlugin::boundingBoxMin(int _id)
return Vector();
if ( object == 0){
emit log(LOGERR, "Unable to get object");
emit log(LOGERR, tr("Unable to get object"));
return Vector();
}
......@@ -430,7 +430,7 @@ Vector InfoPlugin::boundingBoxMin(int _id)
TriMesh* mesh = PluginFunctions::triMesh(object);
if ( mesh == 0 ) {
emit log(LOGERR,"Unable to get mesh");
emit log(LOGERR, tr("Unable to get mesh"));
return Vector();
}
......@@ -444,7 +444,7 @@ Vector InfoPlugin::boundingBoxMin(int _id)
PolyMesh* mesh = PluginFunctions::polyMesh(object);
if ( mesh == 0 ) {
emit log(LOGERR,"Unable to get mesh");
emit log(LOGERR, tr("Unable to get mesh"));
return Vector();
}
......@@ -472,7 +472,7 @@ Vector InfoPlugin::boundingBoxMax(int _id)
return Vector();
if ( object == 0){
emit log(LOGERR, "Unable to get object");
emit log(LOGERR, tr("Unable to get object"));
return Vector();
}
......@@ -480,7 +480,7 @@ Vector InfoPlugin::boundingBoxMax(int _id)
TriMesh* mesh = PluginFunctions::triMesh(object);
if ( mesh == 0 ) {
emit log(LOGERR,"Unable to get mesh");
emit log(LOGERR, tr("Unable to get mesh"));
return Vector();
}
......@@ -494,7 +494,7 @@ Vector InfoPlugin::boundingBoxMax(int _id)
PolyMesh* mesh = PluginFunctions::polyMesh(object);
if ( mesh == 0 ) {
emit log(LOGERR,"Unable to get mesh");
emit log(LOGERR, tr("Unable to get mesh"));
return Vector();
}
......@@ -522,7 +522,7 @@ Vector InfoPlugin::boundingBoxSize(int _id)
return Vector();
if ( object == 0){
emit log(LOGERR, "Unable to get object");
emit log(LOGERR, tr("Unable to get object"));
return Vector();
}
......@@ -530,7 +530,7 @@ Vector InfoPlugin::boundingBoxSize(int _id)
TriMesh* mesh = PluginFunctions::triMesh(object);
if ( mesh == 0 ) {
emit log(LOGERR,"Unable to get mesh");
emit log(LOGERR, tr("Unable to get mesh"));
return Vector();
}
......@@ -544,7 +544,7 @@ Vector InfoPlugin::boundingBoxSize(int _id)
PolyMesh* mesh = PluginFunctions::polyMesh(object);
if ( mesh == 0 ) {
emit log(LOGERR,"Unable to get mesh");
emit log(LOGERR, tr("Unable to get mesh"));
return Vector();
}
......@@ -573,7 +573,7 @@ double InfoPlugin::edgeLength(int _id, int _edgeHandle)
return -1.0;
if ( object == 0){
emit log(LOGERR, "Unable to get object");
emit log(LOGERR, tr("Unable to get object"));
return -1.0;
}
......@@ -581,14 +581,14 @@ double InfoPlugin::edgeLength(int _id, int _edgeHandle)
TriMesh* mesh = PluginFunctions::triMesh(object);
if ( mesh == 0 ) {
emit log(LOGERR,"Unable to get mesh");
emit log(LOGERR, tr("Unable to get mesh"));
return -1.0;
}
TriMesh::EdgeHandle eh( _edgeHandle );
if ( !eh.is_valid() ) {
emit log(LOGERR,"Unable to get edge handle");
emit log(LOGERR,tr("Unable to get edge handle"));
return -1.0;
}
......@@ -602,14 +602,14 @@ double InfoPlugin::edgeLength(int _id, int _edgeHandle)
PolyMesh* mesh = PluginFunctions::polyMesh(object);
if ( mesh == 0 ) {
emit log(LOGERR,"Unable to get mesh");
emit log(LOGERR, tr("Unable to get mesh"));
return -1.0;
}
PolyMesh::EdgeHandle eh( _edgeHandle );
if ( !eh.is_valid() ) {
emit log(LOGERR,"Unable to get edge handle");
emit log(LOGERR,tr("Unable to get edge handle"));
return -1.0;
}
......@@ -638,7 +638,7 @@ double InfoPlugin::faceArea(int _id, int _faceHandle)
return -1.0;
if ( object == 0){
emit log(LOGERR, "Unable to get object");
emit log(LOGERR, tr("Unable to get object"));
return -1.0;
}
......@@ -646,14 +646,14 @@ double InfoPlugin::faceArea(int _id, int _faceHandle)
TriMesh* mesh = PluginFunctions::triMesh(object);
if ( mesh == 0 ) {
emit log(LOGERR,"Unable to get mesh");
emit log(LOGERR, tr("Unable to get mesh"));
return -1.0;
}
TriMesh::FaceHandle fh( _faceHandle );
if ( !fh.is_valid() ) {
emit log(LOGERR,"Unable to get face handle");
emit log(LOGERR,tr("Unable to get face handle"));
return -1.0;
}
......@@ -671,14 +671,14 @@ double InfoPlugin::faceArea(int _id, int _faceHandle)
PolyMesh* mesh = PluginFunctions::polyMesh(object);
if ( mesh == 0 ) {
emit log(LOGERR,"Unable to get mesh");
emit log(LOGERR, tr("Unable to get mesh"));
return -1.0;
}
PolyMesh::FaceHandle fh( _faceHandle );
if ( !fh.is_valid() ) {
emit log(LOGERR,"Unable to get face handle");
emit log(LOGERR,tr("Unable to get face handle"));
return -1.0;
}
......@@ -690,7 +690,7 @@ double InfoPlugin::faceArea(int _id, int _faceHandle)
vertices.push_back( mesh->point( fv_it.handle() ) );
///TODO implement polygonArea
emit log(LOGERR,"Not implemented yet");
emit log(LOGERR,tr("Not implemented yet"));
return -1.0;
// return ACG::Geometry::polygonArea( vertices );
}
......@@ -713,7 +713,7 @@ double InfoPlugin::aspectRatio(int _id, int _faceHandle)
return -1.0;
if ( object == 0){
emit log(LOGERR, "Unable to get object");
emit log(LOGERR, tr("Unable to get object"));
return -1.0;
}
......@@ -721,14 +721,14 @@ double InfoPlugin::aspectRatio(int _id, int _faceHandle)
TriMesh* mesh = PluginFunctions::triMesh(object);
if ( mesh == 0 ) {
emit log(LOGERR,"Unable to get mesh");
emit log(LOGERR, tr("Unable to get mesh"));
return -1.0;
}
TriMesh::FaceHandle fh( _faceHandle );
if ( !fh.is_valid() ) {
emit log(LOGERR,"Unable to get face handle");
emit log(LOGERR,tr("Unable to get face handle"));
return -1.0;
}
......@@ -744,7 +744,7 @@ double InfoPlugin::aspectRatio(int _id, int _faceHandle)
} else {
emit log(LOGERR,"Aspect ratio can only be calculated for triangle meshes");
emit log(LOGERR,tr("Aspect ratio can only be calculated for triangle meshes"));
return -1.0;
}
}
......@@ -766,7 +766,7 @@ int InfoPlugin::vertexValence (int _id, int _vertexHandle)
return -1;
if ( object == 0){
emit log(LOGERR, "Unable to get object");
emit log(LOGERR, tr("Unable to get object"));
return -1;
}
......@@ -774,14 +774,14 @@ int InfoPlugin::vertexValence (int _id, int _vertexHandle)
TriMesh* mesh = PluginFunctions::triMesh(object);
if ( mesh == 0 ) {
emit log(LOGERR,"Unable to get mesh");
emit log(LOGERR, tr("Unable to get mesh"));
return -1;
}
TriMesh::VertexHandle vh( _vertexHandle );
if ( !vh.is_valid() ) {
emit log(LOGERR,"Unable to get vertex handle");
emit log(LOGERR,tr("Unable to get vertex handle"));
return -1;
}
......@@ -798,14 +798,14 @@ int InfoPlugin::vertexValence (int _id, int _vertexHandle)
PolyMesh* mesh = PluginFunctions::polyMesh(object);
if ( mesh == 0 ) {
emit log(LOGERR,"Unable to get mesh");
emit log(LOGERR, tr("Unable to get mesh"));
return -1;
}
PolyMesh::VertexHandle vh( _vertexHandle );
if ( !vh.is_valid() ) {
emit log(LOGERR,"Unable to get vertex handle");
emit log(LOGERR,tr("Unable to get vertex handle"));
return -1;
}
......
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE TS>