GithubHelp home page GithubHelp logo

xcode-snippets / objective-c Goto Github PK

View Code? Open in Web Editor NEW
3.5K 3.5K 641.0 458 KB

A few code snippets from my Xcode arsenal

Home Page: http://nshipster.com/xcode-snippets/

Objective-C 88.85% Mercury 11.15%

objective-c's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

objective-c's Issues

Add Fake Book "recipes" in here?

I just got the "Fake Book" today by e-mail after pre-ordering your upcoming book.

I wondered if it would be possible to add all of those recipes as snippets to be easily used within Xcode?

I don't think it would be hard for me to write down some code that'll do it automatically from your PDF/HTML (if available) , but the question is more legally-speaking.

Thank you and keep up your inspiring work.
Shai.

Add Code Snippet plist files for easier syncing

User defined Code Snippets are found in ~/Library/Developer/Xcode/UserData/CodeSnippets and are saved individually as their own plist file. It would be awesome if these files were stored in the repo and users would be able to drag them to their UserData directory rather than recreate each one. ๐Ÿค˜

Incorrect handling of NSFetchedResultsChangeUpdate in fetched results controller delegate

Just noticed this repo (and the fetched results controller delegate). I'm not interested in fixing it, but I noticed this bug so I will share.

See this article from Apple on NSFetchedResultsChangeUpdate https://developer.apple.com/library/ios/releasenotes/iPhone/NSFetchedResultsChangeMoveReportedAsNSFetchedResultsChangeUpdate/ which describes it in more detail.

Since we use begin and end updates. If cells have been re-ordered, the cell's wont actually be re-ordered until end updates happens. But if we have a NSFetchedResultsChangeUpdate, we will reconfigure the cell at the index path. If a cell before it has been removed/inserted, this indexpath will reference a different cell until end updates has been called. -- kylef-archive/KFData#24 / kylef-archive/KFData@2d5f2d4

Multiple substitution

Great project! In Xcode 3 it had been possible to replace multiple placeholders with the same name, this looked like an 'Edit all in Scope'. Did you find out how to do this in Xcode 4? Would be great for the kvo sample.

a codesnippet file will be much better.

Put the *.codesnippet in ~/Library/Developer/Xcode/UserData/CodeSnippets.

But the .codesnippet is a plist-like file. Can you convert them?

the following is the format:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
    <key>IDECodeSnippetCompletionPrefix</key>
    <string>aaa</string>
    <key>IDECodeSnippetCompletionScopes</key>
    <array>
        <string>ClassInterfaceMethods</string>
    </array>
    <key>IDECodeSnippetContents</key>
    <string>@property (nonatomic, assign) &lt;#type#&gt; &lt;#name#&gt;</string>
    <key>IDECodeSnippetIdentifier</key>
    <string>7707FE2A-C6CF-4774-8A7D-EA6BEE058C11</string>
    <key>IDECodeSnippetLanguage</key>
    <string>Xcode.SourceCodeLanguage.Objective-C-Plus-Plus</string>
    <key>IDECodeSnippetTitle</key>
    <string>ELC property declaration - assign</string>
    <key>IDECodeSnippetUserSnippet</key>
    <true/>
    <key>IDECodeSnippetVersion</key>
    <integer>2</integer>
</dict>
</plist>

 2012-12-16 5 54 48

Xcode Crash

When install these snippets,Xcode can't input any word.It will crash! I don't know whether reason is new version for 8.0!

block implied return type?

i can't tell if that's just a placeholder line or if this is some seriously fancy stuff... if it's the latter, i'm trying to research what's happening here yet it's a little hard to describe so if you could point me in the right direction...

is line 10 actually return'ing frame as the result of this block? @mattt is this in your book at all? you cover some awesomely obscure concepts in there yet i have trouble simply finding the time to sit and open a book haha.

https://github.com/mattt/Xcode-Snippets/blob/master/frame.m#L10

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.