summaryrefslogtreecommitdiffabout
path: root/libkcal/person.cpp
Side-by-side diff
Diffstat (limited to 'libkcal/person.cpp') (more/less context) (show whitespace changes)
-rw-r--r--libkcal/person.cpp8
1 files changed, 7 insertions, 1 deletions
diff --git a/libkcal/person.cpp b/libkcal/person.cpp
index aca28c2..858805d 100644
--- a/libkcal/person.cpp
+++ b/libkcal/person.cpp
@@ -51,3 +51,9 @@ bool KCal::operator==( const Person& p1, const Person& p2 )
-
+QString Person::realName() const
+{
+ int ccc = mName.find (',');
+ if ( ccc < 0 )
+ return mName;
+ return mName.mid( ccc+1 ).stripWhiteSpace() + " " + mName.left( ccc ).stripWhiteSpace();
+}
QString Person::fullName() const