自定义键盘:如何将图像从粘贴板粘贴到messages.app MMS ios8(Custom Keyboard: How to Paste Image from pasteboard into mes

编程入门 行业动态 更新时间:2024-10-27 12:31:34
自定义键盘:如何将图像从粘贴板粘贴到messages.app MMS ios8(Custom Keyboard: How to Paste Image from pasteboard into messages.app MMS ios8)

适用于iOS 8的自定义键盘。

在Swift中创建了键盘Target。 在设备上运行良好。

我将图像复制到粘贴板,如下所示:

let image = UIImage(named: "myImage.png") UIPasteboard.generalPasteboard().image = image;

我已通过手动粘贴到活动文本消息中验证图像确实已复制到粘贴板中。

但我想以编程方式将该图像粘贴到messages.app(MMS)中的用户活动消息中。

Custom Keyboard for iOS 8.

Created the keyboard Target in Swift. Runs fine on device.

I copy an image to the Pasteboard like this:

let image = UIImage(named: "myImage.png") UIPasteboard.generalPasteboard().image = image;

I have verified that image is indeed copied into pasteboard by manual paste into the active text message.

But I want to programmatically paste that image into a user's active message in messages.app (in MMS).

最满意答案

我此刻没有尝试创建自己的键盘。

不过我在iPhone上使用了两个包含图像的键盘。 他们都要求用户将图像复制并粘贴到消息中。

我可能错了,但我想这是一个实际的限制。

编辑:

我找不到该限制的文档。 但是,这里是PopKey键盘FAQ的捕获:

PopKey限制常见问题解答

I haven't tried to create my own keyboard at the moment.

Nevertheless I use two keyboard on my iPhone that includes images. Both of them ask the user to copy & paste the images into the message.

I might be wrong, but I guess this is an actual restriction.

Edit :

I can't find the documentation for that restriction. However, here is a capture of PopKey Keyboard FAQ :

PopKey Restriction FAQ

更多推荐

本文发布于:2023-07-22 02:15:00,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1216021.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:自定义   如何将   图像   键盘   粘贴板

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!