Giter Club home page Giter Club logo

Comments (12)

CDSoft avatar CDSoft commented on September 17, 2024 1

EPS can be converted to PNG with imagemagick (which pp already uses for Asymptote images).
It reminds me that I forgot to add imagemagick (convert) to the prerequisite list.

from pp.

CDSoft avatar CDSoft commented on September 17, 2024

Interesting idea. I'm quite busy now but I'll try to integrate it.

If I have understood correctly, PlantUML is integrated into PP even though is in Java (I've notice reference to .stack-work/PlantumlJar_c.c in the pp.cabal source file). Is it done via a C wrapper, or is it a different PlantUML binary version altogether?

plantuml.jar is in the pp executable. It's just a binary blob copied to /tmp and called as an external command. No clever C wrapper ;-)

Ideally, it would great if there was an Haskell library (or some bindable binary) that could be integrated directly in PP, without requiring external dependencies (or installing languages).

There is a Haskell package that generates syntax diagrams: https://hackage.haskell.org/package/Ebnf2ps-1.0.11 (https://github.com/FranklinChen/Ebnf2ps/blob/master/doc/doc.pdf)

from pp.

tajmone avatar tajmone commented on September 17, 2024

I'm looking at Ebnf2ps, very interesting and well documented. Pity that it only outputs EPS and FIG format images — these are both excellent formats for TeX/LaTeX documents, but for HTML-based docs formats like SVG, PNG and GIF would be more indicated.

from pp.

tajmone avatar tajmone commented on September 17, 2024

Great choice!

I love ImageMagick and always have it up-to-date on my system via the Chocholatey package.

Chances are that anyone working with big PP/pandoc projects will also have ImageMagick on the system, or will be more than happy to install it.

from pp.

CDSoft avatar CDSoft commented on September 17, 2024

I have some trouble to integrate Ebnf2ps to pp and it has some font dependencies that make it not so portable. I think with have to find a different syntax diagram generator.

from pp.

tajmone avatar tajmone commented on September 17, 2024

What about the originally proposed RRDiagram (Java)?

from pp.

CDSoft avatar CDSoft commented on September 17, 2024

I don't find any binary jar file usable on the command line. It seems to be a Java library. Generating diagrams would require to write a java program and run it.

from pp.

tajmone avatar tajmone commented on September 17, 2024

I carried out some more searches, but haven't found any other binary CLI tools, just GUI tools or scripts.

This seems to leave only the tabatkins' railroad-diagrams, which is avialbe as Node.js or Python, but this hasn't got a CLI interface either. Also, it's probably better to leave interfacing with Node.js and Python to end users, as these libs and languages might evolve fast in backward incompatible manners, and introduce a burder in the maintainance of PP.

I'll be further looking around for some CLI binary solutions, and if I find anything I'll update this thread.

from pp.

CDSoft avatar CDSoft commented on September 17, 2024

What do you think about blockdiag to draw railroad like diagrams?
see issue #68.

from pp.

tajmone avatar tajmone commented on September 17, 2024

I've looked at it but it doesn't seem to support railroad diagrams natively.

Did you have in mind to leverage this tool but using some PP-native Haskell code to make the railroad diagrams?

from pp.

CDSoft avatar CDSoft commented on September 17, 2024

from pp.

tajmone avatar tajmone commented on September 17, 2024

Sadly I have nothing in mind (and no time as well currently).

I'm confident that in the future, at some point, a dedicated railroad diagrams library will appear that could be used natively by PP. Maybe is worth waiting for the right tool, after all it's not an essential feature — although a highly desirable one.

For the time being, shell script interfacing to locally installed tools might fill the gap, and if in the future this feature becomes implemented natively it's always possible to switch to it; on the other hand, switching a native implemented tools would be problematic for backward compatibility.

So, unless adding support for blockdiag would bring other benefits too, independently of railroad diagrams, we could just wait and keep an eye open for new tools.

What do you think?

from pp.

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.