Popupwindow with Notes

Source: Internet
Author: User

1. Popupwindow Display and position setting


Window.showatlocation(Parent, Gravity. Right|Gravity.BOTTOM,Ten,Ten);The first parameter specifies a Popupwindowanchor (Anchor) view, which is the view on which to attach.
The second parameter specifies that the starting point is the lower-right corner of the parent, and the third parameter is set to the origin in the lower-right corner of parent, and 10 pixels to the left and the upper.//Popupwindow is displayed as a drop-down window for anchor. Which is shown in the lower left corner of the anchor
Window.Showasdropdown(Anchor);
The //xoff,yoff is offset based on the lower left corner of the anchor.
Window.Showasdropdown(Anchor, Xoff, Yoff);
Supplement anchor.getlocationonscreen (location);
Rect anchorrect = new rect (location[0], location[1],
Location[0] + anchor.getwidth (), Location[1] + anchor.getheight ()); A rect is a rectangular area with four coordinates that are lower left and bottom right, respectively.

Popupwindow with Notes

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.