how to set setNextFocusDown in TextArea - textarea

I am try to use setNextFocusDown method in TextArea eg:
textArea.setNextFocusDown(nextTextField);
But in keyboard it does not show next button so how to set setNextFocusDown in TextArea ?

This will only apply if you do it in the beginning and only for TextArea subclasses. Notice this hint will not apply for every case.

Related

VoiceOver accessibility focus on a series of elements

Say I have a dialog box like this:
and I want to focus on title, then body and then each button one after another. I am able to focus on body using
UIAccessibilityPostNotification(UIAccessibilityScreenChangedNotification, dialog.bodyLabel);
but is there any way to define a set of elements we want to focus instead of a single one?
EDIT:
I have also tried to make a list of elements I want to focus on using this syntax:
dialog.accessibilityElements = #[dialog.titleLable, dialog.bodyLable, etc];
but it just reads the first element (in this case dialog.titleLable) and doesn't move to the next one. Any thoughts?
The default value is set to NO for all the elements.
set the isAccessibleElement to YES for the all individual elements in the dialog
and then you can do
dialog.accessibilityElements = #[dialog.titleLable, dialog.bodyLable];
so that voice over reads title label first and body label next.

Update select2 option text on-the-fly?

I want to change an option's text on the fly. The HTML can be changed easily by:
$('option[value=custom-pub]').text("New Text For Pub");
How can I force select2 to refresh the text? I don't want to destroy() and create the select2 object from scratch, because I want the user selection to stay selected.
Simply
$("select").select2();
works.

Button on jQuery UI

I am writing a script using jQueryUI's button http://jqueryui.com/dialog/#modal-form.
The button is pretty fancy looking.
Now, when I tried to use jQuery to change the display name of the button:
$('#signin').text("new name");
The Button revert to the original style of the browser, with no padding and etc. I don't know why change of style happens when I just change the display name of the button. Please suggest me a way to fix it.
To change button text use this :
$('#btnId').val('new-text');
I figured out how. I used a span tag around the display name and just change text of that span tag.

angularjs same textarea to edit multiple elements

I have this case where I set a current item from a list and I need to use a textarea to edit that element's value.
Because of some constraints I have to use a keyup event but I don't think that's a problem.
Check this fiddle: http://jsfiddle.net/terebentina/Euj2C/
click on first/second buttons - it works, it changes the text in the textarea to the value of each element.
change the text in the textarea to something
click on the first/second buttons again - the textarea is not updated anymore. If you look in console, you can see that it switches between the elements, it's just that the textarea is not updated anymore.
Any suggestions? this is driving me nuts!
I know there is a better way modifying your directive to do this but as a quick fix for now you can try binding your textarea to a ngModel value that is just a copy of the current text in the selected element:
<textarea keyup="" ng-model="keyupText"></textarea>
With this in as your current function:
$scope.current = function(idx) {
$scope.current_element = $scope.elements[idx];
$scope.keyupText = $scope.current_element.value;
console.log('current is', $scope.current_element.value);
}
See this fiddle for an example.

How to change the color of some text in textbox - Silverlight 3?

I have a usual TextBox. I know in order to change the color of some text I can use Run tag. But when I try to use it imperatively instead declaratively (because I need to do that dynamically) I have the text in TextBox like
AAA<Run...>Text to be changed in color</Run>
and sure nothing in color changes.
How can I change the color of some text in some program way?
Thanks
I'm fairly sure you have to use a RichTextBox for that, TextBox only works with plaintext.

Resources