fleighhomes
New Member
So here's my predicament:The graphical layout in Eclipse works and properly displays anything (textviews, buttons, ...) I add by writing the xml out.But when I try to drag and drop things into it, whatever I try to add in this way doesn't get displayed.Specifically, when I'm in LinearLayout, anything I add gets added into the xml without layout properties. A button that I dragged and dropped into the graphical Layout gets added like this:\[code\]<Button android:id="@+id/button1" android:text="@string/hello_world" />\[/code\]So obviously, I can add android:layout_height and width to this button manually (and if I do it shows up on the screen), but this kind of takes the point of the drag and drop away, right?Is there any way to fix this? Can you set up somewhere which default properties a dragndropped widget should have?Also, when I'm working with RelativeLayout, somehow there's a lot more properties added.Another button that was dropped using the graphical layout shows this in the xml:\[code\]<Button android:id="@+id/button1" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_alignParentLeft="true" android:layout_alignParentTop="true" android:layout_marginLeft="78dp" android:layout_marginTop="101dp" android:text="Button" />\[/code\]However, this one ALSO doesn't show up on the screen until I save the xml.Is this normal? Again (assuming it's not), is there a way to solve this?Many thanks to all of you!I looked around and found lots of sort of similar problems, but nothing really quite like this!