[android-developers] Re: WebKit/WebView and Focus Highlighting
The trick is to use -webkit-tap-highlight-color. If the alpha of the color is 0, the orange ring won't be drawn. On Thu, Jan 22, 2009 at 4:33 PM, Andrew Hedges segd...@gmail.com wrote: I'm one of the design guys Mark was talking about. I found scant documentation on Apple's site about -webkit-focus-ring- color, but from what I saw and my own tests on an Android emulator and Safari, it appears that this is not a writable property, but an OS- level constant that is applied to elements with focus. Here's the page I found that calls this a constant and not a property: http://developer.apple.com/documentation/appleapplications/Reference/SafariCSSRef/Articles/StandardCSSProperties.html For example, I tried the following: select style=-webkit-focus-ring-color: green; option1/option /select In Android, the focus ring remained orange. In Safari, it remained blue. Mark, not sure what this means for us. Maybe you can hack the OS and set this value to transparent? C'mon, you can do magic, right? :-) On Jan 23, 2:07 am, Mark Murphy mmur...@commonsware.com wrote: Fred Grott(shareme) wrote: Found it :) I hope how about webkit-focus-ring-color Does that sound correct Mark? I mean there would have to be say an admin.css with webkit in Android setting this to orange correct? Thus, the question is can we override it? In my case, I'd settle for just disabling it. Based on researching that constant you cited, I thought maybe the :focus CSS pseudo-class would allow me to disable the focus ring, but apparently not. Of course, my CSS-fu is weak. I'll pass this info on to the design guys and see if it gives them any help. Thanks! -- Mark Murphy (a Commons Guy)http://commonsware.com _The Busy Coder's Guide to Android Development_ Version 2.0 Published! -- thanks, Grace --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: WebKit/WebView and Focus Highlighting
Grace Kloba wrote: The trick is to use -webkit-tap-highlight-color. If the alpha of the color is 0, the orange ring won't be drawn. Many thanks! -- Mark Murphy (a Commons Guy) http://commonsware.com _The Busy Coder's Guide to Android Development_ Version 2.0 Available! --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: WebKit/WebView and Focus Highlighting
Thanks Grace...we owe you one On Jan 25, 1:44 pm, Grace Kloba klo...@gmail.com wrote: The trick is to use -webkit-tap-highlight-color. If the alpha of the color is 0, the orange ring won't be drawn. On Thu, Jan 22, 2009 at 4:33 PM, Andrew Hedges segd...@gmail.com wrote: I'm one of the design guys Mark was talking about. I found scant documentation on Apple's site about -webkit-focus-ring- color, but from what I saw and my own tests on an Android emulator and Safari, it appears that this is not a writable property, but an OS- level constant that is applied to elements with focus. Here's the page I found that calls this a constant and not a property: http://developer.apple.com/documentation/appleapplications/Reference/... For example, I tried the following: select style=-webkit-focus-ring-color: green; option1/option /select In Android, the focus ring remained orange. In Safari, it remained blue. Mark, not sure what this means for us. Maybe you can hack the OS and set this value to transparent? C'mon, you can do magic, right? :-) On Jan 23, 2:07 am, Mark Murphy mmur...@commonsware.com wrote: Fred Grott(shareme) wrote: Found it :) I hope how about webkit-focus-ring-color Does that sound correct Mark? I mean there would have to be say an admin.css with webkit in Android setting this to orange correct? Thus, the question is can we override it? In my case, I'd settle for just disabling it. Based on researching that constant you cited, I thought maybe the :focus CSS pseudo-class would allow me to disable the focus ring, but apparently not. Of course, my CSS-fu is weak. I'll pass this info on to the design guys and see if it gives them any help. Thanks! -- Mark Murphy (a Commons Guy)http://commonsware.com _The Busy Coder's Guide to Android Development_ Version 2.0 Published! -- thanks, Grace --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: WebKit/WebView and Focus Highlighting
Fred Grott(shareme) wrote: Found it :) I hope how about webkit-focus-ring-color Does that sound correct Mark? I mean there would have to be say an admin.css with webkit in Android setting this to orange correct? Thus, the question is can we override it? In my case, I'd settle for just disabling it. Based on researching that constant you cited, I thought maybe the :focus CSS pseudo-class would allow me to disable the focus ring, but apparently not. Of course, my CSS-fu is weak. I'll pass this info on to the design guys and see if it gives them any help. Thanks! -- Mark Murphy (a Commons Guy) http://commonsware.com _The Busy Coder's Guide to Android Development_ Version 2.0 Published! --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: WebKit/WebView and Focus Highlighting
Your welcome Mark, Currently I am seeking side projects to take care of my own seed capital needs so if you see anything let me know.. I expect to find more tricks over the weekend..switching to using QuickConnect for Android.. On Jan 22, 7:07 am, Mark Murphy mmur...@commonsware.com wrote: Fred Grott(shareme) wrote: Found it :) I hope how about webkit-focus-ring-color Does that sound correct Mark? I mean there would have to be say an admin.css with webkit in Android setting this to orange correct? Thus, the question is can we override it? In my case, I'd settle for just disabling it. Based on researching that constant you cited, I thought maybe the :focus CSS pseudo-class would allow me to disable the focus ring, but apparently not. Of course, my CSS-fu is weak. I'll pass this info on to the design guys and see if it gives them any help. Thanks! -- Mark Murphy (a Commons Guy)http://commonsware.com _The Busy Coder's Guide to Android Development_ Version 2.0 Published! --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: WebKit/WebView and Focus Highlighting
Does that rectangle change with LightTouch enabled? I was kind of hoping that there would be a setting to turn it off or modify it.. On Jan 21, 7:33 pm, Mark Murphy mmur...@commonsware.com wrote: When viewing Web pages either in the built-in Web browser or in a WebView canvas, focusable items get the orange highlight ring as you navigate the page with the D-pad/trackball. A design team I am working with wishes to create some Web content, specifically for Android, where they handle their own focus highlighting via Javascript/CSS and wish to disable the built-in Android focus highlighting. In this case, the content is being viewed through a WebView, so I have some measure of control. I see some posts describing how to use ColorStateList, selector, and android:background to affect this sort of change...for a single View. How would one go about affecting this change for the contents of a WebView? Thanks in advance for any advice! -- Mark Murphy (a Commons Guy)http://commonsware.com Android Training on the Ranch! -- Mar 16-20, 2009http://www.bignerdranch.com/schedule.shtml --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: WebKit/WebView and Focus Highlighting
Found it :) I hope how about webkit-focus-ring-color Does that sound correct Mark? I mean there would have to be say an admin.css with webkit in Android setting this to orange correct? Thus, the question is can we override it? On Jan 21, 7:33 pm, Mark Murphy mmur...@commonsware.com wrote: When viewing Web pages either in the built-in Web browser or in a WebView canvas, focusable items get the orange highlight ring as you navigate the page with the D-pad/trackball. A design team I am working with wishes to create some Web content, specifically for Android, where they handle their own focus highlighting via Javascript/CSS and wish to disable the built-in Android focus highlighting. In this case, the content is being viewed through a WebView, so I have some measure of control. I see some posts describing how to use ColorStateList, selector, and android:background to affect this sort of change...for a single View. How would one go about affecting this change for the contents of a WebView? Thanks in advance for any advice! -- Mark Murphy (a Commons Guy)http://commonsware.com Android Training on the Ranch! -- Mar 16-20, 2009http://www.bignerdranch.com/schedule.shtml --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---