[android-beginners] How to set a TextView to look like the home screen icon text
Hi all, On the Android Home screen, the label set in the manifest on the application appears under the icon with a gray background. Does anyone know how to style a TextView or some other View Widget to look like the text showing under an application icon? I would like to know. Thanks and regards, Beth --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Beginners group. To post to this group, send email to android-beginners@googlegroups.com To unsubscribe from this group, send email to android-beginners-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-beginners?hl=en -~--~~~~--~~--~--~---
[android-beginners] How to redraw the list in ExpandableListViewActivity
Hi there, Here is the situation. In a TabbedView, one of three tabs is an ExpandableListViewActivity. My application is using SQL Lite to store the data bound to the ExpandableListView. When I change the SQL Lite data in another activity, I need to refresh the ExpandableListView and show the new data. If I am drawing the tab for the first time after adding new data, the list shows correctly after the tab switch. If I am in the ExpandableListViewActivity when I add new data to the list or edit existing data, then I do not see the change. In this case, when I exit the application and restart, I see the modified data was stored in SQL Lite as expected. Can anyone suggest how I might get the tab to redraw the list? The partially working code looks like this: @Override protected void onActivityResult(int requestCode, int resultCode, Intent intent) { super.onActivityResult(requestCode, resultCode, intent); //stuff deleted if((requestCode == EDITOR) resultCode==RESULT_OK) { tabs.setCurrentTab(1); tabs.getCurrentView().invalidate(); } } The constructor for the list adapter is where I execute the code to populate the groups and children. Do I want to drop and create a new list adapter? That seems like a waste of perfectly good rows. Is it something I should do in the ExpandableListViewActivity, rather than the TabHost? The fact that this is an expandable list is probably irrelevant; I am stuck where an object on the screen that has changed is not redrawn automatically. Your help is deeply appreciated. Best regards, Beth -- Pablo Picassohttp://www.brainyquote.com/quotes/authors/p/pablo_picasso.html - Computers are useless. They can only give you answers. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Beginners group. To post to this group, send email to android-beginners@googlegroups.com To unsubscribe from this group, send email to android-beginners-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-beginners?hl=en -~--~~~~--~~--~--~---
[android-beginners] SQL Lite question, can you insert negative numbers
Hello,Can I get an (Android) example for getting signed numbers into a SQL Lite database? I've been trying many silly things that generate syntax errors so I thought I could put out the question. Note that I searched and searched the groups and (surprisingly) found no history. Thanks and regards, Beth --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Beginners group. To post to this group, send email to android-beginners@googlegroups.com To unsubscribe from this group, send email to android-beginners-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-beginners?hl=en -~--~~~~--~~--~--~---
[android-beginners] Star-styling a checkbox in the res/values/styles file
Hello there, In my xml layout, I have set the star style on a CheckBox. style=?android:attr/starStyle It looks great. Now I want to setup a custom style for my CheckBox to use the star style as well as other settings (text size, padding) across activity layouts. How do I get the star attribute into my custom style declaration? Is it a parent attribute? Thanks and regards, Beth -- Jack Benny http://www.brainyquote.com/quotes/authors/j/jack_benny.html - I don't deserve this award, but I have arthritis and I don't deserve that either. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Beginners group. To post to this group, send email to android-beginners@googlegroups.com To unsubscribe from this group, send email to android-beginners-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-beginners?hl=en -~--~~~~--~~--~--~---
[android-beginners] CheckBox enabled/disabled reality check
Hello, I want to switch a button out of my UI in favor of a CheckBox object. However, the enable = false parameter in my layout does not seem to have any effect on a CheckBox! My plan is to code the CheckBox to be enabled when certain other objects are valid. With a button object, the grayness and the lack of response to clicks is clear and obvious. When I use a CheckBox and set it to be disabled it has no effect. The object is drawn the same way with true as it is drawn with false in the enabled/setClickable parameter, the callbacks for the touch events work the same, the object continues to respond to onClick and onCheckedChange events when it is supposed to be disabled. This looks like a bug to me. Has anybody got the setEnabled(false) or setClickable(false) methods working on a CheckBox? Any workaround or explanation would be helpful. Thanks and regards, Beth -- Rita Rudner http://www.brainyquote.com/quotes/authors/r/rita_rudner.html - I was a vegetarian until I started leaning toward the sunlight. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Beginners group. To post to this group, send email to android-beginners@googlegroups.com To unsubscribe from this group, send email to android-beginners-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-beginners?hl=en -~--~~~~--~~--~--~---
[android-beginners] install Android app from Gmail
Hey there, hi there, ho there...Is there a way to make Android open and install an apk file as an attachment sent in a Gmail message? This is a nice, signed apk file that installs to the phone correctly from Eclipse or the command line. I'm just checking to see if this is working for somebody somewhere. Cheers, Beth -- Princess Margarethttp://www.brainyquote.com/quotes/authors/p/princess_margaret.html - I have as much privacy as a goldfish in a bowl. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Beginners group. To post to this group, send email to android-beginners@googlegroups.com To unsubscribe from this group, send email to android-beginners-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-beginners?hl=en -~--~~~~--~~--~--~---
[android-beginners] Spinner's default selection, select nothing
Hi all, Do you know any way to turn off the default select that happens with Spinner creation? Although I could set a blank entry or put a selection prompt string at the top or bottom of my Spinner display array, I would prefer to skip any default selection and listen only for a selection done directly by the user after creation of my activity. There is an onNothingSelected listener method. Can I use the spinner setSelection method to select nothing? How do you select nothing in a Spinner? Ciao, Beth --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Beginners group. To post to this group, send email to android-beginners@googlegroups.com To unsubscribe from this group, send email to android-beginners-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-beginners?hl=en -~--~~~~--~~--~--~---
[android-beginners] LED Alerts
Hello good people, Has anybody got an LED notification from the notification manager working? I tried using a custom setup as well as using the DEFAULT_LIGHTS setting but I see nothing in the emulator nor on the device. The log shows the method is executing the code inside my if. Here's some code I tried: if (prefs.getBoolean(ctxt.getString(R.string.led), false)) { //notification.defaults |= Notification.DEFAULT_LIGHTS; // when default did not work I tried these settings notification.ledARGB = 0xff00ff00; notification.ledOnMS = 3000; notification.ledOffMS = 1000; notification.flags |= Notification.FLAG_SHOW_LIGHTS; } If you have it going can you send me a snippet with your working settings? Thanks and regards, Beth -- W. C. Fields http://www.brainyquote.com/quotes/authors/w/w_c_fields.html - If I had to live my life over, I'd live over a saloon. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Beginners group. To post to this group, send email to android-beginners@googlegroups.com To unsubscribe from this group, send email to android-beginners-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-beginners?hl=en -~--~~~~--~~--~--~---
[android-beginners] Layout component width measure returns zero from onCreate
Hi there, Can a layout expert offer insight here? I have an animation in a lovely LinearLayout ViewGroup object that I get into Java from the XML using findViewById. It's working great most of the time. However, my first call to the animate function at the end of onCreate measures the width of this ViewGroup to be zero. What am I missing? The same object will return correct width measurements later in the thread of execution. How can I get the correct measure from onCreate? Because of this behavior I have hard-coded values into my application for the Center X which might work nicely on the current HTC devices and then blow up later, or it might look bad in Europe on devices with different screen sizes. I tried a number of things to solve this (force layout, varied animation cache persistence, getMeasuredWidth instead of getWidth, invalidate on the ViewGroup and parent). The layout and the component's measurements should be the same for onCreate as it is in another method in the Activity that responds to touch input from the user. Also note that if I navigate in the app to another activity, change orientation, and then return to the first activity, this scenario also causes the ViewGroup's getWidth command to be zero. That is why I assume the issue is related to onCreate. How do I get the correct measure of a (linearlayout) component when executing from onCreate? Is there something in the window's drawing sequence that I need to workaround? Any tips or suggestions are most welcome. Regards, Beth --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Beginners group. To post to this group, send email to android-beginners@googlegroups.com To unsubscribe from this group, send email to android-beginners-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-beginners?hl=en -~--~~~~--~~--~--~---