何以解憂?唯有Java

          其實(shí)程序員也懂得浪漫!
          posts - 90, comments - 637, trackbacks - 0, articles - 2
            BlogJava :: 首頁 :: 新隨筆 :: 聯(lián)系 :: 聚合  :: 管理

          nbPython 的代碼提示功能!

          Posted on 2008-11-15 09:43 guanminglin@gmail.com 閱讀(32239) 評論(2)  編輯  收藏 所屬分類: NetBeans
          Here are some screenshots of the code completion working for Python.
          First, let's try it from an import statement:







          Note that the documentation for the module is shown. Next, let's
          try completing on imported symbols - again we've got the documentation:







          I'm writing a unit test, extending TestCase. Now let's try overriding
          some methods - completion after typing def:







          Obviously, invoking methods on self. will show the inherited
          methods - and their documentation:







          Here's completion in my function (not on self) showing
          the local variables, imported symbols and builtins. Notice that deprecated
          methods are marked with strikethrough (and deprecated modules are in imports
          as well, though I didn't show that above).







          Notice also that the documentation here looks better - it has links,
          colors, etc. This is because NetBeans supports the reStructuredText
          Docstring Format (see PEP 287).
          System libraries are being documented in this way now, so more of the
          documentation will start looking like this.



          When NetBeans finds embedded code, it will also syntax highlight the
          code fragments in the documentation:







          You can use this in your own documentation as well obviously.
          Here's a file where I have restructured text. As I'm writing it,
          I can -immediately- preview the text myself by just pressing
          Ctrl-Shift-Space (Show Documentation - for those who don't know, you
          can do this on regular code as well if you want to just get the documentation
          for the code at the caret, rather than completion alternatives up to
          the caret prefix.)







          Here's a final example - completion after raise (or
          exception) will show completion for all Error
          classes:






          I'll be quiet or about a week now -- I'm going on vacation! Not great
          timing given the release date, but this has been planned since February...

          評論

          # re: nbPython 的代碼提示功能!  回復(fù)  更多評論   

          2008-12-05 10:46 by S
          不能順便給翻譯了^-^

          # re: nbPython 的代碼提示功能!  回復(fù)  更多評論   

          2009-06-21 00:12 by esog
          站長收錄查詢:http://www.ngiv.cn
          主站蜘蛛池模板: 大新县| 秀山| 清河县| 郎溪县| 东阳市| 林周县| 蓬莱市| 张家界市| 靖宇县| 锡林郭勒盟| 盐城市| 永嘉县| 宁安市| 杭州市| 牙克石市| 虞城县| 宁国市| 溧水县| 台南县| 怀仁县| 陇南市| 蓬安县| 长泰县| 阿图什市| 澜沧| 西林县| 商都县| 博罗县| 浮山县| 田阳县| 元朗区| 福州市| 威远县| 桦川县| 襄樊市| 宜良县| 娄烦县| 壶关县| 翁牛特旗| 浙江省| 锡林郭勒盟|