Community
    • 登入

    The best way to boycott NP++ is to use another better Text Editor: CudaText

    已排程 已置頂 已鎖定 已移動 Boycott Notepad++
    21 貼文 6 Posters 9.6k 瀏覽
    正在載入更多貼文
    • 從舊到新
    • 從新到舊
    • 最多點贊
    回覆
    • 在新貼文中回覆
    登入後回覆
    此主題已被刪除。只有擁有主題管理權限的使用者可以查看。
    • hycmosH
      hycmos
      最後由 編輯

      well, It seems I can post again.
      Thank the freedom.

      So Now, I show you a wonderful function in CudaText.
      after study CudaText some days, I write my first plugin for the Cudatext.

      [Share My Idea] Plugin to get alt+C function same as NP++:
      function: column mode to insert increasing leading number at everyline (Same as Notepad++)

      1. you can find menu Plugins–> Make Plugin
      2. Click it
      3. Plugname=MyaltC,module name=MyaltC,items=MyaltC>run
      4. Click “OK”
      5. At line 27, find “def run(self)”
      6. replace all of def run(self) with:
      def run(self):
                cnt = ed.get_carets()
                altCnum=dlg_input_ex(4, 'Number be inserted',
                      'start'   , text1="0", label2="Step by", text2="1",
                      label3="Leading Char", text3="",label4="Following Char", text4="")
                if altCnum==None:return()
                i=0
                for a_cnt in cnt:
                    altCtxt=int(altCnum[0])+i*int(altCnum[1])
                    altCtxt=altCnum[2]+str(altCtxt)+altCnum[3]
                    a_caret=a_cnt[0]
                    if a_cnt[0]>a_cnt[2]:
                        a_caret=a_cnt[2]
                    ed.insert(a_caret, a_cnt[1], altCtxt)
                    i=i+1
      

      only 15 lines!!!
      could not believe!!!

      1. Now restart CudaText. you can find new menu in “Plugins–>MyaltC”, even you can assign a hotkey ‘alt+C’ to this.
      2. get the Alt-C function same as many editor :D :D
        Thank too the Cudatext’s power python API,
        this function is more powerful than NP++'s Alt+C. This can add the following char.

      It is so easy to implement this function in Cudatext. more powerful! So easy!
      ByNP1.png

      1 條回覆 最後回覆 回覆 引用 0
      • 第一個貼文
        最後的貼文
      The Community of users of the Notepad++ text editor.
      Powered by NodeBB | Contributors