热门标签 | HotTags
当前位置:  开发笔记 > 编程语言 > 正文

阿里图标库图标大小_适用于所有设备和大小的所有图标

阿里图标库图标大小Asitedoesntseemcompletewithouthavingafavicon.Forsomereason,Iwillusuallyimmediatel

阿里图标库图标大小

A site doesn't seem complete without having a favicon. For some reason, I will usually immediately notice when a site doesn't have one. It leaves me questioning the legitimacy or quality of the site over something that's so seemingly irrelevant.

如果没有网站图标,网站似乎并不完整。 出于某种原因,当一个站点没有站点时,我通常会立即注意到。 这让我对似乎无关紧要的东西质疑网站的合法性或质量。

Favicons have evolved beyond being a simple bookmark "favorite icon" though. They're even more relevant now with responsive design and mobile devices. A user can now "pin" any website or webapp to their home screen (or desktop) to give them the feeling of a quick-access native application. With Windows 8, Microsoft has even gone so far as to let any old website or application even send notifications to the favicon ("tile" in this case).

Favicon的发展已不仅仅是一个简单的书签“收藏夹图标”。 它们现在与响应式设计和移动设备更加相关。 用户现在可以将任何网站或Web应用程序“固定”在其主屏幕(或桌面)上,从而给他们带来快速访问本机应用程序的感觉。 使用Windows 8,Microsoft甚至可以让任何旧网站或应用程序甚至将通知发送到该图标 (在这种情况下为“ tile”)。

我的想法 (My Thoughts)

I think it's definitely worth setting up favicons for as many different devices as possible. You never know who will want to pin or favorite the site on whatever device they have. That extra bit of effort can go a long way, as with many things in development. The problem is the standard for favicons is terrible right now. Between all the different devices, operating systems, browsers, and screen resolutions out there, to support everyone is a huge pain and it pollutes the head of your HTML document with numerous lines of link tags. To be perfect every single time requires lots of research and testing.

我认为绝对值得为尽可能多的不同设备设置图标。 您永远不会知道谁愿意在他们拥有的任何设备上固定或收藏该网站。 与开发中的许多事情一样,这种额外的努力可能会走很长一段路。 问题是网站图标的标准现在很糟糕 。 在所有不同的设备,操作系统,浏览器和屏幕分辨率之间,要为所有人提供支持是一个巨大的痛苦,并且它会用许多行link标签污染HTML文档的head 。 每次都要做到完美,需要大量的研究和测试。

I like the concept of an .ico file supporting multiple sizes in a single file, but what I really want is vector support for favicons (like an SVG image). This way I could do it once and know I'm supporting everyone's needs, but that will probably never happen.

我喜欢在单个文件中支持多种大小的.ico文件的概念,但我真正想要的是对图标图标(如SVG图像)的矢量支持。 这样,我就可以做到一次,并且知道我在满足每个人的需求,但这可能永远不会发生。

Note: It's probably worth saying that favicon images need to be custom tailored in some cases. For example, you may want a different image depending on the size. So even if a vector image was possible, it may not be ideal.注意:值得一提的是,在某些情况下需要自定义定制图标图像。 例如,您可能需要不同的图像,具体取决于尺寸。 因此,即使可以使用矢量图像,也可能不是理想的图像。

Below you will find my default go-to for setting up favicons. There's a ton of information on the web, and many favicon generators seem to generate different sizes to which they think the standards are. Skip to the bottom of this article if you'd like to check out those resources and references to create your own.

在下面,您将找到我的默认图标,用于设置收藏夹图标。 网络上有大量信息,许多网站图标生成器似乎会生成他们认为标准的不同大小。 如果您想查看这些资源和参考来创建自己的资源,请跳到本文的底部。

创建具有多种尺寸的.ico文件 (Creating a .ico file with multiple sizes)

If you didn't know, a .ico file can contain multiple .png or .bmp images. This is awesome because now you can support multiple sized favicons with a single file and line of code in your document's head. This is what we will be creating:

如果您不知道,.ico文件可以包含多个.png或.bmp图像。 真棒,因为现在您可以在文档的head用一个文件和一行代码来支持多个大小的图标。 这是我们将要创建的:

