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

Separate UIView (SMFrameAdditions) Category Into it's Own Header and Implementation Files #26

Closed
JRG-Developer opened this issue Jan 25, 2013 · 6 comments

Comments

@JRG-Developer
Copy link

I just found this repo, and I've gotta say, "This is really great stuff!"

Regarding the "custom_drawn_bg" branch, perhaps it would be better to separate the "UIView (SMFrameAdditions)" category into its own header and implementation files?

That is, this category is pretty useful on its own even!

This also has the benefit that doing such would allow the "UIView+SMFrameAdditions.h" to be added to a project's precompiled header, .pch, file, which would ensure that Xcode sees it in all classes as you're working within the IDE... as the existence of the category's implementation actually affects all classes importing the UIView class already anyways.

@nfarina
Copy link
Owner

nfarina commented Jan 25, 2013

Thanks for the kudos :) Glad you're finding the class useful!

So I definitely considered separating the FrameAdditions class out into its own file, and I think it's more natural that way especially if you want to use these category methods yourself outside the callout view implementation.

However I believe the class is easier for folks to consume as a single .h/.m pair and I think it's worth it to combine everything together for that reason alone.

You could certainly lift the @interface portion of FrameAdditions into a separate UIView+SMFrameAdditions.h on your own and that would work fine. It's not ideal though I admit.

@JRG-Developer
Copy link
Author

Thanks for the reply, Nick! I thought I'd just add my suggestion/feedback in the mix. You're right, though, users can certainly choose to fork the repository and make whatever changes they'd like, which works well enough for me.

I'm closing this issue as it sounds like it has already been thoroughly considered.

Thanks!
Joshua

@exalted
Copy link

exalted commented Jan 31, 2013

I won't argue if callout view class files are easier to import if SMFrameAdditions is embedded, that's fair enough; yet I believe UIView+SMFrameAdditions deserve to have its own repo for anything else. Please reopen this issue and create a separate repository just for sake of framing–math–gods and let us know when you're done.

RSVP

P.S.: I am tempted to create my own, but I don't mean to get any credits for that.

@nfarina
Copy link
Owner

nfarina commented Jan 31, 2013

Ha, well I didn't think it was worth a whole repo but I did make a Gist for it originally:

https://gist.github.com/3412730

@exalted
Copy link

exalted commented Jan 31, 2013

Can we add gist as a submodule in git? Weird?!

@nfarina
Copy link
Owner

nfarina commented Jan 31, 2013

I don't see why it wouldn't be possible—they're just repositories like anything else?

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

3 participants