how to show all of my component in the tab layout? - android

i am facing a problem and wish you help me..
i am using tabs in my code and and i added a lot of component in it (Buttons , ImageButtons, etc..) and i put this layout in the center of the screen and here is the problem because not all my component appear in my layout (some buttons appears and others not and i can't see
it or deal with it).
So can i shrink the component or customize it to appear fine?
iam using TableLayout to manage the component then i added this layout in the corresponding tab ..
can you help me in that?
thnaxx in advance.

Give same weight to component in xml file .
i.e.
android:layout_weight="1"
Hope it will solve the problem

Related

Android studio My app is displaying incorrectly.

I am trying to learn to make my own apps by following tutorials but i have an issue when i run the app in the emulator or on my phone. All theScreenshot contents of the layout are squished in the top left corner.
This is all the codescreenshot 2here. I am a noob so don't go to hard on me. Thanks
It would be better if you also post your layout code (activity_main.xml) here for this kind of problems. But I am guessing you are using constraint layout as root of your layout and its child views are not constrained vertically, so all of them go to another position in run time.
Maybe you are using a relative layout and no positioning is specified.
You should paste the xml's code

Tips at start-up or update

I have an update for my app that includes ActionBarSherlock with a sliding menu. I have put my navigation entirely in to the sliding menu, leaving my main_activity pretty bare. I am worried the user won't know about the menu. So I want to add a prompt at start-up that will highlight the new feature. Like this:
I am not even sure what this is called, so I don't know how to research it. Any help or suggestions will be rewarded. Thanks!
You could just use overlay layout (Frame layout with multiple inner layouts will fit perfectly. Please note Frame Layout Z axis is by the lower the layout is in the xml, so the guide should be the last in the XML). Make that layout's background mostly transparent and add buttons and design to fit your needs. When you don't want to show the layout just set visibility to gone. And when you need it set to visible.

How to set a tabHost at bottom of the screen using only java?

I am working to create a TabHost at bottom of the screen using only java code.
I am in a condition that I cant use xml layouts .Can someone expert in dynamic layouts could help me?
You can do this by providing alignParent rule for parent RelativeLayout, if you have one.
You can do this by providing correct order if your parent is LinearLayout
DO NOT use bottom tabs. Read design guides first.

How do you rearrange buttons where you want them in Eclipse?

Hey guys I am having trouble with placing my buttons in my XML layout. I already have a background and was just trying to put 3 buttons near the middle and thats where I'm having trouble. I know about center gravity and all that but could you help me? Also, If I made my own buttons can I just import them using the image button thing, or is that not right? Thanks for the help!
PS: Also, there is a big white box around my button. How do I get that to go away?
I posted this answer to your duplicate question, so I'll also post it here. :)
You can rearrange elements of your layout by editing the XML directly or by dragging and dropping in the outline view or the graphical layout view (I find the latter harder to do reliably).
To use your custom views, click on the "Custom & Library Views" button in the graphical layout palette, or just type in the fully qualified class name as the view tag in the XML.
If you use Image button you can set your custom Image to src property or background property. If youi chose src you should add android:background="#null".
But I would recommend to use background property while if you use 9-patch png (who knows maybe tomorow you will use 9-patch) they would not stretch if you set it in src.

Want help to make Android layout same like attachd image

I am getting stuck with making android screen layout same like i have in my iPhone application. The iPhone screen layout is given in below image. Please anyone can help me out to make same screen for android. You can give me some idea with having some code snippet please.
Thanks in advance.
First off, you should be creating an XML-based layout. The Android SDK has a graphical layout tool that will help you with that.
Start looking into 9-patch images for your custom button graphics and setting your android:background attribute to them within a <Button />. Make sure you use actual text for the buttons, not graphics of the text. You should probably use a <RelativeLayout /> for the main layout, as that will let you target multiple screen sizes easily without a mess of nested <LinearLayout />s.
For the tinted area, just use a translucent PNG (with an alpha channel) instead of attempting to line up graphics.
use relative layout to design this screen like use image for navigation bar and align it as parent top (use no title bar in mainfest) add its listener
similarly you can align other text and image view

Categories

Resources