如何创建一个包含多种尺寸/图片在C#中的图标文件 [英] How to create an Icon file that contains Multiple Sizes / Images in C#

查看:185
本文介绍了如何创建一个包含多种尺寸/图片在C#中的图标文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我如何创建一个包含多种尺寸的图标文件?

How do I create an icon file that contains multiple sizes?

我知道我创建一个使用从位图图标 Icon.FromHandle()但我怎么另一个图像/尺寸添加到该图标?

I know that I create a icon from a bitmap using Icon.FromHandle() but how do I add another image / size to that icon?

编辑:我需要做这在我的应用程序,所以我不能执行外部应用程序做结合

I need to do this in my application, so I cannot execute an external application to do the combining.

推荐答案

快速CYA:我只是做了谷歌搜索,并没有测试过下面的方法。情况因人而异。

Quick CYA: I just did a Google search, and have not tested the method below. YMMV.

我发现这篇文章,其中提到的一类做这个(尽管在VB.Net,但很容易的翻译),并告诉他如何使用它。虽然页面不再出现线程点,使源$ C ​​$ C提到的,我没有找到一个版本,它的<一个href=\"http://www.vbaccelerator.com/home/net/Utilities/Icon_Extractor/IconExplorer_zip_IconEx%5CIconEx_cs.asp\"相对=nofollow>这里

I found this article, which mentions a class that does this (albeit in VB.Net, but easy enough to translate), and tells how he used it. While the page that the thread points to no longer appears to have the source code mentioned, I did find a version of it here.

这篇关于如何创建一个包含多种尺寸/图片在C#中的图标文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