From 82f32ef0e4e744276a011e30ce99aafa341ea816 Mon Sep 17 00:00:00 2001 From: Thiago Macieira Date: Fri, 29 Apr 2011 18:54:16 +0200 Subject: Fix alignment value not handled in ODF We're currently getting this error: src/gui/text/qtextodfwriter.cpp:592:16: error: enumeration value 'AlignBaseline' not handled in switch [-Werror=switch] Solve by making AlignBaseline operate like AlignNormal. Patch suggested by: Thomas Zander Reviewed-By: Thiago Macieira --- src/gui/text/qtextodfwriter.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/gui/text/qtextodfwriter.cpp b/src/gui/text/qtextodfwriter.cpp index 1619c9c..2addc0f 100644 --- a/src/gui/text/qtextodfwriter.cpp +++ b/src/gui/text/qtextodfwriter.cpp @@ -591,6 +591,7 @@ void QTextOdfWriter::writeCharacterFormat(QXmlStreamWriter &writer, QTextCharFor QString value; switch (format.verticalAlignment()) { case QTextCharFormat::AlignMiddle: + case QTextCharFormat::AlignBaseline: case QTextCharFormat::AlignNormal: value = QString::fromLatin1("0%"); break; case QTextCharFormat::AlignSuperScript: value = QString::fromLatin1("super"); break; case QTextCharFormat::AlignSubScript: value = QString::fromLatin1("sub"); break; -- cgit v0.12