HighCharts For Android Exporting Button - android

I'm using highcharts for android. I wanna change exporting button background. How can I do that?

In order to set the background color of your exporting button, you can use navigation.buttonOptions.theme.fill property. Here is how to implement it using our Android wrapper:
HINavigation navigation = new HINavigation();
navigation.buttonOptions = new HIButtonOptions();
navigation.buttonOptions.theme = new HITheme();
Navigation.buttonOptions.theme.fill = „#ff0000”;
API Reference: https://api.highcharts.com/android/highcharts/

Related

How to change background colour of Leanback SearchSupportFragment Android

How can I change background colour of search support fragment in android leanback library. I have tried to find a public function to do the same just like in BrowseSupportFragment.
Try this:
val backgroundManager = BackgroundManager.getInstance(requireActivity())
val backgroundManager.attach(requireActivity().window)
backgroundManager?.color = Color.parseColor("#ff0000")
It works for the RowsSupportFragment, so I guess it works for search too

How to create progress bar in android without using progress bar widget in xml file?

I want to do something new in my app. I want to create Progress Bar without using tag of xml in android .is there any way to do that ? if yes then please share with me? The purpose of doing this is that i don't want to declare Progress Bar for each of my layout file. I completely want to make it using Kotlin Code in android. thanks in advnance
You can use the ProgressIndicator provided by the Material Components Library.
For example a CircularProgressIndicator:
val layout = findViewById<LinearLayout>(R.id.layout)
val indicator = CircularProgressIndicator(this)
indicator.isIndeterminate = true
indicator.trackColor = ContextCompat.getColor(this,R.color.xxx)
indicator.indicatorSize = resources.getDimensionPixelSize(R.dimen.indicator100dp)
indicator.setIndicatorColor(ContextCompat.getColor(this,R.color.xxx))
indicator.show()
layout.addView(indicator)
Or a LinearProgressIndicator
val indicator = LinearProgressIndicator(this)
indicator.isIndeterminate = true
indicator.trackColor = ContextCompat.getColor(this,R.color.xxxx)
indicator.trackThickness = resources.getDimensionPixelSize(R.dimen.cornerSize8)
indicator.setIndicatorColor(ContextCompat.getColor(this,R.color.xxx))
indicator.show()
layout.addView(indicator)

Create Custom Place Picker using New Google Place API in Xamarin.Android

I am trying to create custom place picker for Xamari.Android. I could not find the following plugin in xamarin
com.google.android.libraries.places:places:1.0.0
Can Anyone help me here? I am trying to implement custom place picker using this link: https://codelabs.developers.google.com/codelabs/location-places-android/index.html?index=..%2F..index#8
If you guyz have any other way to sort this out do let me know. I want to create a view to pick a location from a map, search location etc.
Currently I have these package installed.
The com.google.android.libraries.places:places aar library is wrapped via the
Xamarin.Google.Android.Places package (the current version is 1.1.0.2)
https://www.nuget.org/packages/Xamarin.Google.Android.Places/
This Xamarin library source and its sample code are at:
https://github.com/xamarin/XamarinComponents/tree/master/Android/GooglePlaces
From the sample code:
....
if (!PlacesApi.IsInitialized)
PlacesApi.Initialize (this, apiKey);
placesClient = PlacesApi.CreateClient (this);
placesData = new List<PlaceData> ();
....

Put a lottie animation in a Dialog. Android

I'm developing an app in android, and I want to use lottie for a Dialog that could have an animated icon of checked-done or fail. Wellcome some examples or ideas. I guess this is possible.
Thanks
You can do that using the LottieDialog library
Github Repo for examples and documentation : LottieDialog
Code example:
Button button = new Button(this);
button.setText("Ok");
button.setTextColor(Color.WHITE);
button.setAllCaps(false);
int greenColor = ContextCompat.getColor(this, R.color.green);
button.setBackgroundTintList(ColorStateList.valueOf(greenColor));
LottieDialog dialog = new LottieDialog(this)
.setAnimation(R.raw.success_like)
.setAnimationRepeatCount(LottieDialog.INFINITE)
.setAutoPlayAnimation(true)
.setDialogBackground(Color.WHITE)
.setMessage("Task is Done :D")
.setMessageColor(greenColor)
.addActionButton(button);
dialog.show();
You can add more buttons, or create it with no buttons,

navigation in Android TV

navigation in Android TV.
How do I create just the navigation android tv. I do not care to use the entire theme, it provides android studio.
And I do not understand much of what is in the example given by android studio.
I understand that is something the String.
I looked on the internet examples, but right now, android tv has no further information at this time.
I'm interested only create menu navigation side, nothing more.
Thank you very much.
I found a really nice tutorial : http://corochann.com/browsefragment-header-customization-android-tv-application-hands-on-tutorial-17-697.html
it shows you how to create a custom navigation side with an image and a text
Here what a tried in my application :
copy his IconHeaderItem class and in your loadRows paste
IconHeaderItem gridItemPresenterHeader = new IconHeaderItem(0, BEWELL_THERMO, R.drawable.bewell_thermo);
GridItemPresenter mGridPresenter = new GridItemPresenter();
ArrayObjectAdapter gridRowAdapter = new ArrayObjectAdapter(mGridPresenter);
gridRowAdapter.add(DERNIERE_MESURE);
gridRowAdapter.add(GRID_STRING_GUIDED_STEP_FRAGMENT);
gridRowAdapter.add(GRID_STRING_RECOMMENDATION);
gridRowAdapter.add(GRID_STRING_SPINNER);
mGridItemListRow = new ListRow(gridItemPresenterHeader, gridRowAdapter);
mRowsAdapter.add(mGridItemListRow);
setAdapter(mRowsAdapter);

Categories

Resources