I just downloaded Cordova for mac from https://github.com/apache/incubator-cordova-mac.
I haven't made any changes, so I just load it up in Xcode and hit run, but the first thing I would like to do is specify the window size. I'm not very conversant with xcode and can't find references to the window size, I can't find any nib files either.
How would I set the window size?
Edit I used the method described at How to set NSView size programmatically? in my contentView implementation file.
Cordova runs full screen, and depending on the size of the splash screens included in the project will scale to all respective devices.
If you want to embed Cordova in your application you have to look here: http://docs.phonegap.com/en/2.4.0/guide_cordova-webview_index.md.html#Embedding%20WebView
Related
I have a LaunchScreen.storyboard that has an Image View and will display an image whenever the app is launched. However, I have a different launch image for each Scheme that I define in the project. I have defined a user-defined setting that holds a different image asset for every scheme. My question is, how do I make use of this setting in the storyboard?
I've also been looking for this feature for a long time but I don't think Asset Catalog supports it. Out of the box, Asset Catalog only supports changing the App Icon and Launch Images (not Launch Storyboard) based on build configuration. See attached:
I am working with the apple watch and I would like to just simply set an image in the storyboard. It is a png file and I set it in the storyboard, but it doesn't show up in the simulator. I have tried all of the aspect and fitting options. I believe the view is called a wkinterfaceimage. I have also tried adding programmatically and that does not show up either. Hidden is not checked. Any ideas of what I might be missing?
If you have your image included as a file in your app's bundle select the file, choose File Inspector and add the target under Target Membership:
I've tried that several times, and it seems there is some bug with that (Xcode 4.3.3 - OS X 10.7) :
Put an NSButton in Interface Builder
Set it to 'Image Only'
Drag'n'drop a system icon (e.g. NSAddTemplate)
But the icon fails to show (while I'm perfectly able to see icons when they're not system icons, but added by me).
Any ideas?
I've just tried, it works in a weird way.
Try to set image and alternate in the NSButton inspector.
Pick the images from the drop-down menu directly instead of drag-dropping it.
It works but it's just a workaround...
Alternate answer: Make sure the image files are included in the Copy Bundle Resources phase for your target (especially if you have multiple targets in your Xcode project). There is no build-time error or warning if you specify an image that is not in your bundle. (There is a runtime warning).
Small problem here, I'm building an app for ios, and I've added and icon to my project 57x57, and 114x114, but when I run my app on the device, icon is very dim, when original is very bright. How can I fix it? Does it matter if I build my app in debug mode or release?
iOS adds a gloss/shine effect to your app icon that can sometimes reduce the saturation of your image. Add the UIPrerenderedIcon flag to your info.plist file as described here to disable this.
EDITED to add iOS5 details
On iOS 5 there is a new key for specifying icons: CFBundleIcons is the raw name and it displays as 'Icon files (iOS5)' in the plist editor. To turn off the icon shine effect on iOS 5 devices you need to set the UIPrerenderedIcon flag on the Primary Icon as shown below.
To cover all cases (iOS3 - iOS5) you need to specify UIPrerenderedIcon in both places.
This is probably due to physical differences between your desktop monitor and iOS screen. Only thing you can do is redesign the icon and check the colors on an iOS device.
Check the brightness setting of your device's display. Perhaps it's not "up" as much as you think.
Or, you can disable the "shine" effect that iOS applies to your icon by adding the "Icon already includes gloss effects" boolean to your Info.plist file. That might help.
I have the latest Ipad compatible Monotouch library. I have upgraded my projects to use 3.2 SDK and MonoTouch 1.9 Alpha.
The docs say you need to change the Window in your XIB for the large iPad Window. I don't use XIB. I build my interface from code by constructing the object programatically. What should I be doing to get the large iPad style Window?
Nothing (I assume).
[UIScreen mainScreen].bounds (and its equivalent on MonoTouch) will be 768x1024 in iPad mode and 320x480 in iPhone mode. If your windows and views do not have any hard-coded values they should adopt to the new size naturally.
After further investigation, I found that I needed to add an entry into the info.plist file like so:
Information Property List
UIDeviceFamily
item 0 2
Once this is present the dynamic Window class that I create is the full iPad screen size.
I think it is basically telling the system that my app supports that device. Will have to find our more in the docs.