jaxim
Visitor
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-29-2018
11:19 AM
Problem w/ Changing the focusBitmapUri of MiniKeyboard
I am trying to change the background (focusBitmapUri) of the focused text box of a minikeyboard using a 9-patch image. I ran into 2 problems:
Here are my questions:
- The background is no longer enlarged like the default focused background. (The focused key no longer appears scaled by a factor greater than 100%.) I tried to alter where I place the 9 grid lines. I tried to include an empty border around the 9-patched image. I get varying results but none of those results have the focused key as large as the default focused key (with no passed focusBitmapUri).
- I also tried to alter the keyboard's focusedKeyColor and it seems that when I also assign a value to focusBitmapUri, then the text color has an opacity to it. (it's see thru.) My background is completely black and when I assign the focused text color to white "0xFFFFFFFF", the text looks dark gray rather than white and it is very hard to read. If I do not pass an image to the focusBitmapUri, then the font has no opacity.
Here are my questions:
- How do I get the focused background to be appear as large as the default focused background?
- How do I ensure the text color of the focused key does not have any opacity?
14 REPLIES 14
jaxim
Visitor
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-12-2019
06:30 AM
Re: Problem w/ Changing the focusBitmapUri of MiniKeyboard
this is still a problem. Does anyone know of a solution?
norcaljohnny
Roku Guru
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-12-2019
08:14 AM
Re: Problem w/ Changing the focusBitmapUri of MiniKeyboard
2 things...
1. What do you have your "ui_resolutions=" set to in your manifest file?
2. You can use color="#ffffff" if you intend not to have transparency. Which I get better results from and when transparency is needed I simply use opacity=".7" for instance.
1. What do you have your "ui_resolutions=" set to in your manifest file?
2. You can use color="#ffffff" if you intend not to have transparency. Which I get better results from and when transparency is needed I simply use opacity=".7" for instance.
jaxim
Visitor
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-12-2019
10:55 AM
Re: Problem w/ Changing the focusBitmapUri of MiniKeyboard
ui_resolutions is set to "fhd"
norcaljohnny
Roku Guru
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-12-2019
02:51 PM
Re: Problem w/ Changing the focusBitmapUri of MiniKeyboard
As in like this with no spaces or quotes?
ui_resolutions=fhd
jaxim
Visitor
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-15-2019
07:16 AM
Re: Problem w/ Changing the focusBitmapUri of MiniKeyboard
that is correct. Suggestions?
jaxim
Visitor
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-17-2019
11:44 AM
Re: Problem w/ Changing the focusBitmapUri of MiniKeyboard
Why would the ui_resolutions affect things? Do I need to create an fhd version of the focusBitmapUri image? If so, how is it different?
jaxim
Visitor
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-29-2019
02:32 PM
Re: Problem w/ Changing the focusBitmapUri of MiniKeyboard
Does anyone have any insight into this? I'm starting to think it might be a Roku firmware bug.
Has anyone had any success in using the ui_resolutions field to add a custom focus indicator AND still have it successfully display larger than a non-focused key?
Has anyone had any success in using the ui_resolutions field to add a custom focus indicator AND still have it successfully display larger than a non-focused key?

speechles
Roku Guru
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-29-2019
04:28 PM
Re: Problem w/ Changing the focusBitmapUri of MiniKeyboard
Show come code. Explain your issue with code. Do not try to do this with text. Code please.
What are you trying to do with the keyboard? Does it open within a dialog? Do you really want to change backgroundUri of the dialog the keyboard spawns into?
m.top.keyboard.focusedKeyColor = "0xffffffff"
m.top.keyboard.keyColor = "0xffffffff"
I use the above just fine. You can set the opacity _IN_ the color. The last 2 ff means make it bright as bright gets. The 255 on the scale of 255.
To figure the opacity divide what you put: ff = 255. say you want 0.8 opacity. 80% of FF = what you want to put at the end of your colors.
The main thing is likely there is no issue here. You just aren't doing it right. Without providing code for us to see what you are doing wrong we can't assume you are doing it right. It cannot be assumed this is a bug. You need code that proves the bug. Can you provide that?
Also your statement of: "I tried to include an empty border around the 9-patched image. "
No wonder it doesn't work. Do you understand what a 9patch image is? There can't be empty around. Yes really. Stop doing that.. lol. It needs to know where exactly the edge is to know how to compose the "growth" of this 9patch. It also needs this to know how to apply your corners. You wont get proper growth without proper understanding of this and how to construct a 9patch.
What are you trying to do with the keyboard? Does it open within a dialog? Do you really want to change backgroundUri of the dialog the keyboard spawns into?
m.top.keyboard.focusedKeyColor = "0xffffffff"
m.top.keyboard.keyColor = "0xffffffff"
I use the above just fine. You can set the opacity _IN_ the color. The last 2 ff means make it bright as bright gets. The 255 on the scale of 255.
To figure the opacity divide what you put: ff = 255. say you want 0.8 opacity. 80% of FF = what you want to put at the end of your colors.
The main thing is likely there is no issue here. You just aren't doing it right. Without providing code for us to see what you are doing wrong we can't assume you are doing it right. It cannot be assumed this is a bug. You need code that proves the bug. Can you provide that?
Also your statement of: "I tried to include an empty border around the 9-patched image. "
No wonder it doesn't work. Do you understand what a 9patch image is? There can't be empty around. Yes really. Stop doing that.. lol. It needs to know where exactly the edge is to know how to compose the "growth" of this 9patch. It also needs this to know how to apply your corners. You wont get proper growth without proper understanding of this and how to construct a 9patch.
jaxim
Visitor
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-02-2019
06:41 AM
Re: Problem w/ Changing the focusBitmapUri of MiniKeyboard
Here's the code...
m.top.keyboard.focusBitmapUri = [pathToImage]
One line. That simple.
Changing the focused or unfocused text color as you suggested is not what I want. I want to change the color of the background color. Do you have any experience changing the background color? If you do and you have seen what I have described, then I am interested to hear from you.
thanks so much!! 🙂
m.top.keyboard.focusBitmapUri = [pathToImage]
One line. That simple.
Changing the focused or unfocused text color as you suggested is not what I want. I want to change the color of the background color. Do you have any experience changing the background color? If you do and you have seen what I have described, then I am interested to hear from you.
thanks so much!! 🙂