找回密码
 注册
搜索
热搜: 回贴
微赢网络技术论坛 门户 服务器 Linux/BSD 查看内容

用Emacs来实现html文件的快速编辑

2009-12-20 13:18| 发布者: admin| 查看: 51| 评论: 0|原作者: 回梦游仙

用Emacs来编辑html文档,有两种方法,一种是采用emacs中内置的html-mode,另一种是采用功能更加多的html-helper-mode.不过后者需要安装第三方的插件,对于普通的应用,第一种模式也是比较够用的。使用方式很简单,一种是直接打开.html文件时,会自动进入该模式;另一种是在编辑器输入M-x html-mode。在进入html模式之后,会出现html和sgml菜单,当然,你也可以通过快捷键来进行相关操作。
介绍几个比较有用的技巧:
1).html模板
C-c C-t html
2).预览html
C-c C-v
3).隐藏/显示html标记
C-c tab
4).H1~H6
C-c 1~6
5)
C-c Enter,使用C-c /输入
6)超链接标记
C-c C-c h
当然,还有更多的快捷键来进行html编辑.多数的html标记全部可以用快捷键来代替。不过,采用html-mode的功能还是比较少的,有机会看看html-helper-mode,这个功能较强。不过我在emacs22上试试,尚未成功,应该在老版本上可以。之后,再看一下吧。写得比较简单,只为了抛砖引玉,看官不要见笑。
screen.width*0.7) {this.resized=true; this.width=screen.width*0.7; this.alt='Click here to open new window\nCTRL Mouse wheel to zoom in/out';}" onmouseover="if(this.width>screen.width*0.7) {this.resized=true; this.width=screen.width*0.7; this.style.cursor='hand'; this.alt='Click here to open new window\nCTRL Mouse wheel to zoom in/out';}" onclick="if(!this.resized) {return true;} else {window.open('http://blogimg.chinaunix.net/blog/upfile2/080908000646.png');}" onmousewheel="return imgzoom(this);" alt="" />







最新评论

QQ|小黑屋|最新主题|手机版|微赢网络技术论坛 ( 苏ICP备08020429号 )

GMT+8, 2024-9-29 23:34 , Processed in 0.207534 second(s), 12 queries , Gzip On, MemCache On.

Powered by Discuz! X3.5

© 2001-2023 Discuz! Team.

返回顶部