Specify what image formats are supported in the API docs. (#13717)

Depends on https://github.com/flutter/engine/pull/4483
This commit is contained in:
Ian Hickson 2018-01-17 17:47:47 -08:00 committed by GitHub
parent 0434ae22ec
commit 521bdaea05
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 5 additions and 1 deletions

View File

@ -43,7 +43,7 @@ export 'dart:ui' show
hashList; hashList;
// Intentionally not exported: // Intentionally not exported:
// - Image, decodeImageFromDataPipe, decodeImageFromList: // - Image, instantiateImageCodec, decodeImageFromList:
// We use ui.* to make it very explicit that these are low-level image APIs. // We use ui.* to make it very explicit that these are low-level image APIs.
// Generally, higher layers provide more reasonable APIs around images. // Generally, higher layers provide more reasonable APIs around images.
// - lerpDouble: // - lerpDouble:

View File

@ -168,6 +168,8 @@ class ImageConfiguration {
/// The type argument does not have to be specified when using the type as an /// The type argument does not have to be specified when using the type as an
/// argument (where any image provider is acceptable). /// argument (where any image provider is acceptable).
/// ///
/// The following image formats are supported: {@macro flutter.dart:ui.imageFormats}
///
/// ## Sample code /// ## Sample code
/// ///
/// The following shows the code required to write a widget that fully conforms /// The following shows the code required to write a widget that fully conforms

View File

@ -92,6 +92,8 @@ Future<Null> precacheImage(ImageProvider provider, BuildContext context, { Size
/// * [new Image.file], for obtaining an image from a [File]. /// * [new Image.file], for obtaining an image from a [File].
/// * [new Image.memory], for obtaining an image from a [Uint8List]. /// * [new Image.memory], for obtaining an image from a [Uint8List].
/// ///
/// The following image formats are supported: {@macro flutter.dart:ui.imageFormats}
///
/// To automatically perform pixel-density-aware asset resolution, specify the /// To automatically perform pixel-density-aware asset resolution, specify the
/// image using an [AssetImage] and make sure that a [MaterialApp], [WidgetsApp], /// image using an [AssetImage] and make sure that a [MaterialApp], [WidgetsApp],
/// or [MediaQuery] widget exists above the [Image] widget in the widget tree. /// or [MediaQuery] widget exists above the [Image] widget in the widget tree.