Android Studio: Designer without gravity - java

I don't know how to describe this properly. I'm using Android Studio for the first time (Eclipse before, but due to some reasons I can't use Eclipse on the computer I'm at for some weeks now) and trying to use the implemented designer. The problem is, there are only nine places (top|left, top|right etc...) where you can place objects. Is there any "free mode"?

Got it already. The solution is to morph the FrameLayout of the designer into a RelativeLayout (which Eclipse uses as default as it seems).

Related

Android Studio not Generating Boilerplate Java Classes Like MainActivity

Quick Android Studio question.
Lately I've been creating a lot of new projects in Android Studio and picking the templates like "Blank Activity with Fragment" or "Navigation Drawer Activity" and seeing that it's not generating any Java Classes like it should.
All the /res files get created like normal but there is a lack of any java classes so I have to start from absolute scratch.
While starting from scratch isn't the biggest hassle in the world, I'm curious if I'm just an idiot and have missed a flag somewhere.
here's a shot of the file tree when generating a "Navigation Drawer Activity"
Info on my Android Studio/Project:
-Building with Target SDK 21, minSDK 14, build tools 21.0.1
-Android Studio version is 0.8.13
Thanks For reading, let me know if you need any other information.
I managed to solve the problem. You will need to disable plug-ins that are not the need. In my case, I have used them from GWT

Implement iOS like time picker in Android

I'm looking to implement a time picker like below in Android.
I've already looked at http://tolkianaa.blogspot.mx/2012/04/how-to-use-android-wheel-part-ii.html but he has multiple xml files and multiple classes seemingly so I can't see how thats going to work. (Am I missing something?)
I have android-wheel installed so this question is useless Replicating the iOS time picker in Android
The demos from android wheel don't seem to really accommodate it.
Anyway, does anyone have a better way of implementing this is android?
You should have a look at the AOSP source code, a clock app is included I think it is the default one that is shipped with ICS & JB (but I have not compiled it to verify).
Also, the official website always have some useful info, you should try to start with this widget. The illustration seems to indicate that it uses buttons instead of swiping, which is strange but even if it is the case it will be a good start to implement a swiping version of this widget.
#Lokesh's link also seems to also fit your needs.

Is there a real Android visual designer for IDEs?

I'm trying to develop an Android application with UI. So it's little complex for me to create UI with codes. I was using Visual Studio for long time where visual design is piece of cake. I also used Netbeans and Eclipse for java applications with UI but when it comes to Android I can't find a good way for UI desing. There is a visual design part in Eclipse but I want to use Netbeans as long as it's possible. Also I think DroidDraw is not good enaugh too. So I seached on web for Netbean's visual design tool and found nothing. If there is no tool or plug-in like this WHY? Thank you for any help.
Edit:
Well, long time passed. I just get used to code my ui. Also I am using Android Studio. 8)
edit
just saw that you've used DroidDraw.
There is official GUI designer included in ADT. Browse for main.xml (project/res/layout/main.xml) and doubleclick it :)
enjoy!
The combination of ADT (Android Development Kit) and eclipse 3.1 + will help you to develop the application graphically. Once you open the layout xml files, click “Graphical Layout” tab at the bottom of the section to open the graphical view. Now you can drag and drop components & also update layout.
But it is better to understand how the xml is defined in the layout. This will help you to fix any problems (in case).
Hope this helps.
Using Embarcadero RAD Studio XE7 (delphi or c++builder) allows for that task but it builds apk files with ome 10mo,

Tools for rapid layout/interface creations?

Does anyone know of any tools (besides DroidDraw) that can help me create the basics of my projects a bit quicker? I'm looking for something that will allow me to very quickly generate the XML for my layouts so I don't have to sit there typing like a robot for so long.
Thanks!
However the drag and drop layout design method is not recommended for Android Applications UI designers but there is an Open Source project on Google Code: android-ui-utils , in which you might find something intersiting.
It uses a Firefox addon Pencil to draw and design android layouts and also uses an online "Android Assets Studio" where you can design your custom Icons like:
Launcher icons
List item icons
Menu Icons
Notification icons
You can give up a try here:
http://code.google.com/p/android-ui-utils/
DroidDraw is OK, but the reality is that if you are going to write for Android you are going to want to learn how to write XML layouts from scratch. I remember that XML layouts seemed bizarre when I first started working with the Android SDK, but eventually it starts to make sense.
I read a blog post from a member of the Android team at Google explaining why XML layouts are better than GUI-based layout systems (such as the one included with the iPhone SDK). I can't find the link right now, but basically XML allows for layouts that gracefully scale across devices of radically different sizes and purposes where a GUI-based layout designer often has to be tweaked at best and redone at worst for devices of different sizes.
The official Android Plugin for Eclipse comes with a GUI Editor which supports drag'n'drop of GUI Elements. Not necessarily better than DroidDraw, but maybe you didn't know yet: http://developer.android.com/sdk/eclipse-adt.html

Are there libraries similar to the Three20 Project for Android?

The Three20 project is really nice for building iPhone apps quickly using common libraries:
https://github.com/facebook/three20
Is there anything like this for Android?
Not exactly, but working at a company with a partially three20 based iPhone app developed in parallel with the Android version, I think about 50% of what 320 does you get right out of the platform on Android, minus a little polish. For example, 320's Navigator and TextEditor are basically baked in on Android - the platform's native text editing components can stretch dynamically on their own, and task navigation and back-button history is handled automatically on Android, with URL handling baked in to the intent filter and resolution system.
You can get much of the rest of 320's functionality out of reusable libraries like ignition or GreenDroid (at least with regards to caching and images loading in lists), without the weight and lock-in a fairly monolithic framework like 320 can add to your app. There's a few bits that these solutions miss (three20's zoomable photo viewer, for instance), but there's usually acceptable hackarounds for quick usage (an Android WebView makes a pretty decent image viewer substitute, for instance).
Once upon a time there was an SO wiki page gathering a bunch of those resources, but alas, that's gone away. You can get a pretty good set by looking for popular Android projects on GitHub or Google Code, though.
See Do android developers commonly use 3rd-party UI/networking libraries like Three20 on iPhone?

Categories