summaryrefslogtreecommitdiffstats
path: root/knights/tab_pgnview.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'knights/tab_pgnview.cpp')
-rw-r--r--knights/tab_pgnview.cpp90
1 files changed, 45 insertions, 45 deletions
diff --git a/knights/tab_pgnview.cpp b/knights/tab_pgnview.cpp
index 75a1fda..51bf57c 100644
--- a/knights/tab_pgnview.cpp
+++ b/knights/tab_pgnview.cpp
@@ -60,43 +60,43 @@ tab_pgnView::~tab_pgnView()
void tab_pgnView::init( void )
{
/* Replace macros with data */
- document.tqreplace( TQRegExp( "%site%" ), myParent->TAG_Site );
- document.tqreplace( TQRegExp( "%date%" ), myParent->TAG_Date );
- document.tqreplace( TQRegExp( "%round%" ), myParent->TAG_Round );
- document.tqreplace( TQRegExp( "%result%" ), myParent->TAG_Result );
- document.tqreplace( TQRegExp( "%white%" ), myParent->TAG_White );
- document.tqreplace( TQRegExp( "%whitetitle%" ), myParent->TAG_WhiteTitle );
- document.tqreplace( TQRegExp( "%whiteelo%" ), myParent->TAG_WhiteElo );
- document.tqreplace( TQRegExp( "%whiteuscf%" ), myParent->TAG_WhiteUSCF );
- document.tqreplace( TQRegExp( "%whitena%" ), myParent->TAG_WhiteNA );
- document.tqreplace( TQRegExp( "%whitetype%" ), myParent->TAG_WhiteType );
- document.tqreplace( TQRegExp( "%black%" ), myParent->TAG_Black );
- document.tqreplace( TQRegExp( "%blacktitle%" ), myParent->TAG_BlackTitle );
- document.tqreplace( TQRegExp( "%blackelo%" ), myParent->TAG_BlackElo );
- document.tqreplace( TQRegExp( "%blackuscf%" ), myParent->TAG_BlackUSCF );
- document.tqreplace( TQRegExp( "%blackna%" ), myParent->TAG_BlackNA );
- document.tqreplace( TQRegExp( "%blacktype%" ), myParent->TAG_BlackType );
- document.tqreplace( TQRegExp( "%time%" ), myParent->TAG_Time );
- document.tqreplace( TQRegExp( "%utctime%" ), myParent->TAG_UTCTime );
- document.tqreplace( TQRegExp( "%utcdate%" ), myParent->TAG_UTCDate );
- document.tqreplace( TQRegExp( "%event%" ), myParent->TAG_Event );
- document.tqreplace( TQRegExp( "%eventdate%" ), myParent->TAG_EventDate );
- document.tqreplace( TQRegExp( "%eventsponsor"), myParent->TAG_EventSponsor );
- document.tqreplace( TQRegExp( "%section%" ), myParent->TAG_Section );
- document.tqreplace( TQRegExp( "%stage%" ), myParent->TAG_Stage );
- document.tqreplace( TQRegExp( "%board%" ), myParent->TAG_Board );
- document.tqreplace( TQRegExp( "%opening%" ), myParent->TAG_Opening );
- document.tqreplace( TQRegExp( "%variation%" ), myParent->TAG_Variation );
- document.tqreplace( TQRegExp( "%subvariation%" ), myParent->TAG_SubVariation );
- document.tqreplace( TQRegExp( "%eco%" ), myParent->TAG_ECO );
- document.tqreplace( TQRegExp( "%nic%" ), myParent->TAG_NIC );
- document.tqreplace( TQRegExp( "%timecontrol%" ), myParent->TAG_TimeControl );
- document.tqreplace( TQRegExp( "%termination%" ), myParent->TAG_Termination );
- document.tqreplace( TQRegExp( "%setup%" ), myParent->TAG_SetUp );
- document.tqreplace( TQRegExp( "%fen%" ), myParent->TAG_FEN );
- document.tqreplace( TQRegExp( "%annotator%" ), myParent->TAG_Annotator );
- document.tqreplace( TQRegExp( "%mode%" ), myParent->TAG_Mode );
- document.tqreplace( TQRegExp( "%plycount%" ), myParent->TAG_PlyCount );
+ document.replace( TQRegExp( "%site%" ), myParent->TAG_Site );
+ document.replace( TQRegExp( "%date%" ), myParent->TAG_Date );
+ document.replace( TQRegExp( "%round%" ), myParent->TAG_Round );
+ document.replace( TQRegExp( "%result%" ), myParent->TAG_Result );
+ document.replace( TQRegExp( "%white%" ), myParent->TAG_White );
+ document.replace( TQRegExp( "%whitetitle%" ), myParent->TAG_WhiteTitle );
+ document.replace( TQRegExp( "%whiteelo%" ), myParent->TAG_WhiteElo );
+ document.replace( TQRegExp( "%whiteuscf%" ), myParent->TAG_WhiteUSCF );
+ document.replace( TQRegExp( "%whitena%" ), myParent->TAG_WhiteNA );
+ document.replace( TQRegExp( "%whitetype%" ), myParent->TAG_WhiteType );
+ document.replace( TQRegExp( "%black%" ), myParent->TAG_Black );
+ document.replace( TQRegExp( "%blacktitle%" ), myParent->TAG_BlackTitle );
+ document.replace( TQRegExp( "%blackelo%" ), myParent->TAG_BlackElo );
+ document.replace( TQRegExp( "%blackuscf%" ), myParent->TAG_BlackUSCF );
+ document.replace( TQRegExp( "%blackna%" ), myParent->TAG_BlackNA );
+ document.replace( TQRegExp( "%blacktype%" ), myParent->TAG_BlackType );
+ document.replace( TQRegExp( "%time%" ), myParent->TAG_Time );
+ document.replace( TQRegExp( "%utctime%" ), myParent->TAG_UTCTime );
+ document.replace( TQRegExp( "%utcdate%" ), myParent->TAG_UTCDate );
+ document.replace( TQRegExp( "%event%" ), myParent->TAG_Event );
+ document.replace( TQRegExp( "%eventdate%" ), myParent->TAG_EventDate );
+ document.replace( TQRegExp( "%eventsponsor"), myParent->TAG_EventSponsor );
+ document.replace( TQRegExp( "%section%" ), myParent->TAG_Section );
+ document.replace( TQRegExp( "%stage%" ), myParent->TAG_Stage );
+ document.replace( TQRegExp( "%board%" ), myParent->TAG_Board );
+ document.replace( TQRegExp( "%opening%" ), myParent->TAG_Opening );
+ document.replace( TQRegExp( "%variation%" ), myParent->TAG_Variation );
+ document.replace( TQRegExp( "%subvariation%" ), myParent->TAG_SubVariation );
+ document.replace( TQRegExp( "%eco%" ), myParent->TAG_ECO );
+ document.replace( TQRegExp( "%nic%" ), myParent->TAG_NIC );
+ document.replace( TQRegExp( "%timecontrol%" ), myParent->TAG_TimeControl );
+ document.replace( TQRegExp( "%termination%" ), myParent->TAG_Termination );
+ document.replace( TQRegExp( "%setup%" ), myParent->TAG_SetUp );
+ document.replace( TQRegExp( "%fen%" ), myParent->TAG_FEN );
+ document.replace( TQRegExp( "%annotator%" ), myParent->TAG_Annotator );
+ document.replace( TQRegExp( "%mode%" ), myParent->TAG_Mode );
+ document.replace( TQRegExp( "%plycount%" ), myParent->TAG_PlyCount );
/* Get the White Player's Image */
TQPixmap wi = myResource->loadSCIDImage( myParent->TAG_White );
@@ -110,7 +110,7 @@ void tab_pgnView::init( void )
whiteImage = new KTempFile();
whiteImage->setAutoDelete( TRUE );
wi.save( whiteImage->name(), "PNG" );
- document.tqreplace( TQRegExp( "%whiteimage%" ), whiteImage->name() );
+ document.replace( TQRegExp( "%whiteimage%" ), whiteImage->name() );
/* Get the Black Player's Image */
TQPixmap bi = myResource->loadSCIDImage( myParent->TAG_Black );
@@ -124,7 +124,7 @@ void tab_pgnView::init( void )
blackImage = new KTempFile();
blackImage->setAutoDelete( TRUE );
bi.save( blackImage->name(), "PNG" );
- document.tqreplace( TQRegExp( "%blackimage%" ), blackImage->name() );
+ document.replace( TQRegExp( "%blackimage%" ), blackImage->name() );
/* Obtain the move data */
TQString moves;
@@ -141,16 +141,16 @@ void tab_pgnView::init( void )
/* Do some formatting and then merge the strings */
for( TQStringList::Iterator i = list->begin(); i != list->end(); i++ )
{
- (*i).tqreplace( TQRegExp( "[^\\0040-\\0176]" ), "" );
- (*i).tqreplace( TQRegExp( "\\(" ), "<i>(" );
- (*i).tqreplace( TQRegExp( "\\)" ), ")</i>" );
- (*i).tqreplace( TQRegExp( "\\{" ), "<b>{" );
- (*i).tqreplace( TQRegExp( "\\}" ), "}</b>" );
+ (*i).replace( TQRegExp( "[^\\0040-\\0176]" ), "" );
+ (*i).replace( TQRegExp( "\\(" ), "<i>(" );
+ (*i).replace( TQRegExp( "\\)" ), ")</i>" );
+ (*i).replace( TQRegExp( "\\{" ), "<b>{" );
+ (*i).replace( TQRegExp( "\\}" ), "}</b>" );
}
moves = list->join( " " );
delete list;
- int pos = document.tqfind( "%moves%" );
+ int pos = document.find( "%moves%" );
if( pos != -1 )
{
document.remove( (unsigned int)pos, 7 );