How can I align in Flutter an area at the bottom of screen only if the content above does fit in screen. If not, all content should be scrollable - flutter

I would like to have a screen in Flutter with 2 buttons that should always stay at the bottom screen, unless the height of the content above the buttons plus the height of the 2 buttons overflows the screen height, in which case I would like that all content should be scrollable. How can I achieve this?

Related

`CustomScrollView` with `SliverFillRemaining` show jittery effect

I wanted my button to shift below the content when the keyboard opens or there is no space on the screen, and when there is more space it should stick to the bottom of the screen. For that, I use a CustomScrollView but now the jittery effect is there. How can I make this transition smooth?
Here is the video of the screen:
Rendered Screen
In order to align my button on the bottom of the screen, So I used a CustomScrollView with two sliver widgets SliverToBoxAdapter and SliverFillRemaining with hasScrollBody: false and aligned the button by wrapping in a Align and set alignment: Alignment.bottomCenter.
Widget Tree

Flutter , keeping container of a ListView on the top of the screen when scrolling down

how to keep a specific container of a ListView on the top of the screen when scrolling down?
for example:
appBar
image1(inside the listview)
tabs(should stay below appBar but image1 disappears when scrolling down)
list item 1
list item 2
....
navBar
You have to work with SliverList and SliverAppBar to achieve a layout like that.
Read more about it in this article.

Autolayout in tabs

Tab Bar
I want Chat image in between that menu and people image and fire image in between menu and notification image using autolayout.
I have applied leading, center vertical, fix width and fix height o Chat image
For fire image I have given trailing and remaining same as chat image.
Note: This is not tab bar this is custom view.
Above problem solved but now in iPhoneX am getting
that bottom bar is hidden
How can i come out from this issue?
Create a container with leading and trailing - 0 - to surrounding images(people and menu), and center horizontally the image (chat) inside this container.
or:
chat.center = CGPoint(menu.frame.minX - people.frame.maxX)
If you are creating view programatically then make sure buttons in view have aspect ratio with screen width.
Why don't you use Horizontal Stack View.
See below image

UIWebView setting custom width for the content

I have the html content for my web view. When I load the content my web view makes the content scrollable in both directions, horizontal and vertical.
What I want is to limit content to width of the screen, so that each line of text just wraps onto next line on reaching screen width.
Currently my data loads the text correctly. It is scrollable vertically and text does not go out of the bounds and width.
But there are images in my content that goes out of the bounds in horizontal direction, and user need to scroll horizontal to see full image. I just want that if the image width is more than 320, then I could just resize into same aspect ratio to 320, so that my content is only verticality scrollable.
I have looked up on Stack Overflow and apparently these type of customizations can be done using JavaScript, but I don't know JavaScript.

iPhone App Phone Call Situation

When a phone call occurs, my app moves down, and the bottom of the app is cut off slightly. Is there anyway to shrink or resize that whole view when a call occurs.
Preferably through interface builder.
Indeed, your application window does shrink its subview. For example, if you have a status bar so the frame of your root view is (0,20,320,460), then if the in-call status bar is on, then the frame becomes (0,40,320,440).
Then why does the bottom of your app seem to be cut off? It's simply because the root view autoresizes its content in that way. For example, its autoresizingMask property says it has a fixed top margin and a fixed content height. So,
If you want to 'squeeze' the view, try fixing both top and bottom margins and having flexible content heights.
If you want the in-call status bar to look as if it goes over your app, fix the content heights and the bottom margin, and have a flexible top margin.
If you have a fixed top margin and a fixed content height, then your app will seem to slide down.