Icon for Action Extension in iOS8 - ios8

I have worked on extensions and it's all very interesting. For all type of extensions, icons work really well except for Action Extension where the icon is all white? Do you know how to create an icon for Action Extension?

In the Build Phases of your Extension Settings, just add Images.xcassets (or the icon file) to the Copy Bundle Resources.
PS: For Action Icon, any color data in the image itself is ignored. via Apple Docs
The alpha channel of the image is used as a mask to generate the final
image that is presented to the user. Any color data in the image
itself is ignored.

I had to manually add my icon assets catalog in the build settings. I described it here:
To get this to work with my existing Asset Catalog, I had to add the following to the extension's Build Settings:
The name of the set in my Assets Catalog is "ExtIcon". I had tried setting the CFBundleIcon and the NSExtensionServiceToolbarIconFile keys in the info.plist for the extension, but had no luck. This actually seems to make sense since it is the same way that icon sets are linked to the container app, not via info.plist, but via the Build Settings.

Related

In a Xamarin Forms application. What's a Styles.xcassets file in the iOS project used for?

My application has one of these files but it doesn't seem to do anything and when I click on it, then it shows as empty.
That is an Asset Catalog Image Sets
Asset Catalog Image Sets - Use Asset Catalog Image Sets to manage and
group all version of a given image asset required by an app.
You can add images to your iOS solution, using Resources, or creating a Catalog Image Set.
You can read the official Apple Documentation
There is no default file called Styles.xcassets in the iOS project. And I think this is a normal Asset Catalog Image Sets file created by someone.
In an iOS project, the is a default Asset Catalog Image Sets called Assets.xcassets file and manager your image there.
Also, instead of using the Assets.xcassets, you can create more ....xcassets to manager your images. It can be more clear and is easier to distinguish different kinds of images.
For example, if there is a Styles.xcassets, you can put all images of style into this file. You can also create a Home.xcassets there to put all images in the homePage there.
Hope you understand What's a Styles.xcassets file in the iOS project used for now.

Is it possible to use custom icon for Xcode file template?

In our project we generate multiple swift files when using the file xctemplate configuration. However, with this configuration, there is no icon displayed in Xcode when generating the files (see attached image). We did try to add two images to the template folder: TemplateIcon-png and TemplateIcon#96.png which yielded no success. Is it possible to use a custom icon for file templates in Xcode?
Not sure if you're still looking for an answer to this, but you should be able to create an .icns icon package named TemplateIcon.icns. This should contain your template image(s) to be displayed in the new project picker.
I suspect your issue was trying to use the PNG assets directly.
See the Base Acceptance Testing Bundle for an example. It is part of the OCSlimProjectXcodeTemplates repository.

How to set screensaver thumbnail in Settings panel on Mac?

I'm making a custom *.saver application, and I would like to add my own thumbnail to show up above the name of screensaver (the ladybug pictures in the left column). How do I do that?
By examining the default screensavers, I figured out that you need to add two files:
thumbnail.png, 58x90px
thumbnail#2x.png, 116x180px
When compiled by Xcode, this is automatically included in the .saver Resources folder as "thumbnail.tiff" with two subfiles.

Why isn't my iOS8 Application Action Extension App Icon showing up?

My app icon is just a grey super ellipse even though I have specified a icon asset catalog in my Targets App Icons and Launch Images.
The following worked for me creating a Share Extension, but I believe Action Extension will do the same. Note that in the case of an Action extension, you need a monochromatic version.
If you are using an asset catalog for your main application icon, you should be able to get the Extension to leverage that same asset catalog. The key for me was to:
Select my extension and tell it to use Asset Catalog. Select the same catalog your main icon is using. The default should be AppIcon
Select the image.xcassets file in XCode Project Navigator
Check my extension so that it is included in the Target Membership
Your asset catalog in your main application isn't accessible from your application extension as they are two separate applications bundles that can only share Frameworks.
You will need to create a separate asset catalog in your action extensions folder and reference that one in your Targets.
EDIT: This worked for me for iphone but not for ipad simulator. Making new images (60x60 and 76x76) with only black and white solved it.
Add the image.xcassets to the extension target

Icons path altered in built editor

I've made a couple plugins for ckeditor and added icons for them. These icons show up when I embed the unbuilt code on a test page, but, when I build the editor, the minimized code thinks the icons at 'original/path/to/the/icon.png?t=D5AK' instead of 'original/path/to/the/icon.png'. This error does not occur when I copy an icon from another plugin in the src code. At the moment the only way I am adding the icon is through "icon: this.path + 'icons/icon.png'," in plugin.js. Is there somewhere I need to add a reference to the icon?
This is an intentional addition to resources' paths. It ensures that every two CKEditor releases have different paths to the same resource what disables cache. And this works perfectly unless you're trying to load CKEditor from local file system than from a web server.

Resources