unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
* HTML and CSS in Emacs
@ 2011-02-19 15:00 Alexander Stepanov
  2011-02-20  5:07 ` Rafe Kettler
                   ` (3 more replies)
  0 siblings, 4 replies; 15+ messages in thread
From: Alexander Stepanov @ 2011-02-19 15:00 UTC (permalink / raw)
  To: help-gnu-emacs

I tried to use some html modes for Emacsand did not find any good
mode. I need autocompletion and highlighting of closing tags. Which
addons to use?

http://img513.imageshack.us/img513/6793/npp1.png
http://img263.imageshack.us/img263/8581/npp2.png


^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: HTML and CSS in Emacs
  2011-02-19 15:00 HTML and CSS in Emacs Alexander Stepanov
@ 2011-02-20  5:07 ` Rafe Kettler
  2011-02-20  5:12 ` Bernardo
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 15+ messages in thread
From: Rafe Kettler @ 2011-02-20  5:07 UTC (permalink / raw)
  To: help-gnu-emacs

> I need autocompletion

Set up some abbreviations.<a href="http://docstore.mik.ua/orelly/unix/
upt/ch32_11.htm">This link should get you started on that</a>. I'm not
sure exactly what you'd want to autocomplete, that's your choice.

As for highlighting closing tags, I'm not sure.


^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: HTML and CSS in Emacs
  2011-02-19 15:00 HTML and CSS in Emacs Alexander Stepanov
  2011-02-20  5:07 ` Rafe Kettler
@ 2011-02-20  5:12 ` Bernardo
  2011-02-20 11:45 ` Le Wang
  2011-02-25 20:18 ` Max Penet
  3 siblings, 0 replies; 15+ messages in thread
From: Bernardo @ 2011-02-20  5:12 UTC (permalink / raw)
  To: Alexander Stepanov; +Cc: help-gnu-emacs


> I tried to use some html modes for Emacsand did not find any good
> mode. I need autocompletion and highlighting of closing tags. Which
> addons to use?
> 
> http://img513.imageshack.us/img513/6793/npp1.png
> http://img263.imageshack.us/img263/8581/npp2.png
> 

not a straight answer to your question, but i use Auto Complete for C++ 
and Python code, not sure how hard would it be to provide html support
   http://cx4a.org/software/auto-complete/

a general "Completion" topic on the wiki could be found here
   http://www.emacswiki.org/emacs/CategoryCompletion#toc3






^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: HTML and CSS in Emacs
  2011-02-19 15:00 HTML and CSS in Emacs Alexander Stepanov
  2011-02-20  5:07 ` Rafe Kettler
  2011-02-20  5:12 ` Bernardo
@ 2011-02-20 11:45 ` Le Wang
  2011-02-20 19:45   ` Peter Dyballa
  2011-02-25 20:18 ` Max Penet
  3 siblings, 1 reply; 15+ messages in thread
From: Le Wang @ 2011-02-20 11:45 UTC (permalink / raw)
  To: Alexander Stepanov; +Cc: help-gnu-emacs

[-- Attachment #1: Type: text/plain, Size: 774 bytes --]

On Sat, Feb 19, 2011 at 11:00 PM, Alexander Stepanov <darkdrip@gmail.com>wrote:

> I tried to use some html modes for Emacsand did not find any good
> mode. I need autocompletion and highlighting of closing tags. Which
> addons to use?
>
> http://img513.imageshack.us/img513/6793/npp1.png
> http://img263.imageshack.us/img263/8581/npp2.png
>

nxml-mode has completion for XHTML files.  Nxhtml-mode is based on nxml-mode
with additional features, including mmm-mode for inlined javascript, php,
and RoR code chunks.  I'm not aware of anything that does the dotted line
from opening tag down to closing tag, but Nxhtml is able to fold code.

You likely won't get your Emacs to look as nice as this Notepad++
application, but I bet Emacs understands your HTML better.


-- 
Le

[-- Attachment #2: Type: text/html, Size: 1265 bytes --]

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: HTML and CSS in Emacs
  2011-02-20 11:45 ` Le Wang
