summaryrefslogtreecommitdiffstats
path: root/kdgantt
diff options
context:
space:
mode:
authorTimothy Pearson <kb9vqf@pearsoncomputing.net>2011-12-18 18:12:30 -0600
committerTimothy Pearson <kb9vqf@pearsoncomputing.net>2011-12-18 18:12:30 -0600
commit11191ef0b9908604d1d7aaca382b011ef22c454c (patch)
treed38f0ccd8bfcc9756f5cfc42fb2ad1dad351e6aa /kdgantt
parentc9cb4f487428aad5d8cda5e3a4b9ad87390d7e54 (diff)
downloadkoffice-11191ef0b9908604d1d7aaca382b011ef22c454c.tar.gz
koffice-11191ef0b9908604d1d7aaca382b011ef22c454c.zip
Rename old tq methods that no longer need a unique name
Diffstat (limited to 'kdgantt')
-rw-r--r--kdgantt/KDGanttMinimizeSplitter.cpp136
-rw-r--r--kdgantt/KDGanttMinimizeSplitter.h6
-rw-r--r--kdgantt/KDGanttSemiSizingControl.cpp4
-rw-r--r--kdgantt/KDGanttView.cpp12
-rw-r--r--kdgantt/KDGanttView.h2
-rw-r--r--kdgantt/KDGanttViewItemDrag.cpp4
-rw-r--r--kdgantt/KDGanttViewItemDrag.h2
-rw-r--r--kdgantt/KDGanttViewSubwidgets.cpp32
-rw-r--r--kdgantt/itemAttributeDialog.ui4
-rw-r--r--kdgantt/qlayoutengine_p.h10
10 files changed, 106 insertions, 106 deletions
diff --git a/kdgantt/KDGanttMinimizeSplitter.cpp b/kdgantt/KDGanttMinimizeSplitter.cpp
index 9ba1dbd2..8924ed33 100644
--- a/kdgantt/KDGanttMinimizeSplitter.cpp
+++ b/kdgantt/KDGanttMinimizeSplitter.cpp
@@ -66,7 +66,7 @@ KDGanttSplitterHandle::KDGanttSplitterHandle( Qt::Orientation o,
setMouseTracking( true );
}
-TQSize KDGanttSplitterHandle::tqsizeHint() const
+TQSize KDGanttSplitterHandle::sizeHint() const
{
return TQSize(8,8);
}
@@ -240,16 +240,16 @@ void KDGanttSplitterHandle::paintEvent( TQPaintEvent * )
TQPainter p( &buffer );
// Draw the splitter rectangle
- p.setBrush( tqcolorGroup().background() );
- p.setPen( tqcolorGroup().foreground() );
+ p.setBrush( colorGroup().background() );
+ p.setPen( colorGroup().foreground() );
p.drawRect( rect() );
parentWidget()->tqstyle().tqdrawPrimitive( TQStyle::PE_Panel, &p, rect(),
- parentWidget()->tqcolorGroup());
+ parentWidget()->colorGroup());
int sw = 8; // Hardcoded, given I didn't use styles anymore, I didn't like to use their size
// arrow color
- TQColor col = tqcolorGroup().background().dark( 200 );
+ TQColor col = colorGroup().background().dark( 200 );
p.setBrush( col );
p.setPen( col );
@@ -258,13 +258,13 @@ void KDGanttSplitterHandle::paintEvent( TQPaintEvent * )
for ( TQValueList<TQPointArray>::Iterator it = list.begin(); it != list.end(); ++it ) {
if ( index == _activeButton ) {
p.save();
- p.translate( parentWidget()->tqstyle().tqpixelMetric( TQStyle::PM_ButtonShiftHorizontal ),
- parentWidget()->tqstyle().tqpixelMetric( TQStyle::PM_ButtonShiftVertical ) );
- p.tqdrawPolygon( *it, true );
+ p.translate( parentWidget()->tqstyle().pixelMetric( TQStyle::PM_ButtonShiftHorizontal ),
+ parentWidget()->tqstyle().pixelMetric( TQStyle::PM_ButtonShiftVertical ) );
+ p.drawPolygon( *it, true );
p.restore();
}
else {
- p.tqdrawPolygon( *it, true );
+ p.drawPolygon( *it, true );
}
index++;
}
@@ -366,10 +366,10 @@ static TQSize minSize( const TQWidget* /*w*/ )
// This is the original version of minSize
static TQSize minSizeHint( const TQWidget* w )
{
- TQSize min = w->tqminimumSize();
+ TQSize min = w->minimumSize();
TQSize s;
if ( min.height() <= 0 || min.width() <= 0 )
- s = w->tqminimumSizeHint();
+ s = w->minimumSizeHint();
if ( min.height() > 0 )
s.setHeight( min.height() );
if ( min.width() > 0 )
@@ -415,9 +415,9 @@ void KDGanttMinimizeSplitter::init()
{
data = new TQSplitterData;
if ( orient ==Qt::Horizontal )
- tqsetSizePolicy( TQSizePolicy(TQSizePolicy::Expanding,TQSizePolicy::Minimum) );
+ setSizePolicy( TQSizePolicy(TQSizePolicy::Expanding,TQSizePolicy::Minimum) );
else
- tqsetSizePolicy( TQSizePolicy(TQSizePolicy::Minimum,TQSizePolicy::Expanding) );
+ setSizePolicy( TQSizePolicy(TQSizePolicy::Minimum,TQSizePolicy::Expanding) );
}
@@ -435,9 +435,9 @@ void KDGanttMinimizeSplitter::setOrientation( Qt::Orientation o )
orient = o;
if ( orient ==Qt::Horizontal )
- tqsetSizePolicy( TQSizePolicy( TQSizePolicy::Expanding, TQSizePolicy::Minimum ) );
+ setSizePolicy( TQSizePolicy( TQSizePolicy::Expanding, TQSizePolicy::Minimum ) );
else
- tqsetSizePolicy( TQSizePolicy( TQSizePolicy::Minimum, TQSizePolicy::Expanding ) );
+ setSizePolicy( TQSizePolicy( TQSizePolicy::Minimum, TQSizePolicy::Expanding ) );
KDGanttSplitterLayoutStruct *s = data->list.first();
while ( s ) {
@@ -480,7 +480,7 @@ KDGanttSplitterLayoutStruct *KDGanttMinimizeSplitter::addWidget( TQWidget *w, bo
s->wid = newHandle;
newHandle->setId(data->list.count());
s->isSplitter = TRUE;
- s->sizer = pick( newHandle->tqsizeHint() );
+ s->sizer = pick( newHandle->sizeHint() );
if ( first )
data->list.insert( 0, s );
else
@@ -489,8 +489,8 @@ KDGanttSplitterLayoutStruct *KDGanttMinimizeSplitter::addWidget( TQWidget *w, bo
s = new KDGanttSplitterLayoutStruct;
s->mode = Stretch;
s->wid = w;
- if ( !testWState( WState_Resized ) && w->tqsizeHint().isValid() )
- s->sizer = pick( w->tqsizeHint() );
+ if ( !testWState( WState_Resized ) && w->sizeHint().isValid() )
+ s->sizer = pick( w->sizeHint() );
else
s->sizer = pick( w->size() );
s->isSplitter = FALSE;
@@ -563,7 +563,7 @@ void KDGanttMinimizeSplitter::setRubberband( int p )
paint.setRasterOp( XorROP );
TQRect r = contentsRect();
const int rBord = 3; //Themable????
- int sw = tqstyle().tqpixelMetric(TQStyle::PM_SplitterWidth, this);
+ int sw = tqstyle().pixelMetric(TQStyle::PM_SplitterWidth, this);
if ( orient ==Qt::Horizontal ) {
if ( opaqueOldPos >= 0 )
paint.drawRect( opaqueOldPos + sw/2 - rBord , r.y(),
@@ -603,7 +603,7 @@ bool KDGanttMinimizeSplitter::event( TQEvent *e )
void KDGanttMinimizeSplitter::drawSplitter( TQPainter *p,
TQCOORD x, TQCOORD y, TQCOORD w, TQCOORD h )
{
- tqstyle().tqdrawPrimitive(TQStyle::PE_Splitter, p, TQRect(x, y, w, h), tqcolorGroup(),
+ tqstyle().tqdrawPrimitive(TQStyle::PE_Splitter, p, TQRect(x, y, w, h), colorGroup(),
(orientation() == Qt::Horizontal ?
TQStyle::Style_Horizontal : 0));
}
@@ -708,12 +708,12 @@ void KDGanttMinimizeSplitter::moveBefore( int pos, int id, bool upLeft )
int dd, newLeft, nextPos;
if( TQApplication::reverseLayout() && orient ==Qt::Horizontal ) {
dd = w->tqgeometry().right() - pos;
- dd = TQMAX( pick(minSize(w)), TQMIN(dd, pick(w->tqmaximumSize())));
+ dd = TQMAX( pick(minSize(w)), TQMIN(dd, pick(w->maximumSize())));
newLeft = pos+1;
nextPos = newLeft + dd;
} else {
dd = pos - pick( w->pos() ) + 1;
- dd = TQMAX( pick(minSize(w)), TQMIN(dd, pick(w->tqmaximumSize())));
+ dd = TQMAX( pick(minSize(w)), TQMIN(dd, pick(w->maximumSize())));
newLeft = pos-dd+1;
nextPos = newLeft - 1;
}
@@ -762,13 +762,13 @@ void KDGanttMinimizeSplitter::moveAfter( int pos, int id, bool upLeft )
int right, dd,/* newRight,*/ newLeft, nextPos;
if ( TQApplication::reverseLayout() && orient ==Qt::Horizontal ) {
dd = pos - left + 1;
- dd = TQMAX( pick(minSize(w)), TQMIN(dd, pick(w->tqmaximumSize())));
+ dd = TQMAX( pick(minSize(w)), TQMIN(dd, pick(w->maximumSize())));
newLeft = pos-dd+1;
nextPos = newLeft - 1;
} else {
right = pick( w->tqgeometry().bottomRight() );
dd = right - pos + 1;
- dd = TQMAX( pick(minSize(w)), TQMIN(dd, pick(w->tqmaximumSize())));
+ dd = TQMAX( pick(minSize(w)), TQMIN(dd, pick(w->maximumSize())));
/*newRight = pos+dd-1;*/
newLeft = pos;
nextPos = newLeft + dd;
@@ -822,7 +822,7 @@ void KDGanttMinimizeSplitter::getRange( int id, int *min, int *max )
maxB += s->sizer;
} else {
minB += pick( minSize(s->wid) );
- maxB += pick( s->wid->tqmaximumSize() );
+ maxB += pick( s->wid->maximumSize() );
}
}
for ( i = id; i < n; i++ ) {
@@ -834,12 +834,12 @@ void KDGanttMinimizeSplitter::getRange( int id, int *min, int *max )
maxA += s->sizer;
} else {
minA += pick( minSize(s->wid) );
- maxA += pick( s->wid->tqmaximumSize() );
+ maxA += pick( s->wid->maximumSize() );
}
}
TQRect r = contentsRect();
if ( orient ==Qt::Horizontal && TQApplication::reverseLayout() ) {
- int splitterWidth = tqstyle().tqpixelMetric(TQStyle::PM_SplitterWidth, this);
+ int splitterWidth = tqstyle().pixelMetric(TQStyle::PM_SplitterWidth, this);
if ( min )
*min = pick(r.topRight()) - TQMIN( maxB, pick(r.size())-minA ) - splitterWidth;
if ( max )
@@ -881,27 +881,27 @@ void KDGanttMinimizeSplitter::doResize()
KDGanttSplitterLayoutStruct *s = data->list.at(i);
if ( s->wid->isHidden() ) {
a[i].stretch = 0;
- a[i].tqsizeHint = a[i].tqminimumSize = 0;
- a[i].tqmaximumSize = 0;
+ a[i].sizeHint = a[i].minimumSize = 0;
+ a[i].maximumSize = 0;
} else if ( s->isSplitter ) {
a[i].stretch = 0;
- a[i].tqsizeHint = a[i].tqminimumSize = a[i].tqmaximumSize = s->sizer;
+ a[i].sizeHint = a[i].minimumSize = a[i].maximumSize = s->sizer;
a[i].empty = FALSE;
} else if ( s->mode == KeepSize ) {
a[i].stretch = 0;
- a[i].tqminimumSize = pick( minSize(s->wid) );
- a[i].tqsizeHint = s->sizer;
- a[i].tqmaximumSize = pick( s->wid->tqmaximumSize() );
+ a[i].minimumSize = pick( minSize(s->wid) );
+ a[i].sizeHint = s->sizer;
+ a[i].maximumSize = pick( s->wid->maximumSize() );
a[i].empty = FALSE;
} else if ( s->mode == FollowSizeHint ) {
a[i].stretch = 0;
- a[i].tqminimumSize = a[i].tqsizeHint = pick( s->wid->tqsizeHint() );
- a[i].tqmaximumSize = pick( s->wid->tqmaximumSize() );
+ a[i].minimumSize = a[i].sizeHint = pick( s->wid->sizeHint() );
+ a[i].maximumSize = pick( s->wid->maximumSize() );
a[i].empty = FALSE;
} else { //proportional
a[i].stretch = s->sizer;
- a[i].tqmaximumSize = pick( s->wid->tqmaximumSize() );
- a[i].tqsizeHint = a[i].tqminimumSize = pick( minSize(s->wid) );
+ a[i].maximumSize = pick( s->wid->maximumSize() );
+ a[i].sizeHint = a[i].minimumSize = pick( minSize(s->wid) );
a[i].empty = FALSE;
}
}
@@ -955,9 +955,9 @@ void KDGanttMinimizeSplitter::recalc( bool update )
} else {
TQSize minS = minSize(s->wid);
minl += pick( minS );
- maxl += pick( s->wid->tqmaximumSize() );
+ maxl += pick( s->wid->maximumSize() );
mint = TQMAX( mint, trans( minS ));
- int tm = trans( s->wid->tqmaximumSize() );
+ int tm = trans( s->wid->maximumSize() );
if ( tm > 0 )
maxt = TQMIN( maxt, tm );
}
@@ -1107,7 +1107,7 @@ void KDGanttMinimizeSplitter::recalcId()
/*! Reimplemented from superclass.
*/
-TQSize KDGanttMinimizeSplitter::tqsizeHint() const
+TQSize KDGanttMinimizeSplitter::sizeHint() const
{
constPolish();
int l = 0;
@@ -1121,7 +1121,7 @@ TQSize KDGanttMinimizeSplitter::tqsizeHint() const
++it;
if ( o->isWidgetType() &&
!((TQWidget*)o)->isHidden() ) {
- TQSize s = ((TQWidget*)o)->tqsizeHint();
+ TQSize s = ((TQWidget*)o)->sizeHint();
if ( s.isValid() ) {
l += pick( s );
t = TQMAX( t, trans( s ) );
@@ -1137,7 +1137,7 @@ TQSize KDGanttMinimizeSplitter::tqsizeHint() const
\reimp
*/
-TQSize KDGanttMinimizeSplitter::tqminimumSizeHint() const
+TQSize KDGanttMinimizeSplitter::minimumSizeHint() const
{
constPolish();
int l = 0;
@@ -1311,7 +1311,7 @@ void KDGanttMinimizeSplitter::processChildEvents()
void KDGanttMinimizeSplitter::styleChange( TQStyle& old )
{
- int sw = tqstyle().tqpixelMetric(TQStyle::PM_SplitterWidth, this);
+ int sw = tqstyle().pixelMetric(TQStyle::PM_SplitterWidth, this);
KDGanttSplitterLayoutStruct *s = data->list.first();
while ( s ) {
if ( s->isSplitter )
@@ -1366,9 +1366,9 @@ void kdganttGeomCalc( TQMemArray<TQLayoutStruct> &chain, int start, int count, i
int i;
for ( i = start; i < start + count; i++ ) {
chain[i].done = FALSE;
- cHint += chain[i].tqsizeHint;
- cMin += chain[i].tqminimumSize;
- cMax += chain[i].tqmaximumSize;
+ cHint += chain[i].sizeHint;
+ cMin += chain[i].minimumSize;
+ cMax += chain[i].maximumSize;
sumStretch += chain[i].stretch;
if ( !chain[i].empty )
spacerCount++;
@@ -1381,11 +1381,11 @@ void kdganttGeomCalc( TQMemArray<TQLayoutStruct> &chain, int start, int count, i
if ( space < cMin + spacerCount * spacer ) {
// qDebug("not enough space");
for ( i = start; i < start+count; i++ ) {
- chain[i].size = chain[i].tqminimumSize;
+ chain[i].size = chain[i].minimumSize;
chain[i].done = TRUE;
}
} else if ( space < cHint + spacerCount*spacer ) {
- // Less space than tqsizeHint, but more than minimum.
+ // Less space than sizeHint, but more than minimum.
// Currently take space equally from each, like in TQt 2.x.
// Commented-out lines will give more space to stretchier items.
int n = count;
@@ -1393,10 +1393,10 @@ void kdganttGeomCalc( TQMemArray<TQLayoutStruct> &chain, int start, int count, i
int overdraft = cHint - space_left;
//first give to the fixed ones:
for ( i = start; i < start+count; i++ ) {
- if ( !chain[i].done && chain[i].tqminimumSize >= chain[i].tqsizeHint) {
- chain[i].size = chain[i].tqsizeHint;
+ if ( !chain[i].done && chain[i].minimumSize >= chain[i].sizeHint) {
+ chain[i].size = chain[i].sizeHint;
chain[i].done = TRUE;
- space_left -= chain[i].tqsizeHint;
+ space_left -= chain[i].sizeHint;
// sumStretch -= chain[i].stretch;
n--;
}
@@ -1415,13 +1415,13 @@ void kdganttGeomCalc( TQMemArray<TQLayoutStruct> &chain, int start, int count, i
// else
// fp_w += (fp_over * chain[i].stretch) / sumStretch;
int w = fRound( fp_w );
- chain[i].size = chain[i].tqsizeHint - w;
+ chain[i].size = chain[i].sizeHint - w;
fp_w -= toFixed( w ); //give the difference to the next
- if ( chain[i].size < chain[i].tqminimumSize ) {
+ if ( chain[i].size < chain[i].minimumSize ) {
chain[i].done = TRUE;
- chain[i].size = chain[i].tqminimumSize;
+ chain[i].size = chain[i].minimumSize;
finished = FALSE;
- overdraft -= chain[i].tqsizeHint - chain[i].tqminimumSize;
+ overdraft -= chain[i].sizeHint - chain[i].minimumSize;
// sumStretch -= chain[i].stretch;
n--;
break;
@@ -1433,11 +1433,11 @@ void kdganttGeomCalc( TQMemArray<TQLayoutStruct> &chain, int start, int count, i
int space_left = space - spacerCount*spacer;
// first give to the fixed ones, and handle non-expansiveness
for ( i = start; i < start + count; i++ ) {
- if ( !chain[i].done && (chain[i].tqmaximumSize <= chain[i].tqsizeHint
+ if ( !chain[i].done && (chain[i].maximumSize <= chain[i].sizeHint
|| wannaGrow && !chain[i].expansive) ) {
- chain[i].size = chain[i].tqsizeHint;
+ chain[i].size = chain[i].sizeHint;
chain[i].done = TRUE;
- space_left -= chain[i].tqsizeHint;
+ space_left -= chain[i].sizeHint;
sumStretch -= chain[i].stretch;
n--;
}
@@ -1469,20 +1469,20 @@ void kdganttGeomCalc( TQMemArray<TQLayoutStruct> &chain, int start, int count, i
int w = fRound( fp_w );
chain[i].size = w;
fp_w -= toFixed( w ); // give the difference to the next
- if ( w < chain[i].tqsizeHint ) {
- deficit += chain[i].tqsizeHint - w;
- } else if ( w > chain[i].tqmaximumSize ) {
- surplus += w - chain[i].tqmaximumSize;
+ if ( w < chain[i].sizeHint ) {
+ deficit += chain[i].sizeHint - w;
+ } else if ( w > chain[i].maximumSize ) {
+ surplus += w - chain[i].maximumSize;
}
}
if ( deficit > 0 && surplus <= deficit ) {
// give to the ones that have too little
for ( i = start; i < start+count; i++ ) {
if ( !chain[i].done &&
- chain[i].size < chain[i].tqsizeHint ) {
- chain[i].size = chain[i].tqsizeHint;
+ chain[i].size < chain[i].sizeHint ) {
+ chain[i].size = chain[i].sizeHint;
chain[i].done = TRUE;
- space_left -= chain[i].tqsizeHint;
+ space_left -= chain[i].sizeHint;
sumStretch -= chain[i].stretch;
n--;
}
@@ -1492,10 +1492,10 @@ void kdganttGeomCalc( TQMemArray<TQLayoutStruct> &chain, int start, int count, i
// take from the ones that have too much
for ( i = start; i < start+count; i++ ) {
if ( !chain[i].done &&
- chain[i].size > chain[i].tqmaximumSize ) {
- chain[i].size = chain[i].tqmaximumSize;
+ chain[i].size > chain[i].maximumSize ) {
+ chain[i].size = chain[i].maximumSize;
chain[i].done = TRUE;
- space_left -= chain[i].tqmaximumSize;
+ space_left -= chain[i].maximumSize;
sumStretch -= chain[i].stretch;
n--;
}
diff --git a/kdgantt/KDGanttMinimizeSplitter.h b/kdgantt/KDGanttMinimizeSplitter.h
index 557026f1..7a56d7ce 100644
--- a/kdgantt/KDGanttMinimizeSplitter.h
+++ b/kdgantt/KDGanttMinimizeSplitter.h
@@ -72,8 +72,8 @@ public:
void moveToLast( TQWidget * );
void refresh() { recalc( TRUE ); }
- virtual TQSize tqsizeHint() const;
- virtual TQSize tqminimumSizeHint() const;
+ virtual TQSize sizeHint() const;
+ virtual TQSize minimumSizeHint() const;
TQValueList<int> sizes() const;
void setSizes( TQValueList<int> );
@@ -149,7 +149,7 @@ public:
bool opaque() const { return s->opaqueResize(); }
- TQSize tqsizeHint() const;
+ TQSize sizeHint() const;
int id() const { return myId; } // data->list.at(id())->wid == this
void setId( int i ) { myId = i; }
diff --git a/kdgantt/KDGanttSemiSizingControl.cpp b/kdgantt/KDGanttSemiSizingControl.cpp
index 8bede0d0..8fa33775 100644
--- a/kdgantt/KDGanttSemiSizingControl.cpp
+++ b/kdgantt/KDGanttSemiSizingControl.cpp
@@ -247,7 +247,7 @@ KDGanttSemiSizingControl::ArrowPosition KDGanttSemiSizingControl::arrowPosition(
void KDGanttSemiSizingControl::init()
{
_but = new TQPushButton( this );
- _but->tqsetSizePolicy( TQSizePolicy( TQSizePolicy::Fixed, TQSizePolicy::Fixed ) );
+ _but->setSizePolicy( TQSizePolicy( TQSizePolicy::Fixed, TQSizePolicy::Fixed ) );
connect( _but, TQT_SIGNAL( clicked() ), this, TQT_SLOT(changeState()) );
_layout = 0;
TQWhatsThis::add( _but, "Click on this button to show the \nlegend at the bottom of the widget");
@@ -395,7 +395,7 @@ TQPixmap KDGanttSemiSizingControl::pixmap( Direction direction ) {
TQPainter p( &pix );
p.setPen( black );
- p.setBrush( tqcolorGroup().button() );
+ p.setBrush( colorGroup().button() );
p.drawPolygon( arr );
TQBitmap bit( s, s );
bit.fill( color0 );
diff --git a/kdgantt/KDGanttView.cpp b/kdgantt/KDGanttView.cpp
index f14ac027..45b1b976 100644
--- a/kdgantt/KDGanttView.cpp
+++ b/kdgantt/KDGanttView.cpp
@@ -186,7 +186,7 @@ KDGanttView::KDGanttView( TQWidget* parent, const char* name )
fDropEnabled = false;
closingBlocked = false;
myTimeHeader->computeTicks();
- centerTimelineAfterShow( TQDateTime::tqcurrentDateTime () );
+ centerTimelineAfterShow( TQDateTime::currentDateTime () );
setDisplayEmptyTasksAsLine( false );
TQValueList<int> list;
list.append(240);
@@ -313,12 +313,12 @@ bool KDGanttView::close ( bool alsoDelete )
/*!
Returns a useful size for the view.
Returned width:
- tqsizeHint().width() of the list view + width of TimeTable
+ sizeHint().width() of the list view + width of TimeTable
Returned height:
height() of TimeHeader + height() of TimeTable + height() of Legend (if shown)
*/
-TQSize KDGanttView::tqsizeHint() const
+TQSize KDGanttView::sizeHint() const
{
bool block = myTimeTable->blockUpdating();
myTimeTable->setBlockUpdating( false );
@@ -342,9 +342,9 @@ TQSize KDGanttView::tqsizeHint() const
if ( myLegend->isShown() )
hintHeight += myLegend->legendSizeHint().height() +10;
hintHeight += myTimeTable->minimumHeight+myListView->frameWidth()*2+2;
- int hintWid = myListView->tqsizeHint().width();
+ int hintWid = myListView->sizeHint().width();
//hintWid += myTimeHeader->mySizeHint+myCanvasView->verticalScrollBar()->width();
- hintWid += myCanvasView->tqsizeHint().width();
+ hintWid += myCanvasView->sizeHint().width();
// add 10 for the splitter-bars
// qDebug("sizehint %d %d ",hintWid+10, hintHeight );
myTimeTable->setBlockUpdating( block );
@@ -875,7 +875,7 @@ void KDGanttView::print( TQPrinter* printer ,
TQSize size = drawContents( 0, printListView, printTimeLine, printLegend );
// at the top, we want to print current time/date
- TQString date = "Printing Time: " + TQDateTime::tqcurrentDateTime().toString();
+ TQString date = "Printing Time: " + TQDateTime::currentDateTime().toString();
int hei = p.boundingRect(0,0, 5, 5, TQt::AlignLeft, date ).height();
p.drawText( 0, 0, date );
diff --git a/kdgantt/KDGanttView.h b/kdgantt/KDGanttView.h
index 02fdc5d7..d272e382 100644
--- a/kdgantt/KDGanttView.h
+++ b/kdgantt/KDGanttView.h
@@ -325,7 +325,7 @@ public:
virtual void lvStartDrag (KDGanttViewItem*);
virtual bool lvDragMoveEvent (TQDragMoveEvent * e,KDGanttViewItem*, KDGanttViewItem*);
virtual void lvDragEnterEvent (TQDragEnterEvent * e );
- virtual TQSize tqsizeHint() const;
+ virtual TQSize sizeHint() const;
KDGanttViewItem* getItemByName( const TQString& name ) const;
TQDateTime getDateTimeForCoordX(int coordX, bool global = true ) const;
KDGanttViewItem* getItemByListViewPos( const TQPoint& pos ) const;
diff --git a/kdgantt/KDGanttViewItemDrag.cpp b/kdgantt/KDGanttViewItemDrag.cpp
index c73eff67..92c60201 100644
--- a/kdgantt/KDGanttViewItemDrag.cpp
+++ b/kdgantt/KDGanttViewItemDrag.cpp
@@ -86,7 +86,7 @@ KDGanttViewItemDrag::KDGanttViewItemDrag( KDGanttViewItem* item , TQWidget *sour
\param c the format of the data
\return the encoded data of the drag object
*/
-TQByteArray KDGanttViewItemDrag::tqencodedData( const char * c) const
+TQByteArray KDGanttViewItemDrag::encodedData( const char * c) const
{
TQString s ( c );
if ( s == "x-application/x-KDGanttViewItemDrag" ) {
@@ -132,7 +132,7 @@ bool KDGanttViewItemDrag::canDecode ( const TQMimeSource * e )
bool KDGanttViewItemDrag::decode ( const TQMimeSource * e , TQString & string)
{
TQByteArray arr;
- arr = e->tqencodedData( "x-application/x-KDGanttViewItemDrag");
+ arr = e->encodedData( "x-application/x-KDGanttViewItemDrag");
TQDataStream s( arr, IO_ReadOnly );
s >> string;
return true;
diff --git a/kdgantt/KDGanttViewItemDrag.h b/kdgantt/KDGanttViewItemDrag.h
index a4d6cb6f..9219c918 100644
--- a/kdgantt/KDGanttViewItemDrag.h
+++ b/kdgantt/KDGanttViewItemDrag.h
@@ -44,7 +44,7 @@ class KDGanttViewItemDrag :public TQStoredDrag
public:
KDGanttViewItemDrag(KDGanttViewItem* item, TQWidget *source, const char * name ) ;
- TQByteArray tqencodedData( const char * c) const;
+ TQByteArray encodedData( const char * c) const;
KDGanttViewItem* getItem();
static bool canDecode ( const TQMimeSource * e );
static bool decode ( const TQMimeSource * e, TQString & );
diff --git a/kdgantt/KDGanttViewSubwidgets.cpp b/kdgantt/KDGanttViewSubwidgets.cpp
index d158c75a..ab8b5a92 100644
--- a/kdgantt/KDGanttViewSubwidgets.cpp
+++ b/kdgantt/KDGanttViewSubwidgets.cpp
@@ -702,12 +702,12 @@ KDTimeHeaderWidget:: KDTimeHeaderWidget( TQWidget* parent,KDGanttView* gant )
mySizeHint = 0;
myGanttView = gant;
flagDoNotRecomputeAfterChange = true;
- TQDateTime start = (TQDateTime::tqcurrentDateTime ()).addSecs(-3600);
+ TQDateTime start = (TQDateTime::currentDateTime ()).addSecs(-3600);
setHorizonStart(start);
setHorizonEnd( start.addSecs(3600*2));
flagStartTimeSet = false;
flagEndTimeSet = false;
- myCenterDateTime = TQDateTime::tqcurrentDateTime ();
+ myCenterDateTime = TQDateTime::currentDateTime ();
setScale(KDGanttView::Auto);
//setScale(KDGanttView::Hour);
myMaxScale = KDGanttView::Month;
@@ -2098,7 +2098,7 @@ void KDTimeHeaderWidget::computeTicks(bool doNotComputeRealScale)
TQPainter p(this);
int Width, Height;
TQString testTextMinor,testTextMajor, tempStr;
- TQRect tqitemRectMinor, tqitemRectMajor;
+ TQRect itemRectMinor, itemRectMajor;
TQDate tempDate = myRealStart.date();
myRealEnd = myRealStart;
// preparing the testtext for the differennt scales
@@ -2121,25 +2121,25 @@ void KDTimeHeaderWidget::computeTicks(bool doNotComputeRealScale)
testTextMinor = "12 AM";
testTextMajor = "Mon Aug 30, x";
if ( yearFormat() != KDGanttView::NoDate )
- testTextMajor += getYear(TQDate::tqcurrentDate());
+ testTextMajor += getYear(TQDate::currentDate());
minorPerMajor = 2400;
break;
case KDGanttView::Day:
minorItems = minorItems/(60*24);
testTextMinor = "88";
- testTextMajor = "Aug 30, x"+getYear(TQDate::tqcurrentDate());
+ testTextMajor = "Aug 30, x"+getYear(TQDate::currentDate());
minorPerMajor = 700;
break;
case KDGanttView::Week:
minorItems = minorItems/(60*24*7);
testTextMinor = "88";
- testTextMajor = "Aug x"+getYear(TQDate::tqcurrentDate());
+ testTextMajor = "Aug x"+getYear(TQDate::currentDate());
minorPerMajor = 435; // 435 = 365days/12months/7days * 100
break;
case KDGanttView::Month:
minorItems = (minorItems*12)/(60*24*365);
testTextMinor = "M";
- testTextMajor = "x"+getYear(TQDate::tqcurrentDate());
+ testTextMajor = "x"+getYear(TQDate::currentDate());
minorPerMajor = 1200;
break;
case KDGanttView::Auto:
@@ -2147,12 +2147,12 @@ void KDTimeHeaderWidget::computeTicks(bool doNotComputeRealScale)
qDebug(" RealScale == Auto : This may not be! ");
break;
}
- tqitemRectMinor = p.boundingRect ( 10, 10, 2, 2, TQt::AlignLeft,testTextMinor);
- tqitemRectMajor = p.boundingRect ( 10, 10, 2, 2, TQt::AlignLeft,testTextMajor);
+ itemRectMinor = p.boundingRect ( 10, 10, 2, 2, TQt::AlignLeft,testTextMinor);
+ itemRectMajor = p.boundingRect ( 10, 10, 2, 2, TQt::AlignLeft,testTextMajor);
p.end();
//qDebug(" tempMinorScaleCount %d ", tempMinorScaleCount);
- Height = tqitemRectMinor.height()+tqitemRectMajor.height()+11;
- Width = (tqitemRectMinor.width()+5);
+ Height = itemRectMinor.height()+itemRectMajor.height()+11;
+ Width = (itemRectMinor.width()+5);
if (Width < minimumColumnWidth()) Width = minimumColumnWidth();
// if the desired width is greater than the maximum width of this widget
// increase the minorscalecount
@@ -2209,7 +2209,7 @@ void KDTimeHeaderWidget::computeTicks(bool doNotComputeRealScale)
// checking, if enough space for majorscale
// if not, increasing MajorScaleCount
- while ((minorPerMajor*Width)/100 < tqitemRectMajor.width()) {
+ while ((minorPerMajor*Width)/100 < itemRectMajor.width()) {
minorPerMajor = minorPerMajor/tempMajorScaleCount;
++tempMajorScaleCount;
minorPerMajor = minorPerMajor*tempMajorScaleCount;
@@ -2225,7 +2225,7 @@ void KDTimeHeaderWidget::computeTicks(bool doNotComputeRealScale)
resize( Width, Height );
emit sizeChanged( Width );
}
- myMajorGridHeight = tqitemRectMajor.height()+5;
+ myMajorGridHeight = itemRectMajor.height()+5;
TQTime tempTime = myRealStart.time();
TQDateTime tempDateTime;
int i;
@@ -2643,7 +2643,7 @@ TQSize KDLegendWidget::legendSize()
TQSize KDLegendWidget::legendSizeHint()
{
TQApplication::sendPostedEvents( 0, TQEvent::LayoutHint );
- return TQSize( myLegend->tqsizeHint().width(), myLegend->tqsizeHint().height()+scroll->horizontalScrollBar()->height());
+ return TQSize( myLegend->sizeHint().width(), myLegend->sizeHint().height()+scroll->horizontalScrollBar()->height());
}
@@ -2961,7 +2961,7 @@ void KDListView::drawAllContents(TQPainter * p, int cx, int cy, int cw, int ch)
p->translate( rleft, crtop );
//kdDebug()<<k_funcinfo<<"paintBranches: "<<current->i->text(0)<<endl;
- current->i->paintBranches( p, tqcolorGroup(), treeStepSize(),
+ current->i->paintBranches( p, colorGroup(), treeStepSize(),
rtop - crtop, r.height() );
p->restore();
}
@@ -3506,7 +3506,7 @@ TQString KDGanttCanvasView::getWhatsThisText(TQPoint p)
void KDGanttCanvasView::contentsMousePressEvent ( TQMouseEvent * e )
{
//qDebug("mousepress! %d ", this);
- //qDebug("focus %d ",tqApp->tqfocusWidget());
+ //qDebug("focus %d ",tqApp->focusWidget());
setFocus();
currentLink = 0;
currentItem = 0;
diff --git a/kdgantt/itemAttributeDialog.ui b/kdgantt/itemAttributeDialog.ui
index a3616dca..a98d65a1 100644
--- a/kdgantt/itemAttributeDialog.ui
+++ b/kdgantt/itemAttributeDialog.ui
@@ -64,7 +64,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="tqsizeHint">
+ <property name="sizeHint">
<size>
<width>0</width>
<height>16</height>
@@ -383,7 +383,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="tqsizeHint">
+ <property name="sizeHint">
<size>
<width>0</width>
<height>16</height>
diff --git a/kdgantt/qlayoutengine_p.h b/kdgantt/qlayoutengine_p.h
index e87eb5de..4042e218 100644
--- a/kdgantt/qlayoutengine_p.h
+++ b/kdgantt/qlayoutengine_p.h
@@ -62,15 +62,15 @@
#ifndef TQT_NO_LAYOUT
struct QLayoutStruct
{
- void initParameters() { tqminimumSize = tqsizeHint = 0;
- tqmaximumSize = TQWIDGETSIZE_MAX; expansive = FALSE; empty = TRUE; }
+ void initParameters() { minimumSize = sizeHint = 0;
+ maximumSize = TQWIDGETSIZE_MAX; expansive = FALSE; empty = TRUE; }
void init() { stretch = 0; initParameters(); }
//permanent storage:
int stretch;
//parameters:
- TQCOORD tqsizeHint;
- TQCOORD tqmaximumSize;
- TQCOORD tqminimumSize;
+ TQCOORD sizeHint;
+ TQCOORD maximumSize;
+ TQCOORD minimumSize;
bool expansive;
bool empty;
//temporary storage: