|
|
|
@ -60,7 +60,7 @@
|
|
|
|
|
#include <tqcursor.h>
|
|
|
|
|
#include <tqgrid.h>
|
|
|
|
|
#include <tqlabel.h>
|
|
|
|
|
#include <tqlayout.h>
|
|
|
|
|
#include <layout.h>
|
|
|
|
|
#include <tqradiobutton.h>
|
|
|
|
|
#include <tqrect.h>
|
|
|
|
|
#include <tqregexp.h>
|
|
|
|
@ -423,10 +423,10 @@ void KRenameImpl::setupPage2()
|
|
|
|
|
groupOptions = new TQButtonGroup( page_2 );
|
|
|
|
|
groupOptions->setTitle( i18n( "O&ptions" ) );
|
|
|
|
|
groupOptions->setColumnLayout(0, Qt::Vertical );
|
|
|
|
|
groupOptions->tqlayout()->setSpacing( 6 );
|
|
|
|
|
groupOptions->tqlayout()->setMargin( 11 );
|
|
|
|
|
groupOptionsLayout = new TQVBoxLayout( groupOptions->tqlayout() );
|
|
|
|
|
groupOptionsLayout->tqsetAlignment( TQt::AlignTop );
|
|
|
|
|
groupOptions->layout()->setSpacing( 6 );
|
|
|
|
|
groupOptions->layout()->setMargin( 11 );
|
|
|
|
|
groupOptionsLayout = new TQVBoxLayout( groupOptions->layout() );
|
|
|
|
|
groupOptionsLayout->setAlignment( TQt::AlignTop );
|
|
|
|
|
|
|
|
|
|
optionRename = new TQRadioButton( groupOptions );
|
|
|
|
|
optionRename->setText( i18n( "&Rename input files" ) );
|
|
|
|
@ -619,7 +619,7 @@ void KRenameImpl::setupFileTab1()
|
|
|
|
|
|
|
|
|
|
TQSpacerItem* spacer_9 = new TQSpacerItem( 200, 20, TQSizePolicy::Maximum, TQSizePolicy::Maximum );
|
|
|
|
|
|
|
|
|
|
TQVBoxLayout* tqlayout = new TQVBoxLayout( tab );
|
|
|
|
|
TQVBoxLayout* layout = new TQVBoxLayout( tab );
|
|
|
|
|
TQHBoxLayout* Layout1 = new TQHBoxLayout( 0, 6, 6 );
|
|
|
|
|
TQHBoxLayout* Layout2 = new TQHBoxLayout( 0, 6, 6 );
|
|
|
|
|
TQHBoxLayout* ExtensionLayout = new TQHBoxLayout( 0, 6, 6 );
|
|
|
|
@ -641,10 +641,10 @@ void KRenameImpl::setupFileTab1()
|
|
|
|
|
ExtensionLayout->addWidget( new TQLabel( i18n("File extension starts at:"), tab ) );
|
|
|
|
|
ExtensionLayout->addWidget( comboExtension );
|
|
|
|
|
|
|
|
|
|
tqlayout->addLayout( Layout1 );
|
|
|
|
|
tqlayout->addLayout( ExtensionLayout );
|
|
|
|
|
tqlayout->addLayout( Layout2 );
|
|
|
|
|
tqlayout->addItem( spacer_9 );
|
|
|
|
|
layout->addLayout( Layout1 );
|
|
|
|
|
layout->addLayout( ExtensionLayout );
|
|
|
|
|
layout->addLayout( Layout2 );
|
|
|
|
|
layout->addItem( spacer_9 );
|
|
|
|
|
|
|
|
|
|
fileTab->addWidget( tab, ID_TAB );
|
|
|
|
|
}
|
|
|
|
@ -653,7 +653,7 @@ void KRenameImpl::setupFileTab2()
|
|
|
|
|
{
|
|
|
|
|
TQWidget* tab = new TQWidget( page_4 );
|
|
|
|
|
|
|
|
|
|
TQHBoxLayout* tqlayout = new TQHBoxLayout( tab, 6, 6 );
|
|
|
|
|
TQHBoxLayout* layout = new TQHBoxLayout( tab, 6, 6 );
|
|
|
|
|
|
|
|
|
|
TQVGroupBox* vgroup1 = new TQVGroupBox( i18n("&Filename"), tab );
|
|
|
|
|
TQGrid* grid = new TQGrid( 4, vgroup1 );
|
|
|
|
@ -708,8 +708,8 @@ void KRenameImpl::setupFileTab2()
|
|
|
|
|
buttonEasyReplace = new KPushButton( i18n("&Find and Replace..."), rightBox );
|
|
|
|
|
buttonEasyReplace->setIconSet( SmallIconSet("find") );
|
|
|
|
|
|
|
|
|
|
tqlayout->addWidget( vgroup1 );
|
|
|
|
|
tqlayout->addWidget( rightBox );
|
|
|
|
|
layout->addWidget( vgroup1 );
|
|
|
|
|
layout->addWidget( rightBox );
|
|
|
|
|
|
|
|
|
|
comboKRenamePrefix->insertItem( "" );
|
|
|
|
|
comboKRenamePrefix->insertItem( i18n("Number") );
|
|
|
|
@ -737,10 +737,10 @@ void KRenameImpl::setupFileTab2()
|
|
|
|
|
buttonEasy3->setIconSet( SmallIcon("help") );
|
|
|
|
|
buttonEasy4->setIconSet( SmallIcon("help") );
|
|
|
|
|
|
|
|
|
|
buttonEasy1->tqsetSizePolicy( TQSizePolicy::Maximum, TQSizePolicy::Maximum );
|
|
|
|
|
buttonEasy2->tqsetSizePolicy( TQSizePolicy::Maximum, TQSizePolicy::Maximum );
|
|
|
|
|
buttonEasy3->tqsetSizePolicy( TQSizePolicy::Maximum, TQSizePolicy::Maximum );
|
|
|
|
|
buttonEasy4->tqsetSizePolicy( TQSizePolicy::Maximum, TQSizePolicy::Maximum );
|
|
|
|
|
buttonEasy1->setSizePolicy( TQSizePolicy::Maximum, TQSizePolicy::Maximum );
|
|
|
|
|
buttonEasy2->setSizePolicy( TQSizePolicy::Maximum, TQSizePolicy::Maximum );
|
|
|
|
|
buttonEasy3->setSizePolicy( TQSizePolicy::Maximum, TQSizePolicy::Maximum );
|
|
|
|
|
buttonEasy4->setSizePolicy( TQSizePolicy::Maximum, TQSizePolicy::Maximum );
|
|
|
|
|
|
|
|
|
|
const TQString easy_text( i18n("<qt>Insert a special KRename command which inserts file information into the filename.</qt>") );
|
|
|
|
|
|
|
|
|
@ -1004,7 +1004,7 @@ void KRenameImpl::start()
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
ProgressDialog* p = new ProgressDialog( 0, "p" );
|
|
|
|
|
p->print(TQString( i18n("Starting conversion of %1 files.") ).tqarg(fileList->count()));
|
|
|
|
|
p->print(TQString( i18n("Starting conversion of %1 files.") ).arg(fileList->count()));
|
|
|
|
|
|
|
|
|
|
// Save History
|
|
|
|
|
dirname->saveSettings();
|
|
|
|
@ -1065,7 +1065,7 @@ bool KRenameImpl::checkErrors()
|
|
|
|
|
|
|
|
|
|
void KRenameImpl::updateCount()
|
|
|
|
|
{
|
|
|
|
|
labelCount->setText( TQString( i18n("Files: <b>%1</b>") ).tqarg(fileList->count()));
|
|
|
|
|
labelCount->setText( TQString( i18n("Files: <b>%1</b>") ).arg(fileList->count()));
|
|
|
|
|
|
|
|
|
|
buttonCoord->setEnabled( (bool)fileList->count() );
|
|
|
|
|
buttonReplace->setEnabled( (bool)fileList->count() );
|
|
|
|
@ -1165,7 +1165,7 @@ bool KRenameImpl::setupBatchRenamer( BatchRenamer* b, bool preview )
|
|
|
|
|
if( !KIO::NetAccess::exists( KURL( url ) ) )
|
|
|
|
|
{
|
|
|
|
|
int m = KMessageBox::warningContinueCancel( parent, i18n("The directory %1 does not exist. "
|
|
|
|
|
"KRename will create it for you.").tqarg( url ) );
|
|
|
|
|
"KRename will create it for you.").arg( url ) );
|
|
|
|
|
if( m == KMessageBox::Cancel )
|
|
|
|
|
return false;
|
|
|
|
|
|
|
|
|
|