Commit 9f7b4527 authored by Marat Radchenko's avatar Marat Radchenko 🕹 Committed by Albert Astals Cid
Browse files

add support for <subtitle> tag in FictionBook

(cherry picked from commit bcdd5a99)
parent 239827ba
......@@ -687,7 +687,22 @@ bool Converter::convertPoem(const QDomElement &element)
bool Converter::convertSubTitle(const QDomElement &element)
{
Q_UNUSED(element)
QTextFrame *topFrame = mCursor->currentFrame();
QTextFrameFormat frameFormat;
frameFormat.setBorder(1);
frameFormat.setPadding(8);
frameFormat.setBackground(Qt::lightGray);
frameFormat.setTopMargin(16);
mCursor->insertFrame(frameFormat);
if (!convertParagraph(element)) {
return false;
}
mCursor->setPosition(topFrame->lastPosition());
return true;
}
......
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