Feed Advanced Search

Dec 21 2018

kqwyf added a comment to D14738: Add the markdown entry.

Hi, @kqwyf, as I see, your GitHub account name is kqwyf, right?
As I see, Github don't connect your commit with your github account, so author this patch on Github is 1160300905.
Should we try to fix this injustice :) and connect your github account with commit author via github support?

Dec 21 2018, 12:07 AM · KDE Edu

Aug 24 2018

kqwyf added a comment to D14738: Add the markdown entry.

Thank you for your help! @pino @asemke @filipesaraiva @sirgienko

Aug 24 2018, 3:09 AM · KDE Edu

Aug 23 2018

kqwyf updated the diff for D14738: Add the markdown entry.
  • update the type value of MarkdownEntry
Aug 23 2018, 2:16 AM · KDE Edu

Aug 22 2018

kqwyf updated the diff for D14738: Add the markdown entry.
  • restore the access modifiers of TextEntry
Aug 22 2018, 3:11 PM · KDE Edu
kqwyf updated the diff for D14738: Add the markdown entry.
  • disable rich text for MarkdownEntry
  • make MarkdownEntry inherit from WorksheetEntry
Aug 22 2018, 2:43 PM · KDE Edu

Aug 21 2018

kqwyf added a comment to D14738: Add the markdown entry.

Do you talk about acceptRichText function?

Aug 21 2018, 1:18 PM · KDE Edu

Aug 20 2018

kqwyf added a comment to D14738: Add the markdown entry.

There may not be an elegant solution (without refactoring) to make the rich text action list support the markdown entry... One solution is to disable the action list for markdown entry. Is that okay?

Aug 20 2018, 2:37 AM · KDE Edu
kqwyf updated the diff for D14738: Add the markdown entry.
  • make MarkdownEntry editable
  • remove latex support from MarkdownEntry
Aug 20 2018, 2:06 AM · KDE Edu

Aug 17 2018

kqwyf added a comment to D14738: Add the markdown entry.

Okey, I got it. Well, LatexEntry don't protect rendered content from editing (and it Cantor's architectural miscalculation), so maybe MarkdownEntry also don't need it? In this revision, I mean.
The solution of this problem (more integrated and consistent with another code) could be added later and applied for markdown and latex entries (so, I think, @kqwyf, you don't need solve this problem)

Aug 17 2018, 4:05 PM · KDE Edu
kqwyf added a comment to D14738: Add the markdown entry.

The two solutions are in the code. You can uncomment one of them to apply it.

Aug 17 2018, 12:32 PM · KDE Edu
kqwyf updated the diff for D14738: Add the markdown entry.
  • feature(incomplete): user can edit a markdown entry by double clicking
Aug 17 2018, 12:22 PM · KDE Edu
kqwyf added a comment to D14738: Add the markdown entry.

Here comes a problem...

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.
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.

In this moment, if you haven't libspectre (or latex), you can't exec latex entry (well, you can, but nothing happens) and another actions allowed. If you haven't libspectre and load worksheet with
latex formulas, we can see rendrered images (okay, in this moment, we can't see, but I working on this problem and this will be fix soon on master), but I could edit unrendered latex entries and convert renderered to unrendered entries by double click.

Aug 17 2018, 12:07 AM · KDE Edu

Aug 16 2018

kqwyf added a comment to D14738: Add the markdown entry.

Here comes a problem...

Aug 16 2018, 5:03 PM · KDE Edu
kqwyf added a comment to D14738: Add the markdown entry.

Could @kqwyf implement this using the same behaviour of LaTeX entry?

Aug 16 2018, 9:35 AM · KDE Edu
kqwyf added a comment to D14738: Add the markdown entry.

In this patch, a markdown entry without Discount support behaves just like a text entry, except that the latex formulas can be re-edited. I think it's a useful feature.

Nitpick: Maybe, then user without Discount edit rendered markdown entry from loaded worksheet, we should drop rendered result? So, users don't forget reevaluate this edited entry later.

Aug 16 2018, 6:32 AM · KDE Edu
kqwyf updated the diff for D14738: Add the markdown entry.
  • update the implementation of the last fix
Aug 16 2018, 3:22 AM · KDE Edu
kqwyf updated the diff for D14738: Add the markdown entry.
  • fix: focus appears at wrong position in markdown entries
Aug 16 2018, 2:59 AM · KDE Edu

Aug 15 2018

kqwyf added a comment to D14738: Add the markdown entry.
  • change all the indentation tabs into spaces
  • remove extra changes
  • update CMakeLists.txt
  • bump the ui version in cantor_part.rc
  • fix the memory leak when converting markdown to HTML
  • feature: save evaluation results for markdown entries
Aug 15 2018, 3:50 PM · KDE Edu
kqwyf updated the diff for D14738: Add the markdown entry.
  • change all the indentation tabs into spaces
  • remove extra changes
  • update CMakeLists.txt
  • bump the ui version in cantor_part.rc
  • fix the memory leak when converting markdown to HTML
  • feature: save evaluation results for markdown entries
Aug 15 2018, 3:47 PM · KDE Edu
kqwyf added a comment to D14738: Add the markdown entry.
Aug 15 2018, 2:55 PM · KDE Edu

Aug 14 2018

kqwyf added a comment to D14738: Add the markdown entry.
In D14738#309034, @pino wrote:

Nitpick: please provide a consistent indentation in the new files -- they seem to mix spaces and tabs.
Also, was this tested when cantor is built without the Discount library? How does it behave when trying to add/edit markdown entries, and trying to load worksheets with such entries?

Aug 14 2018, 5:26 PM · KDE Edu
kqwyf added a comment to D14738: Add the markdown entry.

@kqwyf, after previous two diff changes, Markdown entries starts don't work for me (don't evaluate), is they works on your machine?

I think problem, that
#cmakedefine discount_FOUND 1 don't work now, because we start use Discount_FOUND.

Aug 14 2018, 4:33 PM · KDE Edu
kqwyf updated the diff for D14738: Add the markdown entry.
  • update macros about Discount
Aug 14 2018, 4:31 PM · KDE Edu
kqwyf added a comment to D14738: Add the markdown entry.

@kqwyf Could you find Discount twice? Because I could found Discount only in first cmake run, and in seconds I have

-- The following OPTIONAL packages have not been found:

 * Discount
Aug 14 2018, 4:14 PM · KDE Edu
kqwyf updated the diff for D14738: Add the markdown entry.
  • fix the bug that it won't find Discount when doing cmake twice.
  • add package properties for Discount
Aug 14 2018, 4:07 PM · KDE Edu
kqwyf added a comment to D14738: Add the markdown entry.

Thank you for your contribution @kqwyf. I built with Discount and it is working fine. I built without Discount, I could run Cantor correctly and the options to insert Markdown entries continues to show, but it is a problem with others entries options like LaTeX. Maybe it is time to some refactoring in this part.

For a first contribution it is very good, congrats. Stay with us to develop more features and fix bugs. :)

