Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

大家好**「How are you」** is not bolded #421

Closed
seaspeak opened this issue Sep 23, 2018 · 7 comments
Closed

大家好**「How are you」** is not bolded #421

seaspeak opened this issue Sep 23, 2018 · 7 comments

Comments

@seaspeak
Copy link

PLEASE elaborate the issue in detail
请详细描述问题


OS Version (操作系统): Windows, Linux, macOS

VNote Version (VNote版本): 1.22

Symptoms (表现):
大家好**「How are you」** is bolded in edit mode. But in preview mode it is not.

Adding a space between 是 and '**' solves the problem. But it is inconsistent.

How to Repro (如何复现):

@Warning-Forever
Copy link

I have an opposite problem.

[**text**] (also [ **text** ] ) is not bold in Edit Mode, but bold in Read Mode. VNote v2.
In the previous versions text in brackets was bold in Edit Mode.

@tamlok
Copy link
Member

tamlok commented Sep 24, 2018

VNote uses different parsers in edit mode and read mode. It is hard to make them exactly consistent. So I recommend to always add spaces around them.

@Warning-Forever For [**text**], it is because VNote treats it a reference title [xxx]. I need to think about it whether we need to support bold in the reference.

Thanks!

@Warning-Forever
Copy link

Warning-Forever commented Sep 24, 2018

Okay. It's actually not a big problem. :)
Thanks.

ADDED:
But it can be not a reference, but simply text in square brackets.

@seaspeak
Copy link
Author

"好" and "「" are all wide characters. So it is awkward to add a space between them.

@tamlok
Copy link
Member

tamlok commented Sep 30, 2018

Similar issue as #429

@ttimasdf
Copy link

Yeah, more spaces is a good practice. However, Adding spaces manually over times is tiring and easily forgotten, sometimes.
Could there be a possible enhancement adding spaces between normal and CJK characters, ONLY outside the recognized "embracing" elements.
For example

大家好**「How are you」**你好我也好。
    ^ ^ ^            ^ ^
    1 2 3            4 5

that we only add a space between 1 and 5, not 2,3 and 4. Would this be easier than hacking the parser?

@tamlok
Copy link
Member

tamlok commented Oct 1, 2018

@ttimasdf Hi, we only need to add one space before adding bold text, then ctrl-B, type the text, then ctrl-B again, add one more extra space, then type following words.

It is intuitive and simple. :) Space 2/3/4 are not needed now.

@tamlok tamlok closed this as completed Aug 15, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants