Skip to content

GhostscriptSharp #1

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

Open
wants to merge 5 commits into
base: master
Choose a base branch
from
Open

GhostscriptSharp #1

wants to merge 5 commits into from

Conversation

kegluneq
Copy link

mephraim,

I used your code extensively in a project I was working on and made some feature additions along the way. I thought I'd let you know in case you wanted to include some or all of them in the main.

Bear with me here - I'm new to github and am having a bit of trouble with navigating (i.e. the three extra commits trying to clean up my README markdown syntax)

Best,

= and others added 4 commits March 15, 2011 14:47
Added GhostscriptManager to control loading & freeing the Ghostscript library
Added Examples/ directory with ported examples from original API code
@mephraim
Copy link
Owner

kegluneq,

Wow, this is a ton of work! Thanks for all of your changes! I've only had a chance to quickly look over the changes, and it looks like good stuff. You even updated the tests! That doesn't always happen :)

I haven't had a chance to check everything out, because I'm on my Mac right now and I don't have Windows installed on it. It looks like the existing API stuff works the way it always did. Is this the case? If it is, I'd love to pull the changes in, because it looks like you've added a ton extra functionality that would come in handy.

Let me know, and if the old API still works, and it won't break people's existing usage of the code, I'll definitely pull in your changes.

Thanks,

Matt

@kegluneq
Copy link
Author

mephraim,

Thanks! I'm glad you're interested in incorporating the changes! As far as the API goes, I changed the GhostscriptWrapper as little as possible - all the methods are the same except CallAPI which now uses the static methods from the API class instead of the hooks defined directly within the class. So this shouldn't cause any errors, but I've said that enough that I know it's a dumb thing to say :)

The only other changes were:

  • API
    • Moved the gsdll32 hooks into the API class
    • Added additional API hooks
  • Settings
    • Moved the Settings objects into their own folders
    • Provided a DefaultDevice and DefaultPageSize within GhostscriptSettings
    • Allowed specifying the # of rendering threads, defaulted to # of logical processors (or 1 if this throws an Exception)

Let me know if you would like any additional information.

Last, thanks for putting this code out there in the first place! I had been looking for a way to deal with converting Postscript to PDF cleanly for a while, and stumbling onto your code was a huge help in getting me where I needed to go.

Best,
-Tim

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

Successfully merging this pull request may close these issues.

2 participants