X-Git-Url: https://git.dogcows.com/gitweb?a=blobdiff_plain;f=otk%2Fscreeninfo.hh;h=584d92ece76313893a0bc9e2011fa64971c52429;hb=8269fc2b3965d12ba308caa554bfa7ee037fba13;hp=314527ab92aa03a45047fcefc0fbfd8a09094ded;hpb=06de24ec6666578759eff2b348e50f5e8e20f3bd;p=chaz%2Fopenbox diff --git a/otk/screeninfo.hh b/otk/screeninfo.hh index 314527ab..584d92ec 100644 --- a/otk/screeninfo.hh +++ b/otk/screeninfo.hh @@ -1,7 +1,8 @@ -// -*- mode: C++; indent-tabs-mode: nil; -*- +// -*- mode: C++; indent-tabs-mode: nil; c-basic-offset: 2; -*- #ifndef __screeninfo_hh #define __screeninfo_hh +#include "size.hh" #include "rect.hh" extern "C" { @@ -9,6 +10,7 @@ extern "C" { } #include +#include namespace otk { @@ -19,28 +21,27 @@ private: Colormap _colormap; int _depth; - unsigned int _screen; + int _screen; std::string _display_string; - Rect _rect; + Size _size; #ifdef XINERAMA - RectList _xinerama_areas; + std::vector _xinerama_areas; bool _xinerama_active; #endif public: - ScreenInfo(unsigned int num); + ScreenInfo(int num); inline Visual *visual() const { return _visual; } inline Window rootWindow() const { return _root_window; } inline Colormap colormap() const { return _colormap; } inline int depth() const { return _depth; } - inline unsigned int screen() const { return _screen; } - inline const Rect& rect() const { return _rect; } - inline unsigned int width() const { return _rect.width(); } - inline unsigned int height() const { return _rect.height(); } + inline int screen() const { return _screen; } + inline const Size& size() const { return _size; } inline const std::string& displayString() const { return _display_string; } #ifdef XINERAMA - inline const RectList &xineramaAreas() const { return _xinerama_areas; } + inline const std::vector &xineramaAreas() const + { return _xinerama_areas; } inline bool isXineramaActive() const { return _xinerama_active; } #endif };