@ 2011-02-20 19:45   ` Peter Dyballa
  0 siblings, 0 replies; 15+ messages in thread
From: Peter Dyballa @ 2011-02-20 19:45 UTC (permalink / raw)
  To: Le Wang; +Cc: help-gnu-emacs, Alexander Stepanov


Am 20.02.2011 um 12:45 schrieb Le Wang:

> nxml-mode has completion for XHTML files.


It can be found in GNU Emacsen 23.x and 24.0, the developer version  
from bzr.

--
Greetings

   Pete

Real Time, adj.:
	Here and now, as opposed to fake time, which only occurs there and  
then.




^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: HTML and CSS in Emacs
  2011-02-19 15:00 HTML and CSS in Emacs Alexander Stepanov
                   ` (2 preceding siblings ...)
  2011-02-20 11:45 ` Le Wang
@ 2011-02-25 20:18 ` Max Penet
  2011-02-26 19:49   ` Darth Emacs
                     ` (2 more replies)
  3 siblings, 3 replies; 15+ messages in thread
From: Max Penet @ 2011-02-25 20:18 UTC (permalink / raw)
  To: help-gnu-emacs

On Feb 19, 4:00 pm, Alexander Stepanov <darkd...@gmail.com> wrote:
> I tried to use some html modes for Emacsand did not find any good
> mode. I need autocompletion and highlighting of closing tags. Which
> addons to use?
>
> http://img513.imageshack.us/img513/6793/npp1.pnghttp://img263.imageshack.us/img263/8581/npp2.png


I use both yasnippet and zencoding for html editing, it works
wonderfully, i hardly ever type a closing tag or attributes.

For highlighting there are a few choices available, depends if you
need on the fly validation, something more lightweight and also the
template language you use if it s not raw html (in that case yasnippet
allows you to go behond html and define your own snippets, huge
timesaver)


^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: HTML and CSS in Emacs
  2011-02-25 20:18 ` Max Penet
@ 2011-02-26 19:49   ` Darth Emacs
  2011-02-27 10:38   ` ken
  2011-03-12 15:35   ` Alexander Stepanov
  2 siblings, 0 replies; 15+ messages in thread
From: Darth Emacs @ 2011-02-26 19:49 UTC (permalink / raw)
  To: help-gnu-emacs

