File: imviewWindow.hxx

package info (click to toggle)
imview 1.1.8-6
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k
  • size: 3,052 kB
  • ctags: 3,797
  • sloc: cpp: 29,842; sh: 2,620; ansic: 1,835; makefile: 756; exp: 112; python: 88
file content (51 lines) | stat: -rw-r--r-- 1,405 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
/*------------------------------------------------------------------------
 *
 *
 * A subclass of the Fl_Window, that has a few nicer features
 *
 * Hugues Talbot	 5 Jan 2001  
 *      
 *-----------------------------------------------------------------------*/

#ifndef IMVIEWWINDOW_H
#define IMVIEWWINDOW_H


#include <FL/Fl.H>
#include <FL/Fl_Window.H>
#ifdef HAVE_XINERAMA
#  include <FL/Fl.H>
#  include <FL/x.H>
extern "C" {
#  include <X11/extensions/Xinerama.h>
}
#endif // HAVE_XINERAMA

class imviewWindow: public Fl_Window {
public:
    imviewWindow(int w, int h, const char *label = 0);
    imviewWindow(int x, int y, int w, int h, const char *label=0);
    ~imviewWindow();
    void removeMainMenu(void);
    void addMainMenu(void);
    void resize(int x,int y, int w, int h);
    void size_range(int minw, int minh, int maxw=0, int maxh=0, int dw=0, int dh=0, int aspect=0);
    int  currentDisplayWidth(void);
    int  currentDisplayHeight(void);
#ifdef HAVE_XINERAMA
    // redefine these non-virtual methods with a version that supports Xinerama, if present
    void fullscreen(void);
    // fullscreen_off from stock fltk is still compatible.
#endif

private:
    int  w_lower_limit, w_upper_limit;
    int  h_lower_limit, h_upper_limit;
#ifdef HAVE_XINERAMA
    int  xinerama_screen;
    XineramaScreenInfo *screens;
    void  getXineramaInfo(void);
#endif
};

#endif // IMVIEWWINDOW_H