summaryrefslogtreecommitdiffstats
path: root/kspread/kspread_canvas.cc
diff options
context:
space:
mode:
Diffstat (limited to 'kspread/kspread_canvas.cc')
-rw-r--r--kspread/kspread_canvas.cc70
1 files changed, 35 insertions, 35 deletions
diff --git a/kspread/kspread_canvas.cc b/kspread/kspread_canvas.cc
index 6b7e191f4..4d091a3d1 100644
--- a/kspread/kspread_canvas.cc
+++ b/kspread/kspread_canvas.cc
@@ -1011,7 +1011,7 @@ void Canvas::mouseMoveEvent( TQMouseEvent * _ev )
(int) _ev->y() );
if ( ( obj = getObject( p, activeSheet() ) ) && obj->isSelected() )
{
- KoRect const bound = obj->tqgeometry();
+ KoRect const bound = obj->geometry();
TQRect zoomedBound = doc()->zoomRect( KoRect(bound.left(), bound.top(),
bound.width(),
bound.height() ) );
@@ -1056,7 +1056,7 @@ void Canvas::mouseMoveEvent( TQMouseEvent * _ev )
}
//Check to see if the mouse is over a highlight range size grip and if it is, change the cursor
- //tqshape to a resize arrow
+ //shape to a resize arrow
if (highlightRangeSizeGripAt(ev_PosX,ev_PosY))
{
if ( sheet->layoutDirection()==Sheet::RightToLeft )
@@ -1177,7 +1177,7 @@ void Canvas::mouseReleaseEvent( TQMouseEvent* /*_ev*/)
doc()->addCommand( cmd );
} else
{
- tqrepaint();
+ repaint();
}
d->m_isMoving = false;
break;
@@ -1253,13 +1253,13 @@ void Canvas::processLeftClickAnchor()
if ( KRun::isExecutableFile( d->anchor , type ) )
{
- //TQString question = i18n("Do you want to open this link to '%1'?\n").tqarg(d->anchor);
+ //TQString question = i18n("Do you want to open this link to '%1'?\n").arg(d->anchor);
//question += i18n("Note that opening a link to a local file may "
// "compromise your system's security.");
TQString question = i18n("This link points to the program or script '%1'.\n"
- "Malicious programs can harm your computer. Are you sure that you want to run this program?").tqarg(d->anchor);
+ "Malicious programs can harm your computer. Are you sure that you want to run this program?").arg(d->anchor);
// this will also start local programs, so adding a "don't warn again"
// checkbox will probably be too dangerous
int choice = KMessageBox::warningYesNo(this, question, i18n("Open Link?"));
@@ -1352,9 +1352,9 @@ void Canvas::mousePressEvent( TQMouseEvent * _ev )
d->m_resizeObject = obj;
- d->m_ratio = static_cast<double>( obj->tqgeometry().width() ) /
- static_cast<double>( obj->tqgeometry().height() );
- d->m_rectBeforeResize = obj->tqgeometry();
+ d->m_ratio = static_cast<double>( obj->geometry().width() ) /
+ static_cast<double>( obj->geometry().height() );
+ d->m_rectBeforeResize = obj->geometry();
}
KoPoint docPoint ( doc()->unzoomPoint( _ev->pos() ) );
@@ -2150,13 +2150,13 @@ void Canvas::processEscapeKey(TQKeyEvent * event)
case MT_RESIZE_RU:
case MT_RESIZE_RD:
{
- TQRect oldBoundingRect = doc()->zoomRect( d->m_resizeObject->tqgeometry()/*getRepaintRect()*/);
+ TQRect oldBoundingRect = doc()->zoomRect( d->m_resizeObject->geometry()/*getRepaintRect()*/);
d->m_resizeObject->setGeometry( d->m_rectBeforeResize );
oldBoundingRect.moveBy( (int)( -xOffset()*doc()->zoomedResolutionX() ) ,
(int)( -yOffset() * doc()->zoomedResolutionY()) );
activeSheet()->setRegionPaintDirty( oldBoundingRect );
- tqrepaint( oldBoundingRect );
+ repaint( oldBoundingRect );
repaintObject( d->m_resizeObject );
d->m_ratio = 0.0;
d->m_resizeObject = 0;
@@ -3290,7 +3290,7 @@ KSpread::EmbeddedObject *Canvas::getObject( const TQPoint &pos, Sheet *_sheet )
{
if ( itObject.current()->sheet() == _sheet )
{
- KoRect const bound = ( itObject.current() )->tqgeometry();
+ KoRect const bound = ( itObject.current() )->geometry();
TQRect zoomedBound = doc()->zoomRect( KoRect(bound.left(), bound.top(),
bound.width(),
bound.height() ) );
@@ -3429,7 +3429,7 @@ void Canvas::resizeObject( ModifyType _modType, const KoPoint & point, bool keep
{
EmbeddedObject *obj = d->m_resizeObject;
- KoRect objRect = obj->tqgeometry();
+ KoRect objRect = obj->geometry();
objRect.moveBy( -xOffset(), -yOffset() );
TQRect oldBoundingRect( doc()->zoomRect( objRect ) );
@@ -3575,7 +3575,7 @@ void Canvas::resizeObject( ModifyType _modType, const KoPoint & point, bool keep
// m_gl.repaintSnapping( sp, snapStatus );
// }
- tqrepaint( oldBoundingRect );
+ repaint( oldBoundingRect );
repaintObject( obj );
emit objectSizeChanged();
}
@@ -3586,12 +3586,12 @@ void Canvas::finishResizeObject( const TQString &/*name*/, bool /*tqlayout*/ )
{
if ( d->m_resizeObject )
{
- KoPoint move = KoPoint( d->m_resizeObject->tqgeometry().x() - d->m_rectBeforeResize.x(),
- d->m_resizeObject->tqgeometry().y() - d->m_rectBeforeResize.y() );
- KoSize size = KoSize( d->m_resizeObject->tqgeometry().width() - d->m_rectBeforeResize.width(),
- d->m_resizeObject->tqgeometry().height() - d->m_rectBeforeResize.height() );
+ KoPoint move = KoPoint( d->m_resizeObject->geometry().x() - d->m_rectBeforeResize.x(),
+ d->m_resizeObject->geometry().y() - d->m_rectBeforeResize.y() );
+ KoSize size = KoSize( d->m_resizeObject->geometry().width() - d->m_rectBeforeResize.width(),
+ d->m_resizeObject->geometry().height() - d->m_rectBeforeResize.height() );
- if ( ( d->m_resizeObject->tqgeometry() ) != d->m_rectBeforeResize )
+ if ( ( d->m_resizeObject->geometry() ) != d->m_rectBeforeResize )
{
ChangeObjectGeometryCommand *resizeCmd = new ChangeObjectGeometryCommand( d->m_resizeObject, move, size );
// the command is not executed as the object is allready resized.
@@ -3669,7 +3669,7 @@ void Canvas::deleteEditor (bool saveChanges, bool array)
TQString t = d->cellEditor->text();
// Delete the cell editor first and after that update the document.
- // That means we get a synchronous tqrepaint after the cell editor
+ // That means we get a synchronous repaint after the cell editor
// widget is gone. Otherwise we may get painting errors.
delete d->cellEditor;
d->cellEditor = 0;
@@ -3819,8 +3819,8 @@ bool Canvas::createEditor( EditorType ed, bool addFocus, bool captureArrowKeys )
void Canvas::repaintObject( EmbeddedObject *obj )
{
- //Calculate where the object appears on the canvas widget and then tqrepaint that part of the widget
- TQRect canvasRelativeGeometry = doc()->zoomRect( obj->tqgeometry() );
+ //Calculate where the object appears on the canvas widget and then repaint that part of the widget
+ TQRect canvasRelativeGeometry = doc()->zoomRect( obj->geometry() );
canvasRelativeGeometry.moveBy( (int)( -xOffset()*doc()->zoomedResolutionX() ) ,
(int)( -yOffset() * doc()->zoomedResolutionY()) );
@@ -3828,17 +3828,17 @@ void Canvas::repaintObject( EmbeddedObject *obj )
/* if ( !obj->isSelected() )
{
- KoRect g = obj->tqgeometry();
+ KoRect g = obj->geometry();
g.moveBy( -xOffset(), -yOffset() );
- TQRect tqgeometry( doc()->zoomRect( g ) );
+ TQRect geometry( doc()->zoomRect( g ) );
- update( tqgeometry );
+ update( geometry );
}
else
{
TQPainter p(this);
p.translate( -xOffset() * doc()->zoomedResolutionX() , -yOffset() * doc()->zoomedResolutionY() );
- obj->draw(&p); //this goes faster than calling tqrepaint
+ obj->draw(&p); //this goes faster than calling repaint
p.end();
}*/
}
@@ -3888,7 +3888,7 @@ void Canvas::copyOasisObjects()
for( ; itObject.current(); ++itObject )
{
if ( itObject.current()->isSelected() )
- p.drawPixmap( itObject.current()->tqgeometry().toTQRect().left() - r.left(), itObject.current()->tqgeometry().toTQRect().top() - r.top(), itObject.current()->toPixmap( 1.0 , 1.0 ) );
+ p.drawPixmap( itObject.current()->geometry().toTQRect().left() - r.left(), itObject.current()->geometry().toTQRect().top() - r.top(), itObject.current()->toPixmap( 1.0 , 1.0 ) );
}
p.end();
if (!pixmap.isNull())
@@ -4202,7 +4202,7 @@ void Canvas::paintUpdates()
paintHighlightedRanges(painter, unzoomedRect);
paintNormalMarker(painter, unzoomedRect);
- //restore clip region with tqchildren area
+ //restore clip region with children area
painter.restore();
//painter.setClipRegion( rgnComplete );
}
@@ -4223,7 +4223,7 @@ void Canvas::clipoutChildren( TQPainter& painter ) const
{
if ( ( itObject.current() )->sheet() == activeSheet() )
{
- TQRect childGeometry = doc()->zoomRect( itObject.current()->tqgeometry());
+ TQRect childGeometry = doc()->zoomRect( itObject.current()->geometry());
//The clipping region is given in device coordinates
//so subtract the current offset (scroll position) of the canvas
@@ -4232,7 +4232,7 @@ void Canvas::clipoutChildren( TQPainter& painter ) const
if (painter.window().intersects(childGeometry))
rgn -= childGeometry;
- //painter.fillRect( doc()->zoomRect( itObject.current()->tqgeometry() ), TQColor("red" ) );
+ //painter.fillRect( doc()->zoomRect( itObject.current()->geometry() ), TQColor("red" ) );
}
}
@@ -4263,11 +4263,11 @@ void Canvas::paintChildren( TQPainter& painter, TQWMatrix& /*matrix*/ )
for( ; itObject.current(); ++itObject )
{
- TQRect const zoomedObjectGeometry = doc()->zoomRect( itObject.current()->tqgeometry() );
+ TQRect const zoomedObjectGeometry = doc()->zoomRect( itObject.current()->geometry() );
if ( ( itObject.current() )->sheet() == activeSheet() &&
zoomedWindowGeometry.intersects( zoomedObjectGeometry ) )
{
- //To prevent unnecessary redrawing of the embedded object, we only tqrepaint
+ //To prevent unnecessary redrawing of the embedded object, we only repaint
//if one or more of the cells underneath the object has been marked as 'dirty'.
TQRect canvasRelativeGeometry = zoomedObjectGeometry;
@@ -5036,9 +5036,9 @@ void VBorder::paintSizeIndicator( int mouseY, bool firstTime )
TQString tmpSize;
if ( m_iResizePos != y )
- tmpSize = i18n("Height: %1 %2").tqarg( KoUnit::toUserValue( m_pCanvas->doc()->unzoomItY( m_iResizePos - y ),
+ tmpSize = i18n("Height: %1 %2").arg( KoUnit::toUserValue( m_pCanvas->doc()->unzoomItY( m_iResizePos - y ),
m_pView->doc()->unit() ) )
- .tqarg( m_pView->doc()->unitName() );
+ .arg( m_pView->doc()->unitName() );
else
tmpSize = i18n( "Hide Row" );
@@ -5738,9 +5738,9 @@ void HBorder::paintSizeIndicator( int mouseX, bool firstTime )
TQString tmpSize;
if ( m_iResizePos != x )
tmpSize = i18n("Width: %1 %2")
- .tqarg( KGlobal::locale()->formatNumber( KoUnit::toUserValue( m_pCanvas->doc()->unzoomItX( (sheet->layoutDirection()==Sheet::RightToLeft) ? x - m_iResizePos : m_iResizePos - x ),
+ .arg( KGlobal::locale()->formatNumber( KoUnit::toUserValue( m_pCanvas->doc()->unzoomItX( (sheet->layoutDirection()==Sheet::RightToLeft) ? x - m_iResizePos : m_iResizePos - x ),
m_pView->doc()->unit() )))
- .tqarg( m_pView->doc()->unitName() );
+ .arg( m_pView->doc()->unitName() );
else
tmpSize = i18n( "Hide Column" );