This single file actually has five different images. It's actually pretty easy to convert multiple .png images into a single icon file. There's probably a ton of applications you can download to do it for you, but I'll show you how to do it for free from the command line.

该单个文件实际上具有五个不同的图像。 实际上,将多个.png图像转换为单个图标文件非常容易。 您可以下载大量应用程序来为您执行此操作,但是我将向您展示如何从命令行免费进行操作。

The first thing you need to do is install ImageMagick. For Mac users who use Homebrew package manager, you can simply type this from your terminal:

您需要做的第一件事是安装ImageMagick 。 对于使用Homebrew软件包管理器的Mac用户,您只需在终端上键入以下内容:

brew install imagemagick

If you don't have Homebrew installed or that doesn't work, there's this installer. Lastly, if you're hardcore or still having trouble, try to follow these instructions.

如果您没有安装Homebrew或该软件不起作用,请使用此安装程序 。 最后,如果您是中坚分子或仍然遇到问题,请尝试按照以下说明进行操作 。

If everything was successful, you should see a huge list of instructions from the command line when you type:

如果一切成功,则在键入时,您应该从命令行中看到大量的指令列表:

convert -v

Now to convert multiple .png files into a single .ico file, just follow this format from the terminal:

现在要将多个.png文件转换为单个.ico文件,只需在终端上遵循以下格式:

convert pathtofirstfile pathtofsecondfile pathtothirdfile [...] outputname.ico

convert favicon-16.png favicon-24.png favicon-32.png favicon-48.png favicon-64.png favicon.ico

The last thing that I think is important to note is to make sure you put the newly created favicon.ico file in the root of your site, and make sure you reference it with a full absolute URL. This:

我认为需要注意的最后一件事是确保将新创建的favicon.ico文件放在网站的根目录中,并确保使用完整的绝对URL对其进行引用。 这个:

Not this:

不是这个:

And not this:

而不是这样:

For Windows users, you can install ImageMagick here. It should work in a similar way.

对于Windows用户,您可以在此处安装ImageMagick 。 它应该以类似的方式工作。

Android,iPhone和其他应用程序的图标 (Favicons for Android, iPhone and others)

Android-vs-iOS





You'll also want to add this in your document's

您还希望将其添加到文档的

Windows 8 Tile的Favicon (Favicon for Windows 8 Tile)

Microsoft-Will-Tweak-the-Windows-8-1-Start-Screen-to-Act-Like-a-Start-Menu

This is just for the most basic icon. They recently added support for even more sizes though.

这只是最基本的图标。 他们最近增加了对更多尺寸的支持。



和所有在一起 (And All Together)











其他资源和参考 (Additional Resources and References)

博客文章/用户贡献 (Blog Posts / User Contributed)

  • Favicon Cheat Sheet

    Favicon备忘单
  • Convert multiple png images into a single icon file

    将多个png图像转换为单个图标文件
  • Shortcut Icons

    快捷方式图标
  • Touch Icons

    触摸图标

文献资料 (Documentation)

  • Apple Favicon Docs

    Apple Favicon文件
  • Microsoft Tile Docs

    Microsoft Tile文档

发电机 (Generators)

  • Real Favicon Generator (excellent resource)

    真正的Favicon Generator(优秀资源)
  • Favicon Generator

    图标生成器

翻译自: https://scotch.io/tutorials/all-favicons-for-all-devices-and-sizes

阿里图标库图标大小



