summaryrefslogtreecommitdiff
path: root/noncore/apps/tinykate/libkate
Side-by-side diff
Diffstat (limited to 'noncore/apps/tinykate/libkate') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/apps/tinykate/libkate/document/katedialogs.cpp6
-rw-r--r--noncore/apps/tinykate/libkate/document/katedocument.cpp2
-rw-r--r--noncore/apps/tinykate/libkate/view/kateviewdialog.cpp6
3 files changed, 7 insertions, 7 deletions
diff --git a/noncore/apps/tinykate/libkate/document/katedialogs.cpp b/noncore/apps/tinykate/libkate/document/katedialogs.cpp
index 2f0ed7b..f4edd7e 100644
--- a/noncore/apps/tinykate/libkate/document/katedialogs.cpp
+++ b/noncore/apps/tinykate/libkate/document/katedialogs.cpp
@@ -34,57 +34,57 @@
#include <qcheckbox.h>
//FIXME #include <kcharsets.h>
#include <kglobal.h>
#include <qmap.h>
#include <kmessagebox.h>
#include <kstddirs.h>
/*******************************************************************************************************************
* Context Editor *
*******************************************************************************************************************/
StyleChanger::StyleChanger( QWidget *parent )
: QWidget(parent)
{
QLabel *label;
QGridLayout *glay = new QGridLayout( this, 4, 3, 0, KDialog::spacingHint() );
CHECK_PTR(glay);
glay->addColSpacing( 1, KDialog::spacingHint() ); // Looks better
glay->setColStretch( 2, 10 );
col = new KColorButton(this);
CHECK_PTR(col);
- connect(col,SIGNAL(changed(const QColor &)),this,SLOT(changed()));
+ connect(col,SIGNAL(changed(const QColor&)),this,SLOT(changed()));
label = new QLabel(col,i18n("Normal:"),this);
CHECK_PTR(label);
glay->addWidget(label,0,0);
glay->addWidget(col,1,0);
selCol = new KColorButton(this);
CHECK_PTR(selCol);
- connect(selCol,SIGNAL(changed(const QColor &)),this,SLOT(changed()));
+ connect(selCol,SIGNAL(changed(const QColor&)),this,SLOT(changed()));
label = new QLabel(selCol,i18n("Selected:"),this);
CHECK_PTR(label);
glay->addWidget(label,2,0);
glay->addWidget(selCol,3,0);
bold = new QCheckBox(i18n("Bold"),this);
CHECK_PTR(bold);
connect(bold,SIGNAL(clicked()),SLOT(changed()));
glay->addWidget(bold,1,2);
italic = new QCheckBox(i18n("Italic"),this);
CHECK_PTR(italic);
connect(italic,SIGNAL(clicked()),SLOT(changed()));
glay->addWidget(italic,2,2);
}
void StyleChanger::setRef(ItemStyle *s) {
style = s;
col->setColor(style->col);
selCol->setColor(style->selCol);
bold->setChecked(style->bold);
italic->setChecked(style->italic);
@@ -265,49 +265,49 @@ void HighlightDialogPage::hlNew() {
HlEditDialog::HlEditDialog(HlManager *,QWidget *parent, const char *name, bool modal,HlData *data)
:KDialogBase(KDialogBase::Swallow, i18n("Highlight Conditions"), Ok|Cancel, Ok, parent, name, modal)
{
currentItem=0;
transTableCnt=0;
QHBox *wid=new QHBox(this);
QVBox *lbox=new QVBox(wid);
contextList=new KListView(lbox);
contextList->setRootIsDecorated(true);
contextList->addColumn(i18n("Syntax structure"));
contextList->setSorting(-1);
QHBox *bbox=new QHBox(lbox);
QPushButton *addContext=new QPushButton(i18n("New Context"),bbox);
QPushButton *addItem=new QPushButton(i18n("New Item"),bbox);
QVGroupBox *opt = new QVGroupBox( i18n("Options"), wid);
stack=new QWidgetStack(opt);
initContextOptions(contextOptions=new QVBox(stack));
stack->addWidget(contextOptions,HlEContext);
initItemOptions(itemOptions=new QVBox(stack));
stack->addWidget(itemOptions,HlEItem);
stack->raiseWidget(HlEContext);
setMainWidget(wid);
if (data!=0) loadFromDocument(data);
else newDocument();
- connect(contextList,SIGNAL(currentChanged( QListViewItem*)),this,SLOT(currentSelectionChanged ( QListViewItem * )));
+ connect(contextList,SIGNAL(currentChanged(QListViewItem*)),this,SLOT(currentSelectionChanged(QListViewItem*)));
connect(addContext,SIGNAL(clicked()),this,SLOT(contextAddNew()));
connect(addItem,SIGNAL(clicked()),this,SLOT(ItemAddNew()));
}
void HlEditDialog::newDocument()
{
KStandardDirs *dirs = KGlobal::dirs();
QStringList list=dirs->findAllResources("data","kate/syntax/syntax.template",false,true);
for ( QStringList::Iterator it = list.begin(); it != list.end(); ++it )
{
HlData data("","",*it);
loadFromDocument(&data);
return;
}
KMessageBox::error(this,i18n("Can't find template file"));
}
void HlEditDialog::initContextOptions(QVBox *co)
{
if( co!=0)
{
QHBox *tmp = new QHBox(co);
(void) new QLabel(i18n("Description:"),tmp);
diff --git a/noncore/apps/tinykate/libkate/document/katedocument.cpp b/noncore/apps/tinykate/libkate/document/katedocument.cpp
index f05e21a..0c742d7 100644
--- a/noncore/apps/tinykate/libkate/document/katedocument.cpp
+++ b/noncore/apps/tinykate/libkate/document/katedocument.cpp
@@ -147,49 +147,49 @@ KateDocument::KateDocument(bool bSingleViewMode, bool bBrowserView,
RequestPreHighlightTill=0;
m_bSingleViewMode=bSingleViewMode;
m_bBrowserView = bBrowserView;
m_url = QString::null;
// NOTE: QFont::CharSet doesn't provide all the charsets KDE supports
// (esp. it doesn't distinguish between UTF-8 and iso10646-1)
myEncoding = QString::fromLatin1(QTextCodec::codecForLocale()->name());
maxLength = -1;
setFont (KGlobalSettings::generalFont());
myDocID = uniqueID;
uniqueID++;
myDocName = QString ("");
fileInfo = new QFileInfo ();
myCmd = new KateCmd (this);
- connect(this,SIGNAL(modifiedChanged ()),this,SLOT(slotModChanged ()));
+ connect(this,SIGNAL(modifiedChanged()),this,SLOT(slotModChanged()));
buffer = new KWBuffer;
connect(buffer, SIGNAL(linesChanged(int)), this, SLOT(slotBufferChanged()));
// connect(buffer, SIGNAL(textChanged()), this, SIGNAL(textChanged()));
connect(buffer, SIGNAL(needHighlight(long,long)),this,SLOT(slotBufferHighlight(long,long)));
colors[0] = KGlobalSettings::baseColor();
colors[1] = KGlobalSettings::highlightColor();
m_attribs = new Attribute[maxAttribs];
m_highlight = 0L;
tabChars = 8;
m_singleSelection = false;
newDocGeometry = false;
readOnly = false;
newDoc = false;
modified = false;
undoList.setAutoDelete(true);
undoState = 0;
diff --git a/noncore/apps/tinykate/libkate/view/kateviewdialog.cpp b/noncore/apps/tinykate/libkate/view/kateviewdialog.cpp
index a85fb87..8e68262 100644
--- a/noncore/apps/tinykate/libkate/view/kateviewdialog.cpp
+++ b/noncore/apps/tinykate/libkate/view/kateviewdialog.cpp
@@ -514,58 +514,58 @@ void ColorConfig::setColors(QColor *colors)
m_selected->setColor( colors[1] );
}
void ColorConfig::getColors(QColor *colors)
{
colors[0] = m_back->color();
colors[1] = m_selected->color();
}
FontConfig::FontConfig( QWidget *parent, char *name )
: QWidget( parent, name )
{
// sizemanagment
QGridLayout *grid = new QGridLayout( this, 1, 1 );
// QString familyStr = cfg. readEntry ( "FontFamily", "Helvetica" );
// QString styleStr = cfg. readEntry ( "FontStyle", "Regular" );
// int size = cfg. readNumEntry ( "FontSize", 10 );
// OFontSelector *m_fontselect;
m_fontselect = new Opie::OFontSelector ( false, this, "FontTab" );
// m_fontselect-> setSelectedFont ( familyStr, styleStr, size );
// QWhatsThis::add( m_fontselect,
// tr( "Select the desired name, style and size of the default font applications will use." ) );
- connect( m_fontselect, SIGNAL( fontSelected ( const QFont & )),
- this, SLOT( slotFontSelected( const QFont & )));
+ connect( m_fontselect, SIGNAL( fontSelected(const QFont&)),
+ this, SLOT( slotFontSelected(const QFont&)));
grid->addWidget( m_fontselect, 0, 0);
// #if 0
// m_fontchooser = new KFontChooser ( this );
// m_fontchooser->enableColumn(KFontChooser::StyleList, false);
// grid->addWidget( m_fontchooser, 0, 0);
-// connect (m_fontchooser, SIGNAL (fontSelected( const QFont & )), this, SLOT (slotFontSelected( const QFont & )));
+// connect (m_fontchooser, SIGNAL (fontSelected(const QFont&)), this, SLOT (slotFontSelected(const QFont&)));
// #endif
}
FontConfig::~FontConfig()
{
}
void FontConfig::setFont ( const QFont &font )
{
//#if 0
m_fontselect->setFont (font);
myFont = font;
//#endif
}
void FontConfig::slotFontSelected( const QFont &font )
{
myFont = font;
}