diff --git a/en_US.ISO8859-1/books/fdp-primer/writing-style/chapter.sgml b/en_US.ISO8859-1/books/fdp-primer/writing-style/chapter.sgml index 406bb85d3c..70587c2f4b 100644 --- a/en_US.ISO8859-1/books/fdp-primer/writing-style/chapter.sgml +++ b/en_US.ISO8859-1/books/fdp-primer/writing-style/chapter.sgml @@ -183,9 +183,10 @@ regardless of the indentation level of the file which might contain this one. - Every start tag increases the indentation level by 2 spaces, and - every end tag decreases the indentation level by 2 spaces. Replace - as many leading spaces with tabs as appropriate. Do not use + Opening tags increase the indentation level by 2 spaces. + Closing tags decrease the indentation level by 2 spaces. Blocks + of 8 spaces at the start of a line should be replaced with a tab. + Do not use spaces in front of tabs, and do not add extraneous whitespace at the end of a line. Content within elements should be indented by two spaces if the content runs @@ -209,11 +210,6 @@ V regardless of the indentation level of the file which might contain this one. - Every start tag increases the indentation level by 2 spaces, and - every end tag decreases the indentation level by 2 spaces. Content - within elements should be indented by two spaces if the content runs - over more than one line. - ... @@ -224,6 +220,19 @@ V sgml-mode should be loaded automatically, and the Emacs local variables at the bottom of each file should enforce these styles. + + Vim users might want to configure + their editor with: + + augroup sgmledit + autocmd FileType sgml set formatoptions=cq2l " Special formatting options + autocmd FileType sgml set textwidth=70 " Wrap lines at 70 spaces + autocmd FileType sgml set shiftwidth=2 " Automatically indent + autocmd FileType sgml set softtabstop=2 " Tab key indents 2 spaces + autocmd FileType sgml set tabstop=8 " Replace 8 spaces with a tab + autocmd FileType sgml set autoindent " Automatic indentation +augroup END +