diff --git a/zencoding.vim b/zencoding.vim index 472774d..a469f9c 100644 --- a/zencoding.vim +++ b/zencoding.vim @@ -2,7 +2,7 @@ " File: zencoding.vim " Author: Yasuhiro Matsumoto " Last Change: 23-Feb-2010. -" Version: 0.20 +" Version: 0.21 " WebPage: http://github.com/mattn/zencoding-vim " Description: vim plugins for HTML and CSS hi-speed coding. " SeeAlso: http://code.google.com/p/zen-coding/ @@ -982,9 +982,15 @@ function! s:zen_toString(...) return str endfunction -function! s:zen_expand(word) +function! s:zen_get_filetype() let type = &ft if len(type) == 0 | let type = 'html' | endif + if type == 'xhtml' | let type = 'html' | endif + return type +endfunction + +function! s:zen_expand(word) + let type = s:zen_get_filetype() let line = getline('.')[:col('.')-1] if a:word || type != 'html' let part = matchstr(line, '\([0-9A-Za-z_\@:]\+\)$') diff --git a/zencoding.vim.vimup b/zencoding.vim.vimup index e8d3f19..ab083a3 100644 --- a/zencoding.vim.vimup +++ b/zencoding.vim.vimup @@ -2,7 +2,7 @@ script_name: ZenCoding.vim script_id: '2981' script_type: utility script_package: zencoding.vim -script_version: '0.20' +script_version: '0.21' required_vim_version: '7.0' summary: vim plugins for HTML and CSS hi-speed coding. @@ -71,6 +71,8 @@ install_details: | copy zencoding.vim to your plugin directory. versions: +- '0.21': | + This is an upgrade for ZenCoding.vim: treat xhtml as html. - '0.20': | This is an upgrade for ZenCoding.vim: add option use_zen_complete_tag for complete abbr. - '0.19': |