zoukankan      html  css  js  c++  java
  • 中文文案排版风格指南

    文档规范

    编写文档的过程中,考虑文档的可读性,是一件非常重要的事情。一定程度上,从编写的技术文档中可以看出一个程序员是否专业,是否严谨。

    以下介绍三种文档规范:

    Gengo 风格


    Gengo 风格指南,是 Gengo(一个翻译网站)推荐的翻译风格,受到广泛好评,可以作为文档写作的规范指南。

    文档风格

    豌豆荚文案风格指南


    近两年,豌豆荚发布了它自己的文档风格指南,该文档包含标点符号,遣词造句,用字规范等的使用规定。

    查看文档(google doc 版)

    中文文案排版指北


    这是一份简明的中文排版教程,相比于豌豆荚和 Gengo 的指南,更加简练和实用化,更贴近于中文技术圈约定俗成的排版方案。

    由于文档更新较快,这里给出原文链接

    工具使用


    我们如果使用 vim,则可以使用 盘古插件 自动的生成相应格式的文档,省心省力。

    先配置一下:

    1. 使用 Vundle 进行 vim 的插件管理。具体安装比较简单,可参见官方 readme.md 进行配置。

    2. 将 Pangu 放在 ~/.vimrc 中,然后打开 vim 并执行 :PluginInstall 进行安装即可,可参见如下示例,可将如下配置放于该文件的最顶部。

      set nocompatible              " be iMproved, required
      filetype off                  " required
      
      " set the runtime path to include Vundle and initialize
      set rtp+=~/.vim/bundle/Vundle.vim
      call vundle#begin()
      " alternatively, pass a path where Vundle should install plugins
      "call vundle#begin('~/some/path/here')
      " let Vundle manage Vundle, required
      Plugin 'VundleVim/Vundle.vim'
      " use Pangu to format the doc that wrote in Chinese mixed with English
      Plugin 'https://github.com/hotoo/pangu.vim.git'
      " All of your Plugins must be added before the following line
      call vundle#end()            " required
      filetype plugin indent on    " required
      " To ignore plugin indent changes, instead use:
      "filetype plugin on
      "
      " Brief help
      " :PluginList       - lists configured plugins
      " :PluginInstall    - installs plugins; append `!` to update or just :PluginUpdate
      " :PluginSearch foo - searches for foo; append `!` to refresh local cache
      " :PluginClean      - confirms removal of unused plugins; append `!` to auto-approve removal
      "
      " see :h vundle for more details or wiki for FAQ
      " Put your non-Plugin stuff after this line
      
    3. Pangu 的使用

      :Pangu 命令

      手动执行该命令,将当前文件进行规范化。

      :PanguDisable 命令

      禁止自动规范化。

      :PanguEnable 命令

      启用自动规范化。

  • 相关阅读:
    css 计数器
    页面自动刷新的几种方式
    jq的“钉”插件--jquery.pin.js
    CSS3之Transform(变形)一
    css3之Transition(转换)
    常用css+css3集锦
    JQuery需要手动回收xmlHttpRequest对象
    javascript 闭包暴露句柄和命名冲突的解决方案
    firefox浏览器删除插件
    jQuery中的.bind()、.live()和.delegate()之间区别分析
  • 原文地址:https://www.cnblogs.com/qianggezhishen/p/7349333.html
Copyright © 2011-2022 走看看