#include <kdialog.h>
#include <klocale.h>
/****************************************************************************
** Form implementation generated from reading ui file '/usr/src/ports/kdebase3/kdebase3-3.5.10-11.x86_64/src/kdebase-3.5.10/kcontrol/ebrowsing/plugins/ikws/searchproviderdlg_ui.ui'
**
** Created by User Interface Compiler
**
** WARNING! All changes made in this file will be lost!
****************************************************************************/

#include "searchproviderdlg_ui.h"

#include <qvariant.h>
#include <klineedit.h>
#include <qlabel.h>
#include <kcombobox.h>
#include <qlayout.h>
#include <qtooltip.h>
#include <qwhatsthis.h>
#include "klineedit.h"
#include "kcombobox.h"

/*
 *  Constructs a SearchProviderDlgUI as a child of 'parent', with the
 *  name 'name' and widget flags set to 'f'.
 */
SearchProviderDlgUI::SearchProviderDlgUI( QWidget* parent, const char* name, WFlags fl )
    : QWidget( parent, name, fl )
{
    if ( !name )
	setName( "SearchProviderDlgUI" );
    SearchProviderDlgUILayout = new QGridLayout( this, 1, 1, 0, 6, "SearchProviderDlgUILayout"); 

    leName = new KLineEdit( this, "leName" );

    SearchProviderDlgUILayout->addWidget( leName, 1, 0 );

    lbCharset = new QLabel( this, "lbCharset" );

    SearchProviderDlgUILayout->addWidget( lbCharset, 6, 0 );

    lbQuery = new QLabel( this, "lbQuery" );

    SearchProviderDlgUILayout->addWidget( lbQuery, 2, 0 );

    lbName = new QLabel( this, "lbName" );

    SearchProviderDlgUILayout->addWidget( lbName, 0, 0 );

    leShortcut = new KLineEdit( this, "leShortcut" );

    SearchProviderDlgUILayout->addWidget( leShortcut, 5, 0 );

    lbShortcut = new QLabel( this, "lbShortcut" );

    SearchProviderDlgUILayout->addWidget( lbShortcut, 4, 0 );

    leQuery = new KLineEdit( this, "leQuery" );

    SearchProviderDlgUILayout->addWidget( leQuery, 3, 0 );

    cbCharset = new KComboBox( FALSE, this, "cbCharset" );

    SearchProviderDlgUILayout->addWidget( cbCharset, 7, 0 );
    languageChange();
    resize( QSize(399, 206).expandedTo(minimumSizeHint()) );
    clearWState( WState_Polished );

    // tab order
    setTabOrder( leName, leQuery );
    setTabOrder( leQuery, leShortcut );
    setTabOrder( leShortcut, cbCharset );

    // buddies
    lbCharset->setBuddy( cbCharset );
    lbQuery->setBuddy( leQuery );
    lbName->setBuddy( leName );
    lbShortcut->setBuddy( leShortcut );
}

/*
 *  Destroys the object and frees any allocated resources
 */
SearchProviderDlgUI::~SearchProviderDlgUI()
{
    // no need to delete child widgets, Qt does it all for us
}

/*
 *  Sets the strings of the subwidgets using the current
 *  language.
 */
void SearchProviderDlgUI::languageChange()
{
    QWhatsThis::add( leName, tr2i18n( "Enter the human readable name of the search provider here." ) );
    lbCharset->setText( tr2i18n( "&Charset:" ) );
    QWhatsThis::add( lbCharset, tr2i18n( "Select the character set that will be used to encode your search query" ) );
    lbQuery->setText( tr2i18n( "Search &URI:" ) );
    QWhatsThis::add( lbQuery, tr2i18n( "<qt>\n"
"Enter the URI that is used to do a search on the search engine here.<br/>The whole text to be searched for can be specified as \\{@} or \\{0}.<br/>\n"
"Recommended is \\{@}, since it removes all query variables (name=value) from the resulting string whereas \\{0} will be substituted with the unmodified query string.<br/>You can use \\{1} ... \\{n} to specify certain words from the query and \\{name} to specify a value given by 'name=value' in the user query.<br/>In addition it is possible to specify multiple references (names, numbers and strings) at once (\\{name1,name2,...,\"string\"}).<br/>The first matching value (from the left) will be used as substitution value for the resulting URI.<br/>A quoted string can be used as default value if nothing matches from the left of the reference list.\n"
"</qt>" ) );
    lbName->setText( tr2i18n( "Search &provider name:" ) );
    QWhatsThis::add( lbName, tr2i18n( "Enter the human readable name of the search provider here." ) );
    QWhatsThis::add( leShortcut, tr2i18n( "<qt>\n"
"The shortcuts entered here can be used as a pseudo-URI scheme in KDE. For example, the shortcut <b>av</b> can be used as in <b>av</b>:<b>my search</b>\n"
"</qt>" ) );
    lbShortcut->setText( tr2i18n( "UR&I shortcuts:" ) );
    QWhatsThis::add( lbShortcut, tr2i18n( "<qt>\n"
"The shortcuts entered here can be used as a pseudo-URI scheme in KDE. For example, the shortcut <b>av</b> can be used as in <b>av</b>:<b>my search</b>\n"
"</qt>" ) );
    QWhatsThis::add( leQuery, tr2i18n( "<qt>\n"
"Enter the URI that is used to do a search on the search engine here.<br/>The whole text to be searched for can be specified as \\{@} or \\{0}.<br/>\n"
"Recommended is \\{@}, since it removes all query variables (name=value) from the resulting string whereas \\{0} will be substituted with the unmodified query string.<br/>You can use \\{1} ... \\{n} to specify certain words from the query and \\{name} to specify a value given by 'name=value' in the user query.<br/>In addition it is possible to specify multiple references (names, numbers and strings) at once (\\{name1,name2,...,\"string\"}).<br/>The first matching value (from the left) will be used as substitution value for the resulting URI.<br/>A quoted string can be used as default value if nothing matches from the left of the reference list.\n"
"</qt>" ) );
    QWhatsThis::add( cbCharset, tr2i18n( "Select the character set that will be used to encode your search query." ) );
}

#include "searchproviderdlg_ui.moc"
