Use new access functions for wiki-local variables -- part 2

Ref #256
This commit is contained in:
EinfachToll
2016-12-22 19:12:03 +01:00
parent 6221861957
commit 61910cd93a
5 changed files with 13 additions and 20 deletions

View File

@ -88,13 +88,13 @@ endfunction "}}}
function! s:template_full_name(name) "{{{
if a:name == ''
let name = VimwikiGet('template_default')
let name = vimwiki#vars#get_wikilocal('template_default')
else
let name = a:name
endif
let fname = expand(VimwikiGet('template_path').
\ name.VimwikiGet('template_ext'))
let fname = expand(vimwiki#vars#get_wikilocal('template_path').
\ name . vimwiki#vars#get_wikilocal('template_ext'))
if filereadable(fname)
return fname
@ -1361,9 +1361,9 @@ function! vimwiki#html#CustomWiki2HTML(path, wikifile, force) "{{{
\ shellescape(a:path). ' '.
\ shellescape(a:wikifile). ' '.
\ shellescape(s:default_CSS_full_name(a:path)). ' '.
\ (len(VimwikiGet('template_path')) > 1 ? shellescape(expand(VimwikiGet('template_path'))) : '-'). ' '.
\ (len(VimwikiGet('template_default')) > 0 ? VimwikiGet('template_default') : '-'). ' '.
\ (len(VimwikiGet('template_ext')) > 0 ? VimwikiGet('template_ext') : '-'). ' '.
\ (len(vimwiki#vars#get_wikilocal('template_path')) > 1 ? shellescape(expand(vimwiki#vars#get_wikilocal('template_path'))) : '-'). ' '.
\ (len(vimwiki#vars#get_wikilocal('template_default')) > 0 ? vimwiki#vars#get_wikilocal('template_default') : '-'). ' '.
\ (len(vimwiki#vars#get_wikilocal('template_ext')) > 0 ? vimwiki#vars#get_wikilocal('template_ext') : '-'). ' '.
\ (len(VimwikiGet('subdir')) > 0 ? shellescape(s:root_path(VimwikiGet('subdir'))) : '-'))
endfunction " }}}

View File

@ -101,6 +101,7 @@ function! s:populate_wikilocal_options()
\ 'auto_export': 0,
\ 'auto_tags': 0,
\ 'auto_toc': 0,
\ 'automatic_nested_syntaxes': 1,
\ 'css_name': 'style.css',
\ 'custom_wiki2html': '',
\ 'diary_header': 'Diary',