参数名称 参数类型 描述
    range [可选]文本区域,如果不传该参数,则获取整个文档的内容

    返回值

    参数名称 参数类型 描述
    lineno Number 行号,从0开始

    返回值

    参数名称 参数类型 描述
    pos Number 光标位置

    返回值

    languageId

    • txt
    • actionscript
    • ada
    • asm
    • asp
    • autoit
    • baanc
    • bash
    • batch
    • c
    • cs
    • cmake
    • cpp
    • css
    • caml
    • cobol
    • coffeescript
    • d
    • ejs
    • fortran
    • fortran77
    • html
    • html_es6
    • handlebars
    • haskell
    • inno
    • json
    • json_tm
    • java
    • javascript
    • javascriptreact
    • javascript_es6
    • kix
    • less
    • lisp
    • lua
    • markdown
    • matlab
    • njs
    • nml
    • nsis
    • nss
    • objc
    • php
    • perl
    • postscript
    • powershell
    • python
    • r
    • rc
    • ruby
    • sql
    • sass
    • scheme
    • scss
    • smalltalk
    • stylus
    • swift
    • tcl
    • typescript
    • typescriptreact
    • ux
    • vb
    • vhdl
    • verilog
    • vue
    • wxml
    • xml
    • yaml
    • pug