Change the icon in a (appcelerator titanium) desktop app - appcelerator

If I change the default default_app_logo.png with mine, i get: Packaging failed with message: 'NoneType' object has no attribute 'rfind'
I am doing a desktop app. What I can do?
I tried all of kinds of PNG formats...
I am doing the package on windows platform.

I was having this exact same problem, which only occurs when trying to package the mac version. I was using a custom icon also.
Like you I replaced the default_app_logo.png with mine, and there lies the problem. For some reason, Titanium does not like the PNG format I gave this image.
So what I did is open the default_app_logo.png in GIMP, open my icon in GIMP, copy my icon to the default logo image in a new layer, hide the original image layer (the background) and hit save.
And after this manipulation, packaging for Mac works perfectly. I have no idea in whoch way the two differ, because they have exactly the same size, but the fact is that one gives the error and the other doesn't...

Related

No option for Landscape in iPhone Launch Images

Is landscape splash screen supported in iPhone? I don't see the option like I do with iPad, as such:
That's Visual Studio?
Because I am able to see the iPhone Landscape option in Xamarin Studio.
Try switching on and off the "Assets Catalog" dropdown to see if that helps.
Also if that doesn't work you could change at anytime from Launch image to Launch screen and there you can configure your Storyboard for all different sizes and orientations.
Note: will check later in VS.
You could add them to your assets. I don't think image assets are rendered properly in VS. It doesn't show specialized image for iPhone, iPad, watch etc. Only the generic one.
Another thing you might want to consider is using launch story board and not launch images. That's the new way of doing it or the suggested way by Apple. You have far more control on it.
Customizing launch images - Manual approach
Open LaunchImage.launchimage and change the default launch images with your own using the proper resolution for each image (e.g., Default-568h#2x.png should be 640px x 1136px). If your images have different file names then open Contents.json and change the key filename for each image.
Xcode WYSIWYG approach
Drag and drop your Assets.xcassets into Xcode (7.1 or newer version). In the opened window choose LaunchImage and add the proper image for each iOS version and device. Close Xcode and rebuild your Xamarin app to use the new launch images.
Further info : Human guidelines reference

Xamarin - how to center a launch screen image (iOS)?

I'm using Xamarin for Visual Studio, and am getting frustrated trying to do what I would think should be a very simple thing: creating a launch (splash) screen for iOS, that has a single image that is centered on the screen (vertically and horizontally centered).
I'm creating it the recommended way, using a storyboard (other methods, like using an assets catalog, are considered deprecated as of iOS 9). In the storyboard, I have a View Controller, which contains a View, which contains an Image View. In the Properties pane, I've tried messing with the Mode (in Widget tab), and I've tried playing around with contstraints - which I think might be the key, but it is difficult to understand how it all works together.
You need to add the Splash screen in the applications properties (Launch Images). You need to create the image and upload it via that section. I couldn't find anything saying that the use of Asset catalogues are depreciated.

What is the system tray icon size for retina display?

I've created a Qt5 app using PyQt5, now I am adapting images to be compatible with Retina Display on OS X. I've creating duplicates of them with the #2x modificator, but the fact is that I've not been able to make the tray icon to look correctly, I think it is because I am using the image in the wrong size.
Does anybody have any idea?
I don't know if this works with Qt, but you can use a combined file with Xcode.
Within Terminal, you can combine both icons by executing this command:
tiffutil -cathidpicheck tray_icon.png tray_icon#2x.png -out tray_icon.tiff

How to create custom vector icons to use in Xcode application

I'm currently trying to figure out how I can make those glyph/vector icons appear like the default ones that you get with Xcode (e.g. NSActionTemplate). I researched and saw that they were saved in Illustrator to PDFs.
When I did the same trick (I managed to find the original Illustrator files for the icons by Apple) and saved it as an PDF, imported it into my project and dragged the icon onto a textured button it appeared plain black. It did however clear the white background so I thought it might be the white background that was visible in the preview that caused it to not style the button like the originals.
So basically what I'm asking is how I manage to make a icon appear like the default. I don't really wan't to make multiple files and/or code the behavior, since it should be quite easy to just drag and drop the image onto a button and apply the style itself.
-- EDIT --
OK, so I found the solution — By appending the text "Template" to the filename it will do this. But I still can't figure out why my transparent PDF - exported from Illustrator as AI and EPS - it still have a white background, which Xcode uses - so it will be a rectangular with the effect I want, instead of the circle.
Anyone that have an idea on how to remove the white background from the PDF so it will work in Xcode. It bugs me that it shows it is transparent (when seeing transparent grid in the PDF and Illustrator) and it still have a white background.
The white background in the PDF (and you should always use PDF over EPS—they "play nice" with OS X) has to do with the PDF format originally being oriented toward printed content. The white background you see in Preview and Xcode is the "page" area. Fortunately, this usually goes away / gets ignored when you load the PDF into an NSImage, as happens when you put it on a button.
If I'm understanding correctly, the problem you're having is you place a PDF with no background on a button, and in Xcode's Interface Builder it displays as if there were a background? I was able to reproduce this behavior, and I'm not sure what caused it. But I built and ran a test app with the very same Template file and errantly-displayed NIB. And in the actual, running Cocoa app, the graphic displayed correctly.
Sometimes Interface Builder just previews wrongly. I suspect the problem is merely cosmetic in preparing the interface.

#2x images do not display in XCode4 interface builder designer

I'm trying to design a xib using XCode4, but when I put down an image view that displays an #2x image xcode doesn't preview it correctly (it displays a missing image icon).
It works correctly when the app is run though.
As an example: I add a UIImageView to my view and set the image property to test.png.
In my project I add a file named test#2x.png.
In XCode 3.2 this image would have correctly displayed in IB, and the #2x version would have automatically half-sized on non-retina devices.
However in IB in XCode4 the image does not display.
Is anyone else experiencing this? If they are, it's a pretty massive issue.
Why not just add both images? AFAIK UIImage isn’t guaranteed to work like that.
I always use both sizes, having the #2x ones first, and unretining them using the free app unretiner from app store, and drop both sizes to the project. When referring to an image, instead of writing test.png or test#2x.png, I write test and xCode finds sizes to the corresponding devices, but YES! in IB, the image won't be displayed in this way, just a question marked blue screen; but that works fine when running the app.

Resources