summaryrefslogtreecommitdiff
path: root/src/winwidget.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/winwidget.h')
-rw-r--r--src/winwidget.h109
1 files changed, 51 insertions, 58 deletions
diff --git a/src/winwidget.h b/src/winwidget.h
index de08ec9..47ebfcc 100644
--- a/src/winwidget.h
+++ b/src/winwidget.h
@@ -59,58 +59,55 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
#define PROP_MWM_HINTS_ELEMENTS 5
/* Motif window hints */
-typedef struct _mwmhints
-{
- CARD32 flags;
- CARD32 functions;
- CARD32 decorations;
- INT32 input_mode;
- CARD32 status;
-}
-MWMHints;
-
-enum win_type
-{
- WIN_TYPE_UNSET, WIN_TYPE_SLIDESHOW, WIN_TYPE_SINGLE, WIN_TYPE_ABOUT,
- WIN_TYPE_THUMBNAIL, WIN_TYPE_THUMBNAIL_VIEWER
+typedef struct _mwmhints {
+ CARD32 flags;
+ CARD32 functions;
+ CARD32 decorations;
+ INT32 input_mode;
+ CARD32 status;
+} MWMHints;
+
+enum win_type {
+ WIN_TYPE_UNSET, WIN_TYPE_SLIDESHOW, WIN_TYPE_SINGLE,
+ WIN_TYPE_ABOUT,
+ WIN_TYPE_THUMBNAIL, WIN_TYPE_THUMBNAIL_VIEWER
};
-struct __winwidget
-{
- Window win;
- int x;
- int y;
- int w;
- int h;
- int im_w;
- int im_h;
- double im_angle;
- enum win_type type;
- unsigned char had_resize, full_screen;
- Imlib_Image im;
- GC gc;
- Pixmap bg_pmap;
- Pixmap bg_pmap_cache;
- char *name;
- gib_list *file;
- unsigned char visible;
-
- /* Stuff for zooming */
- unsigned char mode;
-
- unsigned char caption_entry; /* are we in caption entry mode? */
-
- /* New stuff */
- int im_x; /* image offset from window top left */
- int im_y; /* image offset from window top left */
- double zoom; /* From 0 (not visible) to 100 (actual size)
- all the way up to INT_MAX (ouch) */
- int click_offset_x;
- int click_offset_y;
- int im_click_offset_x;
- int im_click_offset_y;
-
- unsigned char has_rotated;
+struct __winwidget {
+ Window win;
+ int x;
+ int y;
+ int w;
+ int h;
+ int im_w;
+ int im_h;
+ double im_angle;
+ enum win_type type;
+ unsigned char had_resize, full_screen;
+ Imlib_Image im;
+ GC gc;
+ Pixmap bg_pmap;
+ Pixmap bg_pmap_cache;
+ char *name;
+ gib_list *file;
+ unsigned char visible;
+
+ /* Stuff for zooming */
+ unsigned char mode;
+
+ unsigned char caption_entry; /* are we in caption entry mode? */
+
+ /* New stuff */
+ int im_x; /* image offset from window top left */
+ int im_y; /* image offset from window top left */
+ double zoom; /* From 0 (not visible) to 100 (actual size)
+ all the way up to INT_MAX (ouch) */
+ int click_offset_x;
+ int click_offset_y;
+ int im_click_offset_x;
+ int im_click_offset_y;
+
+ unsigned char has_rotated;
};
int winwidget_loadimage(winwidget winwid, feh_file * filename);
@@ -133,18 +130,14 @@ void winwidget_get_geometry(winwidget winwid, int *rect);
int winwidget_get_width(winwidget winwid);
int winwidget_get_height(winwidget winwid);
winwidget winwidget_get_from_window(Window win);
-winwidget winwidget_create_from_file(gib_list * filename, char *name,
-
- char type);
+winwidget winwidget_create_from_file(gib_list * filename, char *name, char type);
winwidget winwidget_create_from_image(Imlib_Image im, char *name, char type);
void winwidget_rename(winwidget winwid, char *newname);
void winwidget_destroy(winwidget winwid);
void winwidget_create_window(winwidget ret, int w, int h);
void winwidget_clear_background(winwidget w);
Pixmap feh_create_checks(void);
-double feh_calc_needed_zoom(double *zoom, int orig_w, int orig_h, int dest_w,
-
- int dest_h);
+double feh_calc_needed_zoom(double *zoom, int orig_w, int orig_h, int dest_w, int dest_h);
void feh_debug_print_winwid(winwidget winwid);
winwidget winwidget_get_first_window_of_type(unsigned int type);
void winwidget_reset_image(winwidget winwid);
@@ -152,7 +145,7 @@ void winwidget_sanitise_offsets(winwidget winwid);
void winwidget_size_to_image(winwidget winwid);
void winwidget_render_image_cached(winwidget winwid);
-extern int window_num; /* For window list */
-extern winwidget *windows; /* List of windows to loop though */
+extern int window_num; /* For window list */
+extern winwidget *windows; /* List of windows to loop though */
#endif