Attribute error what do these codes mean?

Go To StackoverFlow.com

0

"<Keyboard>" does not set the required layout_height attribute:
 (1) Set to "wrap_content"
 (2) Set to "fill_parent"
"<Row>" does not set the required layout_width attribute:
 (1) Set to "wrap_content"
 (2) Set to "fill_parent"
"<Row>" does not set the required layout_height attribute:
 (1) Set to "wrap_content"
 (2) Set to "fill_parent"
"<Key>" does not set the required layout_width attribute:
 (1) Set to "wrap_content"
 (2) Set to "fill_parent"
"<Key>" does not set the required layout_height attribute:
 (1) Set to "wrap_content"
 (2) Set to "fill_parent"
com.android.layoutlib.bridge.MockView cannot be cast to android.view.ViewGroup
You must supply a layout_height attribute.
Exception details are logged in Window > Show View > Error Log
The following classes could not be found:
- Keyboard (Fix Build Path, Edit XML)
- Row (Fix Build Path, Edit XML)
- com.example.android.softkeyboard.LatinKeyboardView (Fix Build Path, Edit XML, Create Class)
2012-04-03 20:54
by evc
it cut off at the beginnin - evc 2012-04-03 20:54


3

It means that your xml keyboard layout file is missing android:layout_width and/or android:layout_height for some of the components.

EDIT

On second glance, it looks like you are putting your keyboard layout file in the res/layout folder. It belongs in the res/xml folder.

2012-04-03 20:57
by Ted Hopp
it doesnt work my code must be all wrong....I dont know what to do. - evc 2012-04-03 21:14
@evc - see my updated answe - Ted Hopp 2012-04-03 21:45


0

an xml file in your project has elements which

"do not set the required layout_height attribute".

for each element, set it, for example:

<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:orientation="horizontal"
    android:layout_width="fill_parent"
    **android:layout_height="fill_parent"**
    android:background="@android:color/transparent">
2012-04-03 20:56
by pouzzler
I did that but no luck I have no idea why this softkeyboard will not show in graphical view and it keeps giving me errors..Im using the SDK keyboard sample... : - evc 2012-04-03 21:13
oh after looking at it again I get it lets see what happen - evc 2012-04-04 21:23