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

Unify all SharpFont projects into a single Portable library. #101

Merged
merged 8 commits into from
Mar 29, 2017

Conversation

corliss
Copy link
Contributor

@corliss corliss commented Mar 21, 2017

This unifies all the projects into the existing SharpFont.Portable project, and eliminates SharpFont, SharpFont.iOS, and SharpFont.Shared.

Notes:

  1. The non-portable code in FTBitmap has been moved to an extension class FTBitmapEx in the Examples project. TODO: Perhaps this can be moved into a non-portable utility nuget if so desired.
  2. The conditional DLL name for iOS has been eliminated. TODO: This should be fixed and a single name used for all OSes. This probably means just adding a dllmap entry for iOS to SharpFont.dll.config.
  3. Calls to methods that are macOS-specific are now checked at runtime, and an exception is thrown if these are called from the wrong OS.

corliss added 4 commits March 21, 2017 21:00
…s. This checkin removes the name "__Internal" for IOS.
…roject. This results in only portable code in SharpFont. As a result, the SharpFont project is eliminated in favor of SharpFont.Portable.
@Robmaister
Copy link
Owner

This looks good except for the removal of the System.Drawing code for reasons I mentioned in Robmaister/SharpFont.HarfBuzz#9. If you look through some of the old issues you'll see several related to this one function, and I've received a few emails from people looking for help. ToGdipBitmap adds a lot of convenience and seems to be the go-to for people just starting out with the library.

On the other hand, System.Drawing is disappearing with dotnet core, might be better to push off to a separate dll for System.Drawing functionality. The iOS/macOS fixes are excellent though!

I'll mull over what I want to do with System.Drawing and get back to you shortly, and take a look at what dotnet core is looking to do with Bitmap.

@Robmaister
Copy link
Owner

Robmaister commented Mar 21, 2017

Also: my plan is to do away with the SharpFont.iOS and SharpFont.Portable nuget packages and make SharpFont the PCL version in this case, so if you could also move everything into SharpFont instead of SharpFont.Portable, that would be ideal 👍

@corliss
Copy link
Contributor Author

corliss commented Mar 21, 2017

I'll mull over what I want to do with System.Drawing and get back to you shortly, and take a look at what dotnet core is looking to do with Bitmap.

The System.Drawing code has not been expunged. Instead it has been (carefully) extracted into an extension class, FTBitmapEx, that currently lives in the Examples project. This class can be moved into a separate assembly if you wish.

Also: my plan is to do away with the SharpFont.iOS and SharpFont.Portable nuget packages and make SharpFont the PCL version in this case.

This pull request is a step in the same direction. All that is left is for the SharpFont.Portable project to be renamed SharpFont, and for the nuspec to include the PCL as well as the platform-specific native assemblies in the appropriate folders. (I'm not a nuget expert so did not attempt this.)

Cheers

@corliss
Copy link
Contributor Author

corliss commented Mar 21, 2017

if you could also move everything into SharpFont instead of SharpFont.Portable, that would be ideal

Done. [Please see my note above about FTBitmapEx, looks like you may have missed it the first time]

corliss added 2 commits March 22, 2017 13:01
…nuspec and SharpFont.iOS.nuspec.

2. Cleanup SharpFont.csproj: a) Remove SHARPFONT_PORTABLE b) Change the output path to SharpFont instead of SharpFont\Portable.
…es this project as a standard Portable Class Library and adds (Portable) to the display name in Solution Explorer.
@corliss
Copy link
Contributor Author

corliss commented Mar 28, 2017

Hi, are you planning to pull this PR? Be good to get into a regular sync schedule and pick up the pace. Let me know what works for you. Cheers,

@Robmaister
Copy link
Owner

Yup, pulling this in now and going to run through some changes in issues right now

@Robmaister Robmaister merged commit 814db86 into Robmaister:master Mar 29, 2017
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