Commit 971a5315 authored by Robert Knight's avatar Robert Knight

Remove debugging messages.

svn path=/trunk/KDE/kdebase/apps/konsole/; revision=800628
parent b93ed8ab
......@@ -160,7 +160,6 @@ QList<QPair<QString,QString> > BookmarkHandler::currentBookmarkList() const
void BookmarkHandler::setViews(const QList<ViewProperties*>& views)
{
//kDebug() << "BookmarkHandler - View list changed.";
m_views = views;
}
QList<ViewProperties*> BookmarkHandler::views() const
......
......@@ -176,11 +176,6 @@ ColorEntry ColorScheme::colorEntry(int index , uint randomSeed) const
ColorEntry entry = colorTable()[index];
// kDebug() << "Old color: " << entry.color;
// kDebug() << "Random seed: " << randomSeed << "random table: " <<
// _randomTable << "isnull: " << ((_randomTable) ? _randomTable[index].isNull() : true);
if ( randomSeed != 0 &&
_randomTable != 0 &&
!_randomTable[index].isNull() )
......@@ -193,19 +188,14 @@ ColorEntry ColorScheme::colorEntry(int index , uint randomSeed) const
int valueDifference = range.value ? (qrand() % range.value) - range.value/2 : 0;
QColor& color = entry.color;
// kDebug() << "Standard hue" << color.hue() << "saturation" << color.saturation() << "value" << color.value();
int newHue = qAbs( (color.hue() + hueDifference) % MAX_HUE );
int newValue = qMin( qAbs(color.value() + valueDifference) , 255 );
int newSaturation = qMin( qAbs(color.saturation() + saturationDifference) , 255 );
// kDebug() << "New hue: " << newHue << "New sat:" << newSaturation <<
// "New value:" << newValue;
color.setHsv(newHue,newSaturation,newValue);
}
// kDebug() << "New color: " << entry.color;
return entry;
}
void ColorScheme::getColorTable(ColorEntry* table , uint randomSeed) const
......@@ -529,10 +519,8 @@ void ColorSchemeManager::loadAllColorSchemes()
failed++;
}
// if ( success > 0 )
// kDebug() << "succeeded to load " << success << " color schemes.";
if ( failed > 0 )
kDebug() << "failed to load " << failed << " color schemes.";
kWarning() << "failed to load " << failed << " color schemes.";
_haveLoadedAll = true;
}
......@@ -547,8 +535,6 @@ QList<const ColorScheme*> ColorSchemeManager::allColorSchemes()
}
bool ColorSchemeManager::loadKDE3ColorScheme(const QString& filePath)
{
//kDebug() << "loading KDE 3 format color scheme from " << filePath;
QFile file(filePath);
if (!filePath.endsWith(".schema") || !file.open(QIODevice::ReadOnly))
return false;
......@@ -559,17 +545,11 @@ bool ColorSchemeManager::loadKDE3ColorScheme(const QString& filePath)
file.close();
Q_ASSERT( !scheme->name().isEmpty() );
//kDebug() << "found KDE 3 format color scheme - " << scheme->name();
QFileInfo info(filePath);
if ( !_colorSchemes.contains(info.baseName()) )
{
//kDebug() << "added color scheme - " << info.baseName();
_colorSchemes.insert(scheme->name(),scheme);
}
else
{
kDebug() << "color scheme with name" << scheme->name() << "has already been" <<
......@@ -670,8 +650,6 @@ QString ColorSchemeManager::findColorSchemePath(const QString& name) const
}
const ColorScheme* ColorSchemeManager::findColorScheme(const QString& name)
{
//kDebug() << "looking for color scheme - " << name;
if ( name.isEmpty() )
return defaultColorScheme();
......@@ -691,7 +669,7 @@ const ColorScheme* ColorSchemeManager::findColorScheme(const QString& name)
return findColorScheme(name);
}
kDebug() << "Could not find color scheme - " << name;
kWarning() << "Could not find color scheme - " << name;
return 0;
}
......
......@@ -92,8 +92,6 @@ ColorSchemeEditor::ColorSchemeEditor(QWidget* parent)
connect( _ui->colorTable , SIGNAL(itemClicked(QTableWidgetItem*)) , this ,
SLOT(editColorItem(QTableWidgetItem*)) );
kDebug() << "Color scheme editor - have compositing = " << KWindowSystem::compositingActive();
// warning label when transparency is not available
if ( KWindowSystem::compositingActive() )
{
......@@ -148,8 +146,6 @@ void ColorSchemeEditor::setTransparencyPercentLabel(int percent)
qreal opacity = ( 100.0 - percent ) / 100.0;
_colors->setOpacity(opacity);
//kDebug() << "set opacity to:" << opacity;
}
void ColorSchemeEditor::setup(const ColorScheme* scheme)
{
......@@ -165,7 +161,6 @@ void ColorSchemeEditor::setup(const ColorScheme* scheme)
setupColorTable(_colors);
// setup transparency slider
//kDebug() << "read opacity: " << _colors->opacity();
const int transparencyPercent = (int) ( (1-_colors->opacity())*100 );
_ui->transparencySlider->setValue(transparencyPercent);
......
......@@ -209,20 +209,12 @@ void Filter::getLineColumn(int position , int& startLine , int& startColumn)
for (int i = 0 ; i < _linePositions->count() ; i++)
{
//kDebug() << "line position at " << i << " = " << _linePositions[i];
int nextLine = 0;
if ( i == _linePositions->count()-1 )
{
nextLine = _buffer->length() + 1;
}
else
{
nextLine = _linePositions->value(i+1);
}
// kDebug() << "pos - " << position << " line pos(" << i<< ") " << _linePositions->value(i) <<
// " next = " << nextLine << " buffer len = " << _buffer->length();
if ( _linePositions->value(i) <= position && position < nextLine )
{
......@@ -385,15 +377,9 @@ void RegExpFilter::process()
int startColumn = 0;
int endColumn = 0;
//kDebug() << "pos from " << pos << " to " << pos + _searchText.matchedLength();
getLineColumn(pos,startLine,startColumn);
getLineColumn(pos + _searchText.matchedLength(),endLine,endColumn);
//kDebug() << "start " << startLine << " / " << startColumn;
//kDebug() << "end " << endLine << " / " << endColumn;
RegExpFilter::HotSpot* spot = newHotSpot(startLine,startColumn,
endLine,endColumn);
spot->setCapturedTexts(_searchText.capturedTexts());
......@@ -460,8 +446,6 @@ void UrlFilter::HotSpot::activate(QObject* object)
if ( actionName == "copy-action" )
{
//kDebug() << "Copying url to clipboard:" << url;
QApplication::clipboard()->setText(url);
return;
}
......
......@@ -137,7 +137,6 @@ bool KeyBindingEditor::eventFilter( QObject* watched , QEvent* event )
_ui->testAreaInputEdit->setText(keyEvent->text());
_ui->testAreaOutputEdit->setText(keyEvent->text());
}
//kDebug() << "Entry: " << entry.resultToString();
keyEvent->accept();
return true;
......@@ -186,9 +185,6 @@ void KeyBindingEditor::bindingTableItemChanged(QTableWidgetItem* item)
QString result = _ui->keyBindingTable->item( item->row() , 1 )->text();
KeyboardTranslator::Entry entry = KeyboardTranslatorReader::createEntry(condition,result);
kDebug() << "Created entry: " << entry.conditionToString() << " , " << entry.resultToString();
_translator->replaceEntry(existing,entry);
// block signals to prevent this slot from being called repeatedly
......@@ -206,7 +202,6 @@ void KeyBindingEditor::setupKeyBindingTable(const KeyboardTranslator* translator
QList<KeyboardTranslator::Entry> entries = translator->entries();
_ui->keyBindingTable->setRowCount(entries.count());
//kDebug() << "Keyboard translator has" << entries.count() << "entries.";
for ( int row = 0 ; row < entries.count() ; row++ )
{
......
......@@ -537,9 +537,6 @@ SSHProcessInfo::SSHProcessInfo(const ProcessInfo& process)
// if not, this must be the username/host argument
if ( _host.isEmpty() )
{
// found username and host argument
kDebug() << "[username] and host: " << args[i];
// check to see if only a hostname is specified, or whether
// both a username and host are specified ( in which case they
// are separated by an '@' character: username@host )
......@@ -550,23 +547,17 @@ SSHProcessInfo::SSHProcessInfo(const ProcessInfo& process)
// username and host specified
_user = args[i].left(separatorPosition);
_host = args[i].mid(separatorPosition+1);
kDebug() << "found user: " << _user;
kDebug() << "found host: " << _host;
}
else
{
// just the host specified
_host = args[i];
kDebug() << "found only host: " << _host;
}
}
else
{
// host has already been found, this must be the command argument
_command = args[i];
kDebug() << "found command: " << _command;
}
}
......
......@@ -183,12 +183,9 @@ Profile::Profile(Profile::Ptr parent)
: _parent(parent)
,_hidden(false)
{
//kDebug() << "creating new profile" << parent.count();
}
Profile::~Profile()
{
if (!name().isEmpty() && !isHidden())
kDebug() << "Destroying profile " << name();
}
bool Profile::isHidden() const { return _hidden; }
void Profile::setHidden(bool hidden) { _hidden = hidden; }
......@@ -453,9 +450,6 @@ QHash<Profile::Property,QVariant> ProfileCommandParser::parse(const QString& inp
Profile::Property property = Profile::lookupByName(
regExp.capturedTexts()[1]);
const QString value = regExp.capturedTexts()[2];
kDebug() << "property:" << property << "value:" << value;
changes.insert(property,value);
}
......
......@@ -842,8 +842,6 @@ void Screen::resetDroppedLines()
}
void Screen::resetScrolledLines()
{
//kDebug() << "scrolled lines reset";
_scrolledLines = 0;
}
......@@ -891,9 +889,6 @@ void Screen::scrollDown(int n)
void Screen::scrollDown(int from, int n)
{
//kDebug() << "Screen::scrollDown( from: " << from << " , n: " << n << ")";
_scrolledLines += n;
//FIXME: make sure `tmargin', `bmargin', `from', `n' is in bounds.
......@@ -1021,10 +1016,6 @@ NOTE: moveImage() can only move whole lines.
void Screen::moveImage(int dest, int sourceBegin, int sourceEnd)
{
//kDebug() << "moving image from (" << (sourceBegin/columns)
// << "," << (sourceEnd/columns) << ") to " <<
// (dest/columns);
Q_ASSERT( sourceBegin <= sourceEnd );
int lines=(sourceEnd-sourceBegin)/columns;
......@@ -1223,7 +1214,6 @@ void Screen::getSelectionEnd(int& column , int& line)
}
void Screen::setSelectionStart(/*const ScreenCursor& viewCursor ,*/ const int x, const int y, const bool mode)
{
// kDebug(1211) << "setSelBeginXY(" << x << "," << y << ")";
sel_begin = loc(x,y); //+histCursor) ;
/* FIXME, HACK to correct for x too far to the right... */
......@@ -1236,7 +1226,6 @@ void Screen::setSelectionStart(/*const ScreenCursor& viewCursor ,*/ const int x,
void Screen::setSelectionEnd( const int x, const int y)
{
// kDebug(1211) << "setSelExtentXY(" << x << "," << y << ")";
if (sel_begin == -1) return;
int l = loc(x,y); // + histCursor);
......
......@@ -731,7 +731,6 @@ void Session::setIconName(const QString& iconName)
void Session::setIconText(const QString& iconText)
{
_iconText = iconText;
//kDebug(1211)<<"Session setIconText " << _iconText;
}
QString Session::iconName() const
......@@ -1068,8 +1067,6 @@ void SessionGroup::connectPair(Session* master , Session* other)
{
if ( _masterMode & CopyInputToAll )
{
// kDebug() << "Connection session " << master->nameTitle() << "to" << other->nameTitle();
connect( master->emulation() , SIGNAL(sendData(const char*,int)) , other->emulation() ,
SLOT(sendString(const char*,int)) );
}
......@@ -1078,8 +1075,6 @@ void SessionGroup::disconnectPair(Session* master , Session* other)
{
if ( _masterMode & CopyInputToAll )
{
// kDebug() << "Disconnecting session " << master->nameTitle() << "from" << other->nameTitle();
disconnect( master->emulation() , SIGNAL(sendData(const char*,int)) , other->emulation() ,
SLOT(sendString(const char*,int)) );
}
......
......@@ -278,13 +278,9 @@ KUrl SessionController::url() const
int pid = _session->foregroundProcessId();
if ( pid != 0 )
{
kDebug(1211) << "reading session process = " << info->name(&ok);
ProcessInfo* foregroundInfo = ProcessInfo::newInstance(pid);
foregroundInfo->update();
kDebug(1211) << "reading foreground process = " << foregroundInfo->name(&ok);
// for remote connections, save the user and host
// bright ideas to get the directory at the other end are welcome :)
if ( foregroundInfo->name(&ok) == "ssh" && ok )
......@@ -640,13 +636,9 @@ void SessionController::debugProcess()
QString currentDir = fp->currentDir(&ok);
if ( ok )
{
kDebug(1211) << currentDir;
}
else
{
kDebug(1211) << "could not read current dir of foreground process";
}
delete fp;
}
......@@ -703,7 +695,6 @@ void SessionController::closeSession()
void SessionController::openBrowser()
{
kDebug() << "url is" << url();
new KRun(url(), QApplication::activeWindow());
}
......@@ -943,7 +934,6 @@ void SessionController::showHistoryOptions()
void SessionController::sessionResizeRequest(const QSize& size)
{
kDebug(1211) << "View resize requested to " << size;
_view->setSize(size.width(),size.height());
}
void SessionController::scrollBackOptionsChanged( int mode , int lines )
......@@ -1438,10 +1428,8 @@ void SearchHistoryTask::highlightResult(ScreenWindowPtr window , int findPos)
window->scrollTo(findPos);
window->setSelectionStart( 0 , findPos - window->currentLine() , false );
window->setSelectionEnd( window->columnCount() , findPos - window->currentLine() );
//kDebug() << "Current line " << window->currentLine();
window->setTrackOutput(false);
window->notifyOutputChanged();
//kDebug() << "Post update current line " << window->currentLine();
}
SearchHistoryTask::SearchHistoryTask(QObject* parent)
......
......@@ -102,16 +102,6 @@ void ViewContainer::moveActiveView( MoveDirection direction )
void ViewContainer::setNavigationDisplayMode(NavigationDisplayMode mode)
{
_navigationDisplayMode = mode;
#if 0
if ( mode == AlwaysShowNavigation )
kDebug() << "Always show nav";
else if ( mode == AlwaysHideNavigation )
kDebug() << "Always hide nav";
else if ( mode == ShowNavigationAsNeeded )
kDebug() << "Show nav as needed";
#endif
navigationDisplayModeChanged(mode);
}
ViewContainer::NavigationPosition ViewContainer::navigationPosition() const
......@@ -383,8 +373,6 @@ void TabbedViewContainer::removeViewWidget( QWidget* view )
void TabbedViewContainer::updateIcon(ViewProperties* item)
{
kDebug() << k_funcinfo << ": icon changed.";
QList<QWidget*> items = widgetsForItem(item);
QListIterator<QWidget*> itemIter(items);
......@@ -396,8 +384,6 @@ void TabbedViewContainer::updateIcon(ViewProperties* item)
}
void TabbedViewContainer::updateTitle(ViewProperties* item)
{
kDebug() << k_funcinfo << ": title changed.";
QList<QWidget*> items = widgetsForItem(item);
QListIterator<QWidget*> itemIter(items);
......@@ -699,9 +685,6 @@ void TabbedViewContainerV2::navigationDisplayModeChanged(NavigationDisplayMode m
}
void TabbedViewContainerV2::dynamicTabBarVisibility()
{
kDebug() << "tab bar count:" << _tabBar->count();
kDebug() << "tab var hidden:" << _tabBar->isHidden();
if ( _tabBar->count() > 1 && _tabBar->isHidden() )
setTabBarVisible(true);
......@@ -890,8 +873,6 @@ void TabbedViewContainerV2::updateTitle(ViewProperties* item)
}
void TabbedViewContainerV2::updateIcon(ViewProperties* item)
{
kDebug() << "Tab icon changed.";
QListIterator<QWidget*> iter(widgetsForItem(item));
while ( iter.hasNext() )
{
......
......@@ -235,14 +235,12 @@ void ViewManager::updateDetachViewState()
}
void ViewManager::moveActiveViewLeft()
{
kDebug() << "Moving active view to the left";
ViewContainer* container = _viewSplitter->activeContainer();
Q_ASSERT( container );
container->moveActiveView( ViewContainer::MoveViewLeft );
}
void ViewManager::moveActiveViewRight()
{
kDebug() << "Moving active view to the right";
ViewContainer* container = _viewSplitter->activeContainer();
Q_ASSERT( container );
container->moveActiveView( ViewContainer::MoveViewRight );
......@@ -627,8 +625,6 @@ ViewManager::NavigationMethod ViewManager::navigationMethod() const { return _na
void ViewManager::containerViewsChanged(QObject* container)
{
//kDebug() << "Container views changed";
if ( container == _viewSplitter->activeContainer() )
{
emit viewPropertiesChanged( viewProperties() );
......
......@@ -41,8 +41,6 @@ ViewSplitter::ViewSplitter(QWidget* parent)
void ViewSplitter::childEmpty(ViewSplitter* splitter)
{
// kDebug() << k_funcinfo << ": deleting child splitter " ;
delete splitter;
if ( count() == 0 )
......@@ -60,22 +58,14 @@ void ViewSplitter::adjustContainerSize(ViewContainer* container , int percentage
int oldSize = containerSizes[containerIndex];
int newSize = (int)(oldSize * ( 1.0 + percentage/100.0 ));
// kDebug() << "Old container size:" << oldSize << ", new size:" << newSize;
int perContainerDelta = (count() == 1 ) ? 0 : ( (newSize-oldSize) / (count()-1) ) * (-1);
// kDebug() << "Changing sizes of other containers by " << perContainerDelta << "pixels.";
for ( int i = 0 ; i < containerSizes.count() ; i++ )
{
//kDebug() << "Container" << i << "old size =" << containerSizes[i];
if ( i == containerIndex )
containerSizes[i] = newSize;
else
containerSizes[i] = containerSizes[i] + perContainerDelta;
//kDebug() << "Container" << i << "new size =" << containerSizes[i];
}
setSizes(containerSizes);
......@@ -83,32 +73,23 @@ void ViewSplitter::adjustContainerSize(ViewContainer* container , int percentage
ViewSplitter* ViewSplitter::activeSplitter()
{
// kDebug() << "BEGIN activeSplitter" ;
QWidget* widget = focusWidget() ? focusWidget() : this;
ViewSplitter* splitter = 0;
while ( !splitter && widget )
{
// kDebug() << widget ;
splitter = dynamic_cast<ViewSplitter*>(widget);
widget = widget->parentWidget();
}
Q_ASSERT( splitter );
//kDebug() << "END activeSplitter";
return splitter;
}
void ViewSplitter::registerContainer( ViewContainer* container )
{
_containers << container;
//kDebug() << k_funcinfo << ": adding container " << ((QTabWidget*)container->containerWidget())->tabText(0);
connect( container , SIGNAL(destroyed(ViewContainer*)) , this , SLOT( containerDestroyed(ViewContainer*) ) );
connect( container , SIGNAL(empty(ViewContainer*)) , this , SLOT( containerEmpty(ViewContainer*) ) );
}
......@@ -116,9 +97,6 @@ void ViewSplitter::registerContainer( ViewContainer* container )
void ViewSplitter::unregisterContainer( ViewContainer* container )
{
_containers.removeAll(container);
//kDebug() << k_funcinfo << ": removing container " << ((QTabWidget*)container->containerWidget())->tabText(0);
disconnect( container , 0 , this , 0 );
}
......@@ -269,11 +247,6 @@ ViewContainer* ViewSplitter::activeContainer() const
{
if ( QWidget* focusW = focusWidget() )
{
// kDebug() << k_funcinfo << ": focus-widget = " << focusW ;
// if ( dynamic_cast<QLineEdit*>(focusW) )
// kDebug() << k_funcinfo << ": focus-widget-text = " << ((QLineEdit*)focusW)->text();
// kDebug() << k_funcinfo << ": container count = " << _containers.count();
ViewContainer* focusContainer = 0;
while ( focusW != 0 )
......
......@@ -108,21 +108,13 @@ void Vt102Emulation::clearEntireScreen()
void Vt102Emulation::reset()
{
//kDebug(1211)<<"Vt102Emulation::reset() resetToken()";
resetToken();
//kDebug(1211)<<"Vt102Emulation::reset() resetModes()";
resetModes();
//kDebug(1211)<<"Vt102Emulation::reset() resetCharSet()";
resetCharset(0);
//kDebug(1211)<<"Vt102Emulation::reset() reset screen0()";
_screen[0]->reset();
//kDebug(1211)<<"Vt102Emulation::reset() resetCharSet()";
resetCharset(1);
//kDebug(1211)<<"Vt102Emulation::reset() reset _screen 1";
_screen[1]->reset();
//kDebug(1211)<<"Vt102Emulation::reset() setCodec()";
setCodec(LocaleCodec);
//kDebug(1211)<<"Vt102Emulation::reset() done";
bufferedUpdate();
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment