I'm beginning with android and my current project is building a calendar.
At first I thought to use a horizontal list view but then I can't scroll left/backwards. I've found a tone of information on wrap-around infinite scrolling but I don't think it fully applies to this as the dataset is technically infinite.
Any ideas as to what I should use to achieve this (not necessarily code)?
Obviously I want to use some type of view recycling and be able to go to a particular day(today).
Thanks
check the link it helps you to create what you want;
https://www.toptal.com/android/android-customization-how-to-build-a-ui-component-that-does-what-you-want
I use this library, I think it's what you are looking for
https://github.com/prolificinteractive/material-calendarview
Related
What is the easiest way to implement a screen slide in Nativescript like shown in Android Viewpager , but in a vertical direction ? Another example of this functionality would be the rss reader feedly where you can change rss feeds by swiping up/down.
The page should allow vertical scrolling to the top/bottom and then transition after a certain treshold.
I already encountered nativescript-slides, which can only do horizontally sliding.
So is there a "nativescript" way or do i have to implement it as native android/ios feature (for example by this) ? In either case a sample on how to integrate it in nativescript would be great.
Update
Recorded an example:
taken from this Repo with Android native code. The outstanding PR made changes to offer vertical scrolling in the list. But the repo seems to be outdated and a bit buggy.
I can provide more info later but there's a new plugin implementing the native controls for android and iOS for slides/carousel her https://github.com/alexrainman/nativescript-carousel-view and vertical swiping is on his radar, I think he might even be close to completing that.
To give an answer for anybody interested in above nested scrolling animation:
For Android I had to implement the native ReyclerView in Nativescript in favor of the NS buildin ListView. It is an optimized view structure which among other things allows nested (vertical) scrolling and can be used as replacement for an ordinary list.
Together with https://github.com/alexrainman/nativescript-carousel-view works like a charm!
Anyone that ends up here still looking for ways to achieve this.
I spent a lot of time trying to figure out a way to achieve this and tried to find ready plugins for this. Also tried to use the plugin from Alexrainman but eventually gave up since the plugin was not up to date with the current nativescript-version.
My solution:
I used radListView as a basis for this implementation and leveraged the methods and events on the radListView.
By using scrolled-event I gathered data for the use of the scrolling feature: scroll Speed and scroll direction. (These might be also taken from the event data, but since I did not find the event details from the Nativescript-documentation I gave up trying to guess where to find this data on the event-model).
Then I also saved the fixed height of one item on my list (The height I fixed to screenHeight-200).
With all this info, I managed to hook the event "ScrollDragEnded" and add logic that makes my list behave like a vertical slider. Moving on the list by method "scrollToIndex" and figuring out which index to scroll and when by leveraging all the data mentioned above.
This is the way I managed to make a pretty good vertical slide.
Good luck!
I want to make the calendar view to display 2 months, one on top of the other and to be able to scroll/swipe down/up to move between months.
like in the attached image
I tired different custom calendar view but could not find anything like that.
(I just want to make sure there is definitely nothing like that before I start making it myself)
Here's One more:
https://github.com/ik024/CalendarLibrary
Hope it helps.
Found it!
it called CalendarListview. here is a link :
https://github.com/traex/CalendarListview
Friends,
I am trying to develop an application which requires the below UI:
I know its not a feasible thing to run a ListView with-in ListView or with-in a ScrollView. So I'll like to know that Is there any other way to do this same thing ? as the UI has to be same as its running in its LIVE iOS App.
Thanks in advance.
Solution: Thanks guys for all of your answers, but as I told that the Expandable-ListView is not the option in my condition. So I have creating a dynamic layout in Java Class file using an amount of various Layouts & Widget's Array. It took a lot of practice but it covered the necessity.
android-expandable-listview-simple
check this it will help you
You don't really describe your problem in detail but from your indication of a blue bar at the left, I suppose that you want to have some sort of a secondary ScrollView inside the primary ListView; which itself has its one scrolling view. If so, then using an ExpdandableListView will not be the solution that you want.
Android has some difficulties managing a ScrollView inside another ScrollView but if this is what you want, then take a look at: ScrollView Inside ScrollView .
Be warned that these solutions are not perfect and that probably you will never achieve the same level of control for this type of thing on Android as you can have on iOS.
I need to embed the native month-wise calendar with my xml layout, which will also contain some other components inside the layout.. it should also show all the calendar events shown for the specific month. Since i am a beginner in android, any source or example will be very useful !!
Thanks in Advance
In your case I think you have to use Datepicker, just go throgth this example
Haha, funny how I am currently doing just this. There is no built in view to do this, and even fewer examples of any specific code. You will need to build one from scratch. Luckily, Android does come built in with a class to help with the calculations that would otherwise be very annoying:
http://developer.android.com/reference/android/util/MonthDisplayHelper.html
What does this mean? Well you need to use your own code to build it out. If you have Java experience, should not be too bad just playing around with the dates and whatnot and add them into a table or grid layout (Layouts you should probably go with). As soon as you get the hang of it, then you can get into more complex features.
Try using a grid view and fill according to month array with date-time picker you can get a specific date and time each cell click you can show a list which would help user to make reminder or add note specific to that selected date.
At the top there is the favorites/styles/all channels
i don't know what that widget/control is i need to know what it is
i am certain i saw it before i just can't seem to find it again.
then there is a listview which is easy to implement no help needed there
then the same control again, i need to know how to build it.
it looks like a native Android control, i know how i can make one just like it using image buttons but i am sure i am missing something.
P.S. this is an image from sky.fm app on android
EDIT: I Do no need help with the ListView i already did that
What i do need help with is how to make the "favorites/styles/all channels" buttons if there is a way to do natively.
If there isn't a way to do natively, and you are sure just say there isn't a way to do natively ( that would be a good answer )
the perfect answer would be a working code, but i am not lazy i am already implementing the code my self
There's no native control for this. It's probably a Button or maybe ToggleButton. You could create a background xml with different states for selected true or false. And when you click the button toggle the selected state.
Top might be a custom tab layout, or just a bunch of buttons with custom styling.
Main part looks like a listview with complex row views.
Bottom almost definately is a bunch of buttons.
You can implement it using ClickableListAdapter.There is also tab implementation.try it.
Just make it using image buttons and put filters in your ListView, or create your own filter form scratch !