Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding support for uidatepicker #24

Open
Dev-iL opened this issue Sep 20, 2018 · 0 comments
Open

Adding support for uidatepicker #24

Dev-iL opened this issue Sep 20, 2018 · 0 comments

Comments

@Dev-iL
Copy link
Member

Dev-iL commented Sep 20, 2018

Summary

This is a type of element that was added in R2018b, having the following HTML structure:

<div id="undefined" data-type="matlab.ui.control.DatePicker" data-tag="e8b66256" class="vc-widget" style="left: 99px; bottom: 99px; width: 150px; height: 22px;">
  <div class="vc-datepicker" id="uniqName_29_0" widgetid="uniqName_29_0">
    <div class="mwWidget mwComboBox mwDatePicker dijitDownArrowButton mwEditableComboBox mwDefaultVisualFamily mwDisabledMixin mwEnabled mwEditableMixin mwDescriptionMixin mwSizeMixin" id="uniqName_54_0" widgetid="uniqName_54_0" aria-disabled="false" style="width: 150px; height: 22px;">
      <div class="mwComboBoxInnerContainer">
        <div class="mwTextFieldContainerNode" data-dojo-attach-point="textFieldContainerNode" style="width: calc(100% - 22px); background-color: rgb(255, 255, 255); box-shadow: rgba(255, 255, 255, 0.9) 0px 1px 0px 0px inset;">
          <div class="mwWidget mwTextField mwDefaultVisualFamily mwDescriptionMixin mwDisabledMixin mwEnabled mwHorizontalAlignmentMixin mwEditableMixin mwSizeMixin mwTextInputValueMixin mwHorizontalAlignmentRight" id="uniqName_65_0" widgetid="uniqName_65_0" data-tag="" aria-disabled="false" title="" style="width: 100%; height: 22px;">
            <input class="mwInputNode mwAlignmentNode" spellcheck="false" type="text" data-dojo-attach-point="inputNode,focusNode" tabindex="0" placeholder="mm/dd/yyyy" style="background-color: rgba(0, 0, 0, 0); font-family: &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif; font-size: 12px; font-weight: normal; font-style: normal; color: rgb(0, 0, 0); font-variant: normal; font-stretch: normal; line-height: normal;">
            </div>
          </div>
          <div class="mwArrowContainerNode" data-dojo-attach-point="arrowNode">
            <div class="mwArrowNode">
            </div>
          </div>
        </div>
      </div>
    </div>
  </div>
</div>

For the above example, getWebElements currently returns id = uniqName_29_0, but this is not useful for styling. Instead (in addition?), uniqName_65_0 should be the returned handle.

Steps to Reproduce the Problem

hF = uifigure();
hDP = uidatepicker(hF);
mlapptools.setStyle(hDP, 'background', 'black')

Specifications

  • MATLAB Release: R2018b

Additional Information

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant