Distinguish straight lines and polygons in texts

This commit is contained in:
Fabio D'Urso 2013-04-19 21:12:34 +02:00
parent d197c9a109
commit 2e6edb5e2c
2 changed files with 8 additions and 2 deletions

View file

@ -120,7 +120,10 @@ void AnnotsPropertiesDialog::setCaptionTextbyAnnotType()
captiontext = i18n( "Inline Note Properties" );
break;
case Okular::Annotation::ALine:
captiontext = i18n( "Line Properties" );
if ( ((Okular::LineAnnotation*)m_annot)->linePoints().count() == 2 )
captiontext = i18n( "Straight Line Properties" );
else
captiontext = i18n( "Polygon Properties" );
break;
case Okular::Annotation::AGeom:
captiontext = i18n( "Geometry Properties" );

View file

@ -74,7 +74,10 @@ QString captionForAnnotation( const Okular::Annotation * ann )
ret = i18n( "Inline Note" );
break;
case Okular::Annotation::ALine:
ret = i18n( "Line" );
if( ( (Okular::LineAnnotation*)ann )->linePoints().count() == 2 )
ret = i18n( "Straight Line" );
else
ret = i18n( "Polygon" );
break;
case Okular::Annotation::AGeom:
ret = i18n( "Geometry" );