By using the following code snippet, RadPopupEditor needs to indicate focus similar to RadDropDownList with the same properties applied:
Hello, Jason,
The improvement will be introduced in the next official release R1 2020. I suppose that it will be included in one of the upcoming latest internal builds as well. Stay tuned with the feedback item.
If the EditableAreaElement is collapsed, the arrow button will indicate the focus. Please refer to the below screenshots:
Focus indication:
Only the button element is visible:
Should you have further questions please let me know.
Regards,
Dess | Tech Support Engineer, Sr.
Progress Telerik
I would like to add some follow up information provided by Jason which should be considered when addressing this item:
"I should also point out that I'm using the DropDownList style in two ways.
- Normal PopupEditor with DropDownList style
- PopupEditor that looks like a button instead of a DropDown. See the code snippet below.
So, I'd want the focus cues to work for both ways because the EditableAreaElement might not be visible.
Here's what Dimitar suggested to get the PopupEditor to look like a button. Ideally, there would be another style or perhaps a different kind of PopupEditor that is already designed to look like a button."
radPopupEditor1.EditableAreaElement.Visibility = ElementVisibility.Collapsed;
radPopupEditor1.PopupEditorElement.ArrowButtonElement.Arrow.Visibility = ElementVisibility.Hidden;
radPopupEditor1.PopupEditorElement.ArrowButtonElement.ImagePrimitive.Visibility = ElementVisibility.Hidden;
radPopupEditor1.PopupEditorElement.ArrowButtonElement.TextPrimitive.Text = "Test1...";
radPopupEditor1.PopupEditorElement.ArrowButtonElement.TextPrimitive.TextAlignment = ContentAlignment.MiddleCenter;
radPopupEditor1.PopupEditorElement.ArrowButtonElement.MinSize = new Size(20, 20);
radPopupEditor1.PopupEditorElement.ArrowButtonElement.StretchHorizontally = true;
radPopupEditor1.TabStop = true;
Regards,
Dess | Tech Support Engineer, Sr.
Progress Telerik
Hello, Jason,
Indeed, it seems to be a reasonable request. I have also updated your Telerik points.
When the DropDownStyle property is set to DropDown, then the text becomes highlighted which is the indicator that the control is on focus. Another option is to make your own indicator, for example, a border which changes its colors. This can be achieved by subscribing to the GotFocus and LostFocus events and customize the border color.
private void radPopupEditor1_LostFocus(object sender, EventArgs e)
{
BorderPrimitive border = this.radPopupEditor1.PopupEditorElement.FindDescendant<BorderPrimitive>();
border.ForeColor = Color.FromArgb(156, 189, 232);
}
private void radPopupEditor1_GotFocus(object sender, EventArgs e)
{
BorderPrimitive border = this.radPopupEditor1.PopupEditorElement.FindDescendant<BorderPrimitive>();
border.ForeColor = Color.Red;
}
I hope this information helps. If you need any further assistance please don't hesitate to contact me.
Regards,
Dess | Tech Support Engineer, Sr.
Progress Telerik