Skip to content
This repository has been archived by the owner on Nov 13, 2021. It is now read-only.

Composite Fonts #227

Open
d1ngd0 opened this issue Jan 10, 2019 · 7 comments
Open

Composite Fonts #227

d1ngd0 opened this issue Jan 10, 2019 · 7 comments

Comments

@d1ngd0
Copy link
Contributor

d1ngd0 commented Jan 10, 2019

currently only simple fonts are allowed, and any attempt to render using a composite font will just drop anything outside the 256 glyphs. I have been digging into Composite fonts here and have also dug into TCPDF's addTTFfont method. I was considering trying to port that method over here in the following weeks. I figured I would open a dialog with you first to see if you had any other options in mind to enable this.

@jung-kurt
Copy link
Owner

Thanks for your offer to help in fixing gopdf's most glaring limitation. I'm not too familiar with composite fonts but they appear to be a pre-Unicode attempt to deal with fonts having more than 256 glyphs. Two concerns:

  • Might it be more future-proof to implement a Unicode solution than a CID solution?
  • Using code from TCPDF would require gofpdf to give up its use of the MIT license.
    See some of my recent notes about Unicode in introduce an io.Reader-based API for MakeFont #168, in particular some thoughts about applying gofpdf's API to a PDF package that already supports Unicode.

@d1ngd0
Copy link
Contributor Author

d1ngd0 commented Jan 25, 2019

signintech/gopdf#98 I reached out to the author of gopdf so he can pull code if he wants.

I have been making some good progress, I feel like this will be a good way of moving forward. Just wanted to jump in here quick and let you know I am still working on this. I am working on Templates now. So far I have not been creating any tests, that is next on the list after templates. I can put together some kind of strategy after those are done, then maybe we can pull some other people in.

@jung-kurt
Copy link
Owner

All good! Thanks for the update.

I can put together some kind of strategy after those are done, then maybe we can pull some other people in.

Good plan.

@d1ngd0
Copy link
Contributor Author

d1ngd0 commented Jan 31, 2019

Templates are done. I will likely get a plan moving forward written up today and put it here. Then do you have any preferences on where the code should be managed? At some point I assume you will pull my branch over without merging it.

@jung-kurt
Copy link
Owner

Templates are done.

Super!

Then do you have any preferences on where the code should be managed? At some point I assume you will pull my branch over without merging it.

If the plan is to have people begin using, testing and commenting on your new work, maybe I can just add a message and link from gofpdf's landing page to your repository. This way people can get right to your latest work.

I see that the gopdf maintainer is actively merging your changes, so it looks like all pieces are in place for that project to become the defacto PDF generator for Go. When you complete a roadmap, I can put it on gofpdf's landing page to let people know about that.

@joewestcott
Copy link
Contributor

How's this project going, @d1ngd0?

@d1ngd0
Copy link
Contributor Author

d1ngd0 commented Mar 4, 2019

I've gotten pulled off this temporarily because I needed to get some other internal projects done. I believe I got most of the harder things pulled over. At this point I really need to set up a roadmap and start getting external help to finish.

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

No branches or pull requests

3 participants