Giter Site home page Giter Site logo

Comments (5)

mohzy83 avatar mohzy83 commented on September 26, 2024

The PreProcessorExe and PostProcessorExe can be any commandline program.
Maybe the documention is not clear enough about that point.
Actually your configration should work when the python executable accepts the parameters in that order.

from nppmarkdownpanel.

linpengcheng avatar linpengcheng commented on September 26, 2024

Thank you for your reply and work!

According to NppMarkdownPanel.ini, it can choose a different ProcessorExe configuration based on the file extension, just like Preview HTML's Filters.ini, right?

From the default [Filter0] of NppMarkdownPanel.ini, it seems that the configuration name is a bit different.

NppMarkdownPanel.ini

; [Filter0]
; Extensions=.pl,.pm
; Program=pod2html.bat
; Arguments=--css C:\notepad++\plugins\NppMarkdownPanel\style.css

[Filter1]
Extensions=.xyz
Arguments=--css C:\notepad++\plugins\NppMarkdownPanel\style.css
PreProcessorExe=C:\python.exe
PreProcessorArguments=C:\ConvertxxxTOxxx.py %inputfile% %outputfile%
PostProcessorExe=C:\python.exe
PostProcessorArguments=C:\ConvertyyyTOyyy.py %inputfile% %outputfile%

[Filter2]
Extension=.hiccup, .hip
;Program=C:\dev\Notepad++\tools\comrak\comrak.exe
;bb.exe from  https://github.com/babashka/babashka
PreProcessorExe=C:\Notepad++\tools\clj\bb.exe
PreProcessorArguments=C:\Notepad++\tools\clj\hiccup2html.clj %inputfile% %outputfile%

hiccup2html.clj

(use 'hiccup.core)
(let [[inputfile outputfile] *command-line-args*
      f #(spit outputfile % :encoding "utf-8")]
  (->> inputfile
       slurp
       read-string
       eval
       html
       f))

test.hiccup

[:p
  [:h1 "List"]
  [:ul
    (for [x (range 1 4)]
      [:li x])]
  [:p "Hello, world!"]]

preview is wrong

[:p[:h1 "List"]  [:ul (for [x (range 1 4)] [:li x])]  [:p "Hello, world!"]]

update01:

  • hiccup2html.clj

from nppmarkdownpanel.

linpengcheng avatar linpengcheng commented on September 26, 2024

NppMarkdwonPanel and PreviewHTML both work fine under win7, but not under win11. It may be a problem with npp or OS.

Here is the configuration that works under win7:

NppMarkdownPanel.ini

[Options]
CssFileName=style.css
CssDarkModeFileName=style-dark.css
ZoomLevel=301
HtmlFileName=
ShowToolbar=True
ShowStatusbar=True
SupportedFileExt=md,mkd,mdwn,mdown,mdtxt,markdown,text,hiccup
AutoShowPanel=False
SyncViewWithCaretPosition=0
SyncWithFirstVisibleLine=0
PreProcessorExe=C:\Notepad++\tools\clj\bb.exe
PreProcessorArguments=C:\Notepad++\tools\clj\hiccup2html_mdpanel.clj %inputfile% %outputfile%

hiccup2html_mdpanel.clj

(use 'hiccup.core)

(let [[inputfile outputfile] *command-line-args*
      f #(spit outputfile % :encoding "utf-8")]
    (->> inputfile
         slurp
         read-string
         eval
         html
         f))

test.hiccup

[:p
  [:h1 "List"]
  [:ul
    (for [x (range 1 4)]
      [:li x])]
  [:p "Hello, world!"]]

npp_mdpanel

from nppmarkdownpanel.

mohzy83 avatar mohzy83 commented on September 26, 2024

I'm working with Win11 and have no problems so far.
Please specify your problem.

from nppmarkdownpanel.

linpengcheng avatar linpengcheng commented on September 26, 2024

Microsoft is phasing out IE in Windows 11, so some Windows 11 users cannot use the IE kernel-based notepad++ plugin.

from nppmarkdownpanel.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.