Folding HTML

Questions on using RSyntaxTextArea should go here.

Moderator: robert

Folding HTML

Postby Bennou » Mon Sep 24, 2012 9:48 pm

hi !
First scuse my poor english...the school is so far from me....
Second, what a awesome job you have done!!!! I'm starting coding in Java since tow days (don't worry, I wrote code since my 12 in many other languages) and your coponents is so easy to use!

My problem : i din't find the way to have folding with HML language, works fine with css and javascript.


Re: Folding HTML

Postby robert » Tue Sep 25, 2012 12:20 pm

Hi Bennou,

Thanks for the kind words! HTML is tougher to fold properly, since some tags don't need to be closed, so it's tough to determine what needs to be a fold region. I might look into how other editors handle this and try to mimic what they do.
User avatar
Posts: 852
Joined: Sat May 10, 2008 5:16 pm

Re: Folding HTML

Postby Guest » Sun Sep 30, 2012 11:43 am


maybe some track (not sure that's the good word, in french we said "j'ai peut être une piste" to say that we have some hypothesis...), in the recommandation of W3C , the autoclose tags (like <br/> <img src....../>) tooks "/" befor ">" ....

Re: Folding HTML

Postby robert » Tue Oct 02, 2012 12:27 pm

I'm working on this now, for a handful of tags where it is "safe" to do so (i.e. for HTML 4 and 5, tags should always either be self-closed or have an explicit close tag).

  • body
  • canvas
  • div
  • form
  • head
  • ol
  • pre
  • script
  • span
  • style
  • table
  • tfoot
  • thead
  • tr
  • td
  • ul

This should be usable for PHP and JSP as well, so they have some semblance of code folding also.
User avatar
Posts: 852
Joined: Sat May 10, 2008 5:16 pm

Return to Help

Who is online

Users browsing this forum: No registered users and 1 guest