When adding an image to SLComposeViewController, the image is shown to the right in the SLComposeViewController view. However it's shown below (as in layer below) another default image looking like a compass. On top of that is a clip. What is this compass image? I'd like to show the attached image on top. Would be nice instead of that grey thing.
The attached image is the white image below the compass.
I think I got it.
The compass means you also attached a URL to the social posting.
The order of the image and the compass is determined by the way you add that stuff to the SLComposeViewController itself. I was adding the URL first, then the image. Just change the order, and the things clipped to the posting will also change order. The first added item will show on top as it seems.
This is also true for TWTweetComposeViewController in iOS 5.
It seems the above works for Twitter. Facebook never shows any attached image...?
Edit: As for Facebook - As the Safari icon means "URL", I was able to show a thumbnail of the attached image by removing addURL: alltogether. It's weird. If you don't add a URL, you have the thumbnail of the image. You can even change the album # Facebook in which the image will be posted. If you add a URL, you ONLY get that Safari icon. Weird.
Related
I am developing an app that has an internal gallery with some images.
What I want to achieve is exactly a result that behaves and looks like the Apple Photo app image viewer.
With a collection view I implemented the gallery images with thumbnails and now I would like to show the image on fullscreen on press.
The image viewer should have exactly the Apple's Photo behavior:
Full screen on single tap,
Delete, Share button etc...
Pinch to zoom, double tap zoom...
My question is. Is that really possible that such a common feature is not already given by iOS? Is there maybe a view controller already build in that we can use but I am not aware of?
I know there are some libraries around that make such thing, but I'm wondering if there's already something given.
Currently the markers on my Google Maps Map view appear to look like the first picture I uploaded, however I need to find a way to add a thumbnail in the center of the image similar to the second view, I am unsure of how to do this as the thumbnail is dynamic so I cannot set it to a specific image like I am doing by setting the marker.icon to the icons bubble image. Has anybody attempted anything like this before? The thumbnails are being retrieved from a Parse server so I cannot prepare this ahead of time with code.
I had a similar problem in a project a while back. What I did to solve it, was in the javascript I started by making all the markers set to be hidden initially. As I added each one I added an eventListener to the src of the icon image so that when it loaded I could switch the marker on with setAnimation("BOUNCE") to make it look intentional. That's the idea and it worked for me. Let me know if you run into any bumps.
My problem is that I want to show a gif in the UIImageView while downloading a picture from remote server. After I downloaded the picture from remote server, I want this downloaded picture to be shown on the screen.
Without problem, I achieved showing the downloaded picture on the screen, which is not difficult of course. However, I could not achieve displaying a custom preinstalled gif in my local while trying to download that picture. Default ActivityIndicator icon appears while downloading.
I did try a few things but I still could not make it. Is there any suggestion for that ?
I put some pictures:
Before I began to download: UImageView with white background color
After I started to download image for UImageView: default activity indicator
Downloaded image: Which I wanted so.
I just want to replace second picture: Activity indicator with my gif. I hope I am understood.
You cannot play a gif format file in a UIImageView. If you have an array of images, you can ainmate them in the imageView and it will be just like a gif.You can also repeat the animation if you want to.
You need to add UIImage+animatedGIF category to support gif in imageView.
If you want to play gifs from the url, you can consider the webView instead of imageView.
There is no built-in support for animated GIFs in iOS. I found a third-party framework that lets you display animated GIFs. I'm not at my Mac right now so I don't have the info, but it looks like there are quite a few libraries that offer animated GIF support on Github.
As Mr. T. says you can also use an array of images in UIImageView to get the same effect. (And there are tools that let you decompose an animated GIF into its frames.)
I have a simple responsive landing page that is displaying a .png image like this:
It looks like this on other devices and destop:
I tried to re-slice the image out in Photoshop, but It still displays the same way. I have no clue where to go next to try and correct this issue.
Here is the image I am currently using:
I notice that Mobile Safari's Twitter and Facebook share adds a screenshot of the current page without actually sharing it, eg:
Im trying to duplicate this via SLComposeViewController, however calling the addImage: actually adds the UIImage to the tweet/facebook album (as expected).
Is there a way to just display the screenshot of the page without adding the image ?
Edit:
Looks like SLComposeViewController conforms to UIAppearanceContainer however the UI_APPEARANCE_SELECTOR is not documented.
Safari is previewing the screenshot to the website because it has it loaded and ready in on the screen, when you addURL: on the SLComposeViewController it doesn't resolve that URL and grab a preview.
Also when you addImage: that's exactly what it's doing, it's adding an image to your post, this isn't what you want, you just want to have a visual and not a safari logo/icon in place of the attachment indicating a link.
I can only say there is a private method on the SLComposeViewController class which is how Safari is adding a preview image for URLs added...
You should always get this in your app when sharing a URL:
That sucks, you should add a feature request (http://bugreport.apple.com) so that you can add your own preview here, maybe Apple will make that public in future iOS releases.