Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Could not find or load main class me.champeau.deck2pdf.Main #33

Open
dufferzafar opened this issue Mar 17, 2016 · 4 comments
Open

Could not find or load main class me.champeau.deck2pdf.Main #33

dufferzafar opened this issue Mar 17, 2016 · 4 comments

Comments

@dufferzafar
Copy link

I've downloaded deck2pdf from bintray: https://bintray.com/artifact/download/melix/generic-maven/deck2pdf-0.3.0.zip/deck2pdf-0.3.0.zip

Here is how the folder looks:

~/.apps > tree deck2pdf                                                                                                                       06:54:57
deck2pdf
├── bin
│   ├── deck2pdf
│   └── deck2pdf.bat
└── lib
    ├── deck2pdf-0.3.0.jar
    ├── groovy-2.4.4.jar
    └── itextpdf-5.5.1.jar

2 directories, 5 files

I get the following error, on running deck2pdf --help:
Error: Could not find or load main class me.champeau.deck2pdf.Main

I'm using Kubuntu 15.10.
uname -a : Linux dufferzafar-inspiron 4.2.0-25-generic #30-Ubuntu SMP Mon Jan 18 12:31:50 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux

@sylviefiat
Copy link

I have the same issue here, could you find a solution ?

@dufferzafar
Copy link
Author

Sorry, but I didn't find any solution.

@bnouvel-wio
Copy link

I had sthe same error message.
For me the issue, was that I was needing to install javafx on my system:
apt install openjfx if you are using ubuntu.

@redsymbol
Copy link

redsymbol commented Apr 7, 2021

On MacOS (Big Sur 11.2.3), I also had experienced this issue and it was also caused by javafx being missing.

This did NOT work: brew install openjdk

Apparently that package does not include JavaFX. Instead, I had to install this different JDK implementation:

brew tap bell-sw/liberica
brew install --cask liberica-jdk15-full

Where I found this solution: https://stackoverflow.com/questions/61050869/installing-javafx-15-on-mac

There is one imperfection, in that the slide headings are now rendered with a different font which is wider and thus pushing some content down past the bottom edge of the slide. Still tracking down the root cause of that.

UPDATE: Fixing the heading font was actually pretty easy, using the "JavaFX 2.2: Explicit font loading" section in the deck2pdf README. The steps:

(To be clear, the issue I am speaking to now is that one font was being used in the HTML rendered version of the slide, and on my previous computer, that font was also being used in the PDFs rendered by deck2pdf. But after I installed javafx (via Liberica), that font was not being found by deck2pdf, for whatever reason, and it was falling back to a different font which ruined the layout.

That likely had nothing to do with this JavaFX, but posting here just in case. How I fixed the font issue:)

  1. Figure out which font is used by the HTML render, by using the browser's web inspector. In my case, it was 'PT Sans Narrow'.
  2. Find the TTF files. In my case, searching for 'google PT Sans Narrow' led me here: https://fonts.google.com/specimen/PT+Sans+Narrow
  3. Unpack into some folder, e.g. /path/to/PTSansNarrow (should include PTSansNarrow-Bold.ttf and PTSansNarrow-Regular.ttf)
  4. Ensure --fontsdir=/path/to/PTSansNarrow is passed to deck2js

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants