summaryrefslogtreecommitdiffstats
path: root/korganizer/printing/calprintdefaultplugins.cpp
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-04-13 00:46:47 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-04-13 00:46:47 +0000
commit67e29a054cfcb1b0d2fe6b0a316cf6b3eec087b7 (patch)
tree5f52a9eada2e9f3654fc327d7c14dfef570a6ecb /korganizer/printing/calprintdefaultplugins.cpp
parent2ee4bf4fd5eff93b2fbef0ff8e8063edffc5da5c (diff)
downloadtdepim-67e29a054cfcb1b0d2fe6b0a316cf6b3eec087b7.tar.gz
tdepim-67e29a054cfcb1b0d2fe6b0a316cf6b3eec087b7.zip
Initial conversion of kdepim to TQt
This will probably require some tweaking before it will build under Qt4, however Qt3 builds are OK. Any alterations this commit makes to kdepim behaviour under Qt3 are unintentional and should be fixed. git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdepim@1227832 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'korganizer/printing/calprintdefaultplugins.cpp')
-rw-r--r--korganizer/printing/calprintdefaultplugins.cpp46
1 files changed, 23 insertions, 23 deletions
diff --git a/korganizer/printing/calprintdefaultplugins.cpp b/korganizer/printing/calprintdefaultplugins.cpp
index b62c7adda..c5f69dd09 100644
--- a/korganizer/printing/calprintdefaultplugins.cpp
+++ b/korganizer/printing/calprintdefaultplugins.cpp
@@ -21,8 +21,8 @@
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
As a special exception, permission is given to link this program
- with any edition of Qt, and distribute the resulting executable,
- without including the source code for Qt in the source distribution.
+ with any edition of TQt, and distribute the resulting executable,
+ without including the source code for TQt in the source distribution.
*/
#ifndef KORG_NOPRINTER
@@ -144,7 +144,7 @@ class TimePrintStringsVisitor : public IncidenceBase::Visitor
event->dtStart(), event->doesFloat(), false );
} else {
mStartCaption = i18n( "No start date" );
- mStartString = TQString::null;
+ mStartString = TQString();
}
if ( event->hasEndDate() ) {
@@ -162,7 +162,7 @@ class TimePrintStringsVisitor : public IncidenceBase::Visitor
}
} else {
mEndCaption = i18n("No end date");
- mEndString = TQString::null;
+ mEndString = TQString();
}
return true;
}
@@ -173,7 +173,7 @@ class TimePrintStringsVisitor : public IncidenceBase::Visitor
todo->dtStart(), todo->doesFloat(), false );
} else {
mStartCaption = i18n( "No start date" );
- mStartString = TQString::null;
+ mStartString = TQString();
}
if ( todo->hasDueDate() ) {
@@ -182,7 +182,7 @@ class TimePrintStringsVisitor : public IncidenceBase::Visitor
todo->dtDue(), todo->doesFloat(), false );
} else {
mEndCaption = i18n("No due date");
- mEndString = TQString::null;
+ mEndString = TQString();
}
return true;
}
@@ -190,8 +190,8 @@ class TimePrintStringsVisitor : public IncidenceBase::Visitor
mStartCaption = i18n( "Start date: " );
mStartString = IncidenceFormatter::dateTimeToString(
journal->dtStart(), journal->doesFloat(), false );
- mEndCaption = TQString::null;
- mEndString = TQString::null;
+ mEndCaption = TQString();
+ mEndString = TQString();
return true;
}
};
@@ -204,12 +204,12 @@ int CalPrintIncidence::printCaptionAndText( TQPainter &p, const TQRect &box, con
TQFont oldFont( p.font() );
p.setFont( captionFont );
- p.drawText( box, Qt::AlignLeft|Qt::AlignTop|Qt::SingleLine, caption );
+ p.drawText( box, TQt::AlignLeft|TQt::AlignTop|TQt::SingleLine, caption );
if ( !text.isEmpty() ) {
textRect.setLeft( textRect.left() + textWd );
p.setFont( textFont );
- p.drawText( textRect, Qt::AlignLeft|Qt::AlignTop|Qt::SingleLine, text );
+ p.drawText( textRect, TQt::AlignLeft|TQt::AlignTop|TQt::SingleLine, text );
}
p.setFont( oldFont );
return textRect.bottom();
@@ -283,7 +283,7 @@ void CalPrintIncidence::print( TQPainter &p, int width, int height )
textRect.setLeft( textRect.right() );
textRect.setRight( timesBox.right() - padding() );
- h = QMAX( printCaptionAndText( p, textRect, stringVis.mEndCaption, stringVis.mEndString, captionFont, textFont ), h );
+ h = TQMAX( printCaptionAndText( p, textRect, stringVis.mEndCaption, stringVis.mEndString, captionFont, textFont ), h );
}
// Convert recurrence to a string
@@ -303,7 +303,7 @@ void CalPrintIncidence::print( TQPainter &p, int width, int height )
}
}
displayString.append(exceptString);
- h = QMAX( printCaptionAndText( p, recurBox, i18n( "Repeats: "), displayString, captionFont, textFont ), h );
+ h = TQMAX( printCaptionAndText( p, recurBox, i18n( "Repeats: "), displayString, captionFont, textFont ), h );
}
// Alarms Printing
@@ -359,14 +359,14 @@ void CalPrintIncidence::print( TQPainter &p, int width, int height )
txt = alarmStrings.join( i18n("Spacer for the joined list of categories", ", ") );
}
- h = QMAX( printCaptionAndText( p, alarmBox, cap, txt, captionFont, textFont ), h );
+ h = TQMAX( printCaptionAndText( p, alarmBox, cap, txt, captionFont, textFont ), h );
TQRect organizerBox( timesBox.left()+padding(), h+padding(), timesBox.right()-padding(), lineHeight );
- h = QMAX( printCaptionAndText( p, organizerBox, i18n("Organizer: "), (*it)->organizer().fullName(), captionFont, textFont ), h );
+ h = TQMAX( printCaptionAndText( p, organizerBox, i18n("Organizer: "), (*it)->organizer().fullName(), captionFont, textFont ), h );
// Finally, draw the frame around the time information...
- timesBox.setBottom( QMAX( timesBox.bottom(), h+padding() ) );
+ timesBox.setBottom( TQMAX( timesBox.bottom(), h+padding() ) );
drawBox( p, BOX_BORDER_WIDTH, timesBox );
@@ -439,10 +439,10 @@ void CalPrintIncidence::print( TQPainter &p, int width, int height )
if ( mShowSubitemsNotes ) {
if ( (*it)->relations().isEmpty() || (*it)->type() != "Todo" ) {
int notesPosition = drawBoxWithCaption( p, notesBox, i18n("Notes:"),
- TQString::null, /*sameLine=*/false, /*expand=*/false,
+ TQString(), /*sameLine=*/false, /*expand=*/false,
captionFont, textFont );
TQPen oldPen( p.pen() );
- p.setPen( Qt::DotLine );
+ p.setPen( TQt::DotLine );
while ( (notesPosition += int(1.5*lineHeight)) < notesBox.bottom() ) {
p.drawLine( notesBox.left()+padding(), notesPosition, notesBox.right()-padding(), notesPosition );
}
@@ -510,8 +510,8 @@ void CalPrintIncidence::print( TQPainter &p, int width, int height )
subitemString += datesString;
subitemString += "\n";
}
- subitemString += i18n( "subitem Status: statusString",
- "Status: %1\n").arg( statusString );
+ subitemString += i18n( "subitem tqStatus: statusString",
+ "tqStatus: %1\n").arg( statusString );
subitemString += IncidenceFormatter::recurrenceString((*rit)) + "\n";
subitemString += i18n( "subitem Priority: N",
"Priority: %1\n").arg( (*rit)->priority() );
@@ -559,7 +559,7 @@ void CalPrintIncidence::print( TQPainter &p, int width, int height )
for ( Attendee::List::ConstIterator ait = attendees.begin(); ait != attendees.end(); ++ait ) {
if ( !attendeeString.isEmpty() ) attendeeString += "\n";
attendeeString += i18n("Formatting of an attendee: "
- "'Name (Role): Status', e.g. 'Reinhold Kainhofer "
+ "'Name (Role): tqStatus', e.g. 'Reinhold Kainhofer "
"<reinhold@kainhofer.com> (Participant): Awaiting Response'",
"%1 (%2): %3")
.arg( (*ait)->fullName() )
@@ -572,7 +572,7 @@ void CalPrintIncidence::print( TQPainter &p, int width, int height )
if ( mShowOptions ) {
TQString optionsString;
if ( !(*it)->statusStr().isEmpty() ) {
- optionsString += i18n("Status: %1").arg( (*it)->statusStr() );
+ optionsString += i18n("tqStatus: %1").arg( (*it)->statusStr() );
optionsString += "\n";
}
if ( !(*it)->secrecyStr().isEmpty() ) {
@@ -740,8 +740,8 @@ void CalPrintDay::print( TQPainter &p, int width, int height )
uint lineSpacing = p.fontMetrics().lineSpacing();
uint maxAllDayEvents = 8; // the max we allow to be printed, sorry.
- uint allDayHeight = QMIN( alldayEvents.count(), maxAllDayEvents ) * lineSpacing;
- allDayHeight = QMAX( allDayHeight, ( 5 * lineSpacing ) ) + ( 2 * padding() );
+ uint allDayHeight = TQMIN( alldayEvents.count(), maxAllDayEvents ) * lineSpacing;
+ allDayHeight = TQMAX( allDayHeight, ( 5 * lineSpacing ) ) + ( 2 * padding() );
TQRect allDayBox( TIMELINE_WIDTH + padding(), headerBox.bottom() + padding(),
width - TIMELINE_WIDTH - padding(), allDayHeight );
if ( alldayEvents.count() > 0 ) {