layout

How to make RatingBar to show five stars.

Hi! I am following the standard example of how to add a RatingBar. To control the number of stars I tried to use android:numStars="5". The problem is that the number of stars doesn't seem to do anything at all. In portrait-layout I get 6 stars and when I flip the phone I get about 10 stars. I tried to set the number of stars in my Activ...

Why isn't my WebView filling up the entire width of my screen?

My WebView doesn't fill the entire width of my phone. I am telling to fill_parent. Not sure why? <?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="fill_parent" android:layout_height="fill_parent" android:orientation="horizonta...

How create and populate three columns on Android

I need populate three columns in Android activity with dynamic data. How can I do it? ...

Android pages Activity or Layout?

My app Consists an intro page with "Start", "About", etc.. I managed to create a functional version of the app by having the "Start" button call a new layout in which a new onclick listener is defined. This doesn't seem clean to me that I@m defining a new onClick listener for each Layout I use and wonder how the correct way would be t...

Position:fixed inside the wrap block

Say I have an absolutely positioned div inside a normal one. <div id="wrap"> <div id="sidebar"></div> </div> In this case, when I state top and left for the "sidebar", they are calculated inside of the "wrap", because the latter is position="relative". However, when I change the "sidebar" to position="fixed", the coordinates are calc...

Remove highlight effect from EditText

I want to remove the orange highlight around the EditText. This highlight doesn't match my UI and I really want to get rid of it. Any ideas? ...

CSS Layout for Header, Footer and Content with Scrollbar

I need the following layout for a webapp: +---------------------------------------------+ | header | +-------------------------------------------+-+ | |#| | content | | | |#| +-------...

Extending an existing layout in Rails

I have my main application layout, but then I have an /account section of my site which has exactly the same layout as the application layout markupwise, except the /account pages have an added sidebar in the content area of the layout. Rather than blatantly copy the application layout and create a nearly redundant "account" layout, I'd...

Qt: Align controls that are in separate layouts

Hello, On a form designed with Qt Designer, I have two QGroupBoxes with a bunch of controls in each of them. Both group boxes have nearly the same contents (QLineEdits with associated labels). What I want to do, however, is to align the controls together, as if they were part of the same grid layout. But since they are in separate cont...

Android : acces to Canvas without inheritance

Hi all, I want to draw in a view/layout, but I don't want to have to inherit from Layout, ( in order to have the onDispatch(Canvas canvas) method). I want to draw bitmap over my main application, but without losing focus (so i cant run an activity to draw on screen). I had a solution that was working but I had to inherit from LinearLayou...

I thought views/layouts/application.html.erb was meant to apply to all layouts?

I am trying to design my ruby on rails app at the moment. I created views/layouts/posts.html.erb which styled my PostsController's views. I want to add a main bar that is always at the top of the page no matter what view the user is looking at. I thought this was what the views/layouts/application.html.erb was for. This seems to agree ...

Location of head.phtml in Magento

I am working with Magento and need to remove a Javascript that is being included in the <head> section by default. I am using a modified theme called modern. I am looking for head.phtml in: app/design/frontend/default/modern/template/page/html/head.phtml It does not exist. I do have header.phtml and footer.phtml. The code from header...

Theater Seating application in WPF -problems in databinding

Hello, I am new to WPF, and I want to develop an application for Theater seating in WPF- c#.net. I did some research but i am lost as i do not know how each seat's data (sold or not, price, in which row) should be eventually bound to field in a table in SQL Express. Should i be using ObservableCollection to populate the contents of a Dat...

How can I set the width and height of an ImageView to another ImageView's width and height on the XML?

I have this layout. <ImageView android:id="@+id/icon" android:layout_gravity="left" android:layout_marginLeft="5px" android:layout_width="wrap_content" android:layout_height="wrap_content" android:src="@drawable/icon"/> <ImageView android:id="@+id/header_avatar" android:layout_gravity="left" android:layout_marginL...

resize textarea to fit in a fluid width layout with javascript

Hi. I have a fluid layout and i need a textarea to expand/reduce depending of the size of the parent container. In CSS it would look like this: textarea{ width: 100%; } But this doesn´t work with textareas. How can I do this with javascript? I can get the parent element width and them calculate the number of cols to fit that width b...

how to see two or more layout whit android?

hello i got a project that i need to add one or more layout to my existent layout. the problem is that i'm can saw just my last layout . i am using overlay's vector and i'm asure that is not the way to solve this problem i will glad that some one will give me some clue how to solve this problem thank you ...

Storing dimensions in xml file in Android

Hi, I am trying to consistently use the same dimension in all the views in my android app (e.g., a left margin of 20dp). If I were using HTML, I would simply use a CSS file, but I am at a loss of how to do this on Android. Is there a way I can store this value in a xml file inside res/values and then use it in layouts? e.g., I thought...

Android UI: what kind of layout options are mutually exclusive?

After designing layouts in Android for a while now, I still cannot get the hang of it. Often the results are unpredictable. I think part of this boils down to some layout options not working well together. I.e. if you are using one way of specifying your layout, you're not meant to use some other way. Notably, for me, changing layout_...

Why is this JPanel not sticking to the specified size?

So, I'm trying to learn Java Swing and custom components. I've created a JFrame, given it a background color, and added a JPanel: JFrame frame = new JFrame("Testing"); frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); frame.setSize(1000, 2000); frame.setBackground(Color.WHITE); JPanel jp = new JPanel(); jp.s...

Netbeans IDE 6.91 "center horizontally" not clickable

hello everyone, i am decent with java programming, but very new to GUI development. i wanted to make a console blackjack game i made years ago into one where people can play via a GUI i build using netbeans. i think that without a GUI, most people won't take the game seriously when i add it to my working portfolio i created a JFRAME wi...