--- license: > Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. title: 图示和启动画面 toc_title: Customize icons --- # 图示和启动画面 这一节演示如何配置应用程式的图示和可选初始萤幕上的各种平台上,两者在Cordova CLI (描述在命令列介面) 中工作时或使用特定于平台 SDK 工具 (平台指南中详细说明)。 ## 在 CLI 中配置图示 当工作在 CLI 中你可以定义应用程式图示通过 `` 元素 ( `config.xml` )。如果你不指定一个图示然后使用 Apache Cordova徽标。 src: (必填) 指定的影像档,与您的专案目录的位置 平台: (可选) 目标平台 宽度: (可选) 图示的宽度 (以图元为单位) 高度: (可选) 图示的高度 (以图元为单位) 密度: (可选) android 具体,指定图示密度 下面的配置可以用于定义单个预设图示,将用于所有平台。 为每个平台还可以定义设置以适合不同的萤幕解析度图元完美图示。 亚马逊火 OS Android 系统 BlackBerry10 请参阅针对多个大小和地区设定黑莓的文档。[] HTTP://developer.blackberry.com/html5/documentation/icon_element.html 火狐浏览器作业系统 iOS Tizen Windows Phone8 Windows8 ## 在 CLI 中配置初始萤幕 在顶级 `config.xml` 档 (不是在一个 `platforms` ),添加像那些在此指定的配置元素。 # 配置示例 请注意"src"属性的值是相对于专案目录而不是 www 目录。 你可以命名源映射任何你喜欢的。 在应用程式中的内部名称取决于Cordova。 # 支援的平台 到目前为止 (Cordova 3.5.0 7 月 2014年) 以下平台支援的闪屏。 android ios wp8 windows8 blackberry10 # 闪屏外挂程式 Apache Cordova还提供特殊飞溅萤幕外挂程式,它可以用来以程式设计方式显示和隐藏在应用程式启动 HTTPs://github.com/apache/cordova-plugin-splashscreen 期间的初始萤幕