diff options
Diffstat (limited to 'lib/kformula/kformuladocument.cpp')
-rw-r--r-- | lib/kformula/kformuladocument.cpp | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/lib/kformula/kformuladocument.cpp b/lib/kformula/kformuladocument.cpp index 24d7c6504..6d954d66c 100644 --- a/lib/kformula/kformuladocument.cpp +++ b/lib/kformula/kformuladocument.cpp @@ -125,7 +125,7 @@ int Document::formulaCount() bool Document::loadXML( const TQDomDocument& doc ) { setCreationStrategy( "Ordinary" ); - + //clear(); TQDomElement root = doc.documentElement(); @@ -205,12 +205,12 @@ TQDomDocument Document::createDomDocument() */ TQDomDocument Document::createMathMLDomDocument() { - TQDomDocumentType dt = + TQDomDocumentType dt = TQDomImplementation().createDocumentType( "math", "-//W3C//DTD MathML 2.0//EN", "http://www.w3.org/TR/MathML2/dtd/mathml2.dtd"); TQDomDocument doc( dt ); - doc.insertBefore( doc.createProcessingInstruction( "xml", + doc.insertBefore( doc.createProcessingInstruction( "xml", "version=\"1.0\" encoding=\"UTF-8\"" ), doc.documentElement() ); return doc; @@ -1212,10 +1212,10 @@ void DocumentWrapper::setEnabled( bool enabled ) getAddLowerLeftAction()->setEnabled( enabled ); getAddUpperRightAction()->setEnabled( enabled ); getAddLowerRightAction()->setEnabled( enabled ); - + getAddGenericUpperAction()->setEnabled( enabled ); getAddGenericLowerAction()->setEnabled( enabled ); - + if ( enabled ) { getAddGenericUpperAction()-> @@ -1277,6 +1277,7 @@ void DocumentWrapper::setEnabled( bool enabled ) void DocumentWrapper::enableMatrixActions( bool b) { + if (!m_hasActions) return; getAppendColumnAction()->setEnabled( b ); getInsertColumnAction()->setEnabled( b ); getRemoveColumnAction()->setEnabled( b ); |