Sep 13 | 7:15 PM |
Mark M. | has entered the room |
Mark M. | turned on guest access |
Mark M. | has entered the room |
Mark M. | has left the room |
Sep 13 | 7:25 PM |
Ben K. | has entered the room |
Mark M. |
howdy, Ben!
|
Mark M. |
how can I help you today?
|
Ben K. |
I have a couple questions, first is one about the
Menu. Is there a way to hide the menu for a particular screen in
Honeycomb and above, I know it's deprecated
|
Ben K. |
Or changed to action bar
|
Mark M. |
I am confused
|
Mark M. |
what do you mean by "hide the menu"?
|
Ben K. |
Well make it so the action bar isn't visible at all
|
Mark M. |
oh
|
Mark M. |
well, you would do that the same way that you hide the title bar in pre-Honeycomb
|
Mark M. |
e.g., use Theme.NoTitleBar (or, I guess, Theme.Holo.NoTitleBar)
|
Ben K. |
Ok I see.
|
Ben K. |
I don't know if that's available in 2.2?
|
Sep 13 | 7:30 PM |
Mark M. |
Theme.NoTitleBar is
|
Ben K. |
Ok thanks
|
Mark M. |
it's actually Theme.Holo.NoActionBar for API Level 11+
|
Ben K. |
Ok thanks! My second question is about
drawables.. I'm using a FrameLayout to overlay one drawable on top of
another, but the drawables stretch in some cases.
|
Mark M. |
are you putting the drawables in ImageViews, or are you doing something else?
|
Ben K. |
Yes
|
Mark M. |
how are you specifying the sizes of the ImageViews?
|
Ben K. |
I'll check
|
Ben K. |
layout_width is warp_content and layout_height is match_parent
|
Mark M. |
OK
|
Sep 13 | 7:35 PM |
Ben K. |
Maybe layout_height should be wrap_content now that I'm looking at the code
|
Mark M. |
either that, or provide an appropriate scaleType
|
Ben K. |
The ImageView is part of a ListView item.
|
Mark M. |
e.g., android:scaleType="center"
|
Mark M. |
that should not matter
|
Mark M. |
though then your problem is how you are specifying the size of the FrameLayout
|
Ben K. |
I'll check
|
Mark M. |
regardless, if an image is being stretched, it's because that's what Android thinks you want
|
Mark M. |
if you do not want it stretched, you either need to use android:scaleType to control that behavior, or get the sizes right
|
Ben K. |
Ok
|
Ben K. |
I guess I am using a layer-list, not a FrameLayout, sorry
|
Mark M. |
OK
|
Mark M. |
a layer-list is designed for images with the same size AFAIK
|
Mark M. |
(leastways, that's how I see it used)
|
Ben K. |
I see
|
Mark M. |
so, then the issue is what you are putting the layer-list into, and whether it is the right size, etc.
|
Mark M. |
it's conceivable that layer-list works for disparate sizes
|
Mark M. |
but I have no idea what to expect there off the cuff
|
Sep 13 | 7:40 PM |
Ben K. |
It works but when I offset one image the other stretches
|
Mark M. |
yeah, beats me
|
Ben K. |
I'll see what I can do given what you've told me.
|
Ben K. |
My third (and final I think) question is: Is there
a way to query the Play Store for an application that can open a
particular mime-type?
|
Mark M. |
alas, no
|
Mark M. |
I've toyed with trying to build my own database for that, culled from developer submissions
|
Ben K. |
It would be nice to query that and display a list of applications that can open a file, with a link to them
|
Mark M. |
absolutely
|
Mark M. |
my vision was to tie the database to an improved "chooser" dialog
|
Mark M. |
one that would show installed apps *and* matches from the Play Store (or whereever)
|
Ben K. |
Yeah that would be great
|
Mark M. |
I may give it a shot someday -- getting enough developers to join would be the challenge
|
Sep 13 | 7:45 PM |
Ben K. |
I'd think they would want to because it would give them wider distribution
|
Mark M. |
agreed
|
Ben K. |
Well thanks for your time, are these transcripts still being sent out?
|
Mark M. |
visit http://commonsware.com/office-hours for the roster of transcripts
|
Ben K. |
Ok, thank you
|
Mark M. |
happy to help!
|
Ben K. | has left the room |
Sep 13 | 7:50 PM |
Pedro T. | has entered the room |
Mark M. |
howdy, Pedro!
|
Mark M. |
how can I help you today?
|
Pedro T. |
Hi!
|
Mark M. |
how can I help you today?
|
Pedro T. |
I'm relatively new to Android and I'm starting
developing on a project using the Android.media.facedetector library, to
isolate the face and replace it on a template image
|
Mark M. |
I have never used that particular library
|
Sep 13 | 7:55 PM |
Pedro T. |
so, i was thinking on approachs to isolate the face
|
Pedro T. |
the library allows me to calculate the position of the eyes throught the library
|
Pedro T. |
that comes with google 4.0.4
|
Pedro T. |
and the nose can be calculated to
|
Pedro T. |
so I was looking for ideas to work on in order to process the bitMap to isolate the face or at least the most of the face
|
Mark M. |
I am sorry, but I have no experience in this area
|
Pedro T. |
hooo, so sad!!
|
Mark M. |
I have never done anything much with image processing, unless it was *completely* done by a library
|
Sep 13 | 8:00 PM |
Mark M. |
and I have never tried doing image processing on Android
|
Pedro T. |
hoo I see
|
Ben K. | has entered the room |
Mark M. |
hello, again, Ben!
|
Ben K. |
Hello
|
Mark M. |
Pedro: do you have another question, perhaps one that I can answer? :-)
|
Pedro T. |
Bye mark I'll see on another office hour chat byee
|
Pedro T. |
thanks for your help
|
Mark M. |
OK
|
Mark M. |
Ben: do you have another question?
|
Pedro T. |
for now no... maybe when i get further on the book
|
Ben K. |
Yes, I checked and I have the Theme.NoTitleBar set
in the application tag in the manifest. I'm trying to get rid of the
action bar (three dots in a vertical line) soft key. Is this possible?
|
Mark M. |
that is the menu overflow affordance
|
Mark M. |
what is your android:targetSdkVersion set to?
|
Ben K. |
8
|
Mark M. |
that's your problem
|
Mark M. |
you will need at least 11
|
Sep 13 | 8:05 PM |
Mark M. |
and probably all the way to 14
|
Mark M. | |
Ben K. |
Ok
|
Ben K. |
Great!
|
Ben K. |
What are the implications of raising the target sdk?
|
Mark M. |
ummm... well...
|
Mark M. |
11 and higher gives you the holographic widget theme by default
|
Mark M. |
(though Theme.NoTitleBar will probably turn that off and give you the legacy widget theme)
|
Mark M. |
you would ordinarily have an action bar with 11 or higher, but you are disabling that
|
Mark M. |
your AsyncTasks will be single-threaded on Android 3.2 and higher devices if you use 14
|
Mark M. |
(use 14 for your targetSdkVersion, that is)
|
Ben K. |
Ok
|
Ben K. |
It won't affect compatibility with 2.2 devices
|
Ben K. |
?
|
Mark M. |
no
|
Mark M. |
2.2 will see a targetSdkVersion of 14, shrug its shoulders, and ignore it
|
Mark M. |
targetSdkVersion opts you into some changed behavior on newer devices, but does not affect older devices
|
Ben K. |
I see
|
Ben K. |
Ok well that's great, thanks!
|
Sep 13 | 8:10 PM |
Ben K. |
Have a good evening.
|
Mark M. |
you too!
|
Ben K. | has left the room |
Mark M. |
Pedro: if you come up with another question, feel free to ask
|
Sep 13 | 8:20 PM |
Pedro T. | has left the room |
Sep 13 | 8:25 PM |
Mark M. | has entered the room |
Mark M. | has left the room |
Mark M. | turned off guest access |