mirror of
https://github.com/Iconica-Development/flutter_image_picker.git
synced 2025-05-18 19:53:45 +02:00
more documentation in the read me
This commit is contained in:
parent
a569e91520
commit
817854fac2
4 changed files with 19 additions and 19 deletions
24
README.md
24
README.md
|
@ -27,18 +27,18 @@ To use this package, add `flutter_image_picker` as a [dependency in your pubspec
|
||||||
See [Example Code](example/lib/main.dart) for an example on how to use this package.
|
See [Example Code](example/lib/main.dart) for an example on how to use this package.
|
||||||
|
|
||||||
You can add optional parameters to the `showImagePickerDialog(context)` function call. These are:
|
You can add optional parameters to the `showImagePickerDialog(context)` function call. These are:
|
||||||
| Parameter | Explaination |
|
| Parameter | Explaination |
|
||||||
|-------------------|---------------|
|
|-------------------|----------------|
|
||||||
| title | left-aligned |
|
| title | The title that's shown at the top of the Image Picker Dialog in the bottom of the screen |
|
||||||
| titleTextSize | centered |
|
| titleTextSize | The font size of the title mentioned above |
|
||||||
| iconSize | right-aligned |
|
| iconSize | The size of the icons that are shown in the Image Picker Dialog |
|
||||||
| iconTextSize | right-aligned |
|
| iconTextSize | The font size of the text underneath the icons in the Image Picker Dialog |
|
||||||
| spaceBetweenIcons | right-aligned |
|
| spaceBetweenIcons | The space in pixels between the two icons in the Image Picker Dialog |
|
||||||
| makePhotoText | right-aligned |
|
| makePhotoIcon | The icon that is shown as the Make Photo button |
|
||||||
| makePhotoIcon | right-aligned |
|
| makePhotoText | The text that is shown underneath the Make Photo icon in the Image Picker Dialog |
|
||||||
| selectImageText | right-aligned |
|
| selectImageIcon | The icon that is shown as the Select Image button |
|
||||||
| selectImageIcon | right-aligned |
|
| selectImageText | The text that is shown underneath the Select Image icon in the Image Picker Dialog |
|
||||||
| closeButtonText | right-aligned |
|
| closeButtonText | The text that is visible on the button that is shown at the bottom of the Image Picker Dialog that closes the dialog |
|
||||||
|
|
||||||
## Additional information
|
## Additional information
|
||||||
|
|
||||||
|
|
|
@ -13,8 +13,8 @@ class ImagePicker {
|
||||||
double spaceBetweenIcons = ImagePickerDefaultParameters.spaceBetweenIcons,
|
double spaceBetweenIcons = ImagePickerDefaultParameters.spaceBetweenIcons,
|
||||||
String makePhotoText = ImagePickerDefaultParameters.makePhotoText,
|
String makePhotoText = ImagePickerDefaultParameters.makePhotoText,
|
||||||
IconData makePhotoIcon = ImagePickerDefaultParameters.makePhotoIcon,
|
IconData makePhotoIcon = ImagePickerDefaultParameters.makePhotoIcon,
|
||||||
String selectImageText = ImagePickerDefaultParameters.selectImageText,
|
|
||||||
IconData selectImageIcon = ImagePickerDefaultParameters.selectImageIcon,
|
IconData selectImageIcon = ImagePickerDefaultParameters.selectImageIcon,
|
||||||
|
String selectImageText = ImagePickerDefaultParameters.selectImageText,
|
||||||
String closeButtonText = ImagePickerDefaultParameters.closeButtonText}) {
|
String closeButtonText = ImagePickerDefaultParameters.closeButtonText}) {
|
||||||
return ImagePickerUI().pickImageDialog(
|
return ImagePickerUI().pickImageDialog(
|
||||||
context,
|
context,
|
||||||
|
@ -23,10 +23,10 @@ class ImagePicker {
|
||||||
iconSize,
|
iconSize,
|
||||||
iconTextSize,
|
iconTextSize,
|
||||||
spaceBetweenIcons,
|
spaceBetweenIcons,
|
||||||
makePhotoText,
|
|
||||||
makePhotoIcon,
|
makePhotoIcon,
|
||||||
selectImageText,
|
makePhotoText,
|
||||||
selectImageIcon,
|
selectImageIcon,
|
||||||
|
selectImageText,
|
||||||
closeButtonText);
|
closeButtonText);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -6,9 +6,9 @@ class ImagePickerDefaultParameters {
|
||||||
static const double iconSize = 125;
|
static const double iconSize = 125;
|
||||||
static const double iconTextSize = 15;
|
static const double iconTextSize = 15;
|
||||||
static const double spaceBetweenIcons = 30;
|
static const double spaceBetweenIcons = 30;
|
||||||
static const String makePhotoText = "Take a Picture";
|
|
||||||
static const IconData makePhotoIcon = Icons.camera_alt_rounded;
|
static const IconData makePhotoIcon = Icons.camera_alt_rounded;
|
||||||
static const String selectImageText = "Select File";
|
static const String makePhotoText = "Take a Picture";
|
||||||
static const IconData selectImageIcon = Icons.image;
|
static const IconData selectImageIcon = Icons.image;
|
||||||
|
static const String selectImageText = "Select File";
|
||||||
static const String closeButtonText = "Close";
|
static const String closeButtonText = "Close";
|
||||||
}
|
}
|
||||||
|
|
|
@ -14,10 +14,10 @@ class ImagePickerUI {
|
||||||
double iconSize,
|
double iconSize,
|
||||||
double iconTextSize,
|
double iconTextSize,
|
||||||
double spaceBetweenIcons,
|
double spaceBetweenIcons,
|
||||||
String makePhotoText,
|
|
||||||
IconData makePhotoIcon,
|
IconData makePhotoIcon,
|
||||||
String selectImageText,
|
String makePhotoText,
|
||||||
IconData selectImageIcon,
|
IconData selectImageIcon,
|
||||||
|
String selectImageText,
|
||||||
String closeButtonText) async {
|
String closeButtonText) async {
|
||||||
return await showModalBottomSheet<Uint8List?>(
|
return await showModalBottomSheet<Uint8List?>(
|
||||||
context: context,
|
context: context,
|
||||||
|
|
Loading…
Reference in a new issue