I will wait some hours for comments of the others reviewers, if they are nothing to ask I will push to you.

Aug 14 2018, 3:39 PM · KDE Edu
kqwyf updated the diff for D14738: Add the markdown entry.
  • remove the commented code
  • fix a bug that a command entry is appended when clicking a new markdown entry
Aug 14 2018, 3:24 PM · KDE Edu
kqwyf updated the summary of D14738: Add the markdown entry.
Aug 14 2018, 7:27 AM · KDE Edu
kqwyf updated the diff for D14738: Add the markdown entry.
  • add FindDiscount.cmake
Aug 14 2018, 5:09 AM · KDE Edu
kqwyf updated the diff for D14738: Add the markdown entry.
  • use Discount to convert Markdown to HTML
Aug 14 2018, 2:58 AM · KDE Edu

Aug 13 2018

kqwyf added a comment to D14738: Add the markdown entry.

@kqwyf thanks for this contribution. We just had a discussion recently about adding the support for markdown to Cantor, see also some https://phabricator.kde.org/T9108. cpp-markdown requries boost for regex. We should avoid introducing here another dependency for something that can also be done with Qt. Are you familiar with libraries mentioned in T9108 or with Discovery mentioned by @pino ?

Aug 13 2018, 12:57 PM · KDE Edu
kqwyf added a comment to D14738: Add the markdown entry.
In D14738#307471, @pino wrote:

Please no embedded copies of 3rdparty libraries.
Also, okular already uses the Discount library for its markdown backend, so what about using it instead?

Aug 13 2018, 11:41 AM · KDE Edu
kqwyf added a comment to D14738: Add the markdown entry.

Hello @kqwyf, are you from that course in a Chinese university about open source contribution?

Aug 13 2018, 11:15 AM · KDE Edu

Aug 11 2018

kqwyf updated the summary of D14738: Add the markdown entry.
Aug 11 2018, 2:16 AM · KDE Edu
kqwyf updated the summary of D14738: Add the markdown entry.
Aug 11 2018, 1:59 AM · KDE Edu
kqwyf requested review of D14738: Add the markdown entry.
Aug 11 2018, 1:57 AM · KDE Edu

Jul 18 2018

kqwyf removed a watcher for Cantor: kqwyf.
Jul 18 2018, 11:58 PM

Jul 16 2018

kqwyf added a watcher for Cantor: kqwyf.
Jul 16 2018, 10:40 AM