Yii Framework Forum: Cmarkdown -- Small Issue With Paragraphs - Yii Framework Forum

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Cmarkdown -- Small Issue With Paragraphs Rate Topic: -----

#1 User is offline   Trejder 

  • Elite Member
  • PipPipPipPipPip
  • Yii
  • Group: Members
  • Posts: 1,257
  • Joined: 06-October 10
  • Location:Southern Poland

Posted 12 October 2012 - 06:03 PM

Official documentation says:

Quote

The implication of the “one or more consecutive lines of text” rule is that Markdown supports “hard-wrapped” text paragraphs

What does "hard-wrapped" means in context of CMarkdown?

I wrote:

You
got to be
kidding me
really hard

parsed it with CMarkdown and got whole sentence in one line.

Where's hard-breaking?
Proud Cookbook author, though still learning powerful Yii! :] See my generic profile for more information. Cheers!
0

#2 User is offline   bennouna 

  • Master Member
  • PipPipPipPip
  • Yii
  • Group: Members
  • Posts: 1,180
  • Joined: 05-January 12
  • Location:Morocco

Posted 12 October 2012 - 06:20 PM

Like this?

You

got to be

kidding me

really hard

0

#3 User is offline   Trejder 

  • Elite Member
  • PipPipPipPipPip
  • Yii
  • Group: Members
  • Posts: 1,257
  • Joined: 06-October 10
  • Location:Southern Poland

Posted 12 October 2012 - 06:40 PM

No! I'm talking about hard-breaking lines inside one paragraph. Not about creating few paragraphs, by separating each with empty line.

Same here, According to docs, this:

> This is a blockquote with two paragraphs. Lorem ipsum dolor sit amet,
> consectetuer adipiscing elit. Aliquam hendrerit mi posuere lectus.
> Vestibulum enim wisi, viverra nec, fringilla in, laoreet vitae, risus.
> 
> Donec sit amet nisl. Aliquam semper ipsum sit amet velit. Suspendisse
> id sem consectetuer libero luctus adipiscing.

Should be written in quotation with line-breaking. I.e. effect should contain five lines. I do se three lines as contents are not wrapped.

I'm not sure, if this problem is caused by CMarkdown itself (a bug) or foced by an external CSS file, as I'm using Yii Bootstrap Extension, which registers a few CSS files.

I'm kindda of ideas. Cheers.
Proud Cookbook author, though still learning powerful Yii! :] See my generic profile for more information. Cheers!
0

#4 User is offline   softark 

  • Keep It Simple
  • Yii
  • Group: Moderators
  • Posts: 3,036
  • Joined: 16-February 11
  • Location:Japan

Posted 12 October 2012 - 08:17 PM

Is this what you are looking for?

Quote

When you do want to insert a <br /> break tag using Markdown, you end a line with two or more spaces, then type return.

0

#5 User is offline   Trejder 

  • Elite Member
  • PipPipPipPipPip
  • Yii
  • Group: Members
  • Posts: 1,257
  • Joined: 06-October 10
  • Location:Southern Poland

Posted 13 October 2012 - 07:36 AM

Nope. I'm aware of two spaces issue and using it.

After reading the same part of Markdown documentation, you cited, I assumed, that "hard-breaks" means that when I break a line using CR/LF, Markdown will also break it. That is the way, I understood Markdown docs and wanted to confirm if I misunderstood it or if there is something wrong with Yii implementation of this?

Look exactly for the example I showed you (blockquote). If I'm getting it right (do I?), without using any double spaces at the end, I should see FIVE lines. While Yii's implementation (CMarkdown) shows me only three. The text is glued together instead of being spearated into different lines.
Proud Cookbook author, though still learning powerful Yii! :] See my generic profile for more information. Cheers!
0

#6 User is offline   softark 

  • Keep It Simple
  • Yii
  • Group: Moderators
  • Posts: 3,036
  • Joined: 16-February 11
  • Location:Japan

Posted 13 October 2012 - 11:07 PM

Quote

I assumed, that "hard-breaks" means that when I break a line using CR/LF, Markdown will also break it.

No, Markdown will not do that.
They wanted to say that "You can use CR/LFs in your source text, and Markdown will automatically concatenate the source lines to create one single paragraph.".
0

#7 User is offline   Trejder 

  • Elite Member
  • PipPipPipPipPip
  • Yii
  • Group: Members
  • Posts: 1,257
  • Joined: 06-October 10
  • Location:Southern Poland

Posted 14 October 2012 - 06:42 AM

OK! Thanks for the explanation, softark.
Proud Cookbook author, though still learning powerful Yii! :] See my generic profile for more information. Cheers!
0

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users