Android layout development - android

I would like to develop a layout below. I am really confuse related to that. I used RelativeLayout, FrameLayout to develop this. But I am not getting perfect output. As per below image, the Dark Gray color is overlap the light Gray layout. If I used Relative layout then dark Gray will be in the light Gray area. And if I used FrameLayout then the other controls of light Gray will not set perfectly.
Please guide me the right path. I am stuck in this layout. Thanks in advance.

According to your figure, If all widgets need to show without scrolling vertically , you can have vertical linear-layout here,
TextView
Button,
ImageView
List view with defined height
Other widgets

Related

Android Gridlayout isn't showing framelayout that doesn't have any view in it

I wanted to implement a chessboard with gridlayout & framelayout. When I hardcoded the xml everything works fine. But when I tried to implement it programmatically all things fall apart. In xml I added
android:background="#color:blue"
to framelayout and it made a blue square but when I do this dynamically like
framelayout.addBackground(drawable)
no square shows up unless it has a child in it Broken chessboard
Also how to change the size of the chessboard square dynamically? It seems like gridlayout's grids don't get size from its parent rather from its child.
Any help is much appreciated. Take love.
I forgot to set height, width to the framelayout. That's why it was not showing anything. The potential solution is:
framelayout.setMinimumHeight(height);
framelayout.setMinimumWidth(width);

Custom ImageView with custom styling (How-To, Name)

I'd like to know the name of such effect to the following screenshot. For example, the image is full loaded as a Rec, then it has an extra space with an angled white/dark space.
I literally have no idea how to better explain this.
I don't want a code sample, just hints so i can know how to do such custom styles.
The first and second screenshot: you can use Relative Layout
Firstly, insert the imageView, then insert the white layout with needed dimensions and margins, so it will overlap the imageView.

How to set border of Gridview

I am developing an Android app. And i am trying to show a DashBoard. DashBoard is working fine. I have taken gridview to display it, But I want to set the border of that gridview. How can i achieve it ? if anyone can suggest me something useful.
You can override GridView drawing and draw border from there.
You can add rectangular shape as the background.
You can put your GridView inside another layout, set background color for that layout and set margin for the GridView. (not really good as Android has to draw big single-color view and then cover it with GridView)
Lots of ideas here: How do I put a border around an Android textview?

Gridlayout with borders

I'm a new Android developer, and I'm just trying to improve my skill by reading some samples, I want to design a new interface using GridLayout, I've checked a lot of samples but I can't seem to draw borders between the GridLayout cells. What could I be missing?
Here is a link that I went through it, but the borders didn't show up!
http://developer.samsung.com/android/technical-docs/GridLayout-in-Android#
I appreciate your care in advance.
Android Layout containers don't draw borders. Still:
You can set background of each cell's View to an xml Drawable resource,
which describes a transparent rectangle with borders.
Give a background color to GridView's parent View, and set each GridView cell View's background to a different color.
Both of these can also be applied as a Style.

Android 3.0 "holographic" theme borders

I am trying to draw and animate several ImageView items on a screen and I would like to have the images display the blue borders used in other Honeycomb apps (examples of borders here: http://www.youtube.com/watch?v=UPSBctbYc9Q # 1:10).
I've seen hacks/workarounds for older versions of Android using a background image, but I was hoping to avoid that. Can anyone help me to add such borders?
Thanks
I'd suggest just creating a custom view using FrameLayout as its base to layer up the background/border, and then the ImageView on top using an appropriate padding value such that the border remains visible.

Categories

Resources