Flutter: adding a gradient to my progress bar - flutter

Let me first say I started with flutter last week so I apologise in advance for my lack of knowledge.
I'm using a progress bar in my application:
FAProgressBar(
size: 50,
currentValue: dailyProgress,
direction: Axis.vertical,
verticalDirection: VerticalDirection.up,
progressColor: Colors.amber,
backgroundColor: Colors.grey[300],
animatedDuration: const Duration(milliseconds: 2000),
),
In reality it looks like this: https://imgur.com/NZUoZtW
I want it to look like this: https://imgur.com/gFCqfzR
How would you recommend me to proceed? It seems impossible to replace the progressColor property with a gradient. Is there another package I can use? Any suggestion is appreciated.

I suggest you try Gradient Widgets package for Flutter.
It has GradientProgressIndicator which should fit your needs.

Related

what will do after icon broke suddenly in appbar?

I am developing a flutter app where appbar icon broke suddenly without any reason. Try to fix but nothing has been found yet.
enter image description here
AppBar(
actions: [
GestureDetector(
onTap: () {},
child: SvgPicture.asset(
iconSearch,
color: VisuColors.white,
),
),
]
)
According to the image and code that you provide, things that come to my mind are:
1- Try to give width and height to SvgPicture.asset like this:
SvgPicture.asset(
iconSearch,
color: VisuColors.white,
width: 15,
height: 15,
),
2- Check the color that you gave to SvgPicture.asset, maybe it has something related to the color.
3- If these 2 solutions didn't solve your problem, check your SVG file and try to use another SVG file to see if the problem is with the file that you use. Because sometimes, the SVG files may be broken (size, color, formatting etc.).

how to create multiple radial bar inside each other?

I need to make a multiple radial bar inside each other. I searched but only syncfusion_flutter_charts package had some thing like that but I it needs licenses .There is no limitation on using other flutter packages.
the chart is some thing like this multiple radial bar
The best way to do this is to use a Stack widget together with Positioned Widgets. Examples with guides are found in the added links by the Flutter team itself.
What You can do is, use Stack widget to stack the Widgets and use to Wrap those widgets in Positioned widget to Passioned them the way you want inside the Stack.
Although I should mention heavy use of stack widget will have some performance impact.
using this way you can achieve it ( this is only a example , how to do it , it is not a implementation code ) ,
write code according to the use case , that is add alignment ,positioned ,etc...
stack(children: [
CircularPercentIndicator(
radius: 50.0,
circularStrokeCap: CircularStrokeCap.round,
progressColor: Colors.purple,
.....
.....
),
CircularPercentIndicator(
radius: 100.0,
circularStrokeCap: CircularStrokeCap.round,
progressColor: Colors.red,
.....
.....
),
CircularPercentIndicator(
radius: 150.0,
circularStrokeCap: CircularStrokeCap.round,
progressColor: Colors.blue,
.....
.....
),
])
actually I found the best way.CircularPercentIndicator has a center property which takes a widget. I gave it an another CircularPercentIndicator .this way worked perfect

Flutter: Remove brightness bar from flutter_colorpicker

I used the flutter_colorpicker package to implement a color picker in my app. My widget looks something like this:
ColorPicker(
pickerColor: ...,
paletteType: PaletteType.hueWheel,
onColorChanged: (color) {
...
},
enableAlpha: false,
labelTypes: const [],
)
In the UI it looks like this:
Now I want to remove the brightness bar on the bottom. I know that the color picker is not complete without that brighness bar but I will handle the brightness a different way. I have found no official documentation on how to achieve this.
How do I remove that bar? Hacks are also welcome or somehow extending the package with inheritance.
Here I attach some links which contains no brightnesss bar
Flutter Material Color Picker
Flex Color Picker
I have solved the problem by clipping away that bar using a ClipRect widget:
ClipRect(
child: Align(
alignment: Alignment.topCenter,
heightFactor: 0.75,
child: ColorPicker(
...
colorPickerWidth: 250,
),
),
);
I have not found any unwanted side effects with this approach yet.

How to override an ExpansionPanel in flutter

How the title already suggests, I want to have my own ExpansionPanel, where, contrary to the default one, the elevation is set to zero.
I already found this in flutter.dev:
https://api.flutter.dev/flutter/material/ExpansionPanelList/ExpansionPanelList.html
I have been trying to implement this but haven't succeeded yet, how do I do it?
So Im talking about these Elevation marks of each ElevationPanel:
Maybe I misunderstood you, but it is as simple as just setting the elevation parameter when you build the widget, as such:
As such:
ExpansionPanelList(
elevation: 0,
children: [ ... ],
)
Edit:
After comments, problem has to do with divider color. Do something like this:
ExpansionPanelList(
dividerColor: Colors.transparent,
children: [...]
)

flutter circular progress Widget

Am looking to implement a circular progress widget in flutter similar to the Jquery circular progress. The idea is when a button is clicked, as an activity happens in the background, the circular progress fills in color while a counter incrementally goes from 0-100%. I am able to do the circular fill using custom paint but am unable to display the actual % count as the color fills the circular progress. How would i do this in flutter?
Use precent_indicator library: https://pub.dev/packages/percent_indicator/install
It has good features, such as showing progress around a picture:
CircularPercentIndicator(
radius: 100.0,
lineWidth: 15.0,
progressColor: Colors.blue,
percent: 0.4,
center: const CircleAvatar(
backgroundImage: NetworkImage('https://tr.web.img4.acsta.net/c_310_420/pictures/bzp/01/61282.jpg'),
radius: 85,
),
),
),
you can use this plugin: https://pub.dartlang.org/packages/flutter_circular_chart
they have the component you need