pbek / QOwnNotes

QOwnNotes is a plain-text file notepad and todo-list manager with Markdown support and Nextcloud / ownCloud integration.
https://www.qownnotes.org/
GNU General Public License v2.0
4.63k stars 410 forks source link

[BUG] Last but one item of Unordered list shown as a header #3061

Closed vinyatu closed 1 month ago

vinyatu commented 2 months ago

In editor panel, a single last dash in unordered list is treated as several "------" which denotes H2 header in Mardown. To my limited knowledge, this behaviour is not up to Mardown standards.

Expected behaviour

pbek commented 2 months ago

Could you please provide an example in Markdown in a code block, so we can actually see what you are talking about? 😊

pbek commented 2 months ago

And maybe a screenshot...

vinyatu commented 2 months ago

Steps to reproduce were wrong, sorry for that. Actual steps to reproduce this bug: 1) create a file with .md extention in your Notes directory 2) open this file with external editor such as ne, mc-edit, vim etc. 3) enter following markdown code

- unordered item 1
- unordered item 2
-

4) save the note 5) open new note in QON screenshot

pbek commented 2 months ago

@Waqar144, this concerns the highlighter. Do you think you can fix that? It only happens when the note is opened, not during editing itself.

Waqar144 commented 2 months ago

Yep

pbek commented 2 months ago

Thank you very much!

pbek commented 2 months ago

24.8.0

pbek commented 2 months ago

There now is a new release, could you please test it and report if it works for you?

vinyatu commented 2 months ago

Yes, this bug seems to be gone. Thank you.

pbek commented 2 months ago

Great, thank you for testing!

vinyatu commented 2 months ago

Vinyatu kindly asks to solve this issue in new versions of QON, as it's sort of critical for him.

pbek commented 2 months ago

Maybe @Waqar144 can find a solution, but I need to also find a solution to test it with Qt 5.15.2. Other than that, pull requests are welcome, @vinyatu, since it's critical to him.

vinyatu commented 2 months ago

QubesOS may work better than NixOS with devbox, but it's kind of slow and resource-hungry, so generally vinyatu doesn't recommend it. What's the big deal with Qt6 - can't we release 2 versions of QON (Qt5 and Qt6) simultaneously?

pbek commented 2 months ago

What's the big deal with Qt6 - can't we release 2 versions of QON (Qt5 and Qt6) simultaneously?

Well, that's the deal: https://github.com/pbek/QOwnNotes/actions/runs/10221164104 (see failed builds) I'm trying to do release builds for Qt6 for a long time now... Plus, every other build system needs to be rewritten and tested everywhere...

vinyatu commented 1 month ago

Pull request is ready: https://github.com/pbek/qmarkdowntextedit/pull/209 It's untested, so whether it works or not is unknown. Sorry for this low-level effort, but at least it's a strart.

Waqar144 commented 1 month ago

https://github.com/pbek/QOwnNotes/actions/runs/10221164104 (see failed builds)

Not very hard to fix, except for the snap one which I don't understand. For windows, there is no reason to be using mingw, msvc should be used instead or at least a newer mingw which has full c++17 support. MacOS seems like a qmake issue.

pbek commented 1 month ago

The regular Qt6 builds, like in https://github.com/pbek/QOwnNotes/actions/runs/10221164105 then would also need fixing.

vinyatu commented 1 month ago

It's kind of sad that QON is still on Qt5 four years after Qt6 release - especially taking into the account this software name. vinyatu appreciates Waqar144's efforts to build QON with Qt6, but these builds seem to have a problem with SQL drivers, while pbek's builds run fine on Linux. vinyatu would like to offer help with transitioning to Qt6 (as it could possibly solve a host of problems), but it is prohibitively difficult for him to do so, since his country seems to be denied Qt service for a while.

pbek commented 1 month ago

I made some Builds already work a while ago, but they stopped working again after github's infrastructure changed

pbek commented 1 month ago

But nevertheless, all the Launchpad, Obs, freebsb, aur, slackware,... Und release would also need to change. And there are a lot!

pbek commented 1 month ago

24.8.3

There now is a new release, could you please test it and report if it works for you?

vinyatu commented 1 month ago

That's a partial success, thank you. However, there's one more issue left unnoticed

- unordered list item
    - unordered list subitem
-

This produces an header both on Windows QON version 24.8.5 Built on Aug 13 2024 with Qt 5.15.2 and on Linux QON 24.8.5 AppImage Built on Aug 13 2024 with Qt 6.5.0 Should we open a new issue? Or do you believe this to be a normal markdown processing?

pbek commented 1 month ago

So you are using a Tab character (\t) as indent? Please open a new issue.