Mir
Public Member Functions | List of all members
mir::scene::DefaultCoordinateTranslator Class Reference

#include <default_coordinate_translator.h>

Inheritance diagram for mir::scene::DefaultCoordinateTranslator:
[legend]

Public Member Functions

geometry::Point surface_to_screen (std::shared_ptr< frontend::Surface > surface, int32_t x, int32_t y)
 Translate a surface coordinate into the screen coordinate space. More...
 
- Public Member Functions inherited from mir::scene::CoordinateTranslator
virtual ~CoordinateTranslator ()=default
 

Member Function Documentation

geom::Point mir::scene::DefaultCoordinateTranslator::surface_to_screen ( std::shared_ptr< frontend::Surface surface,
int32_t  x,
int32_t  y 
)
virtual

Translate a surface coordinate into the screen coordinate space.

Parameters
[in]surfaceA frontend::Surface. This will need to be dynamic_cast into the scene::Surface relevant for the shell.
[in]x,yCoordinates to translate from the surface coordinate space
Returns
The coordinates in the screen coordinate space.
Exceptions
Astd::runtime_error if the translation cannot be performed for any reason.
Note
It is acceptable for this call to unconditionally throw a std::runtime_error. It is not required for normal functioning of the server or clients; clients which use the debug extension will receive an appropriate failure notice.

Implements mir::scene::CoordinateTranslator.


The documentation for this class was generated from the following files:

Copyright © 2012-2015 Canonical Ltd.
Generated on Wed Mar 30 00:29:56 UTC 2016