Android :: How To Put Multiple Widget Sizes In One APK?
Jul 31, 2010
What I'm trying to do is have a clock widget of different sizes (i.e. 2x2, 3x3, 4x4 etc) in one apk and a configuration activity to be able to select which size to add. From what I've learned from documentation:
Widget size is specified in <appwidget-provider> tag in respective xml file
Also in that file I set up the configuration activity for that provider
So it seems that size is a property of AppWidgetProvider and I'll need to somehow create another provider from the code in configuration Activity of the first one. I have read this and this. First one explains how to put multiple wigets in one apk, but it's not clear how to select between them in runtime. Second one is about changing layouts, but not size.
View 2 Replies
Dec 7, 2009
I have noticed that when I install some widgets I can later choose from different widget sizes while adding widget. How can I implement that feature in my widget?
View 2 Replies
View Related
Apr 22, 2010
I've been reviewing the Supporting Multiple Screens documentation on the Android and I just need some additional clarification...
It's my understanding that designing three unique interfaces (ldpi, mdpi, and hdpi) would be the best way to go about supporting all the potential android screens with minimal scaling/distortion.
Yes, I know there are similar questions posted, however... If I create an image for the benchmark mdpi (let's say my image is 300x210, just for example) how to I determine what size I will need to recreate that image at ldpi & hdpi? This post as well as a google search leads me to believe that ldpi is just 75% of the mdpi image, and the hdpi is 150% of the mdpi image. Is this accurate?
View 1 Replies
View Related
Dec 16, 2009
I have created layout-large and testing against android 2.0.1 WVGA. however, its picking layout-normal. Can anybody suggest me what I am doing wrong. Even though, I have 3 layouts ( layout-normal, layout-large, layout- small), Its always picking layout-normal. why its so.
I added properties to manifest file
CODE:.............
View 2 Replies
View Related
Aug 9, 2010
I'm looking at creating an AppWidget and want to have the user select which size they want before adding it. Thus, the user can choose 1x1, 2x2, etc. The Calendar widget in Android 2.2 (and possibly earlier, but not in 1.6) does this. How is this done?
View 11 Replies
View Related
Jan 19, 2010
I am currently trying to make my app compliant with all screen sizes / api levels. I have this mostly working, however there is 1 issue i cannot resolve: Layouts in the "layout-hdpi" folder are used by and any phone on 1.5 (API level 3). - Which i dont want, i want API level 3 phones to use the "layout" folder. So to resolve this I added "-v4" onto the folder also, this works, the folder is no longer used by 1.5 phones. However, now the folder is also not used on API Level 6 phones, for example the droid. The droid only picks up the folder if i name the folder: "layout-hdpi-v6". (Also if i put "-v3" on a folder, the layout folder is not used by API level 4 phones) My understanding is that the -v<api level> qualifer allows you to exclude phones on an API level that is too low, so -v4 should mean that the folder will be used by all phones on API level 4 and above. I am finding a folder is only used for that specific API level. Has anybody else ran into this same issue? And does anybody know of any possible solutions?
View 3 Replies
View Related
Apr 13, 2010
I've read the Android documentation:
http://developer.android.com/guide/practices/screens_support.html
but still have some questions. I'm trying to design a music application which basically has images of the instrument (ImageButton) that play a sound when clicked. However, I'm confused about how to have the ImageButtons scale to fit all the different screen sizes and how to position them.
Which layout is best used for needing to position ImageButtons in specific locations on the screen? (i.e. cymbals on a drum set) FrameLayout, RelativeLayout? If I only really care about medium and large screens, do I need to create different resources (images) for both as well as a different XML layout to position them? I'm trying to find the simplest way to do this without having to create a separate layout XML file for positioning/size and separate image resources for each screen.
View 1 Replies
View Related
Apr 24, 2009
I want to create an app widget that could take up a different number of "cells" on the home screen, but I don't think that the app widget framework easily supports this. I know that an app widget can have a configuration screen, and I'd like the user to be able select a sort of small, medium, or large size for the widget as part of my configuration activity. Unfortunately, I don't think that this is possible, correct? Based on the minWidth and minHeight properties, the Launcher app will assign a number of cells that I can't configure at run time.
For instance, if I want a weather widget that has a current, hourly and weekly format that take up 1, 2, and 4 cells respectively, I can't do this at run time. Instead, I believe my only option is to export 3 different widgets and have them all listed in the widget picker dialog as something like "Weather - current conditions", "Weather - hourly forcast", and "Weather - week long forcast".
View 2 Replies
View Related
Oct 31, 2009
What are the 4x1 app widget sizes for WVGA and FWVGA in both portrait and landscape?
View 9 Replies
View Related
Mar 1, 2010
i am developing a game and i need to use android1.5 only.
i wrote sample application using 1.6 and kept drawable-hdpi,-ldpi ... and application is working fine in emulator of 1.6. i made apk and opened an emulator (android 1.5) from command prompt application is also working fine.
in 1.6 if i change emulator resolutions the application UI is resizing. but in 1.5 emulators not.
is that mean, the application developed in android 1.6 runs in 1.5 emulator but multi screen support is not achieved?
..."how to achieve multiple screen sizes in android 1.5". multiple screen support is available from 1.6.
View 6 Replies
View Related
Apr 14, 2010
I'm confused regarding the densities. I see that with medium density, the screen resolution could be either 320x480, 480x800, or 480x854. So if I have an image thats 300px wide in the mdpi folder, how is it going to look the same size on all 3 different screen sizes (mainly 320x480 vs the other 2)? And by look the same size, I mean scale to be bigger or smaller depending upon the screen size.
View 5 Replies
View Related
Aug 20, 2010
all my contacts are google contacts with several linked to Facebook accounts.When I access my contacts through the People widget, all's good, I only see the google contacts (I've deselected Facebookers in the view menu). However when I access the Messages widget all my contacts are doubled up for some reason. I realise this list is also showing facebook contacts as well as google contacts but even the non-facebook contacts are doubled up.
View 1 Replies
View Related
Jul 27, 2010
I've just switched to launcherpro from sense, and the one thing I miss is the news widget. On sense in had three full page widgets devoted to it, and I need a replacement! Requirements are:
Full page widget
Multiple homescreen support
Simple aesthetics
Customisable news feeds
View 33 Replies
View Related
Jul 22, 2010
I am looking for a Twitter client for Android that can ...
1. Handle multiple accounts
2. Display multiple accounts on the widget
I like Seesmic but the widget is just too small for my taste. I can only see the very last tweet. It would be nice to have a widget where either tweets from multiple accounts are combined or there is the option to switch between the accounts quickly directly from the widget. Any suggestions?
View 1 Replies
View Related
Jun 4, 2009
I am learning the app widget programming in the 1.5 SDK release. I was playing with the sample widget (wiktionary) and found out that you can actually add multiple instance of the same widget to the home screen, is there a way to prevent this? An attribute in the XML? I am stuck with 3 instance of wikitonary and 2 instances of music player on my emulator now... can't get rid of them... :(Also I am looking into buliding my own app widget container, not a home screen replacement, just a container that can host other widgets, I read the appwidgethost api doc, is there any sample code or guide on how to use the appwidgethost api
View 3 Replies
View Related
Sep 2, 2009
I am wondering is there any way to create something similar to spinner but which allows multiple selection. I guess we can select multiple entries from ListView but I don't have much space to show all the entires and also I need to show three different categories on the same Activity which you can select from.
Here is what I want to do:
Category 1:
Category 2:
Category 3:
View 2 Replies
View Related
May 3, 2010
OK, here goes my first post.
I have the calendar syncing with my gmail calendar, which has multiple calendars inside (mine, my wifes, ours, baseball schedule, cavs schedule, etc..)
I also have the stock "mail" (not Gmail) application syncing with my exchange at work.
Since I got 7 home screens to work with, I wanna put my Gmail calendar on home screen #1, and my exchange calendar on home-screen #7. Sort of a seperation of home and work
So I put the stock widget on home-screen#1, and again on home-screen#7. But a widget is basically just a frontend for an app running in the background. When I go to home-screen#1 and select MINE, WIFES, and CAVS.......that selection affects the widget on home-screen #7 as well. I go to screen #7, tell it to display Exchange only.......and when I go back to #1, it is switched to exchange.
So.....any way to do what I want?
1) Have a calendar on home-screen#1 that shows my Gmail calendar(s)
2) Have a calendar on home-screen#7 that shows my Exchange calendar
View 2 Replies
View Related
May 19, 2010
Does anyone know if there is a widget that will remember multiple wifi connection so I don't have to input a code each time I switch to a different connection.
View 4 Replies
View Related
Nov 13, 2009
I've got a quick question about screen size support. Currently, I've got an application that is rockin' along just fine on 1.5 and 1.6. Today the client called and says they want to run on Droid. While I've downloaded the 2.0 SDK, I'm a little wary of compiling against it. Will it break 1.5 and 1.6 compatilbility? How will the "medium" phones (G1, MyTouch) know to use those layouts?
View 3 Replies
View Related
Oct 15, 2010
I want to develop an application for a tablet of 480*800 screen pixels. I had developed an application for normal mobiles, but now this screen size is large than normal size. what precaution should I take while developing the application? Because device is not available right now so I must have to work on the project using emulator.
View 2 Replies
View Related
Aug 25, 2009
G1, Dream, Magic, Hero, Galaxy and more to come... Does anybody have a rundown of their screen sizes (and of some of the devices to come out)?
View 2 Replies
View Related
Nov 29, 2009
Hello, I would like to ask what settings are necessary for my application to be available on all screen sizes: Is it enough to compile it using SDK 1.6 (but target is set to 1.5 and API level to 3) or maybe I have to set target to 1.6 and API level to 4?
View 4 Replies
View Related
Apr 27, 2010
supporting multiple screens (sizes and resolutions). I´ve searched not only this forum but many different websites and the android documentation but I´m probably doing a small mistake so things are not working properly.
Well, my main layout was designed with a HVGA screen, and it works great. When I try the same app on a WVGA, FWVGA, WQVGA or FWQVGA, I always get an unused space in the end of the layout because the screen ´s "heightnes" is proportionally bigger than HVGA´s.
So I consulted the documentation and decided to give a try on resource qualifiers, so I then created a nonsense UI and placed it on layout- large, created a new AVD using the WVGA skin and launched the app. Well, all I got was my old and not well stretched layout. The same happened to a FWVGA AVD.
This is the first problem. The second is: medium high density medium size screens and medium density large screens have the same resolution: how can I create a layout that is loaded for both, but not for (for example) medium size medium density or small size medium density screens?
View 10 Replies
View Related
Aug 24, 2010
I have a widget in my app (in single choice mode) and the list is longer than the screen so it requires scrolling. There is a lot of space above and below the text so I think that space could be reduced (and the font size) so that everything fit without scrolling. I haven't been able to figure out how to reduce that space.
I'm also trying to get a single checkbox below that list and i tried making 2 listviews on top of each other on the linear layout but it didn't work.
View 2 Replies
View Related
May 10, 2010
I want to make the edittext width the same size as button. My EditText is currently very small. I use relative layout.
<TextView
android:id="@+id/aha4"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textSize="17dip"
android:text="Vzdevek:"..............
View 4 Replies
View Related
Mar 18, 2010
I'd like to use different row descriptors (from the XML layout resource) in one ListView. Can I and how? Also, I'd like to be able to programmatically change the size of the rows, based on the data in each row, in a ListView. Can I and how?
View 1 Replies
View Related
Sep 17, 2010
I'm making an Android AppWidget to sit on the home screen.
The user's home screen space is precious, so I want the widget to be small. The ideal size would be 2x1 cells.
Some documentation suggests you can have any size you like?
But the AppWidget graphical design guidelines imply that only standard sizes are supported: 4x1, 3x3, 2x2.
Does that refer to the available PhotoShop templates or is it a limitation of Android itself?
I'm finding that a 2x1 widget works on my actual device (HTC Wildfire) but expands to 2x2 on the emulator.
HTC have their own special implementation of the home screen, so maybe my widget will only work at 2x1 on HTC devices?
Is there any way to create a 2x1 widget, or should I use a standard size?
My widget was adapted from the Simple Wiktionary sample.
The manifest has android:minWidth="146dip" and android:minHeight="72dip".
There's a RelativeLayout with android:layout_width="fill_parent" and android:layout_height="wrap_content"
I'm just starting with Android, so apologies in advance if this is a silly question. :)
View 1 Replies
View Related
May 27, 2010
I am trying to find the number of rectangles per sec in three different size rectangles. I did find it though. But the only problem is that I see all the rectangles after it ran the program completely. But I would like to have rectangles drawn, when I call canvas.drawRect(rec1,paint); function.
I am also looking to keep the old rectangles on the screen while new ones are drawn. I tried with lots of different options nothing worked. To display the rectangles. Can anybody show me the direction to which way to go?
package com.Benchmark.Rectangle; import java.util.TimerTask; import android.R.anim; import android.app.Activity; import android.app.AlertDialog; import android.graphics.drawable.shapes.*; import android.os.Bundle; import android.content.Context; import android.graphics.*; import android.view.View; import android.view.animation.Animation; import android.widget.Button; import android.widget.TextView; import android.widget.Toast; Code...
View 4 Replies
View Related
Mar 28, 2010
I have read the documentation on "supporting multiple screens" but can't seem to figure it out. I mean, i understand that resolution effects it but it just doesn't make sense to me that the droid and the T-Mobile G1 both use the regular "layout" directory. I developed the app on a droid and got everything to work but there is one view that i need to use hard-coded pixels.....which im using dpi. Now when installing the app on the G1 things on that view are getting cut off because the G1 has a much smaller screen. If I redo it to work on the G1 then everything is all squished together on the droid and even tho everything is visible this way, it looks silly.
I tried using the different attributes in my manifest but that didn't help but since i'm using minSDK as 4, the support different screen size attributes are true by default anyway.
Am i missing something very simple and obvious or is it just the way it is?? Isn't the physical screen size of the G1 like an 1" smaller?? I'm still kinda new to Android development so forgive me if i am missing something simple.
View 3 Replies
View Related
Jul 1, 2010
I'm currently developing my first android app, and my first game. I've been developing on a netbook with a CliqXT (HVGA). Things are going well, it renders perfectly on the smaller screen. I knew I'd have some issues when rendering on larger screens, but the issues I'm having are not what I was expecting and I'm kind of stuck.
So basically the game consists of a main SurfaceView which I'm rendering the tiled game world on to. I followed this tutorial to get started, and my structure is still pretty similar except that it calculates the boundries based on the player location:
http://www.droidnova.com/create-a-scrollable-map-with-cells-part-i,654.html
The game also has various buildings the player can enter. Upon entering it launches another activity for that particular building. The building activities are just normal Views with Android UI stuff defined in XML (Buttons, TextViews, etc).
What I expected to happen:
So I expected the the building UIs to render correctly on the larger screen. I specified all dimensions in "dp" and fonts in "sp" in hopes that they'd scale correctly. I expected the actual game tilemap to render generally correctly, but maybe be really tiny due to the higher resolution / dpi. I'm using a very similar function to the tutorial linked above (calculateLoopBorders(), my version is pasted below) to calculate how many tiles to render based on screen height and width (getHeight() and getWidth()).
What is actually happening:
The whole game is just being rendered as if it's HVGA. The tilemap, and the building UIs are just scaled down to the smaller screen size, leaving black borders around the left, right, and bottom (see images).
View 2 Replies
View Related