[-- Attachment #1: Type: text/plain, Size: 1145 bytes --]

I was wondering if anyone had any ideas or had heard anything on approaching
html 5 and css 3 with a mode?

On Fri, Feb 25, 2011 at 1:18 PM, Max Penet <zcamster@gmail.com> wrote:

> On Feb 19, 4:00 pm, Alexander Stepanov <darkd...@gmail.com> wrote:
> > I tried to use some html modes for Emacsand did not find any good
> > mode. I need autocompletion and highlighting of closing tags. Which
> > addons to use?
> >
> >
> http://img513.imageshack.us/img513/6793/npp1.pnghttp://img263.imageshack.us/img263/8581/npp2.png
>
>
> I use both yasnippet and zencoding for html editing, it works
> wonderfully, i hardly ever type a closing tag or attributes.
>
> For highlighting there are a few choices available, depends if you
> need on the fly validation, something more lightweight and also the
> template language you use if it s not raw html (in that case yasnippet
> allows you to go behond html and define your own snippets, huge
> timesaver)
>



-- 
* Darth Emacs *

“Duct tape is like the force. It has a light side, a dark side, and it holds
the universe together. <http://thinkexist.com/quotes/oprah_winfrey/>”

[-- Attachment #2: Type: text/html, Size: 1841 bytes --]

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: HTML and CSS in Emacs
  2011-02-25 20:18 ` Max Penet
  2011-02-26 19:49   ` Darth Emacs
@ 2011-02-27 10:38   ` ken
  2011-03-12 15:35   ` Alexander Stepanov
  2 siblings, 0 replies; 15+ messages in thread
From: ken @ 2011-02-27 10:38 UTC (permalink / raw)
  To: Max Penet; +Cc: help-gnu-emacs


On 02/25/2011 03:18 PM Max Penet wrote:
> On Feb 19, 4:00 pm, Alexander Stepanov <darkd...@gmail.com> wrote:
>> I tried to use some html modes for Emacsand did not find any good
>> mode. I need autocompletion and highlighting of closing tags. Which
>> addons to use?
>>
>> http://img513.imageshack.us/img513/6793/npp1.pnghttp://img263.imageshack.us/img263/8581/npp2.png
> 
> 
> I use both yasnippet and zencoding for html editing, it works
> wonderfully, i hardly ever type a closing tag or attributes.
> 
> ....

I've been using html-helper-mode for what must be ten years now.  It has
highlighting, autocompletion, and auto-insertion of closing tags... and
a lot more.  When you open a buffer for html editing, a didactic menu
appears, so you can use your mouse to invoke commands.  I prefer the
keyboard though.  Using the prefix-arg (C-u) to relevant HTML tags,
html-helper will put tags around a region you've specified.  Find this
mode on the emacswiki.

hth,
ken



^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: HTML and CSS in Emacs
  2011-02-25 20:18 ` Max Penet
  2011-02-26 19:49   ` Darth Emacs
  2011-02-27 10:38   ` ken
@ 2011-03-12 15:35   ` Alexander Stepanov
  2011-03-12 15:46     ` Alexander Stepanov
  2 siblings, 1 reply; 15+ messages in thread
From: Alexander Stepanov @ 2011-03-12 15:35 UTC (permalink / raw)
  To: help-gnu-emacs

On Feb 25, 10:18 pm, Max Penet <zcams...@gmail.com> wrote:
> On Feb 19, 4:00 pm, Alexander Stepanov <darkd...@gmail.com> wrote:
>
> > I tried to use somehtmlmodes for Emacsand did not find any good
> > mode. I need autocompletion and highlighting of closing tags. Which
> > addons to use?
>
> >http://img513.imageshack.us/img513/6793/npp1.pnghttp://img263.imagesh...
>
> I use both yasnippet and zencoding forhtmlediting, it works
> wonderfully, i hardly ever type a closing tag or attributes.
>
> For highlighting there are a few choices available, depends if you
> need on the fly validation, something more lightweight and also the
> template language you use if it s not rawhtml(in that case yasnippet
> allows you to go behondhtmland define your own snippets, huge
> timesaver)

It will be cool to get the highlighting of <foo>-</foo> and {-} in the
same way as Notepad++ does. Validation is not required.


^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: HTML and CSS in Emacs
  2011-03-12 15:35   ` Alexander Stepanov
@ 2011-03-12 15:46     ` Alexander Stepanov
  2011-03-12 17:11       ` Perry Smith
                         ` (3 more replies)
  0 siblings, 4 replies; 15+ messages in thread
From: Alexander Stepanov @ 2011-03-12 15:46 UTC (permalink / raw)
  To: help-gnu-emacs

I looked at nxml one more time. It has completion of closing tags.
This is a good news for me. And bad news is that nxml does not have
intellisense if html file don't have xhtml declaration. There are a
lot of xml files which begin just with "<html>" and do not have a
doctype.


^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: HTML and CSS in Emacs
  2011-03-12 15:46     ` Alexander Stepanov
@ 2011-03-12 17:11       ` Perry Smith
  2011-03-12 17:35       ` Joe Snikeris
                         ` (2 subsequent siblings)
  3 siblings, 0 replies; 15+ messages in thread
From: Perry Smith @ 2011-03-12 17:11 UTC (permalink / raw)
  To: Alexander Stepanov; +Cc: help-gnu-emacs


On Mar 12, 2011, at 9:46 AM, Alexander Stepanov wrote:

> I looked at nxml one more time. It has completion of closing tags.
> This is a good news for me. And bad news is that nxml does not have
> intellisense if html file don't have xhtml declaration. There are a
> lot of xml files which begin just with "<html>" and do not have a
> doctype.

I get confused between all the xml variations for emacs.  I'm using

http://ourcomments.org/Emacs/nXhtml/doc/nxhtml.html

The person who wrote it provides really good support.  I'm not
using the standard distribution but one that has been patched.

You might want to try it and if you have complaints / suggestions,
contact the guy and see if he can iron out the problems you are
having.

HTH
Perry




^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: HTML and CSS in Emacs
  2011-03-12 15:46     ` Alexander Stepanov
  2011-03-12 17:11       ` Perry Smith
@ 2011-03-12 17:35       ` Joe Snikeris
       [not found]       ` <mailman.1.1299951377.9013.help-gnu-emacs@gnu.org>
  2011-03-16  3:37       ` Jason Rumney
  3 siblings, 0 replies; 15+ messages in thread
From: Joe Snikeris @ 2011-03-12 17:35 UTC (permalink / raw)
  To: Alexander Stepanov; +Cc: help-gnu-emacs

Alexander Stepanov <darkdrip@gmail.com> writes:

> I looked at nxml one more time. It has completion of closing tags.
> This is a good news for me. And bad news is that nxml does not have
> intellisense if html file don't have xhtml declaration. There are a
> lot of xml files which begin just with "<html>" and do not have a
> doctype.

Check out nxhmtl-mode:

http://ourcomments.org/Emacs/nXhtml/doc/nxhtml.html

"For files mixing XHTML with codes, like PHP, you can use something I call Fictive XHTML Validation Headers. That allows you to use XHTML completion even if those files does not have the XHTML headers needed."



^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: HTML and CSS in Emacs
       [not found]       ` <mailman.1.1299951377.9013.help-gnu-emacs@gnu.org>
@ 2011-03-13 15:40         ` Alexander Stepanov
  2011-03-15 14:41           ` Oleksandr Gavenko
  0 siblings, 1 reply; 15+ messages in thread
From: Alexander Stepanov @ 2011-03-13 15:40 UTC (permalink / raw)
  To: help-gnu-emacs

Thank you for your advices. When I’ll have free time I will try to use
at nxhtml and html-helper-mode one more time.
Unfortunately I can't use EmacsW32 because it use too ugly. I use
Windows XP and vanilla emacs. It was difficult to me to install nxml.
nxhtml is even more difficult in installation. It outputted some error
when I tried to use it. I have spent near 4 hours and didn't cope with
this problem


^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: HTML and CSS in Emacs
  2011-03-13 15:40         ` Alexander Stepanov
@ 2011-03-15 14:41           ` Oleksandr Gavenko
  0 siblings, 0 replies; 15+ messages in thread
From: Oleksandr Gavenko @ 2011-03-15 14:41 UTC (permalink / raw)
  To: help-gnu-emacs

On 13.03.2011 17:40, Alexander Stepanov wrote:
> Thank you for your advices. When I’ll have free time I will try to use
> at nxhtml and html-helper-mode one more time.
> Unfortunately I can't use EmacsW32 because it use too ugly. I use
> Windows XP and vanilla emacs. It was difficult to me to install nxml.
nxml for a long time come with GNU Emacs...




^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: HTML and CSS in Emacs
  2011-03-12 15:46     ` Alexander Stepanov
                         ` (2 preceding siblings ...)
       [not found]       ` <mailman.1.1299951377.9013.help-gnu-emacs@gnu.org>
@ 2011-03-16  3:37       ` Jason Rumney
  3 siblings, 0 replies; 15+ messages in thread
From: Jason Rumney @ 2011-03-16  3:37 UTC (permalink / raw)
  To: help-gnu-emacs

It is possible with nxml to associate a schema with an opening tag or file extension, as well as the doctype. See section 6 "Locating a schema" in the nxml manual.


^ permalink raw reply	[flat|nested] 15+ messages in thread

end of thread, other threads:[~2011-03-16  3:37 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-02-19 15:00 HTML and CSS in Emacs Alexander Stepanov
2011-02-20  5:07 ` Rafe Kettler
2011-02-20  5:12 ` Bernardo
2011-02-20 11:45 ` Le Wang
2011-02-20 19:45   ` Peter Dyballa
2011-02-25 20:18 ` Max Penet
2011-02-26 19:49   ` Darth Emacs
2011-02-27 10:38   ` ken
2011-03-12 15:35   ` Alexander Stepanov
2011-03-12 15:46     ` Alexander Stepanov
2011-03-12 17:11       ` Perry Smith
2011-03-12 17:35       ` Joe Snikeris
     [not found]       ` <mailman.1.1299951377.9013.help-gnu-emacs@gnu.org>
2011-03-13 15:40         ` Alexander Stepanov
2011-03-15 14:41           ` Oleksandr Gavenko
2011-03-16  3:37       ` Jason Rumney

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).