I wanted to add a settings menu to my android app.
I followed this tutorial
and added an "activity_settings.xml" in "res/xml/" like descripted.
But now I cannot edit with the WYSIWYG editor?
Why is that? Isn't google supporting this way of creating settings anymore?
How else should I do it? Create a "normal" activity layout file and use this as menu?
Found this, but no answer why:
Where is the option to add a new preference screen in Android Studio 0.4.0?
There has never been a visual editor for PreferenceScreen.
It is an xml file of preferences that are bound to an activity on run time.
I dont see anywhere in the official docs you linked that supports the idea of a visual editor.
You can edit visually, any activity layouts, but this has always (to my understanding) been different.
I can see where you are coming from though, at it is still an xml in a layout kind of structure.
Your best solution is to run your project periodically to see the progress.
Related
Where is this button gone in the UI editor form ADT? Or what is the alternative?
It was very useful to create new layouts for different screen configurations.
Thanks
UPDATE: This button disappeared after updating to ADT 20.0
Where is this button gone in the UI editor form ADT? Or what is the alternative?
If that is what I think it is, it is in the drop-down that, by default, is labeled "default":
When folded open, the drop-down looks like this:
You can refer this SO Question/Answers and followings links, that gives you the same or better UI development tool for different configuration.
Droid Draw
Android App Developers GUI Kits
Android UI Utils
Simple UI
App Inventor
I'm regularly using these tools for UI development for my Android Application, You can try this for your development.
EDIT :
Sorry, I misunderstood the Question and the possible answer is,
You can get this button in Android Common XML Editor in top navigation bar, from there you can create alternative layout for different density.
hi I'm using Eclipse at the moment, and I'm not sure if there is a plug in for it or a better piece of software I can use. It seems fine for the Java side The problem I have is with XML editing, the line up of the characters is very inconsistent and when editing my layouts, I work with a graphic view open and a code view open, but the two are not linked, so if I double click on an element it switches from graphic view to code view in that pane. it would be awesome if I could link the two open panes?
Please see the screen shot for my desired outcome.
I understand that this question could be seen as discussion based, but I am seriously just looking for a solution here. The example I show is very simple, but some of the xml files turn out quite large and complex, and it is becoming more important to me to find a solution for this.
You can use DroidDraw for ui designing. Although it is a bit buggy, but at-least you dont need to edit raw xml files if you use this.
I am now using the Android eclipse Juno development kit, and while I still dont have dual window available, the double click select is working. there is also an Outline pane which shows the layout, although annoyingly this doesn't show comments very well.
The Visual Layout Editor for Android in Eclipse does a poor job at presenting layouts and just gets in the way too much.
How do I turn it off?
thanks!
Simply click the XML tab and write the layouts that way. Every time you open a file that you closed in XML mode, it should open in it as well.
I am using the eclipse (adt plugin) android gui editor and I am wondering how one can display all the used IDs for the single views at once? Currently Iam looking it up by right clicking and choosing Edit ID, is there an easier way to just always show the IDs while the editor is displayed? Thanks!
you can use the tool from the abd hierarchy
That gives you a grear overview of your UI application.
You can switch to the XML Edit Window.
But I think that the right click on the view is the easiest way
I'm trying to get my app to blend in as much as possible with the "standard" with the rest of my android device. It's a stand-alone app, not integrated with the OS or anything, I just want it to look familiar.
The area I'm interested in is the "settings" screen. If I look at Android's standard settings screen, it's well spaced, perfect font size, with neat pin stripes between the menu items.
How do I do that? Is that a ListView? Is it done with a regular LinearLayout?
I would love to be able to replicate the look & feel in my app. Can anybody assist?
And it's not just the Adroid OS. it's most of the "professional" apps out there:
Many thanks
Actually, this is directly part of the Android source code, so I would strongly advise you to take a look in its structure. See the Android Settings tutorial for more info.
Settings are created from the SettingsActivity (which extends the PreferenceActivity, you might want to look this too), which in their turn have their layout based on the following xml files:
preferences.xml
preference.xml
Things are quite strongly interlocked so it needs some reading...
AFAIK its a ListView. by implementing a custom ListView, you can achieve similar effect.
Moreover, you'll have to follow the Icon Design Guidelines to create such icons for ListView rows