summaryrefslogtreecommitdiffstats
path: root/kpilot/lib/pilotDateEntry.cc
diff options
context:
space:
mode:
Diffstat (limited to 'kpilot/lib/pilotDateEntry.cc')
-rw-r--r--kpilot/lib/pilotDateEntry.cc72
1 files changed, 36 insertions, 36 deletions
diff --git a/kpilot/lib/pilotDateEntry.cc b/kpilot/lib/pilotDateEntry.cc
index 4fa93eac6..d7844b897 100644
--- a/kpilot/lib/pilotDateEntry.cc
+++ b/kpilot/lib/pilotDateEntry.cc
@@ -31,9 +31,9 @@
#include <stdlib.h>
-#include <qdatetime.h>
-#include <qnamespace.h>
-#include <qregexp.h>
+#include <tqdatetime.h>
+#include <tqnamespace.h>
+#include <tqregexp.h>
#include <kglobal.h>
@@ -160,12 +160,12 @@ PilotDateEntry & PilotDateEntry::operator = (const PilotDateEntry & e)
} // end of assignment operator
-QString PilotDateEntry::getTextRepresentation(Qt::TextFormat richText)
+TQString PilotDateEntry::getTextRepresentation(Qt::TextFormat richText)
{
- QString text, tmp;
- QString par = (richText==Qt::RichText) ?CSL1("<p>"):QString::null;
- QString ps = (richText==Qt::RichText) ?CSL1("</p>"):CSL1("\n");
- QString br = (richText==Qt::RichText) ?CSL1("<br/>"):CSL1("\n");
+ TQString text, tmp;
+ TQString par = (richText==Qt::RichText) ?CSL1("<p>"):TQString::null;
+ TQString ps = (richText==Qt::RichText) ?CSL1("</p>"):CSL1("\n");
+ TQString br = (richText==Qt::RichText) ?CSL1("<br/>"):CSL1("\n");
// title + name
text += par;
@@ -173,8 +173,8 @@ QString PilotDateEntry::getTextRepresentation(Qt::TextFormat richText)
text += tmp.arg(rtExpand(getDescription(), richText));
text += ps;
- QDateTime dt(readTm(getEventStart()));
- QString startDate(dt.toString(Qt::LocalDate));
+ TQDateTime dt(readTm(getEventStart()));
+ TQString startDate(dt.toString(Qt::LocalDate));
text+=par;
text+=i18n("Start date: %1").arg(startDate);
text+=ps;
@@ -188,7 +188,7 @@ QString PilotDateEntry::getTextRepresentation(Qt::TextFormat richText)
else
{
dt=readTm(getEventEnd());
- QString endDate(dt.toString(Qt::LocalDate));
+ TQString endDate(dt.toString(Qt::LocalDate));
text+=par;
text+=i18n("End date: %1").arg(endDate);
text+=ps;
@@ -204,7 +204,7 @@ QString PilotDateEntry::getTextRepresentation(Qt::TextFormat richText)
case advMinutes: tmp=tmp.arg(i18n("minutes")); break;
case advHours: tmp=tmp.arg(i18n("hours")); break;
case advDays: tmp=tmp.arg(i18n("days")); break;
- default: tmp=tmp.arg(QString::null); break;;
+ default: tmp=tmp.arg(TQString::null); break;;
}
text+=tmp;
text+=ps;
@@ -224,7 +224,7 @@ QString PilotDateEntry::getTextRepresentation(Qt::TextFormat richText)
case repeatMonthlyByDay:
case repeatMonthlyByDate: tmp=tmp.arg(i18n("month(s)")); break;
case repeatYearly: tmp=tmp.arg(i18n("year(s)")); break;
- default: tmp=tmp.arg(QString::null); break;
+ default: tmp=tmp.arg(TQString::null); break;
}
text+=tmp;
text+=br;
@@ -244,7 +244,7 @@ QString PilotDateEntry::getTextRepresentation(Qt::TextFormat richText)
if (getRepeatType()==repeatMonthlyByDay) text+=i18n("Repeating on the i-th day of week j")+br;
if (getRepeatType()==repeatMonthlyByDate) text+=i18n("Repeating on the n-th day of the month")+br;
// TODO: show the dayArray when repeating weekly
- /*QBitArray dayArray(7);
+ /*TQBitArray dayArray(7);
if (getRepeatType()==repeatWeekly) text+=i18n("Repeat day flags: %1").arg(getRepeatDays
const int *days = dateEntry->getRepeatDays();
// Rotate the days of the week, since day numbers on the Pilot and
@@ -263,7 +263,7 @@ QString PilotDateEntry::getTextRepresentation(Qt::TextFormat richText)
text+=i18n("Exceptions:")+br;
for (int i = 0; i < getExceptionCount(); i++)
{
- QDate exdt=readTm(getExceptions()[i]).date();
+ TQDate exdt=readTm(getExceptions()[i]).date();
text+=exdt.toString(Qt::LocalDate);
text+=br;
}
@@ -282,19 +282,19 @@ QString PilotDateEntry::getTextRepresentation(Qt::TextFormat richText)
return text;
}
-QDateTime PilotDateEntry::dtStart() const
+TQDateTime PilotDateEntry::dtStart() const
{
FUNCTIONSETUP;
return readTm( getEventStart() );
}
-QDateTime PilotDateEntry::dtEnd() const
+TQDateTime PilotDateEntry::dtEnd() const
{
FUNCTIONSETUP;
return readTm( getEventEnd() );
}
-QDateTime PilotDateEntry::dtRepeatEnd() const
+TQDateTime PilotDateEntry::dtRepeatEnd() const
{
FUNCTIONSETUP;
return readTm( getRepeatEnd() );
@@ -402,25 +402,25 @@ void PilotDateEntry::setNoteP(const char *note, int l)
}
}
-void PilotDateEntry::setNote(const QString &s)
+void PilotDateEntry::setNote(const TQString &s)
{
- QCString t = Pilot::toPilot(s);
+ TQCString t = Pilot::toPilot(s);
setNoteP( t.data(),t.length() );
}
-void PilotDateEntry::setLocation(const QString &s)
+void PilotDateEntry::setLocation(const TQString &s)
{
- QString note = Pilot::fromPilot(getNoteP());
- QRegExp rxp = QRegExp("^[Ll]ocation:[^\n]+\n");
+ TQString note = Pilot::fromPilot(getNoteP());
+ TQRegExp rxp = TQRegExp("^[Ll]ocation:[^\n]+\n");
- // per QString docs, this covers null and 0 length
+ // per TQString docs, this covers null and 0 length
if( s.isEmpty() )
{
note.replace(rxp,"");
}
else
{
- QString location = "Location: " + s + "\n";
+ TQString location = "Location: " + s + "\n";
int pos = note.find(rxp);
if(pos >= 0)
@@ -435,18 +435,18 @@ void PilotDateEntry::setLocation(const QString &s)
}
}
-QString PilotDateEntry::getLocation() const
+TQString PilotDateEntry::getLocation() const
{
// Read the complete note here and not the filtered
// one from PilotDateEntry::getNote();
- QString note = Pilot::fromPilot(getNoteP());
- QRegExp rxp = QRegExp("^[Ll]ocation:[^\n]+\n");
+ TQString note = Pilot::fromPilot(getNoteP());
+ TQRegExp rxp = TQRegExp("^[Ll]ocation:[^\n]+\n");
int pos = note.find(rxp, 0);
if(pos >= 0)
{
- QString location = rxp.capturedTexts().first();
- rxp = QRegExp("^[Ll]ocation:[\\s|\t]*");
+ TQString location = rxp.capturedTexts().first();
+ rxp = TQRegExp("^[Ll]ocation:[\\s|\t]*");
location.replace(rxp,"");
location.replace("\n", "");
return location;
@@ -457,21 +457,21 @@ QString PilotDateEntry::getLocation() const
}
}
-void PilotDateEntry::setDescription(const QString &s)
+void PilotDateEntry::setDescription(const TQString &s)
{
- QCString t = Pilot::toPilot(s);
+ TQCString t = Pilot::toPilot(s);
setDescriptionP( t.data(),t.length() );
}
-QString PilotDateEntry::getNote() const
+TQString PilotDateEntry::getNote() const
{
- QString note = Pilot::fromPilot(getNoteP());
- QRegExp rxp = QRegExp("^[Ll]ocation:[^\n]+\n");
+ TQString note = Pilot::fromPilot(getNoteP());
+ TQRegExp rxp = TQRegExp("^[Ll]ocation:[^\n]+\n");
note.replace(rxp, "" );
return note;
}
-QString PilotDateEntry::getDescription() const
+TQString PilotDateEntry::getDescription() const
{
return Pilot::fromPilot(getDescriptionP());
}