推荐阅读
  • FeatureRequestIsyourfeaturerequestrelatedtoaproblem?Please ... [详细]
  • 微软头条实习生分享深度学习自学指南
    本文介绍了一位微软头条实习生自学深度学习的经验分享,包括学习资源推荐、重要基础知识的学习要点等。作者强调了学好Python和数学基础的重要性,并提供了一些建议。 ... [详细]
  • imx6ull开发板驱动MT7601U无线网卡的方法和步骤详解
    本文详细介绍了在imx6ull开发板上驱动MT7601U无线网卡的方法和步骤。首先介绍了开发环境和硬件平台,然后说明了MT7601U驱动已经集成在linux内核的linux-4.x.x/drivers/net/wireless/mediatek/mt7601u文件中。接着介绍了移植mt7601u驱动的过程,包括编译内核和配置设备驱动。最后,列举了关键词和相关信息供读者参考。 ... [详细]
  • 如何用JNI技术调用Java接口以及提高Java性能的详解
    本文介绍了如何使用JNI技术调用Java接口,并详细解析了如何通过JNI技术提高Java的性能。同时还讨论了JNI调用Java的private方法、Java开发中使用JNI技术的情况以及使用Java的JNI技术调用C++时的运行效率问题。文章还介绍了JNIEnv类型的使用方法,包括创建Java对象、调用Java对象的方法、获取Java对象的属性等操作。 ... [详细]
  • 恶意软件分析的最佳编程语言及其应用
    本文介绍了学习恶意软件分析和逆向工程领域时最适合的编程语言,并重点讨论了Python的优点。Python是一种解释型、多用途的语言,具有可读性高、可快速开发、易于学习的特点。作者分享了在本地恶意软件分析中使用Python的经验,包括快速复制恶意软件组件以更好地理解其工作。此外,作者还提到了Python的跨平台优势,使得在不同操作系统上运行代码变得更加方便。 ... [详细]
  • 本文介绍了关系型数据库和NoSQL数据库的概念和特点,列举了主流的关系型数据库和NoSQL数据库,同时描述了它们在新闻、电商抢购信息和微博热点信息等场景中的应用。此外,还提供了MySQL配置文件的相关内容。 ... [详细]
  • 本文记录了作者对x265开源代码的实现与框架进行学习与探索的过程,包括x265的下载地址与参考资料,以及在Win7 32 bit PC、VS2010平台上的安装与配置步骤。 ... [详细]
  • 本文详细介绍了Android中的坐标系以及与View相关的方法。首先介绍了Android坐标系和视图坐标系的概念,并通过图示进行了解释。接着提到了View的大小可以超过手机屏幕,并且只有在手机屏幕内才能看到。最后,作者表示将在后续文章中继续探讨与View相关的内容。 ... [详细]
  • PeopleSoft安装镜像版本及导入语言包的方法
    本文介绍了PeopleSoft安装镜像的两个版本,分别是VirtualBox虚拟机版本和NativeOS版本,并详细说明了导入语言包的方法。对于Windows版本,可以通过psdmt.exe登录进入,并使用datamover脚本导入语言包。对于Linux版本,同样可以使用命令行方式执行datamover脚本导入语言包。导入语言包后,可以实现多种语言的登录。参考文献提供了相关链接以供深入了解。 ... [详细]
  • Question该提问来源于开源项目:react-native-device-info/react-native-device-info ... [详细]
  • 微信商户扫码支付 java开发 [从零开发]
    这个教程可以用作了解扫码支付的整体运行过程,已经实现了前端扫码,记录订单,回调等一套完整的微信扫码支付。相关链接:微信支 ... [详细]
  • Thisworkcameoutofthediscussioninhttps://github.com/typesafehub/config/issues/272 ... [详细]
  • AndroidJetpackNavigation基本使用本篇主要介绍一下AndroidJetpack组件Navigation导航组件的基本使用当看到Navigation单词的时候应 ... [详细]
  • 使用gitolite搭建一个私有的git服务器,来管理git仓库。有了它,就可以跟小伙伴们愉快地进行远程协作啦。今天又折腾了一遍,在这里把几个关键的步骤记下来,方便以后查阅。准备工 ... [详细]
  • 面条|发生_做到这7点,避免微服务落地失败
    篇首语:本文由编程笔记#小编为大家整理,主要介绍了做到这7点,避免微服务落地失败相关的知识,希望对你有一定的参考价值。 ... [详细]
author-avatar
低调vs完美
这个家伙很懒,什么也没留下!
PHP1.CN | 中国最专业的PHP中文社区 | DevBox开发工具箱 | json解析格式化 |PHP资讯 | PHP教程 | 数据库技术 | 服务器技术 | 前端开发技术 | PHP框架 | 开发工具 | 在线工具
Copyright © 1998 - 2020 PHP1.CN. All Rights Reserved | 京公网安备 11010802041100号 | 京ICP备19059560号-4 | PHP1.CN 第一PHP社区 版权所有