1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef UI_GFX_GEOMETRY_DIP_UTIL_H_
6 #define UI_GFX_GEOMETRY_DIP_UTIL_H_
8 #include "ui/gfx/gfx_export.h"
17 GFX_EXPORT
gfx::Point
ConvertPointToDIP(float scale_factor
,
18 const gfx::Point
& point_in_pixel
);
19 GFX_EXPORT
gfx::PointF
ConvertPointToDIP(float scale_factor
,
20 const gfx::PointF
& point_in_pixel
);
21 GFX_EXPORT
gfx::Size
ConvertSizeToDIP(float scale_factor
,
22 const gfx::Size
& size_in_pixel
);
23 GFX_EXPORT
gfx::Rect
ConvertRectToDIP(float scale_factor
,
24 const gfx::Rect
& rect_in_pixel
);
26 GFX_EXPORT
gfx::Point
ConvertPointToPixel(float scale_factor
,
27 const gfx::Point
& point_in_pixel
);
28 GFX_EXPORT
gfx::Size
ConvertSizeToPixel(float scale_factor
,
29 const gfx::Size
& size_in_pixel
);
30 GFX_EXPORT
gfx::Rect
ConvertRectToPixel(float scale_factor
,
31 const gfx::Rect
& rect_in_dip
);
34 #endif // UI_GFX_GEOMETRY_DIP_UTIL_H_