6.05.2008

Coordinate Systems

Flex supports three different coordinate systems:
  • Global: 0,0 is the upper left corner of the stage
  • Local: 0,0 is the upper left corner of the component (including margins and borders)
  • Content: 0,0 is the upper left corner of the component's content (not including margins and borders), even if the content is currently hidden due to scrolling
Flex components provide methods for converting between the coordinate systems:
  • contentToGlobal()
  • contentToLocal()
  • globalToContent()
  • globalToLocal()
  • localToContent()
  • localToGlobal()

No comments: