<table><tr><td style="">kqwyf added a comment.
</td><a style="text-decoration: none; padding: 4px 8px; margin: 0 8px 8px; float: right; color: #464C5C; font-weight: bold; border-radius: 3px; background-color: #F7F7F9; background-image: linear-gradient(to bottom,#fff,#f1f0f1); display: inline-block; border: 1px solid rgba(71,87,120,.2);" href="https://phabricator.kde.org/D14738">View Revision</a></tr></table><br /><div><div><p>Here comes a problem...</p>

<p>The reason I'd like to make rendered markdown entries uneditable is that, if the user edited a rendered markdown entry, then we could never convert the content (in html) back to markdown.<br />
To imitate the behaviors of latex entries better, I thought it's a good idea that the cursor can move on the markdown entries while they can't be edited.</p>

<p>But in worksheettextitem.cpp, line 433-437, it wrote:</p>

<div class="remarkup-code-block" style="margin: 12px 0;" data-code-lang="text" data-sigil="remarkup-code-block"><pre class="remarkup-code" style="font: 11px/15px "Menlo", "Consolas", "Monaco", monospace; padding: 12px; margin: 0; background: rgba(71, 87, 120, 0.08);">void WorksheetTextItem::keyPressEvent(QKeyEvent *event)
{
    if (!isEditable())
        return;
    // other code
}</pre></div>

<p>which means that the cursor can't move on an uneditable entry.</p>

<p>A compromise solution is to make <tt style="background: #ebebeb; font-size: 13px;">MarkdownEntry::wantFocus()</tt> return false when the entry is uneditable. And this will cause the cursor to skip the rendered markdown entries. Is that okay?</p>

<p>BTW, when loading a rendered markdown entry, the markdown content will be rendered, but the latex formulas will remain in code form (just like the text entries). Is that okay? Or should they be rendered (by saving all the eps files in the archive), too?</p></div></div><br /><div><strong>REPOSITORY</strong><div><div>R55 Cantor</div></div></div><br /><div><strong>REVISION DETAIL</strong><div><a href="https://phabricator.kde.org/D14738">https://phabricator.kde.org/D14738</a></div></div><br /><div><strong>To: </strong>kqwyf, pino, Cantor, filipesaraiva<br /><strong>Cc: </strong>sirgienko, filipesaraiva, pino, asemke, kde-edu, narvaez, apol<br /></div>