summaryrefslogtreecommitdiff
path: root/core/apps
authorllornkcor <llornkcor>2002-02-03 14:11:38 (UTC)
committer llornkcor <llornkcor>2002-02-03 14:11:38 (UTC)
commitee82c470b34819d24de543b30f150788fb58b2f1 (patch) (side-by-side diff)
treef1161e9dab6f77de6718fcf0e3a36e1ded4388f0 /core/apps
parentf3def578d169c0a937f418b2d956c73592190cda (diff)
downloadopie-ee82c470b34819d24de543b30f150788fb58b2f1.zip
opie-ee82c470b34819d24de543b30f150788fb58b2f1.tar.gz
opie-ee82c470b34819d24de543b30f150788fb58b2f1.tar.bz2
fixed problem with commandlist and very long commands messing up the combo width, so you couldn't edit.
Diffstat (limited to 'core/apps') (more/less context) (show whitespace changes)
-rw-r--r--core/apps/embeddedkonsole/konsole.cpp10
1 files changed, 4 insertions, 6 deletions
diff --git a/core/apps/embeddedkonsole/konsole.cpp b/core/apps/embeddedkonsole/konsole.cpp
index f154bb8..653652a 100644
--- a/core/apps/embeddedkonsole/konsole.cpp
+++ b/core/apps/embeddedkonsole/konsole.cpp
@@ -286,25 +286,25 @@ void Konsole::init(const char* _pgm, QStrList & _args)
connect( a, SIGNAL( activated() ), this, SLOT( hitPaste() ) ); a->addTo( toolbar );
/*
a = new QAction( tr("Up"), Resource::loadPixmap( "up" ), QString::null, 0, this, 0 );
connect( a, SIGNAL( activated() ), this, SLOT( hitUp() ) ); a->addTo( toolbar );
a = new QAction( tr("Down"), Resource::loadPixmap( "down" ), QString::null, 0, this, 0 );
connect( a, SIGNAL( activated() ), this, SLOT( hitDown() ) ); a->addTo( toolbar );
*/
secondToolBar = new QPEToolBar( this );
secondToolBar->setHorizontalStretchable( TRUE );
commonCombo = new QComboBox( secondToolBar );
-
+ commonCombo->setMaximumWidth(236);
configMenu->insertItem( "Edit Command List");
if( listHidden) {
secondToolBar->hide();
configMenu->setItemEnabled(-20 ,FALSE);
}
cfg.setGroup("Commands");
commonCombo->setInsertionPolicy(QComboBox::AtCurrent);
for (int i = 0; commonCmds[i] != NULL; i++) {
commonCombo->insertItem( commonCmds[i], i );
tmp = cfg.readEntry( QString::number(i),"");
@@ -568,26 +568,25 @@ void Konsole::switchSession(QWidget* w) {
bool cf = fnt->getFont() == teFnt;
fontList->setItemChecked(i, cf);
if (cf) {
cfont = i;
}
}
}
/// ------------------------------- some new stuff by L.J. Potter
void Konsole::colorMenuSelected(int iD)
{ // this is NOT pretty, elegant or anything else besides functional
// QString temp;
-// temp.sprintf("%d", iD);
-// qDebug(temp);
+// qDebug( temp.sprintf("%d", iD));
TEWidget* te = getTe();
Config cfg("Konsole");
cfg.setGroup("Colors");
QColor foreground;
QColor background;
colorMenu->setItemChecked(lastSelectedMenu,FALSE);
ColorEntry m_table[TABLE_COLORS];
const ColorEntry * defaultCt=te->getdefaultColorTable();
/////////// fore back
int i;
if(iD==-8) { // default default
for (i = 0; i < TABLE_COLORS; i++) {
@@ -676,27 +675,26 @@ void Konsole::colorMenuSelected(int iD)
}
else
m_table[i].color = defaultCt[i].color;
}
}
lastSelectedMenu = iD;
te->setColorTable(m_table);
update();
}
void Konsole::configMenuSelected(int iD)
{
-// QString temp;
-// temp.sprintf("%d",iD);
-// qDebug(temp);
+ QString temp;
+ qDebug( temp.sprintf("%d",iD));
TEWidget* te = getTe();
Config cfg("Konsole");
cfg.setGroup("Menubar");
if( iD == -2) {
if(!secondToolBar->isHidden()) {
secondToolBar->hide();
configMenu->changeItem( iD,"Show Command List");
cfg.writeEntry("Hidden","TRUE");
configMenu->setItemEnabled(-20 ,FALSE);
} else {
secondToolBar->show();
configMenu->changeItem( iD,"Hide Command List");