summaryrefslogtreecommitdiffstats
path: root/quanta/utility/tagactionset.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'quanta/utility/tagactionset.cpp')
-rw-r--r--quanta/utility/tagactionset.cpp74
1 files changed, 37 insertions, 37 deletions
diff --git a/quanta/utility/tagactionset.cpp b/quanta/utility/tagactionset.cpp
index 28f01ef8..dc994716 100644
--- a/quanta/utility/tagactionset.cpp
+++ b/quanta/utility/tagactionset.cpp
@@ -40,20 +40,20 @@
#include "resource.h"
-TagActionSetAbstract::TagActionSetAbstract(TQObject *parent, const char *name)
- : TQObject(parent, name), m_currentNode(0)
+TagActionSetAbstract::TagActionSetAbstract(TQObject *tqparent, const char *name)
+ : TQObject(tqparent, name), m_currentNode(0)
{}
TagActionSetAbstract::~TagActionSetAbstract()
{}
-Node* TagActionSetAbstract::parentTag(Node* node, TQString const& tagName)
+Node* TagActionSetAbstract::tqparentTag(Node* node, TQString const& tagName)
{
Q_ASSERT(node);
Node* aux = node;
while(aux && aux->nodeName().lower() != tagName)
- aux = aux->parent;
+ aux = aux->tqparent;
return aux;
}
@@ -81,8 +81,8 @@ bool TagActionSetAbstract::fillWithTagActions(TQWidget* /*widget*/, DOM::Node co
//_____________________________________________________________________________
-TagActionSet::TagActionSet(TQObject *parent, const char *name)
- : TagActionSetAbstract(parent, name), m_separator(0)
+TagActionSet::TagActionSet(TQObject *tqparent, const char *name)
+ : TagActionSetAbstract(tqparent, name), m_separator(0)
{
m_separator = new KActionSeparator();
}
@@ -96,7 +96,7 @@ void TagActionSet::initActionMenus(TQWidget* /*widget*/)
{
}
-void TagActionSet::initActions(TQWidget* /*parent*/)
+void TagActionSet::initActions(TQWidget* /*tqparent*/)
{
KActionCollection* ac(TagActionManager::self()->actionCollection());
@@ -221,14 +221,14 @@ bool TagActionSet::isInDivArea() const
{
Q_ASSERT(m_currentNode);
- return parentTag(m_currentNode, "div");
+ return tqparentTag(m_currentNode, "div");
}
void TagActionSet::slotCopyDivElement()
{
Q_ASSERT(m_currentNode);
- Node* divNode = parentTag(m_currentNode, "div");
+ Node* divNode = tqparentTag(m_currentNode, "div");
Q_ASSERT(divNode);
Node* divClosingNode = divNode->getClosingNode();
@@ -245,7 +245,7 @@ void TagActionSet::slotCutDivElement()
{
Q_ASSERT(m_currentNode);
- Node* divNode = parentTag(m_currentNode, "div");
+ Node* divNode = tqparentTag(m_currentNode, "div");
Q_ASSERT(divNode);
Node* divClosingNode = divNode->getClosingNode();
@@ -266,31 +266,31 @@ void TagActionSet::slotCutDivElement()
//_____________________________________________________________________________
-TableTagActionSet::TableTagActionSet(TQObject *parent, const char *name)
- : TagActionSetAbstract(parent, name), m_separator(0), m_tableActionMenu_0(0), m_insertActionMenu_1(0)
+TableTagActionSet::TableTagActionSet(TQObject *tqparent, const char *name)
+ : TagActionSetAbstract(tqparent, name), m_separator(0), m_tableActionMenu_0(0), m_insertActionMenu_1(0)
{
m_separator = new KActionSeparator();
}
bool TableTagActionSet::isInTagContext() const
{
- return parentTag(m_currentNode, "table");
+ return tqparentTag(m_currentNode, "table");
}
void TableTagActionSet::initActionMenus(TQWidget* widget)
{
Q_ASSERT(!m_tableActionMenu_0);
- m_tableActionMenu_0 = new KActionMenu(i18n("Table..."), widget);
+ m_tableActionMenu_0 = new KActionMenu(i18n("Table..."), TQT_TQOBJECT(widget));
m_insertActionMenu_1 = new KActionMenu(i18n("Insert..."), m_tableActionMenu_0);
m_removeActionMenu_1 = new KActionMenu(i18n("Remove..."), m_tableActionMenu_0);
}
-void TableTagActionSet::initActions(TQWidget* parent)
+void TableTagActionSet::initActions(TQWidget* tqparent)
{
if(!m_tableActionMenu_0)
- initActionMenus(parent);
+ initActionMenus(tqparent);
KActionCollection* ac(TagActionManager::self()->actionCollection());
@@ -575,19 +575,19 @@ void TableTagActionSet::slotInsertTable()
bool TableTagActionSet::canInsertRowAbove() const
{
- return isInTagContext() && parentTag(m_currentNode, "tbody");
+ return isInTagContext() && tqparentTag(m_currentNode, "tbody");
}
void TableTagActionSet::slotInsertRowAbove()
{
Q_ASSERT(m_currentNode);
- Node* nearRow = parentTag(m_currentNode, "tr");
+ Node* nearRow = tqparentTag(m_currentNode, "tr");
if(!nearRow)
return;
- Node* nodeParent= nearRow->parent;
+ Node* nodeParent= nearRow->tqparent;
QuantaView* view = ViewManager::ref()->activeView();
NodeModifsSet *modifs = new NodeModifsSet();
@@ -610,16 +610,16 @@ void TableTagActionSet::slotInsertRowBelow()
Q_ASSERT(m_currentNode);
Node* nearRow = 0;
- Node* aux = parentTag(m_currentNode, "thead");
+ Node* aux = tqparentTag(m_currentNode, "thead");
if(aux)
nearRow= firstChildTag(tableStart(), "tr");
else
- nearRow = parentTag(m_currentNode, "tr");
+ nearRow = tqparentTag(m_currentNode, "tr");
if(!nearRow)
return;
- Node* nodeParent= nearRow->parent;
+ Node* nodeParent= nearRow->tqparent;
Node* nextSibling = nearRow->SNext();
QuantaView* view = ViewManager::ref()->activeView();
@@ -781,7 +781,7 @@ void TableTagActionSet::slotRemoveRows()
if(!selection.hasSelection())
{
- Node* nearTr = parentTag(m_currentNode, "tr");
+ Node* nearTr = tqparentTag(m_currentNode, "tr");
kafkaCommon::extractAndDeleteNode(nearTr, modifs, true, true);
}
else
@@ -789,8 +789,8 @@ void TableTagActionSet::slotRemoveRows()
Node* startSelection = kafkaCommon::getNodeFromLocation(selection.cursorNode());
Node* endSelection = kafkaCommon::getNodeFromLocation(selection.cursorNodeEndSel());
- Node* startTr = parentTag(startSelection, "tr");
- Node* endTr = parentTag(endSelection, "tr");
+ Node* startTr = tqparentTag(startSelection, "tr");
+ Node* endTr = tqparentTag(endSelection, "tr");
Node* iteratorNode = startTr;
bool loop(true);
@@ -844,7 +844,7 @@ void TableTagActionSet::slotRemoveColumns()
if(startColumnIndex == -1 || endColumnIndex == -1)
return;
- m_currentNode = parentTag(m_currentNode, "tbody"); // m_currentNode will become invalid
+ m_currentNode = tqparentTag(m_currentNode, "tbody"); // m_currentNode will become invalid
for(int i = 0; i != numberOfColumnsSelected; ++i)
removeColumn(startColumnIndex, modifs);
}
@@ -880,9 +880,9 @@ void TableTagActionSet::slotRemoveCellsContent()
if(!selection.hasSelection())
{
Node* aux = m_currentNode;
- m_currentNode = parentTag(m_currentNode, "tbody");
+ m_currentNode = tqparentTag(m_currentNode, "tbody");
- Node* nearTd = parentTag(aux, "td");
+ Node* nearTd = tqparentTag(aux, "td");
clearCellContents(nearTd, modifs);
}
else
@@ -890,8 +890,8 @@ void TableTagActionSet::slotRemoveCellsContent()
Node* startSelection = kafkaCommon::getNodeFromLocation(selection.cursorNode());
Node* endSelection = kafkaCommon::getNodeFromLocation(selection.cursorNodeEndSel());
- Node* startTd = parentTag(startSelection, "td");
- Node* endTd = parentTag(endSelection, "td");
+ Node* startTd = tqparentTag(startSelection, "td");
+ Node* endTd = tqparentTag(endSelection, "td");
if(!startTd || !endTd)
return;
@@ -933,8 +933,8 @@ void TableTagActionSet::slotMergeSelectedCells()
Node* startSelection = kafkaCommon::getNodeFromLocation(selection.cursorNode());
Node* endSelection = kafkaCommon::getNodeFromLocation(selection.cursorNodeEndSel());
- Node* startTd = parentTag(startSelection, "td");
- Node* endTd = parentTag(endSelection, "td");
+ Node* startTd = tqparentTag(startSelection, "td");
+ Node* endTd = tqparentTag(endSelection, "td");
Node* nodeIterator = startTd->SNext();
Node* stopNode = endTd->SNext();
@@ -975,7 +975,7 @@ Node* TableTagActionSet::tableStart() const
Q_ASSERT(isInTagContext());
Q_ASSERT(m_currentNode);
- return parentTag(m_currentNode, "table");
+ return tqparentTag(m_currentNode, "table");
}
int TableTagActionSet::numberOfColumns() const
@@ -1004,7 +1004,7 @@ int TableTagActionSet::numberOfColumns() const
int TableTagActionSet::currentColumnIndex() const
{
return columnIndex(m_currentNode);
-/* Node* nearTd = parentTag(m_currentNode, "td");
+/* Node* nearTd = tqparentTag(m_currentNode, "td");
if(!nearTd)
return -1;
@@ -1012,7 +1012,7 @@ int TableTagActionSet::currentColumnIndex() const
if(!_tableStart)
return -1;
- Node* firstTd = firstChildTag(parentTag(m_currentNode, "tr"), "td");
+ Node* firstTd = firstChildTag(tqparentTag(m_currentNode, "tr"), "td");
//Node* firstTd = firstChildTag(_tableStart, "td");
if(!firstTd)
return -1;
@@ -1032,7 +1032,7 @@ int TableTagActionSet::currentColumnIndex() const
int TableTagActionSet::columnIndex(Node* node) const
{
- Node* nearTd = parentTag(node, "td");
+ Node* nearTd = tqparentTag(node, "td");
if(!nearTd)
return -1;
@@ -1040,7 +1040,7 @@ int TableTagActionSet::columnIndex(Node* node) const
if(!_tableStart)
return -1;
- Node* firstTd = firstChildTag(parentTag(node, "tr"), "td");
+ Node* firstTd = firstChildTag(tqparentTag(node, "tr"), "td");
if(!firstTd)
return -1;