D28854: [KRichTextWidget] Add support for headings

David Faure noreply at phabricator.kde.org
Wed Apr 15 21:05:02 BST 2020


dfaure requested changes to this revision.
dfaure added inline comments.
This revision now requires changes to proceed.

INLINE COMMENTS

> krichtextedit.cpp:346
> +    // level=2 look the same
> +    int sizeAdjustment = boundedLevel > 0 ? 5 - boundedLevel: 0;
> +

If boundedLevel is 6, the size adjustement will be -1?
Does this mean a heading that's smaller than normal text?

> krichtextedit.cpp:375
> +
> +    cursor.mergeBlockCharFormat(chrfmt);
> +    setTextCursor(cursor);

This seems to duplicate what happened with selectCursor already. Why are two cursors necessary to change the style of one paragraph?

REPOSITORY
  R310 KTextWidgets

REVISION DETAIL
  https://phabricator.kde.org/D28854

To: poboiko, #frameworks, mlaurent, ahmadsamir, dfaure
Cc: kde-frameworks-devel, LeGast00n, cblack, michaelh, ngraham, bruns
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-frameworks-devel/attachments/20200415/71d205f0/attachment.html>


More information about the Kde-frameworks-devel mailing list