Layout and GraphicsView

by henry » Tue, 05 Apr 2011 00:21:00 GMT


Sponsored Links
 I need to add two buttons and one textView with a Graphicsview. How do
I do this? I noticed an expert, Tony Obrien, has an code example,
Could you share with me?

Thanks,

-Henry




-- 



Re: Layout and GraphicsView

by TreKing » Wed, 06 Apr 2011 01:01:56 GMT


 



What is a "Graphicsview"?



Read the documentation?



If *you* noticed the example, why do you need *us* to share it with you?

-------------------------------------------------------------------------------------------------
TreKing < http://sites.google.com/site/rezmobileapps/treking> ; - Chicago
transit tracking app for Android-powered devices

-- 


Sponsored Links


Other Threads

1. Getting hold of PreferenceActivity Views from the xml file

> I have an XML file called user_preferences that contains my

You can try calling getPreferenceScreen(), though a better approach is to
add more validation-style configuration to the preferences themselves. For
example, EditTextPreference supports all of the XML attributes that
EditText does for determining input type and such.

-- 
Mark Murphy (a Commons Guy)
http://commonsware.com
Android App Developer Books: http://commonsware.com/books.html


-- 

2. Can't make columns of RadioButtons in a RadioGroup

Hello,

I have a bunch of radiobuttons in a radiogroup and I would like for
them to be arranged in two columns. The reason being so that they fit
on the screen and so that I can change the columns to be four in
landscape mode. I thought to intermingle the tablelayout with the
radiogroup. with the following code:

<TableLayout android:id="@+id/TableLayout01"
android:layout_height="wrap_content"
android:layout_width="fill_parent">
  <RadioGroup android:layout_height="wrap_content" android:id="@+id/
radiogroupChoices" android:layout_width="fill_parent">
    <TableRow android:id="@+id/TableRow01"
android:layout_height="wrap_content"
android:layout_width="fill_parent">
      <RadioButton android:layout_height="wrap_content"
android:text="One" android:id="@+id/RadioButtonOne"
android:layout_weight="1" android:layout_width="fill_parent"></
RadioButton>
      <RadioButton android:layout_height="wrap_content"
android:text="Two" android:id="@+id/RadioButtonTwo"
android:layout_width="fill_parent" android:layout_weight="1"></
RadioButton>
    </TableRow>
    <TableRow android:id="@+id/TableRow02"
android:layout_height="wrap_content"
android:layout_width="fill_parent">
      <RadioButton android:layout_height="wrap_content"
android:text="Three" android:id="@+id/RadioButtonThree"
android:layout_weight="1" android:layout_width="fill_parent"></
RadioButton>
      <RadioButton android:layout_height="wrap_content"
android:text="Four" android:id="@+id/RadioButtonFour"
android:layout_weight="1" android:layout_width="fill_parent"></
RadioButton>
    </TableRow>
  </RadioGroup>
</TableLayout>

In this setup, the radio buttons show up in neat columns but the
problem is the instant that I do that it takes them out of the
radiogroup.

I tried leaving them in the TableLayout and just changing the parent
of the radiobuttons by using radiogroup.addView(eachbutton) but that
wouldn't work since they were already defined in the xml.

I also tried just having a regular radiogroup with the radiobuttons in
them and then just changing the orientation to horizontal, so that I
could set the width programatically based on the screen width

<ScrollView android:layout_width="fill_parent" android:id="@+id/
scrollviewListHolder" android:layout_height="fill_parent"
android:layout_weight="1">
  <RadioGroup android:id="@+id/radiogroupChoices"
android:layout_width="fill_parent" android:layout_height="fill_parent"
android:layout_weight="1" android:orientation="horizontal">
    <RadioButton android:layout_height="wrap_content"
android:text="One" android:id="@+id/RadioButtonOne"
android:layout_width="wrap_content"></RadioButton>
    <RadioButton android:layout_height="wrap_content"
android:text="Two" android:id="@+id/RadioButtonTwo"
android:layout_width="wrap_content"></RadioButton>
  </RadioGroup>
</ScrollView>

but that wouldn't work either. as many as would fit into one row would
fit and the rest would be off the screen.

Is there a way to arrange them in such a fashion while still keeping
them in the radiogroup?

--

3. Getting hold of PreferenceActivity Views from the xml file

4. Scaling Transparent Graphics in 2.0.1

5. Google map with navigator bisa lagi euy ....

6. For Man Only

7. Where can I catch a point that is assured to be called when a Service is destroied