|
|
@ -193,7 +193,7 @@ void MainWindow::slotReturnPressed()
|
|
|
|
{
|
|
|
|
{
|
|
|
|
TQString text = m_edit->text();
|
|
|
|
TQString text = m_edit->text();
|
|
|
|
|
|
|
|
|
|
|
|
text.tqreplace("\n", "");
|
|
|
|
text.replace("\n", "");
|
|
|
|
|
|
|
|
|
|
|
|
m_edit->appendHistory(text);
|
|
|
|
m_edit->appendHistory(text);
|
|
|
|
|
|
|
|
|
|
|
@ -301,7 +301,7 @@ void MainWindow::slotTextChanged()
|
|
|
|
if(inRPNMode())
|
|
|
|
if(inRPNMode())
|
|
|
|
return;
|
|
|
|
return;
|
|
|
|
|
|
|
|
|
|
|
|
if(str.tqfind(TQRegExp("^[-+*/^]")) != -1) {
|
|
|
|
if(str.find(TQRegExp("^[-+*/^]")) != -1) {
|
|
|
|
m_edit->setText("ans " + str + " ");
|
|
|
|
m_edit->setText("ans " + str + " ");
|
|
|
|
m_edit->moveCursor(TQTextEdit::MoveEnd, false);
|
|
|
|
m_edit->moveCursor(TQTextEdit::MoveEnd, false);
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -643,7 +643,7 @@ void MainWindow::slotRemoveFunction(const TQString &name)
|
|
|
|
TQString fnName = TQString("%1(%2)").tqarg(name, userFn->varName);
|
|
|
|
TQString fnName = TQString("%1(%2)").tqarg(name, userFn->varName);
|
|
|
|
|
|
|
|
|
|
|
|
TQListViewItem *item = 0;
|
|
|
|
TQListViewItem *item = 0;
|
|
|
|
while((item = m_fnList->tqfindItem(fnName, 0)) != 0)
|
|
|
|
while((item = m_fnList->findItem(fnName, 0)) != 0)
|
|
|
|
delete item;
|
|
|
|
delete item;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
@ -654,7 +654,7 @@ void MainWindow::slotNewValue(const TQString &name, Abakus::number_t value)
|
|
|
|
|
|
|
|
|
|
|
|
void MainWindow::slotChangeValue(const TQString &name, Abakus::number_t value)
|
|
|
|
void MainWindow::slotChangeValue(const TQString &name, Abakus::number_t value)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
ValueListViewItem *item = static_cast<ValueListViewItem *>(m_varList->tqfindItem(name, 0));
|
|
|
|
ValueListViewItem *item = static_cast<ValueListViewItem *>(m_varList->findItem(name, 0));
|
|
|
|
|
|
|
|
|
|
|
|
if(item)
|
|
|
|
if(item)
|
|
|
|
item->valueChanged(value);
|
|
|
|
item->valueChanged(value);
|
|
|
@ -662,7 +662,7 @@ void MainWindow::slotChangeValue(const TQString &name, Abakus::number_t value)
|
|
|
|
|
|
|
|
|
|
|
|
void MainWindow::slotRemoveValue(const TQString &name)
|
|
|
|
void MainWindow::slotRemoveValue(const TQString &name)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
delete m_varList->tqfindItem(name, 0);
|
|
|
|
delete m_varList->findItem(name, 0);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
void MainWindow::slotToggleCompactMode()
|
|
|
|
void MainWindow::slotToggleCompactMode()
|
|
|
@ -718,7 +718,7 @@ TQString MainWindow::interpolateExpression(const TQString &text, ResultListViewT
|
|
|
|
return TQString();
|
|
|
|
return TQString();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
str.tqreplace(pos, stackStr.length(), value.toString());
|
|
|
|
str.replace(pos, stackStr.length(), value.toString());
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
return str;
|
|
|
|
return str;
|
|
|
|