Possible to make overlay view scree-wide over 2 different elements? - android

I have a layout looking like this.
The bottom part are the tabs and this is one of the tabs. It has a LinerLayout on the left and ListView on the right side. The list view goes beyond screen height and elements are scrollable.
Is it possible to locate red-colored LayoutView over these element at this specific location without much redesigning a layout?

Related

Make middle View not push other view outside of bounds

I have multiple TextViews inside a horizontal LinearLayout and i need the middle text view to have ellipse=middle so that when the middle text is long enough, it pushes on both sides but the other views don't go out of bounds, but instead the middle TextView shows the '..."
Here's how it should look.
Setting the items normally, wrap_content for all in a horizontal LinearLayout will make the at ASAP text be pushed outside of the screen on Android (the above screens are from the iOS app).
Any ideas on how to accomplish this? Perhaps with a ConstraintLayout somehow ?!
Yes, i would recommend a ConstraintLayout. Top item to the top of the view, bottom item to thr bottom of the view then the middle item attached to these two views. You could also use barriers.

Trying to show to get two relative layouts to scroll

Here is the design for my screen:
The Green border indicates the visible screen.
At first the user would only be able to see relative View 1 and the Scrollview would not do anything.
After the user presses the button to show the 2nd relative view, the 2nd relative goes from invisible to visible and the view is now scrollable (because the screen is extended)
I have nested my layouts as followed
<RelativeLayout>
<ScrollView>
<LinearLayout>
<RelativeLayout1>
<RelativeLayout2>
</ Closing for each layout>
My problem is that my either my Relative View 1 will not stretch to fit the screen or if it does stretch to fit the screen, I will not be able to scroll down to relative view two.
I've tried to play around with match_parent,fill_parent,wrap_content on all different levels but haven't found a solution to my problem. Any suggestions on how I would create fix this?
Your design looks like you wanted to implement something expandable view. Try this Link

how to move all the Layouts up when scrolling more in the list view in android

i have a fragment which has a stationary Image View at the top , some linear layouts to display the texts and List View at the Bottom. i want the entire screen to go up(that stationary Image View and middle part) when i scroll down in the List View.
I tried to place all layouts in a single Linear Layout and put it inside Scroll View since it has only one direct child..but that makes only the List view scroll able.
Try using CoordinatorLayout and scrolling behaviour from the design library.You can find a great tutorial here

How put Horizontal View and Gridview inside Vertical Scrollview

I want to develop an app that includes GridView and I want it to be some thing like horizontal ListView above a gridvew .Horizontal view displays images downloaded from url.I saw this touturial ( horizontal scrollview used)
and saw this to put the GridView inside scrollView because i want to put the gridview(episode #2) and horizontal view (episode #1) in vertical scrollview(episode #3) . I need to scroll the horizontal view vertically when a user is scrolling the gridview and not to have fixed position at the top of the screen.
I have no idea how to do this (use horizontal ScrollView or horizontal Listview)?
after vertical scrolling I want it to be like this (horizontal view must get scrolled vertically):
This is a custom interaction, so you probably will not be able to use a "standard" tool for this. You may want something like the FloatingActionButton (an example here: http://antonioleiva.com/collapsing-toolbar-layout/) but you also want it to scroll, so you may need to extend that class.
Also, you could use touch events to do a custom animation on the area, because you will need to track when it is displayed and the direction/distance of the motion event to collapse/expand it. You also would need to know anchors on the list, to determine when it should reappear...
This is a cool design concept, but usually "cool" = "difficult" because it's not standard.

Android - How to implement a 2 view vertical scroll screen

What do you think is the best way to implement the following: there are two views (A and B) and both should have the same height of the screen. View A should be on top of View B. View B is accessed by scrolling down on the screen (like a list view).
Would you use a vertical ViewPager, ListView, ScrollView, other?
Thank you
If you want to be able to stop showing half of both views use scrollview. If you want to switch between whole views use vertical pager. It really depends on what effect you want to achieve.

Categories

Resources